summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorDenis 'GNUtoo' Carikli <GNUtoo@no-log.org>2016-02-20 17:32:03 +0100
committerStefan Reinauer <stefan.reinauer@coreboot.org>2016-02-26 07:01:21 +0100
commit0e92bb010f8bd45b2543f2553a4d3c2f35dffc09 (patch)
treef4cf3e8be983087518a1261f5a4c24b40de61da1 /src
parentbfe07899e372ac41c0a6dd4efac25458f5d48c9c (diff)
downloadcoreboot-0e92bb010f8bd45b2543f2553a4d3c2f35dffc09.tar.xz
tree wide: Convert "if (CONFIG_.*_TPM.*)" to "if (IS_ENABLED(...))"
Change-Id: Ib73abb0ada7dfdfab3487c005719e19f51ef1812 Signed-off-by: Denis 'GNUtoo' Carikli <GNUtoo@no-log.org> Reviewed-on: https://review.coreboot.org/13779 Tested-by: build bot (Jenkins) Reviewed-by: Patrick Georgi <pgeorgi@google.com>
Diffstat (limited to 'src')
-rw-r--r--src/cpu/intel/haswell/romstage.c2
-rw-r--r--src/drivers/pc80/tpm/romstage.c4
-rw-r--r--src/drivers/pc80/tpm/tpm.c2
-rw-r--r--src/northbridge/intel/sandybridge/romstage.c2
-rw-r--r--src/soc/intel/baytrail/romstage/romstage.c2
5 files changed, 6 insertions, 6 deletions
diff --git a/src/cpu/intel/haswell/romstage.c b/src/cpu/intel/haswell/romstage.c
index 6da7fd932e..9932a508e5 100644
--- a/src/cpu/intel/haswell/romstage.c
+++ b/src/cpu/intel/haswell/romstage.c
@@ -267,7 +267,7 @@ void romstage_common(const struct romstage_params *params)
printk(BIOS_DEBUG, "Romstage handoff structure not added!\n");
post_code(0x3f);
- if (CONFIG_LPC_TPM) {
+ if (IS_ENABLED(CONFIG_LPC_TPM)) {
init_tpm(wake_from_s3);
}
}
diff --git a/src/drivers/pc80/tpm/romstage.c b/src/drivers/pc80/tpm/romstage.c
index b8b9b36c5c..a257ba1610 100644
--- a/src/drivers/pc80/tpm/romstage.c
+++ b/src/drivers/pc80/tpm/romstage.c
@@ -183,7 +183,7 @@ void init_tpm(int s3resume)
u32 result;
u8 response[TPM_LARGE_ENOUGH_COMMAND_SIZE];
- if (CONFIG_TPM_DEACTIVATE) {
+ if (IS_ENABLED(CONFIG_TPM_DEACTIVATE)) {
printk(BIOS_SPEW, "TPM: Deactivate\n");
result = TlclSendReceive(tpm_deactivate_cmd.buffer,
response, sizeof(response));
@@ -241,7 +241,7 @@ void init_tpm(int s3resume)
printk(BIOS_ERR, "TPM: Error code 0x%x.\n", result);
- if (CONFIG_TPM_INIT_FAILURE_IS_FATAL) {
+ if (IS_ENABLED(CONFIG_TPM_INIT_FAILURE_IS_FATAL)) {
printk(BIOS_ERR, "Hard reset!\n");
post_code(POST_TPM_FAILURE);
if (IS_ENABLED(CONFIG_CONSOLE_CBMEM_DUMP_TO_UART))
diff --git a/src/drivers/pc80/tpm/tpm.c b/src/drivers/pc80/tpm/tpm.c
index 064cb994fb..fa46b476f5 100644
--- a/src/drivers/pc80/tpm/tpm.c
+++ b/src/drivers/pc80/tpm/tpm.c
@@ -37,7 +37,7 @@
/* coreboot wrapper for TPM driver (start) */
#define TPM_DEBUG(fmt, args...) \
- if (CONFIG_DEBUG_TPM) { \
+ if (IS_ENABLED(CONFIG_DEBUG_TPM)) { \
printk(BIOS_DEBUG, PREFIX); \
printk(BIOS_DEBUG, fmt , ##args); \
}
diff --git a/src/northbridge/intel/sandybridge/romstage.c b/src/northbridge/intel/sandybridge/romstage.c
index d6135bd8ac..df0c5bbba5 100644
--- a/src/northbridge/intel/sandybridge/romstage.c
+++ b/src/northbridge/intel/sandybridge/romstage.c
@@ -113,7 +113,7 @@ void main(unsigned long bist)
northbridge_romstage_finalize(s3resume);
- if (CONFIG_LPC_TPM) {
+ if (IS_ENABLED(CONFIG_LPC_TPM)) {
init_tpm(s3resume);
}
diff --git a/src/soc/intel/baytrail/romstage/romstage.c b/src/soc/intel/baytrail/romstage/romstage.c
index 60146b5042..36682352cb 100644
--- a/src/soc/intel/baytrail/romstage/romstage.c
+++ b/src/soc/intel/baytrail/romstage/romstage.c
@@ -239,7 +239,7 @@ void romstage_common(struct romstage_params *params)
else
printk(BIOS_DEBUG, "Romstage handoff structure not added!\n");
- if (CONFIG_LPC_TPM) {
+ if (IS_ENABLED(CONFIG_LPC_TPM)) {
init_tpm(prev_sleep_state == 3);
}
}