Re: [PATCH v3 14/62] KVM: SVM: Track AVIC tables as natively sized pointers, not "struct pages"

From: Naveen N Rao
Date: Tue Jun 17 2025 - 11:10:40 EST


On Wed, Jun 11, 2025 at 03:45:17PM -0700, Sean Christopherson wrote:
> @@ -277,8 +265,8 @@ static int avic_init_backing_page(struct kvm_vcpu
> *vcpu)
> return 0;
> }
>
> - BUILD_BUG_ON((AVIC_MAX_PHYSICAL_ID + 1) * sizeof(*table) > PAGE_SIZE ||
> - (X2AVIC_MAX_PHYSICAL_ID + 1) * sizeof(*table) > PAGE_SIZE);
> + BUILD_BUG_ON((AVIC_MAX_PHYSICAL_ID + 1) * sizeof(new_entry) > PAGE_SIZE ||
> + (X2AVIC_MAX_PHYSICAL_ID + 1) * sizeof(new_entry) > PAGE_SIZE);

Ah, you change to 'new_entry' here. Would be good to rename it to just
'entry', but that's a minor nit. Ignore my comment on the previous
patch.

For this patch:
Acked-by: Naveen N Rao (AMD) <naveen@xxxxxxxxxx>


- Naveen