[U-Boot] [RFC] toradex: imx6: Move g_dnl_bind_fixup() into common SPL code

Fabio Estevam festevam at gmail.com
Tue Sep 5 22:34:58 UTC 2017


On Tue, Sep 5, 2017 at 6:18 PM, Stefan Agner <stefan.agner at toradex.com> wrote:

> Note that 0xfff was a rather randomly picked offset, not sure if we want that in common code.

Yes, I noticed that. I am inclined to go with 0xfff and then later we
can even introduce a CONFIG option for the offset if needed.

>> -#ifdef CONFIG_USB_GADGET_DOWNLOAD
>> -int g_dnl_bind_fixup(struct usb_device_descriptor *dev, const char *name)
>> -{
>> -     unsigned short usb_pid;
>> -
>> -     usb_pid = TORADEX_USB_PRODUCT_NUM_OFFSET + tdx_hw_tag.prodid;
>> -     put_unaligned(usb_pid, &dev->idProduct);
>> -
>> -     return 0;
>> -}
>> -#endif
>
> Nack to this part, this is U-Boot only (not used in SPL) and reads the product ID from eMMC to generate the officially assigned Toradex USB Product ID.

Ok, will prepare another version that keeps the non-SPL code then.

Thanks


More information about the U-Boot mailing list