Reputation: 11
Is it possible to have only one device tree which supports two different Phy's from different vendors for one network interface (eth0 etc..)? Can Uboot/Linux then automatically detect which Phy is on the board? I think it is to easy if I simple expand the compatiple list for the Phy ...
Does anyone have an example of such a DeviceTree?
Thanks Boris
Upvotes: 1
Views: 1023
Reputation: 2483
The U-Boot drivers following the driver model (https://u-boot.readthedocs.io/en/latest/develop/driver-model/index.html) have a probe function that checks if the device in the device tree is really usable. So if you have two phy devices defined in the device tree only the one that is really available should be successfully probed.
Upvotes: 1