aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid S. Miller <[email protected]>2019-04-15 13:39:19 -0700
committerDavid S. Miller <[email protected]>2019-04-15 13:39:19 -0700
commit47a1a225ab35038ac158494fac87b4b7b2e59d58 (patch)
treecc6617d85b04cafc9435ad000d1c606c36dde0fa
parentc7cf89b5dd38a9f2aa410f70f80ba0c4c4d02239 (diff)
parent2566f10676ba996b745e138f54f3e2f974311692 (diff)
Merge branch 'hns3-next'
Huazhong Tan says: ==================== net: hns3: fixes sparse: warning and type error This patchset fixes a sparse warning and a overflow problem. ==================== Signed-off-by: David S. Miller <[email protected]>
-rw-r--r--drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c6
-rw-r--r--drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.h2
2 files changed, 5 insertions, 3 deletions
diff --git a/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c b/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c
index d2fb548e1f50..7dba3b448b8b 100644
--- a/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c
+++ b/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c
@@ -6964,7 +6964,8 @@ int hclge_update_port_base_vlan_cfg(struct hclge_vport *vport, u16 state,
if (state == HNAE3_PORT_BASE_VLAN_MODIFY) {
/* add new VLAN tag */
- ret = hclge_set_vlan_filter_hw(hdev, vlan_info->vlan_proto,
+ ret = hclge_set_vlan_filter_hw(hdev,
+ htons(vlan_info->vlan_proto),
vport->vport_id,
vlan_info->vlan_tag,
vlan_info->qos, false);
@@ -6972,7 +6973,8 @@ int hclge_update_port_base_vlan_cfg(struct hclge_vport *vport, u16 state,
return ret;
/* remove old VLAN tag */
- ret = hclge_set_vlan_filter_hw(hdev, old_vlan_info->vlan_proto,
+ ret = hclge_set_vlan_filter_hw(hdev,
+ htons(old_vlan_info->vlan_proto),
vport->vport_id,
old_vlan_info->vlan_tag,
old_vlan_info->qos, true);
diff --git a/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.h b/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.h
index f04a52f143ae..e736030ac180 100644
--- a/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.h
+++ b/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.h
@@ -854,7 +854,7 @@ struct hclge_vport {
u16 alloc_rss_size;
u16 qs_offset;
- u16 bw_limit; /* VSI BW Limit (0 = disabled) */
+ u32 bw_limit; /* VSI BW Limit (0 = disabled) */
u8 dwrr;
struct hclge_port_base_vlan_config port_base_vlan_cfg;