iPXE
mlx_vmac.h File Reference

Go to the source code of this file.

Data Structures

struct  mlx_vmac_query_virt_mac
struct  mlx_vmac_set_virt_mac

Functions

 FILE_LICENCE (GPL2_OR_LATER)
mlx_status mlx_vmac_query_virt_mac (IN mlx_utils *utils, OUT struct mlx_vmac_query_virt_mac *virt_mac)
mlx_status mlx_vmac_set_virt_mac (IN mlx_utils *utils, OUT struct mlx_vmac_set_virt_mac *virt_mac)

Function Documentation

◆ FILE_LICENCE()

FILE_LICENCE ( GPL2_OR_LATER )

◆ mlx_vmac_query_virt_mac()

mlx_status mlx_vmac_query_virt_mac ( IN mlx_utils * utils,
OUT struct mlx_vmac_query_virt_mac * virt_mac )

Definition at line 27 of file mlx_vmac.c.

31{
33 if (utils == NULL || virt_mac == NULL) {
35 goto bad_param;
36 }
37
39 utils,
41 virt_mac,
42 0,
43 sizeof(*virt_mac)
44 );
45 MLX_CHECK_STATUS(utils, status, icmd_err, "mlx_icmd_send_command failed");
46icmd_err:
47bad_param:
48 return status;
49}
#define NULL
NULL pointer (VOID *)
Definition Base.h:322
uint8_t status
Status.
Definition ena.h:5
#define MLX_CHECK_STATUS(id, status, label, message)
Definition mlx_bail.h:37
@ QUERY_VIRTUAL_MAC
Definition mlx_icmd.h:38
mlx_status mlx_icmd_send_command(IN mlx_utils *utils, IN mlx_uint16 opcode, IN OUT mlx_void *data, IN mlx_uint32 write_data_size, IN mlx_uint32 read_data_size)
Definition mlx_icmd.c:310
#define MLX_INVALID_PARAMETER
#define MLX_SUCCESS
int mlx_status

References IN, MLX_CHECK_STATUS, mlx_icmd_send_command(), MLX_INVALID_PARAMETER, MLX_SUCCESS, NULL, OUT, QUERY_VIRTUAL_MAC, and status.

Referenced by flexboot_nodnic_get_factory_mac().

◆ mlx_vmac_set_virt_mac()

mlx_status mlx_vmac_set_virt_mac ( IN mlx_utils * utils,
OUT struct mlx_vmac_set_virt_mac * virt_mac )

Definition at line 52 of file mlx_vmac.c.

56{
58 if (utils == NULL || virt_mac == NULL) {
60 goto bad_param;
61 }
62
64 utils,
66 virt_mac,
67 sizeof(*virt_mac),
68 0
69 );
70 MLX_CHECK_STATUS(utils, status, icmd_err, "mlx_icmd_send_command failed");
71icmd_err:
72bad_param:
73 return status;
74}
@ SET_VIRTUAL_MAC
Definition mlx_icmd.h:39

References IN, MLX_CHECK_STATUS, mlx_icmd_send_command(), MLX_INVALID_PARAMETER, MLX_SUCCESS, NULL, OUT, SET_VIRTUAL_MAC, and status.