aboutsummaryrefslogtreecommitdiff
path: root/src/mainboard/amd/serengeti_cheetah_fam10/get_bus_conf.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/mainboard/amd/serengeti_cheetah_fam10/get_bus_conf.c')
-rw-r--r--src/mainboard/amd/serengeti_cheetah_fam10/get_bus_conf.c28
1 files changed, 15 insertions, 13 deletions
diff --git a/src/mainboard/amd/serengeti_cheetah_fam10/get_bus_conf.c b/src/mainboard/amd/serengeti_cheetah_fam10/get_bus_conf.c
index 87ca67274f..fda2626a74 100644
--- a/src/mainboard/amd/serengeti_cheetah_fam10/get_bus_conf.c
+++ b/src/mainboard/amd/serengeti_cheetah_fam10/get_bus_conf.c
@@ -29,8 +29,9 @@
struct mb_sysconf_t mb_sysconf;
/* Here you only need to set value in pci1234 for HT-IO that could be
-installed or not You may need to preset pci1234 for HTIO board, please
-refer to src/northbridge/amd/amdfam10/get_sblk_pci1234.c for detail */
+ * installed or not You may need to preset pci1234 for HTIO board, please
+ * refer to src/northbridge/amd/amdfam10/get_sblk_pci1234.c for detail
+ */
static u32 pci1234x[] = {
0x0000ffc, 0x0000ffc, 0x0000ffc, 0x0000ffc, 0x0000ffc, 0x0000ffc,
0x0000ffc, 0x0000ffc, 0x0000ffc, 0x0000ffc, 0x0000ffc, 0x0000ffc,
@@ -42,7 +43,8 @@ static u32 pci1234x[] = {
/* HT Chain device num, actually it is unit id base of every ht device
-in chain, assume every chain only have 4 ht device at most */
+ * in chain, assume every chain only have 4 ht device at most
+ */
static unsigned hcdnx[] = {
0x20202020, 0x20202020, 0x20202020, 0x20202020, 0x20202020,
@@ -70,18 +72,18 @@ static u32 get_hcid(u32 i)
dev = dev_find_slot(busn, PCI_DEVFN(devn,0));
switch (dev->device) {
- case 0x7458: //8132
+ case 0x7458: /* 8132 */
id = 1;
break;
- case 0x7454: //8151
+ case 0x7454: /* 8151 */
id = 2;
break;
- case 0x7450: //8131
+ case 0x7450: /* 8131 */
id = 3;
break;
}
- // we may need more way to find out hcid: subsystem id? GPIO read ?
- // we need use id for 1. bus num, 2. mptable, 3. ACPI table
+ /* we may need more way to find out hcid: subsystem id? GPIO read ? */
+ /* we need use id for 1. bus num, 2. mptable, 3. ACPI table */
return id;
}
@@ -94,7 +96,7 @@ void get_bus_conf(void)
struct mb_sysconf_t *m;
if(get_bus_conf_done == 1)
- return; //do it only once
+ return; /* do it only once */
get_bus_conf_done = 1;
@@ -145,13 +147,13 @@ void get_bus_conf(void)
for(i = 1; i< sysconf.hc_possible_num; i++) {
if(!(sysconf.pci1234[i] & 0x1) ) continue;
- // check hcid type here
+ /* check hcid type here */
sysconf.hcid[i] = get_hcid(i);
switch(sysconf.hcid[i]) {
- case 1: //8132
- case 3: //8131
+ case 1: /* 8132 */
+ case 3: /* 8131 */
m->bus_8132a[j][0] = (sysconf.pci1234[i] >> 12) & 0xff;
@@ -175,7 +177,7 @@ void get_bus_conf(void)
break;
- case 2: //8151
+ case 2: /* 8151 */
m->bus_8151[j][0] = (sysconf.pci1234[i] >> 12) & 0xff;
m->sbdn5[j] = sysconf.hcdn[i] & 0xff;