bnxt.h (d5430d31ca72ec37fd539fd1c5230859509be4ef) | bnxt.h (2ae7408fedfee979e01ed3801223c632bb124c46) |
---|---|
1/* Broadcom NetXtreme-C/E network driver. 2 * 3 * Copyright (c) 2014-2016 Broadcom Corporation 4 * Copyright (c) 2016-2017 Broadcom Limited 5 * 6 * This program is free software; you can redistribute it and/or modify 7 * it under the terms of the GNU General Public License as published by 8 * the Free Software Foundation. --- 5 unchanged lines hidden (view full) --- 14#define DRV_MODULE_NAME "bnxt_en" 15#define DRV_MODULE_VERSION "1.8.0" 16 17#define DRV_VER_MAJ 1 18#define DRV_VER_MIN 8 19#define DRV_VER_UPD 0 20 21#include <linux/interrupt.h> | 1/* Broadcom NetXtreme-C/E network driver. 2 * 3 * Copyright (c) 2014-2016 Broadcom Corporation 4 * Copyright (c) 2016-2017 Broadcom Limited 5 * 6 * This program is free software; you can redistribute it and/or modify 7 * it under the terms of the GNU General Public License as published by 8 * the Free Software Foundation. --- 5 unchanged lines hidden (view full) --- 14#define DRV_MODULE_NAME "bnxt_en" 15#define DRV_MODULE_VERSION "1.8.0" 16 17#define DRV_VER_MAJ 1 18#define DRV_VER_MIN 8 19#define DRV_VER_UPD 0 20 21#include <linux/interrupt.h> |
22#include <linux/rhashtable.h> |
|
22#include <net/devlink.h> 23#include <net/dst_metadata.h> 24#include <net/switchdev.h> 25 26struct tx_bd { 27 __le32 tx_bd_len_flags_type; 28 #define TX_BD_TYPE (0x3f << 0) 29 #define TX_BD_TYPE_SHORT_TX_BD (0x00 << 0) --- 908 unchanged lines hidden (view full) --- 938 u16 timeout; 939 char string[BNXT_MAX_TEST][ETH_GSTRING_LEN]; 940}; 941 942#define BNXT_GRCPF_REG_WINDOW_BASE_OUT 0x400 943#define BNXT_CAG_REG_LEGACY_INT_STATUS 0x4014 944#define BNXT_CAG_REG_BASE 0x300000 945 | 23#include <net/devlink.h> 24#include <net/dst_metadata.h> 25#include <net/switchdev.h> 26 27struct tx_bd { 28 __le32 tx_bd_len_flags_type; 29 #define TX_BD_TYPE (0x3f << 0) 30 #define TX_BD_TYPE_SHORT_TX_BD (0x00 << 0) --- 908 unchanged lines hidden (view full) --- 939 u16 timeout; 940 char string[BNXT_MAX_TEST][ETH_GSTRING_LEN]; 941}; 942 943#define BNXT_GRCPF_REG_WINDOW_BASE_OUT 0x400 944#define BNXT_CAG_REG_LEGACY_INT_STATUS 0x4014 945#define BNXT_CAG_REG_BASE 0x300000 946 |
947struct bnxt_tc_info { 948 bool enabled; 949 950 /* hash table to store TC offloaded flows */ 951 struct rhashtable flow_table; 952 struct rhashtable_params flow_ht_params; 953 954 /* hash table to store L2 keys of TC flows */ 955 struct rhashtable l2_table; 956 struct rhashtable_params l2_ht_params; 957 958 /* lock to atomically add/del an l2 node when a flow is 959 * added or deleted. 960 */ 961 struct mutex lock; 962 963 /* Stat counter mask (width) */ 964 u64 bytes_mask; 965 u64 packets_mask; 966}; 967 |
|
946struct bnxt_vf_rep_stats { 947 u64 packets; 948 u64 bytes; 949 u64 dropped; 950}; 951 952struct bnxt_vf_rep { 953 struct bnxt *bp; --- 330 unchanged lines hidden (view full) --- 1284 1285 struct bpf_prog *xdp_prog; 1286 1287 /* devlink interface and vf-rep structs */ 1288 struct devlink *dl; 1289 enum devlink_eswitch_mode eswitch_mode; 1290 struct bnxt_vf_rep **vf_reps; /* array of vf-rep ptrs */ 1291 u16 *cfa_code_map; /* cfa_code -> vf_idx map */ | 968struct bnxt_vf_rep_stats { 969 u64 packets; 970 u64 bytes; 971 u64 dropped; 972}; 973 974struct bnxt_vf_rep { 975 struct bnxt *bp; --- 330 unchanged lines hidden (view full) --- 1306 1307 struct bpf_prog *xdp_prog; 1308 1309 /* devlink interface and vf-rep structs */ 1310 struct devlink *dl; 1311 enum devlink_eswitch_mode eswitch_mode; 1312 struct bnxt_vf_rep **vf_reps; /* array of vf-rep ptrs */ 1313 u16 *cfa_code_map; /* cfa_code -> vf_idx map */ |
1314 struct bnxt_tc_info tc_info; |
|
1292}; 1293 1294#define BNXT_RX_STATS_OFFSET(counter) \ 1295 (offsetof(struct rx_port_stats, counter) / 8) 1296 1297#define BNXT_TX_STATS_OFFSET(counter) \ 1298 ((offsetof(struct tx_port_stats, counter) + \ 1299 sizeof(struct rx_port_stats) + 512) / 8) --- 68 unchanged lines hidden --- | 1315}; 1316 1317#define BNXT_RX_STATS_OFFSET(counter) \ 1318 (offsetof(struct rx_port_stats, counter) / 8) 1319 1320#define BNXT_TX_STATS_OFFSET(counter) \ 1321 ((offsetof(struct tx_port_stats, counter) + \ 1322 sizeof(struct rx_port_stats) + 512) / 8) --- 68 unchanged lines hidden --- |