mirror of
https://git.savannah.gnu.org/git/grub.git
synced 2026-10-25 08:39:28 +00:00
* include/grub/net.h (grub_net_card): New member txbufsize.
* include/grub/ieee1275/ieee1275.h (grub_ieee1275_flag): New enum values GRUB_IEEE1275_FLAG_NO_OFNET_SUFFIX and GRUB_IEEE1275_FLAG_VIRT_TO_REAL_BROKEN. * grub-core/net/drivers/efi/efinet.c (grub_efinet_findcards): Use txbufsize. * grub-core/kern/ieee1275/cmain.c (grub_ieee1275_find_options): Use compatible property to check for macs. Set GRUB_IEEE1275_FLAG_NO_OFNET_SUFFIX and GRUB_IEEE1275_FLAG_VIRT_TO_REAL_BROKEN on macs. * grub-core/net/drivers/ieee1275/ofnet.c (card_open): Don't add suffix if GRUB_IEEE1275_FLAG_NO_OFNET_SUFFIX is set. (send_card_buffer): Use txbuf. (grub_ofnet_findcards): Allocate txbuf. Simplify code flow and move nested function out of the parent while on it.
This commit is contained in:
1 parent
cc35fe8f31
commit
0494408e7e
6 files changed
+164
-81
No files matched your search
@@ -181,7 +181,8 @@ grub_efinet_findcards (void)
|
||||
}
|
||||
|
||||
card->mtu = net->mode->max_packet_size;
|
||||
card->txbuf = grub_zalloc (ALIGN_UP (card->mtu, 64) + 256);
|
||||
card->txbufsize = ALIGN_UP (card->mtu, 64) + 256;
|
||||
card->txbuf = grub_zalloc (card->txbufsize);
|
||||
if (!card->txbuf)
|
||||
{
|
||||
grub_print_error ();
|
||||
|
||||
Reference in new issue
Block a user