VirtualBox

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

Last change on this file since 90283 was 90283, checked in by vboxsync, 4 years ago

Runtime/efi: Started implementing the functionality to parse, create and modify EFI signature databases, bugref:9580

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 2.4 KB
Line 
1/* $Id: efi-common.h 90283 2021-07-22 11:37:25Z vboxsync $ */
2/** @file
3 * IPRT, EFI common definitions.
4 */
5
6/*
7 * Copyright (C) 2021 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
56
57/**
58 * EFI time value.
59 */
60typedef struct EFI_TIME
61{
62 uint16_t u16Year;
63 uint8_t u8Month;
64 uint8_t u8Day;
65 uint8_t u8Hour;
66 uint8_t u8Minute;
67 uint8_t u8Second;
68 uint8_t bPad0;
69 uint32_t u32Nanosecond;
70 int16_t iTimezone;
71 uint8_t u8Daylight;
72 uint8_t bPad1;
73} EFI_TIME;
74AssertCompileSize(EFI_TIME, 16);
75/** Pointer to an EFI time abstraction. */
76typedef EFI_TIME *PEFI_TIME;
77/** Pointer to a const EFI time abstraction. */
78typedef const EFI_TIME *PCEFI_TIME;
79
80#define EFI_TIME_TIMEZONE_UNSPECIFIED INT16_C(0x07ff)
81
82#define EFI_TIME_DAYLIGHT_ADJUST RT_BIT(0)
83#define EFI_TIME_DAYLIGHT_INDST RT_BIT(1)
84
85#endif /* !IPRT_INCLUDED_formats_efi_common_h */
86
Note: See TracBrowser for help on using the repository browser.

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