2 * Linux network driver for Brocade Converged Network Adapter.
4 * This program is free software; you can redistribute it and/or modify it
5 * under the terms of the GNU General Public License (GPL) Version 2 as
6 * published by the Free Software Foundation
8 * This program is distributed in the hope that it will be useful, but
9 * WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11 * General Public License for more details.
14 * Copyright (c) 2005-2010 Brocade Communications Systems, Inc.
22 #include "bfa_defs_cna.h"
27 BFI_PORT_H2I_ENABLE_REQ
= (1),
28 BFI_PORT_H2I_DISABLE_REQ
= (2),
29 BFI_PORT_H2I_GET_STATS_REQ
= (3),
30 BFI_PORT_H2I_CLEAR_STATS_REQ
= (4),
34 BFI_PORT_I2H_ENABLE_RSP
= BFA_I2HM(1),
35 BFI_PORT_I2H_DISABLE_RSP
= BFA_I2HM(2),
36 BFI_PORT_I2H_GET_STATS_RSP
= BFA_I2HM(3),
37 BFI_PORT_I2H_CLEAR_STATS_RSP
= BFA_I2HM(4),
40 /* Generic REQ type */
41 struct bfi_port_generic_req
{
42 struct bfi_mhdr mh
; /*!< msg header */
43 u32 msgtag
; /*!< msgtag for reply */
47 /* Generic RSP type */
48 struct bfi_port_generic_rsp
{
49 struct bfi_mhdr mh
; /*!< common msg header */
50 u8 status
; /*!< port enable status */
52 u32 msgtag
; /*!< msgtag for reply */
55 /* BFI_PORT_H2I_GET_STATS_REQ */
56 struct bfi_port_get_stats_req
{
57 struct bfi_mhdr mh
; /*!< common msg header */
58 union bfi_addr_u dma_addr
;
61 union bfi_port_h2i_msg_u
{
63 struct bfi_port_generic_req enable_req
;
64 struct bfi_port_generic_req disable_req
;
65 struct bfi_port_get_stats_req getstats_req
;
66 struct bfi_port_generic_req clearstats_req
;
69 union bfi_port_i2h_msg_u
{
71 struct bfi_port_generic_rsp enable_rsp
;
72 struct bfi_port_generic_rsp disable_rsp
;
73 struct bfi_port_generic_rsp getstats_rsp
;
74 struct bfi_port_generic_rsp clearstats_rsp
;
77 /* @brief Mailbox commands from host to (DCBX/LLDP) firmware */
78 enum bfi_cee_h2i_msgs
{
79 BFI_CEE_H2I_GET_CFG_REQ
= 1,
80 BFI_CEE_H2I_RESET_STATS
= 2,
81 BFI_CEE_H2I_GET_STATS_REQ
= 3,
84 /* @brief Mailbox reply and AEN messages from DCBX/LLDP firmware to host */
85 enum bfi_cee_i2h_msgs
{
86 BFI_CEE_I2H_GET_CFG_RSP
= BFA_I2HM(1),
87 BFI_CEE_I2H_RESET_STATS_RSP
= BFA_I2HM(2),
88 BFI_CEE_I2H_GET_STATS_RSP
= BFA_I2HM(3),
94 * @brief H2I command structure for resetting the stats.
95 * BFI_CEE_H2I_RESET_STATS
97 struct bfi_lldp_reset_stats
{
102 * @brief H2I command structure for resetting the stats.
103 * BFI_CEE_H2I_RESET_STATS
105 struct bfi_cee_reset_stats
{
110 * @brief get configuration command from host
111 * BFI_CEE_H2I_GET_CFG_REQ
113 struct bfi_cee_get_req
{
115 union bfi_addr_u dma_addr
;
119 * @brief reply message from firmware
120 * BFI_CEE_I2H_GET_CFG_RSP
122 struct bfi_cee_get_rsp
{
129 * @brief get configuration command from host
130 * BFI_CEE_H2I_GET_STATS_REQ
132 struct bfi_cee_stats_req
{
134 union bfi_addr_u dma_addr
;
138 * @brief reply message from firmware
139 * BFI_CEE_I2H_GET_STATS_RSP
141 struct bfi_cee_stats_rsp
{
147 /* @brief mailbox command structures from host to firmware */
148 union bfi_cee_h2i_msg_u
{
150 struct bfi_cee_get_req get_req
;
151 struct bfi_cee_stats_req stats_req
;
154 /* @brief mailbox message structures from firmware to host */
155 union bfi_cee_i2h_msg_u
{
157 struct bfi_cee_get_rsp get_rsp
;
158 struct bfi_cee_stats_rsp stats_rsp
;
163 #endif /* __BFI_CNA_H__ */