FreeBSD kernel BXE device code
ecore_vlan_mac_obj Struct Reference

#include <ecore_sp.h>

Collaboration diagram for ecore_vlan_mac_obj:

Data Fields

struct ecore_raw_obj raw
 
ecore_list_t head
 
uint8_t head_reader
 
bool head_exe_request
 
unsigned long saved_ramrod_flags
 
struct ecore_exe_queue_obj exe_queue
 
struct ecore_credit_pool_objmacs_pool
 
struct ecore_credit_pool_objvlans_pool
 
int ramrod_cmd
 
int(* get_n_elements )(struct bxe_softc *sc, struct ecore_vlan_mac_obj *o, int n, uint8_t *base, uint8_t stride, uint8_t size)
 
int(* check_add )(struct bxe_softc *sc, struct ecore_vlan_mac_obj *o, union ecore_classification_ramrod_data *data)
 
struct ecore_vlan_mac_registry_elem *(* check_del )(struct bxe_softc *sc, struct ecore_vlan_mac_obj *o, union ecore_classification_ramrod_data *data)
 
bool(* check_move )(struct bxe_softc *sc, struct ecore_vlan_mac_obj *src_o, struct ecore_vlan_mac_obj *dst_o, union ecore_classification_ramrod_data *data)
 
bool(* get_credit )(struct ecore_vlan_mac_obj *o)
 
bool(* put_credit )(struct ecore_vlan_mac_obj *o)
 
bool(* get_cam_offset )(struct ecore_vlan_mac_obj *o, int *offset)
 
bool(* put_cam_offset )(struct ecore_vlan_mac_obj *o, int offset)
 
void(* set_one_rule )(struct bxe_softc *sc, struct ecore_vlan_mac_obj *o, struct ecore_exeq_elem *elem, int rule_idx, int cam_offset)
 
int(* delete_all )(struct bxe_softc *sc, struct ecore_vlan_mac_obj *o, unsigned long *vlan_mac_flags, unsigned long *ramrod_flags)
 
int(* restore )(struct bxe_softc *sc, struct ecore_vlan_mac_ramrod_params *p, struct ecore_vlan_mac_registry_elem **ppos)
 
int(* complete )(struct bxe_softc *sc, struct ecore_vlan_mac_obj *o, union event_ring_elem *cqe, unsigned long *ramrod_flags)
 
int(* wait )(struct bxe_softc *sc, struct ecore_vlan_mac_obj *o)
 

Detailed Description

Definition at line 750 of file ecore_sp.h.

Field Documentation

◆ check_add

int(* ecore_vlan_mac_obj::check_add) (struct bxe_softc *sc, struct ecore_vlan_mac_obj *o, union ecore_classification_ramrod_data *data)

Checks if ADD-ramrod with the given params may be performed.

Returns
zero if the element may be added

Definition at line 797 of file ecore_sp.h.

Referenced by ecore_check_move(), ecore_init_mac_obj(), ecore_init_vlan_mac_obj(), ecore_init_vlan_obj(), ecore_init_vxlan_fltr_obj(), and ecore_validate_vlan_mac_add().

◆ check_del

struct ecore_vlan_mac_registry_elem *(* ecore_vlan_mac_obj::check_del) (struct bxe_softc *sc, struct ecore_vlan_mac_obj *o, union ecore_classification_ramrod_data *data)

Checks if DEL-ramrod with the given params may be performed.

Returns
TRUE if the element may be deleted

Definition at line 797 of file ecore_sp.h.

Referenced by ecore_check_move(), ecore_execute_vlan_mac(), ecore_init_mac_obj(), ecore_init_vlan_mac_obj(), ecore_init_vlan_obj(), ecore_init_vxlan_fltr_obj(), ecore_validate_vlan_mac_del(), and ecore_vlan_mac_get_registry_elem().

◆ check_move

bool(* ecore_vlan_mac_obj::check_move) (struct bxe_softc *sc, struct ecore_vlan_mac_obj *src_o, struct ecore_vlan_mac_obj *dst_o, union ecore_classification_ramrod_data *data)

Checks if DEL-ramrod with the given params may be performed.

Returns
TRUE if the element may be deleted

Definition at line 816 of file ecore_sp.h.

Referenced by ecore_init_mac_obj(), ecore_init_vlan_mac_obj(), ecore_init_vlan_obj(), ecore_init_vxlan_fltr_obj(), and ecore_validate_vlan_mac_move().

◆ complete

