init an hotplug und udev angepasst. modprobe hack ist damit nicht mehr
notwendig git-svn-id: svn://svn.compuextreme.de/Viitor/V962/Viitor_initrd@5370 504e572c-2e33-0410-9681-be2bf7408885
This commit is contained in:
parent
d0c2267895
commit
26ea8bbe8f
15
init
15
init
@ -104,6 +104,10 @@ done
|
||||
mount -t proc none /proc
|
||||
mount -t sysfs none /sys
|
||||
mount -n -t tmpfs -o mode=0755 udev /dev
|
||||
mknod /dev/null c 1 3
|
||||
mknod /dev/console c 5 1
|
||||
mkdir /dev/pts
|
||||
mkdir /dev/shm
|
||||
if [ -d /proc/bus/usb ]; then
|
||||
mount -t usbfs none /proc/bus/usb
|
||||
fi
|
||||
@ -112,15 +116,6 @@ if [ ! -d /var/lock/subsys ]; then
|
||||
fi
|
||||
/etc/init.d/udev start
|
||||
/etc/init.d/hotplug start
|
||||
echo "0" >/proc/sys/kernel/printk
|
||||
cd /lib/modules/*
|
||||
for i in `find kernel/drivers -name "*.ko"`; do
|
||||
MODNAME=`basename $i`
|
||||
MODNAME=`echo $MODNAME|sed -e "s/\.ko$//"`
|
||||
echo "Trying to load $MODNAME"
|
||||
modprobe -q $MODNAME 2>&1 >/dev/null
|
||||
done
|
||||
echo "7" >/proc/sys/kernel/printk
|
||||
|
||||
for i in /dev/sr*; do
|
||||
mount -o ro $i /mnt
|
||||
@ -131,6 +126,8 @@ for i in /dev/sr*; do
|
||||
umount /mnt
|
||||
done
|
||||
|
||||
pkill udevd
|
||||
|
||||
if [ "$FOUND" ]; then
|
||||
exec /sbin/switch_root /mnt /sbin/init
|
||||
else
|
||||
|
15
init.hd
15
init.hd
@ -97,9 +97,12 @@ for i in /proc /sys /mnt; do
|
||||
done
|
||||
|
||||
mount -t proc none /proc
|
||||
echo "0" >/proc/sys/kernel/printk
|
||||
mount -t sysfs none /sys
|
||||
mount -n -t tmpfs -o mode=0755 udev /dev
|
||||
mknod /dev/null c 1 3
|
||||
mknod /dev/console c 5 1
|
||||
mkdir /dev/pts
|
||||
mkdir /dev/shm
|
||||
if [ -d /proc/bus/usb ]; then
|
||||
mount -t usbfs none /proc/bus/usb
|
||||
fi
|
||||
@ -108,15 +111,6 @@ if [ ! -d /var/lock/subsys ]; then
|
||||
fi
|
||||
/etc/init.d/udev start
|
||||
/etc/init.d/hotplug start
|
||||
cd /lib/modules/*
|
||||
for i in `find kernel/drivers -name "*.ko"`; do
|
||||
MODNAME=`basename $i`
|
||||
MODNAME=`echo $MODNAME|sed -e "s/\.ko$//"`
|
||||
echo "Trying to load $MODNAME"
|
||||
modprobe -q -s $MODNAME 2>&1 >/dev/null
|
||||
done
|
||||
echo "7" >/proc/sys/kernel/printk
|
||||
|
||||
for i in `cat /proc/cmdline`; do
|
||||
DEVNAME=$DEVNAME`echo $i|awk -F "=" '{ if ($1 == "root" ) print $2 }'`
|
||||
done
|
||||
@ -131,6 +125,7 @@ for i in /sys/block/[hs]d?; do
|
||||
done
|
||||
fi
|
||||
done
|
||||
pkill udevd
|
||||
if [ ${ROOTDEV} ]; then
|
||||
mount /dev/$ROOTDEV /mnt
|
||||
exec /sbin/switch_root /mnt /sbin/init
|
||||
|
Loading…
Reference in New Issue
Block a user