diff options
| author | Martin Jansa <martin.jansa@gmail.com> | 2012-03-23 15:37:23 +0100 | 
|---|---|---|
| committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2012-03-23 17:47:14 +0000 | 
| commit | 38302a1353cf072b7c6c54f7f90936e4c2180102 (patch) | |
| tree | a0a117a47cbb766a488af2b5a1aa04dc1d500b74 | |
| parent | 56fe5300ab5ab072c20acd03d7fc26e9cae4e652 (diff) | |
| download | openembedded-core-38302a1353cf072b7c6c54f7f90936e4c2180102.tar.gz openembedded-core-38302a1353cf072b7c6c54f7f90936e4c2180102.tar.bz2 openembedded-core-38302a1353cf072b7c6c54f7f90936e4c2180102.zip | |
update-modules: update script to read /etc/modules-load.d/ directory
* show warning for old /etc/modutils/* files without .conf extension
* v2: keep adding modules also from old /etc/modutils/* after showing
  warning, this way update-modules will be backward compatible also on
  images without kernel upgrade
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
| -rwxr-xr-x | meta/recipes-kernel/update-modules/update-modules-1.0/update-modules | 15 | ||||
| -rw-r--r-- | meta/recipes-kernel/update-modules/update-modules_1.0.bb | 2 | 
2 files changed, 14 insertions, 3 deletions
| diff --git a/meta/recipes-kernel/update-modules/update-modules-1.0/update-modules b/meta/recipes-kernel/update-modules/update-modules-1.0/update-modules index 7ee7df8192..99040a1ab4 100755 --- a/meta/recipes-kernel/update-modules/update-modules-1.0/update-modules +++ b/meta/recipes-kernel/update-modules/update-modules-1.0/update-modules @@ -103,8 +103,8 @@ createfile() {  $HEADER"  #  # Please do not edit this file directly. If you want to change or add -# anything please take a look at the files in /etc/modutils and read -# the manpage for update-modules. +# anything please take a look at the files in /etc/modutils, /etc/modules-load.d  +# and read the manpage for update-modules.  #  EOF  } @@ -161,6 +161,7 @@ fi  createfile "$MODCONFTMPFILE"  createfile "$MODULESTMPFILE" +# well we're using /etc/modprobe.d/*.conf instead of /etc/modutils/*.conf anyway..  for cfg in /etc/modutils/* $CONF ; do  	if [ -f "$cfg" ]; then # this check is necesarry to skip /etc/modutils/archs  		if echo $cfg | grep -q '\.dpkg-[a-z]*\|~$' ; then @@ -168,6 +169,16 @@ for cfg in /etc/modutils/* $CONF ; do  		elif echo $cfg | grep -q '\.conf$' ; then  			addfile "$cfg" "$MODCONFTMPFILE"  		else +			echo "Please migrate your $cfg file to /etc/modules-load.d/*.conf" +			addfile "$cfg" "$MODULESTMPFILE" +		fi +	fi +done +for cfg in /etc/modules-load.d/*.conf; do +	if [ -f "$cfg" ]; then # this check is necesarry to skip weird entries +		if echo $cfg | grep -q '\.dpkg-[a-z]*\|~$' ; then +		        true +		else  			addfile "$cfg" "$MODULESTMPFILE"  		fi  	fi diff --git a/meta/recipes-kernel/update-modules/update-modules_1.0.bb b/meta/recipes-kernel/update-modules/update-modules_1.0.bb index d9697de6c3..2af75e6a99 100644 --- a/meta/recipes-kernel/update-modules/update-modules_1.0.bb +++ b/meta/recipes-kernel/update-modules/update-modules_1.0.bb @@ -5,7 +5,7 @@ LIC_FILES_CHKSUM = "file://${WORKDIR}/COPYING.GPL;md5=751419260aa954499f7abaabaa  RDEPENDS_${PN} = "module-init-tools-depmod" -PR = "r12" +PR = "r13"  SRC_URI = "file://update-modules \             file://COPYING.GPL" | 
