Changeset a6cd72e for udev/ide.sh


Ignore:
Timestamp:
Feb 21, 2006, 9:37:37 AM (19 years ago)
Author:
Jim Gifford <clfs@…>
Branches:
clfs-1.2, clfs-2.1, clfs-3.0.0-systemd, clfs-3.0.0-sysvinit, master, systemd, sysvinit
Children:
128c984
Parents:
ce36880
Message:

r861@server (orig r859): jim | 2005-12-06 22:41:11 -0800

r994@server: jim | 2005-12-06 22:39:42 -0800
Updates from 077 OpenSuse Package


File:
1 moved

Legend:

Unmodified
Added
Removed
  • udev/ide.sh

    • Property mode changed from 100644 to 100755
    rce36880 ra6cd72e  
    22########################################################################
    33#
    4 # Description : load_ide_modules
     4# Description : Load ide
    55#
    66# Authors     : Based on Open Suse Udev Rules
     
    1212# Version     : 00.00
    1313#
    14 # Notes       : 
     14# Notes       :
    1515#
    1616########################################################################
    1717
     18# calculate device name from bus and drive number
    1819device=${DEVPATH#/devices/*/ide?/}
    1920drive=${device#?.}
    2021bus=${device%.?}
    21 name=$(printf "hd%x" $(($drive + $bus * 2 + 10)))
     22unitnum=$((96 + 1 + $drive + $bus * 2))
     23name=$(printf "hd\\$(printf '%o' $unitnum)")
    2224procfile="/proc/ide/$name/media"
    2325
    24 loop=50
     26# wait for /proc file to appear
     27loop=30
    2528while ! test -e $procfile; do
    2629    sleep 0.1;
    27     test "$loop" -gt 0 || exit 1
     30    test "$loop" -gt 0 || break
    2831    loop=$(($loop - 1))
    2932done
Note: See TracChangeset for help on using the changeset viewer.