Lines Matching +full:pa +full:- +full:stats

1 /* SPDX-License-Identifier: GPL-2.0-only */
3 * Copyright (c) 2005-2014 Brocade Communications Systems, Inc.
4 * Copyright (c) 2014- QLogic Corporation.
8 * Linux driver for QLogic BR-series Fibre Channel Host Bus Adapter.
21 (sizeof(struct bfa_trc_mod_s) - \
111 dm_ptr->mem_len = seg_sz; in bfa_mem_dma_setup()
113 list_add_tail(&dm_ptr->qe, &meminfo->dma_info.qe); in bfa_mem_dma_setup()
120 kva_ptr->mem_len = seg_sz; in bfa_mem_kva_setup()
122 list_add_tail(&kva_ptr->qe, &meminfo->kva_info.qe); in bfa_mem_kva_setup()
126 #define bfa_mem_dma_sptr(_mod, _i) (&(_mod)->dma_seg[(_i)])
131 #define bfa_mem_kva_curp(_mod) ((_mod)->kva_seg.kva_curp)
132 #define bfa_mem_dma_virt(_sptr) ((_sptr)->kva_curp)
133 #define bfa_mem_dma_phys(_sptr) ((_sptr)->dma_curp)
134 #define bfa_mem_dma_len(_sptr) ((_sptr)->mem_len)
136 /* Get the corresponding dma buf kva for a req - from the tag */
138 (((u8 *)(_mod)->dma_seg[BFI_MEM_SEG_FROM_TAG(_tag, _rqsz)].kva_curp) +\
141 /* Get the corresponding dma buf pa for a req - from the tag */
143 ((_mod)->dma_seg[BFI_MEM_SEG_FROM_TAG(_tag, _rqsz)].dma_curp + \
158 * Structure used to remember the DMA-able memory block's KVA and Physical
163 u64 pa; /* ! Physical address */ member
167 #define BFA_ROUNDUP(_l, _s) (((_l) + ((_s) - 1)) & ~((_s) - 1))
175 #define bfa_dma_be_addr_set(dma_addr, pa) \ argument
176 __bfa_dma_be_addr_set(&dma_addr, (u64)pa)
178 __bfa_dma_be_addr_set(union bfi_addr_u *dma_addr, u64 pa) in __bfa_dma_be_addr_set() argument
180 dma_addr->a32.addr_lo = cpu_to_be32(pa); in __bfa_dma_be_addr_set()
181 dma_addr->a32.addr_hi = cpu_to_be32(pa >> 32); in __bfa_dma_be_addr_set()
188 __bfa_alen_set(struct bfi_alen_s *alen, u32 len, u64 pa) in __bfa_alen_set() argument
190 alen->al_len = cpu_to_be32(len); in __bfa_alen_set()
191 bfa_dma_be_addr_set(alen->al_addr, pa); in __bfa_alen_set()
299 (__notify)->cbfn = (__cbfn); \
300 (__notify)->cbarg = (__cbarg); \
348 struct bfa_ioc_drv_stats_s stats; member
351 bfa_boolean_t stats_busy; /* outstanding stats */
439 #define BFA_MEM_ABLK_DMA(__bfa) (&((__bfa)->modules.ablk.ablk_dma))
471 #define BFA_SFP_MOD(__bfa) (&(__bfa)->modules.sfp)
472 #define BFA_MEM_SFP_DMA(__bfa) (&(BFA_SFP_MOD(__bfa)->sfp_dma))
521 #define BFA_FLASH(__bfa) (&(__bfa)->modules.flash)
522 #define BFA_MEM_FLASH_DMA(__bfa) (&(BFA_FLASH(__bfa)->flash_dma))
567 u8 rsvd; /* 64-bit align */
592 u16 temp; /* 10-bit A/D value */
593 u16 brd_temp; /* 9-bit board temp */
655 #define BFA_DIAG_MOD(__bfa) (&(__bfa)->modules.diag_mod)
656 #define BFA_MEM_DIAG_DMA(__bfa) (&(BFA_DIAG_MOD(__bfa)->diag_dma))
712 #define BFA_PHY(__bfa) (&(__bfa)->modules.phy)
713 #define BFA_MEM_PHY_DMA(__bfa) (&(BFA_PHY(__bfa)->phy_dma))
720 struct bfa_phy_stats_s *stats,
763 #define BFA_FRU(__bfa) (&(__bfa)->modules.fru)
764 #define BFA_MEM_FRU_DMA(__bfa) (&(BFA_FRU(__bfa)->fru_dma))
834 (&(__bfa)->modules.dconf_mod)
835 #define BFA_MEM_DCONF_KVA(__bfa) (&(BFA_DCONF_MOD(__bfa)->kva_seg))
837 (BFA_DCONF_MOD(__bfa)->read_data_valid)
840 (BFA_DCONF_MOD(__bfa)->min_cfg)
849 #define bfa_ioc_pcifn(__ioc) ((__ioc)->pcidev.pci_func)
850 #define bfa_ioc_devid(__ioc) ((__ioc)->pcidev.device_id)
851 #define bfa_ioc_bar0(__ioc) ((__ioc)->pcidev.pci_bar_kva)
852 #define bfa_ioc_portid(__ioc) ((__ioc)->port_id)
853 #define bfa_ioc_asic_gen(__ioc) ((__ioc)->asic_gen)
858 (((__stats)->drv_stats) = (__ioc)->stats)
860 memset(&(__ioc)->stats, 0, sizeof((__ioc)->stats))
861 #define bfa_ioc_maxfrsize(__ioc) ((__ioc)->attr->maxfrsize)
862 #define bfa_ioc_rx_bbcredit(__ioc) ((__ioc)->attr->rx_bbcredit)
865 BFI_ADAPTER_GETP(SPEED, (__ioc)->attr->adapter_prop))
867 BFI_ADAPTER_GETP(NPORTS, (__ioc)->attr->adapter_prop)
869 #define bfa_ioc_stats(_ioc, _stats) ((_ioc)->stats._stats++)
895 ((__ioc)->ioc_hwif->ioc_pll_init((__ioc)->pcidev.pci_bar_kva, \
896 (__ioc)->asic_mode))
904 if ((__ioc)->ioc_hwif->ioc_isr_mode_set) \
905 ((__ioc)->ioc_hwif->ioc_isr_mode_set(__ioc, __msix)); \
908 ((__ioc)->ioc_hwif->ioc_ownership_reset(__ioc))
909 #define bfa_ioc_get_fcmode(__ioc) ((__ioc)->fcmode)
911 if ((__ioc)->ioc_hwif->ioc_lpu_read_stat) \
912 ((__ioc)->ioc_hwif->ioc_lpu_read_stat(__ioc)); \
970 bfa_status_t bfa_ioc_fw_stats_get(struct bfa_ioc_s *ioc, void *stats);