Hello, On 16 June 2016 at 18:36, Stefan Monnier <[email protected]> wrote: >>> But this last step often fails with timeouts or bad CRC checksums or >>> other errors (the exact errors vary from time to time). I'd estimate >>> that the boot succeeds about 1/3 of the time. >> Could you post some logs on how it fails? > > Here's one example (hand-copied, so may include some typos): > > Scanning scsi 0:0... > Found U-Boot script /boot.scr > 853 bytes read in 21 ms > ## Executing script at 43100000 > scanning bus for devices... > Device 0: (0:0) Vendor: ATA Prod.: ST912082 Rev: 3.06 > Type: Hard Disk > Capacity: 114473.4 MB = 111.7 GB > Found 1 devic(s). > timeout exit! > timeout exit! > 3636648 bytes read in 20153 ms (175.8 KiB/s) > timout exit! > bad MBR sector signature 0xf55a > ** Invalid partition 1** > timout exit! > bad MBR sector signature 0x0000 > ** Invalid partition 1** >
It looks like the disk is slow to respond. Either U-boot does not wait long enough to honor the spec (which may also somewhat vary per disk ) or the disk really takes too long and Linux just covers that up with numerous retries and longer timeouts (iirc it waits up to 10x 30s for scsi device to send data). So you probably want to extend the timeout and add more retries in U-boot code if the disk works OK in Linux. Also I think it looks like U-boot never received valid data from the disk but interprets the buffer as a MBR nonetheless which is bogus. HTH Michal -- You received this message because you are subscribed to the Google Groups "linux-sunxi" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
