diff options
author | Jan Samek <jan.samek@siemens.com> | 2023-04-27 10:39:27 +0200 |
---|---|---|
committer | Felix Held <felix-coreboot@felixheld.de> | 2023-04-28 13:38:33 +0000 |
commit | edda0f94e58a510f6e13bf632c6dc7294840ac43 (patch) | |
tree | ee053ebe935070bd8ccb068ca031cd3fa6f0129f /src/drivers/generic | |
parent | 8ba2ecf2b40b9bffc20ccad0c76ba2eefcfd1396 (diff) |
treewide: Add missing include guards to chip.h
Some of the chip.h files in the tree are missing the include guards.
This patch adds them in order to avoid potential redefinions of symbols
contained in these headers, when they are included multiple times in
static.c generated by sconfig.
Change-Id: I550a514e72a8dd4db602e7ceffccd81aa36446e3
Signed-off-by: Jan Samek <jan.samek@siemens.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/74749
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Felix Held <felix-coreboot@felixheld.de>
Diffstat (limited to 'src/drivers/generic')
-rw-r--r-- | src/drivers/generic/alc1015/chip.h | 5 | ||||
-rw-r--r-- | src/drivers/generic/bayhub/chip.h | 5 | ||||
-rw-r--r-- | src/drivers/generic/bayhub_lv2/chip.h | 5 | ||||
-rw-r--r-- | src/drivers/generic/max98357a/chip.h | 5 | ||||
-rw-r--r-- | src/drivers/generic/nau8315/chip.h | 5 |
5 files changed, 25 insertions, 0 deletions
diff --git a/src/drivers/generic/alc1015/chip.h b/src/drivers/generic/alc1015/chip.h index fa841772ed..16b0d22cd8 100644 --- a/src/drivers/generic/alc1015/chip.h +++ b/src/drivers/generic/alc1015/chip.h @@ -1,8 +1,13 @@ /* SPDX-License-Identifier: GPL-2.0-only */ +#ifndef __DRIVERS_GENERIC_ALC1015_CHIP_H__ +#define __DRIVERS_GENERIC_ALC1015_CHIP_H__ + #include <acpi/acpi_device.h> struct drivers_generic_alc1015_config { const char *hid; /* ACPI _HID */ struct acpi_gpio sdb; /* SDMODE GPIO */ }; + +#endif /* __DRIVERS_GENERIC_ALC1015_CHIP_H__ */ diff --git a/src/drivers/generic/bayhub/chip.h b/src/drivers/generic/bayhub/chip.h index 77b7512143..82fe67085b 100644 --- a/src/drivers/generic/bayhub/chip.h +++ b/src/drivers/generic/bayhub/chip.h @@ -1,5 +1,8 @@ /* SPDX-License-Identifier: GPL-2.0-only */ +#ifndef __DRIVERS_GENERIC_BAYHUB_CHIP_H__ +#define __DRIVERS_GENERIC_BAYHUB_CHIP_H__ + #include <acpi/acpi_device.h> /* @@ -15,3 +18,5 @@ struct drivers_generic_bayhub_config { /* CLK and DAT tuning values */ uint8_t vih_tuning_value; }; + +#endif /* __DRIVERS_GENERIC_BAYHUB_CHIP_H__ */ diff --git a/src/drivers/generic/bayhub_lv2/chip.h b/src/drivers/generic/bayhub_lv2/chip.h index aa8f3fd879..ea5c55fc7f 100644 --- a/src/drivers/generic/bayhub_lv2/chip.h +++ b/src/drivers/generic/bayhub_lv2/chip.h @@ -1,8 +1,13 @@ /* SPDX-License-Identifier: GPL-2.0-only */ +#ifndef __DRIVERS_GENERIC_BAYHUB_LV2_CHIP_H__ +#define __DRIVERS_GENERIC_BAYHUB_LV2_CHIP_H__ + #include <stdbool.h> /* Bayhub LV2 PCIe to SD bridge */ struct drivers_generic_bayhub_lv2_config { bool enable_power_saving; }; + +#endif /* __DRIVERS_GENERIC_BAYHUB_LV2_CHIP_H__ */ diff --git a/src/drivers/generic/max98357a/chip.h b/src/drivers/generic/max98357a/chip.h index 66ebecfc5f..3916b80f86 100644 --- a/src/drivers/generic/max98357a/chip.h +++ b/src/drivers/generic/max98357a/chip.h @@ -1,5 +1,8 @@ /* SPDX-License-Identifier: GPL-2.0-only */ +#ifndef __DRIVERS_GENERIC_MAX98357A_CHIP_H__ +#define __DRIVERS_GENERIC_MAX98357A_CHIP_H__ + #include <acpi/acpi_device.h> struct drivers_generic_max98357a_config { @@ -16,3 +19,5 @@ struct drivers_generic_max98357a_config { unsigned int device_present_gpio; unsigned int device_present_gpio_invert; }; + +#endif /* __DRIVERS_GENERIC_MAX98357A_CHIP_H__ */ diff --git a/src/drivers/generic/nau8315/chip.h b/src/drivers/generic/nau8315/chip.h index 45cb412d48..550f11ed1e 100644 --- a/src/drivers/generic/nau8315/chip.h +++ b/src/drivers/generic/nau8315/chip.h @@ -1,5 +1,8 @@ /* SPDX-License-Identifier: GPL-2.0-only */ +#ifndef __DRIVERS_GENERIC_NAU8315_CHIP_H__ +#define __DRIVERS_GENERIC_NAU8315_CHIP_H__ + #include <acpi/acpi_device.h> struct drivers_generic_nau8315_config { @@ -12,3 +15,5 @@ struct drivers_generic_nau8315_config { /* ENABLE GPIO */ struct acpi_gpio enable_gpio; }; + +#endif /* __DRIVERS_GENERIC_NAU8315_CHIP_H__ */ |