Page MenuHomeFreeBSD

loader.efi try to fallback on first device
ClosedPublic

Authored by manu on Jun 9 2016, 12:24 AM.
Tags
None
Referenced Files
Unknown Object (File)
Fri, Dec 20, 5:55 PM
Unknown Object (File)
Thu, Dec 12, 7:13 AM
Unknown Object (File)
Thu, Dec 12, 12:54 AM
Unknown Object (File)
Wed, Dec 4, 10:03 AM
Unknown Object (File)
Wed, Dec 4, 10:03 AM
Unknown Object (File)
Wed, Dec 4, 10:03 AM
Unknown Object (File)
Wed, Dec 4, 10:03 AM
Unknown Object (File)
Wed, Dec 4, 9:41 AM

Details

Summary

Try to fallback on the first device if we can't find the device from which the image is loaded.

Test Plan

Tested on beaglebone black with u-boot efi implementation.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

manu retitled this revision from to loader.efi try to fallback on first device.
manu updated this object.
manu edited the test plan for this revision. (Show Details)
manu set the repository for this revision to rS FreeBSD src repository - subversion.
manu added a project: ARM.
This revision is now accepted and ready to land.Jun 14 2016, 1:19 AM

I'd like to know why finding the current device would ever fail?

In D6780#143556, @smh wrote:

I'd like to know why finding the current device would ever fail?

I see at least two valid reason :

  1. In case of a bad/incomplete EFI implementation (like U-Boot currently)
  2. In embedded world you could have uboot + loader.efi in a SPI flash for example and this device would not be exposed as an EFI disk.

I would rather put this logic in find_currdev() itself.

Should we go with @jhb's suggestion then?

imp edited edge metadata.

I'm good either way, though jhb's method is cleaner.

Totally forgot about this review, I'll update it this weekend with @jhb suggestion.

manu edited edge metadata.

Update with @jhb suggestion.

This revision now requires review to proceed.Oct 27 2016, 5:05 PM
jhb edited edge metadata.

Thanks

This revision is now accepted and ready to land.Oct 27 2016, 9:23 PM
This revision was automatically updated to reflect the committed changes.