]> git.michaelhowe.org Git - packages/o/openafs.git/commit
LINUX: fix RedHat 7.5 ENOTDIR issues
authorMark Vitale <mvitale@sinenomine.net>
Fri, 2 Mar 2018 04:16:56 +0000 (23:16 -0500)
committerBenjamin Kaduk <kaduk@mit.edu>
Sat, 10 Mar 2018 00:22:50 +0000 (19:22 -0500)
commitb73863b8d2669830a17c097abf1d846d0108a2f4
treeeb5b9489ce119151050871ef0fd49dc1e16be164
parent55fbc8ee055958b309011eeb62d7166ff0415905
LINUX: fix RedHat 7.5 ENOTDIR issues

Red Hat Linux 7.5 beta introduces a new file->f_mode flag
FMODE_KABI_ITERATE as a means for certain in-tree filesystems to
indicate that they have implemented file operation iterate() instead of
readdir().  The kernel routine iterate_dir() tests this flag to decide
whether to invoke the file operation iterate() or readdir().

The OpenAFS configure script detects that the file operation iterate()
is available under RH7.5 and so implements iterate() as
afs_linux_readdir().  However, since OpenAFS does not set
FMODE_KABI_ITERATE on any of its files, the kernel's iterate_dir() will
not invoke iterate() for any OpenAFS files.  OpenAFS has also not
implemented readdir(), so iterate_dir() must return -ENOTDIR.

Instead, modify OpenAFS to fall back to readdir() in this case.

Reviewed-on: https://gerrit.openafs.org/12935
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
(cherry picked from commit c818f86b79a636532d396887d4f22cc196c86288)

Change-Id: I71386b17f0c751b69c86ef0f5766a5baf3dc36bd
Reviewed-on: https://gerrit.openafs.org/12950
Reviewed-by: Mark Vitale <mvitale@sinenomine.net>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
src/afs/LINUX/osi_vnodeops.c