Hi,
I've not made any changes to the default Ubuntu-Mate and am running the same version on both a working and non-working machine. Both machines are dual processor multi-core HP Z280 workstations.
Code: Select all
miller@trailtechu3:~/src/peak-linux-driver-8.12.0
$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 20.04.2 LTS
Release: 20.04
Codename: focal
But I have always let the update services run, I see two different kernel versions on two machines. The first works and the second does not.
Working Machine:
Code: Select all
$ uname -a
Linux goliath 5.4.0-74-generic #83-Ubuntu SMP Sat May 8 02:35:39 UTC 2021 x86_64 x86_64 x86_64 GNU/Linux
Non-Working Machine:
Code: Select all
$ uname -a
Linux trailtechu3 5.8.0-53-generic #60~20.04.1-Ubuntu SMP Thu May 6 09:52:46 UTC 2021 x86_64 x86_64 x86_64 GNU/Linux
I don't know how the two machines wound up ad different versions.
The pcan driver downloaded and build fine I had to install;
Code: Select all
sudo apt install linux-headers
sudo apt install libpopt-dev
After I built the code the make install appears to pass
Code: Select all
$ sudo make install
make[1]: Entering directory '/home/miller/src/peak-linux-driver-8.12.0/driver'
Info: Left current 'pcan'-entry in /etc/modprobe.d/pcan.conf untouched.
mkdir -p /usr/local/bin
cp -f udev/pcan_usb_minor_check.bash /usr/local/bin
chmod 744 /usr/local/bin/pcan_usb_minor_check.bash
cp -f udev/45-pcan.rules /etc/udev/rules.d
Info: Copied 45-pcan.rules to /etc/udev/rules.d.
cp -f udev/blacklist-peak.conf /etc/modprobe.d
chmod 644 /etc/modprobe.d/blacklist-peak.conf
Info: mainline drivers removed and blacklisted in
/etc/modprobe.d/blacklist-peak.conf
udevadm control --reload-rules
- manually installing pcan under /lib/modules/5.8.0-53-generic/misc...
- Building dependencies...
make[1]: Leaving directory '/home/miller/src/peak-linux-driver-8.12.0/driver'
make[1]: Entering directory '/home/miller/src/peak-linux-driver-8.12.0/lib'
mkdir -p /usr/lib
cp -d lib/* /usr/lib
if [ -d lib32 ]; then \
mkdir -p /usr/lib32; \
cp -d lib32/* /usr/lib32; \
fi
mkdir -p /usr/include
chmod 644 libpcan.h libpcanfd.h
cp libpcan.h libpcanfd.h /usr/include
/sbin/ldconfig
make[1]: Leaving directory '/home/miller/src/peak-linux-driver-8.12.0/lib'
make[1]: Entering directory '/home/miller/src/peak-linux-driver-8.12.0/test'
cp receivetest transmitest bitratetest filtertest pcanfdtst pcan-settings receivetest_posix transmitest_posix /usr/local/bin
make[1]: Leaving directory '/home/miller/src/peak-linux-driver-8.12.0/test'
make[1]: Entering directory '/home/miller/src/peak-linux-driver-8.12.0/libpcanbasic'
make[2]: Entering directory '/home/miller/src/peak-linux-driver-8.12.0/libpcanbasic/pcanbasic'
cp libpcanbasic.so.4.4.2 /usr/lib/libpcanbasic.so.4.4.2
ln -sf /usr/lib/libpcanbasic.so.4.4.2 /usr/lib/libpcanbasic.so.4
ln -sf /usr/lib/libpcanbasic.so.4.4.2 /usr/lib/libpcanbasic.so.0
ln -sf /usr/lib/libpcanbasic.so.4 /usr/lib/libpcanbasic.so
cp PCANBasic.h /usr/include/PCANBasic.h
chmod 644 /usr/include/PCANBasic.h
/sbin/ldconfig
make[2]: Leaving directory '/home/miller/src/peak-linux-driver-8.12.0/libpcanbasic/pcanbasic'
make[2]: Entering directory '/home/miller/src/peak-linux-driver-8.12.0/libpcanbasic/pcaninfo'
cp pcaninfo.1.2.0 /usr/local/bin/pcaninfo
chmod 755 /usr/local/bin/pcaninfo
make[2]: Leaving directory '/home/miller/src/peak-linux-driver-8.12.0/libpcanbasic/pcaninfo'
make[2]: Entering directory '/home/miller/src/peak-linux-driver-8.12.0/libpcanbasic/examples'
make[3]: Entering directory '/home/miller/src/peak-linux-driver-8.12.0/libpcanbasic/examples/python'
make[3]: Nothing to be done for 'install'.
make[3]: Leaving directory '/home/miller/src/peak-linux-driver-8.12.0/libpcanbasic/examples/python'
make[3]: Entering directory '/home/miller/src/peak-linux-driver-8.12.0/libpcanbasic/examples/c++'
#cp pcanwrite pcanread pcaneventread pcaneventwrite /usr/local/bin
make[3]: Leaving directory '/home/miller/src/peak-linux-driver-8.12.0/libpcanbasic/examples/c++'
make[2]: Leaving directory '/home/miller/src/peak-linux-driver-8.12.0/libpcanbasic/examples'
make[1]: Leaving directory '/home/miller/src/peak-linux-driver-8.12.0/libpcanbasic'
But then the modprobe message fails....
Code: Select all
$ sudo modprobe pcan
modprobe: ERROR: could not insert 'pcan': Unknown symbol in module, or unknown parameter (see dmesg)
modprobe: ERROR: ../libkmod/libkmod-module.c:990 command_do() Error running install command 'modprobe --ignore-install pcan' for module pcan: retcode 1
modprobe: ERROR: could not insert 'pcan': Invalid argument
The end of the dmesg doesn't give me any clues, but I'm not really a kernel/driver guy.
Code: Select all
$ dmesg
... Clipped above this...
[59396.602767] kauditd_printk_skb: 23 callbacks suppressed
[59396.602771] audit: type=1400 audit(1622876416.237:35): apparmor="DENIED" operation="capable" profile="/usr/sbin/cups-browsed" pid=4586 comm="cups-browsed" capability=23 capname="sys_nice"
[70720.384766] perf: interrupt took too long (2557 > 2500), lowering kernel.perf_event_max_sample_rate to 78000
[83154.195648] SGI XFS with ACLs, security attributes, realtime, quota, no debug enabled
[83154.271684] Btrfs loaded, crc32c=crc32c-intel
[95412.197157] perf: interrupt took too long (3239 > 3196), lowering kernel.perf_event_max_sample_rate to 61750
[123394.492241] perf: interrupt took too long (4151 > 4048), lowering kernel.perf_event_max_sample_rate to 48000
[145796.333884] audit: type=1400 audit(1622962817.035:36): apparmor="DENIED" operation="capable" profile="/usr/sbin/cups-browsed" pid=16029 comm="cups-browsed" capability=23 capname="sys_nice"
[158313.335023] perf: interrupt took too long (5219 > 5188), lowering kernel.perf_event_max_sample_rate to 38250
[214254.632035] perf: interrupt took too long (6530 > 6523), lowering kernel.perf_event_max_sample_rate to 30500
[232197.284274] audit: type=1400 audit(1623049219.010:37): apparmor="DENIED" operation="capable" profile="/usr/sbin/cups-browsed" pid=22007 comm="cups-browsed" capability=23 capname="sys_nice"
[267553.266576] can: controller area network core (rev 20170425 abi 9)
[267553.266647] NET: Registered protocol family 29
[267553.270190] can: raw protocol (rev 20170425)
[268010.091526] pcan: module verification failed: signature and/or required key missing - tainting kernel
[268010.091689] pcan: Unknown symbol alloc_canfd_skb (err -2)
[268010.091784] pcan: Unknown symbol open_candev (err -2)
[268010.091868] pcan: Unknown symbol alloc_can_skb (err -2)
[268010.091903] pcan: Unknown symbol unregister_candev (err -2)
[268010.091950] pcan: Unknown symbol can_change_mtu (err -2)
[268010.092006] pcan: Unknown symbol alloc_candev_mqs (err -2)
[268010.092110] pcan: Unknown symbol close_candev (err -2)
[268010.092169] pcan: Unknown symbol can_bus_off (err -2)
[268010.092271] pcan: Unknown symbol register_candev (err -2)
The non-working computer does have an ISOtp driver installed.
If I thought reinstalling Linux would correct the issue I'd do it but am concerned that some later kernel update will just do it again. I'd prefer to get the pcan driver to work without reinstalling. We run this code and PCAN USB devices on probably 20 machines in my division.. If they all start failing after recommended updates I'm going to have a support storm on my hands.
If you have any more suggestions I'll try them.
Miller