]> www.infradead.org Git - users/jedix/linux-maple.git/commit
ncpfs: fix a braino in OOM handling in ncp_fill_cache()
authorAl Viro <viro@zeniv.linux.org.uk>
Tue, 8 Mar 2016 03:17:07 +0000 (22:17 -0500)
committerChuck Anderson <chuck.anderson@oracle.com>
Thu, 26 May 2016 22:45:41 +0000 (15:45 -0700)
commit865a124feaf6ca6c7189155ca5741cc57574b2fd
treef36ef153017eb235ff215721ba20d25c2dd399ac
parent304e86418c0c3d2f7a5e7c3258dcc5b256939628
ncpfs: fix a braino in OOM handling in ncp_fill_cache()

Orabug: 23331002

[ Upstream commit 803c00123a8012b3a283c0530910653973ef6d8f ]

Failing to allocate an inode for child means that cache for *parent* is
incompletely populated.  So it's parent directory inode ('dir') that
needs NCPI_DIR_CACHE flag removed, *not* the child inode ('inode', which
is what we'd failed to allocate in the first place).

Fucked-up-in: commit 5e993e25 ("ncpfs: get rid of d_validate() nonsense")
Fucked-up-by: Al Viro <viro@zeniv.linux.org.uk>
Cc: stable@vger.kernel.org # v3.19
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Sasha Levin <sasha.levin@oracle.com>
(cherry picked from commit 906e5a6e6e73316fa4741ca53be014c9477a100c)

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