[PATCH] mdio-gpio: Add mdc pin direction initialization

DORMANTno replies

From: Paulius Zaleckas <hidden>
Date: 2009-02-09 09:52:52
Subsystem: ethernet phy library, networking drivers, the rest · Maintainers: Andrew Lunn, Heiner Kallweit, Andrew Lunn, "David S. Miller", Eric Dumazet, Jakub Kicinski, Paolo Abeni, Linus Torvalds

mdc pin should always be output. Initialize it as output,
so each board code does not need to do this.

Signed-off-by: Paulius Zaleckas <redacted>
---

 drivers/net/phy/mdio-gpio.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/drivers/net/phy/mdio-gpio.c b/drivers/net/phy/mdio-gpio.c
index a439ebe..af28ff7 100644
--- a/drivers/net/phy/mdio-gpio.c
+++ b/drivers/net/phy/mdio-gpio.c
@@ -125,6 +125,8 @@ static int __devinit mdio_gpio_bus_init(struct device *dev,
 	if (gpio_request(bitbang->mdio, "mdio"))
 		goto out_free_mdc;
 
+	gpio_direction_output(bitbang->mdc, 0);
+
 	dev_set_drvdata(dev, new_bus);
 
 	ret = mdiobus_register(new_bus);
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help