本文整理汇总了C++中EFI_BOOT_SERVICES::UninstallMultipleProtocolInterfaces方法的典型用法代码示例。如果您正苦于以下问题:C++ EFI_BOOT_SERVICES::UninstallMultipleProtocolInterfaces方法的具体用法?C++ EFI_BOOT_SERVICES::UninstallMultipleProtocolInterfaces怎么用?C++ EFI_BOOT_SERVICES::UninstallMultipleProtocolInterfaces使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类EFI_BOOT_SERVICES
的用法示例。
在下文中一共展示了EFI_BOOT_SERVICES::UninstallMultipleProtocolInterfaces方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1:
EFI_STATUS EFIAPI
OvrUninstallMultipleProtocolInterfaces(
IN EFI_HANDLE Handle,
...
)
{
EFI_STATUS Status;
EFI_HANDLE HandleIn = Handle;
VA_LIST Args;
EFI_GUID *Protocol[4];
VOID *Interface[4];
UINTN Index;
// again, va args ... we'll just have to support constant number
VA_START(Args, Handle);
// will start with Index=1 to cover the case when no Protocol/Interface is specified at all
for (Index = 1; Index < 4; Index++) {
Protocol[Index] = VA_ARG(Args, EFI_GUID *);
if (Protocol[Index] == NULL) {
Index--;
break;
}
Interface[Index] = VA_ARG(Args, VOID *);
}
VA_END(Args);
switch (Index) {
case 0:
Status = gOrgBS.UninstallMultipleProtocolInterfaces(Handle);
PRINT("->UninstallMultipleProtocolInterfaces(%p/%p) = %r\n", HandleIn, Handle, Status);
break;
case 1:
Status = gOrgBS.UninstallMultipleProtocolInterfaces(Handle, Protocol[1], Interface[1]);
PRINT("->UninstallMultipleProtocolInterfaces(%p/%p, %s, %p) = %r\n",
HandleIn, Handle,
GuidStr(Protocol[1]), Interface[1],
Status);
break;
case 2:
Status = gOrgBS.UninstallMultipleProtocolInterfaces(Handle, Protocol[1], Interface[1], Protocol[2], Interface[2]);
PRINT("->UninstallMultipleProtocolInterfaces(%p/%p, %s, %p, %s, %p) = %r\n",
HandleIn, Handle,
GuidStr(Protocol[1]), Interface[1],
GuidStr(Protocol[2]), Interface[2],
Status);
break;
case 3:
Status = gOrgBS.UninstallMultipleProtocolInterfaces(Handle, Protocol[1], Interface[1], Protocol[2], Interface[2], Protocol[3], Interface[3]);
PRINT("->UninstallMultipleProtocolInterfaces(%p/%p, %s, %p, %s, %p, %s, %p) = %r\n",
HandleIn, Handle,
GuidStr(Protocol[1]), Interface[1],
GuidStr(Protocol[2]), Interface[2],
GuidStr(Protocol[3]), Interface[3],
Status);
break;
default:
Status = EFI_UNSUPPORTED;
PRINT("->UninstallMultipleProtocolInterfaces(%p, ...) = %r, too many Protocol/Interface pairs\n", Handle, Status);
break;
}
return Status;
}