aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/bfa/include
diff options
context:
space:
mode:
authorKrishna Gudipati <kgudipat@brocade.com>2010-03-05 22:38:07 -0500
committerJames Bottomley <James.Bottomley@suse.de>2010-03-07 02:40:13 -0500
commitca8b4327e405820966971236224db0e0724b5673 (patch)
tree26d7bc6337c6b13c25d46ae7162c724227da4c99 /drivers/scsi/bfa/include
parent0a4b1fc0b24fc7adbaf8413f2992ce1395991a78 (diff)
[SCSI] bfa: Modified the portstats get/clear logic
Modified the portstats get/clear logic for port physical/FCoE/QoS stats. Added more stats to FC Fixed some issues with FCoE stats collection. Signed-off-by: Krishna Gudipati <kgudipat@brocade.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Diffstat (limited to 'drivers/scsi/bfa/include')
-rw-r--r--drivers/scsi/bfa/include/bfa_svc.h24
-rw-r--r--drivers/scsi/bfa/include/bfi/bfi.h4
-rw-r--r--drivers/scsi/bfa/include/bfi/bfi_pport.h177
-rw-r--r--drivers/scsi/bfa/include/defs/bfa_defs_pport.h128
4 files changed, 135 insertions, 198 deletions
diff --git a/drivers/scsi/bfa/include/bfa_svc.h b/drivers/scsi/bfa/include/bfa_svc.h
index f2c30858900b..1349b99a3c6d 100644
--- a/drivers/scsi/bfa/include/bfa_svc.h
+++ b/drivers/scsi/bfa/include/bfa_svc.h
@@ -36,7 +36,7 @@ struct bfa_fcxp_s;
36struct bfa_rport_info_s { 36struct bfa_rport_info_s {
37 u16 max_frmsz; /* max rcv pdu size */ 37 u16 max_frmsz; /* max rcv pdu size */
38 u32 pid:24, /* remote port ID */ 38 u32 pid:24, /* remote port ID */
39 lp_tag:8; 39 lp_tag:8; /* tag */
40 u32 local_pid:24, /* local port ID */ 40 u32 local_pid:24, /* local port ID */
41 cisc:8; /* CIRO supported */ 41 cisc:8; /* CIRO supported */
42 u8 fc_class; /* supported FC classes. enum fc_cos */ 42 u8 fc_class; /* supported FC classes. enum fc_cos */
@@ -55,7 +55,7 @@ struct bfa_rport_s {
55 void *rport_drv; /* fcs/driver rport object */ 55 void *rport_drv; /* fcs/driver rport object */
56 u16 fw_handle; /* firmware rport handle */ 56 u16 fw_handle; /* firmware rport handle */
57 u16 rport_tag; /* BFA rport tag */ 57 u16 rport_tag; /* BFA rport tag */
58 struct bfa_rport_info_s rport_info; /* rport info from *fcs/driver */ 58 struct bfa_rport_info_s rport_info; /* rport info from fcs/driver */
59 struct bfa_reqq_wait_s reqq_wait; /* to wait for room in reqq */ 59 struct bfa_reqq_wait_s reqq_wait; /* to wait for room in reqq */
60 struct bfa_cb_qe_s hcb_qe; /* BFA callback qelem */ 60 struct bfa_cb_qe_s hcb_qe; /* BFA callback qelem */
61 struct bfa_rport_hal_stats_s stats; /* BFA rport statistics */ 61 struct bfa_rport_hal_stats_s stats; /* BFA rport statistics */
@@ -102,7 +102,7 @@ struct bfa_uf_buf_s {
102struct bfa_uf_s { 102struct bfa_uf_s {
103 struct list_head qe; /* queue element */ 103 struct list_head qe; /* queue element */
104 struct bfa_s *bfa; /* bfa instance */ 104 struct bfa_s *bfa; /* bfa instance */
105 u16 uf_tag; /* identifying tag f/w messages */ 105 u16 uf_tag; /* identifying tag fw msgs */
106 u16 vf_id; 106 u16 vf_id;
107 u16 src_rport_handle; 107 u16 src_rport_handle;
108 u16 rsvd; 108 u16 rsvd;
@@ -128,7 +128,7 @@ struct bfa_lps_s {
128 u8 reqq; /* lport request queue */ 128 u8 reqq; /* lport request queue */
129 u8 alpa; /* ALPA for loop topologies */ 129 u8 alpa; /* ALPA for loop topologies */
130 u32 lp_pid; /* lport port ID */ 130 u32 lp_pid; /* lport port ID */
131 bfa_boolean_t fdisc; /* send FDISC instead of FLOGI*/ 131 bfa_boolean_t fdisc; /* send FDISC instead of FLOGI */
132 bfa_boolean_t auth_en; /* enable authentication */ 132 bfa_boolean_t auth_en; /* enable authentication */
133 bfa_boolean_t auth_req; /* authentication required */ 133 bfa_boolean_t auth_req; /* authentication required */
134 bfa_boolean_t npiv_en; /* NPIV is allowed by peer */ 134 bfa_boolean_t npiv_en; /* NPIV is allowed by peer */
@@ -178,11 +178,6 @@ bfa_status_t bfa_fcport_trunk_disable(struct bfa_s *bfa);
178bfa_boolean_t bfa_fcport_trunk_query(struct bfa_s *bfa, u32 *bitmap); 178bfa_boolean_t bfa_fcport_trunk_query(struct bfa_s *bfa, u32 *bitmap);
179void bfa_fcport_get_attr(struct bfa_s *bfa, struct bfa_pport_attr_s *attr); 179void bfa_fcport_get_attr(struct bfa_s *bfa, struct bfa_pport_attr_s *attr);
180wwn_t bfa_fcport_get_wwn(struct bfa_s *bfa, bfa_boolean_t node); 180wwn_t bfa_fcport_get_wwn(struct bfa_s *bfa, bfa_boolean_t node);
181bfa_status_t bfa_pport_get_stats(struct bfa_s *bfa,
182 union bfa_pport_stats_u *stats,
183 bfa_cb_pport_t cbfn, void *cbarg);
184bfa_status_t bfa_pport_clear_stats(struct bfa_s *bfa, bfa_cb_pport_t cbfn,
185 void *cbarg);
186void bfa_fcport_event_register(struct bfa_s *bfa, 181void bfa_fcport_event_register(struct bfa_s *bfa,
187 void (*event_cbfn) (void *cbarg, 182 void (*event_cbfn) (void *cbarg,
188 bfa_pport_event_t event), void *event_cbarg); 183 bfa_pport_event_t event), void *event_cbarg);
@@ -198,14 +193,21 @@ void bfa_fcport_busy(struct bfa_s *bfa, bfa_boolean_t status);
198void bfa_fcport_beacon(struct bfa_s *bfa, bfa_boolean_t beacon, 193void bfa_fcport_beacon(struct bfa_s *bfa, bfa_boolean_t beacon,
199 bfa_boolean_t link_e2e_beacon); 194 bfa_boolean_t link_e2e_beacon);
200void bfa_cb_pport_event(void *cbarg, bfa_pport_event_t event); 195void bfa_cb_pport_event(void *cbarg, bfa_pport_event_t event);
201void bfa_fcport_qos_get_attr(struct bfa_s *bfa, struct bfa_qos_attr_s *qos_attr); 196void bfa_fcport_qos_get_attr(struct bfa_s *bfa,
197 struct bfa_qos_attr_s *qos_attr);
202void bfa_fcport_qos_get_vc_attr(struct bfa_s *bfa, 198void bfa_fcport_qos_get_vc_attr(struct bfa_s *bfa,
203 struct bfa_qos_vc_attr_s *qos_vc_attr); 199 struct bfa_qos_vc_attr_s *qos_vc_attr);
204bfa_status_t bfa_fcport_get_qos_stats(struct bfa_s *bfa, 200bfa_status_t bfa_fcport_get_qos_stats(struct bfa_s *bfa,
205 union bfa_pport_stats_u *stats, 201 union bfa_fcport_stats_u *stats,
206 bfa_cb_pport_t cbfn, void *cbarg); 202 bfa_cb_pport_t cbfn, void *cbarg);
207bfa_status_t bfa_fcport_clear_qos_stats(struct bfa_s *bfa, bfa_cb_pport_t cbfn, 203bfa_status_t bfa_fcport_clear_qos_stats(struct bfa_s *bfa, bfa_cb_pport_t cbfn,
208 void *cbarg); 204 void *cbarg);
205bfa_status_t bfa_fcport_get_fcoe_stats(struct bfa_s *bfa,
206 union bfa_fcport_stats_u *stats,
207 bfa_cb_pport_t cbfn, void *cbarg);
208bfa_status_t bfa_fcport_clear_fcoe_stats(struct bfa_s *bfa, bfa_cb_pport_t cbfn,
209 void *cbarg);
210
209bfa_boolean_t bfa_fcport_is_ratelim(struct bfa_s *bfa); 211bfa_boolean_t bfa_fcport_is_ratelim(struct bfa_s *bfa);
210bfa_boolean_t bfa_fcport_is_linkup(struct bfa_s *bfa); 212bfa_boolean_t bfa_fcport_is_linkup(struct bfa_s *bfa);
211bfa_status_t bfa_fcport_get_stats(struct bfa_s *bfa, 213bfa_status_t bfa_fcport_get_stats(struct bfa_s *bfa,
diff --git a/drivers/scsi/bfa/include/bfi/bfi.h b/drivers/scsi/bfa/include/bfi/bfi.h
index 7042c18e542d..a550e80cabd2 100644
--- a/drivers/scsi/bfa/include/bfi/bfi.h
+++ b/drivers/scsi/bfa/include/bfi/bfi.h
@@ -143,8 +143,8 @@ enum bfi_mclass {
143 BFI_MC_IOC = 1, /* IO Controller (IOC) */ 143 BFI_MC_IOC = 1, /* IO Controller (IOC) */
144 BFI_MC_DIAG = 2, /* Diagnostic Msgs */ 144 BFI_MC_DIAG = 2, /* Diagnostic Msgs */
145 BFI_MC_FLASH = 3, /* Flash message class */ 145 BFI_MC_FLASH = 3, /* Flash message class */
146 BFI_MC_CEE = 4, 146 BFI_MC_CEE = 4, /* CEE */
147 BFI_MC_FC_PORT = 5, /* FC port */ 147 BFI_MC_FCPORT = 5, /* FC port */
148 BFI_MC_IOCFC = 6, /* FC - IO Controller (IOC) */ 148 BFI_MC_IOCFC = 6, /* FC - IO Controller (IOC) */
149 BFI_MC_LL = 7, /* Link Layer */ 149 BFI_MC_LL = 7, /* Link Layer */
150 BFI_MC_UF = 8, /* Unsolicited frame receive */ 150 BFI_MC_UF = 8, /* Unsolicited frame receive */
diff --git a/drivers/scsi/bfa/include/bfi/bfi_pport.h b/drivers/scsi/bfa/include/bfi/bfi_pport.h
index 5c3d289d986d..50dcf45c7470 100644
--- a/drivers/scsi/bfa/include/bfi/bfi_pport.h
+++ b/drivers/scsi/bfa/include/bfi/bfi_pport.h
@@ -22,168 +22,97 @@
22 22
23#pragma pack(1) 23#pragma pack(1)
24 24
25enum bfi_pport_h2i { 25enum bfi_fcport_h2i {
26 BFI_PPORT_H2I_ENABLE_REQ = (1), 26 BFI_FCPORT_H2I_ENABLE_REQ = (1),
27 BFI_PPORT_H2I_DISABLE_REQ = (2), 27 BFI_FCPORT_H2I_DISABLE_REQ = (2),
28 BFI_PPORT_H2I_GET_STATS_REQ = (3), 28 BFI_FCPORT_H2I_SET_SVC_PARAMS_REQ = (3),
29 BFI_PPORT_H2I_CLEAR_STATS_REQ = (4), 29 BFI_FCPORT_H2I_STATS_GET_REQ = (4),
30 BFI_PPORT_H2I_SET_SVC_PARAMS_REQ = (5), 30 BFI_FCPORT_H2I_STATS_CLEAR_REQ = (5),
31 BFI_PPORT_H2I_ENABLE_RX_VF_TAG_REQ = (6),
32 BFI_PPORT_H2I_ENABLE_TX_VF_TAG_REQ = (7),
33 BFI_PPORT_H2I_GET_QOS_STATS_REQ = (8),
34 BFI_PPORT_H2I_CLEAR_QOS_STATS_REQ = (9),
35 BFI_FCPORT_H2I_GET_STATS_REQ = (10),
36 BFI_FCPORT_H2I_CLEAR_STATS_REQ = (11),
37}; 31};
38 32
39enum bfi_pport_i2h { 33enum bfi_fcport_i2h {
40 BFI_PPORT_I2H_ENABLE_RSP = BFA_I2HM(1), 34 BFI_FCPORT_I2H_ENABLE_RSP = BFA_I2HM(1),
41 BFI_PPORT_I2H_DISABLE_RSP = BFA_I2HM(2), 35 BFI_FCPORT_I2H_DISABLE_RSP = BFA_I2HM(2),
42 BFI_PPORT_I2H_GET_STATS_RSP = BFA_I2HM(3), 36 BFI_FCPORT_I2H_SET_SVC_PARAMS_RSP = BFA_I2HM(3),
43 BFI_PPORT_I2H_CLEAR_STATS_RSP = BFA_I2HM(4), 37 BFI_FCPORT_I2H_STATS_GET_RSP = BFA_I2HM(4),
44 BFI_PPORT_I2H_SET_SVC_PARAMS_RSP = BFA_I2HM(5), 38 BFI_FCPORT_I2H_STATS_CLEAR_RSP = BFA_I2HM(5),
45 BFI_PPORT_I2H_ENABLE_RX_VF_TAG_RSP = BFA_I2HM(6), 39 BFI_FCPORT_I2H_EVENT = BFA_I2HM(6),
46 BFI_PPORT_I2H_ENABLE_TX_VF_TAG_RSP = BFA_I2HM(7),
47 BFI_PPORT_I2H_EVENT = BFA_I2HM(8),
48 BFI_PPORT_I2H_GET_QOS_STATS_RSP = BFA_I2HM(9),
49 BFI_PPORT_I2H_CLEAR_QOS_STATS_RSP = BFA_I2HM(10),
50 BFI_FCPORT_I2H_GET_STATS_RSP = BFA_I2HM(11),
51 BFI_FCPORT_I2H_CLEAR_STATS_RSP = BFA_I2HM(12),
52}; 40};
53 41
54/** 42/**
55 * Generic REQ type 43 * Generic REQ type
56 */ 44 */
57struct bfi_pport_generic_req_s { 45struct bfi_fcport_req_s {
58 struct bfi_mhdr_s mh; /* msg header */ 46 struct bfi_mhdr_s mh; /* msg header */
59 u32 msgtag; /* msgtag for reply */ 47 u32 msgtag; /* msgtag for reply */
60}; 48};
61 49
62/** 50/**
63 * Generic RSP type 51 * Generic RSP type
64 */ 52 */
65struct bfi_pport_generic_rsp_s { 53struct bfi_fcport_rsp_s {
66 struct bfi_mhdr_s mh; /* common msg header */ 54 struct bfi_mhdr_s mh; /* common msg header */
67 u8 status; /* port enable status */ 55 u8 status; /* port enable status */
68 u8 rsvd[3]; 56 u8 rsvd[3];
69 u32 msgtag; /* msgtag for reply */ 57 u32 msgtag; /* msgtag for reply */
70}; 58};
71 59
72/** 60/**
73 * BFI_PPORT_H2I_ENABLE_REQ 61 * BFI_FCPORT_H2I_ENABLE_REQ
74 */ 62 */
75struct bfi_pport_enable_req_s { 63struct bfi_fcport_enable_req_s {
76 struct bfi_mhdr_s mh; /* msg header */ 64 struct bfi_mhdr_s mh; /* msg header */
77 u32 rsvd1; 65 u32 rsvd1;
78 wwn_t nwwn; /* node wwn of physical port */ 66 wwn_t nwwn; /* node wwn of physical port */
79 wwn_t pwwn; /* port wwn of physical port */ 67 wwn_t pwwn; /* port wwn of physical port */
80 struct bfa_pport_cfg_s port_cfg; /* port configuration */ 68 struct bfa_pport_cfg_s port_cfg; /* port configuration */
81 union bfi_addr_u stats_dma_addr; /* DMA address for stats */ 69 union bfi_addr_u stats_dma_addr; /* DMA address for stats */
82 union bfi_addr_u fcport_stats_dma_addr;/*!< DMA address for stats */ 70 u32 msgtag; /* msgtag for reply */
83 u32 msgtag; /* msgtag for reply */ 71 u32 rsvd2;
84 u32 rsvd2;
85}; 72};
86 73
87/** 74/**
88 * BFI_PPORT_I2H_ENABLE_RSP 75 * BFI_FCPORT_H2I_SET_SVC_PARAMS_REQ
89 */ 76 */
90#define bfi_pport_enable_rsp_t struct bfi_pport_generic_rsp_s 77struct bfi_fcport_set_svc_params_req_s {
91
92/**
93 * BFI_PPORT_H2I_DISABLE_REQ
94 */
95#define bfi_pport_disable_req_t struct bfi_pport_generic_req_s
96
97/**
98 * BFI_PPORT_I2H_DISABLE_RSP
99 */
100#define bfi_pport_disable_rsp_t struct bfi_pport_generic_rsp_s
101
102/**
103 * BFI_PPORT_H2I_GET_STATS_REQ
104 */
105#define bfi_pport_get_stats_req_t struct bfi_pport_generic_req_s
106
107/**
108 * BFI_PPORT_I2H_GET_STATS_RSP
109 */
110#define bfi_pport_get_stats_rsp_t struct bfi_pport_generic_rsp_s
111
112/**
113 * BFI_PPORT_H2I_CLEAR_STATS_REQ
114 */
115#define bfi_pport_clear_stats_req_t struct bfi_pport_generic_req_s
116
117/**
118 * BFI_PPORT_I2H_CLEAR_STATS_RSP
119 */
120#define bfi_pport_clear_stats_rsp_t struct bfi_pport_generic_rsp_s
121
122/**
123 * BFI_PPORT_H2I_GET_QOS_STATS_REQ
124 */
125#define bfi_pport_get_qos_stats_req_t struct bfi_pport_generic_req_s
126
127/**
128 * BFI_PPORT_H2I_GET_QOS_STATS_RSP
129 */
130#define bfi_pport_get_qos_stats_rsp_t struct bfi_pport_generic_rsp_s
131
132/**
133 * BFI_PPORT_H2I_CLEAR_QOS_STATS_REQ
134 */
135#define bfi_pport_clear_qos_stats_req_t struct bfi_pport_generic_req_s
136
137/**
138 * BFI_PPORT_H2I_CLEAR_QOS_STATS_RSP
139 */
140#define bfi_pport_clear_qos_stats_rsp_t struct bfi_pport_generic_rsp_s
141
142/**
143 * BFI_PPORT_H2I_SET_SVC_PARAMS_REQ
144 */
145struct bfi_pport_set_svc_params_req_s {
146 struct bfi_mhdr_s mh; /* msg header */ 78 struct bfi_mhdr_s mh; /* msg header */
147 u16 tx_bbcredit; /* Tx credits */ 79 u16 tx_bbcredit; /* Tx credits */
148 u16 rsvd; 80 u16 rsvd;
149}; 81};
150 82
151/** 83/**
152 * BFI_PPORT_I2H_SET_SVC_PARAMS_RSP 84 * BFI_FCPORT_I2H_EVENT
153 */
154
155/**
156 * BFI_PPORT_I2H_EVENT
157 */ 85 */
158struct bfi_pport_event_s { 86struct bfi_fcport_event_s {
159 struct bfi_mhdr_s mh; /* common msg header */ 87 struct bfi_mhdr_s mh; /* common msg header */
160 struct bfa_pport_link_s link_state; 88 struct bfa_pport_link_s link_state;
161}; 89};
162 90
163union bfi_pport_h2i_msg_u { 91/**
92 * fcport H2I message
93 */
94union bfi_fcport_h2i_msg_u {
164 struct bfi_mhdr_s *mhdr; 95 struct bfi_mhdr_s *mhdr;
165 struct bfi_pport_enable_req_s *penable; 96 struct bfi_fcport_enable_req_s *penable;
166 struct bfi_pport_generic_req_s *pdisable; 97 struct bfi_fcport_req_s *pdisable;
167 struct bfi_pport_generic_req_s *pgetstats; 98 struct bfi_fcport_set_svc_params_req_s *psetsvcparams;
168 struct bfi_pport_generic_req_s *pclearstats; 99 struct bfi_fcport_req_s *pstatsget;
169 struct bfi_pport_set_svc_params_req_s *psetsvcparams; 100 struct bfi_fcport_req_s *pstatsclear;
170 struct bfi_pport_get_qos_stats_req_s *pgetqosstats;
171 struct bfi_pport_generic_req_s *pclearqosstats;
172}; 101};
173 102
174union bfi_pport_i2h_msg_u { 103/**
104 * fcport I2H message
105 */
106union bfi_fcport_i2h_msg_u {
175 struct bfi_msg_s *msg; 107 struct bfi_msg_s *msg;
176 struct bfi_pport_generic_rsp_s *enable_rsp; 108 struct bfi_fcport_rsp_s *penable_rsp;
177 struct bfi_pport_disable_rsp_s *disable_rsp; 109 struct bfi_fcport_rsp_s *pdisable_rsp;
178 struct bfi_pport_generic_rsp_s *getstats_rsp; 110 struct bfi_fcport_rsp_s *psetsvcparams_rsp;
179 struct bfi_pport_clear_stats_rsp_s *clearstats_rsp; 111 struct bfi_fcport_rsp_s *pstatsget_rsp;
180 struct bfi_pport_set_svc_params_rsp_s *setsvcparasm_rsp; 112 struct bfi_fcport_rsp_s *pstatsclear_rsp;
181 struct bfi_pport_get_qos_stats_rsp_s *getqosstats_rsp; 113 struct bfi_fcport_event_s *event;
182 struct bfi_pport_clear_qos_stats_rsp_s *clearqosstats_rsp;
183 struct bfi_pport_event_s *event;
184}; 114};
185 115
186#pragma pack() 116#pragma pack()
187 117
188#endif /* __BFI_PPORT_H__ */ 118#endif /* __BFI_PPORT_H__ */
189
diff --git a/drivers/scsi/bfa/include/defs/bfa_defs_pport.h b/drivers/scsi/bfa/include/defs/bfa_defs_pport.h
index 164cfbef9b12..26e5cc78095d 100644
--- a/drivers/scsi/bfa/include/defs/bfa_defs_pport.h
+++ b/drivers/scsi/bfa/include/defs/bfa_defs_pport.h
@@ -240,73 +240,79 @@ struct bfa_pport_attr_s {
240 * FC Port statistics. 240 * FC Port statistics.
241 */ 241 */
242struct bfa_pport_fc_stats_s { 242struct bfa_pport_fc_stats_s {
243 u64 secs_reset; /* seconds since stats is reset */ 243 u64 secs_reset; /* Seconds since stats is reset */
244 u64 tx_frames; /* transmitted frames */ 244 u64 tx_frames; /* Tx frames */
245 u64 tx_words; /* transmitted words */ 245 u64 tx_words; /* Tx words */
246 u64 rx_frames; /* received frames */ 246 u64 tx_lip; /* TX LIP */
247 u64 rx_words; /* received words */ 247 u64 tx_nos; /* Tx NOS */
248 u64 lip_count; /* LIPs seen */ 248 u64 tx_ols; /* Tx OLS */
249 u64 nos_count; /* NOS count */ 249 u64 tx_lr; /* Tx LR */
250 u64 error_frames; /* errored frames */ 250 u64 tx_lrr; /* Tx LRR */
251 u64 dropped_frames; /* dropped frames */ 251 u64 rx_frames; /* Rx frames */
252 u64 link_failures; /* link failure count */ 252 u64 rx_words; /* Rx words */
253 u64 loss_of_syncs; /* loss of sync count */ 253 u64 lip_count; /* Rx LIP */
254 u64 loss_of_signals;/* loss of signal count */ 254 u64 nos_count; /* Rx NOS */
255 u64 primseq_errs; /* primitive sequence protocol */ 255 u64 ols_count; /* Rx OLS */
256 u64 bad_os_count; /* invalid ordered set */ 256 u64 lr_count; /* Rx LR */
257 u64 err_enc_out; /* Encoding error outside frame */ 257 u64 lrr_count; /* Rx LRR */
258 u64 invalid_crcs; /* frames received with invalid CRC*/ 258 u64 invalid_crcs; /* Rx CRC err frames */
259 u64 undersized_frm; /* undersized frames */ 259 u64 invalid_crc_gd_eof; /* Rx CRC err good EOF frames */
260 u64 oversized_frm; /* oversized frames */ 260 u64 undersized_frm; /* Rx undersized frames */
261 u64 bad_eof_frm; /* frames with bad EOF */ 261 u64 oversized_frm; /* Rx oversized frames */
262 struct bfa_qos_stats_s qos_stats; /* QoS statistics */ 262 u64 bad_eof_frm; /* Rx frames with bad EOF */
263 u64 error_frames; /* Errored frames */
264 u64 dropped_frames; /* Dropped frames */
265 u64 link_failures; /* Link Failure (LF) count */
266 u64 loss_of_syncs; /* Loss of sync count */
267 u64 loss_of_signals;/* Loss of signal count */
268 u64 primseq_errs; /* Primitive sequence protocol err. */
269 u64 bad_os_count; /* Invalid ordered sets */
270 u64 err_enc_out; /* Encoding err nonframe_8b10b */
271 u64 err_enc; /* Encoding err frame_8b10b */
263}; 272};
264 273
265/** 274/**
266 * Eth Port statistics. 275 * Eth Port statistics.
267 */ 276 */
268struct bfa_pport_eth_stats_s { 277struct bfa_pport_eth_stats_s {
269 u64 secs_reset; /* seconds since stats is reset */ 278 u64 secs_reset; /* Seconds since stats is reset */
270 u64 frame_64; /* both rx and tx counter */ 279 u64 frame_64; /* Frames 64 bytes */
271 u64 frame_65_127; /* both rx and tx counter */ 280 u64 frame_65_127; /* Frames 65-127 bytes */
272 u64 frame_128_255; /* both rx and tx counter */ 281 u64 frame_128_255; /* Frames 128-255 bytes */
273 u64 frame_256_511; /* both rx and tx counter */ 282 u64 frame_256_511; /* Frames 256-511 bytes */
274 u64 frame_512_1023; /* both rx and tx counter */ 283 u64 frame_512_1023; /* Frames 512-1023 bytes */
275 u64 frame_1024_1518; /* both rx and tx counter */ 284 u64 frame_1024_1518; /* Frames 1024-1518 bytes */
276 u64 frame_1519_1522; /* both rx and tx counter */ 285 u64 frame_1519_1522; /* Frames 1519-1522 bytes */
277 286 u64 tx_bytes; /* Tx bytes */
278 u64 tx_bytes; 287 u64 tx_packets; /* Tx packets */
279 u64 tx_packets; 288 u64 tx_mcast_packets; /* Tx multicast packets */
280 u64 tx_mcast_packets; 289 u64 tx_bcast_packets; /* Tx broadcast packets */
281 u64 tx_bcast_packets; 290 u64 tx_control_frame; /* Tx control frame */
282 u64 tx_control_frame; 291 u64 tx_drop; /* Tx drops */
283 u64 tx_drop; 292 u64 tx_jabber; /* Tx jabber */
284 u64 tx_jabber; 293 u64 tx_fcs_error; /* Tx FCS error */
285 u64 tx_fcs_error; 294 u64 tx_fragments; /* Tx fragments */
286 u64 tx_fragments; 295 u64 rx_bytes; /* Rx bytes */
287 296 u64 rx_packets; /* Rx packets */
288 u64 rx_bytes; 297 u64 rx_mcast_packets; /* Rx multicast packets */
289 u64 rx_packets; 298 u64 rx_bcast_packets; /* Rx broadcast packets */
290 u64 rx_mcast_packets; 299 u64 rx_control_frames; /* Rx control frames */
291 u64 rx_bcast_packets; 300 u64 rx_unknown_opcode; /* Rx unknown opcode */
292 u64 rx_control_frames; 301 u64 rx_drop; /* Rx drops */
293 u64 rx_unknown_opcode; 302 u64 rx_jabber; /* Rx jabber */
294 u64 rx_drop; 303 u64 rx_fcs_error; /* Rx FCS errors */
295 u64 rx_jabber; 304 u64 rx_alignment_error; /* Rx alignment errors */
296 u64 rx_fcs_error; 305 u64 rx_frame_length_error; /* Rx frame len errors */
297 u64 rx_alignment_error; 306 u64 rx_code_error; /* Rx code errors */
298 u64 rx_frame_length_error; 307 u64 rx_fragments; /* Rx fragments */
299 u64 rx_code_error; 308 u64 rx_pause; /* Rx pause */
300 u64 rx_fragments; 309 u64 rx_zero_pause; /* Rx zero pause */
301 310 u64 tx_pause; /* Tx pause */
302 u64 rx_pause; /* BPC */ 311 u64 tx_zero_pause; /* Tx zero pause */
303 u64 rx_zero_pause; /* BPC Pause cancellation */ 312 u64 rx_fcoe_pause; /* Rx fcoe pause */
304 u64 tx_pause; /* BPC */ 313 u64 rx_fcoe_zero_pause; /* Rx FCoE zero pause */
305 u64 tx_zero_pause; /* BPC Pause cancellation */ 314 u64 tx_fcoe_pause; /* Tx FCoE pause */
306 u64 rx_fcoe_pause; /* BPC */ 315 u64 tx_fcoe_zero_pause; /* Tx FCoE zero pause */
307 u64 rx_fcoe_zero_pause; /* BPC Pause cancellation */
308 u64 tx_fcoe_pause; /* BPC */
309 u64 tx_fcoe_zero_pause; /* BPC Pause cancellation */
310}; 316};
311 317
312/** 318/**