From 65391c38c52dcbc0fab11340fd59ed83089d5cd5 Mon Sep 17 00:00:00 2001 From: maximilian attems Date: Wed, 8 Mar 2006 17:36:52 +0100 Subject: add the 0.53[bc] changesets: where takeover=0 and no '-' in script names --- scripts/local-top/udev-helper | 95 ------------------------------------------- scripts/local-top/udev_helper | 95 +++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 95 insertions(+), 95 deletions(-) delete mode 100755 scripts/local-top/udev-helper create mode 100755 scripts/local-top/udev_helper (limited to 'scripts') diff --git a/scripts/local-top/udev-helper b/scripts/local-top/udev-helper deleted file mode 100755 index 8ae47d2..0000000 --- a/scripts/local-top/udev-helper +++ /dev/null @@ -1,95 +0,0 @@ -#!/bin/sh - -PREREQ="udev" - -prereqs() -{ - echo "$PREREQ" -} - -case $1 in -# get pre-requisites -prereqs) - prereqs - exit 0 - ;; -esac - -# Our job now is to make the block device for the root filesystem available. -# This is actually a bit trickier than it first appears because we first need -# to figure out which driver needs it, and to do that, we need to know what -# type of bus it's on. Fortunately we have all that information, this still -# feels like an ungodly hack though. -case "${ROOT}" in -/dev/root) - # An interesting case, this root device was specified as a - # major/minor pair. Fortunately we have that information - case "${major}" in - 3|22|33|34|56|57|88|89|90|91) - # traditional ide - root_type=ide - ;; - 80|81|82|83|84|85|86|87) - # ide on i2o - root_type=ide - ;; - 8|11|65|66|67|68|69|70|71|128|129|130|131|132|133|134|135) - # scsi - root_type=scsi - ;; - esac - ;; -/dev/hd*) - # Ahh, plain-old traditional ide - root_type=ide - ;; -/dev/sd*) - # SCSI, or an IDE controller dressed up in drag - root_type=scsi - ;; -/dev/disk/*) - # Specified by label; sadly there's no way to tell what bus - # this is on, so we'll just declare that we only support it - # for SCSI and removable devices - root_type=scsi - ;; -esac - -case "${root_type}" in -ide) - # If we're booting from IDE, it might not be a PCI controller, - # but might be an old fashioned ISA controller; in which case - # we need to load ide-generic. - if [ ! -e "${ROOT}" -o "${ROOT}" = "/dev/root" ]; then - /sbin/modprobe -Qb ide-generic - fi - ;; - -scsi) - # If we're booting from SCSI we should have done all we need, - # now it's just a matter of waiting for the devices to appear - # which could take a while... - [ -e "${ROOT}" ] || log_begin_msg "Waiting for root file system" - - if type usplash_write >/dev/null 2>&1; then - usplash_write "TIMEOUT 30" || true - fi - - slumber=300 - while [ ${slumber} -gt 0 -a ! -e "${ROOT}" ]; do - /bin/sleep 0.1 - slumber=$(( ${slumber} - 1 )) - done - - if type usplash_write >/dev/null 2>&1; then - usplash_write "TIMEOUT 15" || true - fi - - if [ ${slumber} -gt 0 ]; then - log_end_msg 0 - else - log_end_msg 1 || true - fi - ;; -esac -;; diff --git a/scripts/local-top/udev_helper b/scripts/local-top/udev_helper new file mode 100755 index 0000000..8ae47d2 --- /dev/null +++ b/scripts/local-top/udev_helper @@ -0,0 +1,95 @@ +#!/bin/sh + +PREREQ="udev" + +prereqs() +{ + echo "$PREREQ" +} + +case $1 in +# get pre-requisites +prereqs) + prereqs + exit 0 + ;; +esac + +# Our job now is to make the block device for the root filesystem available. +# This is actually a bit trickier than it first appears because we first need +# to figure out which driver needs it, and to do that, we need to know what +# type of bus it's on. Fortunately we have all that information, this still +# feels like an ungodly hack though. +case "${ROOT}" in +/dev/root) + # An interesting case, this root device was specified as a + # major/minor pair. Fortunately we have that information + case "${major}" in + 3|22|33|34|56|57|88|89|90|91) + # traditional ide + root_type=ide + ;; + 80|81|82|83|84|85|86|87) + # ide on i2o + root_type=ide + ;; + 8|11|65|66|67|68|69|70|71|128|129|130|131|132|133|134|135) + # scsi + root_type=scsi + ;; + esac + ;; +/dev/hd*) + # Ahh, plain-old traditional ide + root_type=ide + ;; +/dev/sd*) + # SCSI, or an IDE controller dressed up in drag + root_type=scsi + ;; +/dev/disk/*) + # Specified by label; sadly there's no way to tell what bus + # this is on, so we'll just declare that we only support it + # for SCSI and removable devices + root_type=scsi + ;; +esac + +case "${root_type}" in +ide) + # If we're booting from IDE, it might not be a PCI controller, + # but might be an old fashioned ISA controller; in which case + # we need to load ide-generic. + if [ ! -e "${ROOT}" -o "${ROOT}" = "/dev/root" ]; then + /sbin/modprobe -Qb ide-generic + fi + ;; + +scsi) + # If we're booting from SCSI we should have done all we need, + # now it's just a matter of waiting for the devices to appear + # which could take a while... + [ -e "${ROOT}" ] || log_begin_msg "Waiting for root file system" + + if type usplash_write >/dev/null 2>&1; then + usplash_write "TIMEOUT 30" || true + fi + + slumber=300 + while [ ${slumber} -gt 0 -a ! -e "${ROOT}" ]; do + /bin/sleep 0.1 + slumber=$(( ${slumber} - 1 )) + done + + if type usplash_write >/dev/null 2>&1; then + usplash_write "TIMEOUT 15" || true + fi + + if [ ${slumber} -gt 0 ]; then + log_end_msg 0 + else + log_end_msg 1 || true + fi + ;; +esac +;; -- cgit v1.2.3