summaryrefslogtreecommitdiff
path: root/arch
diff options
context:
space:
mode:
authorTom Rini <trini@konsulko.com>2020-04-04 19:20:26 -0400
committerTom Rini <trini@konsulko.com>2020-04-04 19:20:26 -0400
commita7b86eb5248bf33dca35cb9ba2fb211aa67ef370 (patch)
tree3efee5e463fe9e6b30fa549a4f597391fff94b65 /arch
parent60f1cc529ccc364e8374945a06ff2f7a2c54fb1e (diff)
parent9e6ce62190b7cd874d2bf727c7681292551ba6b9 (diff)
Merge https://gitlab.denx.de/u-boot/custodians/u-boot-x86
- verdin-imx8mm board reST documentation update - Intel Edison board ACPI table I2C/USB minor updates - Fix a regression of ns16550 serial driver that breaks Intel Edison
Diffstat (limited to 'arch')
-rw-r--r--arch/x86/include/asm/arch-tangier/acpi/southcluster.asl77
-rw-r--r--arch/x86/lib/acpi_table.c37
2 files changed, 96 insertions, 18 deletions
diff --git a/arch/x86/include/asm/arch-tangier/acpi/southcluster.asl b/arch/x86/include/asm/arch-tangier/acpi/southcluster.asl
index c622783f44..f088fe3cf5 100644
--- a/arch/x86/include/asm/arch-tangier/acpi/southcluster.asl
+++ b/arch/x86/include/asm/arch-tangier/acpi/southcluster.asl
@@ -240,6 +240,21 @@ Device (PCI0)
Return (STA_VISIBLE)
}
+ Name (SSCN, Package ()
+ {
+ 0x02F8, 0x037B, Zero,
+ })
+
+ Name (FMCN, Package ()
+ {
+ 0x0087, 0x010A, Zero,
+ })
+
+ Name (HSCN, Package ()
+ {
+ 0x0008, 0x0020, Zero,
+ })
+
Name (RBUF, ResourceTemplate()
{
FixedDMA(0x0009, 0x0000, Width32bit, )
@@ -260,6 +275,21 @@ Device (PCI0)
{
Return (STA_VISIBLE)
}
+
+ Name (SSCN, Package ()
+ {
+ 0x02F8, 0x037B, Zero,
+ })
+
+ Name (FMCN, Package ()
+ {
+ 0x0087, 0x010A, Zero,
+ })
+
+ Name (HSCN, Package ()
+ {
+ 0x0008, 0x0020, Zero,
+ })
}
Device (GPIO)
@@ -291,6 +321,53 @@ Device (PCI0)
}
}
+ Device (DWC3)
+ {
+ Name (_ADR, 0x00110000)
+ Name (_DEP, Package ()
+ {
+ ^IPC1.PMIC
+ })
+
+ Method (_STA, 0, NotSerialized)
+ {
+ Return (STA_VISIBLE)
+ }
+
+ Device (RHUB)
+ {
+ Name (_ADR, Zero)
+
+ /* GPLD: Generate Port Location Data (PLD) */
+ Method (GPLD, 1, Serialized) {
+ Name (PCKG, Package () {
+ Buffer (0x14) {}
+ })
+
+ /* REV: Revision 0x02 for ACPI 5.0 */
+ CreateField (DerefOf (Index (PCKG, Zero)), Zero, 0x07, REV)
+ Store (0x0002, REV)
+
+ /* VISI: Port visibility to user per port */
+ CreateField (DerefOf (Index (PCKG, Zero)), 0x40, One, VISI)
+ Store (Arg0, VISI)
+
+ /* VOFF: Vertical offset is not supplied */
+ CreateField (DerefOf (Index (PCKG, Zero)), 0x80, 0x10, VOFF)
+ Store (0xFFFF, VOFF)
+
+ /* HOFF: Horizontal offset is not supplied */
+ CreateField (DerefOf (Index (PCKG, Zero)), 0x90, 0x10, HOFF)
+ Store (0xFFFF, HOFF)
+
+ Return (PCKG)
+ }
+
+ Device (HS01) { Name (_ADR, 1) }
+ Device (SS01) { Name (_ADR, 2) }
+ }
+ }
+
Device (PWM0)
{
Name (_ADR, 0x00170000)
diff --git a/arch/x86/lib/acpi_table.c b/arch/x86/lib/acpi_table.c
index 0d69cf271f..66e32f21bd 100644
--- a/arch/x86/lib/acpi_table.c
+++ b/arch/x86/lib/acpi_table.c
@@ -109,14 +109,11 @@ static void acpi_add_table(struct acpi_rsdp *rsdp, void *table)
{
int i, entries_num;
struct acpi_rsdt *rsdt;
- struct acpi_xsdt *xsdt = NULL;
+ struct acpi_xsdt *xsdt;
/* The RSDT is mandatory while the XSDT is not */
rsdt = (struct acpi_rsdt *)rsdp->rsdt_address;
- if (rsdp->xsdt_address)
- xsdt = (struct acpi_xsdt *)((u32)rsdp->xsdt_address);
-
/* This should always be MAX_ACPI_TABLES */
entries_num = ARRAY_SIZE(rsdt->entry);
@@ -135,30 +132,34 @@ static void acpi_add_table(struct acpi_rsdp *rsdp, void *table)
/* Fix RSDT length or the kernel will assume invalid entries */
rsdt->header.length = sizeof(struct acpi_table_header) +
- (sizeof(u32) * (i + 1));
+ sizeof(u32) * (i + 1);
/* Re-calculate checksum */
rsdt->header.checksum = 0;
rsdt->header.checksum = table_compute_checksum((u8 *)rsdt,
rsdt->header.length);
+ /* The RSDT is mandatory while the XSDT is not */
+ if (!rsdp->xsdt_address)
+ return;
+
/*
* And now the same thing for the XSDT. We use the same index as for
* now we want the XSDT and RSDT to always be in sync in U-Boot
*/
- if (xsdt) {
- /* Add table to the XSDT */
- xsdt->entry[i] = (u64)(u32)table;
-
- /* Fix XSDT length */
- xsdt->header.length = sizeof(struct acpi_table_header) +
- (sizeof(u64) * (i + 1));
-
- /* Re-calculate checksum */
- xsdt->header.checksum = 0;
- xsdt->header.checksum = table_compute_checksum((u8 *)xsdt,
- xsdt->header.length);
- }
+ xsdt = (struct acpi_xsdt *)((u32)rsdp->xsdt_address);
+
+ /* Add table to the XSDT */
+ xsdt->entry[i] = (u64)(u32)table;
+
+ /* Fix XSDT length */
+ xsdt->header.length = sizeof(struct acpi_table_header) +
+ sizeof(u64) * (i + 1);
+
+ /* Re-calculate checksum */
+ xsdt->header.checksum = 0;
+ xsdt->header.checksum = table_compute_checksum((u8 *)xsdt,
+ xsdt->header.length);
}
static void acpi_create_facs(struct acpi_facs *facs)