diff options
author | Elyes HAOUAS <ehaouas@noos.fr> | 2018-02-01 09:11:43 +0100 |
---|---|---|
committer | Felix Held <felix-coreboot@felixheld.de> | 2018-05-01 16:55:36 +0000 |
commit | 66f1bd208550e5c35f27679d8d8c48f50c6958e7 (patch) | |
tree | 5f077b49bee44c5ce90077265784c12bf98d73ab /src/mainboard/hp/dl145_g3 | |
parent | cc1e3b64ed3621b06f853166bc767cc2625651d4 (diff) |
mainboard/hp/dl145_g3: Fix coding style
Change-Id: I78b43cbc052e6d243d67ca8cdd86b242e477a2c7
Signed-off-by: Elyes HAOUAS <ehaouas@noos.fr>
Reviewed-on: https://review.coreboot.org/23532
Reviewed-by: Felix Held <felix-coreboot@felixheld.de>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Diffstat (limited to 'src/mainboard/hp/dl145_g3')
-rw-r--r-- | src/mainboard/hp/dl145_g3/get_bus_conf.c | 18 | ||||
-rw-r--r-- | src/mainboard/hp/dl145_g3/mptable.c | 2 |
2 files changed, 9 insertions, 11 deletions
diff --git a/src/mainboard/hp/dl145_g3/get_bus_conf.c b/src/mainboard/hp/dl145_g3/get_bus_conf.c index d69e224cd8..15a74669d3 100644 --- a/src/mainboard/hp/dl145_g3/get_bus_conf.c +++ b/src/mainboard/hp/dl145_g3/get_bus_conf.c @@ -68,7 +68,8 @@ void get_bus_conf(void) int i; struct mb_sysconf_t *m; - if(get_bus_conf_done == 1) return; //do it only once + if (get_bus_conf_done == 1) + return; //do it only once get_bus_conf_done = 1; @@ -78,7 +79,7 @@ void get_bus_conf(void) sysconf.hc_possible_num = ARRAY_SIZE(pci1234x); - for(i = 0; i < sysconf.hc_possible_num; i++) { + for (i = 0; i < sysconf.hc_possible_num; i++) { sysconf.pci1234[i] = pci1234x[i]; sysconf.hcdn[i] = hcdnx[i]; } @@ -100,23 +101,20 @@ void get_bus_conf(void) printk(BIOS_DEBUG, "secondary is %d...\n",m->bus_bcm5785_1); dev = dev_find_slot(m->bus_bcm5785_1, PCI_DEVFN(0xd,0)); printk(BIOS_DEBUG, "now found %s...\n",dev_path(dev)); - if(dev) { + if (dev) m->bus_bcm5785_1_1 = pci_read_config8(dev, PCI_SECONDARY_BUS); - } } else { printk(BIOS_DEBUG, "ERROR - could not find PCI %02x:%02x.0, using defaults\n", m->bus_bcm5785_0, sysconf.sbdn); } /* bcm5780 */ - for(i = 1; i < 6; i++) { + for (i = 1; i < 6; i++) { dev = dev_find_slot(m->bus_bcm5780[0], PCI_DEVFN(m->sbdn2 + i - 1,0)); - if(dev) { + if (dev) m->bus_bcm5780[i] = pci_read_config8(dev, PCI_SECONDARY_BUS); - } - else { + else printk(BIOS_DEBUG, "ERROR - could not find PCI %02x:%02x.0, using defaults\n", m->bus_bcm5780[0], m->sbdn2+i-1); - } } @@ -125,6 +123,6 @@ void get_bus_conf(void) apicid_base = get_apicid_base(3); else apicid_base = CONFIG_MAX_PHYSICAL_CPUS; - for(i = 0; i < 3; i++) + for (i = 0; i < 3; i++) m->apicid_bcm5785[i] = apicid_base+i; } diff --git a/src/mainboard/hp/dl145_g3/mptable.c b/src/mainboard/hp/dl145_g3/mptable.c index 86affe8a8c..4e33f9b3d8 100644 --- a/src/mainboard/hp/dl145_g3/mptable.c +++ b/src/mainboard/hp/dl145_g3/mptable.c @@ -57,7 +57,7 @@ static void *smp_write_config_table(void *v) device_t dev = 0; int i; struct resource *res; - for(i = 0; i < 3; i++) { + for (i = 0; i < 3; i++) { dev = dev_find_device(0x1166, 0x0235, dev); if (dev) { res = find_resource(dev, PCI_BASE_ADDRESS_0); |