Exemplo n.º 1
0
/**
 *  Creates/installs the BlackBox Interface and eminating Entry Point node list.
 *  @param  ImageHandle The test driver image handle
 *  @param  SystemTable Pointer to System Table
 *  @return EFI_SUCCESS Indicates the interface was installed
 *  @return EFI_OUT_OF_RESOURCES Indicates space for the new handle could not be allocated
 *  @return EFI_INVALID_PARAMETER: One of the parameters has an invalid value.
 */
EFI_STATUS
InitializeBBTestPxeBCProtocol (
  IN EFI_HANDLE           ImageHandle,
  IN EFI_SYSTEM_TABLE     *SystemTable
  )
{
  EFI_STATUS Status;

  EfiInitializeTestLib (ImageHandle, SystemTable);
  InitializeLib (ImageHandle, SystemTable);
  EfiInitializeDriverLib (ImageHandle, SystemTable);

  Status = gtBS->CreateEvent (EFI_EVENT_TIMER, 0, NULL, NULL, &TimerEvent);
  if (EFI_ERROR(Status)) {
    return Status;
  }

  Status = GetSystemDevicePathAndFilePath (ImageHandle);
  if (EFI_ERROR(Status)) {
    return Status;
  }

  return EfiInitAndInstallBBTestInterface (
           &ImageHandle,
           &gEfiPxeBcTestProtField,
           gPxeTestEntryField,
           BBTestPxeBcUnload,
           &gBBTestProtocolInterface
           );
}
Exemplo n.º 2
0
EFI_STATUS
InitializeBBTestDeviceIo (
  IN EFI_HANDLE           ImageHandle,
  IN EFI_SYSTEM_TABLE     *SystemTable
  )
/*++

Routine Description:
  Creates/installs the BlackBox Interface and eminating Entry Point node list.

Arguments:
  ImageHandle:  NULL
  *SystemTable: Pointer to System Table

Returns:
  EFI_SUCCESS:              Indicates the interface was installed.
  EFI_OUT_OF_RESOURCES:     Indicates space for the new handle could not be allocated
  EFI_INVALID_PARAMETER:    One of the parameters has an invalid value.

--*/
{
  EfiInitializeTestLib (ImageHandle, SystemTable);
  InitializeLib (ImageHandle, SystemTable);
  GetSystemDevicePathAndFilePath (ImageHandle);

  return  EfiInitAndInstallIHVBBTestInterface (
            &ImageHandle,
            &gBBTestProtocolField,
            gBBTestEntryField,
            BBTestDeviceIoUnload,
            &gBBTestProtocolInterface
            );

}
Exemplo n.º 3
0
EFI_STATUS
InitializeBBTestPciRootBridgeIo (
    IN EFI_HANDLE           ImageHandle,
    IN EFI_SYSTEM_TABLE     *SystemTable
)
{
    //
    //initialize all the library to be used in this driver.
    //
    EfiInitializeTestLib (ImageHandle, SystemTable);
    InitializeLib (ImageHandle, SystemTable);

    GetSystemDevicePathAndFilePath (ImageHandle);

    return EfiInitAndInstallBBTestInterface (
               &ImageHandle,
               &gBBTestProtocolField,
               gBBTestEntryField,
               BBTestPciRootBridgeIoUnload,
               &gBBTestProtocolInterface
           );
}