Skip to content

Commit

Permalink
net: hns3: change TM sched mode to TC-based mode when SRIOV enabled
Browse files Browse the repository at this point in the history
TC-based sched mode supports SRIOV enabled and SRIOV disabled. This
patch change the TM sched mode to TC-based mode in initialization
process.

Fixes: cc9bb43 ("net: hns3: Add tc-based TM support for sriov enabled port")
Signed-off-by: Peng Li <lipeng321@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Peng Li authored and David S. Miller committed Dec 27, 2017
1 parent 3a7d595 commit 71b8386
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -1100,10 +1100,7 @@ static int hclge_configure(struct hclge_dev *hdev)
for (i = 0; i < hdev->tm_info.num_tc; i++)
hnae_set_bit(hdev->hw_tc_map, i, 1);

if (!hdev->num_vmdq_vport && !hdev->num_req_vfs)
hdev->tx_sch_mode = HCLGE_FLAG_TC_BASE_SCH_MODE;
else
hdev->tx_sch_mode = HCLGE_FLAG_VNET_BASE_SCH_MODE;
hdev->tx_sch_mode = HCLGE_FLAG_TC_BASE_SCH_MODE;

return ret;
}
Expand Down

0 comments on commit 71b8386

Please sign in to comment.