]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commitdiff
net: hns3: export pci table of hclge and hclgevf to userspace
authorYunsheng Lin <linyunsheng@huawei.com>
Thu, 5 Apr 2018 22:00:39 +0000 (15:00 -0700)
committerSeth Forshee <seth.forshee@canonical.com>
Mon, 9 Apr 2018 20:59:29 +0000 (15:59 -0500)
BugLink: https://bugs.launchpad.net/bugs/1761610
There is no module that is dependent on hclge or hclgevf's symbol,
but hns_enet need them to provide ops for it to run. When there is
a need to auto load the hns3 driver, the auto load will fail because
hclge or hclgevf is not loaded.

Hns_enet has already exported the pci table, so this patch exports
the pci table for hclge and hclgevf module too.

Signed-off-by: Yunsheng Lin <linyunsheng@huawei.com>
Signed-off-by: Peng Li <lipeng321@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
(cherry picked from commit 2f550a467895b8715e17ae9bd6da048e8fce8c92)
Signed-off-by: dann frazier <dann.frazier@canonical.com>
Signed-off-by: Seth Forshee <seth.forshee@canonical.com>
drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c
drivers/net/ethernet/hisilicon/hns3/hns3vf/hclgevf_main.c

index 32bc6f68e2974762d9eb6f2597d976a59f833322..c00d6683e0c48936b50cf7b0863f161c427dc51f 100644 (file)
@@ -55,6 +55,8 @@ static const struct pci_device_id ae_algo_pci_tbl[] = {
        {0, }
 };
 
+MODULE_DEVICE_TABLE(pci, ae_algo_pci_tbl);
+
 static const char hns3_nic_test_strs[][ETH_GSTRING_LEN] = {
        "Mac    Loopback test",
        "Serdes Loopback test",
index 0d89965f79288710da4b73ee09bd431925a2ef40..cc95fc15fb0bb30f4387c53f72e26ac1261244a1 100644 (file)
@@ -18,6 +18,8 @@ static const struct pci_device_id ae_algovf_pci_tbl[] = {
        {0, }
 };
 
+MODULE_DEVICE_TABLE(pci, ae_algovf_pci_tbl);
+
 static inline struct hclgevf_dev *hclgevf_ae_get_hdev(
        struct hnae3_handle *handle)
 {