Re: waiting 10s before mounting root filesystem?

From: Bodo Eggert (7eggert_at_gmx.de)
Date: 12/31/04

  • Next message: Andi Kleen: "Re: ptrace single-stepping change breaks Wine"
    To: Jesper Juhl <juhl-lkml@dif.dk>, Marcelo Tosatti <marcelo.tosatti@cyclades.com>, linux-kernel@vger.kernel.org, Jesper Juhl <juhl-lkml@dif.dk>, Andrew Morton <akpm@osdl.org>
    Date:	Fri, 31 Dec 2004 13:33:01 +0100
    
    

    Jesper Juhl wrote:

    > I agree with you that reducing screen clutter is a good thing. How about
    > something like this that waits for 10+ seconds so even slow devices have a
    > chance to get up but also does some primitive ratelimiting on the messages
    > by only printing one every 3 seconds (but still attempting to mount every
    > 1 sec) ?

    a) Print every 4 seconds, this will replace one division by a bit-test:
    ... int retries = 32 ...
    ... if (! (retries & 0x3)) /* is a multiple of 4 */ ...

    I choose 32 because I saw SCSI controlers taking an enormous amount of time
    until detecting all devices. Maybe it's still too low for bus 7 id 15, but
    I'd wait for someone to complain.

    b) I saw no benefit from using 'short' instead of 'int' when I did a small
    test (with uudecoding on i386) some time ago, but I could make the
    resulting code be smaller and use less memory accesses by introducing some
    temporary ints to hold the chars I was operating upon. Are there contrary
    experiences that lead to using 'short' here?

    c) This patch will sleep for a second after the last try before it
    continues to panic. It's OK for me, but maybe there is a better way of
    doing this.

    @ Andrew Morton:

    The patch with a timeout is needed because the machine might be on a
    remote location and rebooted using lilo's once-only feature. An automatic
    reset after the panic will bring it back.
    -
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.kernel.org
    More majordomo info at http://vger.kernel.org/majordomo-info.html
    Please read the FAQ at http://www.tux.org/lkml/


  • Next message: Andi Kleen: "Re: ptrace single-stepping change breaks Wine"

    Relevant Pages

    • Re: [PATCH][5/?] count writeback pages in nr_scanned
      ... but even sleeping for a fixed amount of time ... of dirty pages backed by fast devices when you have slow devices ... send the line "unsubscribe linux-kernel" in ...
      (Linux-Kernel)
    • Re: ext2/3 performance regression in 2.6 vs 2.4 for small interl
      ... >> function of requests, no matter how long it takes to write a request, ... >> so it's potentially optimizing slow devices when you don't care about ... > slow devices is lower than fast devices. ... send the line "unsubscribe linux-kernel" in ...
      (Linux-Kernel)
    • Re: ext2/3 performance regression in 2.6 vs 2.4 for small interl
      ... > function of requests, no matter how long it takes to write a request, ... slow devices is lower than fast devices. ... has a terrible latency on slow devices, ... To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/ ...
      (Linux-Kernel)
    • Re: ext2/3 performance regression in 2.6 vs 2.4 for small interl
      ... >> function of requests, no matter how long it takes to write a request, ... > slow devices is lower than fast devices. ... On CDs and DVDs ... send the line "unsubscribe linux-kernel" in ...
      (Linux-Kernel)