Inline mdio_init() back into mdio_alloc(), separate access to mdio_init() is no longer necessary.
Signed-off-by: Marek Vasut <[email protected]> --- Cc: Jim Liu <[email protected]> Cc: Joe Hershberger <[email protected]> Cc: Mario Six <[email protected]> Cc: Michael Chang <[email protected]> Cc: Nobuhiro Iwamatsu <[email protected]> Cc: Parvathi Bhogaraju <[email protected]> Cc: Paul Barker <[email protected]> Cc: Ramon Fried <[email protected]> Cc: Tom Rini <[email protected]> Cc: [email protected] --- common/miiphyutil.c | 13 ++++--------- include/miiphy.h | 1 - 2 files changed, 4 insertions(+), 10 deletions(-) diff --git a/common/miiphyutil.c b/common/miiphyutil.c index 2a034d3a77c..1298f07815e 100644 --- a/common/miiphyutil.c +++ b/common/miiphyutil.c @@ -65,14 +65,6 @@ void miiphy_init(void) current_mii = NULL; } -void mdio_init(struct mii_dev *bus) -{ - memset(bus, 0, sizeof(*bus)); - - /* initialize mii_dev struct fields */ - INIT_LIST_HEAD(&bus->link); -} - struct mii_dev *mdio_alloc(void) { struct mii_dev *bus; @@ -81,7 +73,10 @@ struct mii_dev *mdio_alloc(void) if (!bus) return bus; - mdio_init(bus); + memset(bus, 0, sizeof(*bus)); + + /* initialize mii_dev struct fields */ + INIT_LIST_HEAD(&bus->link); return bus; } diff --git a/include/miiphy.h b/include/miiphy.h index 5930fa1b1c9..b4cad2c636f 100644 --- a/include/miiphy.h +++ b/include/miiphy.h @@ -44,7 +44,6 @@ struct phy_device *mdio_phydev_for_ethname(const char *devname); void miiphy_listdev(void); -void mdio_init(struct mii_dev *bus); struct mii_dev *mdio_alloc(void); void mdio_free(struct mii_dev *bus); int mdio_register(struct mii_dev *bus); -- 2.47.2

