Re: [PATCH] KVM: SVM: Consider NUMA affinity when allocating per-CPU save_area

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Apr 23, 2024, Yosry Ahmed wrote:
> On Tue, Apr 23, 2024 at 11:43 AM Sean Christopherson <seanjc@xxxxxxxxxx> wrote:
> > But snp_safe_alloc_page() should again flow alloc_pages() and pass numa_node_id(),
> > not NUMA_NO_NODE.
> 
> alloc_pages_node() will use numa_node_id() if you pass in NUMA_NO_NODE.

The code uses numa_mem_id()

	if (nid == NUMA_NO_NODE)
		nid = numa_mem_id();

which is presumably the exact same thing as numa_node_id() on x86.  But I don't
want to have to think that hard :-)

In other words, all I'm saying is that if we want to mirror alloc_pages() and
alloc_pages_node(), then we should mirror them exactly.

> That's the documented behavior and it seems to be widely
> used. I don't see anyone using numa_node_id() directly with
> alloc_pages_node().







[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux