mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-08-27 19:29:37 +00:00
bna: Fix Ucast Failure Handling
Failure of the UCAST set for base mac address fails when user configures a duplicate mac address that matches that of another vNIC on the same port. The bna does not handle the ucast failure and keeps this address in cache. On disable of the vNIC, bna tries to delete the failed base mac address and the fw asserts. On failure of ucast address, mark ucast address set to false. Signed-off-by: Rasesh Mody <rmody@brocade.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
4b2305826c
commit
f489a4ba76
3 changed files with 23 additions and 1 deletions
|
@ -455,6 +455,8 @@ void bna_bfi_rx_enet_stop_rsp(struct bna_rx *rx,
|
|||
void bna_bfi_rxf_cfg_rsp(struct bna_rxf *rxf, struct bfi_msgq_mhdr *msghdr);
|
||||
void bna_bfi_rxf_mcast_add_rsp(struct bna_rxf *rxf,
|
||||
struct bfi_msgq_mhdr *msghdr);
|
||||
void bna_bfi_rxf_ucast_set_rsp(struct bna_rxf *rxf,
|
||||
struct bfi_msgq_mhdr *msghdr);
|
||||
|
||||
/* APIs for BNA */
|
||||
void bna_rx_mod_init(struct bna_rx_mod *rx_mod, struct bna *bna,
|
||||
|
|
|
@ -298,7 +298,6 @@ bna_msgq_rsp_handler(void *arg, struct bfi_msgq_mhdr *msghdr)
|
|||
case BFI_ENET_I2H_RSS_ENABLE_RSP:
|
||||
case BFI_ENET_I2H_RX_PROMISCUOUS_RSP:
|
||||
case BFI_ENET_I2H_RX_DEFAULT_RSP:
|
||||
case BFI_ENET_I2H_MAC_UCAST_SET_RSP:
|
||||
case BFI_ENET_I2H_MAC_UCAST_CLR_RSP:
|
||||
case BFI_ENET_I2H_MAC_UCAST_ADD_RSP:
|
||||
case BFI_ENET_I2H_MAC_UCAST_DEL_RSP:
|
||||
|
@ -311,6 +310,12 @@ bna_msgq_rsp_handler(void *arg, struct bfi_msgq_mhdr *msghdr)
|
|||
bna_bfi_rxf_cfg_rsp(&rx->rxf, msghdr);
|
||||
break;
|
||||
|
||||
case BFI_ENET_I2H_MAC_UCAST_SET_RSP:
|
||||
bna_rx_from_rid(bna, msghdr->enet_id, rx);
|
||||
if (rx)
|
||||
bna_bfi_rxf_ucast_set_rsp(&rx->rxf, msghdr);
|
||||
break;
|
||||
|
||||
case BFI_ENET_I2H_MAC_MCAST_ADD_RSP:
|
||||
bna_rx_from_rid(bna, msghdr->enet_id, rx);
|
||||
if (rx)
|
||||
|
|
|
@ -710,6 +710,21 @@ bna_bfi_rxf_cfg_rsp(struct bna_rxf *rxf, struct bfi_msgq_mhdr *msghdr)
|
|||
bfa_fsm_send_event(rxf, RXF_E_FW_RESP);
|
||||
}
|
||||
|
||||
void
|
||||
bna_bfi_rxf_ucast_set_rsp(struct bna_rxf *rxf,
|
||||
struct bfi_msgq_mhdr *msghdr)
|
||||
{
|
||||
struct bfi_enet_rsp *rsp =
|
||||
(struct bfi_enet_rsp *)msghdr;
|
||||
|
||||
if (rsp->error) {
|
||||
/* Clear ucast from cache */
|
||||
rxf->ucast_active_set = 0;
|
||||
}
|
||||
|
||||
bfa_fsm_send_event(rxf, RXF_E_FW_RESP);
|
||||
}
|
||||
|
||||
void
|
||||
bna_bfi_rxf_mcast_add_rsp(struct bna_rxf *rxf,
|
||||
struct bfi_msgq_mhdr *msghdr)
|
||||
|
|
Loading…
Reference in a new issue