]> git.proxmox.com Git - mirror_edk2.git/blame - OvmfPkg/Bhyve/AcpiTables/Spcr.aslc
UefiCpuPkg: Move AsmRelocateApLoopStart from Mpfuncs.nasm to AmdSev.nasm
[mirror_edk2.git] / OvmfPkg / Bhyve / AcpiTables / Spcr.aslc
CommitLineData
656419f9
RC
1/*\r
2 * Copyright (c) 2020, Rebecca Cran <rebecca@bsdio.com>\r
3 * Copyright (c) 2015, Nahanni Systems, Inc.\r
4 *\r
5 * SPDX-License-Identifier: BSD-2-Clause-Patent\r
6 */\r
7\r
8#include "Platform.h"\r
9\r
10#define EFI_ACPI_OEM_TABLE_ID SIGNATURE_64('B','V','S','P','C','R',' ',' ')\r
11\r
12EFI_ACPI_SERIAL_PORT_CONSOLE_REDIRECTION_TABLE SPCR = {\r
13 {\r
14 EFI_ACPI_2_0_SERIAL_PORT_CONSOLE_REDIRECTION_TABLE_SIGNATURE,\r
15 sizeof (EFI_ACPI_SERIAL_PORT_CONSOLE_REDIRECTION_TABLE),\r
16 EFI_ACPI_SERIAL_PORT_CONSOLE_REDIRECTION_TABLE_REVISION,\r
17 0, // to make sum of entire table == 0\r
18 {EFI_ACPI_OEM_ID}, // OEMID is a 6 bytes long field\r
19 EFI_ACPI_OEM_TABLE_ID, // OEM table identification(8 bytes long)\r
20 EFI_ACPI_OEM_REVISION, // OEM revision number\r
21 EFI_ACPI_CREATOR_ID, // ASL compiler vendor ID\r
22 EFI_ACPI_CREATOR_REVISION // ASL compiler revision number\r
23 },\r
24 EFI_ACPI_SERIAL_PORT_CONSOLE_REDIRECTION_TABLE_INTERFACE_TYPE_16550,\r
25 { 0 }, // Reserved\r
26 { // BaseAddress\r
27 0x01, // AddressSpaceId\r
28 0x08, // RegisterBitWidth\r
29 0x00, // RegisterBitOffset\r
30 0x00, // Reserved\r
31 0x03F8 // Address (COM1)\r
32 },\r
33 EFI_ACPI_SERIAL_PORT_CONSOLE_REDIRECTION_TABLE_INTERRUPT_TYPE_8259,\r
34 4, // Irq\r
35 0, // GlobalSystemInterrupt\r
36 EFI_ACPI_SERIAL_PORT_CONSOLE_REDIRECTION_TABLE_BAUD_RATE_115200,\r
37 EFI_ACPI_SERIAL_PORT_CONSOLE_REDIRECTION_TABLE_PARITY_NO_PARITY,\r
38 EFI_ACPI_SERIAL_PORT_CONSOLE_REDIRECTION_TABLE_STOP_BITS_1,\r
39 0x03, // FlowControl: RTS/CTS | DCD\r
40 EFI_ACPI_SERIAL_PORT_CONSOLE_REDIRECTION_TABLE_TERMINAL_TYPE_VT_UTF8,\r
41 0, // Language\r
42 0, // PciDeviceId\r
43 0, // PciVendorId\r
44 0, // PciBusNumber\r
45 0, // PciDeviceNumber\r
46 0, // PciFunctionNumber\r
47 0, // PciFlags\r
48 0, // PciSegment\r
49 0 // Reserved\r
50};\r
51\r
52\r
53VOID *\r
54ReferenceAcpiTable (\r
55 VOID\r
56 )\r
57{\r
58 //\r
59 // Reference the table being generated to prevent the optimizer from removing the\r
60 // data structure from the exeutable\r
61 //\r
62 return (VOID*)&SPCR;\r
63}\r