iPXE
|
Ethernet over Infiniband. More...
#include <stdint.h>
#include <byteswap.h>
#include <ipxe/netdevice.h>
#include <ipxe/infiniband.h>
#include <ipxe/ib_mcast.h>
Go to the source code of this file.
Data Structures | |
struct | eoib_header |
An EoIB header. More... | |
struct | eoib_device |
An EoIB device. More... | |
Macros | |
#define | EOIB_MAGIC 0x8919 |
EoIB magic signature. More... | |
Functions | |
FILE_LICENCE (GPL2_OR_LATER_OR_UBDL) | |
static int | eoib_has_gateway (struct eoib_device *eoib) |
Check if EoIB device uses a gateway. More... | |
static void | eoib_force_group_creation (struct eoib_device *eoib) |
Force creation of multicast group. More... | |
int | eoib_create (struct ib_device *ibdev, const uint8_t *hw_addr, struct ib_address_vector *broadcast, const char *name) |
Create EoIB device. More... | |
struct eoib_device * | eoib_find (struct ib_device *ibdev, const uint8_t *hw_addr) |
Find EoIB device. More... | |
void | eoib_destroy (struct eoib_device *eoib) |
Remove EoIB device. More... | |
void | eoib_set_gateway (struct eoib_device *eoib, struct ib_address_vector *av) |
Set EoIB gateway. More... | |
Ethernet over Infiniband.
Definition in file eoib.h.
FILE_LICENCE | ( | GPL2_OR_LATER_OR_UBDL | ) |
|
inlinestatic |
Check if EoIB device uses a gateway.
eoib | EoIB device |
has_gw | EoIB device uses a gateway |
Definition at line 71 of file eoib.h.
References eoib_device::duplicate, and NULL.
Referenced by eoib_rx_av(), and eoib_transmit().
|
inlinestatic |
Force creation of multicast group.
eoib | EoIB device |
Definition at line 81 of file eoib.h.
References IB_SA_MCMEMBER_REC_FLOW_LABEL, IB_SA_MCMEMBER_REC_PKEY, IB_SA_MCMEMBER_REC_QKEY, IB_SA_MCMEMBER_REC_SL, IB_SA_MCMEMBER_REC_TRAFFIC_CLASS, and eoib_device::mask.
Referenced by xsmp_rx_xve_modify().
int eoib_create | ( | struct ib_device * | ibdev, |
const uint8_t * | hw_addr, | ||
struct ib_address_vector * | broadcast, | ||
const char * | name | ||
) |
Create EoIB device.
ibdev | Infiniband device |
hw_addr | Ethernet MAC |
broadcast | Broadcast address vector |
name | Interface name (or NULL to use default) |
rc | Return status code |
Definition at line 619 of file eoib.c.
References alloc_etherdev(), eoib_device::broadcast, DBGC, net_device::dev, ib_device::dev, ENOMEM, eoib_operations, ETH_ALEN, eth_ntoa(), ib_address_vector::gid, net_device::hw_addr, IB_GID_ARGS, IB_GID_FMT, eoib_device::ibdev, ibdev_get(), ibdev_put(), INIT_LIST_HEAD, eoib_device::list, list_add_tail, list_del, memcpy(), eoib_device::name, net_device::name, ib_device::name, name, eoib_device::netdev, netdev, netdev_init(), netdev_nullify(), netdev_put(), eoib_device::peers, net_device::priv, rc, register_netdev(), snprintf(), and unregister_netdev().
Referenced by xve_create().
struct eoib_device* eoib_find | ( | struct ib_device * | ibdev, |
const uint8_t * | hw_addr | ||
) |
Find EoIB device.
ibdev | Infiniband device |
hw_addr | Original Ethernet MAC |
eoib | EoIB device |
Definition at line 677 of file eoib.c.
References ETH_ALEN, net_device::hw_addr, eoib_device::ibdev, eoib_device::list, list_for_each_entry, memcmp(), eoib_device::netdev, and NULL.
Referenced by xsigo_net_notify(), xsmp_rx_xve_modify(), and xve_destroy().
void eoib_destroy | ( | struct eoib_device * | eoib | ) |
Remove EoIB device.
eoib | EoIB device |
Definition at line 695 of file eoib.c.
References DBGC, eoib_device::ibdev, ibdev_put(), eoib_device::list, list_del, eoib_device::name, eoib_device::netdev, netdev, netdev_nullify(), netdev_put(), and unregister_netdev().
Referenced by eoib_remove(), and xve_destroy().
void eoib_set_gateway | ( | struct eoib_device * | eoib, |
struct ib_address_vector * | av | ||
) |
Set EoIB gateway.
eoib | EoIB device |
av | Address vector, or NULL to clear gateway |
Definition at line 881 of file eoib.c.
References DBGC, eoib_device::duplicate, eoib_duplicate(), eoib_device::gateway, ib_address_vector::gid, IB_GID_ARGS, IB_GID_FMT, memcpy(), eoib_device::name, and NULL.
Referenced by xve_update_tca().