kernel-module-qualcomm: qualcomm-pre-up: compatibility improvement for modprobe

The root filesystem can have installed the busybox modprobe implementation or
the kmod modprobe implementation.
Check the version installed and compound the modprobe arguments.

Signed-off-by: Isaac Hermida <isaac.hermida@digi.com>
This commit is contained in:
Isaac Hermida 2016-06-24 13:36:27 +02:00
parent 113e9a0e0b
commit 021bc9d29d
1 changed files with 5 additions and 1 deletions

View File

@ -49,8 +49,12 @@ if ! cmp -s ${TMP_MACFILE} ${MACFILE}; then
fi
rm -f ${TMP_MACFILE}
# Check the version of modprobe installed to compound the arguments.
if readlink -f $(which modprobe) | grep -qs kmod; then
MODPROBE_ARGS="-i"
fi
# Load the wireless module with the params defined in modprobe.d/qualcomm.conf
modprobe wlan
modprobe ${MODPROBE_ARGS} wlan
# Validate that firmware was loaded by checking if the interface is present.
if [ -d "/sys/class/net/${IFACE}" ]; then