On Feb 5, 2016, at 9:56 AM, Cohen, Eugene eugene@hp.com wrote:
If I duplicate the call to BdsLibConnectAll() [2], then boot works as expected. On first boot, the boot order is created correctly and EFI Network pulls down a file and boots it.
I have seen components that have asynchronous initialization characteristics, meaning that they returns from the Driver Binding Start() call but keep doing processing on callbacks. If this processing will eventually result in creating new handles (USB bus enumeration comes to mind) then the asynchronous processing is effectively racing the driver connection process (others feel free to jump in and disagree with this assertion). I have no idea if this is your issue but wanted to raise it as a possibility for completeness.
Well USB is different since it supports hot-plug. The USB bus driver is doing the gBS->ConnectController() on the children as they are discovered, but the Start() should connect the current topology.
If drivers are picking and choosing what to connect that seems like a bug in the driver. The architecture is the platform will pass in a remaining device path to bus driver to give a hint on the only device that NEEDs to be connected, and it is a driver implementation choice if it just enumerates that device or the entire bus. There is not concept of the driver choosing, that is non conferment driver behavior.
In general connecting all drivers on boot is a performance bug.
How the BDS configures boot options is just implementation choice, so you can modify it to be what ever your platform needs.
Thanks,
Andrew Fish
I've been thinking about proposing an enhancement to the spec to cover this case but haven't been motivated enough yet.
Eugene
edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel