linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Huang, Kai" <kai.huang@intel.com>
To: "tglx@linutronix.de" <tglx@linutronix.de>,
	"khaliidcaliy@gmail.com" <khaliidcaliy@gmail.com>,
	"mingo@redhat.com" <mingo@redhat.com>,
	"bp@alien8.de" <bp@alien8.de>,
	"dave.hansen@linux.intel.com" <dave.hansen@linux.intel.com>
Cc: "hpa@zytor.com" <hpa@zytor.com>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"khaliidcaly@gmail.com" <khaliidcaly@gmail.com>,
	"x86@kernel.org" <x86@kernel.org>
Subject: Re: [PATCH v8] x86/boot: Don't return encryption mask from __startup_64()
Date: Wed, 16 Jul 2025 11:33:19 +0000	[thread overview]
Message-ID: <51aad9762bca3678f0d79adf72728e54c67973ce.camel@intel.com> (raw)
In-Reply-To: <20250716091332.737-1-khaliidcaliy@gmail.com>

On Wed, 2025-07-16 at 09:11 +0000, Khalid Ali wrote:
> From: Khalid Ali <khaliidcaly@gmail.com>
> 
> Avoid returning encryption mask to callers of __startup_64().
> 
> The encryption mask is available to callers and canbe accessed
						  ^
						  can be

> sme_get_me_mask() in C code and sme_me_mask symbol in assembly code.
> 
> This change aligns the way the mask is retrieved in
> secondary_startup_64_no_verify().
> 
> No functionality change intended, only consistency improvement, so the
> code becomes cleaner.
> 
> On intel processors sme_me_mask is zero. So, it is safe to add mask only
> if CONFIG_AMD_MEM_ENCRYPT.
> 
> Signed-off-by: Khalid Ali <khaliidcaly@gmail.com>
> Acked-by: Kai Huang <kai.huang@intel.com>
> ---
> 
> Changes in v8:
>   * Improve commit message for clarity.

Apparently not jut commit message change, since ...



>  	/*
>  	 * Perform pagetable fixups. Additionally, if SME is active, encrypt
> -	 * the kernel and retrieve the modifier (SME encryption mask if SME
> -	 * is active) to be added to the initial pgdir entry that will be
> -	 * programmed into CR3.
> -	 */
> +	 * the kernel.
> +	*/

... the indent of this comment is broken.  Your v7 was fine.

And ...

>  	movq	%r15, %rsi
>  	call	__startup_64
>  
>  	/* Form the CR3 value being sure to include the CR3 modifier */
> -	leaq	early_top_pgt(%rip), %rcx
> -	addq	%rcx, %rax
> +	leaq	early_top_pgt(%rip), %rax
>  
>  #ifdef CONFIG_AMD_MEM_ENCRYPT
> +	/* Retrieve the modifier (SME encryption mask if SME
> +	 * is active) to be added to the initial pgdir entry that will be
> +	 * programmed into CR3.
> +	 */

... this comment style is broken too.  Again, your v7 was fine:

+	/*
+	 * Retrieve the modifier (SME encryption mask if SME
+	 * is active) to be added to the initial pgdir entry that will be
+	 * programmed into CR3.
+	 */


I am not sure how you ended up with those random broken changes, because
they are quite unusual to me.

Could you please remove my Acked-by?

      reply	other threads:[~2025-07-16 11:33 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-07-16  9:11 [PATCH v8] x86/boot: Don't return encryption mask from __startup_64() Khalid Ali
2025-07-16 11:33 ` Huang, Kai [this message]

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=51aad9762bca3678f0d79adf72728e54c67973ce.camel@intel.com \
    --to=kai.huang@intel.com \
    --cc=bp@alien8.de \
    --cc=dave.hansen@linux.intel.com \
    --cc=hpa@zytor.com \
    --cc=khaliidcaliy@gmail.com \
    --cc=khaliidcaly@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@redhat.com \
    --cc=tglx@linutronix.de \
    --cc=x86@kernel.org \
    /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;
as well as URLs for NNTP newsgroup(s).