@@ -779,12 +779,4 @@ static struct platform_driver mal_of_driver = {
.remove_new = mal_remove,
};
-int __init mal_init(void)
-{
- return platform_driver_register(&mal_of_driver);
-}
-
-void mal_exit(void)
-{
- platform_driver_unregister(&mal_of_driver);
-}
+module_platform_driver(mal_of_driver);
@@ -303,12 +303,4 @@ static struct platform_driver rgmii_driver = {
.remove_new = rgmii_remove,
};
-int __init rgmii_init(void)
-{
- return platform_driver_register(&rgmii_driver);
-}
-
-void rgmii_exit(void)
-{
- platform_driver_unregister(&rgmii_driver);
-}
+module_platform_driver(rgmii_driver);
@@ -161,12 +161,4 @@ static struct platform_driver tah_driver = {
.remove_new = tah_remove,
};
-int __init tah_init(void)
-{
- return platform_driver_register(&tah_driver);
-}
-
-void tah_exit(void)
-{
- platform_driver_unregister(&tah_driver);
-}
+module_platform_driver(tah_driver);
@@ -309,12 +309,4 @@ static struct platform_driver zmii_driver = {
.remove_new = zmii_remove,
};
-int __init zmii_init(void)
-{
- return platform_driver_register(&zmii_driver);
-}
-
-void zmii_exit(void)
-{
- platform_driver_unregister(&zmii_driver);
-}
+module_platform_driver(zmii_driver);
These init and exit functions don't do anything special. Just macro it away. Signed-off-by: Rosen Penev <rosenp@gmail.com> --- drivers/net/ethernet/ibm/emac/mal.c | 10 +--------- drivers/net/ethernet/ibm/emac/rgmii.c | 10 +--------- drivers/net/ethernet/ibm/emac/tah.c | 10 +--------- drivers/net/ethernet/ibm/emac/zmii.c | 10 +--------- 4 files changed, 4 insertions(+), 36 deletions(-)