My system is an Intel nuc (NUC6CAYH), running Debian 11. I'm trying to install a kernel module to interact with the programmable LEDs via acpi. I have successfully installed this module on an identical system under Ubuntu 20.04 LTS, but it fails to install on Debian 11.
The driver is here: https://github.com/milesp20/intel_nuc_led
My install procedure:
git clone https://github.com/milesp20/intel_nuc_led.git
cd intel_nuc_led
sudo make dkms-deb
sudo dpkg -i /var/lib/dkms/intel-nuc-led/1.0/deb/intel-nuc-led-dkms_1.0_all.deb
The output of the last command:
Selecting previously unselected package intel-nuc-led-dkms.
(Reading database ... 89355 files and directories currently installed.)
Preparing to unpack .../intel-nuc-led-dkms_1.0_all.deb ...
Unpacking intel-nuc-led-dkms (1.0) ...
Setting up intel-nuc-led-dkms (1.0) ...
Removing old intel-nuc-led-1.0 DKMS files...
------------------------------
Deleting module version: 1.0
completely from the DKMS tree.
------------------------------
Done.
Loading new intel-nuc-led-1.0 DKMS files...
Building for 5.10.0-10-amd64
Building for architecture x86_64
Building initial module for 5.10.0-10-amd64
Error! Bad return status for module build on kernel: 5.10.0-10-amd64 (x86_64)
Consult /var/lib/dkms/intel-nuc-led/1.0/build/make.log for more information.
dpkg: error processing package intel-nuc-led-dkms (--install):
installed intel-nuc-led-dkms package post-installation script subprocess returned error exit status 10
Errors were encountered while processing:
intel-nuc-led-dkms
And, looking at that log file:
DKMS make.log for intel-nuc-led-1.0 for kernel 5.10.0-10-amd64 (x86_64)
Tue 21 Dec 2021 02:26:47 PM EST
make: Entering directory '/usr/src/linux-headers-5.10.0-10-amd64'
CC [M] /var/lib/dkms/intel-nuc-led/1.0/build/nuc_led.o
/var/lib/dkms/intel-nuc-led/1.0/build/nuc_led.c: In function ‘init_nuc_led’:
/var/lib/dkms/intel-nuc-led/1.0/build/nuc_led.c:475:75: error: passing argument 4 of ‘proc_create’ from incompatible pointer type [-Werror=incompatible-pointer-types]
475 | acpi_entry = proc_create("nuc_led", nuc_led_perms, acpi_root_dir, &proc_acpi_operations);
| ^~~~~~~~~~~~~~~~~~~~~
| |
| struct file_operations *
In file included from /var/lib/dkms/intel-nuc-led/1.0/build/nuc_led.c:36:
/usr/src/linux-headers-5.10.0-10-common/include/linux/proc_fs.h:109:122: note: expected ‘const struct proc_ops *’ but argument is of type ‘struct file_operations *’
109 | struct proc_dir_entry *proc_create(const char *name, umode_t mode, struct proc_dir_entry *parent, const struct proc_ops *proc_ops);
| ~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~
cc1: some warnings being treated as errors
make[2]: *** [/usr/src/linux-headers-5.10.0-10-common/scripts/Makefile.build:285: /var/lib/dkms/intel-nuc-led/1.0/build/nuc_led.o] Error 1
make[1]: *** [/usr/src/linux-headers-5.10.0-10-common/Makefile:1846: /var/lib/dkms/intel-nuc-led/1.0/build] Error 2
make: *** [/usr/src/linux-headers-5.10.0-10-common/Makefile:185: __sub-make] Error 2
make: Leaving directory '/usr/src/linux-headers-5.10.0-10-amd64'
So, to recap, it builds and installs fine on Ubuntu 20.04 LTS using kernel 5.4.0-91, but fails on Debian 11 using kernel 5.10.0-10.
Thanks.