Felix Held has submitted this change. ( https://review.coreboot.org/c/coreboot/+/69032 )
Change subject: soc/intel: Include <cpu/cpu.h> instead of <arch/cpu.h> ......................................................................
soc/intel: Include <cpu/cpu.h> instead of <arch/cpu.h>
Also sort includes.
Change-Id: I7da9c672ee230dfaebd943247639b78d675957e4 Signed-off-by: Elyes Haouas ehaouas@noos.fr Reviewed-on: https://review.coreboot.org/c/coreboot/+/69032 Tested-by: build bot (Jenkins) no-reply@coreboot.org Reviewed-by: Werner Zeh werner.zeh@siemens.com --- M src/soc/intel/alderlake/bootblock/report_platform.c M src/soc/intel/alderlake/bootblock/update_descriptor.c M src/soc/intel/apollolake/report_platform.c M src/soc/intel/baytrail/ramstage.c M src/soc/intel/braswell/ramstage.c M src/soc/intel/broadwell/report_platform.c M src/soc/intel/cannonlake/bootblock/report_platform.c M src/soc/intel/common/block/acpi/acpi.c M src/soc/intel/common/block/acpi/sgx.c M src/soc/intel/common/block/cpu/cpulib.c M src/soc/intel/common/block/cse/cse_lite.c M src/soc/intel/common/block/timer/timer.c M src/soc/intel/elkhartlake/bootblock/report_platform.c M src/soc/intel/icelake/bootblock/report_platform.c M src/soc/intel/jasperlake/bootblock/report_platform.c M src/soc/intel/meteorlake/bootblock/report_platform.c M src/soc/intel/meteorlake/cpu.c M src/soc/intel/quark/include/soc/ramstage.h M src/soc/intel/quark/romstage/report_platform.c M src/soc/intel/skylake/acpi.c M src/soc/intel/skylake/bootblock/report_platform.c M src/soc/intel/tigerlake/bootblock/report_platform.c M src/soc/intel/tigerlake/lpm.c 23 files changed, 72 insertions(+), 58 deletions(-)
Approvals: build bot (Jenkins): Verified Werner Zeh: Looks good to me, approved
diff --git a/src/soc/intel/alderlake/bootblock/report_platform.c b/src/soc/intel/alderlake/bootblock/report_platform.c index edc3ca8..2be7546 100644 --- a/src/soc/intel/alderlake/bootblock/report_platform.c +++ b/src/soc/intel/alderlake/bootblock/report_platform.c @@ -6,16 +6,16 @@ * Chapter number: 2, 14 */
-#include <arch/cpu.h> -#include <device/pci_ops.h> #include <commonlib/helpers.h> #include <console/console.h> +#include <cpu/cpu.h> #include <cpu/intel/cpu_ids.h> #include <cpu/intel/microcode.h> #include <cpu/x86/msr.h> #include <cpu/x86/name.h> #include <device/pci.h> #include <device/pci_ids.h> +#include <device/pci_ops.h> #include <soc/bootblock.h> #include <soc/pci_devs.h>
diff --git a/src/soc/intel/alderlake/bootblock/update_descriptor.c b/src/soc/intel/alderlake/bootblock/update_descriptor.c index dbb152c..9c8ce9c 100644 --- a/src/soc/intel/alderlake/bootblock/update_descriptor.c +++ b/src/soc/intel/alderlake/bootblock/update_descriptor.c @@ -1,10 +1,10 @@ /* SPDX-License-Identifier: GPL-2.0-or-later */
-#include <arch/cpu.h> #include <arch/mmio.h> #include <cf9_reset.h> #include <commonlib/region.h> #include <console/console.h> +#include <cpu/cpu.h> #include <cpu/intel/cpu_ids.h> #include <fmap.h> #include <intelblocks/pmclib.h> diff --git a/src/soc/intel/apollolake/report_platform.c b/src/soc/intel/apollolake/report_platform.c index 31a6458..2e73f4a 100644 --- a/src/soc/intel/apollolake/report_platform.c +++ b/src/soc/intel/apollolake/report_platform.c @@ -1,16 +1,16 @@ /* SPDX-License-Identifier: GPL-2.0-only */
-#include <arch/cpu.h> -#include <device/pci_ops.h> #include <console/console.h> +#include <cpu/cpu.h> #include <cpu/intel/cpu_ids.h> #include <cpu/intel/microcode.h> #include <cpu/x86/msr.h> #include <cpu/x86/name.h> #include <device/pci.h> #include <device/pci_ids.h> -#include <soc/romstage.h> +#include <device/pci_ops.h> #include <soc/pci_devs.h> +#include <soc/romstage.h>
static struct { u32 cpuid; diff --git a/src/soc/intel/baytrail/ramstage.c b/src/soc/intel/baytrail/ramstage.c index 26de1cb..4e8dc68 100644 --- a/src/soc/intel/baytrail/ramstage.c +++ b/src/soc/intel/baytrail/ramstage.c @@ -1,19 +1,19 @@ /* SPDX-License-Identifier: GPL-2.0-only */
-#include <arch/cpu.h> #include <acpi/acpi_gnvs.h> #include <acpi/acpi_pm.h> #include <bootstate.h> #include <console/console.h> +#include <cpu/cpu.h> #include <cpu/intel/microcode.h> #include <cpu/x86/cr.h> #include <cpu/x86/msr.h> #include <device/device.h> #include <device/pci_def.h> #include <device/pci_ops.h> - #include <soc/device_nvs.h> #include <soc/gpio.h> +#include <soc/iosf.h> #include <soc/lpc.h> #include <soc/msr.h> #include <soc/nvs.h> @@ -21,7 +21,6 @@ #include <soc/pci_devs.h> #include <soc/pm.h> #include <soc/ramstage.h> -#include <soc/iosf.h>
#define SHOW_PATTRS 1
diff --git a/src/soc/intel/braswell/ramstage.c b/src/soc/intel/braswell/ramstage.c index 1dffd2d..6784eb9 100644 --- a/src/soc/intel/braswell/ramstage.c +++ b/src/soc/intel/braswell/ramstage.c @@ -1,16 +1,16 @@ /* SPDX-License-Identifier: GPL-2.0-only */
-#include <arch/cpu.h> #include <acpi/acpi_pm.h> #include <console/console.h> +#include <cpu/cpu.h> #include <cpu/intel/microcode.h> #include <cpu/x86/cr.h> #include <cpu/x86/msr.h> #include <device/device.h> #include <device/pci_def.h> #include <device/pci_ops.h> -#include <intelblocks/acpi_wake_source.h> #include <fsp/util.h> +#include <intelblocks/acpi_wake_source.h> #include <soc/gpio.h> #include <soc/lpc.h> #include <soc/msr.h> diff --git a/src/soc/intel/broadwell/report_platform.c b/src/soc/intel/broadwell/report_platform.c index 7e044be..5dbe196 100644 --- a/src/soc/intel/broadwell/report_platform.c +++ b/src/soc/intel/broadwell/report_platform.c @@ -1,17 +1,17 @@ /* SPDX-License-Identifier: GPL-2.0-only */
-#include <arch/cpu.h> -#include <device/pci_ops.h> #include <console/console.h> -#include <device/pci.h> -#include <string.h> +#include <cpu/cpu.h> #include <cpu/intel/haswell/haswell.h> #include <cpu/intel/microcode.h> #include <cpu/x86/msr.h> +#include <device/pci.h> +#include <device/pci_ops.h> #include <soc/pch.h> #include <soc/pci_devs.h> #include <soc/romstage.h> #include <soc/systemagent.h> +#include <string.h>
/* FIXME: Needs an update */ static struct { diff --git a/src/soc/intel/cannonlake/bootblock/report_platform.c b/src/soc/intel/cannonlake/bootblock/report_platform.c index fe36271..c062746 100644 --- a/src/soc/intel/cannonlake/bootblock/report_platform.c +++ b/src/soc/intel/cannonlake/bootblock/report_platform.c @@ -1,14 +1,14 @@ /* SPDX-License-Identifier: GPL-2.0-only */
-#include <arch/cpu.h> -#include <device/pci_ops.h> #include <console/console.h> +#include <cpu/cpu.h> #include <cpu/intel/cpu_ids.h> #include <cpu/intel/microcode.h> #include <cpu/x86/msr.h> #include <cpu/x86/name.h> #include <device/pci.h> #include <device/pci_ids.h> +#include <device/pci_ops.h> #include <soc/bootblock.h> #include <soc/pch.h> #include <soc/pci_devs.h> diff --git a/src/soc/intel/common/block/acpi/acpi.c b/src/soc/intel/common/block/acpi/acpi.c index 99cf23f..f0903ff 100644 --- a/src/soc/intel/common/block/acpi/acpi.c +++ b/src/soc/intel/common/block/acpi/acpi.c @@ -2,16 +2,17 @@
#include <acpi/acpi_pm.h> #include <acpi/acpigen.h> -#include <arch/cpu.h> #include <arch/ioapic.h> #include <arch/smp/mpspec.h> #include <console/console.h> -#include <cpu/intel/turbo.h> -#include <cpu/intel/msr.h> +#include <cpu/cpu.h> #include <cpu/intel/common/common.h> +#include <cpu/intel/msr.h> +#include <cpu/intel/turbo.h> +#include <cpu/x86/lapic.h> #include <cpu/x86/smm.h> -#include <intelblocks/acpi.h> #include <intelblocks/acpi_wake_source.h> +#include <intelblocks/acpi.h> #include <intelblocks/lpc_lib.h> #include <intelblocks/pmclib.h> #include <intelblocks/sgx.h> @@ -19,7 +20,6 @@ #include <soc/gpio.h> #include <soc/iomap.h> #include <soc/pm.h> -#include <cpu/x86/lapic.h>
#define CPUID_6_EAX_ISST (1 << 7)
diff --git a/src/soc/intel/common/block/acpi/sgx.c b/src/soc/intel/common/block/acpi/sgx.c index 7d9073d..4d2bab5 100644 --- a/src/soc/intel/common/block/acpi/sgx.c +++ b/src/soc/intel/common/block/acpi/sgx.c @@ -1,8 +1,8 @@ /* SPDX-License-Identifier: GPL-2.0-only */
#include <acpi/acpigen.h> -#include <arch/cpu.h> #include <console/console.h> +#include <cpu/cpu.h> #include <intelblocks/acpi.h> #include <intelblocks/sgx.h>
diff --git a/src/soc/intel/common/block/cpu/cpulib.c b/src/soc/intel/common/block/cpu/cpulib.c index 4898066..1c7a173 100644 --- a/src/soc/intel/common/block/cpu/cpulib.c +++ b/src/soc/intel/common/block/cpu/cpulib.c @@ -1,13 +1,13 @@ /* SPDX-License-Identifier: GPL-2.0-only */
-#include <assert.h> #include <acpi/acpigen.h> +#include <assert.h> #include <console/console.h> +#include <cpu/cpu.h> #include <cpu/intel/common/common.h> #include <cpu/intel/turbo.h> #include <cpu/x86/msr.h> #include <cpu/x86/mtrr.h> -#include <arch/cpu.h> #include <intelblocks/cpulib.h> #include <intelblocks/fast_spi.h> #include <intelblocks/msr.h> diff --git a/src/soc/intel/common/block/cse/cse_lite.c b/src/soc/intel/common/block/cse/cse_lite.c index 1d30a8d..f051061 100644 --- a/src/soc/intel/common/block/cse/cse_lite.c +++ b/src/soc/intel/common/block/cse/cse_lite.c @@ -1,17 +1,17 @@ /* SPDX-License-Identifier: GPL-2.0-only */
#include <acpi/acpi.h> -#include <arch/cpu.h> #include <bootstate.h> -#include <console/console.h> #include <cbfs.h> #include <commonlib/region.h> +#include <console/console.h> +#include <cpu/cpu.h> #include <fmap.h> +#include <intelbasecode/debug_feature.h> #include <intelblocks/cse.h> #include <intelblocks/cse_layout.h> -#include <intelbasecode/debug_feature.h> -#include <security/vboot/vboot_common.h> #include <security/vboot/misc.h> +#include <security/vboot/vboot_common.h> #include <soc/intel/common/reset.h> #include <timestamp.h>
diff --git a/src/soc/intel/common/block/timer/timer.c b/src/soc/intel/common/block/timer/timer.c index 0d201a5..88d1bf2 100644 --- a/src/soc/intel/common/block/timer/timer.c +++ b/src/soc/intel/common/block/timer/timer.c @@ -1,6 +1,6 @@ /* SPDX-License-Identifier: GPL-2.0-only */
-#include <arch/cpu.h> +#include <cpu/cpu.h> #include <cpu/x86/tsc.h> #include <intelblocks/msr.h>
diff --git a/src/soc/intel/elkhartlake/bootblock/report_platform.c b/src/soc/intel/elkhartlake/bootblock/report_platform.c index cc3462d..40816bb 100644 --- a/src/soc/intel/elkhartlake/bootblock/report_platform.c +++ b/src/soc/intel/elkhartlake/bootblock/report_platform.c @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: GPL-2.0-only */
-#include <arch/cpu.h> #include <console/console.h> +#include <cpu/cpu.h> #include <cpu/intel/cpu_ids.h> #include <cpu/intel/microcode.h> #include <cpu/x86/msr.h> diff --git a/src/soc/intel/icelake/bootblock/report_platform.c b/src/soc/intel/icelake/bootblock/report_platform.c index 2188009..2a1a13b 100644 --- a/src/soc/intel/icelake/bootblock/report_platform.c +++ b/src/soc/intel/icelake/bootblock/report_platform.c @@ -1,13 +1,13 @@ /* SPDX-License-Identifier: GPL-2.0-only */
-#include <arch/cpu.h> -#include <device/pci_ops.h> #include <console/console.h> +#include <cpu/cpu.h> #include <cpu/intel/cpu_ids.h> #include <cpu/intel/microcode.h> #include <cpu/x86/msr.h> #include <device/pci.h> #include <device/pci_ids.h> +#include <device/pci_ops.h> #include <soc/bootblock.h> #include <soc/pch.h> #include <soc/pci_devs.h> diff --git a/src/soc/intel/jasperlake/bootblock/report_platform.c b/src/soc/intel/jasperlake/bootblock/report_platform.c index 0d2fe43..357d038 100644 --- a/src/soc/intel/jasperlake/bootblock/report_platform.c +++ b/src/soc/intel/jasperlake/bootblock/report_platform.c @@ -1,14 +1,14 @@ /* SPDX-License-Identifier: GPL-2.0-only */
-#include <arch/cpu.h> -#include <device/pci_ops.h> #include <console/console.h> +#include <cpu/cpu.h> #include <cpu/intel/cpu_ids.h> #include <cpu/intel/microcode.h> #include <cpu/x86/msr.h> #include <cpu/x86/name.h> #include <device/pci.h> #include <device/pci_ids.h> +#include <device/pci_ops.h> #include <soc/bootblock.h> #include <soc/pch.h> #include <soc/pci_devs.h> diff --git a/src/soc/intel/meteorlake/bootblock/report_platform.c b/src/soc/intel/meteorlake/bootblock/report_platform.c index 72d0d83..63f1771 100644 --- a/src/soc/intel/meteorlake/bootblock/report_platform.c +++ b/src/soc/intel/meteorlake/bootblock/report_platform.c @@ -1,14 +1,14 @@ /* SPDX-License-Identifier: GPL-2.0-only */
-#include <arch/cpu.h> -#include <device/pci_ops.h> #include <console/console.h> +#include <cpu/cpu.h> #include <cpu/intel/cpu_ids.h> #include <cpu/intel/microcode.h> #include <cpu/x86/msr.h> #include <cpu/x86/name.h> #include <device/pci.h> #include <device/pci_ids.h> +#include <device/pci_ops.h> #include <soc/bootblock.h> #include <soc/pci_devs.h>
diff --git a/src/soc/intel/meteorlake/cpu.c b/src/soc/intel/meteorlake/cpu.c index 00caaa5..55ab15c 100644 --- a/src/soc/intel/meteorlake/cpu.c +++ b/src/soc/intel/meteorlake/cpu.c @@ -1,25 +1,25 @@ /* SPDX-License-Identifier: GPL-2.0-only */
-#include <arch/cpu.h> +#include <assert.h> #include <console/console.h> -#include <device/pci.h> +#include <cpu/cpu.h> +#include <cpu/intel/common/common.h> +#include <cpu/intel/smm_reloc.h> +#include <cpu/intel/turbo.h> #include <cpu/x86/lapic.h> #include <cpu/x86/mp.h> #include <cpu/x86/msr.h> -#include <cpu/intel/smm_reloc.h> -#include <cpu/intel/turbo.h> -#include <cpu/intel/common/common.h> +#include <device/pci.h> #include <fsp/api.h> +#include <intelblocks/acpi.h> #include <intelblocks/cpulib.h> #include <intelblocks/mp_init.h> #include <intelblocks/msr.h> -#include <intelblocks/acpi.h> #include <soc/cpu.h> #include <soc/msr.h> #include <soc/pci_devs.h> #include <soc/soc_chip.h> #include <soc/soc_info.h> -#include <assert.h>
bool cpu_soc_is_in_untrusted_mode(void) { diff --git a/src/soc/intel/quark/include/soc/ramstage.h b/src/soc/intel/quark/include/soc/ramstage.h index d54a74a..3002322f 100644 --- a/src/soc/intel/quark/include/soc/ramstage.h +++ b/src/soc/intel/quark/include/soc/ramstage.h @@ -3,7 +3,7 @@ #ifndef _SOC_RAMSTAGE_H_ #define _SOC_RAMSTAGE_H_
-#include <arch/cpu.h> +#include <cpu/cpu.h> #include <device/device.h> #include <soc/QuarkNcSocId.h>
diff --git a/src/soc/intel/quark/romstage/report_platform.c b/src/soc/intel/quark/romstage/report_platform.c index ab5b0d1..3b4e367 100644 --- a/src/soc/intel/quark/romstage/report_platform.c +++ b/src/soc/intel/quark/romstage/report_platform.c @@ -1,10 +1,10 @@ /* SPDX-License-Identifier: GPL-2.0-only */
-#include <arch/cpu.h> #include <console/console.h> +#include <cpu/cpu.h> #include <device/pci.h> -#include <device/pci_ops.h> #include <device/pci_def.h> +#include <device/pci_ops.h> #include <soc/cpu.h> #include <soc/pci_devs.h> #include <soc/romstage.h> diff --git a/src/soc/intel/skylake/acpi.c b/src/soc/intel/skylake/acpi.c index 9ae0bb6..5824630 100644 --- a/src/soc/intel/skylake/acpi.c +++ b/src/soc/intel/skylake/acpi.c @@ -1,15 +1,15 @@ /* SPDX-License-Identifier: GPL-2.0-only */
-#include <acpi/acpi.h> #include <acpi/acpi_gnvs.h> #include <acpi/acpi_pm.h> +#include <acpi/acpi.h> #include <acpi/acpigen.h> -#include <arch/cpu.h> #include <arch/ioapic.h> #include <arch/smp/mpspec.h> #include <console/console.h> -#include <intelblocks/acpi.h> +#include <cpu/cpu.h> #include <intelblocks/acpi_wake_source.h> +#include <intelblocks/acpi.h> #include <intelblocks/cpulib.h> #include <intelblocks/pmclib.h> #include <soc/cpu.h> diff --git a/src/soc/intel/skylake/bootblock/report_platform.c b/src/soc/intel/skylake/bootblock/report_platform.c index 3cfac5e..ce250ad 100644 --- a/src/soc/intel/skylake/bootblock/report_platform.c +++ b/src/soc/intel/skylake/bootblock/report_platform.c @@ -1,14 +1,14 @@ /* SPDX-License-Identifier: GPL-2.0-only */
-#include <arch/cpu.h> -#include <device/pci_ops.h> #include <console/console.h> +#include <cpu/cpu.h> #include <cpu/intel/cpu_ids.h> #include <cpu/intel/microcode.h> #include <cpu/x86/msr.h> #include <cpu/x86/name.h> #include <device/pci.h> #include <device/pci_ids.h> +#include <device/pci_ops.h> #include <soc/bootblock.h> #include <soc/cpu.h> #include <soc/pch.h> diff --git a/src/soc/intel/tigerlake/bootblock/report_platform.c b/src/soc/intel/tigerlake/bootblock/report_platform.c index af7a96a..1ecaf77 100644 --- a/src/soc/intel/tigerlake/bootblock/report_platform.c +++ b/src/soc/intel/tigerlake/bootblock/report_platform.c @@ -6,14 +6,14 @@ * Chapter number: 2, 4, 5, 6 */
-#include <arch/cpu.h> -#include <device/pci_ops.h> #include <console/console.h> +#include <cpu/cpu.h> #include <cpu/intel/cpu_ids.h> #include <cpu/intel/microcode.h> #include <cpu/x86/msr.h> #include <device/pci.h> #include <device/pci_ids.h> +#include <device/pci_ops.h> #include <soc/bootblock.h> #include <soc/pch.h> #include <soc/pci_devs.h> diff --git a/src/soc/intel/tigerlake/lpm.c b/src/soc/intel/tigerlake/lpm.c index 0dd725a..fe4f43d 100644 --- a/src/soc/intel/tigerlake/lpm.c +++ b/src/soc/intel/tigerlake/lpm.c @@ -1,10 +1,10 @@ /* SPDX-License-Identifier: GPL-2.0-or-later */
-#include <arch/cpu.h> -#include <device/device.h> -#include <device/pci_ops.h> -#include <device/pci_ids.h> +#include <cpu/cpu.h> #include <cpu/intel/cpu_ids.h> +#include <device/device.h> +#include <device/pci_ids.h> +#include <device/pci_ops.h> #include <soc/lpm.h> #include <soc/pci_devs.h> #include <soc/soc_chip.h>