Cleanup usage of LINUX_VERSION_CODE for older kernels 89/14389/14
authorCheyenne Wills <cwills@sinenomine.net>
Thu, 17 Dec 2020 02:48:46 +0000 (19:48 -0700)
committerBenjamin Kaduk <kaduk@mit.edu>
Mon, 19 Jul 2021 00:33:24 +0000 (20:33 -0400)
commit91a576142e36fa423ee1a571a040b5ccf16d10d7
treef7dc6b08df4432aa1fd9c43d2fbde4b5600990ab
parentcbc18e4b311bdd2c461f60b7b96eb2ab8a6d1ee5
Cleanup usage of LINUX_VERSION_CODE for older kernels

2.6.18 is the minimum supported linux kernel level. There are
preprocessor checks for specific kernel versions that predate 2.6.18.

Refactor the use of the LINUX_VERSION_CODE that checks for kernel
versions older than 2.6.18.

In addition, there are a couple of locations where the kernel version
is checked with an additional test to see if module_param or
module_param_array are defined.  These checks are used to determine
whether to use the macros module_param/module_param_array or to use
the macro MODULE_PARM. The macros module_param and module_param_array
were present in Linux prior to 2.6.12.  The macro MODULE_PARM was marked
as deprecated prior to 2.6.12 and removed in Linux 2.6.17 (8d3b33f67fd
'[PATCH] Remove MODULE_PARM').

Remove the preprocessor checks for module_param/module_param_array and
remove the use of MODULE_PARM.

The updates should have no functional changes.

Change-Id: I1dc5dca1252abfc865917757989df235c75059a6
Reviewed-on: https://gerrit.openafs.org/14389
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
13 files changed:
src/afs/LINUX/osi_alloc.c
src/afs/LINUX/osi_gcpags.c
src/afs/LINUX/osi_groups.c
src/afs/LINUX/osi_machdep.h
src/afs/LINUX/osi_module.c
src/afs/LINUX/osi_nfssrv.c
src/afs/LINUX/osi_pag_module.c
src/afs/LINUX/osi_probe.c
src/afs/LINUX/osi_vnodeops.c
src/afs/sysincludes.h
src/config/param.linux26.h
src/rx/LINUX/rx_kmutex.c
src/rx/LINUX/rx_kmutex.h