soc/intel/common/block/pcie/rtd3: Fix PMC IPC method for CPU PCIe RP
When calling get_pcie_rp_pmc_idx(), the following code checked the
return value to see if it was negative or `> CONFIG_MAX_ROOT_PORTS`.
However, the expected return value for CPU PCIe RPs is above
MAX_ROOT_PORTS. Since the static, local function is intended to return
-1 or a valid value, drop the check for `> CONFIG_MAX_ROOT_PORTS`.
Change-Id: I2039273ad246884cd8736a7f0355e621a706a526
Fixes: b6a15a7
("soc/intel/common/block/pcie/rtd3: Update ACPI Update
ACPI methods for CPU PCIe RPs")
Tested-by: Tim Crawford <tcrawford@system76.com>
Signed-off-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61280
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Subrata Banik <subratabanik@google.com>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-by: Paul Menzel <paulepanter@mailbox.org>
Reviewed-by: Tim Crawford <tcrawford@system76.com>
This commit is contained in:
parent
6dfa528af9
commit
b3cd55b224
|
@ -289,7 +289,7 @@ static void pcie_rtd3_acpi_fill_ssdt(const struct device *dev)
|
|||
|
||||
const enum pcie_rp_type rp_type = soc_get_pcie_rp_type(parent);
|
||||
pcie_rp = get_pcie_rp_pmc_idx(rp_type, parent);
|
||||
if (pcie_rp < 0 || pcie_rp > CONFIG_MAX_ROOT_PORTS) {
|
||||
if (pcie_rp < 0) {
|
||||
printk(BIOS_ERR, "%s: Unknown PCIe root port\n", __func__);
|
||||
return;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue