-
Notifications
You must be signed in to change notification settings - Fork 205
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
MSD Boot (sometimes) stuck at Read start4.elf bytes #227
Comments
Please can you try connecting via a powered USB hub to see if this improves things. UART or NETCONSOLE logs would be needed if this doesn't resolve the problem Feel free to discuss USB interoperability issues on the Raspberry General discussion forum |
Connecting the disk via powered USB does not boot RPi at all (red led on, green led off). Setting up UART and catching the moment where it acutally freezes took some time - but here it is :)
|
Thanks, that's great. If you are comfortable adding updating the bootloader EEPROM config then temporarily adding XHCI_DEBUG_FLAGS=0xf would be useful (0x3f is also useful but extremely verbose. I've found that USB hubs in monitors are often good, but we don't have an official list of good/bad USB hubs because it's not possible to keep it up to date. |
Here's log where it gets stuck, this time with
Thanks for the tip with monitor USB hub, I will try that tomorrow! |
Apologies, it should have been XHCI_DEBUG not XHCI_DEBUG_FLAGS The behaviour did look different on that run, it didn't seem to find a USB device at all instead of finding one and stopping at start4.elf, presumably getting stuck looking for fixup4.dat |
Aah I didn't notice the wrong flag name - it was late in the night :)
Here are the complete logs, where it gets stuck: uartLog_dbg0xf_failed.txt |
That's interesting, do you have any other USB devices connected? |
I have a keyboard and a mouse connected to both USB2 ports, but the SSD disk is the only USB3 device... |
ok, it looks as though in the failure case a response is not received for the first read of fixup4.dat. The same request is sent as in the success case, but nothing comes back. There might be something that can be done to improve the error handling/timeout in that area. I'll update the bug if we have a test binary available, might be a few days though as this code is quite complex. MSD [02:00] 3.32 000000:03 READ lun 0 addr: 16290 count: 4 |
Ok, I am glad to hear that the logs are showing something. I didn't undestand what you meant by "...if we have a test binary available..." - should I send you my disk image? Let me know if there is anything I can help with and thanks for looking into it! |
I think Tim meant "if/when I've produced a test binary (presumably a new EEPROM image), I'll update this bug to let you know". |
Please could you try with the pieeprom-2020-10-28 beta image? |
Thanks for the update! I tried running However connecting the disk via powered usb hub (on the monitor) works everytime. Here's the log for a successful boot via powered usb hub: uartLog2_success.txt Also, I tested another USB enclosure which is powered by the Realtek chipset (the best option I could find; see last paragraph) and it works flawlessly. Apparently the JMicron chipset has some problems (some versions at least): https://www.legitreviews.com/jmicron-jms583-controller-version-matters-for-portable-usb-drives_219422 So, Realtek RTL9210 works out of the box. The JMicron JMS583 not really. Problem is that the latter is very common, afaik. |
Thanks for the report. The logs suggest a power-related issue if going via a powered hub resolves the problem. Although, that can also change delay times for USB enumeration. The JMS583 issues happen later on when Linux select UASP because the JMicron Firmware appears to have some bugs with UAS. It's unlikely that anything will change there without an updated firmware for JMicron or possibly a JMS specific quirk in the Kernel driver (unlikely) |
@jurc192 Does https://www.raspberrypi.org/forums/viewtopic.php?t=245931 help with that? |
The latest bootloader beta release (2021-12-01) will now timeout MSD/SCSI command and restart the USB boot modes. There's also some improvements which helped compatibility with JMicron chipsets. |
@timg236 unfortunately I am no longer working on that project and I don't have access to the equipment (lab) anymore, sorry. Thanks for your great work! :) |
Ok, thanks for replying. I'm going to close the bug for now because I was able to simulate this by unplugging the USB at random points, re-connecting it then re-inserting it to show that boot did not get stuck forever. |
Describe the bug
I am booting the RPi from the USB3/SSD and it sometimes gets stuck at the boot screen at
Read start4.elf bytes 2278336 hnd 0x00011128e hash '78e6729ebb0d2e84
.RPi: 4B
SSD: Samsung 970 EVO, 500 GB
USB-SSD enclosure: ICY box IB-1817M-C31 (JMicron USB chip)
To Reproduce
Steps to reproduce the behavior:
Sometimes it works, sometimes it gets stuck at reading start4.elf. The LED on the SSD disk is blinking, but nothing happens.
Screenshots
USB boot:
When booting from SD, my SSD always gets detected, using
uas
driver,5000M
speedAdditional context
I noticed I had similar problems to #183 , since it would sometimes also get stuck at
LUN timeout
...init port 3 speed 2
etc.Using advice from the related issue, I increased the LUN timeout to 5 seconds and it seems to help. Now it only gets stuck on read start4.elf sometimes.
P.S. I want to ask the same subquestion which remained unaswered in #183 -> is there a forum/place to discuss SSD-USB enclosure issues, which ones work well, which are bugy, which can be upgraded etc.?
The text was updated successfully, but these errors were encountered: