Received: by 2002:a05:6358:1087:b0:cb:c9d3:cd90 with SMTP id j7csp4066074rwi; Sat, 22 Oct 2022 04:44:24 -0700 (PDT) X-Google-Smtp-Source: AMsMyM7x0Yv8A6NZcw3kKY1EOMWEIJSwqfyol0RJDdQqiuyU8VxiIhRdwv//RoilYtLeuOQJ9x2T X-Received: by 2002:a05:6a00:10cf:b0:563:34ce:4138 with SMTP id d15-20020a056a0010cf00b0056334ce4138mr24468933pfu.6.1666439064706; Sat, 22 Oct 2022 04:44:24 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1666439064; cv=none; d=google.com; s=arc-20160816; b=0RvRTVxp9nlQif00qS9QuLG+oouSHyLX7brck88F48w7zx/gaCIEP9QEc4mAzGmF7S 0y8DNwTG9QwiQxlgkXiL1QoTM9dOQrAO9kYgN10JwABE634AhsPkGlTEGW9CJPZBU6q2 X+nvNPKE8uAeSTO4oFTF71WGhRVdLElsbum2dw8V0nfm0hJDzCdMajopKJzGVbXsfKnv CPbQo1rMNeUSwPOQsdsdL2esumuotpujNcGvmRj0pjsEpHCvzJufeyic/kavmDzozLEL 00IX7VlxnO1SqomQcXsQSLIenAjvXxgdYy4UfdzQ1eXmhjSmxAueUx2XLFftvB5McFNO 5yXQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=UQT/RBcMwYsllz3NtL9eyvzMx1/o4/tLqDof4NbQ7EA=; b=yLrqhjUq9hglgv0WpAUlVWo2QvG99KHWucyhD10hxvooOgvN7yztf+IrtfDF8XZlFA QUwt+IvME6+KZWcwMqslDry7UdbMz2yv77/li911VKoOmykHyBQNnXZl4P7j697hozN4 gVtWOUi/seEcbtBUUvbxgXA4etwzVSZfRgRZCAJevE/V3y/JOaLPzI9FvQj8tvtqQ51z RyPHMI/qvEu1gdH24U/KlTJud4yIiUxmZPYR/E+I/Iqm8EMVoTlnuWaOMnEi1dI5g3p4 Y+nhn+RTnIyUrng/NRpqvGZz/BrW4YRU/jOHkM64qtc5C3oEbbt0IOKXI6XWlN8c9rXU ZN2g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=khJ39P7w; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id y1-20020a17090a474100b0020d5867aab6si8625356pjg.141.2022.10.22.04.44.12; Sat, 22 Oct 2022 04:44:24 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=khJ39P7w; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230000AbiJVK7Q (ORCPT + 99 others); Sat, 22 Oct 2022 06:59:16 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46418 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230253AbiJVK6p (ORCPT ); Sat, 22 Oct 2022 06:58:45 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2686D46D85; Sat, 22 Oct 2022 03:17:05 -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 55029B82E05; Sat, 22 Oct 2022 07:54:26 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 6B13BC433D6; Sat, 22 Oct 2022 07:54:24 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1666425265; bh=aRoHgLT18h88Rn43em+coJfcbxqhuSaOBcPrfYQ//0Q=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=khJ39P7ww19bhrsKyQWDEX5PalT+DcYk+zzFVH5uxOZVFll1TeDhRtOyMALa9alU6 5/10WmQ5LZvYMB+fBWDzbb9gtMfEah8NyApha9wnGUVgdVlAYCPzuSpke8ckYmZz0R siTnpdd8BlSd3XYnWCAwDVB0btyGbPp3sz61Z7CQ= 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 5.19 444/717] xhci: Dont show warning for reinit on known broken suspend Date: Sat, 22 Oct 2022 09:25:23 +0200 Message-Id: <20221022072517.931513104@linuxfoundation.org> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221022072415.034382448@linuxfoundation.org> References: <20221022072415.034382448@linuxfoundation.org> User-Agent: quilt/0.67 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-7.4 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 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=216470 Fixes: 8b328f8002bc ("xhci: re-initialize the HC during resume if HCE was set") 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 38649284ff88..a7ef675f00fd 100644 --- a/drivers/usb/host/xhci.c +++ b/drivers/usb/host/xhci.c @@ -1183,7 +1183,8 @@ int xhci_resume(struct xhci_hcd *xhci, bool hibernated) /* re-initialize the HC on Restore Error, or Host Controller Error */ if (temp & (STS_SRE | STS_HCE)) { reinit_xhc = 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); } if (reinit_xhc) { -- 2.35.1