[PATCH 3/3] net: fec: add phy-reset-interval for device tree probe

Shawn Guo shawn.guo at linaro.org
Tue Jun 26 08:13:36 EDT 2012


On Tue, Jun 26, 2012 at 01:55:05PM +0200, Florian Fainelli wrote:
> > +	of_property_read_u32(np, "phy-reset-interval", &msec);
> >  	phy_reset = of_get_named_gpio(np, "phy-reset-gpios", 0);
> >  	err = gpio_request_one(phy_reset, GPIOF_OUT_INIT_LOW, "phy-reset");
> >  	if (err) {
> >  		pr_debug("FEC: failed to get gpio phy-reset: %d\n", err);
> >  		return;
> >  	}
> > -	msleep(1);
> > +	msleep(msec);
> 
> You might want to check the value of the property here to make sure it is in 
> the msleep() acceptable range.
> 
Sounds good.  I think a sensible reset duration should be less one
second, so let's force 1000 ms to be the possible max one?

-- 
Regards,
Shawn




More information about the linux-arm-kernel mailing list