From 8f06ce35125869f631a3c7a072503103feca227c Mon Sep 17 00:00:00 2001 From: Jonathan Neuschäfer Date: Mon, 20 Nov 2017 01:56:44 +0100 Subject: Constify struct cpu_device_id instances MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit There is currently no case where a struct cpu_device_id instance needs to be modified. Thus, declare all instances as const. Change-Id: I5ec7460b56d75d255b3451d76a46df76a51d6365 Signed-off-by: Jonathan Neuschäfer Reviewed-on: https://review.coreboot.org/22526 Tested-by: build bot (Jenkins) Reviewed-by: Paul Menzel Reviewed-by: Aaron Durbin --- src/soc/amd/stoneyridge/model_15_init.c | 2 +- src/soc/intel/apollolake/cpu.c | 2 +- src/soc/intel/baytrail/cpu.c | 2 +- src/soc/intel/braswell/cpu.c | 2 +- src/soc/intel/broadwell/cpu.c | 2 +- src/soc/intel/common/block/cpu/mp_init.c | 2 +- src/soc/intel/denverton_ns/cpu.c | 2 +- src/soc/intel/fsp_baytrail/cpu.c | 2 +- src/soc/intel/fsp_broadwell_de/cpu.c | 2 +- 9 files changed, 9 insertions(+), 9 deletions(-) (limited to 'src/soc') diff --git a/src/soc/amd/stoneyridge/model_15_init.c b/src/soc/amd/stoneyridge/model_15_init.c index c3e9bf52bd..930e395507 100644 --- a/src/soc/amd/stoneyridge/model_15_init.c +++ b/src/soc/amd/stoneyridge/model_15_init.c @@ -87,7 +87,7 @@ static struct device_operations cpu_dev_ops = { .init = model_15_init, }; -static struct cpu_device_id cpu_table[] = { +static const struct cpu_device_id cpu_table[] = { { X86_VENDOR_AMD, 0x670f00 }, { 0, 0 }, }; diff --git a/src/soc/intel/apollolake/cpu.c b/src/soc/intel/apollolake/cpu.c index d2c7001ede..96c37f1518 100644 --- a/src/soc/intel/apollolake/cpu.c +++ b/src/soc/intel/apollolake/cpu.c @@ -103,7 +103,7 @@ static struct device_operations cpu_dev_ops = { .init = soc_init_core, }; -static struct cpu_device_id cpu_table[] = { +static const struct cpu_device_id cpu_table[] = { { X86_VENDOR_INTEL, CPUID_APOLLOLAKE_A0 }, { X86_VENDOR_INTEL, CPUID_APOLLOLAKE_B0 }, { X86_VENDOR_INTEL, CPUID_APOLLOLAKE_E0 }, diff --git a/src/soc/intel/baytrail/cpu.c b/src/soc/intel/baytrail/cpu.c index a3844047c4..ed18ce10bf 100644 --- a/src/soc/intel/baytrail/cpu.c +++ b/src/soc/intel/baytrail/cpu.c @@ -66,7 +66,7 @@ static struct device_operations cpu_dev_ops = { .init = baytrail_core_init, }; -static struct cpu_device_id cpu_table[] = { +static const struct cpu_device_id cpu_table[] = { { X86_VENDOR_INTEL, 0x30673 }, { X86_VENDOR_INTEL, 0x30678 }, { 0, 0 }, diff --git a/src/soc/intel/braswell/cpu.c b/src/soc/intel/braswell/cpu.c index a2bd180da5..ed7e2faac8 100644 --- a/src/soc/intel/braswell/cpu.c +++ b/src/soc/intel/braswell/cpu.c @@ -71,7 +71,7 @@ static struct device_operations cpu_dev_ops = { .init = soc_core_init, }; -static struct cpu_device_id cpu_table[] = { +static const struct cpu_device_id cpu_table[] = { { X86_VENDOR_INTEL, 0x406C4 }, { X86_VENDOR_INTEL, 0x406C3 }, { X86_VENDOR_INTEL, 0x406C2 }, diff --git a/src/soc/intel/broadwell/cpu.c b/src/soc/intel/broadwell/cpu.c index 7b56db17fc..ecb7247900 100644 --- a/src/soc/intel/broadwell/cpu.c +++ b/src/soc/intel/broadwell/cpu.c @@ -684,7 +684,7 @@ static struct device_operations cpu_dev_ops = { .init = cpu_core_init, }; -static struct cpu_device_id cpu_table[] = { +static const struct cpu_device_id cpu_table[] = { { X86_VENDOR_INTEL, CPUID_HASWELL_ULT }, { X86_VENDOR_INTEL, CPUID_BROADWELL_C0 }, { X86_VENDOR_INTEL, CPUID_BROADWELL_D0 }, diff --git a/src/soc/intel/common/block/cpu/mp_init.c b/src/soc/intel/common/block/cpu/mp_init.c index e301c24447..e19127c1b3 100644 --- a/src/soc/intel/common/block/cpu/mp_init.c +++ b/src/soc/intel/common/block/cpu/mp_init.c @@ -50,7 +50,7 @@ static struct device_operations cpu_dev_ops = { .init = init_one_cpu, }; -static struct cpu_device_id cpu_table[] = { +static const struct cpu_device_id cpu_table[] = { { X86_VENDOR_INTEL, CPUID_SKYLAKE_C0 }, { X86_VENDOR_INTEL, CPUID_SKYLAKE_D0 }, { X86_VENDOR_INTEL, CPUID_SKYLAKE_HQ0 }, diff --git a/src/soc/intel/denverton_ns/cpu.c b/src/soc/intel/denverton_ns/cpu.c index b6c05e754c..528d2e5ae6 100644 --- a/src/soc/intel/denverton_ns/cpu.c +++ b/src/soc/intel/denverton_ns/cpu.c @@ -54,7 +54,7 @@ static struct device_operations cpu_dev_ops = { .init = denverton_core_init, }; -static struct cpu_device_id cpu_table[] = { +static const struct cpu_device_id cpu_table[] = { {X86_VENDOR_INTEL, CPUID_DENVERTON_A0_A1}, /* Denverton-NS A0/A1 CPUID */ {X86_VENDOR_INTEL, CPUID_DENVERTON_B0}, /* Denverton-NS B0 CPUID */ diff --git a/src/soc/intel/fsp_baytrail/cpu.c b/src/soc/intel/fsp_baytrail/cpu.c index c3879e1f95..38c4446e01 100644 --- a/src/soc/intel/fsp_baytrail/cpu.c +++ b/src/soc/intel/fsp_baytrail/cpu.c @@ -64,7 +64,7 @@ static struct device_operations cpu_dev_ops = { .init = baytrail_core_init, }; -static struct cpu_device_id cpu_table[] = { +static const struct cpu_device_id cpu_table[] = { { X86_VENDOR_INTEL, 0x30671 }, { X86_VENDOR_INTEL, 0x30672 }, { X86_VENDOR_INTEL, 0x30673 }, diff --git a/src/soc/intel/fsp_broadwell_de/cpu.c b/src/soc/intel/fsp_broadwell_de/cpu.c index 68825a365f..d89ae87b1d 100644 --- a/src/soc/intel/fsp_broadwell_de/cpu.c +++ b/src/soc/intel/fsp_broadwell_de/cpu.c @@ -160,7 +160,7 @@ static struct device_operations cpu_dev_ops = { .init = broadwell_de_core_init, }; -static struct cpu_device_id cpu_table[] = { +static const struct cpu_device_id cpu_table[] = { { X86_VENDOR_INTEL, 0x50661 }, { X86_VENDOR_INTEL, 0x50662 }, { X86_VENDOR_INTEL, 0x50663 }, -- cgit v1.2.3