From nobody Mon Dec 15 17:58:02 2025 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 70A8EC38A2D for ; Mon, 24 Oct 2022 12:11:25 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232867AbiJXMLX (ORCPT ); Mon, 24 Oct 2022 08:11:23 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59540 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233207AbiJXMJ5 (ORCPT ); Mon, 24 Oct 2022 08:09:57 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [IPv6:2604:1380:4601:e00::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7E3597FE45; Mon, 24 Oct 2022 04:53:17 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 00F5FB811BE; Mon, 24 Oct 2022 11:52:00 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 522B4C433C1; Mon, 24 Oct 2022 11:51:58 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1666612318; bh=wK+jnoO9VRmlYg/cydAggE/JknkiKXKsyEkHJKl9iJ8=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=BETrhagQvKOmBCokw12nWP2tV4Yj6/MD5nqS2EPbMKkKx22vvRmg1pbbvX4IMvuY0 8FOperXki7Swz9ydPlVt4Ax74M18mKy+7kgkMOqIlkIRr0o9okPgU6OGVdtwl+2I4q JKWaw7jCvXoKbVPZLqjoRAlL2lkpxe6fM0wRv0wg= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, "Artem S. Tashkinov" , Mario Limonciello , Mathias Nyman , Sasha Levin Subject: [PATCH 4.14 135/210] xhci: Dont show warning for reinit on known broken suspend Date: Mon, 24 Oct 2022 13:30:52 +0200 Message-Id: <20221024113001.377705871@linuxfoundation.org> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221024112956.797777597@linuxfoundation.org> References: <20221024112956.797777597@linuxfoundation.org> User-Agent: quilt/0.67 MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Mario Limonciello [ Upstream commit 484d6f7aa3283d082c87654b7fe7a7f725423dfb ] commit 8b328f8002bc ("xhci: re-initialize the HC during resume if HCE was set") introduced a new warning message when the host controller error was set and re-initializing. This is expected behavior on some designs which already set `xhci->broken_suspend` so the new warning is alarming to some users. Modify the code to only show the warning if this was a surprising behavior to the XHCI driver. Link: https://bugzilla.kernel.org/show_bug.cgi?id=3D216470 Fixes: 8b328f8002bc ("xhci: re-initialize the HC during resume if HCE was s= et") Reported-by: Artem S. Tashkinov Signed-off-by: Mario Limonciello Signed-off-by: Mathias Nyman Link: https://lore.kernel.org/r/20220921123450.671459-4-mathias.nyman@linux= .intel.com Signed-off-by: Greg Kroah-Hartman Signed-off-by: Sasha Levin --- drivers/usb/host/xhci.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/usb/host/xhci.c b/drivers/usb/host/xhci.c index c41548f08c54..0f2b67f38d2e 100644 --- a/drivers/usb/host/xhci.c +++ b/drivers/usb/host/xhci.c @@ -1094,7 +1094,8 @@ int xhci_resume(struct xhci_hcd *xhci, bool hibernate= d) /* re-initialize the HC on Restore Error, or Host Controller Error */ if (temp & (STS_SRE | STS_HCE)) { reinit_xhc =3D true; - xhci_warn(xhci, "xHC error in resume, USBSTS 0x%x, Reinit\n", temp); + if (!xhci->broken_suspend) + xhci_warn(xhci, "xHC error in resume, USBSTS 0x%x, Reinit\n", temp); } =20 if (reinit_xhc) { --=20 2.35.1