OSDN Git Service

net: hns3: add support to query device specifications
authorGuangbin Huang <huangguangbin2@huawei.com>
Sun, 27 Sep 2020 07:12:45 +0000 (15:12 +0800)
committerDavid S. Miller <davem@davemloft.net>
Sun, 27 Sep 2020 20:25:22 +0000 (13:25 -0700)
commitaf2aedc57277dfd1d9ebe16777cf84dccce8e68d
tree64ae476f0eb8c42109724b22026a03d4d0fdf6cd
parent9484e3379e46afffcf0973677656bc36fe96ac71
net: hns3: add support to query device specifications

To improve code maintainability and compatibility, new commands
HCLGE_OPC_QUERY_DEV_SPECS for PF and HCLGEVF_OPC_QUERY_DEV_SPECS
for VF are introduced to query device specifications, instead of
statically defining specifications by checking the hardware version
or other methods.

Signed-off-by: Guangbin Huang <huangguangbin2@huawei.com>
Signed-off-by: Huazhong Tan <tanhuazhong@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/hisilicon/hns3/hnae3.h
drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_cmd.h
drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c
drivers/net/ethernet/hisilicon/hns3/hns3vf/hclgevf_cmd.h
drivers/net/ethernet/hisilicon/hns3/hns3vf/hclgevf_main.c