Hello,
I have a system with fully functioning USB hardware and a U-Boot image that can load the kernel and other necessary firmwares from a USB Drive and jump to the kernel. Driver configuration issues aside, this wasn't too complicated to accomplish.
That being said, I have now discovered a chicken-and-egg problem. The Linux drivers for USB are the proprietary DWC3 kernel modules, and they don't seem to want to be built into the kernel. Since they are loadable modules, they live in the filesystem. I am attempting to boot a system with a USB filesystem, but the drivers to mount a USB filesystem live in the filesystem.
I have two requests for information:
1) It seems that I need to add these files to the initrd, but I lack enough context/understanding to know exactly what that should contain. I have a list of modules that need to be loaded and I have the initrd provided by the PSDK (In this case PSDK 6.3). What's odd is that the k2-fw-initrd image provided only contains ./lib/firmware/ and a handful of IP firmwares. I do not understand how these files are loaded or used by the kernel in the early boot. I'm certain I could read the kernel source and figure that out, but if there are any experts out there who have a concise explanation or direction on where to look, I'd love to hear it.
2) Additionally, we're using Yocto/Arago as our build system. This makes the issue a little more complicated than building the initrd we need and compressing it into the correct format. The details of how to accomplish this may be better asked on a Yocto forum, but since it pertains to a TI-provided recipe I thought I'd ask for some info here. The recipe for k2-fw-initrd has some hacks and explanations that it's an unconventional recipe. I'd like to write a bbappend for this recipe that adds the USB kernel modules to the image it generates. It seems this will involve modifying the linux-ti-staging recipe as well because the generated modules are a part of the kernel recipe and need to be made available to the initrd recipe. Can anyone offer some recommendations about how to approach adding the kernel modules to the initrd?