net: phy: atheros: Convert to U_BOOT_PHY_DRIVER()
Convert PHY driver to U_BOOT_PHY_DRIVER() macro and drop phy_register() init call.
Converted using sed
"s@^static struct phy_driver \(.*\)_driver = \+{@U_BOOT_PHY_DRIVER(\L\1) = {"
Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
Acked-by: Michal Simek <michal.simek@amd.com>
Tested-by: Michal Simek <michal.simek@amd.com> #microblaze (MANUAL_RELOC)
diff --git a/drivers/net/phy/atheros.c b/drivers/net/phy/atheros.c
index c6f9f91..abb7bdf 100644
--- a/drivers/net/phy/atheros.c
+++ b/drivers/net/phy/atheros.c
@@ -333,7 +333,7 @@
return 0;
}
-static struct phy_driver AR8021_driver = {
+U_BOOT_PHY_DRIVER(AR8021) = {
.name = "AR8021",
.uid = AR8021_PHY_ID,
.mask = 0xfffffff0,
@@ -343,7 +343,7 @@
.shutdown = genphy_shutdown,
};
-static struct phy_driver AR8031_driver = {
+U_BOOT_PHY_DRIVER(AR8031) = {
.name = "AR8031/AR8033",
.uid = AR8031_PHY_ID,
.mask = 0xffffffef,
@@ -353,7 +353,7 @@
.shutdown = genphy_shutdown,
};
-static struct phy_driver AR8035_driver = {
+U_BOOT_PHY_DRIVER(AR8035) = {
.name = "AR8035",
.uid = AR8035_PHY_ID,
.mask = 0xffffffef,
@@ -362,12 +362,3 @@
.startup = genphy_startup,
.shutdown = genphy_shutdown,
};
-
-int phy_atheros_init(void)
-{
- phy_register(&AR8021_driver);
- phy_register(&AR8031_driver);
- phy_register(&AR8035_driver);
-
- return 0;
-}