From: Jacob Xu <jacobhxu@google.com>
To: jeremy.compostella@intel.com
Cc: acdunlap@google.com, Thomas.Lendacky@amd.com,
michael.roth@amd.com, ashish.kalra@amd.com, bp@alien8.de,
felix-coreboot@felixheld.de, kirill.shutemov@linux.intel.com,
linux-kernel@vger.kernel.org, mingo@kernel.org, x86@kernel.org
Subject: Re: Reserved bits and commit x86/sev-es: Set x86_virt_bits to the correct value straight away, instead of a two-phase approach
Date: Tue, 30 Jan 2024 21:33:54 +0000 [thread overview]
Message-ID: <20240130213354.863963-1-jacobhxu@google.com> (raw)
In-Reply-To: <87jzribcvn.fsf@jcompost-mobl.amr.corp.intel.com>
Adding some AMD folk to the thread here.
For AMD CPUs, initialization of c->x86_phys_bits occurs in
get_cpu_address_sizes() which is called from early_identify_cpu().
However, early_identify_cpu() will first call early_init_amd() which adjusts
x86_phys_bits based on the PhysAddrReduction CPUID field.
c->x86_phys_bits -= (cpuid_ebx(0x8000001f) >> 6) & 0x3f;
Thus, this adjustment is ignored.
Adding a new cpu_dev callback to calculate num reserved_cpu_bits makes sense to
me, hopefully the AMD folk can chime in here though.
Jacob
next prev parent reply other threads:[~2024-01-30 21:33 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-10-18 22:26 Reserved bits and commit x86/sev-es: Set x86_virt_bits to the correct value straight away, instead of a two-phase approach Compostella, Jeremy
2023-10-18 23:02 ` Adam Dunlap
2023-10-18 23:39 ` Compostella, Jeremy
2023-10-19 20:01 ` Compostella, Jeremy
2024-01-30 21:33 ` Jacob Xu [this message]
2024-01-30 21:44 ` Jacob Xu
2024-01-31 21:34 ` Tom Lendacky
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=20240130213354.863963-1-jacobhxu@google.com \
--to=jacobhxu@google.com \
--cc=Thomas.Lendacky@amd.com \
--cc=acdunlap@google.com \
--cc=ashish.kalra@amd.com \
--cc=bp@alien8.de \
--cc=felix-coreboot@felixheld.de \
--cc=jeremy.compostella@intel.com \
--cc=kirill.shutemov@linux.intel.com \
--cc=linux-kernel@vger.kernel.org \
--cc=michael.roth@amd.com \
--cc=mingo@kernel.org \
--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