Using MODPROBE_FLAGS in /etc/ethercat.conf fails loading of master kernel module
Hi,
I found an unexpected behaviour of version 1.6.7 of EtherCAT Master:
When using the MODPROBE_FLAGS
in the /etc/ethercat.conf
, the loading of modules is failing at systemd startup time.
E.g. MODPROBE_FLAGS="run_on_cpu=0x3"
leads to a systemd error message modprobe: FATAL: Module run_on_cpu=0x3 not found in directory /lib/modules/5.15.148-rt74-6.8.0-devel+git.8c5c2dcbf6ba
.
The cause seems to be in the /sbin/ethercatctl
script.
Here the variable ${MODPROBE_FLAGS}
and the following variable for the kernel modulename (ec_master
) are in wrong order after the call of modprobe (${MODPROBE}
).
The man page of modprobe says: modprobe [-v] [-V] [-C config-file] [-n] [-i] [-q] [-b] [modulename] [module parameters...]
So as far as I understand, first comes the modulename like ec_master followed by the kernel module parameters like run_on_cpu=0x3
.
I tested a quick fix of /sbin/ethercatctl
on the EtherCat master which works fine.