X-Git-Url: http://wien.tomnetworks.com/gitweb/?a=blobdiff_plain;f=src%2Fmainboard%2Fgigabyte%2Fga_2761gxdk%2Fmptable.c;h=914b25a9a7427dbd0246aafec3c806e14082f161;hb=c8feeddf343e8fd0ddd6be7e42101ab4f1866ed0;hp=b6356f055b5b59764cac2bb2673305f99c124e38;hpb=b907d321a5d0957f5cbb03d8f9c8d0ff0c23523b;p=coreboot.git diff --git a/src/mainboard/gigabyte/ga_2761gxdk/mptable.c b/src/mainboard/gigabyte/ga_2761gxdk/mptable.c index b6356f055..914b25a9a 100644 --- a/src/mainboard/gigabyte/ga_2761gxdk/mptable.c +++ b/src/mainboard/gigabyte/ga_2761gxdk/mptable.c @@ -28,35 +28,26 @@ #include #include -extern unsigned char bus_isa; extern unsigned char bus_sis966[8]; //1 extern unsigned apicid_sis966; -extern unsigned bus_type[256]; - static void *smp_write_config_table(void *v) { struct mp_config_table *mc; unsigned sbdn; - int i,j; + int i, j, bus_isa; mc = (void *)(((char *)v) + SMP_FLOATING_TABLE_LEN); - mptable_init(mc, "GA-2761GXDK ", LAPIC_ADDR); + mptable_init(mc, LOCAL_APIC_ADDR); smp_write_processors(mc); get_bus_conf(); sbdn = sysconf.sbdn; -/*Bus: Bus ID Type*/ - /* define bus and isa numbers */ - for(j= 0; j < 256 ; j++) { - if(bus_type[j]) - smp_write_bus(mc, j, "PCI "); - } - smp_write_bus(mc, bus_isa, "ISA "); + mptable_write_buses(mc, NULL, &bus_isa); /*I/O APICs: APIC ID Version State Address*/ { @@ -113,21 +104,16 @@ static void *smp_write_config_table(void *v) } /*Local Ints: Type Polarity Trigger Bus ID IRQ APIC ID PIN#*/ - smp_write_lintsrc(mc, mp_ExtINT, MP_IRQ_TRIGGER_EDGE|MP_IRQ_POLARITY_HIGH, bus_isa, 0x0, MP_APIC_ALL, 0x0); - smp_write_lintsrc(mc, mp_NMI, MP_IRQ_TRIGGER_EDGE|MP_IRQ_POLARITY_HIGH, bus_isa, 0x0, MP_APIC_ALL, 0x1); + mptable_lintsrc(mc, bus_isa); /* There is no extension information... */ /* Compute the checksums */ - mc->mpe_checksum = smp_compute_checksum(smp_next_mpc_entry(mc), mc->mpe_length); - mc->mpc_checksum = smp_compute_checksum(mc, mc->mpc_length); - printk(BIOS_DEBUG, "Wrote the mp table end at: %p - %p\n", - mc, smp_next_mpe_entry(mc)); - return smp_next_mpe_entry(mc); + return mptable_finalize(mc); } unsigned long write_smp_table(unsigned long addr) { void *v; - v = smp_write_floating_table(addr); + v = smp_write_floating_table(addr, 0); return (unsigned long)smp_write_config_table(v); }