
Hi Tim,
On 07.04.20 19:06, Tim Harvey wrote:
On Mon, Apr 6, 2020 at 2:43 AM Schrempf Frieder frieder.schrempf@kontron.de wrote:
Hi Tim,
On 01.04.20 19:55, Tim Harvey wrote:
Peng,
It looks like IMX8MM USB support hasn't made it upstream yet. Is this something your working on?
I'm interested in booting an IMX8MM via SDP.
If I remember correctly, the main issue is that the ci_udc driver is missing DM support. See here: [1].
I have pulled some patches/hacks into our tree to make SDP work, at least without DM [2].
If someone could come up with a proper solution for upstream that would be great and I would be happy to review/test.
[1] https://eur04.safelinks.protection.outlook.com/?url=http%3A%2F%2Fu-boot.1091... [2] https://eur04.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgit.kontro...
Frieder,
Thanks - this was very helpful! After applying the patches adding IMX8MM USB I can boot the EVK SPL via SDP and get it to transition over to providing a gadget at 0525:c4a4 but when I try to load u-boot.img to that it fails with a header not found error:
sudo ../imx_usb_loader/imx_usb u-boot.imx; sleep 2; sudo ../imx_usb_loader/imx_usb u-boot.img config file <../imx_usb_loader//imx_usb.conf> ... vid=0x1fc9 pid=0x0134 file_name=mx8mm_usb_work.conf ... config file <../imx_usb_loader//mx8mm_usb_work.conf> parse ../imx_usb_loader//mx8mm_usb_work.conf Trying to open device vid=0x1fc9 pid=0x0134 Interface 0 claimed HAB security state: development mode (0x56787856) == work item filename u-boot.imx load_size 0 bytes load_addr 0x00000000 dcd 1 clear_dcd 0 plug 1 jump_mode 3 jump_addr 0x00000000 == end work item No DCD table
loading binary file(u-boot.imx) to 007e0fc0, skip=0, fsize=37600 type=aa
<<<226816, 226816 bytes>>> succeeded (security 0x56787856, status 0x88888888) jumping to 0x007e0fc0 config file <../imx_usb_loader//imx_usb.conf> ... config file <../imx_usb_loader//mx8mm_usb_sdp_spl.conf> parse ../imx_usb_loader//mx8mm_usb_sdp_spl.conf Trying to open device vid=0x0525 pid=0xc4a4 Interface 0 claimed HAB security state: development mode (0x56787856) == work item filename u-boot.img load_size 0 bytes load_addr 0x00000000 dcd 1 clear_dcd 0 plug 1 jump_mode 3 jump_addr 0x00000000 == end work item header not found 8400:91000694, 4000 do_download failed, err=-22 HAB security state: development mode (0x56787856)
Note I had to add a line to imx_usb.conf to map 0525:c4a4 to mx8mm_usb_sdp_spl.conf: diff --git a/imx_usb.conf b/imx_usb.conf index c7c00f6..4d89230 100644 --- a/imx_usb.conf +++ b/imx_usb.conf @@ -17,6 +17,7 @@ 0x066f:0x37ff, linux_gadget.conf 0x1b67:0x4fff, mx6_usb_sdp_spl.conf 0x0525:0xb4a4, mx6_usb_sdp_spl.conf +0x0525:0xc4a4, mx8mm_usb_sdp_spl.conf 0x1fc9:0x012b, mx8mq_usb_work.conf 0x1fc9:0x0134, mx8mm_usb_work.conf 0x1fc9:0x013e, mx8mn_usb_work.conf
Do you know what's missing from u-boot.img?
In my case I'm loading a FIT image, so things are a bit different. Where are you loading the image to?
I have the following line in mx8mm_usb_sdp_spl.conf to load my FIT image to DDR and jump to it:
/path/to/image/u-boot.itb:load 0x40200000, jump_direct 0x40200000
Best Regards, Frieder