• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /* SPDX-License-Identifier: BSD-3-Clause */
2 
3 #ifndef __EFI_WRAPPER_H__
4 #define __EFI_WRAPPER_H__
5 
6 #define EFI_WRAPPER_VER 2
7 
8 /* Provide generic x86 calling conventions. */
9 #define ABI_X86 __attribute((regparm(0)))
10 
11 /* Errors returned by the EFI wrapper. */
12 enum efi_wrapper_error {
13 	INVALID_VER = -1,
14 };
15 
16 struct efi_wrapper_params {
17 	/* Mainboard Inputs */
18 	int version;
19 
20 	void ABI_X86(*console_out)(unsigned char byte);
21 
22 	unsigned int tsc_ticks_per_microsecond;
23 } __packed;
24 
25 typedef int ABI_X86(*efi_wrapper_entry_t)(struct efi_wrapper_params *);
26 #endif
27