Skip to contentSkip to conversation

PCI reset using x86 or x86-64 BIOS calls?

DISCUSSION Robert Hancock 3 participants 3 messages May 26, 2006 – May 27, 2006 1 message not in the archive

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): [email protected]

#1 lore raw
Quoted 5 lines · Linas Vepstas

I've go a newbie x86 BIOS question: is there a BIOS function that can be called to reset a PCI device? (By "reset a device" I mean raise the #RST PCI signal line to electrical high for 1.5 seconds).
I know that BIOS does this during a soft reboot, but I was wondering
if there's a stand-alone function for doing this while the system is up
and running.

Unlikely - if you mean just resetting one PCI device, it's likely electrically impossible on many, if not most machines as the RST lines will be tied together on all slots.

The BIOS might possibly have the ability to issue a PCI bus reset independent of resetting the CPU, chipset, etc. but I don't think there's any standardized way to trigger this, even so.

In any case, I don't think - or at least would hope - that a PCI device going so far into the weeds that it can't be recovered without a RST would be a rare situation.

Signature · 3 lines
Robert Hancock      Saskatoon, SK, Canada
To email, remove "nospam" from [email protected]
Home Page: http://www.roberthancock.com/
#2 lore raw
Quoted 11 lines · Robert Hancock
Quoted 6 lines · Linas Vepstas

I've go a newbie x86 BIOS question: is there a BIOS function that can be called to reset a PCI device? (By "reset a device" I mean raise the #RST PCI signal line to electrical high for 1.5 seconds). I know that BIOS does this during a soft reboot, but I was wondering if there's a stand-alone function for doing this while the system is up and running.

Unlikely - if you mean just resetting one PCI device, it's likely electrically impossible on many, if not most machines as the RST lines will be tied together on all slots.

I was afraid of that.

Quoted 3 lines

In any case, I don't think - or at least would hope - that a PCI device going so far into the weeds that it can't be recovered without a RST would be a rare situation.

Well, this comes up in the case of having kexec take over from a crashed kernel; the state of any given PCI card is unclear, and its conceptually easiest to hit them with a hammer to put them back into a known state.

For hotplug slots, this can be accomplished by toggling power to a slot, but not all slots out there are hot-pluggable.

The other situation where this is useful is in recovering from a PCI bus error (e.g. parity error); but his has additional complications.

I've got someone here asking about the LSI megaraid controller; appearently its under-documented, and it can hang hard on kexec. Hitting it with a reset would make life simpler.

--linas

#3 lore raw
In reply to Robert Hancock
Quoted 11 lines · Robert Hancock

Unlikely - if you mean just resetting one PCI device, it's likely electrically impossible on many, if not most machines as the RST lines will be tied together on all slots.

The BIOS might possibly have the ability to issue a PCI bus reset independent of resetting the CPU, chipset, etc. but I don't think there's any standardized way to trigger this, even so.

In any case, I don't think - or at least would hope - that a PCI device going so far into the weeds that it can't be recovered without a RST would be a rare situation.

Well I know there is a way to make a pci to pci bridge assert reset on the secondary bus, which of course resets all devices behind the bridge. I am not sure when, other than in the bios, this would be useful. I wouldn't want to have to go clean up the pci configuration settings on all the devices after the reset. I considered doing it to solve a rare problem with some pci cards, but decided a reboot was simpler.

Len Sorensen