From 24bada7991d9f1d412f9bfca36716e8457cb4f90 Mon Sep 17 00:00:00 2001 From: Dan Williams Date: Fri, 8 Dec 2017 08:29:25 -0800 Subject: ACPI: add NFIT and HMAT to the initrd override list These tables, NFIT and HMAT, are essential for describing next-generation platform memory topologies and performance characteristics. Allow them to be overridden for debug and test and purposes. Signed-off-by: Dan Williams Reviewed-by: Ross Zwisler Signed-off-by: Rafael J. Wysocki --- drivers/acpi/tables.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'drivers/acpi') diff --git a/drivers/acpi/tables.c b/drivers/acpi/tables.c index 7bcb66ccccf3..849c4fb19b03 100644 --- a/drivers/acpi/tables.c +++ b/drivers/acpi/tables.c @@ -457,7 +457,7 @@ static const char * const table_sigs[] = { ACPI_SIG_UEFI, ACPI_SIG_WAET, ACPI_SIG_WDAT, ACPI_SIG_WDDT, ACPI_SIG_WDRT, ACPI_SIG_DSDT, ACPI_SIG_FADT, ACPI_SIG_PSDT, ACPI_SIG_RSDT, ACPI_SIG_XSDT, ACPI_SIG_SSDT, ACPI_SIG_IORT, - NULL }; + ACPI_SIG_NFIT, ACPI_SIG_HMAT, NULL }; #define ACPI_HEADER_SIZE sizeof(struct acpi_table_header) -- cgit From d29abc836843b8c9537b4d778eb2d429a804a5ed Mon Sep 17 00:00:00 2001 From: George Cherian Date: Tue, 20 Feb 2018 11:16:03 +0000 Subject: ACPI / CPPC: Update all pr_(debug/err) messages to log the susbspace id CPPC dirver is aware of multiple PCC subspace IDs. Enhance the debug and error messages in the driver to print the subspace id. In case of error it will be helpful to find which particular subspace is failing. Signed-off-by: George Cherian Signed-off-by: Rafael J. Wysocki --- drivers/acpi/cppc_acpi.c | 27 ++++++++++++++++----------- 1 file changed, 16 insertions(+), 11 deletions(-) (limited to 'drivers/acpi') diff --git a/drivers/acpi/cppc_acpi.c b/drivers/acpi/cppc_acpi.c index 0afbb2658cbc..735c74a4cbdb 100644 --- a/drivers/acpi/cppc_acpi.c +++ b/drivers/acpi/cppc_acpi.c @@ -227,7 +227,8 @@ static int check_pcc_chan(int pcc_ss_id, bool chk_err_bit) if (likely(!ret)) pcc_ss_data->platform_owns_pcc = false; else - pr_err("PCC check channel failed. Status=%x\n", status); + pr_err("PCC check channel failed for ss: %d. Status=%x\n", + pcc_ss_id, status); return ret; } @@ -291,7 +292,8 @@ static int send_pcc_cmd(int pcc_ss_id, u16 cmd) time_delta = ktime_ms_delta(ktime_get(), pcc_ss_data->last_mpar_reset); if ((time_delta < 60 * MSEC_PER_SEC) && pcc_ss_data->last_mpar_reset) { - pr_debug("PCC cmd not sent due to MPAR limit"); + pr_debug("PCC cmd for subspace %d not sent due to MPAR limit", + pcc_ss_id); ret = -EIO; goto end; } @@ -312,8 +314,8 @@ static int send_pcc_cmd(int pcc_ss_id, u16 cmd) /* Ring doorbell */ ret = mbox_send_message(pcc_ss_data->pcc_channel, &cmd); if (ret < 0) { - pr_err("Err sending PCC mbox message. cmd:%d, ret:%d\n", - cmd, ret); + pr_err("Err sending PCC mbox message. ss: %d cmd:%d, ret:%d\n", + pcc_ss_id, cmd, ret); goto end; } @@ -553,7 +555,8 @@ static int register_pcc_channel(int pcc_ss_idx) pcc_mbox_request_channel(&cppc_mbox_cl, pcc_ss_idx); if (IS_ERR(pcc_data[pcc_ss_idx]->pcc_channel)) { - pr_err("Failed to find PCC communication channel\n"); + pr_err("Failed to find PCC channel for subspace %d\n", + pcc_ss_idx); return -ENODEV; } @@ -566,7 +569,8 @@ static int register_pcc_channel(int pcc_ss_idx) cppc_ss = (pcc_data[pcc_ss_idx]->pcc_channel)->con_priv; if (!cppc_ss) { - pr_err("No PCC subspace found for CPPC\n"); + pr_err("No PCC subspace found for %d CPPC\n", + pcc_ss_idx); return -ENODEV; } @@ -584,7 +588,8 @@ static int register_pcc_channel(int pcc_ss_idx) pcc_data[pcc_ss_idx]->pcc_comm_addr = acpi_os_ioremap(cppc_ss->base_address, cppc_ss->length); if (!pcc_data[pcc_ss_idx]->pcc_comm_addr) { - pr_err("Failed to ioremap PCC comm region mem\n"); + pr_err("Failed to ioremap PCC comm region mem for %d\n", + pcc_ss_idx); return -ENOMEM; } @@ -973,8 +978,8 @@ static int cpc_read(int cpu, struct cpc_register_resource *reg_res, u64 *val) *val = readq_relaxed(vaddr); break; default: - pr_debug("Error: Cannot read %u bit width from PCC\n", - reg->bit_width); + pr_debug("Error: Cannot read %u bit width from PCC for ss: %d\n", + reg->bit_width, pcc_ss_id); ret_val = -EFAULT; } @@ -1012,8 +1017,8 @@ static int cpc_write(int cpu, struct cpc_register_resource *reg_res, u64 val) writeq_relaxed(val, vaddr); break; default: - pr_debug("Error: Cannot write %u bit width to PCC\n", - reg->bit_width); + pr_debug("Error: Cannot write %u bit width to PCC for ss: %d\n", + reg->bit_width, pcc_ss_id); ret_val = -EFAULT; break; } -- cgit From 92d1b381f677cbd2d4370dc3b8d0679b7f0ace32 Mon Sep 17 00:00:00 2001 From: Alex Hung Date: Thu, 22 Feb 2018 21:43:44 -0800 Subject: ACPI / PCI: pci_link: Allow the absence of _PRS and change log level In recent Intel hardware the IRQs become non-configurable after BIOS initializes them in PEI phase and _PRS objects are no longer included in ASL. This is the same as "static (non-configurable) devices do not specify a _PRS object" in ACPI spec. As a result, error messages saying "ACPI Exception: AE_NOT_FOUND, Evaluating _PRS" does not need to be in kernel messenges all the time but only when debug is enabled, and acpi_pci_link_get_possible should not return -ENODEV when _PRS is absent. Signed-off-by: Alex Hung Acked-by: Bjorn Helgaas Signed-off-by: Rafael J. Wysocki --- drivers/acpi/pci_link.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'drivers/acpi') diff --git a/drivers/acpi/pci_link.c b/drivers/acpi/pci_link.c index 85ad679390e3..d5eec352a6e1 100644 --- a/drivers/acpi/pci_link.c +++ b/drivers/acpi/pci_link.c @@ -173,8 +173,8 @@ static int acpi_pci_link_get_possible(struct acpi_pci_link *link) status = acpi_walk_resources(link->device->handle, METHOD_NAME__PRS, acpi_pci_link_check_possible, link); if (ACPI_FAILURE(status)) { - ACPI_EXCEPTION((AE_INFO, status, "Evaluating _PRS")); - return -ENODEV; + acpi_handle_debug(link->device->handle, "_PRS not present or invalid"); + return 0; } ACPI_DEBUG_PRINT((ACPI_DB_INFO, -- cgit