Re: [PATCH v9 04/11] x86/virt/tdx: Allocate refcounts for Dynamic PAMT memory
Dave Hansen <[email protected]>
| Newsgroups | dev.linux.lists.sashiko-reviews,dev.linux.lists.linux-coco,org.kernel.vger.kvm,org.kernel.vger.linux-doc,org.kernel.vger.linux-kernel |
|---|---|
| Message-ID | <[email protected]> |
On 8/6/26 15:02, Edgecombe, Rick P wrote: > On Thu, 2026-08-06 at 02:21 +0000, [email protected] wrote: >> [Severity: High] >> Could this vzalloc() call trigger a kernel panic on systems with sparse >> memory layouts instead of gracefully disabling TDX? ... > I think this is a bit overblown. If there is a lot of memory such that this > allocation is large, we can expect it be less likely to fail. Yes, it could trigger a kernel panic. And, yes, sashiko's concern is overblown. This code only runs on the host side, so there's no exotic VM craziness. In reality, today, there are not many TDX systems. The ones that do exist don't have exotic sparse memory layouts either. TDX also doesn't yet support any of the emerging memory technologies like CXL.mem that might lead to bare-metal weirdo layouts. But even in a future with a pathologically evil memory layout, is anyone going to miss 8GB of memory on a server? Probably not. So, yeah, I just don't see the point of going crazy over this. If someone hits this in 10 years, we'll fix it then. Oooh, maybe I'll be retired in 10 years. One can dream.