Re: [PATCH v4 4/6] KVM: X86: Implement PV IPIs send hypercall
From: Wanpeng Li
Date: Mon Jul 23 2018 - 02:22:31 EST
On Mon, 23 Jul 2018 at 14:19, Paolo Bonzini <pbonzini@xxxxxxxxxx> wrote:
>
> On 23/07/2018 08:10, Wanpeng Li wrote:
> >>> On 20/07/2018 18:28, Wanpeng Li wrote:
> >>>> +a0: ipi_bitmap low 64 bits
> >>>> +a1: ipi_bitmap high 64 bits
> >>>> +a2: the lowest APIC ID in bitmap
> >>>> +a3: APIC ICR
> >>>> +
> >>>> +The hypercall lets a guest send multicast IPIs at most can handle
> >>>> +128 vCPUs per hypercall on 64-bit machines and 64 vCPUs per hypercall
> >>>> +on 32-bit machines.
> >>>> +
> >>>> +Returns 0 if successfully delivery the IPIs and 1 if discarded.
> >>> This description does not mention what happens in 32-bit mode.
> > Sorry, I think I mentioned "64 vCPUs per hypercall on 32-bit machines" above.
>
> Yes, but the description of a0 and a1 is not accurate. Something like
>
> a0: lower part of the bitmap of destination APIC IDs
> a1: higher part of the bitmap of destination APIC IDs
> ....
>
> The hypercall lets a guest send multicast IPIs, with at most 128
> 128 destinations per hypercall in 64-bit mode and 64 vCPUs per
> hypercall in 32-bit mode. The destinations are represented by a bitmap
> contained in the first two arguments (a0 and a1). Bit 0 of a0
> corresponds to the APIC ID in the third argument (a2), bit 1 corresponds
> to the APIC ID a2+1, and so on.
Thanks to the great description, I will fold this to the next version.
Regards,
Wanpeng Li