]> www.infradead.org Git - users/jedix/linux-maple.git/commit
namei: ->d_inode of a pinned dentry is stable only for positives
authorAl Viro <viro@zeniv.linux.org.uk>
Sun, 28 Feb 2016 00:23:16 +0000 (19:23 -0500)
committerChuck Anderson <chuck.anderson@oracle.com>
Thu, 26 May 2016 22:45:33 +0000 (15:45 -0700)
commite640f78a8d1bae768328da5d35ffefa30c428472
tree3f3d89ba1aa09450b284e405de67b1556266cf8c
parent88b4a2a3dacd7f677b029870636048efe343335e
namei: ->d_inode of a pinned dentry is stable only for positives

Orabug: 23330981

[ Upstream commit d4565649b6d6923369112758212b851adc407f0c ]

both do_last() and walk_component() risk picking a NULL inode out
of dentry about to become positive, *then* checking its flags and
seeing that it's not negative anymore and using (already stale by
then) value they'd fetched earlier.  Usually ends up oopsing soon
after that...

Cc: stable@vger.kernel.org # v3.13+
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Sasha Levin <sasha.levin@oracle.com>
(cherry picked from commit 9b77cd137fd841d7a14e1c9428cfc49f4df0306e)

Signed-off-by: Dan Duval <dan.duval@oracle.com>
fs/namei.c