bochs and mp tables

Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
Post Reply
blound
Member
Member
Posts: 70
Joined: Sat Dec 01, 2007 1:36 pm

bochs and mp tables

Post by blound »

Been a while since I have been here..

I am having a problem with the mp tables from bochs and locating the PCI busses. When I boot my os and have it print the busses it from the mp tables it says it only finds 1 ISA bus, but I have configured all the pci support for bochs.

My options during ./configure were:

"--enable-smp --enable-apic --enable-ne2000 --enable-acpi --enable-pci --enable-pnic --enable-usb --enable-large-pages --enable-pae --enable-mtrr --enable-show-ips --enable-debugger --enable-disasm --enable-readline --enable-logging --enable-x86-debugger --with-x11"

and my config file I boot with is:
"
megs: 64
romimage: file="/home/blound/os32/bochs-build/share/bochs/BIOS-bochs-latest"
vgaromimage: file="/home/blound/os32/bochs-build/share/bochs/VGABIOS-elpin-2.40"
floppya: 1_44=/dev/loop0, status=inserted
boot: a
log: bochsout.txt
mouse: enabled=0
clock: sync=realtime
cpu: count=2, ips=700000
panic: action=ask
error: action=report
info: action=report
debug: action=ignore
pass: action=fatal
i440fxsupport: enabled=1, slot1=pcivga, slot2=ne2k
ne2k: enabled=1, ioaddr=0x300, irq=9, mac=b0:c4:20:aa:bb:cc, ethmod=linux, ethdev=wlan0
usb1: enabled=1, port1=mouse, port2=keypad
"

is there no way to get bochs to populate the mp tables with info about the pci busses? or am I missing something I need to do with bochs to get it to use pci?
ru2aqare
Member
Member
Posts: 342
Joined: Fri Jul 11, 2008 5:15 am
Location: Hungary

Re: bochs and mp tables

Post by ru2aqare »

I don't know about the MP tables, but I was able to scan the PCI buses after I recompiled Bochs. I passed --enable-pci to the configure script, and PCI worked as expected.

On the other hand, I was only able to locate devices on PCI bus zero only. Although the scan indicated a PCI->PCI (or PCI->AGP) bridge, I was not able to scan it. I presume the emulated PCI graphics card would be located there, but I might be doing something the wrong way.
User avatar
01000101
Member
Member
Posts: 1599
Joined: Fri Jun 22, 2007 12:47 pm
Contact:

Re: bochs and mp tables

Post by 01000101 »

I believe the "--enable-pcidev" option allows for devices found by Linux to be used in the emulation environment... I think.
User avatar
Brendan
Member
Member
Posts: 8561
Joined: Sat Jan 15, 2005 12:00 am
Location: At his keyboard!
Contact:

Re: bochs and mp tables

Post by Brendan »

Hi,
blound wrote:I am having a problem with the mp tables from bochs and locating the PCI busses.
I took a look at the source code that generates the MP specification tables (in the Bochs BIOS), and it'll only ever generate one entry for one ISA bus, and that ISA bus will be "bus_ID = 0" (where "bus_ID = 0" is always the first PCI bus in PCI systems).

That only gives you 2 choices - write a patch for the Bochs BIOS to correct it's MP tables, or modify your OS so that it scans PCI buses itself instead of getting this information from the MP specification tables.

To be honest, you probably should scan the PCI buses yourself anyway, because it's possible for real computers to have no MP tables (either because they don't support multi-CPU or because they support ACPI only).


Cheers,

Brendan
For all things; perfection is, and will always remain, impossible to achieve in practice. However; by striving for perfection we create things that are as perfect as practically possible. Let the pursuit of perfection be our guide.
blound
Member
Member
Posts: 70
Joined: Sat Dec 01, 2007 1:36 pm

Re: bochs and mp tables

Post by blound »

Brendan wrote:Hi,
blound wrote:I am having a problem with the mp tables from bochs and locating the PCI busses.
I took a look at the source code that generates the MP specification tables (in the Bochs BIOS), and it'll only ever generate one entry for one ISA bus, and that ISA bus will be "bus_ID = 0" (where "bus_ID = 0" is always the first PCI bus in PCI systems).

That only gives you 2 choices - write a patch for the Bochs BIOS to correct it's MP tables, or modify your OS so that it scans PCI buses itself instead of getting this information from the MP specification tables.

To be honest, you probably should scan the PCI buses yourself anyway, because it's possible for real computers to have no MP tables (either because they don't support multi-CPU or because they support ACPI only).


Cheers,

Brendan

thanks for the replies. I will just have it scan the pci buses for the info.
Post Reply