0

I have added some IOCTL calls to the existing cifs kernel module. How do I ensure that the customized cifs module is supported with future kernel upgrades? Also how to compile the customized cifs module for various Linux flavours ?

The customized kernel module runs with the current kernel version. But as soon as I upgrade my kernel, I cant use the customized Cifs module since it is compiled with the previous kernel version.

I dont want to compile the kernel module manually to be supported for every kernel upgrade

  • 2
    You can use DKMS (Dynamic Kernel Module Support) to rebuild a module from source automatically when an updated kernel is installed by the package manager. However, there is no guarantee that your modified source will remain compatible with future kernel versions as the kernel API is not fixed in stone. – Ian Abbott Jul 23 '19 at 09:27
  • Have you seen [1](https://stackoverflow.com/questions/53839625/adaptation-from-old-init-timer-to-new-timer-setup/), [2](https://stackoverflow.com/questions/27761061/understanding-linux-version-code/) and [3](https://stackoverflow.com/questions/56485820/conditional-compilation-based-on-functionality-in-linux-kernel-headers/) for example? – red0ct Jul 23 '19 at 09:28
  • 1
    Have you considered upstreaming those changes to cifs so you don't have to maintain them? – idlethread Jul 24 '19 at 11:48

0 Answers0