]> asedeno.scripts.mit.edu Git - linux.git/commit
staging: lustre: llite: use d_splice_alias for directories.
authorNeilBrown <neilb@suse.com>
Mon, 12 Feb 2018 21:30:48 +0000 (08:30 +1100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 16 Feb 2018 14:13:32 +0000 (15:13 +0100)
commite9d4f0b9f55920821845b8e063ed593422c18d8a
tree8075031a6510841eae523ae1d23da464be7e4f7e
parenta22c3d41d187dc3cdaf41166ef0a20b8663fdfee
staging: lustre: llite: use d_splice_alias for directories.

In the Linux dcache a directory only ever has one dentry,
so d_splice_alias() can be used by ll_splice_alias() for directories.
It will find the one dentry whether it is DCACHE_DISCONNECTED or
IS_ROOT() or d_lustre_invalid().
Separating out the directories from non-directories will allow us
to simplify the non-directory code.

Signed-off-by: NeilBrown <neilb@suse.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/lustre/lustre/llite/namei.c