diff options
author | Johan Hovold <johan@kernel.org> | 2014-11-11 19:45:58 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2014-11-12 13:52:53 -0500 |
commit | 116dffa0b543a2e560abd62a0b3207b1694f9ab9 (patch) | |
tree | bf26c3d107938367692f724596da9067cea09aa0 /drivers/net/phy/qsemi.c | |
parent | c31accd159a6477b91de61ae237dce38e3f3ee4d (diff) |
net: phy: replace phy_driver_register calls
Replace module init/exit which only calls phy_driver_register with
module_phy_driver macro.
Compile tested only.
Signed-off-by: Johan Hovold <johan@kernel.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/phy/qsemi.c')
-rw-r--r-- | drivers/net/phy/qsemi.c | 17 |
1 files changed, 3 insertions, 14 deletions
diff --git a/drivers/net/phy/qsemi.c b/drivers/net/phy/qsemi.c index fe0d0a15d5e1..be4c6f7c3645 100644 --- a/drivers/net/phy/qsemi.c +++ b/drivers/net/phy/qsemi.c @@ -111,7 +111,7 @@ static int qs6612_config_intr(struct phy_device *phydev) } -static struct phy_driver qs6612_driver = { +static struct phy_driver qs6612_driver[] = { { .phy_id = 0x00181440, .name = "QS6612", .phy_id_mask = 0xfffffff0, @@ -123,20 +123,9 @@ static struct phy_driver qs6612_driver = { .ack_interrupt = qs6612_ack_interrupt, .config_intr = qs6612_config_intr, .driver = { .owner = THIS_MODULE,}, -}; - -static int __init qs6612_init(void) -{ - return phy_driver_register(&qs6612_driver); -} - -static void __exit qs6612_exit(void) -{ - phy_driver_unregister(&qs6612_driver); -} +} }; -module_init(qs6612_init); -module_exit(qs6612_exit); +module_phy_driver(qs6612_driver); static struct mdio_device_id __maybe_unused qs6612_tbl[] = { { 0x00181440, 0xfffffff0 }, |