mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Hans de Goede <hdegoede@redhat.com>
To: Mario Limonciello <mario.limonciello@amd.com>, Shyam-sundar.S-k@amd.com
Cc: platform-driver-x86@vger.kernel.org,
	linux-kernel@vger.kernel.org,
	Linux regressions mailing list <regressions@lists.linux.dev>
Subject: Re: [PATCH 1/2] platform/x86/amd/pmf: Add debugging message for missing policy data
Date: Sun, 18 Feb 2024 11:26:57 +0100	[thread overview]
Message-ID: <3e81d005-663d-4c80-b9e9-5ddf56600c56@redhat.com> (raw)
In-Reply-To: <20240217012205.113614-2-mario.limonciello@amd.com>

Hi,

On 2/17/24 02:22, Mario Limonciello wrote:
> If a machine advertises Smart PC support but is missing policy data
> show a debugging message to help clarify why Smart PC wasn't enabled.
> 
> Signed-off-by: Mario Limonciello <mario.limonciello@amd.com>

Thanks, patch looks good to me:

Reviewed-by: Hans de Goede <hdegoede@redhat.com>

Regards,

Hans



> ---
>  drivers/platform/x86/amd/pmf/tee-if.c | 4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/platform/x86/amd/pmf/tee-if.c b/drivers/platform/x86/amd/pmf/tee-if.c
> index 8b7e3f87702e..1359ab340f7c 100644
> --- a/drivers/platform/x86/amd/pmf/tee-if.c
> +++ b/drivers/platform/x86/amd/pmf/tee-if.c
> @@ -252,8 +252,10 @@ static int amd_pmf_start_policy_engine(struct amd_pmf_dev *dev)
>  	cookie = readl(dev->policy_buf + POLICY_COOKIE_OFFSET);
>  	length = readl(dev->policy_buf + POLICY_COOKIE_LEN);
>  
> -	if (cookie != POLICY_SIGN_COOKIE || !length)
> +	if (cookie != POLICY_SIGN_COOKIE || !length) {
> +		dev_dbg(dev->dev, "cookie doesn't match\n");
>  		return -EINVAL;
> +	}
>  
>  	/* Update the actual length */
>  	dev->policy_sz = length + 512;


  reply	other threads:[~2024-02-18 10:27 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-02-17  1:22 [PATCH 0/2] AMD PMF Smart PC error handling cleanups Mario Limonciello
2024-02-17  1:22 ` [PATCH 1/2] platform/x86/amd/pmf: Add debugging message for missing policy data Mario Limonciello
2024-02-18 10:26   ` Hans de Goede [this message]
2024-02-17  1:22 ` [PATCH 2/2] platform/x86/amd/pmf: Fixup error handling for amd_pmf_init_smart_pc() Mario Limonciello
2024-02-18 11:01   ` Hans de Goede

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=3e81d005-663d-4c80-b9e9-5ddf56600c56@redhat.com \
    --to=hdegoede@redhat.com \
    --cc=Shyam-sundar.S-k@amd.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mario.limonciello@amd.com \
    --cc=platform-driver-x86@vger.kernel.org \
    --cc=regressions@lists.linux.dev \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®