From e7aaf04cf5a3d3d679de5f7949a374deed5ec37b Mon Sep 17 00:00:00 2001 From: Arthur Heymans Date: Wed, 7 Jun 2023 12:12:45 +0200 Subject: acpi: Add struct for SPCR table MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Arthur Heymans Change-Id: I46d5caa0af95ec27fd49b0cf8fa704d656c89e7e Reviewed-on: https://review.coreboot.org/c/coreboot/+/75684 Reviewed-by: Lean Sheng Tan Reviewed-by: Kyösti Mälkki Tested-by: build bot (Jenkins) --- src/include/acpi/acpi.h | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/src/include/acpi/acpi.h b/src/include/acpi/acpi.h index 78a6005a7dbf..548b4c3e63dd 100644 --- a/src/include/acpi/acpi.h +++ b/src/include/acpi/acpi.h @@ -1298,6 +1298,36 @@ typedef struct acpi_einj { acpi_einj_action_table_t action_table[ACTION_COUNT]; } __packed acpi_einj_t; +/* SPCR (Serial Port Console Redirection Table) */ +typedef struct acpi_spcr { + acpi_header_t header; + uint8_t interface_type; + uint8_t reserved[3]; + acpi_addr_t base_address; + uint8_t interrupt_type; + uint8_t irq; + uint32_t global_system_interrupt; + uint8_t configured_baudrate; + uint8_t parity; + uint8_t stop_bits; + uint8_t flow_control; + uint8_t terminal_type; + uint8_t language; + uint16_t pci_did; + uint16_t pci_vid; + uint8_t pci_bus; + uint8_t pci_dev; + uint8_t pci_fun; + uint32_t pci_flags; + uint8_t pci_segment; + uint32_t uart_clock; + uint32_t precise_baud_rate; + uint16_t namespace_string_length; + uint16_t namespace_string_offset; + char namespacestring[]; +} __packed acpi_spcr_t; +_Static_assert(sizeof(acpi_spcr_t) == 88, "acpi_spcr_t must have an 88 byte size\n"); + uintptr_t get_coreboot_rsdp(void); void acpi_create_einj(acpi_einj_t *einj, uintptr_t addr, u8 actions); -- cgit v1.2.3