Lines 92-97
Link Here
|
92 |
fi |
92 |
fi |
93 |
fi |
93 |
fi |
94 |
} |
94 |
} |
|
|
95 |
|
96 |
findusbmount() { |
97 |
if [ "$#" -gt "0" ] |
98 |
then |
99 |
for x in $* |
100 |
do |
101 |
# Check for a block device to mount |
102 |
if [ -b "${x}" ] |
103 |
then |
104 |
good_msg "Attempting to mount USB Device:- ${x}" |
105 |
if [ "${CDROOT}" -eq '1' ] |
106 |
then |
107 |
mount ${x} ${NEW_ROOT}/mnt/cdrom > /dev/null 2>&1 |
108 |
if [ "$?" = '0' ] |
109 |
then |
110 |
if [ -e ${NEW_ROOT}/mnt/cdrom/liveusb ] |
111 |
then |
112 |
REAL_ROOT="${x}" |
113 |
break |
114 |
else |
115 |
umount ${NEW_ROOT}/mnt/cdrom |
116 |
fi |
117 |
fi |
118 |
else |
119 |
mount ${x} ${NEW_ROOT} > /dev/null 2>&1 |
120 |
if [ "$?" = '0' ] |
121 |
then |
122 |
if [ -e ${NEW_ROOT}/liveusb ] |
123 |
then |
124 |
REAL_ROOT="${x}" |
125 |
break |
126 |
else |
127 |
umount ${NEW_ROOT} |
128 |
fi |
129 |
fi |
130 |
fi |
131 |
fi |
132 |
done |
133 |
if [ "${REAL_ROOT}" != '' ] |
134 |
then |
135 |
good_msg "USB medium found on ${x}" |
136 |
fi |
137 |
fi |
138 |
} |
139 |
|
95 |
cache_cd_contents() { |
140 |
cache_cd_contents() { |
96 |
# Check loop file exists and cache to ramdisk if DO_cache is enabled |
141 |
# Check loop file exists and cache to ramdisk if DO_cache is enabled |
97 |
if [ "${LOOPTYPE}" != 'noloop' ] |
142 |
if [ "${LOOPTYPE}" != 'noloop' ] |
Lines 292-308
Link Here
|
292 |
} |
337 |
} |
293 |
|
338 |
|
294 |
bootstrapCD() { |
339 |
bootstrapCD() { |
295 |
# Locate the cdrom device with our media on it. |
340 |
local DEVICES='' |
296 |
[ -n "${CDROOT_DEV}" ] && DEVICES="$DEVICES ${CDROOT_DEV}" # Device specified on the command line |
341 |
|
297 |
DEVICES="$DEVICES /dev/cdroms/*" # CDROM DEVICES |
342 |
if [ "${USBROOT}" != '0' ] |
298 |
DEVICES="$DEVICES /dev/ide/cd/*" # CDROM DEVICES |
343 |
then |
299 |
DEVICES="$DEVICES /dev/sr*" # UML DEVICES |
344 |
# Locate the usb device with our media on it. |
300 |
DEVICES="$DEVICES /dev/sd*" # USB Keychain |
345 |
[ -n "${USBROOT_DEV}" ] && DEVICES="$DEVICES ${USBROOT_DEV}" # Device specified on the command line |
301 |
DEVICES="$DEVICES /dev/hd*" # IDE devices |
346 |
DEVICES="$DEVICES /dev/sd*" # USB Keychain |
302 |
DEVICES="$DEVICES /dev/ubd* /dev/ubd/*" # UML DEVICES |
347 |
|
303 |
DEVICES="$DEVICES /dev/iseries/vcd*" # iSeries Devices |
348 |
findusbmount $DEVICES |
|
|
349 |
else |
350 |
# Locate the cdrom device with our media on it. |
351 |
[ -n "${CDROOT_DEV}" ] && DEVICES="$DEVICES ${CDROOT_DEV}" # Device specified on the command line |
352 |
DEVICES="$DEVICES /dev/cdroms/*" # CDROM DEVICES |
353 |
DEVICES="$DEVICES /dev/ide/cd/*" # CDROM DEVICES |
354 |
DEVICES="$DEVICES /dev/sr*" # UML DEVICES |
355 |
DEVICES="$DEVICES /dev/sd*" # USB Keychain |
356 |
DEVICES="$DEVICES /dev/hd*" # IDE devices |
357 |
DEVICES="$DEVICES /dev/ubd* /dev/ubd/*" # UML DEVICES |
358 |
DEVICES="$DEVICES /dev/iseries/vcd*" # iSeries Devices |
304 |
|
359 |
|
305 |
findcdmount $DEVICES |
360 |
findcdmount $DEVICES |
|
|
361 |
fi |
306 |
} |
362 |
} |
307 |
|
363 |
|
308 |
cmdline_hwopts() { |
364 |
cmdline_hwopts() { |