On Sonntag, 9. Oktober 2016 08:57:28 CEST Sven Eckelmann wrote:
compat-includes/compat.h can usually be used to solve compatibility problems with older kernels. This works well for functions, defines/enums and sometimes even structures that were introduced.
But this can fail when structs changed. Some of these can be solved in crude ways but sometimes it is unavoidable to have a version specific code. Unfortunately, this kind of code is not acceptable in the kernel and thus the compat infrastructure of the external module has to do add it automatically before the source is compiled.
This process works by creating a build directory which is prefilled with the source from net/batman-adv/. The patches from compat-patches/ will be applied on top of this copy and then the code is compiled.
Signed-off-by: Sven Eckelmann sven@narfation.org
v2:
- no change
.gitignore | 10 ++++------ Makefile | 31 +++++++++++++++++++++++++++---- compat-patches/README | 23 +++++++++++++++++++++++ compat-sources/Makefile | 6 +++--- 4 files changed, 57 insertions(+), 13 deletions(-) create mode 100644 compat-patches/README
Applied in 66ac14a09445b6066de6a8ae4382d8f981466ae3 [1].
Kind regards, Sven
[1] https://git.open-mesh.org/batman-adv.git/commit/66ac14a09445b6066de6a8ae4382...