• R/O
  • HTTP
  • SSH
  • HTTPS

Commit

Tags
Aucun tag

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

bootable/newinstaller


Commit MetaInfo

Révision10a68efaf5265887fe76a07fa655722cd6bf9c0d (tree)
l'heure2015-10-23 17:32:15
AuteurChih-Wei Huang <cwhuang@linu...>
CommiterChih-Wei Huang

Message de Log

init: avoid using init modprobe

The init modprobe should not be used before the porting is finished,
otherwise the system suddenly reboots.

Also remove the obsolete way to load modules.

Change Summary

Modification

--- a/initrd/init
+++ b/initrd/init
@@ -3,7 +3,7 @@
33 # By Chih-Wei Huang <cwhuang@linux.org.tw>
44 # and Thorsten Glaser <tg@mirbsd.org>
55 #
6-# Last updated 2015/10/05
6+# Last updated 2015/10/23
77 #
88 # License: GNU Public License
99 # We explicitely grant the right to use the scripts
@@ -169,7 +169,7 @@ if [ -x system/bin/ln -a \( -n "$DEBUG" -o -n "$BUSYBOX" \) ]; then
169169 fi
170170
171171 # ensure keyboard driver is loaded
172-[ -n "$INSTALL" -o -n "$DEBUG" ] && modprobe atkbd
172+[ -n "$INSTALL" -o -n "$DEBUG" ] && busybox modprobe atkbd
173173
174174 if [ 0$DEBUG -gt 0 ]; then
175175 echo -e "\nType 'exit' to continue booting...\n"
--- a/initrd/scripts/0-auto-detect
+++ b/initrd/scripts/0-auto-detect
@@ -1,6 +1,6 @@
11 #
22 # By Chih-Wei Huang <cwhuang@linux.org.tw>
3-# Last updated 2015/10/20
3+# Last updated 2015/10/23
44 #
55 # License: GNU Public License
66 # We explicitely grant the right to use the scripts
@@ -13,7 +13,7 @@ auto_detect()
1313 tmp=/tmp/dev2mod
1414 echo 'dev2mod() { while read dev; do case $dev in' > $tmp
1515 sort -r /lib/modules/`uname -r`/modules.alias | \
16- sed -n 's/^alias *\([^ ]*\) *\(.*\)/\1)modprobe \2;;/p' >> $tmp
16+ sed -n 's/^alias *\([^ ]*\) *\(.*\)/\1)busybox modprobe \2;;/p' >> $tmp
1717 echo 'esac; done; }' >> $tmp
1818 source $tmp
1919 cat /sys/bus/*/devices/*/modalias | dev2mod
@@ -41,19 +41,12 @@ find_network_dev_name()
4141
4242 load_modules()
4343 {
44- if [ -n "$FOUND" ]; then
45- [ -n "$PREDEV" ] && modprobe $PREDEV
46- [ -n "$FB0DEV" -a -z "$UVESA_MODE" ] && modprobe $FB0DEV
47- [ -n "$LANDEV" ] && modprobe $LANDEV
48- [ -n "$WIFDEV" ] && modprobe $WIFDEV
49- [ -n "$SNDDEV" ] && modprobe $SNDDEV
50- [ -n "$CAMDEV" ] && modprobe $CAMDEV
51- else
44+ if [ -z "$FOUND" ]; then
5245 auto_detect
5346 fi
5447
5548 # 3G modules
5649 for m in $EXTMOD; do
57- modprobe $m
50+ busybox modprobe $m
5851 done
5952 }