From d4bbfe863b8d7f0018e1b1a35034f783293926ea Mon Sep 17 00:00:00 2001 From: Timothy Pearson Date: Tue, 27 Oct 2015 16:48:36 -0500 Subject: mainboard: Convert #ifdef to IS_ENABLED in get_bus_conf.c Change-Id: I254e9e9e65519edcf4d3f1ecc385af16d18c2367 Signed-off-by: Timothy Pearson Reviewed-on: http://review.coreboot.org/12208 Tested-by: build bot (Jenkins) Reviewed-by: Paul Menzel Reviewed-by: Martin Roth Reviewed-by: Patrick Georgi --- src/mainboard/hp/dl145_g1/get_bus_conf.c | 11 ++++------- src/mainboard/hp/dl145_g3/get_bus_conf.c | 11 ++++------- src/mainboard/hp/dl165_g6_fam10/get_bus_conf.c | 2 -- 3 files changed, 8 insertions(+), 16 deletions(-) (limited to 'src/mainboard/hp') diff --git a/src/mainboard/hp/dl145_g1/get_bus_conf.c b/src/mainboard/hp/dl145_g1/get_bus_conf.c index acfa02320d..9c35814f03 100644 --- a/src/mainboard/hp/dl145_g1/get_bus_conf.c +++ b/src/mainboard/hp/dl145_g1/get_bus_conf.c @@ -7,9 +7,7 @@ #include #include #include -#if CONFIG_LOGICAL_CPUS #include -#endif #include #include @@ -104,11 +102,10 @@ void get_bus_conf(void) /*I/O APICs: APIC ID Version State Address*/ -#if CONFIG_LOGICAL_CPUS - apicid_base = get_apicid_base(3); -#else - apicid_base = CONFIG_MAX_PHYSICAL_CPUS; -#endif + if (IS_ENABLED(CONFIG_LOGICAL_CPUS)) + apicid_base = get_apicid_base(3); + else + apicid_base = CONFIG_MAX_PHYSICAL_CPUS; m->apicid_8111 = apicid_base+0; m->apicid_8131_1 = apicid_base+1; m->apicid_8131_2 = apicid_base+2; diff --git a/src/mainboard/hp/dl145_g3/get_bus_conf.c b/src/mainboard/hp/dl145_g3/get_bus_conf.c index 944d3287a8..f22bd74a73 100644 --- a/src/mainboard/hp/dl145_g3/get_bus_conf.c +++ b/src/mainboard/hp/dl145_g3/get_bus_conf.c @@ -26,9 +26,7 @@ #include #include #include -#if CONFIG_LOGICAL_CPUS #include -#endif #include @@ -127,11 +125,10 @@ void get_bus_conf(void) /*I/O APICs: APIC ID Version State Address*/ -#if CONFIG_LOGICAL_CPUS - apicid_base = get_apicid_base(3); -#else - apicid_base = CONFIG_MAX_PHYSICAL_CPUS; -#endif + if (IS_ENABLED(CONFIG_LOGICAL_CPUS)) + apicid_base = get_apicid_base(3); + else + apicid_base = CONFIG_MAX_PHYSICAL_CPUS; for(i=0;i<3;i++) m->apicid_bcm5785[i] = apicid_base+i; } diff --git a/src/mainboard/hp/dl165_g6_fam10/get_bus_conf.c b/src/mainboard/hp/dl165_g6_fam10/get_bus_conf.c index 395c612e6c..2f3c1ac043 100644 --- a/src/mainboard/hp/dl165_g6_fam10/get_bus_conf.c +++ b/src/mainboard/hp/dl165_g6_fam10/get_bus_conf.c @@ -24,9 +24,7 @@ #include #include #include -#if CONFIG_LOGICAL_CPUS #include -#endif #include -- cgit v1.2.3