Commit 8954f2b8d8 added an unconditional:
MODULE_IMPORT_NS(VFS_internal_I_am_really_a_filesystem_and_am_NOT_a_driver);
For compatibility with old kernel versions, guard this declaration
with #ifdef MODULE_IMPORT_NS.
This specific symbol namespace is also Android-specific, so the
declaration should also be conditional on building for Android, but
there doesn't seem to be a single preprocessor symbol that indicates
that.
Signed-off-by: Ben Hutchings <ben.hutchings@mind.be>
This is done by specifying the ranges for 6.3 and 6.4 versions which need the fix.
Kernel 6.2, to my knowledge, is not used in other popular distros than Ubuntu.
Ubuntu had backported the change from kernel 6.5 to 6.2, which is why this is needed.
Added a comment instructing what to do if one wants to build the module
running kernel 6.2 on something else than Ubuntu.
It was broken due to kernel changes backported from 6.5 (torvalds/linux@e8c2af6).
Changes have been tested on the following configurations and observed to build:
- Debian Bullseye, kernel 6.1.38-4 (bullseye-backports)
- Debian Bookworm, kernel 6.1.52-1
- Ubuntu 23.04 Lunar, kernel 6.2.0-36
There are also other kernel versions which are affected up to some point in their history,
but there were a few reasons I ended up not including them:
- Kernel 6.2: Not in use on Debian, likely skipped in favor of 6.4+. Ubuntu though has backported the change to 6.2 on Lunar.
- Kernel 6.3: Not in use on Debian/Ubuntu, seems to have been skipped in favor of 6.4/6.5+.
- Kernel 6.4: Not in use on Ubuntu. Debian Bookworm has this available in backports, but they now also offer 6.5 which does not have the issue.
In case someone tries to build this module running kernel 6.2 on something other than Ubuntu, this fix is most likely necessary.
Kernel 4.10.x adjusted cfg80211_connect_bss to accept a timeout as the last
argument. Add a conditional statement which removes this extra parameter if the
kernel is less than version 4.10.x to fix build errors against version 4.9.x.
Note that the Jetson TX2 kernel is still version 4.9.x even though this version
is technically deprecated upstream.
Signed-off-by: Christian Stewart <christian@aperture.us>