diff options
-rwxr-xr-x | meta/recipes-kernel/modutils-initscripts/files/modutils.sh | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/meta/recipes-kernel/modutils-initscripts/files/modutils.sh b/meta/recipes-kernel/modutils-initscripts/files/modutils.sh index a78adf5729..3274c25a69 100755 --- a/meta/recipes-kernel/modutils-initscripts/files/modutils.sh +++ b/meta/recipes-kernel/modutils-initscripts/files/modutils.sh | |||
@@ -13,14 +13,16 @@ | |||
13 | 13 | ||
14 | LOAD_MODULE=modprobe | 14 | LOAD_MODULE=modprobe |
15 | [ -f /proc/modules ] || exit 0 | 15 | [ -f /proc/modules ] || exit 0 |
16 | [ -f /etc/modules ] || [ -d /etc/modules-load.d ] || exit 0 | ||
17 | [ -e /sbin/modprobe ] || LOAD_MODULE=insmod | ||
18 | 16 | ||
19 | if [ ! -f /lib/modules/`uname -r`/modules.dep ]; then | 17 | # Test if modules.dep exists and has a size greater than zero |
18 | if [ ! -s /lib/modules/`uname -r`/modules.dep ]; then | ||
20 | [ "$VERBOSE" != no ] && echo "Calculating module dependencies ..." | 19 | [ "$VERBOSE" != no ] && echo "Calculating module dependencies ..." |
21 | depmod -Ae | 20 | depmod -Ae |
22 | fi | 21 | fi |
23 | 22 | ||
23 | [ -f /etc/modules ] || [ -d /etc/modules-load.d ] || exit 0 | ||
24 | [ -e /sbin/modprobe ] || LOAD_MODULE=insmod | ||
25 | |||
24 | loaded_modules=" " | 26 | loaded_modules=" " |
25 | 27 | ||
26 | process_file() { | 28 | process_file() { |