[edk2-devel] [RFC PATCH 0/5] support CPU hot-unplug

Laszlo Ersek lersek at redhat.com
Mon Dec 21 19:58:48 UTC 2020


On 12/21/20 20:09, Ankur Arora wrote:
> On 2020-12-21 6:44 a.m., Laszlo Ersek wrote:
>> Hi Ankur,
>>
>> On 12/08/20 06:34, Ankur Arora wrote:
>>> [ Resending to the correct edk2 alias this time. ]
>>>
>>> Hi,
>>>
>>> This series adds support for CPU hot-unplug with OVMF.
>>>
>>> Please see this in conjunction with the QEMU v2 series posted here:
>>>   
>>> https://lore.kernel.org/qemu-devel/20201207140739.3829993-1-imammedo@redhat.com/
>>>
>>>
>>> In particular, would be glad for comments on Patch 4, specifically
>>> where we should be ejecting the CPU.
>>>
>>> Right now the ejection happens in UnplugCpus() (called from
>>> CpuHotplugMmi()):
>>>    +    QemuCpuhpWriteCpuSelector (mMmCpuIo, RemoveApicId);
>>>    +    QemuCpuhpWriteCpuStatus (mMmCpuIo, QEMU_CPUHP_STAT_EJECTED);
>>>
>>> That is way too early -- given that the actual unplug will happen
>>> in SmmCpuUpdate() and given that the BSPHandler() would have waited
>>> for the APs multiple times before then.
>>>
>>> Another possibility is that the actual ejection be deferred to the
>>> _EJ0 method after the return from the SMI. But, that seems like a
>>> hack. Additionally, Igor points out here that this approach has
>>> problems:
>>>   
>>> https://lore.kernel.org/qemu-devel/20201204170939.1815522-1-imammedo@redhat.com/
>>>
>>
>> I've filed:
>>
>>    https://bugzilla.tianocore.org/show_bug.cgi?id=3132
>>
>> Can you please register an account in the TianoCore Bugzilla at
>> <https://bugzilla.tianocore.org/>, and assign the above ticket to
>> yourself?
>>
>> And then, the URL of the new BZ ticket should be included in every
>> commit message, like this:
>>
>> Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=3132
>>
>> just above your S-o-b.
> 
> Sure. Will do.
>  
>> No need to repost just because of this; I'll review the RFC series later.
> 
> Actually could you hold off before reviewing the RFC series. I'll be
> sending
> a v2 series shortly. That does the actual unplug via
> SmmCpuFeaturesRendezvousExit()
> (I had described the approach elsewhere in this thread.)

Sure, I can de-queue the RFC series. I planned to review it anyway in
the new year; I've just done some admin stuff around the feature now.

Thanks
Laszlo



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#69339): https://edk2.groups.io/g/devel/message/69339
Mute This Topic: https://groups.io/mt/78802720/1813853
Group Owner: devel+owner at edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [edk2-devel-archive at redhat.com]
-=-=-=-=-=-=-=-=-=-=-=-





More information about the edk2-devel-archive mailing list