[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20150302210359.GG13270@amd>
Date: Mon, 2 Mar 2015 22:03:59 +0100
From: Pavel Machek <pavel@....cz>
To: NeilBrown <neilb@...e.de>
Cc: Tony Lindgren <tony@...mide.com>, Felipe Balbi <balbi@...com>,
Kishon Vijay Abraham I <kishon@...com>,
linux-omap@...r.kernel.org, lkml <linux-kernel@...r.kernel.org>,
GTA04 owners <gta04-owner@...delico.com>
Subject: Re: [PATCH 1/4] usb: phy: twl4030: make runtime pm more reliable.
Hi!
> + status_changed =
> + (twl->linkstat == OMAP_MUSB_VBUS_VALID ||
> + twl->linkstat == OMAP_MUSB_ID_GROUND)
> + !=
> + (status == OMAP_MUSB_VBUS_VALID ||
> + status == OMAP_MUSB_ID_GROUND);
> twl->linkstat = status;
...
> @@ -768,6 +770,10 @@ static int twl4030_usb_remove(struct platform_device *pdev)
>
> /* disable complete OTG block */
> twl4030_usb_clear_bits(twl, POWER_CTRL, POWER_CTRL_OTG_ENAB);
> +
> + if (twl->linkstat == OMAP_MUSB_VBUS_VALID ||
> + twl->linkstat == OMAP_MUSB_ID_GROUND)
> + pm_runtime_put_noidle(twl->dev);
> pm_runtime_mark_last_busy(twl->dev);
inline function returning (x == OMAP_MUSB_VBUS_VALID || x ==
OMAP_MUSB_ID_GROUND) would really help readability here.
Thanks,
Pavel
--
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists