Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 3c9c75de authored by Rafael J. Wysocki's avatar Rafael J. Wysocki
Browse files

Merge branches 'acpi-tables', 'acpi-bus' and 'acpi-processor'

* acpi-tables:
  ACPI: SPCR: Make SPCR available to x86
  ACPI / tables: Add IORT to injectable table list

* acpi-bus:
  ACPI / bus: Parse tables as term_list for Dell XPS 9570 and Precision M5530
  ACPI / scan: Use acpi_bus_get_status() to initialize ACPI_TYPE_DEVICE devs
  ACPI / bus: Do not call _STA on battery devices with unmet dependencies
  PCI: acpiphp_ibm: prepare for acpi_get_object_info() no longer returning status
  ACPI: export acpi_bus_get_status_handle()

* acpi-processor:
  ACPI / processor: Set default C1 idle state description
  ACPI: processor_perflib: Do not send _PPC change notification if not ready
Loading
Loading
Loading
Loading
+6 −3
Original line number Diff line number Diff line
@@ -917,9 +917,12 @@

	earlycon=	[KNL] Output early console device and options.

			When used with no options, the early console is
			determined by the stdout-path property in device
			tree's chosen node.
			[ARM64] The early console is determined by the
			stdout-path property in device tree's chosen node,
			or determined by the ACPI SPCR table.

			[X86] When used with no options the early console is
			determined by the ACPI SPCR table.

		cdns,<addr>[,options]
			Start an early, polled-mode console on a Cadence
+2 −2
Original line number Diff line number Diff line
@@ -230,10 +230,10 @@ void __init acpi_boot_table_init(void)

done:
	if (acpi_disabled) {
		if (earlycon_init_is_deferred)
		if (earlycon_acpi_spcr_enable)
			early_init_dt_scan_chosen_stdout();
	} else {
		parse_spcr(earlycon_init_is_deferred);
		acpi_parse_spcr(earlycon_acpi_spcr_enable, true);
		if (IS_ENABLED(CONFIG_ACPI_BGRT))
			acpi_table_parse(ACPI_SIG_BGRT, acpi_parse_bgrt);
	}
+3 −0
Original line number Diff line number Diff line
@@ -36,6 +36,7 @@
#include <linux/ioport.h>
#include <linux/pci.h>
#include <linux/efi-bgrt.h>
#include <linux/serial_core.h>

#include <asm/e820/api.h>
#include <asm/irqdomain.h>
@@ -1625,6 +1626,8 @@ int __init acpi_boot_init(void)
	if (!acpi_noirq)
		x86_init.pci.init = pci_acpi_init;

	/* Do not enable ACPI SPCR console by default */
	acpi_parse_spcr(earlycon_acpi_spcr_enable, false);
	return 0;
}

+6 −1
Original line number Diff line number Diff line
@@ -79,7 +79,12 @@ config ACPI_DEBUGGER_USER
endif

config ACPI_SPCR_TABLE
	bool
	bool "ACPI Serial Port Console Redirection Support"
	default y if X86
	help
	  Enable support for Serial Port Console Redirection (SPCR) Table.
	  This table provides information about the configuration of the
	  earlycon console.

config ACPI_LPIT
	bool
+38 −7
Original line number Diff line number Diff line
@@ -66,10 +66,37 @@ static int set_copy_dsdt(const struct dmi_system_id *id)
	return 0;
}
#endif
static int set_gbl_term_list(const struct dmi_system_id *id)
{
	acpi_gbl_parse_table_as_term_list = 1;
	return 0;
}

static const struct dmi_system_id dsdt_dmi_table[] __initconst = {
static const struct dmi_system_id acpi_quirks_dmi_table[] __initconst = {
	/*
	 * Touchpad on Dell XPS 9570/Precision M5530 doesn't work under I2C
	 * mode.
	 * https://bugzilla.kernel.org/show_bug.cgi?id=198515
	 */
	{
		.callback = set_gbl_term_list,
		.ident = "Dell Precision M5530",
		.matches = {
			DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc."),
			DMI_MATCH(DMI_PRODUCT_NAME, "Precision M5530"),
		},
	},
	{
		.callback = set_gbl_term_list,
		.ident = "Dell XPS 15 9570",
		.matches = {
			DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc."),
			DMI_MATCH(DMI_PRODUCT_NAME, "XPS 15 9570"),
		},
	},
	/*
	 * Invoke DSDT corruption work-around on all Toshiba Satellite.
	 * DSDT will be copied to memory.
	 * https://bugzilla.kernel.org/show_bug.cgi?id=14679
	 */
	{
@@ -83,7 +110,7 @@ static const struct dmi_system_id dsdt_dmi_table[] __initconst = {
	{}
};
#else
static const struct dmi_system_id dsdt_dmi_table[] __initconst = {
static const struct dmi_system_id acpi_quirks_dmi_table[] __initconst = {
	{}
};
#endif
@@ -108,6 +135,7 @@ acpi_status acpi_bus_get_status_handle(acpi_handle handle,
	}
	return status;
}
EXPORT_SYMBOL_GPL(acpi_bus_get_status_handle);

int acpi_bus_get_status(struct acpi_device *device)
{
@@ -119,6 +147,12 @@ int acpi_bus_get_status(struct acpi_device *device)
		return 0;
	}

	/* Battery devices must have their deps met before calling _STA */
	if (acpi_device_is_battery(device) && device->dep_unmet) {
		acpi_set_device_status(device, 0);
		return 0;
	}

	status = acpi_bus_get_status_handle(device->handle, &sta);
	if (ACPI_FAILURE(status))
		return -ENODEV;
@@ -1001,11 +1035,8 @@ void __init acpi_early_init(void)

	acpi_permanent_mmap = true;

	/*
	 * If the machine falls into the DMI check table,
	 * DSDT will be copied to memory
	 */
	dmi_check_system(dsdt_dmi_table);
	/* Check machine-specific quirks */
	dmi_check_system(acpi_quirks_dmi_table);

	status = acpi_reallocate_root_table();
	if (ACPI_FAILURE(status)) {
Loading