net: phy: replace phy_drivers_register calls
Replace module init/exit which only calls phy_drivers_register with module_phy_driver macro. Tested using Micrel driver, and otherwise compile-tested only. Signed-off-by: Johan Hovold <johan@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:

committed by
David S. Miller

parent
116dffa0b5
commit
50fd71507e
@@ -129,20 +129,7 @@ static struct phy_driver cis820x_driver[] = {
|
||||
.driver = { .owner = THIS_MODULE,},
|
||||
} };
|
||||
|
||||
static int __init cicada_init(void)
|
||||
{
|
||||
return phy_drivers_register(cis820x_driver,
|
||||
ARRAY_SIZE(cis820x_driver));
|
||||
}
|
||||
|
||||
static void __exit cicada_exit(void)
|
||||
{
|
||||
phy_drivers_unregister(cis820x_driver,
|
||||
ARRAY_SIZE(cis820x_driver));
|
||||
}
|
||||
|
||||
module_init(cicada_init);
|
||||
module_exit(cicada_exit);
|
||||
module_phy_driver(cis820x_driver);
|
||||
|
||||
static struct mdio_device_id __maybe_unused cicada_tbl[] = {
|
||||
{ 0x000fc410, 0x000ffff0 },
|
||||
|
Reference in New Issue
Block a user