29 PCI_ROM( 0x14e4, 0x1604,
"14e4-1604",
"Broadcom BCM957454", 0 ),
30 PCI_ROM( 0x14e4, 0x1605,
"14e4-1605",
"Broadcom BCM957454 RDMA", 0 ),
35 PCI_ROM( 0x14e4, 0x1614,
"14e4-1614",
"Broadcom BCM957454", 0 ),
37 PCI_ROM( 0x14e4, 0x16c0,
"14e4-16c0",
"Broadcom BCM957417", 0 ),
40 PCI_ROM( 0x14e4, 0x16c8,
"14e4-16c8",
"Broadcom BCM957301", 0 ),
41 PCI_ROM( 0x14e4, 0x16c9,
"14e4-16c9",
"Broadcom BCM957302", 0 ),
42 PCI_ROM( 0x14e4, 0x16ca,
"14e4-16ca",
"Broadcom BCM957304", 0 ),
43 PCI_ROM( 0x14e4, 0x16cc,
"14e4-16cc",
"Broadcom BCM957417 MF", 0 ),
44 PCI_ROM( 0x14e4, 0x16cd,
"14e4-16cd",
"Broadcom BCM958700", 0 ),
45 PCI_ROM( 0x14e4, 0x16ce,
"14e4-16ce",
"Broadcom BCM957311", 0 ),
46 PCI_ROM( 0x14e4, 0x16cf,
"14e4-16cf",
"Broadcom BCM957312", 0 ),
47 PCI_ROM( 0x14e4, 0x16d0,
"14e4-16d0",
"Broadcom BCM957402", 0 ),
48 PCI_ROM( 0x14e4, 0x16d1,
"14e4-16d1",
"Broadcom BCM957404", 0 ),
49 PCI_ROM( 0x14e4, 0x16d2,
"14e4-16d2",
"Broadcom BCM957406", 0 ),
50 PCI_ROM( 0x14e4, 0x16d4,
"14e4-16d4",
"Broadcom BCM957402 MF", 0 ),
51 PCI_ROM( 0x14e4, 0x16d5,
"14e4-16d5",
"Broadcom BCM957407", 0 ),
52 PCI_ROM( 0x14e4, 0x16d6,
"14e4-16d6",
"Broadcom BCM957412", 0 ),
53 PCI_ROM( 0x14e4, 0x16d7,
"14e4-16d7",
"Broadcom BCM957414", 0 ),
54 PCI_ROM( 0x14e4, 0x16d8,
"14e4-16d8",
"Broadcom BCM957416", 0 ),
55 PCI_ROM( 0x14e4, 0x16d9,
"14e4-16d9",
"Broadcom BCM957417", 0 ),
56 PCI_ROM( 0x14e4, 0x16da,
"14e4-16da",
"Broadcom BCM957402", 0 ),
57 PCI_ROM( 0x14e4, 0x16db,
"14e4-16db",
"Broadcom BCM957404", 0 ),
59 PCI_ROM( 0x14e4, 0x16de,
"14e4-16de",
"Broadcom BCM957412 MF", 0 ),
60 PCI_ROM( 0x14e4, 0x16df,
"14e4-16df",
"Broadcom BCM957314", 0 ),
61 PCI_ROM( 0x14e4, 0x16e0,
"14e4-16e0",
"Broadcom BCM957317", 0 ),
62 PCI_ROM( 0x14e4, 0x16e2,
"14e4-16e2",
"Broadcom BCM957417", 0 ),
63 PCI_ROM( 0x14e4, 0x16e3,
"14e4-16e3",
"Broadcom BCM957416", 0 ),
64 PCI_ROM( 0x14e4, 0x16e4,
"14e4-16e4",
"Broadcom BCM957317", 0 ),
65 PCI_ROM( 0x14e4, 0x16e7,
"14e4-16e7",
"Broadcom BCM957404 MF", 0 ),
66 PCI_ROM( 0x14e4, 0x16e8,
"14e4-16e8",
"Broadcom BCM957406 MF", 0 ),
67 PCI_ROM( 0x14e4, 0x16e9,
"14e4-16e9",
"Broadcom BCM957407", 0 ),
68 PCI_ROM( 0x14e4, 0x16ea,
"14e4-16ea",
"Broadcom BCM957407 MF", 0 ),
69 PCI_ROM( 0x14e4, 0x16eb,
"14e4-16eb",
"Broadcom BCM957412 RDMA MF", 0 ),
70 PCI_ROM( 0x14e4, 0x16ec,
"14e4-16ec",
"Broadcom BCM957414 MF", 0 ),
71 PCI_ROM( 0x14e4, 0x16ed,
"14e4-16ed",
"Broadcom BCM957414 RDMA MF", 0 ),
72 PCI_ROM( 0x14e4, 0x16ee,
"14e4-16ee",
"Broadcom BCM957416 MF", 0 ),
73 PCI_ROM( 0x14e4, 0x16ef,
"14e4-16ef",
"Broadcom BCM957416 RDMA MF", 0 ),
74 PCI_ROM( 0x14e4, 0x16f0,
"14e4-16f0",
"Broadcom BCM957320", 0 ),
75 PCI_ROM( 0x14e4, 0x16f1,
"14e4-16f1",
"Broadcom BCM957320", 0 ),
76 PCI_ROM( 0x14e4, 0x1750,
"14e4-1750",
"Broadcom BCM957508", 0 ),
77 PCI_ROM( 0x14e4, 0x1751,
"14e4-1751",
"Broadcom BCM957504", 0 ),
78 PCI_ROM( 0x14e4, 0x1752,
"14e4-1752",
"Broadcom BCM957502", 0 ),
79 PCI_ROM( 0x14e4, 0x1760,
"14e4-1760",
"Broadcom BCM957608", 0 ),
80 PCI_ROM( 0x14e4, 0x1800,
"14e4-1800",
"Broadcom BCM957502 MF", 0 ),
81 PCI_ROM( 0x14e4, 0x1801,
"14e4-1801",
"Broadcom BCM957504 MF", 0 ),
82 PCI_ROM( 0x14e4, 0x1802,
"14e4-1802",
"Broadcom BCM957508 MF", 0 ),
83 PCI_ROM( 0x14e4, 0x1803,
"14e4-1803",
"Broadcom BCM957502 RDMA MF", 0 ),
84 PCI_ROM( 0x14e4, 0x1804,
"14e4-1804",
"Broadcom BCM957504 RDMA MF", 0 ),
85 PCI_ROM( 0x14e4, 0x1805,
"14e4-1805",
"Broadcom BCM957508 RDMA MF", 0 ),
107 DBGP (
"%s\n", __func__ );
124 unsigned long reg_base, reg_size;
135 DBGP (
"%s\n", __func__ );
144 &
bp->subsystem_vendor );
148 &
bp->subsystem_device );
169 DBGP (
"%s\n", __func__ );
172 DBGP (
"- %s ( ): Failed\n", __func__ );
207 off = (
void * ) (
bp->bar1 );
221 (
u32 )
bp->nq.epoch, 0 );
247 (
u32 )
bp->rx.epoch, 0 );
258 (
u32 )
bp->tx.epoch, 0 );
267 char *
src = (
char * )iob->
data;
295 return ( avail-use );
306 else if (
len < 1024 )
308 else if (
len < 2048 )
313 prod_bd->
dma = mapping;
323 iob =
bp->tx.iob[hw_idx];
335 DBGP (
"%s\n", __func__ );
339 for ( i = 0; i <
bp->rx.buf_cnt; i++ ) {
340 if (
bp->rx.iob[i] ) {
370 DBGP (
"- %s ( ): alloc_iob Failed\n", __func__ );
377 bp->rx.iob[iob_idx] = iob;
383 u16 cons_id = (
bp->rx.cons_id %
bp->rx.ring_cnt );
386 while (
bp->rx.iob_cnt <
bp->rx.buf_cnt ) {
387 iob_idx = ( cons_id %
bp->rx.buf_cnt );
388 if ( !
bp->rx.iob[iob_idx] ) {
394 cons_id =
NEXT_IDX ( cons_id,
bp->rx.ring_cnt );
396 if ( iob_idx > cons_id )
401 if ( cons_id !=
bp->rx.cons_id ) {
403 bp->rx.cons_id = cons_id;
419 u8 ignore_chksum_err = 0;
428 ignore_chksum_err = 1;
430 if ( err_flags && !ignore_chksum_err ) {
435 for ( i = 0; i < 6; i++ ) {
436 if ( rx_buf[6 + i] !=
bp->mac_addr[i] )
456 cons_id =
bp->cq.cons_id + cnt;
457 if ( cons_id >=
bp->cq.ring_cnt ) {
459 bp->cq.completion_bit ^= 1;
461 cons_id = cons_id -
bp->cq.ring_cnt;
463 bp->cq.cons_id = cons_id;
484 bp->rx.iob[desc_idx] =
NULL;
496 u8 cmpl_bit =
bp->cq.completion_bit;
498 if (
bp->cq.cons_id == (
bp->cq.ring_cnt - 1 ) ) {
513 DBGP (
"%s\n", __func__ );
524 DBGP (
"%s\n", __func__ );
543 DBGP (
"%s\n", __func__ );
549 bp->nq.completion_bit = 0x1;
553 bp->cq.completion_bit = 0x1;
572 DBGP (
"%s\n", __func__ );
573 if (
bp->nq.bd_virt ) {
578 if (
bp->cq.bd_virt ) {
583 if (
bp->rx.bd_virt ) {
588 if (
bp->tx.bd_virt ) {
593 DBGP (
"- %s ( ): - Done\n", __func__ );
598 DBGP (
"%s\n", __func__ );
599 if (
bp->hwrm_addr_dma ) {
604 if (
bp->hwrm_addr_resp ) {
606 bp->hwrm_addr_resp =
NULL;
609 if (
bp->hwrm_addr_req ) {
613 DBGP (
"- %s ( ): - Done\n", __func__ );
618 DBGP (
"%s\n", __func__ );
626 if (
bp->hwrm_addr_req &&
bp->hwrm_addr_resp &&
bp->hwrm_addr_dma) {
631 DBGP (
"- %s ( ): Failed\n", __func__ );
638 DBGP (
"%s\n", __func__ );
647 if (
bp->tx.bd_virt &&
bp->rx.bd_virt &&
648 bp->nq.bd_virt &&
bp->cq.bd_virt) {
653 DBGP (
"- %s ( ): Failed\n", __func__ );
672 for ( i = 0; i < cnt; i++ ) {
698 u8 *ptr = (
u8 * )resp;
704 if (
len >
bp->hwrm_max_req_len )
709 for ( idx = 0; idx < wait_cnt; idx++ ) {
731 DBGP (
"%s\n", __func__ );
746 if ( !
bp->hwrm_cmd_timeout )
778 DBGP (
"%s\n", __func__ );
837 DBGP (
"%s\n", __func__ );
845 bp->num_cmpl_rings =
bp->min_cp_rings;
848 bp->num_tx_rings =
bp->min_tx_rings;
851 bp->num_rx_rings =
bp->min_rx_rings;
854 bp->num_hw_ring_grps =
bp->min_hw_ring_grps;
857 bp->num_stat_ctxs =
bp->min_stat_ctxs;
873 DBGP (
"%s\n", __func__ );
893 DBGP (
"%s\n", __func__ );
903 DBGP (
"- %s ( ): Failed\n", __func__ );
911 bp->err_rcvry_supported = 1;
928 DBGP (
"%s\n", __func__ );
935 DBGP (
"- %s ( ): Failed\n", __func__ );
946 bp->ordinal_value = (
u8 ) resp->
pci_id & 0x0F;
969 DBGP (
"%s\n", __func__ );
976 DBGP (
"-s %s ( ): Failed\n", __func__ );
991 DBGP (
"%s\n", __func__ );
1005 DBGP (
"%s\n", __func__ );
1021 return wait_resp (
bp,
bp->hwrm_cmd_timeout, cmd_len, __func__ );
1032 DBGP (
"%s\n", __func__ );
1034 bp->er.drv_poll_freq = 100;
1035 if ( ! (
bp->err_rcvry_supported ) ) {
1046 DBGP (
"- %s ( ): Failed\n", __func__ );
1079 DBGP (
"rst_reg = %x ",
bp->er.rst_reg[i] );
1080 DBGP (
"rst_reg_val = %x ",
bp->er.rst_reg_val[i] );
1081 DBGP (
"rst_after_reset = %x\n",
bp->er.delay_after_rst[i] );
1093 DBGP (
"%s\n", __func__ );
1108 if (
bp->err_rcvry_supported ) {
1121 DBGP (
"- %s ( ): Failed\n", __func__ );
1135 DBGP (
"%s\n", __func__ );
1155 DBGP (
"%s\n", __func__ );
1157 idx =
bp->nq_ring_id;
1159 idx =
bp->cq_ring_id;
1197 DBGP (
"%s\n", __func__ );
1235 DBGP (
"%s\n", __func__ );
1245 DBGP (
"- %s ( ): Failed\n", __func__ );
1284 return wait_resp (
bp,
bp->hwrm_cmd_timeout, cmd_len, __func__ );
1294 DBGP (
"%s\n", __func__ );
1300 DBGP (
"- %s ( ): Failed\n", __func__ );
1332 DBGP (
"%s\n", __func__ );
1342 cmd_len, __func__ );
1349 DBGP (
"%s\n", __func__ );
1434 DBGP (
"%s\n", __func__ );
1441 return wait_resp (
bp,
bp->hwrm_cmd_timeout, cmd_len, __func__ );
1449 DBGP (
"%s\n", __func__ );
1468 DBGP (
"%s\n", __func__ );
1477 DBGP (
"- %s ( ): Failed\n", __func__ );
1490 DBGP (
"%s\n", __func__ );
1497 return wait_resp (
bp,
bp->hwrm_cmd_timeout, cmd_len, __func__ );
1515 DBGP (
"%s\n", __func__ );
1646 return wait_resp (
bp,
bp->hwrm_cmd_timeout, cmd_len, __func__ );
1653 DBGP (
"%s\n", __func__ );
1687 DBGP (
"%s\n", __func__ );
1689 for ( i = 0; i < (
bp->wait_link_timeout / 100 ); i++ ) {
1701 if ( !
bp->er.er_rst_on )
1714 DBGP (
"%s\n", __func__ );
1720 DBGP (
"- %s ( ): Failed\n", __func__ );
1735 DBGP (
"%s\n", __func__ );
1744 DBGP (
"- %s ( ): Failed\n", __func__ );
1758 DBGP (
"%s\n", __func__ );
1767 DBGP (
"- %s ( ): Failed\n", __func__ );
1782 DBGP (
"%s\n", __func__ );
1789 req->
cr =
bp->cq_ring_id;
1790 req->
rr =
bp->rx_ring_id;
1793 req->
sc =
bp->stat_ctx_id;
1797 DBGP (
"- %s ( ): Failed\n", __func__ );
1811 DBGP (
"%s\n", __func__ );
1816 return wait_resp (
bp,
bp->hwrm_cmd_timeout, cmd_len, __func__ );
1826 DBGP (
"%s\n", __func__ );
1877 DBGP (
"- %s ( ): Failed, type = %x\n", __func__,
type );
1899 DBGP (
"%s\n", __func__ );
1905 DBGP (
"%s\n", __func__ );
1911 DBGP (
"%s\n", __func__ );
1919 DBGP (
"%s\n", __func__ );
1934 DBGP (
"%s\n", __func__ );
1949 DBGP (
"%s\n", __func__ );
1974 DBGP (
"%s\n", __func__ );
1992 DBGP (
"%s\n", __func__ );
1999 DBGP (
"- %s ( ): Failed\n", __func__ );
2014 DBGP (
"%s\n", __func__ );
2023 DBGP (
"- %s ( ): Failed\n", __func__ );
2036 DBGP (
"%s\n", __func__ );
2053 return wait_resp (
bp,
bp->hwrm_cmd_timeout, cmd_len, __func__ );
2070 DBGP (
"%s \n", __func__ );
2148 for ( ptr = cmds; *ptr; ++ptr ) {
2151 ret = ( *ptr ) (
bp );
2153 DBGP (
"- %s ( ): Failed\n", __func__ );
2160#define bnxt_down_chip( bp ) bnxt_hwrm_run ( bring_down_chip, bp )
2161#define bnxt_up_chip( bp ) bnxt_hwrm_run ( bring_up_chip, bp )
2162#define bnxt_down_nic( bp ) bnxt_hwrm_run ( bring_down_nic, bp )
2163#define bnxt_up_nic( bp ) bnxt_hwrm_run ( bring_up_nic, bp )
2164#define bnxt_up_init( bp ) bnxt_hwrm_run ( bring_up_init, bp )
2170 DBGP (
"%s\n", __func__ );
2174 DBGP (
"- %s ( ): bnxt_alloc_rings_mem Failed\n", __func__ );
2181 DBGP (
"- %s ( ): bnxt_up_chip Failed\n", __func__ );
2186 DBGP (
"- %s ( ): bnxt_up_nic\n", __func__);
2205 if ( !
bp->vlan_tx &&
bp->vlan_id )
2209 if (
iob_len ( iob ) != prev_len )
2220 if (
bp->er.er_rst_on ) {
2226 DBGP (
"- %s ( ): Failed no bd's available\n", __func__ );
2232 entry =
bp->tx.prod_id;
2234 bp->tx.iob[entry] = iob;
2238 if (
bp->tx.prod_id > entry )
2243 bp->tx.prod_id = entry;
2254 cons_id =
bp->nq.cons_id + cnt;
2255 if ( cons_id >=
bp->nq.ring_cnt ) {
2257 bp->nq.completion_bit ^= 1;
2259 cons_id = cons_id -
bp->nq.ring_cnt;
2261 bp->nq.cons_id = cons_id;
2275#define BNXT_FW_HEALTH_WIN_OFF 0x3000
2276#define BNXT_REG_WINDOW_BASE 0x400
2277#define BNXT_GRC_BASE_MASK 0xfff
2278#define BNXT_GRC_OFFSET_MASK 0xffc
2291 DBGP (
"bnxt_er_reg_write: reg_addr = %x, reg_val = %x\n", reg_addr, reg_val);
2307 DBGP (
"bnxt_er_reg_read: reg_addr = %x, reg_val = %x\n", reg_addr, reg_val);
2315 switch ( reg_type ) {
2323 reg_val =
readl (
bp->bar0 + ( reg_addr & mask ) );
2326 reg_val =
readl (
bp->bar1 + ( reg_addr & mask ) );
2331 DBGP (
"read_reg_val bp %p addr %x type %x : reg_val = %x\n",
bp, reg_addr, reg_type, reg_val );
2340 switch ( reg_type ) {
2348 writel ( reg_val,
bp->bar0 + ( reg_addr & mask ) );
2351 writel ( reg_val,
bp->bar1 + ( reg_addr & mask ) );
2363 for ( i = 0; i <
bp->er.reg_array_cnt; i++ ) {
2366 delay_time =
bp->er.delay_after_rst[i];
2368 udelay ( delay_time * 100000 );
2377 unsigned short pci_command, new_command;
2380 DBGP (
"%s(hb_task: %d)\n", __func__, hb_task );
2381 if (
bp->er.er_rst_on ) {
2382 if ( timer_running ( &
bp->wait_timer) ) {
2394 if ( present_hb_cnt !=
bp->er.last_fw_hb ) {
2395 bp->er.last_fw_hb = present_hb_cnt;
2401 DBGP (
"%s(): Trigger Error Recovery\n", __func__ );
2402 bp->er.er_rst_on = 1;
2415 udelay (
bp->er.rst_min_dsecs * 100000 );
2421 if (
bp->er.master_pf ) {
2423 udelay (
bp->er.master_wait_period * 100000 );
2429 udelay (
bp->er.master_wait_post_rst * 100000 );
2432 udelay (
bp->er.normal_wait_period * 100000 );
2436 for ( i = 0; i <
bp->er.max_bailout_post_rst; i++ ) {
2438 bp->er.fw_status_reg,
2461 bp->er.er_rst_on = 0;
2470 bp->er.driver_initiated_recovery = 1;
2474 bp->er.driver_initiated_recovery = 0;
2480 bp->er.master_pf = 1;
2482 bp->er.master_pf = 0;
2486 bp->er.fw_status_reg,
2490 bp->er.last_fw_hb = 0;
2492 bp->er.fw_rst_cnt_reg,
2496 bp->er.rst_inprg_reg,
2500 bp->er.recvry_cnt_reg,
2508 DBGP (
"Reset Notify Async event" );
2512 DBGP (
" error recovery initiated\n" );
2516 if (
bp->er.rst_min_dsecs == 0 )
2519 if (
bp->er.rst_max_dsecs == 0 )
2523 bp->er.er_initiate = 1;
2530 DBGP (
"bnxt_link_speed_evt: event data = %lx\n",
2577 u16 old_cid =
bp->cq.cons_id;
2594 switch ( cq_type ) {
2645 if (
bp->cq.cons_id != old_cid )
2653 u16 old_cid =
bp->nq.cons_id;
2665 if ( ( nqp->
v &
NQ_CN_V ) ^
bp->nq.completion_bit )
2672 switch ( nq_type ) {
2714 if (
bp->nq.cons_id != old_cid )
2724 if (
bp->er.driver_initiated_recovery ) {
2747 if (
bp->er.er_initiate ) {
2749 bp->er.er_initiate = 0;
2758 DBGP (
"%s\n", __func__ );
2781 DBGP (
"%s\n", __func__ );
2785 DBGP (
"- %s ( ): alloc_etherdev Failed\n", __func__ );
2809 bp->dma = &pci->
dma;
2820 goto err_alloc_hwrm;
2829 DBGP (
"- %s ( ): register_netdev Failed\n", __func__ );
2830 goto err_register_netdev;
2856 DBGP (
"%s\n", __func__ );
2871 DBGP (
"%s - Done\n", __func__ );
#define NULL
NULL pointer (VOID *)
uint32_t flag
Flag number.
struct arbelprm_rc_send_wqe rc
#define assert(condition)
Assert a condition at run-time.
static int bnxt_hwrm_set_rx_mask(struct bnxt *bp, u32 rx_mask)
static int bnxt_hwrm_error_recovery_req(struct bnxt *bp)
static int bnxt_hwrm_ring_alloc_nq(struct bnxt *bp)
static int bnxt_hwrm_ring_free_grp(struct bnxt *bp)
static u32 bnxt_tx_avail(struct bnxt *bp)
void bnxt_rst_er_registers(struct bnxt *bp)
int bnxt_alloc_rings_mem(struct bnxt *bp)
static void bnxt_poll(struct net_device *dev)
static int bnxt_hwrm_stat_ctx_free(struct bnxt *bp)
static int bnxt_hwrm_vnic_alloc(struct bnxt *bp)
static int bnxt_alloc_rx_iob(struct bnxt *bp, u16 cons_id, u16 iob_idx)
static void bnxt_close(struct net_device *dev)
u32 bnxt_er_reg_read(struct bnxt *bp, u32 reg_addr)
static int bnxt_hwrm_ring_free_cq(struct bnxt *bp)
hwrm_func_t bring_down_nic[]
static void bnxt_db_nq(struct bnxt *bp)
int bnxt_free_rx_iob(struct bnxt *bp)
hwrm_func_t bring_down_chip[]
static int bnxt_hwrm_ring_alloc_grp(struct bnxt *bp)
#define BNXT_FW_HEALTH_WIN_OFF
static int bnxt_get_pci_info(struct bnxt *bp)
static int bnxt_open(struct net_device *dev)
static void bnxt_db_cq(struct bnxt *bp)
static int bnxt_hwrm_ring_alloc_rx(struct bnxt *bp)
static int bnxt_tx(struct net_device *dev, struct io_buffer *iob)
void bnxt_mm_init_hwrm(struct bnxt *bp, const char *func)
hwrm_func_t bring_up_chip[]
#define BNXT_GRC_BASE_MASK
static int bnxt_get_link_state(struct bnxt *bp)
static int bnxt_reset_rx_mask(struct bnxt *bp)
void bnxt_er_task(struct bnxt *bp, u8 hb_task)
static int bnxt_hwrm_cfa_l2_filter_alloc(struct bnxt *bp)
static void bnxt_service_cq(struct net_device *dev)
static void bnxt_tx_adjust_pkt(struct bnxt *bp, struct io_buffer *iob)
void bnxt_set_txq(struct bnxt *bp, int entry, physaddr_t mapping, int len)
static int bnxt_hwrm_func_drv_rgtr(struct bnxt *bp)
static int bnxt_hwrm_func_qcfg_req(struct bnxt *bp)
static int bnxt_hwrm_queue_qportcfg(struct bnxt *bp)
static int bnxt_hwrm_cfa_l2_filter_free(struct bnxt *bp)
hwrm_func_t bring_up_nic[]
static void bnxt_down_pci(struct bnxt *bp)
void bnxt_link_speed_evt(struct bnxt *bp, struct hwrm_async_event_cmpl *evt)
static int bnxt_hwrm_backing_store_qcfg(struct bnxt *bp)
static int bnxt_hwrm_backing_store_cfg(struct bnxt *bp)
#define BNXT_GRC_OFFSET_MASK
u8 bnxt_is_pci_vf(struct pci_device *pdev)
Check if Virtual Function.
static int bnxt_hwrm_ring_alloc_tx(struct bnxt *bp)
static int bnxt_hwrm_ver_get(struct bnxt *bp)
static int bnxt_get_link_speed(struct bnxt *bp)
static int bnxt_hwrm_func_resource_qcaps(struct bnxt *bp)
static void bnxt_db_rx(struct bnxt *bp, u32 idx)
int bnxt_hwrm_ring_free(struct bnxt *bp, u16 ring_id, u8 ring_type)
static int wait_resp(struct bnxt *bp, u32 tmo, u16 len, const char *func)
static void short_hwrm_cmd_req(struct bnxt *bp, u16 len)
static void bnxt_er_task_timer(struct retry_timer *timer, int over __unused)
static int bnxt_hwrm_ring_free_nq(struct bnxt *bp)
u32 bnxt_er_get_reg_val(struct bnxt *bp, u32 reg_addr, u32 reg_type, u32 mask)
static void bnxt_set_link(struct bnxt *bp)
static u32 bnxt_set_ring_info(struct bnxt *bp)
int bnxt_post_rx_buffers(struct bnxt *bp)
void bnxt_free_rings_mem(struct bnxt *bp)
static int bnxt_hwrm_vnic_free(struct bnxt *bp)
static int bnxt_hwrm_port_mac_cfg(struct bnxt *bp)
void bnxt_add_vlan(struct io_buffer *iob, u16 vlan)
void bnxt_rst_reg_val(struct bnxt *bp, u32 reg_addr, u32 reg_val)
static void * bnxt_pci_base(struct pci_device *pdev, unsigned int reg)
static int bnxt_hwrm_nvm_get_variable_req(struct bnxt *bp, u16 data_len, u16 option_num, u16 dimensions, u16 index_0)
static void bnxt_db_tx(struct bnxt *bp, u32 idx)
void bnxt_link_speed_chg_evt(struct bnxt *bp, struct hwrm_async_event_cmpl *evt)
int bnxt_alloc_hwrm_mem(struct bnxt *bp)
void bnxt_mm_init_rings(struct bnxt *bp, const char *func)
static struct pci_device_id bnxt_nics[]
static int bnxt_set_rx_mask(struct bnxt *bp)
void bnxt_process_er_event(struct bnxt *bp, struct hwrm_async_event_cmpl *evt)
static struct net_device_operations bnxt_netdev_ops
static void bnxt_set_rx_desc(u8 *buf, struct io_buffer *iob, u16 cid, u32 idx)
static int bnxt_hwrm_ring_free_tx(struct bnxt *bp)
static void bnxt_hwrm_assign_resources(struct bnxt *bp)
int(* hwrm_func_t)(struct bnxt *bp)
static int bnxt_init_one(struct pci_device *pci)
#define BNXT_REG_WINDOW_BASE
hwrm_func_t bring_up_init[]
void bnxt_port_phy_chg_evt(struct bnxt *bp, struct hwrm_async_event_cmpl *evt)
static void bnxt_adv_nq_index(struct bnxt *bp, u16 cnt)
void bnxt_rx_process(struct net_device *dev, struct bnxt *bp, struct rx_pkt_cmpl *rx_cmp, struct rx_pkt_cmpl_hi *rx_cmp_hi)
static int bnxt_get_device_address(struct bnxt *bp)
#define bnxt_down_nic(bp)
static int bnxt_hwrm_vnic_cfg(struct bnxt *bp)
static int bnxt_hwrm_func_drv_unrgtr(struct bnxt *bp)
static int bnxt_hwrm_port_phy_cfg(struct bnxt *bp)
static int bnxt_hwrm_func_cfg_req(struct bnxt *bp)
static void dev_p7_db(struct bnxt *bp, u32 idx, u32 xid, u32 flag, u32 epoch, u32 toggle)
void bnxt_mm_nic(struct bnxt *bp)
static int bnxt_hwrm_ring_alloc_cq(struct bnxt *bp)
static int bnxt_hwrm_func_qcaps_req(struct bnxt *bp)
static void bnxt_tx_complete(struct net_device *dev, u16 hw_idx)
void bnxt_link_evt(struct bnxt *bp, struct hwrm_async_event_cmpl *evt)
static void hwrm_init(struct bnxt *bp, struct input *req, u16 cmd, u16 len)
static void bnxt_er_wait_timer(struct retry_timer *timer, int over __unused)
static int bnxt_hwrm_port_phy_qcaps_req(struct bnxt *bp)
u32 set_rx_mask(u32 rx_mask)
static int bnxt_hwrm_port_phy_qcfg(struct bnxt *bp, u16 idx)
static void bnxt_service_nq(struct net_device *dev)
static int bnxt_hwrm_set_async_event(struct bnxt *bp)
static int bnxt_hwrm_ring_free_rx(struct bnxt *bp)
static void hwrm_write_req(struct bnxt *bp, void *req, u32 cnt)
static int bnxt_get_phy_link(struct bnxt *bp)
static int bnxt_rx_complete(struct net_device *dev, struct rx_pkt_cmpl *rx)
static int bnxt_hwrm_ring_alloc(struct bnxt *bp, u8 type)
static int bnxt_hwrm_func_reset_req(struct bnxt *bp)
static void bnxt_remove_one(struct pci_device *pci)
static int bnxt_query_phy_link(struct bnxt *bp)
u32 bnxt_er_reg_write(struct bnxt *bp, u32 reg_addr, u32 reg_val)
static void dev_p5_db(struct bnxt *bp, u32 idx, u32 xid, u32 flag)
static int bnxt_hwrm_stat_ctx_alloc(struct bnxt *bp)
static void bnxt_adv_cq_index(struct bnxt *bp, u16 cnt)
u8 bnxt_rx_drop(struct bnxt *bp, struct io_buffer *iob, struct rx_pkt_cmpl *rx_cmp, struct rx_pkt_cmpl_hi *rx_cmp_hi, u16 rx_len)
static u16 bnxt_get_pkt_vlan(char *src)
void bnxt_free_hwrm_mem(struct bnxt *bp)
void bnxt_process_reset_notify_event(struct bnxt *bp, struct hwrm_async_event_cmpl *evt)
int bnxt_hwrm_run(hwrm_func_t cmds[], struct bnxt *bp)
#define DEFAULT_NUMBER_OF_STAT_CTXS
#define LINK_SPEED_FW_40G
#define SET_MEDIUM_SPEED(bp, s)
#define PORT_CFG_LINK_SETTINGS_MEDIA_AUTO_DETECT_NUM
#define LINK_SPEED_FW_100G_PAM4
#define GET_MEDIUM_SPEED(m)
#define MEDIUM_SPEED_25GBPS
#define CMPL_BASE_TYPE_TX_L2
#define IPXE_VERSION_UPDATE
#define RING_FREE(bp, rid, flag)
#define MEDIA_AUTO_DETECT_MASK
#define D3_SPEED_FW_SHIFT
#define SET_MEDIUM_DUPLEX(bp, d)
#define FW_STATUS_REG_CODE_READY
#define NQ_CN_TOGGLE_MASK
#define HWRM_CMD_DEFAULT_TIMEOUT
#define MEDIUM_SPEED_400PAM4_112GBPS
#define MEDIUM_SPEED_50PAM4GBPS
#define CMPL_BASE_TYPE_RX_L2_V3
#define TX_RING_BUFFER_SIZE
#define SERVICE_NEXT_NQ_BD
#define SHORT_CMD_SUPPORTED
#define BD_NOW(bd, entry, len)
#define LINK_SPEED_DRV_NUM
#define STATUS_LINK_ACTIVE
#define DEFAULT_NUMBER_OF_RING_GRPS
#define RX_PKT_V3_CMPL_TYPE_RX_L2_V3
#define DEFAULT_NUMBER_OF_TX_RINGS
#define BNXT_CQ_INTR_MODE(vf)
#define IPXE_VERSION_MINOR
#define LINK_SPEED_FW_AUTONEG
#define TX_BD_SHORT_FLAGS_LHINT_GTE2K
#define RX_RING_BUFFER_SIZE
#define MEDIUM_SPEED_200PAM4_112GBPS
#define SET_LINK(p, m, s)
#define RX_MASK_ACCEPT_ALL_MULTICAST
#define NQ_RING_BUFFER_SIZE
#define BNXT_RX_STD_DMA_SZ
#define DBC_MSG_XID(xid, flg)
#define LINK_SPEED_FW_10G
#define TX_DOORBELL_KEY_TX
#define MEDIUM_SPEED_100PAM4_112GBPS
#define MEDIUM_SPEED_400PAM4GBPS
#define RX_MASK_ACCEPT_MULTICAST
#define CMPL_BASE_TYPE_HWRM_ASYNC_EVENT
#define CMPL_BASE_TYPE_MASK
#define BNXT_ER_TIMER_INTERVAL(x)
#define CQ_DOORBELL_KEY_IDX(a)
#define LINK_SPEED_FW_50G
#define PCICFG_ME_REGISTER
#define ER_DFLT_FW_RST_MAX_DSECS
#define CMPL_BASE_TYPE_RX_L2
#define LINK_SPEED_FW_MASK
#define MAX_ETHERNET_PACKET_BUFFER_SIZE
#define LINK_SPEED_FW_2_5G
#define TX_BD_SHORT_FLAGS_LHINT_LT512
#define LINK_SPEED_FW_50G_PAM4
#define TX_BD_SHORT_FLAGS_LHINT_LT2K
#define NO_MORE_CQ_BD_TO_SERVICE
#define DEFAULT_NUMBER_OF_RX_RINGS
#define RX_PKT_CMPL_ERRORS_BUFFER_ERROR_SFT
#define BNXT_FLAG_IS_CHIP_P5_PLUS
#define D3_LINK_SPEED_FW_NUM
#define LINK_SPEED_FW_NUM
#define MEDIUM_SPEED_100GBPS
#define MEDIUM_FULL_DUPLEX
#define NQ_CN_TYPE_CQ_NOTIFICATION
#define BNXT_FLAG_NPAR_MODE
#define NO_MORE_NQ_BD_TO_SERVICE
#define MEDIUM_SPEED_40GBPS
#define TX_IN_USE(a, b, c)
#define VF_CFG_ENABLE_FLAGS
#define LINK_POLL_WAIT_TIME
#define DBC_MSG_EPCH(idx)
#define RX_MASK_PROMISCUOUS_MODE
#define BNXT_FLAG_RESOURCE_QCAPS_SUPPORT
#define SERVICE_NEXT_CQ_BD
#define RX_PKT_V3_CMPL_TYPE_MASK
#define HWRM_CMD_FLASH_MULTIPLAYER(a)
#define RX_PROD_PKT_BD_TYPE_RX_PROD_PKT
#define RESP_DMA_ADDR(bp)
#define DBC_MSG_TOGGLE(idx)
#define SHORT_CMD_REQUIRED
#define TX_BD_SHORT_FLAGS_LHINT_LT1K
#define RX_PKT_V3_CMPL_HI_ERRORS_BUFFER_ERROR_SFT
#define MEDIUM_SPEED_200GBPS
#define MEDIUM_SPEED_100PAM4GBPS
#define LINK_SPEED_FW_400G_PAM4
#define MEDIUM_SPEED_50GBPS
#define HWRM_CMD_POLL_WAIT_TIME
#define LINK_SPEED_FW_100G
#define LINK_SPEED_FW_200G
#define LINK_DEFAULT_TIMEOUT
#define LINK_SPEED_FW_200G_PAM4_112
#define LINK_SPEED_FW_100G_PAM4_112
#define BNXT_FLAG_IS_CHIP_P5
#define DBC_DBC_TYPE_NQ_ARM
#define CQ_RING_BUFFER_SIZE
#define BNXT_FLAG_IS_CHIP_P7
#define CMPL_DOORBELL_KEY_CMPL
#define RX_DOORBELL_KEY_RX
#define BNXT_FLAG_LINK_SPEEDS2
#define CMPL_BASE_TYPE_STAT_EJECT
#define MEDIUM_SPEED_1000MBPS
#define MEDIUM_SPEED_10GBPS
#define BNXT_DMA_ALIGNMENT
#define MEDIUM_SPEED_2500MBPS
#define BNXT_FLAG_MULTI_HOST
#define ER_DFLT_FW_RST_MIN_DSECS
#define MEDIUM_SPEED_AUTONEG
#define LINK_SPEED_FW_400G_PAM4_112
#define GRC_COM_CHAN_BASE
#define RX_MASK_ACCEPT_NONE
#define HWRM_CMD_DEFAULT_MULTIPLAYER(a)
#define BNXT_FLAG_HWRM_SHORT_CMD_SUPP
#define LINK_SPEED_FW_25G
#define IPXE_VERSION_MAJOR
#define DEFAULT_NUMBER_OF_CMPL_RINGS
#define BNXT_ER_WAIT_TIMER_INTERVAL(x)
#define GRC_COM_CHAN_TRIG
#define MEDIA_AUTO_DETECT_SHIFT
#define dbg_rx_cid(idx, cid)
#define dump_evt(cq, ty, id, ring)
#define dbg_alloc_rx_iob_fail(iob_idx, cons_id)
#define dbg_hw_cmd(bp, func, cmd_len, resp_len, cmd_tmo, err)
#define dbg_pci(bp, func, creg)
#define dbg_alloc_rx_iob(iob, id, cid)
#define dbg_tx_avail(bp, a, u)
#define dbg_tx_done(pkt, len, idx)
#define dbg_fw_ver(resp, tmo)
#define dbg_func_qcaps(bp)
#define dump_cq(cq, id, toggle)
#define dbg_link_state(bp, tmo)
#define dbg_tx_vlan(bp, src, plen, len)
#define dbg_func_qcfg(bp)
#define prn_set_speed(speed)
#define dbg_mem(bp, func)
#define dbg_rxp(iob, rx_len, drop)
#define dbg_link_info(bp)
#define dbg_flags(func, flags)
#define dbg_func_resource_qcaps(bp)
#define dbg_short_cmd(sreq, func, len)
#define dbg_link_status(bp)
#define dbg_num_rings(bp)
#define dump_tx_pkt(pkt, len, idx)
#define dump_rx_bd(rx_cmp, rx_cmp_hi, desc_idx)
#define dbg_chip_info(bp)
#define ASYNC_EVENT_CMPL_LINK_SPEED_CFG_CHANGE_SUPPORTED_LINK_SPEEDS_CHANGE
#define ASYNC_EVENT_CMPL_ER_EVENT_DATA1_MASTER_FUNC
#define VNIC_ALLOC_REQ_FLAGS_DEFAULT
#define ASYNC_EVENT_CMPL_LINK_SPEED_CHANGE_FORCE
#define CFA_L2_FILTER_ALLOC_REQ_SRC_TYPE_NPORT
#define ASYNC_EVENT_CMPL_EVENT_ID_LINK_SPEED_CFG_CHANGE
#define PORT_MAC_CFG_REQ_LPBK_NONE
#define PORT_PHY_CFG_REQ_AUTO_PAUSE_TX
#define FUNC_CFG_REQ_ENABLES_NUM_HW_RING_GRPS
#define PORT_PHY_CFG_REQ_FORCE_PAM4_LINK_SPEED_50GB
#define ASYNC_EVENT_CMPL_EVENT_ID_ERROR_RECOVERY
#define FUNC_CFG_REQ_ENABLES_NUM_MSIX
#define ER_QCFG_FW_HEALTH_REG_ADDR_SPACE_MASK
#define PORT_PHY_CFG_REQ_FORCE_LINK_SPEEDS2_50GB_PAM4_56
#define PORT_PHY_CFG_REQ_ENABLES_FORCE_LINK_SPEEDS2
#define PORT_PHY_CFG_REQ_FLAGS_RESET_PHY
#define ASYNC_EVENT_CMPL_PORT_PHY_CFG_CHANGE_FEC_CFG_CHANGE
#define ER_QCFG_FW_HEALTH_REG_ADDR_SPACE_BAR1
#define ER_QCFG_FW_HEALTH_REG_ADDR_SPACE_PCIE_CFG
#define HWRM_VERSION_MINOR
#define HWRM_CFA_L2_FILTER_FREE
#define PORT_PHY_CFG_REQ_FORCE_LINK_SPEEDS2_100GB_PAM4_112
#define PORT_PHY_CFG_REQ_ENABLES_AUTO_DUPLEX
#define RING_FREE_REQ_RING_TYPE_NQ
#define HWRM_PORT_PHY_CFG
#define PORT_PHY_CFG_REQ_FORCE_LINK_SPEEDS2_200GB_PAM4_112
#define CFA_L2_SET_RX_MASK_REQ_MASK_BCAST
#define FUNC_QCFG_RESP_FLAGS_MULTI_HOST
#define PORT_PHY_CFG_REQ_FORCE_LINK_SPEEDS2_200GB_PAM4_56
#define ASYNC_EVENT_CMPL_EVENT_ID_PORT_PHY_CFG_CHANGE
#define ASYNC_EVENT_CMPL_PORT_PHY_CFG_CHANGE_PAUSE_CFG_CHANGE
#define RING_ALLOC_REQ_INT_MODE_POLL
#define HWRM_PORT_PHY_QCAPS
#define ER_QCFG_RESET_REG_ADDR_MASK
#define RING_ALLOC_REQ_RING_TYPE_RX
#define PORT_PHY_CFG_REQ_FORCE_LINK_SPEEDS2_50GB
#define ASYNC_EVENT_CMPL_EVENT_DATA1_REASON_CODE_MASK
#define ASYNC_EVENT_CMPL_EVENT_ID_RESET_NOTIFY
#define CFA_L2_FILTER_ALLOC_REQ_ENABLES_L2_ADDR_MASK
#define PORT_PHY_CFG_REQ_FORCE_LINK_SPEEDS2_100GB_PAM4_56
#define HWRM_FUNC_RESOURCE_QCAPS
#define VNIC_CFG_REQ_ENABLES_DFLT_RING_GRP
#define PORT_PHY_CFG_REQ_FORCE_LINK_SPEED_25GB
#define ASYNC_EVENT_CMPL_ER_EVENT_DATA1_RECOVERY_ENABLED
#define ER_QCFG_FW_HEALTH_REG_ADDR_MASK
#define FUNC_CFG_REQ_ENABLES_NUM_RX_RINGS
#define PORT_PHY_CFG_REQ_FORCE_LINK_SPEED_1GB
#define PORT_PHY_CFG_REQ_FORCE_LINK_SPEED_40GB
#define PORT_PHY_CFG_REQ_AUTO_PAUSE_RX
#define ER_QCFG_FW_HB_REG_ADDR_MASK
#define PORT_PHY_CFG_REQ_FORCE_LINK_SPEEDS2_40GB
#define VNIC_CFG_REQ_ENABLES_DEFAULT_CMPL_RING_ID
#define RING_FREE_REQ_RING_TYPE_L2_CMPL
#define FUNC_DRV_RGTR_REQ_FLAGS_MASTER_SUPPORT
#define PORT_PHY_CFG_REQ_FORCE_LINK_SPEEDS2_400GB_PAM4_56
#define SHORT_REQ_SIGNATURE_SHORT_CMD
#define FUNC_CFG_REQ_EVB_MODE_NO_EVB
#define PORT_PHY_QCFG_RESP_LINK_LINK
#define FUNC_DRV_RGTR_REQ_ENABLES_VER
#define HWRM_CFA_L2_SET_RX_MASK
#define FUNC_DRV_UNRGTR_REQ_FLAGS_PREPARE_FOR_SHUTDOWN
#define CFA_L2_FILTER_ALLOC_REQ_FLAGS_OUTERMOST
#define FUNC_BACKING_STORE_CFG_REQ_FLAGS_PREBOOT_MODE
#define HWRM_NVM_GET_VARIABLE
#define FUNC_RESET_REQ_FUNC_RESET_LEVEL_RESETME
#define HWRM_FUNC_BACKING_STORE_QCFG
#define FUNC_QCFG_RESP_PORT_PARTITION_TYPE_NPAR1_0
#define HWRM_RING_GRP_ALLOC
#define CFA_L2_SET_RX_MASK_REQ_MASK_MCAST
#define RING_ALLOC_REQ_RING_TYPE_NQ
#define HWRM_QUEUE_QPORTCFG
#define HWRM_FUNC_DRV_UNRGTR
#define PORT_PHY_CFG_REQ_ENABLES_AUTO_PAUSE
#define PORT_PHY_CFG_REQ_ENABLES_AUTO_LINK_SPEED_MASK
#define PORT_PHY_CFG_REQ_ENABLES_AUTO_MODE
#define CFA_L2_SET_RX_MASK_REQ_MASK_PROMISCUOUS
#define HWRM_FUNC_DRV_RGTR
#define PORT_PHY_CFG_REQ_FORCE_LINK_SPEEDS2_400GB_PAM4_112
#define HWRM_PORT_MAC_CFG
#define HWRM_VERSION_MAJOR
#define ASYNC_EVENT_CMPL_PORT_PHY_CFG_CHANGE_EEE_CFG_CHANGE
#define PORT_PHY_CFG_REQ_FORCE_LINK_SPEED_100GB
#define ER_QCFG_RESET_INPRG_REG_ADDR_SPACE_MASK
#define RING_FREE_REQ_RING_TYPE_TX
#define RING_ALLOC_REQ_RING_TYPE_TX
#define PORT_PHY_CFG_REQ_FORCE_PAM4_LINK_SPEED_200GB
#define FUNC_DRV_RGTR_REQ_ENABLES_ASYNC_EVENT_FWD
#define FUNC_CFG_REQ_ENABLES_ASYNC_EVENT_CR
#define FUNC_DRV_RGTR_REQ_OS_TYPE_OTHER
#define CFA_L2_FILTER_ALLOC_REQ_FLAGS_PATH_RX
#define FUNC_CFG_REQ_ENABLES_EVB_MODE
#define ER_QCFG_FW_HEALTH_REG_ADDR_SPACE_GRC
#define FUNC_DRV_RGTR_REQ_FLAGS_ERROR_RECOVERY_SUPPORT
#define PORT_PHY_CFG_REQ_FORCE_LINK_SPEEDS2_10GB
#define PORT_PHY_CFG_REQ_AUTO_DUPLEX_BOTH
#define HWRM_VERSION_UPDATE
#define RING_ALLOC_REQ_RING_TYPE_L2_CMPL
#define HWRM_PORT_PHY_QCFG
#define FUNC_CFG_REQ_ENABLES_NUM_STAT_CTXS
#define PORT_PHY_CFG_REQ_FORCE_LINK_SPEED_50GB
#define HWRM_CFA_L2_FILTER_ALLOC
#define ER_QCFG_RESET_INPRG_REG_ADDR_MASK
#define PORT_PHY_CFG_REQ_FORCE_LINK_SPEEDS2_25GB
#define FUNC_QCAPS_OUTPUT_FLAGS_ERROR_RECOVERY_CAPABLE
#define PORT_PHY_CFG_REQ_ENABLES_AUTO_LINK_SPEEDS2_MASK
#define ASYNC_EVENT_CMPL_LINK_SPEED_CHANGE_MASK
#define ASYNC_EVENT_CMPL_LINK_SPEED_CFG_CHANGE_ILLEGAL_LINK_SPEED_CFG
#define ASYNC_EVENT_CMPL_EVENT_ID_LINK_STATUS_CHANGE
#define HWRM_FUNC_BACKING_STORE_CFG
#define FUNC_DRV_RGTR_REQ_FLAGS_16BIT_VER_MODE
#define HWRM_NA_SIGNATURE
#define VNIC_CFG_REQ_ENABLES_MRU
#define ER_QCFG_FW_HB_REG_ADDR_SPACE_MASK
#define CFA_L2_FILTER_ALLOC_REQ_ENABLES_L2_ADDR
#define VNIC_CFG_REQ_ENABLES_DEFAULT_RX_RING_ID
#define PORT_PHY_CFG_REQ_AUTO_MODE_SPEED_MASK
#define PORT_PHY_CFG_REQ_ENABLES_FORCE_PAM4_LINK_SPEED
#define CFA_L2_SET_RX_MASK_REQ_MASK_ALL_MCAST
#define FUNC_CFG_REQ_ENABLES_NUM_VNICS
#define ER_QCFG_RCVRY_CNT_REG_ADDR_SPACE_MASK
#define PORT_PHY_CFG_REQ_FORCE_LINK_SPEEDS2_100GB
#define ASYNC_EVENT_CMPL_EVENT_DATA1_REASON_CODE_FATAL
#define PORT_PHY_CFG_REQ_FLAGS_FORCE
#define RING_ALLOC_REQ_ENABLES_NQ_RING_ID_VALID
#define ER_QCFG_RESET_REG_ADDR_SPACE_MASK
#define RING_FREE_REQ_RING_TYPE_RX
#define FUNC_CFG_REQ_ENABLES_NUM_TX_RINGS
#define ER_QCFG_FW_RESET_CNT_REG_ADDR_SPACE_MASK
#define CFA_L2_FILTER_ALLOC_REQ_ENABLES_DST_ID
#define HWRM_STAT_CTX_ALLOC
#define PORT_PHY_QCAPS_RESP_FLAGS2_SPEEDS2_SUPPORTED
#define FUNC_CFG_REQ_ENABLES_NUM_CMPL_RINGS
#define PORT_PHY_CFG_REQ_FORCE_PAM4_LINK_SPEED_100GB
#define ER_QCFG_FW_HEALTH_REG_ADDR_SPACE_BAR0
#define ASYNC_EVENT_CMPL_EVENT_ID_LINK_SPEED_CHANGE
#define ER_QCFG_RCVRY_CNT_REG_ADDR_MASK
#define FUNC_DRV_RGTR_REQ_ENABLES_OS_TYPE
#define HWRM_STAT_CTX_FREE
#define HWRM_RING_GRP_FREE
#define ER_QCFG_FW_RESET_CNT_REG_ADDR_MASK
#define RING_ALLOC_REQ_ENABLES_RX_BUF_SIZE_VALID
#define PORT_PHY_CFG_REQ_FORCE_LINK_SPEED_10GB
struct bofm_section_header done
uint32_t type
Operating system type.
struct ena_llq_option desc
Descriptor counts.
struct net_device * alloc_etherdev(size_t priv_size)
Allocate Ethernet device.
static int is_valid_ether_addr(const void *addr)
Check if Ethernet address is valid.
static struct net_device * netdev
#define __unused
Declare a variable or data structure as unused.
#define FILE_LICENCE(_licence)
Declare a particular licence as applying to a file.
#define EINVAL
Invalid argument.
#define ENOMEM
Not enough space.
#define EBUSY
Device or resource busy.
#define ENOBUFS
No buffer space available.
#define barrier()
Optimisation barrier.
void mb(void)
Memory barrier.
#define writeq(data, io_addr)
void iounmap(volatile const void *io_addr)
Unmap I/O address.
int pci_read_config_dword(struct pci_device *pci, unsigned int where, uint32_t *value)
Read 32-bit dword from PCI configuration space.
int pci_read_config_word(struct pci_device *pci, unsigned int where, uint16_t *value)
Read 16-bit word from PCI configuration space.
void * pci_ioremap(struct pci_device *pci, unsigned long bus_addr, size_t len)
Map PCI bus address as an I/O address.
int pci_write_config_word(struct pci_device *pci, unsigned int where, uint16_t value)
Write 16-bit word to PCI configuration space.
int pci_read_config_byte(struct pci_device *pci, unsigned int where, uint8_t *value)
Read byte from PCI configuration space.
int pci_write_config_dword(struct pci_device *pci, unsigned int where, uint32_t value)
Write 32-bit dword to PCI configuration space.
void * memcpy(void *dest, const void *src, size_t len) __nonnull
void * memset(void *dest, int character, size_t len) __nonnull
void * memmove(void *dest, const void *src, size_t len) __nonnull
struct io_buffer * alloc_rx_iob(size_t len, struct dma_device *dma)
Allocate and map I/O buffer for receive DMA.
void free_rx_iob(struct io_buffer *iobuf)
Unmap and free I/O buffer for receive DMA.
#define iob_put(iobuf, len)
static __always_inline physaddr_t iob_dma(struct io_buffer *iobuf)
Get I/O buffer DMA address.
static size_t iob_len(struct io_buffer *iobuf)
Calculate length of data in an I/O buffer.
void dma_free(struct dma_mapping *map, void *addr, size_t len)
Unmap and free DMA-coherent buffer.
void * dma_alloc(struct dma_device *dma, struct dma_mapping *map, size_t len, size_t align)
Allocate and map DMA-coherent buffer.
Dynamic memory allocation.
Media Independent Interface constants.
static unsigned int unsigned int reg
void netdev_link_down(struct net_device *netdev)
Mark network device as having link down.
void netdev_rx(struct net_device *netdev, struct io_buffer *iobuf)
Add packet to receive queue.
void unregister_netdev(struct net_device *netdev)
Unregister network device.
void netdev_rx_err(struct net_device *netdev, struct io_buffer *iobuf, int rc)
Discard received packet.
int register_netdev(struct net_device *netdev)
Register network device.
Network device management.
static void netdev_link_up(struct net_device *netdev)
Mark network device as having link up.
static void netdev_init(struct net_device *netdev, struct net_device_operations *op)
Initialise a network device.
static void netdev_nullify(struct net_device *netdev)
Stop using a network device.
static void netdev_put(struct net_device *netdev)
Drop reference to network device.
static void netdev_tx_complete(struct net_device *netdev, struct io_buffer *iobuf)
Complete network transmission.
unsigned long pci_bar_size(struct pci_device *pci, unsigned int reg)
Get the size of a PCI BAR.
void adjust_pci_device(struct pci_device *pci)
Enable PCI device.
unsigned long pci_bar_start(struct pci_device *pci, unsigned int reg)
Find the start of a PCI BAR.
#define __pci_driver
Declare a PCI driver.
#define PCI_SUBSYSTEM_ID
PCI subsystem ID.
#define PCI_COMMAND_MASTER
Bus master.
#define PCI_BASE_ADDRESS_2
static void pci_set_drvdata(struct pci_device *pci, void *priv)
Set PCI driver-private data.
#define PCI_ROM(_vendor, _device, _name, _description, _data)
#define PCI_COMMAND_INTX_DISABLE
Interrupt disable.
#define PCI_BASE_ADDRESS_0
static void * pci_get_drvdata(struct pci_device *pci)
Get PCI driver-private data.
#define PCI_COMMAND
PCI command.
#define PCI_BASE_ADDRESS_4
#define PCI_SUBSYSTEM_VENDOR_ID
PCI subsystem vendor ID.
void start_timer_fixed(struct retry_timer *timer, unsigned long timeout)
Start timer with a specified timeout.
void stop_timer(struct retry_timer *timer)
Stop timer.
#define container_of(ptr, type, field)
Get containing structure.
struct retry_timer wait_timer
struct retry_timer task_timer
__le32 reset_inprogress_reg_mask
__le32 normal_wait_period
__le32 master_wait_period
__le32 master_wait_post_reset
__le32 driver_polling_freq
__le32 fw_health_status_reg
__le32 err_recovery_cnt_reg
__le32 reset_inprogress_reg
__le16 vf_reservation_strategy
void * data
Start of data.
Network device operations.
void * priv
Driver private data.
struct device * dev
Underlying hardware device.
A PCI device ID list entry.
unsigned long driver_data
Arbitrary driver data.
struct device dev
Generic device.
struct pci_device_id * id
Driver device ID.
struct dma_device dma
DMA device.
void mdelay(unsigned long msecs)
Delay for a fixed number of milliseconds.
void udelay(unsigned long usecs)
Delay for a fixed number of microseconds.
uint32_t data_len
Microcode data size (or 0 to indicate 2000 bytes)
u8 tx[WPA_TKIP_MIC_KEY_LEN]
MIC key for packets to the AP.
u8 rx[WPA_TKIP_MIC_KEY_LEN]
MIC key for packets from the AP.