aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--include/acpi/actbl2.h126
1 files changed, 126 insertions, 0 deletions
diff --git a/include/acpi/actbl2.h b/include/acpi/actbl2.h
index 93f85e8f7e9a..370d69d871a0 100644
--- a/include/acpi/actbl2.h
+++ b/include/acpi/actbl2.h
@@ -69,6 +69,7 @@
69#define ACPI_SIG_DMAR "DMAR" /* DMA Remapping table */ 69#define ACPI_SIG_DMAR "DMAR" /* DMA Remapping table */
70#define ACPI_SIG_HPET "HPET" /* High Precision Event Timer table */ 70#define ACPI_SIG_HPET "HPET" /* High Precision Event Timer table */
71#define ACPI_SIG_IBFT "IBFT" /* iSCSI Boot Firmware Table */ 71#define ACPI_SIG_IBFT "IBFT" /* iSCSI Boot Firmware Table */
72#define ACPI_SIG_IORT "IORT" /* IO Remapping Table */
72#define ACPI_SIG_IVRS "IVRS" /* I/O Virtualization Reporting Structure */ 73#define ACPI_SIG_IVRS "IVRS" /* I/O Virtualization Reporting Structure */
73#define ACPI_SIG_LPIT "LPIT" /* Low Power Idle Table */ 74#define ACPI_SIG_LPIT "LPIT" /* Low Power Idle Table */
74#define ACPI_SIG_MCFG "MCFG" /* PCI Memory Mapped Configuration table */ 75#define ACPI_SIG_MCFG "MCFG" /* PCI Memory Mapped Configuration table */
@@ -650,6 +651,131 @@ struct acpi_ibft_target {
650 651
651/******************************************************************************* 652/*******************************************************************************
652 * 653 *
654 * IORT - IO Remapping Table
655 *
656 * Conforms to "IO Remapping Table System Software on ARM Platforms",
657 * Document number: ARM DEN 0049A, 2015
658 *
659 ******************************************************************************/
660
661struct acpi_table_iort {
662 struct acpi_table_header header;
663 u32 node_count;
664 u32 node_offset;
665 u32 reserved;
666};
667
668/*
669 * IORT subtables
670 */
671struct acpi_iort_node {
672 u8 type;
673 u16 length;
674 u8 revision;
675 u32 reserved;
676 u32 mapping_count;
677 u32 mapping_offset;
678 char node_data[1];
679};
680
681/* Values for subtable Type above */
682
683enum acpi_iort_node_type {
684 ACPI_IORT_NODE_ITS_GROUP = 0x00,
685 ACPI_IORT_NODE_NAMED_COMPONENT = 0x01,
686 ACPI_IORT_NODE_PCI_ROOT_COMPLEX = 0x02,
687 ACPI_IORT_NODE_SMMU = 0x03
688};
689
690struct acpi_iort_id_mapping {
691 u32 input_base; /* Lowest value in input range */
692 u32 id_count; /* Number of IDs */
693 u32 output_base; /* Lowest value in output range */
694 u32 output_reference; /* A reference to the output node */
695 u32 flags;
696};
697
698/* Masks for Flags field above for IORT subtable */
699
700#define ACPI_IORT_ID_SINGLE_MAPPING (1)
701
702struct acpi_iort_memory_access {
703 u32 cache_coherency;
704 u8 hints;
705 u16 reserved;
706 u8 memory_flags;
707};
708
709/* Values for cache_coherency field above */
710
711#define ACPI_IORT_NODE_COHERENT 0x00000001 /* The device node is fully coherent */
712#define ACPI_IORT_NODE_NOT_COHERENT 0x00000000 /* The device node is not coherent */
713
714/* Masks for Hints field above */
715
716#define ACPI_IORT_HT_TRANSIENT (1)
717#define ACPI_IORT_HT_WRITE (1<<1)
718#define ACPI_IORT_HT_READ (1<<2)
719#define ACPI_IORT_HT_OVERRIDE (1<<3)
720
721/* Masks for memory_flags field above */
722
723#define ACPI_IORT_MF_COHERENCY (1)
724#define ACPI_IORT_MF_ATTRIBUTES (1<<1)
725
726/*
727 * IORT node specific subtables
728 */
729struct acpi_iort_its_group {
730 u32 its_count;
731 u32 identifiers[1]; /* GIC ITS identifier arrary */
732};
733
734struct acpi_iort_named_component {
735 u32 node_flags;
736 u64 memory_properties; /* Memory access properties */
737 u8 memory_address_limit; /* Memory address size limit */
738 char device_name[1]; /* Path of namespace object */
739};
740
741struct acpi_iort_root_complex {
742 u64 memory_properties; /* Memory access properties */
743 u32 ats_attribute;
744 u32 pci_segment_number;
745};
746
747/* Values for ats_attribute field above */
748
749#define ACPI_IORT_ATS_SUPPORTED 0x00000001 /* The root complex supports ATS */
750#define ACPI_IORT_ATS_UNSUPPORTED 0x00000000 /* The root complex doesn't support ATS */
751
752struct acpi_iort_smmu {
753 u64 base_address; /* SMMU base address */
754 u64 span; /* Length of memory range */
755 u32 model;
756 u32 flags;
757 u32 global_interrupt_offset;
758 u32 context_interrupt_count;
759 u32 context_interrupt_offset;
760 u32 pmu_interrupt_count;
761 u32 pmu_interrupt_offset;
762 u64 interrupts[1]; /* Interrupt array */
763};
764
765/* Values for Model field above */
766
767#define ACPI_IORT_SMMU_V1 0x00000000 /* Generic SMMUv1 */
768#define ACPI_IORT_SMMU_V2 0x00000001 /* Generic SMMUv2 */
769#define ACPI_IORT_SMMU_CORELINK_MMU400 0x00000002 /* ARM Corelink MMU-400 */
770#define ACPI_IORT_SMMU_CORELINK_MMU500 0x00000003 /* ARM Corelink MMU-500 */
771
772/* Masks for Flags field above */
773
774#define ACPI_IORT_SMMU_DVM_SUPPORTED (1)
775#define ACPI_IORT_SMMU_COHERENT_WALK (1<<1)
776
777/*******************************************************************************
778 *
653 * IVRS - I/O Virtualization Reporting Structure 779 * IVRS - I/O Virtualization Reporting Structure
654 * Version 1 780 * Version 1
655 * 781 *