int(* ecore_vlan_mac_obj::complete) (struct bxe_softc *sc, struct ecore_vlan_mac_obj *o, union event_ring_elem *cqe, unsigned long *ramrod_flags)

Should be called on a completion arrival.

Parameters
sc
o
cqeCompletion element we are handling
ramrod_flagsif RAMROD_CONT is set the next bulk of pending commands will be executed. RAMROD_DRV_CLR_ONLY and RAMROD_RESTORE may also be set if needed.
Returns
0 if there are neither pending nor waiting for completion commands. Positive value if there are pending for execution or for completion commands. Negative value in case of an error (including an error in the cqe).

Definition at line 896 of file ecore_sp.h.

Referenced by bxe_handle_classification_eqe(), and ecore_init_vlan_mac_common().

◆ delete_all

int(* ecore_vlan_mac_obj::delete_all) (struct bxe_softc *sc, struct ecore_vlan_mac_obj *o, unsigned long *vlan_mac_flags, unsigned long *ramrod_flags)

Delete all configured elements having the given vlan_mac_flags specification. Assumes no pending for execution commands. Will schedule all all currently configured MACs/VLANs/VLAN-MACs matching the vlan_mac_flags specification for deletion and will use the given ramrod_flags for the last DEL operation.

Parameters
sc
o
ramrod_flagsRAMROD_XX flags
Returns
0 if the last operation has completed successfully and there are no more elements left, positive value if there are pending for completion commands, negative value in case of failure.

Definition at line 855 of file ecore_sp.h.

Referenced by bxe_del_all_macs(), bxe_squeeze_objects(), and ecore_init_vlan_mac_common().

◆ exe_queue

◆ get_cam_offset

bool(* ecore_vlan_mac_obj::get_cam_offset) (struct ecore_vlan_mac_obj *o, int *offset)

◆ get_credit

bool(* ecore_vlan_mac_obj::get_credit) (struct ecore_vlan_mac_obj *o)

◆ get_n_elements

int(* ecore_vlan_mac_obj::get_n_elements) (struct bxe_softc *sc, struct ecore_vlan_mac_obj *o, int n, uint8_t *base, uint8_t stride, uint8_t size)

Definition at line 787 of file ecore_sp.h.

Referenced by bxe_drv_info_ether_stat(), ecore_init_mac_obj(), and ecore_init_vlan_obj().

◆ head

◆ head_exe_request

◆ head_reader

uint8_t ecore_vlan_mac_obj::head_reader

◆ macs_pool

◆ put_cam_offset

bool(* ecore_vlan_mac_obj::put_cam_offset) (struct ecore_vlan_mac_obj *o, int offset)

◆ put_credit

◆ ramrod_cmd

int ecore_vlan_mac_obj::ramrod_cmd

◆ raw

◆ restore

int(* ecore_vlan_mac_obj::restore) (struct bxe_softc *sc, struct ecore_vlan_mac_ramrod_params *p, struct ecore_vlan_mac_registry_elem **ppos)

Reconfigures the next MAC/VLAN/VLAN-MAC element from the previously configured elements list.

Parameters
sc
pCommand parameters (RAMROD_COMP_WAIT bit in ramrod_flags is only taken into an account)
pposa pointer to the cookie that should be given back in the next call to make function handle the next element. If *ppos is set to NULL it will restart the iterator. If returned *ppos == NULL this means that the last element has been handled.
Returns
int

Definition at line 875 of file ecore_sp.h.

Referenced by ecore_init_vlan_mac_common(), and ecore_vlan_mac_push_new_cmd().

◆ saved_ramrod_flags

unsigned long ecore_vlan_mac_obj::saved_ramrod_flags

◆ set_one_rule

void(* ecore_vlan_mac_obj::set_one_rule) (struct bxe_softc *sc, struct ecore_vlan_mac_obj *o, struct ecore_exeq_elem *elem, int rule_idx, int cam_offset)

Configures one rule in the ramrod data buffer.

Definition at line 833 of file ecore_sp.h.

Referenced by ecore_execute_vlan_mac(), ecore_init_mac_obj(), ecore_init_vlan_mac_obj(), ecore_init_vlan_obj(), and ecore_init_vxlan_fltr_obj().

◆ vlans_pool

◆ wait

int(* ecore_vlan_mac_obj::wait) (struct bxe_softc *sc, struct ecore_vlan_mac_obj *o)

Wait for completion of all commands. Don't schedule new ones, just wait. It assumes that the completion code will schedule for new commands.

Definition at line 905 of file ecore_sp.h.

Referenced by ecore_init_vlan_mac_common().


The documentation for this struct was generated from the following file: