LINUX: Debian/Ubuntu build regression on kernel 3.16.39 23/12523/3
authorSergio Gelato <Sergio.Gelato@astro.su.se>
Wed, 22 Feb 2017 21:55:33 +0000 (13:55 -0800)
committerBenjamin Kaduk <kaduk@mit.edu>
Sun, 26 Feb 2017 02:09:26 +0000 (21:09 -0500)
commit6ea6c182c7fb6c22dafbbf203abcc23726e06cba
treeeb70272ab94ad3acdf5f6e8a21c03ad05a34abfc
parent789319bf0f2b26ad67995f8cbe88cee87a1bbdc0
LINUX: Debian/Ubuntu build regression on kernel 3.16.39

Now that kernel 4.9 has hit jessie-backports, it becomes desirable to
also backport the associated openafs patches.

Unfortunately, Linux-4.9-inode_change_ok-becomes-setattr_prepare.patch
causes a build failure against jessie's current default kernel,
3.16.39-1, due to the fact that setattr_prepare() is available (it was
cherrypicked to address CVE-2015-1350) but file_dentry() is not (it was
introduced in kernel 4.6).

This makes it difficult to have a version of openafs for jessie that
supports both kernels.

To deal with this, follow the implementation of file_dentry() in 4.6,
and simplify it to account for the lack of d_real() support in older
kernels.

Note that inode_change_ok() has been added back to 3.16.39-1 to avoid
ABI changes. That means the current openafs packages in jessie continue
to work with kernel 3.16.39-1 since they do not include
Linux-4.9-inode_change_ok-becomes-setattr_prepare.patch.

Originally reported at
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=855366

FIXES RT134158

Change-Id: I157aa2ff25945c1c6e3b8e4a600557125711a681
Reviewed-on: https://gerrit.openafs.org/12523
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Michael Meffie <mmeffie@sinenomine.net>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
acinclude.m4
src/afs/LINUX/osi_compat.h