On Thu, Nov 12, 2009 at 09:11:58AM +0530, Gupta, Ajay Kumar wrote:

> > > +         if (omap->port_mode[i] == EHCI_HCD_OMAP_MODE_UNKNOWN)
> > > +                 continue;
> > > +         if (omap->regulator[i]) {
> > > +                 if (regulator_is_enabled(omap->regulator[i]))
> > > +                         regulator_disable(omap->regulator[i]);
> > > +                 regulator_put(omap->regulator[i]);
> > > +         }

> > For robustness I'd drop the first check for MODE_UNKNOWN here - it
> > doesn't add anything.

> MODE_UNKNOWN means that the port is not connected and so no need to check
> the regulator availability.

Sure, currently - the point is that if you're going to check for the
individual allocations anyway then the check doesn't buy you anything.
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to