summaryrefslogtreecommitdiff
path: root/src/mainboard/tyan/s8226
diff options
context:
space:
mode:
Diffstat (limited to 'src/mainboard/tyan/s8226')
-rw-r--r--src/mainboard/tyan/s8226/get_bus_conf.c4
-rw-r--r--src/mainboard/tyan/s8226/irq_tables.c8
-rw-r--r--src/mainboard/tyan/s8226/mptable.c4
3 files changed, 5 insertions, 11 deletions
diff --git a/src/mainboard/tyan/s8226/get_bus_conf.c b/src/mainboard/tyan/s8226/get_bus_conf.c
index 7a6876b880..087c04206a 100644
--- a/src/mainboard/tyan/s8226/get_bus_conf.c
+++ b/src/mainboard/tyan/s8226/get_bus_conf.c
@@ -30,7 +30,6 @@
* and acpi_tables busnum is default.
*/
u8 bus_sp5100[2];
-u32 sbdn_sp5100;
void get_bus_conf(void);
@@ -39,7 +38,6 @@ void get_bus_conf(void)
device_t dev;
int i;
- sbdn_sp5100 = 0;
for (i = 0; i < 0; i++) {
bus_sp5100[i] = 0;
@@ -48,7 +46,7 @@ void get_bus_conf(void)
bus_sp5100[0] = 0;
/* sp5100 */
- dev = dev_find_slot(bus_sp5100[0], PCI_DEVFN(sbdn_sp5100 + 0x14, 4));
+ dev = dev_find_slot(0, PCI_DEVFN(0x14, 4));
if (dev) {
bus_sp5100[1] = pci_read_config8(dev, PCI_SECONDARY_BUS);
diff --git a/src/mainboard/tyan/s8226/irq_tables.c b/src/mainboard/tyan/s8226/irq_tables.c
index 6b1e226007..0af225c9dd 100644
--- a/src/mainboard/tyan/s8226/irq_tables.c
+++ b/src/mainboard/tyan/s8226/irq_tables.c
@@ -44,8 +44,6 @@ static void write_pirq_info(struct irq_info *pirq_info, u8 bus, u8 devfn,
pirq_info->slot = slot;
pirq_info->rfu = rfu;
}
-extern u8 bus_sp5100[2];
-extern unsigned long sbdn_sp5100;
unsigned long write_pirq_routing_table(unsigned long addr)
{
@@ -71,8 +69,8 @@ unsigned long write_pirq_routing_table(unsigned long addr)
pirq->signature = PIRQ_SIGNATURE;
pirq->version = PIRQ_VERSION;
- pirq->rtr_bus = bus_sp5100[0];
- pirq->rtr_devfn = ((sbdn_sp5100 + 0x14) << 3) | 4;
+ pirq->rtr_bus = 0;
+ pirq->rtr_devfn = PCI_DEVFN(0x14, 4);
pirq->exclusive_irqs = 0;
@@ -88,7 +86,7 @@ unsigned long write_pirq_routing_table(unsigned long addr)
/* pci bridge */
- write_pirq_info(pirq_info, bus_sp5100[0], ((sbdn_sp5100 + 0x14) << 3) | 4,
+ write_pirq_info(pirq_info, 0, PCI_DEVFN(0x14, 4),
0x1, 0xdef8, 0x2, 0xdef8, 0x3, 0xdef8, 0x4, 0xdef8, 0,
0);
pirq_info++;
diff --git a/src/mainboard/tyan/s8226/mptable.c b/src/mainboard/tyan/s8226/mptable.c
index 6a12f2b821..3793212711 100644
--- a/src/mainboard/tyan/s8226/mptable.c
+++ b/src/mainboard/tyan/s8226/mptable.c
@@ -29,8 +29,6 @@
#include <cpu/amd/amdfam10_sysconf.h>
extern u8 bus_sp5100[2];
-extern u32 sbdn_sr5650;
-extern u32 sbdn_sp5100;
static void *smp_write_config_table(void *v)
{
@@ -60,7 +58,7 @@ static void *smp_write_config_table(void *v)
apicid_sp5100 = CONFIG_MAX_CPUS + 1;
apicid_sr5650 = apicid_sp5100 + 1;
- dev = dev_find_slot(0, PCI_DEVFN(sbdn_sp5100 + 0x14, 0));
+ dev = dev_find_slot(0, PCI_DEVFN(0x14, 0));
if (dev) {
/* Set SP5100 IOAPIC ID */
dword = pci_read_config32(dev, 0x74) & 0xfffffff0;