diff options
Diffstat (limited to 'meta/recipes-core/initrdscripts/files/init-install-efi.sh')
-rw-r--r-- | meta/recipes-core/initrdscripts/files/init-install-efi.sh | 20 |
1 files changed, 16 insertions, 4 deletions
diff --git a/meta/recipes-core/initrdscripts/files/init-install-efi.sh b/meta/recipes-core/initrdscripts/files/init-install-efi.sh index 14939acd69..f339b30ebe 100644 --- a/meta/recipes-core/initrdscripts/files/init-install-efi.sh +++ b/meta/recipes-core/initrdscripts/files/init-install-efi.sh | |||
@@ -18,7 +18,14 @@ swap_ratio=5 | |||
18 | hdnamelist="" | 18 | hdnamelist="" |
19 | live_dev_name=`cat /proc/mounts | grep ${1%/} | awk '{print $1}'` | 19 | live_dev_name=`cat /proc/mounts | grep ${1%/} | awk '{print $1}'` |
20 | live_dev_name=${live_dev_name#\/dev/} | 20 | live_dev_name=${live_dev_name#\/dev/} |
21 | live_dev_name=${live_dev_name%%[0-9]*} | 21 | # Only strip the digit identifier if the device is not an mmc |
22 | case $live_dev_name in | ||
23 | mmcblk*) | ||
24 | ;; | ||
25 | *) | ||
26 | live_dev_name=${live_dev_name%%[0-9]*} | ||
27 | ;; | ||
28 | esac | ||
22 | 29 | ||
23 | echo "Searching for hard drives ..." | 30 | echo "Searching for hard drives ..." |
24 | 31 | ||
@@ -36,9 +43,14 @@ for device in `ls /sys/block/`; do | |||
36 | *) | 43 | *) |
37 | # skip the device LiveOS is on | 44 | # skip the device LiveOS is on |
38 | # Add valid hard drive name to the list | 45 | # Add valid hard drive name to the list |
39 | if [ $device != $live_dev_name -a -e /dev/$device ]; then | 46 | case $device in |
40 | hdnamelist="$hdnamelist $device" | 47 | $live_dev_name*) |
41 | fi | 48 | # skip the device we are running from |
49 | ;; | ||
50 | *) | ||
51 | hdnamelist="$hdnamelist $device" | ||
52 | ;; | ||
53 | esac | ||
42 | ;; | 54 | ;; |
43 | esac | 55 | esac |
44 | done | 56 | done |