(OSD3358) U-Boot, kernel, BB-DT questions

Hi,
I found this topic where you mentioned switching to 2020.04 device-tree model.

I have a custom board based upon BBB. My board has two LAN8710 ethernet PHYs wired RMII. I am using u-boot 2019.04 with your patches, kernel 4.19.106-bone49. I use BeagleBoard-DeviceTrees-4.19.x-ti to build my custom DT.dtb file. I have created a custom device tree based upon am335x. When the kernel boots it loads my custom DT.dtb.

Does the ‘old board file method’ mean that u-boot uses the u-boot-v2019.04/board/ti/am335x/board.c file?

Are device-tree method, driver model and CONFIG_DM_ETH all the same thing?

Back in August 2020, u-boot was at version v2020.04. I noticed today that latest u-boot is v2021.01.

I understand that u-boot is closely related to Linux.

If I change to v2020.04 or v2021.01…
What kernel version do I need?
What version of BB-DT builder do I need?

Will u-boot v2020.04 and/or v2020.01 use the same DT.dtb file for configuration?

I’m sorry for the excessive number of questions.

Thank you,

Correct…

Kind of, the driver model still supports some board file/functions/etc, but device tree and driver model are tied together… DM_ETH is the config to enable it for this hardware.

They are pretty separate, u-boot is needed to correctly init the ddram on the am335x, otherwise once it loads the kernel it’s done. Just use the newest that supports what you want it to do…

For u-boot, i never setup a repo for that situtation…

I’d assume the v2021.01 has a few changes, as i have noticed a lot pinmux changes on u-boot’s mailing list…

Regards,

Robert,

Your reply made me think about,
What is broken?
U-boot cannot use my Ethernet PHY(s) to connect to my network. I believe this is because my PHYs are wired RMII and do not use the same pinmux as setup in the board.c file.
What do I want u-boot to do?
The most important is, I would like u-boot to know the about the Ethernet PHY(s) on my custom board. I want to be able to download files (i.e. the kernel then the ROOTFS) from a server on my network.
I have a custom device tree with two Microchip LAN8710 PHYs setup as RMII with a working pinmux that the kernel uses. I understand that I could edit the board.c file but I don’t want to maintain separate board.c file and device tree .dts/.dtsi files. I do want to create and maintain one custom.dtb file that u-boot and the kernel can use.

Can u-boot use the same custom.dtb that was built for the kernel?
If yes, what version of u-boot supports this?
Is there a tutorial that would help guide me through how to do this?

Thank you,

For you device, if you are using the board file method, you must update the pinmux in the board.c file. If you are using the device-tree file method, you must update the pinmux there for your ethernet configuration.

It’s similar but not 100%, u-boot has a few extra node options to minimize dtb size, but much of what you change on your kernel dtb could be used for u-boot…

Regards,

1 Like