Lines Matching refs:rvu
66 struct rvu *rvu; member
312 struct rvu { struct
370 static inline void rvu_write64(struct rvu *rvu, u64 block, u64 offset, u64 val) in rvu_write64() argument
372 writeq(val, rvu->afreg_base + ((block << 28) | offset)); in rvu_write64()
375 static inline u64 rvu_read64(struct rvu *rvu, u64 block, u64 offset) in rvu_read64() argument
377 return readq(rvu->afreg_base + ((block << 28) | offset)); in rvu_read64()
380 static inline void rvupf_write64(struct rvu *rvu, u64 offset, u64 val) in rvupf_write64() argument
382 writeq(val, rvu->pfreg_base + offset); in rvupf_write64()
385 static inline u64 rvupf_read64(struct rvu *rvu, u64 offset) in rvupf_read64() argument
387 return readq(rvu->pfreg_base + offset); in rvupf_read64()
391 static inline bool is_rvu_96xx_A0(struct rvu *rvu) in is_rvu_96xx_A0() argument
393 struct pci_dev *pdev = rvu->pdev; in is_rvu_96xx_A0()
399 static inline bool is_rvu_96xx_B0(struct rvu *rvu) in is_rvu_96xx_B0() argument
401 struct pci_dev *pdev = rvu->pdev; in is_rvu_96xx_B0()
407 static inline bool is_rvu_supports_nix1(struct rvu *rvu) in is_rvu_supports_nix1() argument
409 struct pci_dev *pdev = rvu->pdev; in is_rvu_supports_nix1()
425 static inline bool is_rvu_fwdata_valid(struct rvu *rvu) in is_rvu_fwdata_valid() argument
427 return (rvu->fwdata->header_magic == RVU_FWDATA_HEADER_MAGIC) && in is_rvu_fwdata_valid()
428 (rvu->fwdata->version == RVU_FWDATA_VERSION); in is_rvu_fwdata_valid()
439 struct rvu_pfvf *rvu_get_pfvf(struct rvu *rvu, int pcifunc);
440 void rvu_get_pf_numvfs(struct rvu *rvu, int pf, int *numvfs, int *hwvf);
442 bool is_pffunc_map_valid(struct rvu *rvu, u16 pcifunc, int blktype);
443 int rvu_get_lf(struct rvu *rvu, struct rvu_block *block, u16 pcifunc, u16 slot);
444 int rvu_lf_reset(struct rvu *rvu, struct rvu_block *block, int lf);
445 int rvu_get_blkaddr(struct rvu *rvu, int blktype, u16 pcifunc);
446 int rvu_poll_reg(struct rvu *rvu, u64 block, u64 offset, u64 mask, bool zero);
457 int rvu_aq_alloc(struct rvu *rvu, struct admin_queue **ad_queue,
459 void rvu_aq_free(struct rvu *rvu, struct admin_queue *aq);
462 static inline bool is_pf_cgxmapped(struct rvu *rvu, u8 pf) in is_pf_cgxmapped() argument
464 return (pf >= PF_CGXMAP_BASE && pf <= rvu->cgx_mapped_pfs); in is_pf_cgxmapped()
474 int rvu_mbox_handler_ ## fn_name(struct rvu *, struct req *, struct rsp *);
478 int rvu_cgx_init(struct rvu *rvu);
479 int rvu_cgx_exit(struct rvu *rvu);
480 void *rvu_cgx_pdata(u8 cgx_id, struct rvu *rvu);
481 int rvu_cgx_config_rxtx(struct rvu *rvu, u16 pcifunc, bool start);
482 void rvu_cgx_enadis_rx_bp(struct rvu *rvu, int pf, bool enable);
483 int rvu_cgx_start_stop_io(struct rvu *rvu, u16 pcifunc, bool start);
484 int rvu_cgx_nix_cuml_stats(struct rvu *rvu, void *cgxd, int lmac_id, int index,
487 int rvu_npa_init(struct rvu *rvu);
488 void rvu_npa_freemem(struct rvu *rvu);
489 void rvu_npa_lf_teardown(struct rvu *rvu, u16 pcifunc, int npalf);
490 int rvu_npa_aq_enq_inst(struct rvu *rvu, struct npa_aq_enq_req *req,
494 bool is_nixlf_attached(struct rvu *rvu, u16 pcifunc);
495 int rvu_nix_init(struct rvu *rvu);
496 int rvu_nix_reserve_mark_format(struct rvu *rvu, struct nix_hw *nix_hw,
498 void rvu_nix_freemem(struct rvu *rvu);
499 int rvu_get_nixlf_count(struct rvu *rvu);
500 void rvu_nix_lf_teardown(struct rvu *rvu, u16 pcifunc, int blkaddr, int npalf);
501 int nix_get_nixlf(struct rvu *rvu, u16 pcifunc, int *nixlf, int *nix_blkaddr);
502 int nix_update_bcast_mce_list(struct rvu *rvu, u16 pcifunc, bool add);
505 int rvu_npc_init(struct rvu *rvu);
506 void rvu_npc_freemem(struct rvu *rvu);
507 int rvu_npc_get_pkind(struct rvu *rvu, u16 pf);
508 void rvu_npc_set_pkind(struct rvu *rvu, int pkind, struct rvu_pfvf *pfvf);
509 int npc_config_ts_kpuaction(struct rvu *rvu, int pf, u16 pcifunc, bool en);
510 void rvu_npc_install_ucast_entry(struct rvu *rvu, u16 pcifunc,
512 void rvu_npc_install_promisc_entry(struct rvu *rvu, u16 pcifunc,
514 void rvu_npc_disable_promisc_entry(struct rvu *rvu, u16 pcifunc, int nixlf);
515 void rvu_npc_enable_promisc_entry(struct rvu *rvu, u16 pcifunc, int nixlf);
516 void rvu_npc_install_bcast_match_entry(struct rvu *rvu, u16 pcifunc,
518 void rvu_npc_enable_bcast_entry(struct rvu *rvu, u16 pcifunc, bool enable);
519 int rvu_npc_update_rxvlan(struct rvu *rvu, u16 pcifunc, int nixlf);
520 void rvu_npc_disable_mcam_entries(struct rvu *rvu, u16 pcifunc, int nixlf);
521 void rvu_npc_disable_default_entries(struct rvu *rvu, u16 pcifunc, int nixlf);
522 void rvu_npc_enable_default_entries(struct rvu *rvu, u16 pcifunc, int nixlf);
523 void rvu_npc_update_flowkey_alg_idx(struct rvu *rvu, u16 pcifunc, int nixlf,
525 void rvu_npc_get_mcam_entry_alloc_info(struct rvu *rvu, u16 pcifunc,
528 void rvu_npc_get_mcam_counter_alloc_info(struct rvu *rvu, u16 pcifunc,
533 void rvu_dbg_init(struct rvu *rvu);
534 void rvu_dbg_exit(struct rvu *rvu);
536 static inline void rvu_dbg_init(struct rvu *rvu) {} in rvu_dbg_init() argument
537 static inline void rvu_dbg_exit(struct rvu *rvu) {} in rvu_dbg_exit() argument