summaryrefslogtreecommitdiff
path: root/drivers/net/can/sja1000/kvaser_pci.c
diff options
context:
space:
mode:
authorAxel Lin <axel.lin@gmail.com>2012-04-14 08:38:43 +0400
committerMarc Kleine-Budde <mkl@pengutronix.de>2012-04-16 23:08:18 +0400
commitfb7944b36931d77ea2cde061ff714415ef6e4cef (patch)
tree3d2cf39d8d7d607d0d482783f311841cb3f2424d /drivers/net/can/sja1000/kvaser_pci.c
parenta75afd4770d401186b130b2bbb58ad23d4d01ae3 (diff)
downloadlinux-fb7944b36931d77ea2cde061ff714415ef6e4cef.tar.xz
net/can: use module_pci_driver
This patch converts the drivers in drivers/net/can/* to use module_pci_driver() macro which makes the code smaller and a bit simpler. Signed-off-by: Axel Lin <axel.lin@gmail.com> Cc: Wolfgang Grandegger <wg@grandegger.com> Cc: Marc Kleine-Budde <mkl@pengutronix.de> Cc: "David S. Miller" <davem@davemloft.net> Cc: linux-can@vger.kernel.org Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
Diffstat (limited to 'drivers/net/can/sja1000/kvaser_pci.c')
-rw-r--r--drivers/net/can/sja1000/kvaser_pci.c13
1 files changed, 1 insertions, 12 deletions
diff --git a/drivers/net/can/sja1000/kvaser_pci.c b/drivers/net/can/sja1000/kvaser_pci.c
index ed004cebd31f..23ed6ea4c7c3 100644
--- a/drivers/net/can/sja1000/kvaser_pci.c
+++ b/drivers/net/can/sja1000/kvaser_pci.c
@@ -397,15 +397,4 @@ static struct pci_driver kvaser_pci_driver = {
.remove = __devexit_p(kvaser_pci_remove_one),
};
-static int __init kvaser_pci_init(void)
-{
- return pci_register_driver(&kvaser_pci_driver);
-}
-
-static void __exit kvaser_pci_exit(void)
-{
- pci_unregister_driver(&kvaser_pci_driver);
-}
-
-module_init(kvaser_pci_init);
-module_exit(kvaser_pci_exit);
+module_pci_driver(kvaser_pci_driver);