aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/stmicro/stmmac/stmmac_pci.c
diff options
context:
space:
mode:
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>2014-11-10 05:38:59 -0500
committerDavid S. Miller <davem@davemloft.net>2014-11-11 14:34:39 -0500
commitb2e2f0c779fefede3a871781c8827bd8e76c7c0f (patch)
tree1ccbaf7b6fa0a4549e531bacdbc101d1e60043b8 /drivers/net/ethernet/stmicro/stmmac/stmmac_pci.c
parentba7a46f16dd29f93303daeb1fee8af316c5a07f4 (diff)
stmmac: split to core library and probe drivers
Instead of registering the platform and PCI drivers in one module let's move necessary bits to where it belongs. During this procedure we convert the module registration part to use module_*_driver() macros which makes code simplier. >From now on the driver consists three parts: core library, PCI, and platform drivers. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Acked-by: Giuseppe Cavallaro <peppe.cavallaro@st.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/stmicro/stmmac/stmmac_pci.c')
-rw-r--r--drivers/net/ethernet/stmicro/stmmac/stmmac_pci.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_pci.c b/drivers/net/ethernet/stmicro/stmmac/stmmac_pci.c
index 5084699baeab..77a6d68f7189 100644
--- a/drivers/net/ethernet/stmicro/stmmac/stmmac_pci.c
+++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_pci.c
@@ -158,7 +158,7 @@ static const struct pci_device_id stmmac_id_table[] = {
158 158
159MODULE_DEVICE_TABLE(pci, stmmac_id_table); 159MODULE_DEVICE_TABLE(pci, stmmac_id_table);
160 160
161struct pci_driver stmmac_pci_driver = { 161static struct pci_driver stmmac_pci_driver = {
162 .name = STMMAC_RESOURCE_NAME, 162 .name = STMMAC_RESOURCE_NAME,
163 .id_table = stmmac_id_table, 163 .id_table = stmmac_id_table,
164 .probe = stmmac_pci_probe, 164 .probe = stmmac_pci_probe,
@@ -168,6 +168,8 @@ struct pci_driver stmmac_pci_driver = {
168 }, 168 },
169}; 169};
170 170
171module_pci_driver(stmmac_pci_driver);
172
171MODULE_DESCRIPTION("STMMAC 10/100/1000 Ethernet PCI driver"); 173MODULE_DESCRIPTION("STMMAC 10/100/1000 Ethernet PCI driver");
172MODULE_AUTHOR("Rayagond Kokatanur <rayagond.kokatanur@vayavyalabs.com>"); 174MODULE_AUTHOR("Rayagond Kokatanur <rayagond.kokatanur@vayavyalabs.com>");
173MODULE_AUTHOR("Giuseppe Cavallaro <peppe.cavallaro@st.com>"); 175MODULE_AUTHOR("Giuseppe Cavallaro <peppe.cavallaro@st.com>");