Skip to content

Commit

Permalink
net: mdio-octeon: Use module_platform_driver()
Browse files Browse the repository at this point in the history
module_platform_driver macro removes some boilerplate and
simplifies the code.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Cc: David Daney <ddaney@caviumnetworks.com>
Acked-by: David Daney <ddaney@caviumnetworks.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Sachin Kamat authored and David S. Miller committed Mar 20, 2013
1 parent f8e5fc8 commit 9fad0c9
Showing 1 changed file with 1 addition and 12 deletions.
13 changes: 1 addition & 12 deletions drivers/net/phy/mdio-octeon.c
Original file line number Diff line number Diff line change
Expand Up @@ -197,18 +197,7 @@ void octeon_mdiobus_force_mod_depencency(void)
}
EXPORT_SYMBOL(octeon_mdiobus_force_mod_depencency);

static int __init octeon_mdiobus_mod_init(void)
{
return platform_driver_register(&octeon_mdiobus_driver);
}

static void __exit octeon_mdiobus_mod_exit(void)
{
platform_driver_unregister(&octeon_mdiobus_driver);
}

module_init(octeon_mdiobus_mod_init);
module_exit(octeon_mdiobus_mod_exit);
module_platform_driver(octeon_mdiobus_driver);

MODULE_DESCRIPTION(DRV_DESCRIPTION);
MODULE_VERSION(DRV_VERSION);
Expand Down

0 comments on commit 9fad0c9

Please sign in to comment.