From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 1AB69C197A0 for ; Fri, 17 Nov 2023 03:38:59 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=02t9cZEAwuc4jaaXle9ag2U4Vh8XB61lVPOtxCgr5ZE=; b=SE0e5UB6C3y4En u6CWMfO0xiO3Wm1SVJYtWWiZJlaa+NPmwKPig/BJvRCry9iiSKA7ssvpOc3Cmi9ipYCWOjyxnlGWm 1nWZCFhdgAYA3W8Td3s3JrEsSUE3MrpfUQ20jINFe2psPxu3XKNVkOLq9BtuievuH/ONFhDxWwOCt n8OO1CDJQf8fD8e516iOX3WL14pJv4A/4vfQgsmPj3bBa4qc7W0fLkXyoraakee+S+/IKAPwoiwIc 5XmP+C9T3eMq1Jpwq+umd9k9adbmp5fb6dUP0/9KEiUJsQ6x8Z67NMaSYm54w2wAYTqZDdpOBNq9t evSHJocvblCZ3CnySggA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1r3pge-005YDl-2I; Fri, 17 Nov 2023 03:38:32 +0000 Received: from ams.source.kernel.org ([2604:1380:4601:e00::1]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1r3pgc-005YDC-0r for linux-arm-kernel@lists.infradead.org; Fri, 17 Nov 2023 03:38:31 +0000 Received: from smtp.kernel.org (transwarp.subspace.kernel.org [100.75.92.58]) by ams.source.kernel.org (Postfix) with ESMTP id 98071B80886; Fri, 17 Nov 2023 03:38:27 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 4256BC433C8; Fri, 17 Nov 2023 03:38:23 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1700192307; bh=pT1BzgitY92OrK+bcmiH4d/YlOWx34mfM/YbnLtCb3E=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=m0Bbp8AeEm3UxtlqyPQPLRXg82ZM0TQdcnipmtkwDsW+4DZZ50ef9wqoevPWRMyOG NBSYb1Z9XXmbs5+n7QfFGUO8kgfQLZWvV9aDb29YrpsIr2iACm0euhAKpAp/OEfPDl AgsmzhqcQB+jAWtbYKx0229xVosdWvyY6DH4jKPCHNRbl8UlzbuKk3pNhxXmuuglC5 1psVDWzt8iYqPiYmUeyXKmo0e7i0w9WRB5jgyG+FwAm13aI0LQdkOB8EFVEhvv+Y06 5M9zzp4DvSz7C0NdWKBdufjSxOG2ItZyIgjiGZewM6zkksVTCzN48QyWHT8+NrNCtJ gnypkcvrJuraA== Date: Fri, 17 Nov 2023 11:38:14 +0800 From: Peter Chen To: =?iso-8859-1?Q?Th=E9o?= Lebrun Cc: Greg Kroah-Hartman , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Roger Quadros , Pawel Laszczak , Nishanth Menon , Vignesh Raghavendra , Tero Kristo , linux-usb@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: Re: [PATCH 4/6] usb: cdns3: support power-off of controller when in host role Message-ID: <20231117033814.GA485583@nchen-desktop> References: <20231113-j7200-usb-suspend-v1-0-ad1ee714835c@bootlin.com> <20231113-j7200-usb-suspend-v1-4-ad1ee714835c@bootlin.com> <20231114083838.GC64573@nchen-desktop> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20231116_193830_458827_5BC0DFEC X-CRM114-Status: GOOD ( 17.16 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On 23-11-14 12:10:18, Th=E9o Lebrun wrote: > Hello, > = > On Tue Nov 14, 2023 at 9:38 AM CET, Peter Chen wrote: > > On 23-11-13 15:26:59, Th=E9o Lebrun wrote: > > > The controller is not being reconfigured at resume. Change resume to > > > redo hardware config if quirk CDNS3_RESET_ON_RESUME is active. > > > > Current logic has power off judgement, see cdns3_controller_resume for > > detail. > = > Indeed! Thanks for the pointer. I had not noticed that, those patches > come from an older kernel which didn't have it. That'll make for less > changes; patches 4 & 5 can go away. > = > > > + if (cdns->pdata && cdns->pdata->quirks & CDNS3_RESET_ON_RESUME) > > > + cdns->xhci_plat_data->quirks |=3D XHCI_RESET_ON_RESUME | XHCI_SUSP= END_RESUME_CLKS; > > > + > > > > If you set this flag, how could you support the USB remote wakeup > > request? In that case, the USB bus does not expect re-enumeration. > = > We didn't support remote USB wakeup. Only S2R mattered in our case and > USB remote wakeup wasn't a possibility. Without this patch, will below be hit for your platform: /* re-initialize the HC on Restore Error, or Host Controller Error */ if (temp & (STS_SRE | STS_HCE)) { reinit_xhc =3D true; if (!xhci->broken_suspend) xhci_warn(xhci, "xHC error in resume, USBSTS 0x%x, Reinit\n", temp); } -- = Thanks, Peter Chen _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel