forked from luck/tmp_suning_uos_patched
be2net: check for INSUFFICIENT_VLANS error
When the FW runs out of vlan filters it can either return an INSUFFICIENT_RESOURCES error or an INSUFFICIENT_VLANS error. The driver currently checks only for the former error value. This patch adds a check for the latter value too. Signed-off-by: Kalesh AP <kalesh.purayil@emulex.com> Signed-off-by: Sathya Perla <sathya.perla@avagotech.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
0ed7d7498d
commit
77be8c1c4c
|
@ -140,6 +140,7 @@ static bool be_skip_err_log(u8 opcode, u16 base_status, u16 addl_status)
|
|||
if (base_status == MCC_STATUS_NOT_SUPPORTED ||
|
||||
base_status == MCC_STATUS_ILLEGAL_REQUEST ||
|
||||
addl_status == MCC_ADDL_STATUS_TOO_MANY_INTERFACES ||
|
||||
addl_status == MCC_ADDL_STATUS_INSUFFICIENT_VLANS ||
|
||||
(opcode == OPCODE_COMMON_WRITE_FLASHROM &&
|
||||
(base_status == MCC_STATUS_ILLEGAL_FIELD ||
|
||||
addl_status == MCC_ADDL_STATUS_FLASH_IMAGE_CRC_MISMATCH)))
|
||||
|
|
|
@ -65,7 +65,8 @@ enum mcc_base_status {
|
|||
enum mcc_addl_status {
|
||||
MCC_ADDL_STATUS_INSUFFICIENT_RESOURCES = 0x16,
|
||||
MCC_ADDL_STATUS_FLASH_IMAGE_CRC_MISMATCH = 0x4d,
|
||||
MCC_ADDL_STATUS_TOO_MANY_INTERFACES = 0x4a
|
||||
MCC_ADDL_STATUS_TOO_MANY_INTERFACES = 0x4a,
|
||||
MCC_ADDL_STATUS_INSUFFICIENT_VLANS = 0xab
|
||||
};
|
||||
|
||||
#define CQE_BASE_STATUS_MASK 0xFFFF
|
||||
|
|
|
@ -1269,7 +1269,8 @@ static int be_vid_config(struct be_adapter *adapter)
|
|||
if (status) {
|
||||
dev_err(dev, "Setting HW VLAN filtering failed\n");
|
||||
/* Set to VLAN promisc mode as setting VLAN filter failed */
|
||||
if (addl_status(status) ==
|
||||
if (addl_status(status) == MCC_ADDL_STATUS_INSUFFICIENT_VLANS ||
|
||||
addl_status(status) ==
|
||||
MCC_ADDL_STATUS_INSUFFICIENT_RESOURCES)
|
||||
return be_set_vlan_promisc(adapter);
|
||||
} else if (adapter->if_flags & BE_IF_FLAGS_VLAN_PROMISCUOUS) {
|
||||
|
|
Loading…
Reference in New Issue
Block a user