On 1/25/24 13:05, Ni, Ray wrote:
> Laszlo,
> SMI handler is called from SmmCore.
> So SmmCore knows which handle is passed to the SMI handler.
> How about let Unregister() rejects the request coming from a SMI handler 
> which unregisters other handles?
> 
> A "gCurrentSmiHandle" can be assigned before calling the SMI handler and set 
> to NULL when it returns.
> Unregister() compares the handle against gCurrentSmiHandle if it's not NULL.

Sounds safe enough. I don't know if it conforms to the spec however
(although we might just choose not to care about that).

Laszlo



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#114458): https://edk2.groups.io/g/devel/message/114458
Mute This Topic: https://groups.io/mt/103925794/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: 
https://edk2.groups.io/g/devel/leave/9847357/21656/1706620634/xyzzy 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Reply via email to