net: phy: Define init routine and register generic phy driver

This patch define init routine for generic phy driver and registers it
using phy_register as this generic phy driver also needs to be relocated
incase of manual reloc.

Signed-off-by: Siva Durga Prasad Paladugu <siva.durga.paladugu@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
This commit is contained in:
Siva Durga Prasad Paladugu
2019-03-15 17:46:47 +05:30
committed by Michal Simek
parent 69b67ec8c9
commit be49508a0f

View File

@@ -458,6 +458,11 @@ static struct phy_driver genphy_driver = {
.shutdown = genphy_shutdown,
};
int genphy_init(void)
{
return phy_register(&genphy_driver);
}
static LIST_HEAD(phy_drivers);
int phy_init(void)
@@ -540,6 +545,8 @@ int phy_init(void)
#ifdef CONFIG_PHY_FIXED
phy_fixed_init();
#endif
genphy_init();
return 0;
}