nusb/disk: add small delay after unit start command (for thinkpad sdcard reader)
diskparts fails on thinkpad x200 sdcard reader if we dont give the unit some time to startup. the device took about 100ms to become ready so status poll loop with a long timeout would be overkill.
This commit is contained in:
parent
cc02f96ed9
commit
9f25f9504a
1 changed files with 3 additions and 1 deletions
|
@ -345,8 +345,10 @@ umsinit(void)
|
|||
if(SRready(lun) < 0 && SRready(lun) < 0 && SRready(lun) < 0)
|
||||
dprint(2, "disk: lun %d not ready\n", i);
|
||||
|
||||
if((lun->inquiry[0] & 0x1F) == 0)
|
||||
if((lun->inquiry[0] & 0x1F) == 0){
|
||||
SRstart(lun, 1);
|
||||
sleep(250);
|
||||
}
|
||||
|
||||
/*
|
||||
* we ignore the device type reported by inquiry.
|
||||
|
|
Loading…
Reference in a new issue