Setting PCI IRQ levels?

Is there any way from software (RTP or Windows or standalone utility) to set the IRQ’s of PCI
slots and motherboard PCI devices? We are encountering machines with BIOS setup screens that leave
this menu out. I’m desparate here- I’m interested no matter how convoluted the solution
may be.


Art Hays
National Institutes of Health
avhays@nih.gov

You could write a program that calls the pci_map_irq() function and see
if that works. Are you saying that the BIOS doesn’t setup IRQs at all?

Previously, Art Hays wrote in qdn.public.qnxrtp.os:

Is there any way from software (RTP or Windows or standalone utility) to set the IRQ’s of PCI
slots and motherboard PCI devices? We are encountering machines with BIOS setup screens that leave
this menu out. I’m desparate here- I’m interested no matter how convoluted the solution
may be.


Art Hays
National Institutes of Health
avhays@nih.gov

“Hugh Brown” <hsbrown@qnx.com> wrote in message
news:Voyager.030520081822.23473B@node90.ott.qnx.com

You could write a program that calls the pci_map_irq() function and see
if that works. Are you saying that the BIOS doesn’t setup IRQs at all?

The BIOS sets them up, but some BIOS setup screens (like the latest Dell Canterwood
motherboards)
no longer have a ‘PCI Configuration’ screen to change them. The BIOS ‘knows’ things-
like which slot INTA#'s are wire-or’ed to motherboard components like USB. What I’d
really like is a program
that prints out what the BIOS ‘knows’, then allows one to change IRQ’s, then writes this
back into the non-volatile area of the BIOS so it persists across reboots as long as no
cards
are added/removed.

With regard to using ‘pci_map_irq()’ I’m curious what would happen in this case- I want
to change the IRQ
of a card in slot 2. Slot 2’s INTA# is wire-or’ed to a USB controller. If I change the
IRQ of the card,
does this automatically result in the USB controller’s IRQ being changed as well? Do I
need to
call ‘pci_map_irq()’ for both?

Why is all this important? Some of us (perhaps a dwindling few) are still trying to do
hard realtime on
regular PC’s. In my case, we need our a/d converter on a high priority IRQ (i.e. ahead
of the IDE or video) that is unshared.

Previously, Art Hays wrote in qdn.public.qnxrtp.os:
Is there any way from software (RTP or Windows or standalone utility) to set the
IRQ’s of PCI
slots and motherboard PCI devices? We are encountering machines with BIOS setup
screens that leave
this menu out. I’m desparate here- I’m interested no matter how convoluted the
solution
may be.


Art Hays
National Institutes of Health
avhays@nih.gov
\

Art Hays <avhays@nih.gov> wrote:

AH > “Hugh Brown” <hsbrown@qnx.com> wrote in message
AH > news:Voyager.030520081822.23473B@node90.ott.qnx.com

You could write a program that calls the pci_map_irq() function and see
if that works. Are you saying that the BIOS doesn’t setup IRQs at all?

AH > With regard to using ‘pci_map_irq()’ I’m curious what would happen
AH > in this case- I want to change the IRQ
AH > of a card in slot 2. Slot 2’s INTA# is wire-or’ed to a USB
AH > controller. If I change the IRQ of the card,
AH > does this automatically result in the USB controller’s IRQ being
AH > changed as well? Do I need to call ‘pci_map_irq()’ for both?

I believe that the USB controller should have a different bus/dev_func
pair from the card that you’re trying to control. But this calls for a
trial and error answer to be sure.

So, if you want to control both, then you need to call pci_map_irq()
for each device.

Previously, Art Hays wrote in qdn.public.qnxrtp.os:

“Hugh Brown” <> hsbrown@qnx.com> > wrote in message
news:> Voyager.030520081822.23473B@node90.ott.qnx.com> …
You could write a program that calls the pci_map_irq() function and see
if that works. Are you saying that the BIOS doesn’t setup IRQs at all?


