Gentoo Archives: gentoo-commits

From: Richard Yao <ryao@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/genkernel:ryao commit in: defaults/
Date: Mon, 03 Jun 2013 23:35:10
Message-Id: 1366874440.682d0b0d0aaf30e4236809bcf87fc674e6e88c8c.ryao@gentoo
1 commit: 682d0b0d0aaf30e4236809bcf87fc674e6e88c8c
2 Author: Fabio Erculiani <lxnay <AT> sabayon <DOT> org>
3 AuthorDate: Tue Apr 23 15:54:10 2013 +0000
4 Commit: Richard Yao <ryao <AT> gentoo <DOT> org>
5 CommitDate: Thu Apr 25 07:20:40 2013 +0000
6 URL: http://git.overlays.gentoo.org/gitweb/?p=proj/genkernel.git;a=commit;h=682d0b0d
7
8 Drop "sleep 3" from sdelay if CDROOT=1. One can use scandelay=secs if needed.
9
10 While this makes out of the box booting a bit harder on some ancient CD/DVD
11 drives, it really speeds up the common use case by not sleeping for 3 seconds.
12
13 ---
14 defaults/initrd.scripts | 10 ++--------
15 1 file changed, 2 insertions(+), 8 deletions(-)
16
17 diff --git a/defaults/initrd.scripts b/defaults/initrd.scripts
18 index e614064..abd8fad 100755
19 --- a/defaults/initrd.scripts
20 +++ b/defaults/initrd.scripts
21 @@ -991,19 +991,13 @@ startLUKS() {
22
23 sdelay() {
24 # Sleep a specific number of seconds if SDELAY is set
25 - if [ "${SDELAY}" ]
26 + if [ -n "${SDELAY}" ]
27 then
28 good_msg "Waiting ${SDELAY} seconds..."
29 sleep ${SDELAY}
30 elif [ "${CDROOT}" = '1' ]
31 then
32 - # many CD/DVD drives require extra sleep, especially when
33 - # connected via USB. Many people reported that 1 second sleep
34 - # is not enough on their notebooks, that's why sleep 3, when booting
35 - # off a livecd is a better default.
36 - sleep 3
37 - else
38 - good_msg 'Hint: Use parameter scandelay[=seconds] if you need waiting here'
39 + good_msg 'Hint: Use scandelay[=seconds] if your live medium is slowand boot fails'
40 fi
41 }