Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754819AbbGFTCy (ORCPT ); Mon, 6 Jul 2015 15:02:54 -0400 Received: from comal.ext.ti.com ([198.47.26.152]:47829 "EHLO comal.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752130AbbGFTCu (ORCPT ); Mon, 6 Jul 2015 15:02:50 -0400 Date: Mon, 6 Jul 2015 14:02:12 -0500 From: Felipe Balbi To: Alan Stern CC: Douglas Anderson , Greg Kroah-Hartman , John Youn , Felipe Balbi , , Chris Zhong , Heiko Stuebner , Julius Werner , Andrew Bresticker , Alexandru Stan , , , Subject: Re: [REPOST PATCH 3/3] USB: dwc2: Don't turn off the usbphy in suspend if wakeup is enabled Message-ID: <20150706190212.GN20779@saruman.tx.rr.com> Reply-To: References: <1436207224-21849-4-git-send-email-dianders@chromium.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="RHdRtM27np9fZUoh" Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2577 Lines: 64 --RHdRtM27np9fZUoh Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Mon, Jul 06, 2015 at 02:58:16PM -0400, Alan Stern wrote: > On Mon, 6 Jul 2015, Douglas Anderson wrote: >=20 > > If the 'snps,need-phy-for-wake' is set in the device tree then: > >=20 > > - We know that we can wakeup, so call device_set_wakeup_capable(). > > The USB core will use this knowledge to enable wakeup by default. > > - We know that we should keep the PHY on during suspend if something > > on our root hub needs remote wakeup. This requires the patch (USB: > > Export usb_wakeup_enabled_descendants()). Note that we don't keep > > the PHY on at suspend time if it's not needed because it would be a > > power draw. >=20 > You know, this is the first time I've run across this optimization. >=20 > In principle it applies to any USB host controller, not just to PHYs. =20 > There's no reason to enable wakeup for a controller if none of the=20 > attached devices can issue a wakeup request. >=20 > I don't know if implementing this in other HCDs would save any power. =20 > Any ideas? most likely it would. Enabling wakeup usually boils down to keeping a tiny part of the controller (or PHY) powered up. Sometimes that lies in an always-on power domain, so there would be no difference. cheers --=20 balbi --RHdRtM27np9fZUoh Content-Type: application/pgp-signature; name="signature.asc" Content-Description: Digital signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQIcBAEBAgAGBQJVmtC0AAoJEIaOsuA1yqREpswP/2e3nZ2edi+BQyY5ij5bVTzf kgVMZqpV/4Tjdso6DVNgGy+JiVlQ92WphkgbiQ3lNhB/fYdBjD+ay4nHu046eljr 4KzLyTLBtct00ZLwoLPniplUnZvzRUvF0XG8Dut2aebQSuGboncOxtjDubuctCPT +yxM8ETG80C2VlNNYopFuMW80diyn5/eMVllQH4WLDnN6DArXAle7CtNpvMMbrhn 6kdIczfvIJ4gIohb5dxVPImIDt6I1ToDxVPMPBYTJAlKTXYuN1/IcC/IgkOMicqX 6qaIZI2zKtxgxRidU7U/AAWtydsalx584HK8lWy7Q9LyGa55Izv8csWJQxi6PsUD +eVTX/7ZeSRDonLo02cW3fEZVwd8TYu7f2jTsQiL+lVcsxr0YQgDkPmc36aPfhDy d1Rt5ocIP00qozMCctC9In2PFiK+V0hiuq5IzD8oBVJepe8xur4Q3yu24M599//e niAUy0LknZcHIEG901mNFTHztm1Q73M0WkmgSvXneq5s9tQqim1VKlCnhZ9BFjIU /hg+/Hbx0fNVYVNlX4AzhQ9rXm9CBjL8d20PRj7ZdojPdGP8Jf26f8z9Uofu8vgg KyKsIwC5ZMm4KGFTCvriiFP2Vmq+7if+KUGgTJWtuwsJUf3va7zmKEPRwNuEc541 w6pZyhQhimeB31lLpwA3 =0284 -----END PGP SIGNATURE----- --RHdRtM27np9fZUoh-- -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/