#include "bnx2x.h"
#include "bnx2x_cmn.h"
#include <linux/crc32.h>
static int bnx2x_vfpf_teardown_queue(struct bnx2x *bp, int qidx);
static void bnx2x_add_tlv(struct bnx2x *bp, void *tlvs_list,
u16 offset, u16 type, u16 length)
{ … }
static void bnx2x_vfpf_prep(struct bnx2x *bp, struct vfpf_first_tlv *first_tlv,
u16 type, u16 length)
{ … }
static void bnx2x_vfpf_finalize(struct bnx2x *bp,
struct vfpf_first_tlv *first_tlv)
{ … }
static void *bnx2x_search_tlv_list(struct bnx2x *bp, void *tlvs_list,
enum channel_tlvs req_tlv)
{ … }
static void bnx2x_dp_tlv_list(struct bnx2x *bp, void *tlvs_list)
{ … }
bool bnx2x_tlv_supported(u16 tlvtype)
{ … }
static inline int bnx2x_pfvf_status_codes(int rc)
{ … }
static int bnx2x_send_msg2pf(struct bnx2x *bp, u8 *done, dma_addr_t msg_mapping)
{ … }
static int bnx2x_get_vf_id(struct bnx2x *bp, u32 *vf_id)
{ … }
int bnx2x_vfpf_acquire(struct bnx2x *bp, u8 tx_count, u8 rx_count)
{ … }
int bnx2x_vfpf_release(struct bnx2x *bp)
{ … }
int bnx2x_vfpf_init(struct bnx2x *bp)
{ … }
void bnx2x_vfpf_close_vf(struct bnx2x *bp)
{ … }
static void bnx2x_leading_vfq_init(struct bnx2x *bp, struct bnx2x_virtf *vf,
struct bnx2x_vf_queue *q)
{ … }
int bnx2x_vfpf_setup_q(struct bnx2x *bp, struct bnx2x_fastpath *fp,
bool is_leading)
{ … }
static int bnx2x_vfpf_teardown_queue(struct bnx2x *bp, int qidx)
{ … }
int bnx2x_vfpf_config_mac(struct bnx2x *bp, const u8 *addr, u8 vf_qid, bool set)
{ … }
int bnx2x_vfpf_config_rss(struct bnx2x *bp,
struct bnx2x_config_rss_params *params)
{ … }
int bnx2x_vfpf_set_mcast(struct net_device *dev)
{ … }
int bnx2x_vfpf_update_vlan(struct bnx2x *bp, u16 vid, u8 vf_qid, bool add)
{ … }
int bnx2x_vfpf_storm_rx_mode(struct bnx2x *bp)
{ … }
static void storm_memset_vf_mbx_ack(struct bnx2x *bp, u16 abs_fid)
{ … }
static void storm_memset_vf_mbx_valid(struct bnx2x *bp, u16 abs_fid)
{ … }
void bnx2x_vf_enable_mbx(struct bnx2x *bp, u8 abs_vfid)
{ … }
static int bnx2x_copy32_vf_dmae(struct bnx2x *bp, u8 from_vf,
dma_addr_t pf_addr, u8 vfid, u32 vf_addr_hi,
u32 vf_addr_lo, u32 len32)
{ … }
static void bnx2x_vf_mbx_resp_single_tlv(struct bnx2x *bp,
struct bnx2x_virtf *vf)
{ … }
static void bnx2x_vf_mbx_resp_send_msg(struct bnx2x *bp,
struct bnx2x_virtf *vf,
int vf_rc)
{ … }
static void bnx2x_vf_mbx_resp(struct bnx2x *bp,
struct bnx2x_virtf *vf,
int rc)
{ … }
static void bnx2x_vf_mbx_resp_phys_port(struct bnx2x *bp,
struct bnx2x_virtf *vf,
void *buffer,
u16 *offset)
{ … }
static void bnx2x_vf_mbx_resp_fp_hsi_ver(struct bnx2x *bp,
struct bnx2x_virtf *vf,
void *buffer,
u16 *offset)
{ … }
static void bnx2x_vf_mbx_acquire_resp(struct bnx2x *bp, struct bnx2x_virtf *vf,
struct bnx2x_vf_mbx *mbx, int vfop_status)
{ … }
static bool bnx2x_vf_mbx_is_windows_vm(struct bnx2x *bp,
struct vfpf_acquire_tlv *acquire)
{ … }
static int bnx2x_vf_mbx_acquire_chk_dorq(struct bnx2x *bp,
struct bnx2x_virtf *vf,
struct bnx2x_vf_mbx *mbx)
{ … }
static void bnx2x_vf_mbx_acquire(struct bnx2x *bp, struct bnx2x_virtf *vf,
struct bnx2x_vf_mbx *mbx)
{ … }
static void bnx2x_vf_mbx_init_vf(struct bnx2x *bp, struct bnx2x_virtf *vf,
struct bnx2x_vf_mbx *mbx)
{ … }
static void bnx2x_vf_mbx_set_q_flags(struct bnx2x *bp, u32 mbx_q_flags,
unsigned long *sp_q_flags)
{ … }
static void bnx2x_vf_mbx_setup_q(struct bnx2x *bp, struct bnx2x_virtf *vf,
struct bnx2x_vf_mbx *mbx)
{ … }
static int bnx2x_vf_mbx_macvlan_list(struct bnx2x *bp,
struct bnx2x_virtf *vf,
struct vfpf_set_q_filters_tlv *tlv,
struct bnx2x_vf_mac_vlan_filters **pfl,
u32 type_flag)
{ … }
static int bnx2x_vf_filters_contain(struct vfpf_set_q_filters_tlv *filters,
u32 flags)
{ … }
static void bnx2x_vf_mbx_dp_q_filter(struct bnx2x *bp, int msglvl, int idx,
struct vfpf_q_mac_vlan_filter *filter)
{ … }
static void bnx2x_vf_mbx_dp_q_filters(struct bnx2x *bp, int msglvl,
struct vfpf_set_q_filters_tlv *filters)
{ … }
#define VFPF_MAC_FILTER …
#define VFPF_VLAN_FILTER …
#define VFPF_VLAN_MAC_FILTER …
static int bnx2x_vf_mbx_qfilters(struct bnx2x *bp, struct bnx2x_virtf *vf)
{ … }
static int bnx2x_filters_validate_mac(struct bnx2x *bp,
struct bnx2x_virtf *vf,
struct vfpf_set_q_filters_tlv *filters)
{ … }
static int bnx2x_filters_validate_vlan(struct bnx2x *bp,
struct bnx2x_virtf *vf,
struct vfpf_set_q_filters_tlv *filters)
{ … }
static void bnx2x_vf_mbx_set_q_filters(struct bnx2x *bp,
struct bnx2x_virtf *vf,
struct bnx2x_vf_mbx *mbx)
{ … }
static void bnx2x_vf_mbx_teardown_q(struct bnx2x *bp, struct bnx2x_virtf *vf,
struct bnx2x_vf_mbx *mbx)
{ … }
static void bnx2x_vf_mbx_close_vf(struct bnx2x *bp, struct bnx2x_virtf *vf,
struct bnx2x_vf_mbx *mbx)
{ … }
static void bnx2x_vf_mbx_release_vf(struct bnx2x *bp, struct bnx2x_virtf *vf,
struct bnx2x_vf_mbx *mbx)
{ … }
static void bnx2x_vf_mbx_update_rss(struct bnx2x *bp, struct bnx2x_virtf *vf,
struct bnx2x_vf_mbx *mbx)
{ … }
static int bnx2x_validate_tpa_params(struct bnx2x *bp,
struct vfpf_tpa_tlv *tpa_tlv)
{ … }
static void bnx2x_vf_mbx_update_tpa(struct bnx2x *bp, struct bnx2x_virtf *vf,
struct bnx2x_vf_mbx *mbx)
{ … }
static void bnx2x_vf_mbx_request(struct bnx2x *bp, struct bnx2x_virtf *vf,
struct bnx2x_vf_mbx *mbx)
{ … }
void bnx2x_vf_mbx_schedule(struct bnx2x *bp,
struct vf_pf_event_data *vfpf_event)
{ … }
void bnx2x_vf_mbx(struct bnx2x *bp)
{ … }
void bnx2x_vf_bulletin_finalize(struct pf_vf_bulletin_content *bulletin,
bool support_long)
{ … }
int bnx2x_post_vf_bulletin(struct bnx2x *bp, int vf)
{ … }