diff options
author | Elyes Haouas <ehaouas@noos.fr> | 2023-01-12 06:21:42 +0100 |
---|---|---|
committer | Elyes Haouas <ehaouas@noos.fr> | 2023-01-17 04:23:49 +0000 |
commit | 24769421cd1df4f58a8addce16ff9c46080ba1ba (patch) | |
tree | f88a0af9a0ee4b367f4891bf34ce3f1a8b25ab0c | |
parent | 4d661eebe95b06acae7d99777ed36ba56a560112 (diff) | |
download | coreboot-24769421cd1df4f58a8addce16ff9c46080ba1ba.tar.gz coreboot-24769421cd1df4f58a8addce16ff9c46080ba1ba.tar.bz2 coreboot-24769421cd1df4f58a8addce16ff9c46080ba1ba.zip |
treewide: Fix old-style declarations
Replace old style declaration "const static" with "static const".
This to enable "Wold-style-declaration" command option.
Change-Id: I757632befed1854f422daaf4dfea58281b16e2f5
Signed-off-by: Elyes Haouas <ehaouas@noos.fr>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/71841
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Eric Lai <eric_lai@quanta.corp-partner.google.com>
-rw-r--r-- | src/drivers/mrc_cache/mrc_cache.c | 2 | ||||
-rw-r--r-- | src/mainboard/google/drallion/variants/drallion/include/variant/variant.h | 2 | ||||
-rw-r--r-- | src/mainboard/sifive/hifive-unleashed/media.c | 2 | ||||
-rw-r--r-- | src/soc/amd/cezanne/aoac.c | 2 | ||||
-rw-r--r-- | src/soc/amd/cezanne/fch.c | 2 | ||||
-rw-r--r-- | src/soc/amd/glinda/aoac.c | 2 | ||||
-rw-r--r-- | src/soc/amd/glinda/fch.c | 2 | ||||
-rw-r--r-- | src/soc/amd/mendocino/aoac.c | 2 | ||||
-rw-r--r-- | src/soc/amd/mendocino/fch.c | 2 | ||||
-rw-r--r-- | src/soc/amd/phoenix/aoac.c | 2 | ||||
-rw-r--r-- | src/soc/amd/phoenix/fch.c | 2 | ||||
-rw-r--r-- | src/soc/amd/picasso/aoac.c | 2 | ||||
-rw-r--r-- | src/soc/amd/picasso/fch.c | 2 | ||||
-rw-r--r-- | src/soc/samsung/exynos5250/alternate_cbfs.c | 2 | ||||
-rw-r--r-- | src/vendorcode/amd/pi/Lib/amdlib.c | 12 |
15 files changed, 20 insertions, 20 deletions
diff --git a/src/drivers/mrc_cache/mrc_cache.c b/src/drivers/mrc_cache/mrc_cache.c index 484b414dfacf..bb560c89bdf8 100644 --- a/src/drivers/mrc_cache/mrc_cache.c +++ b/src/drivers/mrc_cache/mrc_cache.c @@ -25,7 +25,7 @@ /* Signature "MRCD" was used for older header format before CB:67670. */ #define MRC_DATA_SIGNATURE (('M'<<0)|('R'<<8)|('C'<<16)|('d'<<24)) -const static uint32_t mrc_invalid_sig = ~MRC_DATA_SIGNATURE; +static const uint32_t mrc_invalid_sig = ~MRC_DATA_SIGNATURE; struct mrc_metadata { uint32_t signature; diff --git a/src/mainboard/google/drallion/variants/drallion/include/variant/variant.h b/src/mainboard/google/drallion/variants/drallion/include/variant/variant.h index c61a06319a52..8d641aff68f6 100644 --- a/src/mainboard/google/drallion/variants/drallion/include/variant/variant.h +++ b/src/mainboard/google/drallion/variants/drallion/include/variant/variant.h @@ -12,7 +12,7 @@ typedef struct { const char *name; } sku_info; -const static sku_info skus[] = { +static const sku_info skus[] = { // Drallion 360 { .id = 1, .name = "sku1" }, // Drallion diff --git a/src/mainboard/sifive/hifive-unleashed/media.c b/src/mainboard/sifive/hifive-unleashed/media.c index f3dcf7f62185..a225dda9e921 100644 --- a/src/mainboard/sifive/hifive-unleashed/media.c +++ b/src/mainboard/sifive/hifive-unleashed/media.c @@ -56,7 +56,7 @@ const struct region_device *boot_device_ro(void) return NULL; } -const static struct fu540_spi_mmap_config spi_mmap_config = { +static const struct fu540_spi_mmap_config spi_mmap_config = { .cmd_en = 1, .addr_len = 4, .pad_cnt = 6, diff --git a/src/soc/amd/cezanne/aoac.c b/src/soc/amd/cezanne/aoac.c index c313a55b5f6f..14758e0da46a 100644 --- a/src/soc/amd/cezanne/aoac.c +++ b/src/soc/amd/cezanne/aoac.c @@ -23,7 +23,7 @@ * * TODO: Find out which I2C controllers we really need to enable here. */ -const static unsigned int aoac_devs[] = { +static const unsigned int aoac_devs[] = { FCH_AOAC_DEV_AMBA, FCH_AOAC_DEV_I2C0, FCH_AOAC_DEV_I2C1, diff --git a/src/soc/amd/cezanne/fch.c b/src/soc/amd/cezanne/fch.c index 1ceb8bc7b979..0936c5e255e8 100644 --- a/src/soc/amd/cezanne/fch.c +++ b/src/soc/amd/cezanne/fch.c @@ -29,7 +29,7 @@ * amd_pci_int_defs.h, just add the pair at the end of this table. * Order is not important. */ -const static struct irq_idx_name irq_association[] = { +static const struct irq_idx_name irq_association[] = { { PIRQ_A, "INTA#" }, { PIRQ_B, "INTB#" }, { PIRQ_C, "INTC#" }, diff --git a/src/soc/amd/glinda/aoac.c b/src/soc/amd/glinda/aoac.c index 9cb9c1a0e21f..ab3ec59c1ea5 100644 --- a/src/soc/amd/glinda/aoac.c +++ b/src/soc/amd/glinda/aoac.c @@ -28,7 +28,7 @@ * * TODO: Find out which I2C controllers we really need to enable here. */ -const static unsigned int aoac_devs[] = { +static const unsigned int aoac_devs[] = { FCH_AOAC_DEV_AMBA, FCH_AOAC_DEV_I2C0, FCH_AOAC_DEV_I2C1, diff --git a/src/soc/amd/glinda/fch.c b/src/soc/amd/glinda/fch.c index ea196c0af180..af5f0ecf282d 100644 --- a/src/soc/amd/glinda/fch.c +++ b/src/soc/amd/glinda/fch.c @@ -25,7 +25,7 @@ * amd_pci_int_defs.h, just add the pair at the end of this table. * Order is not important. */ -const static struct irq_idx_name irq_association[] = { +static const struct irq_idx_name irq_association[] = { { PIRQ_A, "INTA#" }, { PIRQ_B, "INTB#" }, { PIRQ_C, "INTC#" }, diff --git a/src/soc/amd/mendocino/aoac.c b/src/soc/amd/mendocino/aoac.c index ab5254418947..d63ca6258783 100644 --- a/src/soc/amd/mendocino/aoac.c +++ b/src/soc/amd/mendocino/aoac.c @@ -26,7 +26,7 @@ * * TODO: Find out which I2C controllers we really need to enable here. */ -const static unsigned int aoac_devs[] = { +static const unsigned int aoac_devs[] = { FCH_AOAC_DEV_AMBA, FCH_AOAC_DEV_I2C0, FCH_AOAC_DEV_I2C1, diff --git a/src/soc/amd/mendocino/fch.c b/src/soc/amd/mendocino/fch.c index 4427ab6fa357..d7c488bf67d6 100644 --- a/src/soc/amd/mendocino/fch.c +++ b/src/soc/amd/mendocino/fch.c @@ -24,7 +24,7 @@ * amd_pci_int_defs.h, just add the pair at the end of this table. * Order is not important. */ -const static struct irq_idx_name irq_association[] = { +static const struct irq_idx_name irq_association[] = { { PIRQ_A, "INTA#" }, { PIRQ_B, "INTB#" }, { PIRQ_C, "INTC#" }, diff --git a/src/soc/amd/phoenix/aoac.c b/src/soc/amd/phoenix/aoac.c index ab5254418947..d63ca6258783 100644 --- a/src/soc/amd/phoenix/aoac.c +++ b/src/soc/amd/phoenix/aoac.c @@ -26,7 +26,7 @@ * * TODO: Find out which I2C controllers we really need to enable here. */ -const static unsigned int aoac_devs[] = { +static const unsigned int aoac_devs[] = { FCH_AOAC_DEV_AMBA, FCH_AOAC_DEV_I2C0, FCH_AOAC_DEV_I2C1, diff --git a/src/soc/amd/phoenix/fch.c b/src/soc/amd/phoenix/fch.c index 7e265338dfb9..91df79e35abc 100644 --- a/src/soc/amd/phoenix/fch.c +++ b/src/soc/amd/phoenix/fch.c @@ -24,7 +24,7 @@ * amd_pci_int_defs.h, just add the pair at the end of this table. * Order is not important. */ -const static struct irq_idx_name irq_association[] = { +static const struct irq_idx_name irq_association[] = { { PIRQ_A, "INTA#" }, { PIRQ_B, "INTB#" }, { PIRQ_C, "INTC#" }, diff --git a/src/soc/amd/picasso/aoac.c b/src/soc/amd/picasso/aoac.c index 13d6be4976c6..a191032c2239 100644 --- a/src/soc/amd/picasso/aoac.c +++ b/src/soc/amd/picasso/aoac.c @@ -23,7 +23,7 @@ * waiting for each device to become available, a single delay will be * executed. The console UART is handled separately from this table. */ -const static unsigned int aoac_devs[] = { +static const unsigned int aoac_devs[] = { FCH_AOAC_DEV_AMBA, FCH_AOAC_DEV_I2C2, FCH_AOAC_DEV_I2C3, diff --git a/src/soc/amd/picasso/fch.c b/src/soc/amd/picasso/fch.c index e364a48419b2..a1eef6f53409 100644 --- a/src/soc/amd/picasso/fch.c +++ b/src/soc/amd/picasso/fch.c @@ -31,7 +31,7 @@ * amd_pci_int_defs.h, just add the pair at the end of this table. * Order is not important. */ -const static struct irq_idx_name irq_association[] = { +static const struct irq_idx_name irq_association[] = { { PIRQ_A, "INTA#" }, { PIRQ_B, "INTB#" }, { PIRQ_C, "INTC#" }, diff --git a/src/soc/samsung/exynos5250/alternate_cbfs.c b/src/soc/samsung/exynos5250/alternate_cbfs.c index a540c3cadf90..4da2333edc25 100644 --- a/src/soc/samsung/exynos5250/alternate_cbfs.c +++ b/src/soc/samsung/exynos5250/alternate_cbfs.c @@ -92,7 +92,7 @@ static int sdmmc_cbfs_open(void) return 0; } -const static struct mem_region_device alternate_rdev = +static const struct mem_region_device alternate_rdev = MEM_REGION_DEV_RO_INIT(_cbfs_cache, REGION_SIZE(cbfs_cache)); const struct region_device *boot_device_ro(void) diff --git a/src/vendorcode/amd/pi/Lib/amdlib.c b/src/vendorcode/amd/pi/Lib/amdlib.c index a5f6898c3f69..cc742301d602 100644 --- a/src/vendorcode/amd/pi/Lib/amdlib.c +++ b/src/vendorcode/amd/pi/Lib/amdlib.c @@ -58,16 +58,16 @@ RDATA_GROUP (G1_PEICC) #define FILECODE LIB_AMDLIB_FILECODE -BOOLEAN STATIC +BOOLEAN GetPciMmioAddress ( OUT UINT64 *MmioAddress, OUT UINT32 *MmioSize, IN AMD_CONFIG_PARAMS *StdHeader ); -VOID STATIC +VOID LibAmdGetDataFromPtr ( IN ACCESS_WIDTH AccessWidth, IN CONST VOID *Data, @@ -150,8 +150,8 @@ WriteIo32 ( __outdword (Address, Data); } -AMDLIB_OPTIMIZE STATIC +AMDLIB_OPTIMIZE UINT64 SetFsBase ( UINT64 address ) @@ -163,8 +163,8 @@ UINT64 SetFsBase ( return hwcr; } -AMDLIB_OPTIMIZE STATIC +AMDLIB_OPTIMIZE VOID RestoreHwcr ( UINT64 @@ -961,8 +961,8 @@ LibAmdPciPoll ( * * @retval TRUE MmioAddress/MmioSize are valid */ -BOOLEAN STATIC +BOOLEAN GetPciMmioAddress ( OUT UINT64 *MmioAddress, OUT UINT32 *MmioSize, @@ -1300,8 +1300,8 @@ LibAmdGetPackageType ( * @param[out] TempDataMask typecast data */ -VOID STATIC +VOID LibAmdGetDataFromPtr ( IN ACCESS_WIDTH AccessWidth, IN CONST VOID *Data, |