net: hns3: fix error type definition of return value
An enum type variable was used to store an "int" type return value.
This patch fixes it.
Fixes: 46a3df9f97
("net: hns3: Add HNS3 Acceleration Engine & Compatibility Layer Support")
Signed-off-by: Jian Shen <shenjian15@huawei.com>
Signed-off-by: Peng Li <lipeng321@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
5d02a58dae
commit
aa7a795eec
@ -4107,8 +4107,8 @@ int hclge_add_uc_addr_common(struct hclge_vport *vport,
|
||||
{
|
||||
struct hclge_dev *hdev = vport->back;
|
||||
struct hclge_mac_vlan_tbl_entry_cmd req;
|
||||
enum hclge_cmd_status status;
|
||||
u16 egress_port = 0;
|
||||
int ret;
|
||||
|
||||
/* mac addr check */
|
||||
if (is_zero_ether_addr(addr) ||
|
||||
@ -4140,9 +4140,9 @@ int hclge_add_uc_addr_common(struct hclge_vport *vport,
|
||||
|
||||
hclge_prepare_mac_addr(&req, addr);
|
||||
|
||||
status = hclge_add_mac_vlan_tbl(vport, &req, NULL);
|
||||
ret = hclge_add_mac_vlan_tbl(vport, &req, NULL);
|
||||
|
||||
return status;
|
||||
return ret;
|
||||
}
|
||||
|
||||
static int hclge_rm_uc_addr(struct hnae3_handle *handle,
|
||||
@ -4158,7 +4158,7 @@ int hclge_rm_uc_addr_common(struct hclge_vport *vport,
|
||||
{
|
||||
struct hclge_dev *hdev = vport->back;
|
||||
struct hclge_mac_vlan_tbl_entry_cmd req;
|
||||
enum hclge_cmd_status status;
|
||||
int ret;
|
||||
|
||||
/* mac addr check */
|
||||
if (is_zero_ether_addr(addr) ||
|
||||
@ -4174,9 +4174,9 @@ int hclge_rm_uc_addr_common(struct hclge_vport *vport,
|
||||
hnae_set_bit(req.flags, HCLGE_MAC_VLAN_BIT0_EN_B, 1);
|
||||
hnae_set_bit(req.entry_type, HCLGE_MAC_VLAN_BIT0_EN_B, 0);
|
||||
hclge_prepare_mac_addr(&req, addr);
|
||||
status = hclge_remove_mac_vlan_tbl(vport, &req);
|
||||
ret = hclge_remove_mac_vlan_tbl(vport, &req);
|
||||
|
||||
return status;
|
||||
return ret;
|
||||
}
|
||||
|
||||
static int hclge_add_mc_addr(struct hnae3_handle *handle,
|
||||
|
Loading…
Reference in New Issue
Block a user