Disassembling/Debugging the PC's BIOS?

I have a normal pc desktop machine with a msi k8t neo-v motherboard which utilizes an AMI BIOS. I have a pci video card in an expansion slot. On bootup POST, the BIOS complains about a routing table error on device 0:05:00 which pionts to my video card (the only PCI device in an expansion slot). This motherboard does not have onboard video so I need this video card in order to see anything (as I do not have any backups). This video card works flawlessly in another machine (different mobo/chipset/bios). I have done some searching and it seems I need to look for a "pnp os" setting in my BIOS; none exists (or the the mobo manufacturer has conveniently removed the ability to alter this setting as a lot of them do to a stock BIOS).

So I've come to the point where I want to disassembly/debug my BIOS to see what the exact error is. I can use dos debug to find the location of the '$PIR' signature of the routing table and maybe will only have to analyze the data and this will show what the inconsistency/error is. Otherwise I need to do some really-involved disassembly/debugging.

The video card still works, however very slowly. It's like it's "painting" row by row....very obvious to the human eye. CPU utilization runs up to 90% for a simple act like scrolling a ms-windows notepad window (and takes a couple of seconds). The card itself is a 5volt PCI ATI Rage Mobility card (mobo supports 3.3 & 5 and AGP up to 3.0).

I've reset CMOS, removed/reinstalled battery, disconnect power chord from psu, disconnect all connections to the mobo including the atx PSU connector, reseated the video card in all slots, removed/reinstalled the cpu (which isan AMD Athlon 64 @ 2.0Ghz, 200MHz HTT x4 = 800MHz FSB), tried different memory (current is 512MB ddr400 [200Mhz bus], and even booted up with only memory, cpu, psu, and video card hooked up and still same error.

Any tips/pointers?

Reply to
jonfaquit
Loading thread data ...

The BIOS has problems assigning interrupts to the Board. Have you tried the VGA board in other slots? (Ok. you had, overread it) It may be that the VGA board has faulty PCI configuration space and it's not the Mobo's fault. Check the traces on the PCB, which lead to the PCI- INTA, INTB, INTC, INTD contacts. If more then INTA is used (I.e, boards uses more than one interrupt, which is quite uncommon these days) it may get difficult. IIRC "PnP" refers to legacy ISA PnP. PCI is plug-and-play by default. Try to use an AGP board in addition to the PCI board. Start someting like Knoppix (Linux on a DVD) and diagnose the PCI bus using lspci.

Reply to
Thomas Gallenkamp

But what if this board works correctly on another computer? Would that still be a faulty PCI config space? At the moment I'm running Debian as video as Linux handles the video problem/setup better than windows. It's still evident that there's a problem however.

heres some lspci -vvv

# lspci -vvv -s 0:05.0

0000:00:05.0 VGA compatible controller: ATI Technologies Inc Rage Mobility P/M AGP 2x (rev 64) (prog-if 00 [VGA]) Subsystem: ATI Technologies Inc Rage Mobility P/M AGP 2x Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping+ SERR- FastB2B- Status: Cap+ 66MHz- UDF- FastB2B+ ParErr- DEVSEL=medium
Reply to
jonfaquit

Get the OEM customization utility for your motherboard BIOS and see if you can simply re-enable the setting, if it exists.

Reply to
larwe

Only thing I've found is a program called AMISETUP that does not work (as it is unable to recognize my BIOS).

Reply to
jonfaquit

If you have an American Megatrends BIOS, you need AMIBCP. AMISETUP is an ancient, ANCIENT utility that simply edits CMOS settings. AMIBCP works on a BIOS dump and edits the menu structures in it.

Reply to
larwe

ok, I'll look for it.

Reply to
jonfaquit

Well, I found AMIBCP but all versions of it crash under win2k/winxp/winxp64 and the DOS version tells me the checksum is bad for the particular BIOS image from MSI. The crash occurs in ntdll so I will try this on another system.

It seems BIOS editing/modding tools are all out of date. The latest programs are all prior to 2003.

Well, I analyzed my IRQ table. Based on my understanding, there's an error in the table because the BIOS doesn't include an entry for bus 0, device 5?

This is the table: (microsoft spec:

formatting link

00: 24 50 49 52 00 01 D0 00-00 88 00 00 06 11 27 32 $PIR..........'2 10: 00 00 00 00 00 00 00 00-00 00 00 00 00 00 00 47 ...............G 20: 00 08 01 F8 DC 02 F8 DC-00 00 00 00 00 00 00 00 ................ 30: 00 88 00 00 00 00 00 00-03 F8 DC 00 00 00 00 00 ................ 40: 00 80 01 F8 DC 02 F8 DC-03 F8 DC 05 F8 DC 00 00 ................ 50: 00 78 02 F8 DC 03 F8 DC-05 F8 DC 01 F8 DC 00 00 .x.............. 60: 00 40 01 F8 DC 02 F8 DC-03 F8 DC 05 F8 DC 01 00 .@.............. 70: 00 48 02 F8 DC 03 F8 DC-05 F8 DC 01 F8 DC 02 00 .H.............. 80: 00 50 03 F8 DC 05 F8 DC-01 F8 DC 02 F8 DC 03 00 .P.............. 90: 00 58 05 F8 DC 01 F8 DC-02 F8 DC 03 F8 DC 04 00 .X.............. A0: 00 60 02 F8 DC 03 F8 DC-05 F8 DC 01 F8 DC 05 00 .`.............. B0: 00 70 02 F8 DC 03 F8 DC-05 F8 DC 01 F8 DC 05 00 .p.............. C0: 00 90 03 F8 DC 05 F8 DC-01 F8 DC 02 F8 DC 00 00 ................

--Table---------

0x00 - 03: signature = '$PIR' 0x04 - 05: version = 1.0 0x06 - 07: size = 0xD0 (bytes 00->CF) 0x20 - 0x2F: first slot entry (slots start at '1' for you 0-based thinkers) 0x30 - 0x3F: second slot entry ... 0xC0 - 0xCF: last slot entry, in my case the 11th slot entry

--Slot Entry (0x00-0x0F)----------

0x00: bus number 0x01: dev number (in upper five bits...readable would be byte shift-right 3) 0x02: link value for INTA# pci-connector pin 0x03-0x04: irq bitmap for INTA# .. 0x0C-0x0D: irq bitmap for INTD# 0x0E: slot number (0=system, non-zero = expansion slot number)

So if I'm looking for device 5, that would be byte 0x01 shifted-right 3 bits should equal 5 (or 5 shift-left 3 should equal (slot_entry_byte_01 & F8) == 0x28).

Problem is, there is none that match a device number of 5! Is that the error? Where is the device number of 05 coming from? I thought device number specifies the pci-bus's 'slot' (which is not necessarily an expansion slot). The expansion slot I have the card in right now is #2. Based on byte 0x7E being 2, this is the system 'slot' the card is using. It has a device number "byte" of 0x48 which, shifted-right 3 is device number 9. Why is the card showing up as device 5 instead of 9?

Any ideas (or links to a recent AMIBIOS setup-editing tool)?

Reply to
jonfaquit

Also, does anyone know where I can find the most complete PCI spec? That would help a lot!

Reply to
jonfaquit

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.