diff options
author | Timothy Pearson <tpearson@raptorengineeringinc.com> | 2015-10-27 16:48:36 -0500 |
---|---|---|
committer | Patrick Georgi <pgeorgi@google.com> | 2015-10-29 15:38:12 +0100 |
commit | d4bbfe863b8d7f0018e1b1a35034f783293926ea (patch) | |
tree | 5879636080f8e42f069c42c49f3ff2ae5bbddc09 /src/mainboard/supermicro | |
parent | ce2564ac519fd974eeaa070ccb30d5a12e0c3334 (diff) | |
download | coreboot-d4bbfe863b8d7f0018e1b1a35034f783293926ea.tar.xz |
mainboard: Convert #ifdef to IS_ENABLED in get_bus_conf.c
Change-Id: I254e9e9e65519edcf4d3f1ecc385af16d18c2367
Signed-off-by: Timothy Pearson <tpearson@raptorengineeringinc.com>
Reviewed-on: http://review.coreboot.org/12208
Tested-by: build bot (Jenkins)
Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net>
Reviewed-by: Martin Roth <martinroth@google.com>
Reviewed-by: Patrick Georgi <pgeorgi@google.com>
Diffstat (limited to 'src/mainboard/supermicro')
-rw-r--r-- | src/mainboard/supermicro/h8dme/get_bus_conf.c | 11 | ||||
-rw-r--r-- | src/mainboard/supermicro/h8dmr/get_bus_conf.c | 11 | ||||
-rw-r--r-- | src/mainboard/supermicro/h8dmr_fam10/get_bus_conf.c | 11 | ||||
-rw-r--r-- | src/mainboard/supermicro/h8qme_fam10/get_bus_conf.c | 11 | ||||
-rw-r--r-- | src/mainboard/supermicro/h8scm_fam10/get_bus_conf.c | 11 |
5 files changed, 20 insertions, 35 deletions
diff --git a/src/mainboard/supermicro/h8dme/get_bus_conf.c b/src/mainboard/supermicro/h8dme/get_bus_conf.c index c000000791..4e57f06974 100644 --- a/src/mainboard/supermicro/h8dme/get_bus_conf.c +++ b/src/mainboard/supermicro/h8dme/get_bus_conf.c @@ -24,9 +24,7 @@ #include <device/pci_ids.h> #include <string.h> #include <stdint.h> -#if CONFIG_LOGICAL_CPUS #include <cpu/amd/multicore.h> -#endif #include <cpu/amd/amdk8_sysconf.h> #include <stdlib.h> @@ -142,11 +140,10 @@ void get_bus_conf(void) } /*I/O APICs: APIC ID Version State Address*/ -#if CONFIG_LOGICAL_CPUS - apicid_base = get_apicid_base(1); -#else - apicid_base = CONFIG_MAX_PHYSICAL_CPUS; -#endif + if (IS_ENABLED(CONFIG_LOGICAL_CPUS)) + apicid_base = get_apicid_base(1); + else + apicid_base = CONFIG_MAX_PHYSICAL_CPUS; apicid_mcp55 = apicid_base + 0; } diff --git a/src/mainboard/supermicro/h8dmr/get_bus_conf.c b/src/mainboard/supermicro/h8dmr/get_bus_conf.c index c000000791..4e57f06974 100644 --- a/src/mainboard/supermicro/h8dmr/get_bus_conf.c +++ b/src/mainboard/supermicro/h8dmr/get_bus_conf.c @@ -24,9 +24,7 @@ #include <device/pci_ids.h> #include <string.h> #include <stdint.h> -#if CONFIG_LOGICAL_CPUS #include <cpu/amd/multicore.h> -#endif #include <cpu/amd/amdk8_sysconf.h> #include <stdlib.h> @@ -142,11 +140,10 @@ void get_bus_conf(void) } /*I/O APICs: APIC ID Version State Address*/ -#if CONFIG_LOGICAL_CPUS - apicid_base = get_apicid_base(1); -#else - apicid_base = CONFIG_MAX_PHYSICAL_CPUS; -#endif + if (IS_ENABLED(CONFIG_LOGICAL_CPUS)) + apicid_base = get_apicid_base(1); + else + apicid_base = CONFIG_MAX_PHYSICAL_CPUS; apicid_mcp55 = apicid_base + 0; } diff --git a/src/mainboard/supermicro/h8dmr_fam10/get_bus_conf.c b/src/mainboard/supermicro/h8dmr_fam10/get_bus_conf.c index 6b1d1b8115..48b0a0a3e4 100644 --- a/src/mainboard/supermicro/h8dmr_fam10/get_bus_conf.c +++ b/src/mainboard/supermicro/h8dmr_fam10/get_bus_conf.c @@ -24,9 +24,7 @@ #include <device/pci_ids.h> #include <string.h> #include <stdint.h> -#if CONFIG_LOGICAL_CPUS #include <cpu/amd/multicore.h> -#endif #include <cpu/amd/amdfam10_sysconf.h> @@ -115,11 +113,10 @@ void get_bus_conf(void) } /*I/O APICs: APIC ID Version State Address*/ -#if CONFIG_LOGICAL_CPUS - apicid_base = get_apicid_base(1); -#else - apicid_base = CONFIG_MAX_PHYSICAL_CPUS; -#endif + if (IS_ENABLED(CONFIG_LOGICAL_CPUS)) + apicid_base = get_apicid_base(1); + else + apicid_base = CONFIG_MAX_PHYSICAL_CPUS; m->apicid_mcp55 = apicid_base+0; } diff --git a/src/mainboard/supermicro/h8qme_fam10/get_bus_conf.c b/src/mainboard/supermicro/h8qme_fam10/get_bus_conf.c index bcdd0fd6dd..7e9d4b86da 100644 --- a/src/mainboard/supermicro/h8qme_fam10/get_bus_conf.c +++ b/src/mainboard/supermicro/h8qme_fam10/get_bus_conf.c @@ -24,9 +24,7 @@ #include <device/pci_ids.h> #include <string.h> #include <stdint.h> -#if CONFIG_LOGICAL_CPUS #include <cpu/amd/multicore.h> -#endif #include <cpu/amd/amdfam10_sysconf.h> @@ -132,11 +130,10 @@ void get_bus_conf(void) m->bus_8132_2 = pci_read_config8(dev, PCI_SECONDARY_BUS); /*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_mcp55 = apicid_base+0; m->apicid_8132_1 = apicid_base+1; m->apicid_8132_2 = apicid_base+2; diff --git a/src/mainboard/supermicro/h8scm_fam10/get_bus_conf.c b/src/mainboard/supermicro/h8scm_fam10/get_bus_conf.c index 8e1a8ab444..ae119421ad 100644 --- a/src/mainboard/supermicro/h8scm_fam10/get_bus_conf.c +++ b/src/mainboard/supermicro/h8scm_fam10/get_bus_conf.c @@ -23,9 +23,7 @@ #include <string.h> #include <stdint.h> #include <stdlib.h> -#if CONFIG_LOGICAL_CPUS #include <cpu/amd/multicore.h> -#endif #include <cpu/amd/amdfam10_sysconf.h> @@ -118,10 +116,9 @@ void get_bus_conf(void) /* I/O APICs: APIC ID Version State Address */ bus_isa = 10; -#if CONFIG_LOGICAL_CPUS - apicid_base = get_apicid_base(1); -#else - apicid_base = CONFIG_MAX_PHYSICAL_CPUS; -#endif + if (IS_ENABLED(CONFIG_LOGICAL_CPUS)) + apicid_base = get_apicid_base(1); + else + apicid_base = CONFIG_MAX_PHYSICAL_CPUS; apicid_sp5100 = apicid_base + 0; } |