[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250319234422.GG126678@ziepe.ca>
Date: Wed, 19 Mar 2025 20:44:22 -0300
From: Jason Gunthorpe <jgg@...pe.ca>
To: Stefano Garzarella <sgarzare@...hat.com>
Cc: Tom Lendacky <thomas.lendacky@....com>,
Jarkko Sakkinen <jarkko@...nel.org>,
Peter Huewe <peterhuewe@....de>, x86@...nel.org,
linux-kernel@...r.kernel.org, Borislav Petkov <bp@...en8.de>,
linux-integrity@...r.kernel.org, Dov Murik <dovmurik@...ux.ibm.com>,
Dionna Glaze <dionnaglaze@...gle.com>, linux-coco@...ts.linux.dev,
James Bottomley <James.Bottomley@...senpartnership.com>,
Claudio Carvalho <cclaudio@...ux.ibm.com>,
Ingo Molnar <mingo@...hat.com>, "H. Peter Anvin" <hpa@...or.com>,
Thomas Gleixner <tglx@...utronix.de>,
Dave Hansen <dave.hansen@...ux.intel.com>,
Joerg Roedel <jroedel@...e.de>
Subject: Re: [PATCH v3 3/4] tpm: add SNP SVSM vTPM driver
On Tue, Mar 18, 2025 at 05:18:53PM +0100, Stefano Garzarella wrote:
> I see, thanks for the clarification!
> I saw that with devm_get_free_pages() I can easily allocate a
> resource-managed page, so I'll do that in v4.
As a general note you should just use kmalloc these days, even for
PAGE_SIZE. It is efficient and OK.
Having a struct that is PAGE_SIZE+1 is not efficient and will waste
a page of memory. That should be avoided ..
Jason
Powered by blists - more mailing lists