Received: by 2002:a05:6a11:4021:0:0:0:0 with SMTP id ky33csp4149305pxb; Mon, 27 Sep 2021 10:23:34 -0700 (PDT) X-Google-Smtp-Source: ABdhPJy39wAQM0APXWsuNWGeA7hlcUe7DXUNjJYQQqyzdJxuXa1YcdusHAaeIEcjBLdwWG+QiqYN X-Received: by 2002:a50:e1cd:: with SMTP id m13mr1321547edl.93.1632763414256; Mon, 27 Sep 2021 10:23:34 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1632763414; cv=none; d=google.com; s=arc-20160816; b=zsMp1+Id9RnXL534XJ8iuy9PeTrtfdFJPpFXy9cH2SQwXygZ451JXcIx8VAxA9A3/z rHMkXQZC+ShFpJHpSV3Pc8+wGQhJuF/RLpE48irX3TnogYtMIzMrdgoFSMyspXhJt01+ cqHLiwGHQVezufLSh0wUJIimsy3mLLOs+F7Q8r7YmXdEZA8c06GoxrObS1XaqgWr86Qa ISIHHkJvkcWN21HBVFbkCbT+6I8axv+2n79V2voD4a+GTvxyjyzpHZfOKtXFAy6lWgwA 8MCUkez5dfOOfiQ0pJiUSu3WjkvdZYxoTVxiOtq8RwJs8TrJulce1Khrw0MTeIK3BUf6 hBDQ== 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=gCmaRZxU7U20cx5uwrvt/tSMBlWkK52A5KZ1KiTd/FQ=; b=jUDip83vNiCb+uXyS1LnBs15/tPHtAV29AuJU9CvLw5vygnLFegg/m5l9FucjrfmAS pqq5VwkxtqmKlo+PiDRfEBraMIQltpoOAIR/I2rYPvz0oxtybAUGYWq6ZP2I9z+KQv9i lgzdnjvwIm5kWwInAOMwM4+XU/nnSdqToUvA2W2Y4qqRnCPcUQFub6suZF10kh6WfdKN 5DP4qsKKI5QC28UoEZdlIVYCp6ND0lROaPDQm52s7NLTl4iCHr1MIsdjiUftkY6gIphG y1oD2fKNgdF5RgQDsSQUMLLrIqoVfc3sWRwyiYLxhoLDY62fJQxqpbduc7GM04tGTnhh cnwA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=ITQ1leqv; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 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 vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id w15si10247253edd.191.2021.09.27.10.23.08; Mon, 27 Sep 2021 10:23:34 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=ITQ1leqv; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 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 S236764AbhI0RWo (ORCPT + 99 others); Mon, 27 Sep 2021 13:22:44 -0400 Received: from mail.kernel.org ([198.145.29.99]:34004 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236695AbhI0RTc (ORCPT ); Mon, 27 Sep 2021 13:19:32 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 73AC06128E; Mon, 27 Sep 2021 17:12:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1632762766; bh=WHSjQM5z8ey52B025NzG0YTyEhmuD7BGA2Bn9yJrbMw=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=ITQ1leqvDHYloam7jYhnKzhTSRwUGNNq0UCHyp1Se3/UirF+uhiSbamM0jFyjjdbi XkcDlD/oo40+gkBPgvWEwp2ZPMiAspMe9Y1RR0TacPCvMcpK9lnPREn35ieai/9FJF PLLXTWoASTVjxfiLmTlaAKt33BtSwS6y8hJy56UA= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, stable@kernel.org, Julian Sikorski , Mario Limonciello , Shyam Sundar S K , Hans de Goede Subject: [PATCH 5.14 043/162] platform/x86: amd-pmc: Increase the response register timeout Date: Mon, 27 Sep 2021 19:01:29 +0200 Message-Id: <20210927170234.998866332@linuxfoundation.org> X-Mailer: git-send-email 2.33.0 In-Reply-To: <20210927170233.453060397@linuxfoundation.org> References: <20210927170233.453060397@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Mario Limonciello commit 3c3c8e88c8712bfe06cd10d7ca77a94a33610cd6 upstream. There have been reports of approximately a 0.9%-1.7% failure rate in SMU communication timeouts with s0i3 entry on some OEM designs. Currently the design in amd-pmc is to try every 100us for up to 20ms. However the GPU driver which also communicates with the SMU using a mailbox register which the driver polls every 1us for up to 2000ms. In the GPU driver this was increased by commit 055162645a40 ("drm/amd/pm: increase time out value when sending msg to SMU") Increase the maximum timeout used by amd-pmc to 2000ms to match this behavior. This has been shown to improve the stability for machines that randomly have failures. Cc: stable@kernel.org Reported-by: Julian Sikorski BugLink: https://gitlab.freedesktop.org/drm/amd/-/issues/1629 Signed-off-by: Mario Limonciello Acked-by: Shyam Sundar S K Link: https://lore.kernel.org/r/20210914020115.655-1-mario.limonciello@amd.com Signed-off-by: Hans de Goede Signed-off-by: Greg Kroah-Hartman --- drivers/platform/x86/amd-pmc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/drivers/platform/x86/amd-pmc.c +++ b/drivers/platform/x86/amd-pmc.c @@ -71,7 +71,7 @@ #define AMD_CPU_ID_YC 0x14B5 #define PMC_MSG_DELAY_MIN_US 100 -#define RESPONSE_REGISTER_LOOP_MAX 200 +#define RESPONSE_REGISTER_LOOP_MAX 20000 #define SOC_SUBSYSTEM_IP_MAX 12 #define DELAY_MIN_US 2000