lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250815102537.GCaJ8LIZodp1yY39QA@fat_crate.local>
Date: Fri, 15 Aug 2025 12:25:37 +0200
From: Borislav Petkov <bp@...en8.de>
To: Neeraj Upadhyay <Neeraj.Upadhyay@....com>
Cc: linux-kernel@...r.kernel.org, tglx@...utronix.de, mingo@...hat.com,
	dave.hansen@...ux.intel.com, Thomas.Lendacky@....com,
	nikunj@....com, Santosh.Shukla@....com, Vasant.Hegde@....com,
	Suravee.Suthikulpanit@....com, David.Kaplan@....com, x86@...nel.org,
	hpa@...or.com, peterz@...radead.org, seanjc@...gle.com,
	pbonzini@...hat.com, kvm@...r.kernel.org,
	kirill.shutemov@...ux.intel.com, huibo.wang@....com,
	naveen.rao@....com, francescolavra.fl@...il.com,
	tiala@...rosoft.com
Subject: Re: [PATCH v9 02/18] x86/apic: Initialize Secure AVIC APIC backing
 page

On Mon, Aug 11, 2025 at 03:14:28PM +0530, Neeraj Upadhyay wrote:
> With Secure AVIC, the APIC backing page is owned and managed by guest.

Please use articles: "...and managed by the guest."

Check all your text pls.

> +enum es_result savic_register_gpa(u64 gpa)
> +{
> +	struct ghcb_state state;
> +	struct es_em_ctxt ctxt;
> +	enum es_result res;
> +	struct ghcb *ghcb;
> +
> +	guard(irqsave)();
> +
> +	ghcb = __sev_get_ghcb(&state);
> +	vc_ghcb_invalidate(ghcb);
> +
> +	ghcb_set_rax(ghcb, SVM_VMGEXIT_SAVIC_SELF_GPA);
> +	ghcb_set_rbx(ghcb, gpa);
> +	res = sev_es_ghcb_hv_call(ghcb, &ctxt, SVM_VMGEXIT_SAVIC,
> +				  SVM_VMGEXIT_SAVIC_REGISTER_GPA, 0);
> +
> +	__sev_put_ghcb(&state);
> +
> +	return res;
> +}

I was gonna say put this into a new arch/x86/coco/sev/savic.c but ok, you're
adding only two functions.

> +struct secure_avic_page {
> +	u8 regs[PAGE_SIZE];
> +} __aligned(PAGE_SIZE);
> +
> +static struct secure_avic_page __percpu *secure_avic_page __ro_after_init;


static struct secure_avic_page __percpu *savic_page __ro_after_init;

-- 
Regards/Gruss,
    Boris.

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

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