LINUX: Don't compile syscall code with keyrings
commit32901c58b29ba4ac666f1dba9915cae2c1f03b52
authorAndrew Deason <adeason@sinenomine.net>
Mon, 9 Mar 2015 23:01:29 +0000 (9 18:01 -0500)
committerBenjamin Kaduk <kaduk@mit.edu>
Mon, 5 Dec 2016 01:48:52 +0000 (4 20:48 -0500)
tree770c15434290d94419caee4d939fd08accc8f7e7
parenta6e96a8f10df738eb9b69227d344a72eb830e02e
LINUX: Don't compile syscall code with keyrings

osi_syscall_init() is not currently called if we have kernel keyrings
support, since we don't need to set up or alter any syscalls if we
have kernel keyrings (we track PAGs by keyrings, and we use ioctls
instead of the AFS syscall now).

Since we don't call it, this commit makes us also not compile the
relevant syscall-related code. This allows new platforms to be added
without needing to deal with any platform-specific code for handling
32-bit compat processes and such, since usually we don't need to deal
with intercepting syscalls.

To do this, we just define osi_syscall_init and osi_syscall_cleanup as
noops if we have keyrings support. This allows us to reduce the #ifdef
clutter in the actual callers.

Note that the 'afspag' module does currently call osi_syscall_init
unconditionally, but this seems like an oversight. With this change,
the afspag module will no longer alter syscalls when we have linux
keyrings support.

Change-Id: I219b92d89303975765743712587ff897b55a2631
Reviewed-on: https://gerrit.openafs.org/11936
Reviewed-by: Chas Williams <3chas3@gmail.com>
Reviewed-by: Perry Ruiter <pruiter@sinenomine.net>
Reviewed-by: Michael Meffie <mmeffie@sinenomine.net>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
src/afs/LINUX/osi_groups.c
src/afs/LINUX/osi_module.c
src/afs/LINUX/osi_syscall.c