The following warnings occurred:
Warning [2] count(): Parameter must be an array or an object that implements Countable - Line: 807 - File: showthread.php PHP 7.3.15 (Linux)
File Line Function
/showthread.php 807 errorHandler->error





Post Reply 
 
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
iPXE Block IO stub breaks grubnet
2017-12-05, 09:19
Post: #1
iPXE Block IO stub breaks grubnet
I am having the exact problem described here: https://lists.gnu.org/archive/html/help-...00082.html

However, I am using grub2netx64.efi from Solaris and it's going to be a lot harder to get Oracle to work on a fix for this iPXE particularity.

Below is a description, from the Ubuntu patch, of what causes the problem:

Subject: [PATCH] disk/efi: skip iPXE dummy block devices
iPXE adds Simple File System Protocol to loaded image handle, as side
effect it also adds Block IO protocol (according to comments, to work
around some bugs in EDK2). GRUB assumes that every device with Block IO
is disk and skips network initialization entirely. But iPXE Block IO
implementation is just a stub which always fails for every operation
so cannot be used. Attempt to detect and skip such devices.

And a comment on the nature of the fix:
We are using media ID which iPXE sets to "iPXE" and block IO size in
hope that no real device would announce 1B block ...

The fix is:
--- a/grub-core/disk/efi/efidisk.c
+++ b/grub-core/disk/efi/efidisk.c
@@ -80,6 +80,14 @@ make_devices (void)
/* This should not happen... Why? */
continue;

+ /* iPXE adds stub Block IO protocol to loaded image device handle. It is
+ completely non-functional and simply returns an error for every method.
+ So attempt to detect and skip it. Magic number is literal "iPXE" and
+ check block size as well */
+ if (bio->media && bio->media->media_id == 0x69505845U &&
+ bio->media->block_size == 1)
+ continue;
+
d = grub_malloc (sizeof (*d));
if (! d)
{


Since I have little to no hope of seeing a similar fix from Oracle any time soon, can anyone suggest a workaround I can use?

Thanks.
Darie
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
iPXE Block IO stub breaks grubnet - eterle - 2017-12-05 09:19



User(s) browsing this thread: 2 Guest(s)