iPXE
BusSpecificDriverOverride.h
Go to the documentation of this file.
00001 /** @file
00002   Bus Specific Driver Override protocol as defined in the UEFI 2.0 specification.
00003 
00004   Bus drivers that have a bus specific algorithm for matching drivers to controllers are
00005   required to produce this protocol for each controller. For example, a PCI Bus Driver will produce an
00006   instance of this protocol for every PCI controller that has a PCI option ROM that contains one or
00007   more UEFI drivers. The protocol instance is attached to the handle of the PCI controller.
00008 
00009   Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR>
00010   This program and the accompanying materials
00011   are licensed and made available under the terms and conditions of the BSD License
00012   which accompanies this distribution.  The full text of the license may be found at
00013   http://opensource.org/licenses/bsd-license.php
00014 
00015   THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
00016   WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
00017 
00018 **/
00019 
00020 #ifndef _EFI_BUS_SPECIFIC_DRIVER_OVERRIDE_PROTOCOL_H_
00021 #define _EFI_BUS_SPECIFIC_DRIVER_OVERRIDE_PROTOCOL_H_
00022 
00023 FILE_LICENCE ( BSD3 );
00024 
00025 ///
00026 /// Global ID for the Bus Specific Driver Override Protocol
00027 ///
00028 #define EFI_BUS_SPECIFIC_DRIVER_OVERRIDE_PROTOCOL_GUID \
00029   { \
00030     0x3bc1b285, 0x8a15, 0x4a82, {0xaa, 0xbf, 0x4d, 0x7d, 0x13, 0xfb, 0x32, 0x65 } \
00031   }
00032 
00033 typedef struct _EFI_BUS_SPECIFIC_DRIVER_OVERRIDE_PROTOCOL  EFI_BUS_SPECIFIC_DRIVER_OVERRIDE_PROTOCOL;
00034 
00035 //
00036 // Prototypes for the Bus Specific Driver Override Protocol
00037 //
00038 
00039 /**
00040   Uses a bus specific algorithm to retrieve a driver image handle for a controller.
00041 
00042   @param  This                  A pointer to the EFI_BUS_SPECIFIC_DRIVER_
00043                                 OVERRIDE_PROTOCOL instance.
00044   @param  DriverImageHandle     On input, a pointer to the previous driver image handle returned
00045                                 by GetDriver(). On output, a pointer to the next driver
00046                                 image handle. Passing in a NULL, will return the first driver
00047                                 image handle.
00048 
00049   @retval EFI_SUCCESS           A bus specific override driver is returned in DriverImageHandle.
00050   @retval EFI_NOT_FOUND         The end of the list of override drivers was reached.
00051                                 A bus specific override driver is not returned in DriverImageHandle.
00052   @retval EFI_INVALID_PARAMETER DriverImageHandle is not a handle that was returned on a
00053                                 previous call to GetDriver().
00054 
00055 **/
00056 typedef
00057 EFI_STATUS
00058 (EFIAPI *EFI_BUS_SPECIFIC_DRIVER_OVERRIDE_GET_DRIVER)(
00059   IN EFI_BUS_SPECIFIC_DRIVER_OVERRIDE_PROTOCOL              *This,
00060   IN OUT EFI_HANDLE                                         *DriverImageHandle
00061   );
00062 
00063 ///
00064 /// This protocol matches one or more drivers to a controller. This protocol is produced by a bus driver,
00065 /// and it is installed on the child handles of buses that require a bus specific algorithm for matching
00066 /// drivers to controllers.
00067 ///
00068 struct _EFI_BUS_SPECIFIC_DRIVER_OVERRIDE_PROTOCOL {
00069   EFI_BUS_SPECIFIC_DRIVER_OVERRIDE_GET_DRIVER GetDriver;
00070 };
00071 
00072 extern EFI_GUID gEfiBusSpecificDriverOverrideProtocolGuid;
00073 
00074 #endif