summaryrefslogtreecommitdiffstats
path: root/IntelFrameworkModulePkg/Universal/DriverSampleDxe/DriverSample.h
blob: e32927d7a79825dea251e0ac4cfd52cc78307f75 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
/**@file

  This is an example of how a driver might export data to the HII protocol to be
  later utilized by the Setup Protocol
  
Copyright (c) 2006, Intel Corporation
All rights reserved. This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution.  The full text of the license may be found at
http://opensource.org/licenses/bsd-license.php

THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.

**/
#ifndef _DRIVER_SAMPLE_H
#define _DRIVER_SAMPLE_H



#include <PiDxe.h>

#include <Protocol/FormCallbackFramework.h>
#include <Protocol/HiiFramework.h>

#include <Library/UefiBootServicesTableLib.h>
#include <Library/UefiRuntimeServicesTableLib.h>
#include <Library/DebugLib.h>
#include <Library/UefiDriverEntryPoint.h>
#include <Library/BaseLib.h>
#include <Library/PrintLib.h>
#include <Library/IfrSupportLibFramework.h>
#include <Library/BaseMemoryLib.h>
#include <Library/MemoryAllocationLib.h>
#include <Library/HiiLibFramework.h>

#include "NVDataStruc.h"

//
// This is the generated header file which includes whatever needs to be exported (strings + IFR)
//

extern UINT8  VfrBin[];
//
// extern UINT8 VfrStringsStr[];
//
extern UINT8  InventoryBin[];
//
// extern UINT8 InventoryStringsStr[];
//
extern UINT8  DriverSampleDxeStrings[];

#define SAMPLE_STRING               L"This is an error!"

#define EFI_CALLBACK_INFO_SIGNATURE EFI_SIGNATURE_32 ('C', 'l', 'b', 'k')

typedef struct {
  UINTN                       Signature;
  EFI_HANDLE                  CallbackHandle;
  EFI_FORM_CALLBACK_PROTOCOL  DriverCallback;
  UINT16                      *KeyList;
  VOID                        *FormBuffer;
  EFI_HII_HANDLE              RegisteredHandle;
  EFI_HII_PROTOCOL            *Hii;
} EFI_CALLBACK_INFO;

#define EFI_CALLBACK_INFO_FROM_THIS(a)  CR (a, EFI_CALLBACK_INFO, DriverCallback, EFI_CALLBACK_INFO_SIGNATURE)

#endif