From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-lf1-f41.google.com (mail-lf1-f41.google.com [209.85.167.41]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 4C30A2F3618 for ; Sun, 18 Jan 2026 17:58:27 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.167.41 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1768759108; cv=none; b=omWyCUseaWw2dr5sO587GvlGJYpZeqGRgqQNdLK2TmbvUhS0L79w4jQWotHMbvS8yA4V9ZDfEf27DLtjmQ7WVBDTfNPcAM3KD7etT7OSfOizhJChz/oOfefL1Ak3O9mBfbKI4K10DtScnU1KRY2dwDvicMzFm1jeGUaDhfRcd5w= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1768759108; c=relaxed/simple; bh=rOVC8jxswWb2T4Z0g8a+6WwBGSkdOf5ibuAAow6pqGQ=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=rRumTNRwjJXYhzLINn3z207sasqvlcsmnzCm7CqMovW570P2B4pjC/dYlSrBbexxLmjUgiavW8qmYtK+L//Ty3zbkPXgdUo5Sdachin4WXoiS0fRnRJPBl8Iy+NNDZ8F8LsD5ccu/DvKSAgWjzf0ctHjm9cSkPfs5mNsP7NE4w4= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=hGmj3zPV; arc=none smtp.client-ip=209.85.167.41 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="hGmj3zPV" Received: by mail-lf1-f41.google.com with SMTP id 2adb3069b0e04-59b7b27ebf2so3351048e87.1 for ; Sun, 18 Jan 2026 09:58:27 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1768759105; x=1769363905; darn=vger.kernel.org; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=j2CTlTN2uu1pdeMB7v3S2dD/BdhNBasD9g6dEiEow3Y=; b=hGmj3zPVEwbRGsJ0fEyq8Gsh1kBYezCBMRE1Pa4J57v/BS+sWxFTZs84RMgqyBTgKk q2w6Hx0PhZRK64RXh+YNZy/5Efl55ASh8mxjC4tMdCKeRvjYg1wCaakytYzsgYjTiS+s eVp2Qdh28UYyvUVZATN4C/vG0rhAX+UGDvNJAPDT4LfqdnlxHe8RS3dlVByE1vPLCqYU eMnSlKWBCFPLd2e0gado+9SiwYNKvLSVS4zjNgmoT9XlKHAdYDUs3bphk0gF0v9e3Ena 0ZdhjYkYWvCS7qCm44o9u470CJUg/PaVk4TBX+EwbmY97Z/N3Kb61btp8/hOroO/uRYM HJrA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1768759105; x=1769363905; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:date:message-id :x-gm-gg:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=j2CTlTN2uu1pdeMB7v3S2dD/BdhNBasD9g6dEiEow3Y=; b=CBakGrAol8os07u7F7tOjnhH+m0/836PDEZSBUlpXNpQ4ZRsPJxtOKVY0mwn4bJIWM xSBnLY4ZSnod9vTDvqEpTpdF+OTA0JzEwKWXVLp36SQ5K0SQzKFsr+pcwXrXs/kULSsO 4TLnjanrEMCQK7cI1nsVjiYCsFcewRlVHxL3EjoYxo1IJXT3BZzJZeb8k/gg6CxOmNjz +laqVqHVX3aonTZ/i+tHD9bDugnkLi8GDDmpYP9sljAT4tucIyW/ErHqUFWKP5hr+eJv z00o56x/BxBc447BDX/u7nxH8GZFtbsX3meIl5mwxWJbTe2HtRw3uwCDCm5wVTwetY5Z BWRQ== X-Forwarded-Encrypted: i=1; AJvYcCWqYPy+zyI7k0k48JM5Uhr5w+9I7MVV6F59FGJOm+snvEldaOrpmy9/6SHN/6a3iIjUCfpJems8F1N8nR0=@vger.kernel.org X-Gm-Message-State: AOJu0Yz8MFIpqIRXWWD4FRNSohXtVENLA232UW8NeqB8J6QD6eUoGAXW 3aX8nJtN3BFY+C3I+jxuqimMxfhjOY+OJ9o0am1SmN8pahuuuk+ltFGkQK1tVxkg X-Gm-Gg: AY/fxX5XycU+J4xIDlyeDEOdW5h1BQaaQwkQR+6IVPwQknDMAE4czi4guR3mi+lMfSd cniEzbU5N7eHMqVLD75OmWpdd1lQKfEoJeiEUycKo7uf7cl2IvlORVjmn6iBl8orp4SLq9bWgRZ SCWugEeRFHoeozf+cRUdM1nlB2lKlm0JMMGns99wzAiF79KvntCsCEAkhVsZ2JDrRJOB/V6Plxt NNBu/mNBhniRqaF/pBW2hBDsX5JSPp2yRRaoZv7ylm/p0FRLIQYhiqntUJn/DmVMb8Vxbe+ErA+ VuaSkgg5mvHumYxMrgTk13WTQvTz0YjvU/KMGtX+DXfwdotmKmoYppbIg2NA+LsPiPd1oEB3eKP VUW8zY6GO1U+GOx0TSls9EfQgnM9U3bJiaQrTrTy8zKa/emWYllQnTEjwzH4/bh5IvAI6v+C6ms ztzRhZ/jGN1LkUAbhBuNM4SI1WhQ== X-Received: by 2002:a05:6512:3408:b0:59b:f5f9:7864 with SMTP id 2adb3069b0e04-59bf5f9793emr1518867e87.28.1768759105103; Sun, 18 Jan 2026 09:58:25 -0800 (PST) Received: from ?IPV6:2a0c:9a40:8950:800::67d? ([2a0c:9a40:8950:800::67d]) by smtp.gmail.com with ESMTPSA id 38308e7fff4ca-38384dbe6c1sm25325281fa.22.2026.01.18.09.58.22 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sun, 18 Jan 2026 09:58:24 -0800 (PST) Message-ID: <1eff30f0-f619-419b-ab26-b8c68cad87df@gmail.com> Date: Sun, 18 Jan 2026 22:58:21 +0500 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH 1/1] platform/x86/amd/pmf: Introduce option to disable Smart PC function in PMF To: Shyam Sundar S K , platform-driver-x86@vger.kernel.org Cc: Hans de Goede , =?UTF-8?Q?Ilpo_J=C3=A4rvinen?= , linux-kernel@vger.kernel.org References: <20260117200819.12383-1-xglooom@gmail.com> <20260117200819.12383-2-xglooom@gmail.com> <35a7f364-a89f-4625-82e2-03c1fb42ec74@amd.com> Content-Language: en-US From: Alexey Zagorodnikov In-Reply-To: <35a7f364-a89f-4625-82e2-03c1fb42ec74@amd.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Sorry for the inconvenience, it is my first time :) Originally bugreport here https://gitlab.freedesktop.org/drm/amd/-/issues/4868 But it turned out to be not a real bug, but rather a feature of the firmware, which in my case is not desirable. Would nice to have a toggle to disable, instead of completely blacklist module. Should I send v2 patch with a new message? On 1/18/26 20:20, Shyam Sundar S K wrote: > > On 1/18/2026 01:38, Alexey Zagorodnikov wrote: >> Signed-off-by: Alexey Zagorodnikov > Please include the context in the commit message instead of the cover > letter. Additionally, if there are any bug reports or issue tracker > entries (e.g., Bugzilla) documenting the problem this addresses, > please reference them to provide justification for the change. > > Thanks, > Shyam > >> --- >> drivers/platform/x86/amd/pmf/core.c | 19 ++++++++++++++----- >> 1 file changed, 14 insertions(+), 5 deletions(-) >> >> diff --git a/drivers/platform/x86/amd/pmf/core.c b/drivers/platform/x86/amd/pmf/core.c >> index 8fc293c9c5380..00a4fc899c727 100644 >> --- a/drivers/platform/x86/amd/pmf/core.c >> +++ b/drivers/platform/x86/amd/pmf/core.c >> @@ -53,6 +53,11 @@ static bool force_load; >> module_param(force_load, bool, 0444); >> MODULE_PARM_DESC(force_load, "Force load this driver on supported older platforms (experimental)"); >> >> +/* Force to disable Smart PC Solution */ >> +static bool disable_smart_pc; >> +module_param(disable_smart_pc, bool, 0444); >> +MODULE_PARM_DESC(disable_smart_pc, "Disable Smart PC Solution"); >> + >> static int amd_pmf_pwr_src_notify_call(struct notifier_block *nb, unsigned long event, void *data) >> { >> struct amd_pmf_dev *pmf = container_of(nb, struct amd_pmf_dev, pwr_src_notifier); >> @@ -362,11 +367,15 @@ static void amd_pmf_init_features(struct amd_pmf_dev *dev) >> dev_dbg(dev->dev, "SPS enabled and Platform Profiles registered\n"); >> } >> >> - amd_pmf_init_smart_pc(dev); >> - if (dev->smart_pc_enabled) { >> - dev_dbg(dev->dev, "Smart PC Solution Enabled\n"); >> - /* If Smart PC is enabled, no need to check for other features */ >> - return; >> + if (disable_smart_pc) { >> + dev->smart_pc_enabled = false; >> + } else { >> + amd_pmf_init_smart_pc(dev); >> + if (dev->smart_pc_enabled) { >> + dev_dbg(dev->dev, "Smart PC Solution Enabled\n"); >> + /* If Smart PC is enabled, no need to check for other features */ >> + return; >> + } >> } >> >> if (is_apmf_func_supported(dev, APMF_FUNC_AUTO_MODE)) { >