sun4v vnet devices do not implement the support of duplex and speed
instance attributes. An attempt to open such a device with
the attributes will fail:
ok select net:speed=auto,duplex=auto
Unknown key 'speed'
Unknown key 'duplex'
Manual Configuration: Host IP, boot server and filename must be specified
WARNING: /virtual-devices@100/channel-devices@200/network@0: Can't open OBP standard TFTP package
Can't open device
ok
Therefore, let's not set SUFFIX for such devices.
Signed-off-by: Stanislav Kholmanskikh <stanislav.kholmanskikh@oracle.com>
It enables net boot even when there is no bootp/dhcp server.
* grub-core/net/drivers/ieee1275/ofnet.c: Add grub_ieee1275_parse_bootpath and
call it at grub_ieee1275_net_config_real.
* grub-core/kern/ieee1275/init.c: Add bootpath to grub_ieee1275_net_config.
* include/grub/ieee1275/ieee1275.h: Likewise.
* 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.
* include/grub/net.h (grub_net_card_driver): Allow driver to modify
card. All users updated.
(grub_net_card): New members txbuf, rcvbuf, rcvbufsize and txbusy.
* grub-core/net/drivers/efi/efinet.c (send_card_buffer): Reuse buffer.
(get_card_packet): Likewise.
(grub_efinet_findcards): Init new fields.