VirtualBox

source: vbox/trunk/include/iprt/formats/efi-common.h@ 93941

Last change on this file since 93941 was 93115, checked in by vboxsync, 3 years ago

scm --update-copyright-year

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 2.7 KB
Line 
1/* $Id: efi-common.h 93115 2022-01-01 11:31:46Z vboxsync $ */
2/** @file
3 * IPRT, EFI common definitions.
4 */
5
6/*
7 * Copyright (C) 2021-2022 Oracle Corporation
8 *
9 * This file is part of VirtualBox Open Source Edition (OSE), as
10 * available from http://www.virtualbox.org. This file is free software;
11 * you can redistribute it and/or modify it under the terms of the GNU
12 * General Public License (GPL) as published by the Free Software
13 * Foundation, in version 2 as it comes in the "COPYING" file of the
14 * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
15 * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
16 *
17 * The contents of this file may alternatively be used under the terms
18 * of the Common Development and Distribution License Version 1.0
19 * (CDDL) only, as it comes in the "COPYING.CDDL" file of the
20 * VirtualBox OSE distribution, in which case the provisions of the
21 * CDDL are applicable instead of those of the GPL.
22 *
23 * You may elect to license modified versions of this file under the
24 * terms and conditions of either the GPL or the CDDL or both.
25 */
26
27#ifndef IPRT_INCLUDED_formats_efi_common_h
28#define IPRT_INCLUDED_formats_efi_common_h
29#ifndef RT_WITHOUT_PRAGMA_ONCE
30# pragma once
31#endif
32
33#include <iprt/types.h>
34#include <iprt/assertcompile.h>
35
36/**
37 * EFI GUID.
38 */
39typedef struct EFI_GUID
40{
41 uint32_t u32Data1;
42 uint16_t u16Data2;
43 uint16_t u16Data3;
44 uint8_t abData4[8];
45} EFI_GUID;
46AssertCompileSize(EFI_GUID, 16);
47/** Pointer to an EFI GUID. */
48typedef EFI_GUID *PEFI_GUID;
49/** Pointer to a const EFI GUID. */
50typedef const EFI_GUID *PCEFI_GUID;
51
52
53/** A Null GUID. */
54#define EFI_NULL_GUID { 0, 0, 0, { 0, 0, 0, 0, 0, 0, 0, 0 }}
55/** Global variable GUID. */
56#define EFI_GLOBAL_VARIABLE_GUID \
57 { 0x8be4df61, 0x93ca, 0x11d2, { 0xaa, 0x0d, 0x00, 0xe0, 0x98, 0x03, 0x2b, 0x8c }}
58/** SecureBootEnable variable GUID. */
59#define EFI_SECURE_BOOT_ENABLE_DISABLE_GUID \
60 { 0xf0a30bc7, 0xaf08, 0x4556, { 0x99, 0xc4, 0x0, 0x10, 0x9, 0xc9, 0x3a, 0x44 } }
61
62
63/**
64 * EFI time value.
65 */
66typedef struct EFI_TIME
67{
68 uint16_t u16Year;
69 uint8_t u8Month;
70 uint8_t u8Day;
71 uint8_t u8Hour;
72 uint8_t u8Minute;
73 uint8_t u8Second;
74 uint8_t bPad0;
75 uint32_t u32Nanosecond;
76 int16_t iTimezone;
77 uint8_t u8Daylight;
78 uint8_t bPad1;
79} EFI_TIME;
80AssertCompileSize(EFI_TIME, 16);
81/** Pointer to an EFI time abstraction. */
82typedef EFI_TIME *PEFI_TIME;
83/** Pointer to a const EFI time abstraction. */
84typedef const EFI_TIME *PCEFI_TIME;
85
86#define EFI_TIME_TIMEZONE_UNSPECIFIED INT16_C(0x07ff)
87
88#define EFI_TIME_DAYLIGHT_ADJUST RT_BIT(0)
89#define EFI_TIME_DAYLIGHT_INDST RT_BIT(1)
90
91#endif /* !IPRT_INCLUDED_formats_efi_common_h */
92
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette