diff options
author | Elyes HAOUAS <ehaouas@noos.fr> | 2019-03-18 22:49:36 +0100 |
---|---|---|
committer | Kyösti Mälkki <kyosti.malkki@gmail.com> | 2019-03-20 20:27:51 +0000 |
commit | a1e22b8192d5fc85995a41d0961c25293ba4391f (patch) | |
tree | 7b7dbc885d3ac99fe029cf0961eda1052e753dc1 /src/northbridge/intel | |
parent | 0eb4db185cfef44ddfdbd91d4fe69a48c127fa84 (diff) |
src: Use 'include <string.h>' when appropriate
Drop 'include <string.h>' when it is not used and
add it when it is missing.
Also extra lines removed, or added just before local includes.
Change-Id: Iccac4dbaa2dd4144fc347af36ecfc9747da3de20
Signed-off-by: Elyes HAOUAS <ehaouas@noos.fr>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/31966
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Werner Zeh <werner.zeh@siemens.com>
Reviewed-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Diffstat (limited to 'src/northbridge/intel')
27 files changed, 13 insertions, 31 deletions
diff --git a/src/northbridge/intel/e7505/northbridge.c b/src/northbridge/intel/e7505/northbridge.c index 8c31f7ee83..e3d3faf4a1 100644 --- a/src/northbridge/intel/e7505/northbridge.c +++ b/src/northbridge/intel/e7505/northbridge.c @@ -11,6 +11,7 @@ * GNU General Public License for more details. */ +#include <arch/acpi.h> #include <console/console.h> #include <device/pci_ops.h> #include <stdint.h> @@ -18,9 +19,8 @@ #include <device/pci.h> #include <cpu/cpu.h> #include <stdlib.h> -#include <string.h> + #include "e7505.h" -#include <arch/acpi.h> unsigned long acpi_fill_mcfg(unsigned long current) { diff --git a/src/northbridge/intel/fsp_rangeley/acpi.c b/src/northbridge/intel/fsp_rangeley/acpi.c index 901843d0e1..0c52d52588 100644 --- a/src/northbridge/intel/fsp_rangeley/acpi.c +++ b/src/northbridge/intel/fsp_rangeley/acpi.c @@ -17,12 +17,12 @@ */ #include <types.h> -#include <string.h> #include <arch/acpi.h> #include <device/device.h> #include <device/pci.h> #include <device/pci_ids.h> #include <arch/acpigen.h> + #include "northbridge.h" unsigned long acpi_fill_mcfg(unsigned long current) diff --git a/src/northbridge/intel/fsp_rangeley/northbridge.c b/src/northbridge/intel/fsp_rangeley/northbridge.c index cd900be438..7663b26513 100644 --- a/src/northbridge/intel/fsp_rangeley/northbridge.c +++ b/src/northbridge/intel/fsp_rangeley/northbridge.c @@ -25,13 +25,13 @@ #include <device/pci.h> #include <device/pci_ids.h> #include <stdlib.h> -#include <string.h> #include <cpu/cpu.h> -#include "chip.h" -#include "northbridge.h" #include <drivers/intel/fsp1_0/fsp_util.h> #include <cpu/x86/lapic.h> +#include "chip.h" +#include "northbridge.h" + static int bridge_revision_id = -1; int bridge_silicon_revision(void) diff --git a/src/northbridge/intel/fsp_rangeley/raminit.c b/src/northbridge/intel/fsp_rangeley/raminit.c index 32941357cf..da9ed71a67 100644 --- a/src/northbridge/intel/fsp_rangeley/raminit.c +++ b/src/northbridge/intel/fsp_rangeley/raminit.c @@ -14,12 +14,12 @@ * GNU General Public License for more details. */ -#include <string.h> #include <cbmem.h> #include <device/pci_def.h> -#include "northbridge.h" #include <drivers/intel/fsp1_0/fsp_util.h> +#include "northbridge.h" + static uintptr_t smm_region_start(void) { /* diff --git a/src/northbridge/intel/gm45/acpi.c b/src/northbridge/intel/gm45/acpi.c index 301743ce4a..decf712302 100644 --- a/src/northbridge/intel/gm45/acpi.c +++ b/src/northbridge/intel/gm45/acpi.c @@ -15,13 +15,13 @@ */ #include <types.h> -#include <string.h> #include <console/console.h> #include <arch/acpi.h> #include <arch/acpigen.h> #include <device/device.h> #include <device/pci.h> #include <device/pci_ops.h> + #include "gm45.h" unsigned long acpi_fill_mcfg(unsigned long current) diff --git a/src/northbridge/intel/gm45/northbridge.c b/src/northbridge/intel/gm45/northbridge.c index 40e4f61afd..f011cce8d7 100644 --- a/src/northbridge/intel/gm45/northbridge.c +++ b/src/northbridge/intel/gm45/northbridge.c @@ -20,11 +20,11 @@ #include <device/device.h> #include <device/pci.h> #include <stdlib.h> -#include <string.h> #include <cpu/cpu.h> #include <boot/tables.h> #include <arch/acpi.h> #include <cpu/intel/smm/gen1/smi.h> + #include "chip.h" #include "gm45.h" diff --git a/src/northbridge/intel/gm45/pcie.c b/src/northbridge/intel/gm45/pcie.c index c470b8147c..4199274f3c 100644 --- a/src/northbridge/intel/gm45/pcie.c +++ b/src/northbridge/intel/gm45/pcie.c @@ -16,7 +16,6 @@ #include <stdint.h> #include <stddef.h> -#include <string.h> #include <device/pci_ops.h> #include <device/pci_def.h> #include <console/console.h> diff --git a/src/northbridge/intel/gm45/pm.c b/src/northbridge/intel/gm45/pm.c index a447a23093..d96bcf4528 100644 --- a/src/northbridge/intel/gm45/pm.c +++ b/src/northbridge/intel/gm45/pm.c @@ -16,7 +16,6 @@ #include <stdint.h> #include <stddef.h> -#include <string.h> #include <device/pci_def.h> #include <cpu/x86/msr.h> #include <cpu/intel/speedstep.h> diff --git a/src/northbridge/intel/gm45/romstage.c b/src/northbridge/intel/gm45/romstage.c index 7335ac914f..09439f25ef 100644 --- a/src/northbridge/intel/gm45/romstage.c +++ b/src/northbridge/intel/gm45/romstage.c @@ -27,6 +27,7 @@ #include <northbridge/intel/gm45/gm45.h> #include <southbridge/intel/i82801ix/i82801ix.h> #include <southbridge/intel/common/gpio.h> +#include <string.h> #define LPC_DEV PCI_DEV(0, 0x1f, 0) #define MCH_DEV PCI_DEV(0, 0, 0) diff --git a/src/northbridge/intel/gm45/thermal.c b/src/northbridge/intel/gm45/thermal.c index 3ed75b30af..1629a67b8d 100644 --- a/src/northbridge/intel/gm45/thermal.c +++ b/src/northbridge/intel/gm45/thermal.c @@ -16,11 +16,10 @@ #include <stdint.h> #include <stddef.h> -#include <string.h> #include <device/pci_def.h> #include <spd.h> -#include "delay.h" +#include "delay.h" #include "gm45.h" void raminit_thermal(const sysinfo_t *sysinfo) diff --git a/src/northbridge/intel/haswell/northbridge.c b/src/northbridge/intel/haswell/northbridge.c index ad4563bb35..2b7afa8172 100644 --- a/src/northbridge/intel/haswell/northbridge.c +++ b/src/northbridge/intel/haswell/northbridge.c @@ -26,9 +26,9 @@ #include <device/pci_ids.h> #include <device/pci_ops.h> #include <stdlib.h> -#include <string.h> #include <cpu/x86/smm.h> #include <boot/tables.h> + #include "chip.h" #include "haswell.h" diff --git a/src/northbridge/intel/i440bx/northbridge.c b/src/northbridge/intel/i440bx/northbridge.c index 2e4c3a15d3..ef6329c172 100644 --- a/src/northbridge/intel/i440bx/northbridge.c +++ b/src/northbridge/intel/i440bx/northbridge.c @@ -18,7 +18,6 @@ #include <device/pci.h> #include <device/pci_ids.h> #include <stdlib.h> -#include <string.h> #include <cpu/cpu.h> #include "northbridge.h" #include "i440bx.h" diff --git a/src/northbridge/intel/i945/acpi.c b/src/northbridge/intel/i945/acpi.c index f817cdf570..3a9f6a2b2f 100644 --- a/src/northbridge/intel/i945/acpi.c +++ b/src/northbridge/intel/i945/acpi.c @@ -15,7 +15,6 @@ */ #include <types.h> -#include <string.h> #include <arch/acpi.h> #include <arch/acpigen.h> #include <device/device.h> diff --git a/src/northbridge/intel/i945/early_init.c b/src/northbridge/intel/i945/early_init.c index e8cacf622f..d3ed27745d 100644 --- a/src/northbridge/intel/i945/early_init.c +++ b/src/northbridge/intel/i945/early_init.c @@ -22,7 +22,6 @@ #include <cbmem.h> #include <halt.h> #include <romstage_handoff.h> -#include <string.h> #include "i945.h" #include <pc80/mc146818rtc.h> #include <southbridge/intel/common/gpio.h> diff --git a/src/northbridge/intel/i945/northbridge.c b/src/northbridge/intel/i945/northbridge.c index ce7d292a27..82392f4e53 100644 --- a/src/northbridge/intel/i945/northbridge.c +++ b/src/northbridge/intel/i945/northbridge.c @@ -21,7 +21,6 @@ #include <device/pci.h> #include <device/pci_ids.h> #include <stdlib.h> -#include <string.h> #include <cpu/cpu.h> #include <arch/acpi.h> #include <cpu/intel/smm/gen1/smi.h> diff --git a/src/northbridge/intel/nehalem/gma.c b/src/northbridge/intel/nehalem/gma.c index 86fc583f88..16f1c35935 100644 --- a/src/northbridge/intel/nehalem/gma.c +++ b/src/northbridge/intel/nehalem/gma.c @@ -21,7 +21,6 @@ #include <device/device.h> #include <device/pci.h> #include <device/pci_ids.h> -#include <string.h> #include <device/pci_ops.h> #include <drivers/intel/gma/edid.h> #include <drivers/intel/gma/i915.h> diff --git a/src/northbridge/intel/nehalem/northbridge.c b/src/northbridge/intel/nehalem/northbridge.c index 8a4f64c809..575c6008fc 100644 --- a/src/northbridge/intel/nehalem/northbridge.c +++ b/src/northbridge/intel/nehalem/northbridge.c @@ -26,7 +26,6 @@ #include <device/pci.h> #include <device/pci_ids.h> #include <stdlib.h> -#include <string.h> #include <cpu/cpu.h> #include "chip.h" #include "nehalem.h" diff --git a/src/northbridge/intel/nehalem/smi.c b/src/northbridge/intel/nehalem/smi.c index 6aefc9b141..5bfc934e04 100644 --- a/src/northbridge/intel/nehalem/smi.c +++ b/src/northbridge/intel/nehalem/smi.c @@ -14,7 +14,6 @@ #define __SIMPLE_DEVICE__ #include <types.h> -#include <string.h> #include <device/device.h> #include <device/pci.h> #include <device/pci_ops.h> diff --git a/src/northbridge/intel/pineview/early_init.c b/src/northbridge/intel/pineview/early_init.c index 4f284747b9..a0d5305255 100644 --- a/src/northbridge/intel/pineview/early_init.c +++ b/src/northbridge/intel/pineview/early_init.c @@ -21,7 +21,6 @@ #include <device/pci_ops.h> #include <device/pci_def.h> #include <device/pci.h> -#include <string.h> #include <northbridge/intel/pineview/pineview.h> #include <northbridge/intel/pineview/chip.h> #include <pc80/mc146818rtc.h> diff --git a/src/northbridge/intel/pineview/gma.c b/src/northbridge/intel/pineview/gma.c index 8bacc77598..d6ece9dc03 100644 --- a/src/northbridge/intel/pineview/gma.c +++ b/src/northbridge/intel/pineview/gma.c @@ -22,7 +22,6 @@ #include <device/device.h> #include <device/pci.h> #include <device/pci_ids.h> -#include <string.h> #include <device/pci_ops.h> #include <drivers/intel/gma/i915_reg.h> diff --git a/src/northbridge/intel/pineview/northbridge.c b/src/northbridge/intel/pineview/northbridge.c index 5ddcd73cea..4b67cfdefd 100644 --- a/src/northbridge/intel/pineview/northbridge.c +++ b/src/northbridge/intel/pineview/northbridge.c @@ -21,7 +21,6 @@ #include <device/device.h> #include <device/pci.h> #include <stdlib.h> -#include <string.h> #include <cpu/cpu.h> #include <boot/tables.h> #include <arch/acpi.h> diff --git a/src/northbridge/intel/sandybridge/gma.c b/src/northbridge/intel/sandybridge/gma.c index d302c52c35..7f7ea0c10f 100644 --- a/src/northbridge/intel/sandybridge/gma.c +++ b/src/northbridge/intel/sandybridge/gma.c @@ -18,7 +18,6 @@ #include <console/console.h> #include <bootmode.h> #include <delay.h> -#include <string.h> #include <device/device.h> #include <device/pci.h> #include <device/pci_ids.h> diff --git a/src/northbridge/intel/sandybridge/northbridge.c b/src/northbridge/intel/sandybridge/northbridge.c index e58a0ebc3a..477c26ec4e 100644 --- a/src/northbridge/intel/sandybridge/northbridge.c +++ b/src/northbridge/intel/sandybridge/northbridge.c @@ -25,7 +25,6 @@ #include <device/pci.h> #include <device/pci_ids.h> #include <stdlib.h> -#include <string.h> #include <cpu/cpu.h> #include "chip.h" #include "sandybridge.h" diff --git a/src/northbridge/intel/sandybridge/romstage.c b/src/northbridge/intel/sandybridge/romstage.c index d48bac4a0f..b49165cb3f 100644 --- a/src/northbridge/intel/sandybridge/romstage.c +++ b/src/northbridge/intel/sandybridge/romstage.c @@ -16,7 +16,6 @@ */ #include <stdint.h> -#include <string.h> #include <console/console.h> #include <arch/io.h> #include <device/pci_ops.h> diff --git a/src/northbridge/intel/x4x/acpi.c b/src/northbridge/intel/x4x/acpi.c index da9ed40687..fb04fd8582 100644 --- a/src/northbridge/intel/x4x/acpi.c +++ b/src/northbridge/intel/x4x/acpi.c @@ -16,7 +16,6 @@ */ #include <types.h> -#include <string.h> #include <console/console.h> #include <arch/acpi.h> #include <arch/acpigen.h> diff --git a/src/northbridge/intel/x4x/gma.c b/src/northbridge/intel/x4x/gma.c index 8de568a0ea..2c045e6fd1 100644 --- a/src/northbridge/intel/x4x/gma.c +++ b/src/northbridge/intel/x4x/gma.c @@ -20,7 +20,6 @@ #include <device/device.h> #include <device/pci.h> #include <device/pci_ids.h> -#include <string.h> #include <device/pci_ops.h> #include <commonlib/helpers.h> #include <cbmem.h> diff --git a/src/northbridge/intel/x4x/northbridge.c b/src/northbridge/intel/x4x/northbridge.c index ba51430b20..b6616e1dd8 100644 --- a/src/northbridge/intel/x4x/northbridge.c +++ b/src/northbridge/intel/x4x/northbridge.c @@ -21,7 +21,6 @@ #include <device/device.h> #include <device/pci.h> #include <stdlib.h> -#include <string.h> #include <cpu/cpu.h> #include <boot/tables.h> #include <arch/acpi.h> |