diff options
author | Anish Gupta <anish@FreeBSD.org> | 2018-02-16 05:17:00 +0000 |
---|---|---|
committer | Anish Gupta <anish@FreeBSD.org> | 2018-02-16 05:17:00 +0000 |
commit | 0b37d3d90ed3f4575ee4312f78f3646b0d3e58c5 (patch) | |
tree | b0f370c5f97fbec5d1ebc3668bd5b2f14be84473 /sys/contrib/dev/acpica | |
parent | 39006570a401ef5fb6d7d8029089fb11280bfd24 (diff) | |
download | src-0b37d3d90ed3f4575ee4312f78f3646b0d3e58c5.tar.gz src-0b37d3d90ed3f4575ee4312f78f3646b0d3e58c5.zip |
This change fixes duplicate detection of same IOMMU/AMD-Vi device for Ryzen with EFR support.
IVRS can have entry of type legacy and non-legacy present at same time for same AMD-Vi device. ivhd driver will ignore legacy if new IVHD type is present as specified in AMD-Vi specification. Earlier both of IVHD entries used and two ivhd devices were created.
Add support for new IVHD type 0x11 and 0x40 in ACPI. Create new struct of type acpi_ivrs_hardware_new for these new type of IVHDs. Legacy type 0x10 will continue to use acpi_ivrs_hardware.
Reviewed by: avg
Approved by: grehan
Differential Revision:https://reviews.freebsd.org/D13160
Notes
Notes:
svn path=/head/; revision=329360
Diffstat (limited to 'sys/contrib/dev/acpica')
-rw-r--r-- | sys/contrib/dev/acpica/include/actbl2.h | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/sys/contrib/dev/acpica/include/actbl2.h b/sys/contrib/dev/acpica/include/actbl2.h index 4b3d460d88e3..9c8c00a8eb4a 100644 --- a/sys/contrib/dev/acpica/include/actbl2.h +++ b/sys/contrib/dev/acpica/include/actbl2.h @@ -444,6 +444,8 @@ typedef struct acpi_ivrs_header enum AcpiIvrsType { ACPI_IVRS_TYPE_HARDWARE = 0x10, + ACPI_IVRS_TYPE_HARDWARE_EXT1 = 0x11, + ACPI_IVRS_TYPE_HARDWARE_EXT2 = 0x40, ACPI_IVRS_TYPE_MEMORY1 = 0x20, ACPI_IVRS_TYPE_MEMORY2 = 0x21, ACPI_IVRS_TYPE_MEMORY3 = 0x22 @@ -482,6 +484,21 @@ typedef struct acpi_ivrs_hardware } ACPI_IVRS_HARDWARE; +/* 0x11 and 0x40: I/O Virtualization Hardware Definition Block (IVHD) */ + +typedef struct acpi_ivrs_hardware_new +{ + ACPI_IVRS_HEADER Header; + UINT16 CapabilityOffset; /* Offset for IOMMU control fields */ + UINT64 BaseAddress; /* IOMMU control registers */ + UINT16 PciSegmentGroup; + UINT16 Info; /* MSI number and unit ID */ + UINT32 Attr; /* IOMMU Feature */ + UINT64 ExtFR; /* IOMMU Extended Feature */ + UINT64 Reserved; /* v1 feature or v2 attribute */ + +} ACPI_IVRS_HARDWARE_NEW; + /* Masks for Info field above */ #define ACPI_IVHD_MSI_NUMBER_MASK 0x001F /* 5 bits, MSI message number */ |