• A
    libata: correct handling of SRST reset sequences · 681c80b5
    Alan Cox 提交于
    Correct handling of SRST reset sequences.  After an SRST it is undefined
    whether the drive has gone back to PIO0.  In order to talk safely we should
    talk slowly and carefully until we know.
    
    Thus when we do the reset if the controller has a pio setup method we call it
    to flip back to PIO 0 and a known state.  After the reset completes the
    identify will then be done at the safe speed and the drive/controller will
    pick suitable faster modes and reconfigure the controller to these timings.
    
    As a side effect it means we force the controller to PIO 0 as we bring it up
    which fixes funnies on a few systems where the BIOS firmware leaves us in an
    interesting choice of modes, or embedded boxes with no firmware which come up
    in random states.
    
    For smart controllers there is nothing to do - they know about this
    internally.
    Signed-off-by: NAlan Cox <alan@redhat.com>
    Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
    Signed-off-by: NJeff Garzik <jeff@garzik.org>
    681c80b5
libata-core.c 183.4 KB