The BIOS sets them up, but some BIOS setup screens (like the latest Dell Canterwood
motherboards)
no longer have a ‘PCI Configuration’ screen to change them. The BIOS ‘knows’ things-
like which slot INTA#'s are wire-or’ed to motherboard components like USB. What I’d
really like is a program
that prints out what the BIOS ‘knows’, then allows one to change IRQ’s, then writes this
back into the non-volatile area of the BIOS so it persists across reboots as long as no
cards
are added/removed.

Well, if you have a QNX4 boot, you could run ‘show_pci -v’ and this would
show you the IRQ routing on the motherboard.

With regard to using ‘pci_map_irq()’ I’m curious what would happen in this case- I want
to change the IRQ
of a card in slot 2. Slot 2’s INTA# is wire-or’ed to a USB controller. If I change the
IRQ of the card,
does this automatically result in the USB controller’s IRQ being changed as well? Do I
need to
call ‘pci_map_irq()’ for both?

How do you know that they are wire-or’ed? They could have the same IRQ but
be on different INTx lines. It all depends on how the BIOS sets up the
interrupt routing chip. If they are both on the same INTx line, then yes,
you will have to change the IRQs for both of the controllers. You might
still be in trouble though, as some BIOSes don’t allow you to re-map IRQs.
You will soon find out by using the pci_map_irq() call and checking the
return status.

Why is all this important? Some of us (perhaps a dwindling few) are still trying to do
hard realtime on
regular PC’s. In my case, we need our a/d converter on a high priority IRQ (i.e. ahead
of the IDE or video) that is unshared.

Previously, Art Hays wrote in qdn.public.qnxrtp.os:
Is there any way from software (RTP or Windows or standalone utility) to set the
IRQ’s of PCI
slots and motherboard PCI devices? We are encountering machines with BIOS setup
screens that leave
this menu out. I’m desparate here- I’m interested no matter how convoluted the
solution
may be.


Art Hays
National Institutes of Health
avhays@nih.gov



\

“Hugh Brown” <hsbrown@qnx.com> wrote in message
news:Voyager.030520150920.31395E@node90.ott.qnx.com

How do you know that they are wire-or’ed? They could have the same IRQ but
be on different INTx lines. It all depends on how the BIOS sets up the
interrupt routing chip. If they are both on the same INTx line, then yes,
you will have to change the IRQs for both of the controllers. You might
still be in trouble though, as some BIOSes don’t allow you to re-map IRQs.
You will soon find out by using the pci_map_irq() call and checking the
return status.

On the motherboards I’m familiar with the PCI interrupts go into the ICH on
8 lines named PIRQA-H in non-APIC mode. These 8 lines are for all of the slot’s INTA-INTD,
as well as things line AGP, USB, SMBus, LAN, etc. So there are far more
than 8 sources to handle. How these interrupt sources are routed and shared to the 8 PIRQA-H
inputs seems fixed and unchangeable in the BIOS. This is why I said they were ‘wire-or’ed’.
APIC mode opens this up, but I’m not aware of the plans for support of this in RTP.

Previously, Art Hays wrote in qdn.public.qnxrtp.os:

“Hugh Brown” <> hsbrown@qnx.com> > wrote in message
news:> Voyager.030520150920.31395E@node90.ott.qnx.com> …

How do you know that they are wire-or’ed? They could have the same IRQ but
be on different INTx lines. It all depends on how the BIOS sets up the
interrupt routing chip. If they are both on the same INTx line, then yes,
you will have to change the IRQs for both of the controllers. You might
still be in trouble though, as some BIOSes don’t allow you to re-map IRQs.
You will soon find out by using the pci_map_irq() call and checking the
return status.


On the motherboards I’m familiar with the PCI interrupts go into the ICH on
8 lines named PIRQA-H in non-APIC mode. These 8 lines are for all of the slot’s INTA-INTD,
as well as things line AGP, USB, SMBus, LAN, etc. So there are far more
than 8 sources to handle. How these interrupt sources are routed and shared to the 8 PIRQA-H
inputs seems fixed and unchangeable in the BIOS. This is why I said they were ‘wire-or’ed’.
APIC mode opens this up, but I’m not aware of the plans for support of this in RTP.

No, we don’t support APIC mode at the moment.