QEMU RTL8139 Interrupt's

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
jammmie999
Posts: 13
Joined: Sun Feb 06, 2011 4:54 am

QEMU RTL8139 Interrupt's

Post by jammmie999 »

A simulated RTL8139 under QEMU isn't reporting its interrupt information (PIN or Line) in the PCI configuration space, see the attached image, I have run through a loop printing out all information in the PCI configuration space. 0x3E and 0x3F report 0x0 back, not what I was expecting, though the IO address is reported fine at 0x10 being 0xc101 or 49409. Any ideas why this is?

Thanks
QEMU.png
User avatar
bluemoon
Member
Member
Posts: 1761
Joined: Wed Dec 01, 2010 3:41 am
Location: Hong Kong

Re: QEMU RTL8139 Interrupt's

Post by bluemoon »

To get the IRQ you need another IO, this is what I do:

Code: Select all

    outl(PCI_CONFIG_ADDRESS, base +0x3C);
    if ( (data = inl(PCI_CONFIG_DATA)) == 0xFFFFFFFF ) return -1;
    *irq = data & 0xFF;
In my setting, the 8139 has IRQ 11.
Post Reply