Hi,
I have written a MSI setup, but I do not know how to test it. My test PC supports MSI for an ethernet controller (class code: 0x2 - subclass code 0x0). How can I let this PCI device trigger an interrupt using my MSI setup? I have no TCP stack or something.. If you need additional information/code; just ask for it!
Thanks in advance & greets,
Bietje
Interrupts from PCI devices
- Combuster
- Member
- Posts: 9301
- Joined: Wed Oct 18, 2006 3:45 am
- Libera.chat IRC: [com]buster
- Location: On the balcony, where I can actually keep 1½m distance
- Contact:
Re: Interrupts from PCI devices
You can't quite make an ethernet card raise interrupts without having it do meaningful stuff first. Write an implementation of ARP for starters, and see if you can get a request and reply using a sniffer. Depending on the hardware card you may get an interrupt when the send buffer is empty or when a packet has arrived. When you actually have something that can reliably trigger an interrupt, you have a proper tool to implement MSI.
Re: Interrupts from PCI devices
Hi,
That sounds as a good idea. Now I come with a second question.. I downloaded the specification of my NIC, so I know how I can send and receive ARP requests and sent replies. The specification says the following:
Greets,
Bietje
That sounds as a good idea. Now I come with a second question.. I downloaded the specification of my NIC, so I know how I can send and receive ARP requests and sent replies. The specification says the following:
I guess that the base of the config space is defined in one of the PCI BAR's, but I couldn't find in which one I should look. So my question is, where can I find which BAR I should read?Realtek RTL8111B & RTL8168B Specification wrote:The RTL8111B/RTL8168B provide the following set of operational registers mapped into PCI memory
space and I/O space.
Greets,
Bietje