Re: [PATCH v5 2/8] x86/sev: Add support for the RMPREAD instruction

From: Borislav Petkov
Date: Tue Nov 12 2024 - 13:41:35 EST


On Mon, Oct 28, 2024 at 02:32:37PM -0500, Tom Lendacky wrote:
> + if (cpu_feature_enabled(X86_FEATURE_RMPREAD)) {
> + int ret;
> +
> + /* RMPREAD */

Now that we know:

/* Supported in binutils version 2.44 */

> + asm volatile(".byte 0xf2, 0x0f, 0x01, 0xfd"
> + : "=a" (ret)
> + : "a" (pfn << PAGE_SHIFT), "c" (e)
> + : "memory", "cc");
> +

--
Regards/Gruss,
Boris.

https://people.kernel.org/tglx/notes-about-netiquette