15.2 GetVersion() Implementation
The example below shows an example implementation of the GetVersion()
function of the Driver Family Override Protocol. This function returns a
UNIT32
value and, in this case, returns a value from a define statement in
the UEFI Driver. The manufacturer of a family of controllers is free to select
any version value assignment as long as UEFI Drivers that are required to be
used over previously released UEFI Drivers have higher values.
Example 159-GetVersion() Function of the Driver Family Override Protocol
#include <Uefi.h>
#include <Protocol/DriverFamilyOverride.h>
#define ABC_DRIVER_FAMILY_OVERRIDE_VERSION 0x00050063
UINT32
EFIAPI
AbcGetVersion (
IN EFI_DRIVER_FAMILY_OVERRIDE_PROTOCOL *This
)
{
return ABC_DRIVER_FAMILY_OVERRIDE_VERSION;
}