Resetting the PCI Bus

Guys,

Maybe someone out there knows the answer. Is there a kosher way
of resetting the PCI bus ? Or, failing that, is there an easy
way to quiet down the OS so that a hardware-level bus (and
bridge) reset doesn’t break things ? I have a chip with an
intermittent problem, every once in a blue moon the PCI
interface is screwed up, and no matter how much I reset the
chip, the bridge still misbehaves - only a power cycle fixes it.
I know that a reset fixes the issue, but that’s a bit of an
extreme action, at least the way the driver does it. Is there
any other way ?

Tks,

Alberto.

I don’t think there are the means of reset on the PCI bus, it is not SCSI.

Maxim Shatskih, Windows DDK MVP
StorageCraft Corporation
xxxxx@storagecraft.com
http://www.storagecraft.com

----- Original Message -----
From: “Alberto Moreira”
To: “Windows System Software Devs Interest List”
Sent: Friday, November 25, 2005 1:04 AM
Subject: [ntdev] Resetting the PCI Bus

> Guys,
>
> Maybe someone out there knows the answer. Is there a kosher way
> of resetting the PCI bus ? Or, failing that, is there an easy
> way to quiet down the OS so that a hardware-level bus (and
> bridge) reset doesn’t break things ? I have a chip with an
> intermittent problem, every once in a blue moon the PCI
> interface is screwed up, and no matter how much I reset the
> chip, the bridge still misbehaves - only a power cycle fixes it.

If you reset the whole PCI bus, you’ll effectively reset everything (not
much non pci stuff out there nowadays).
You might be ‘lucky’ if your device sits on a bus that’s behind a
transparent bridge and that bridge has a register to issue a secondary
bus reset.
Unfortunately transparent bridges aren’t visible to you unless you have
your own pci bus filter, and then they still might not allow you to
reset only the secondary bus and if they do, you’re still resetting all
devices below this bus.
A lot of ‘ifs’, but if someone has another way, I’d also like to know.

Robin

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Alberto Moreira
Sent: Donnerstag, 24. November 2005 23:04
To: Windows System Software Devs Interest List
Subject: [ntdev] Resetting the PCI Bus

Guys,

Maybe someone out there knows the answer. Is there a kosher way
of resetting the PCI bus ? Or, failing that, is there an easy
way to quiet down the OS so that a hardware-level bus (and
bridge) reset doesn’t break things ? I have a chip with an
intermittent problem, every once in a blue moon the PCI
interface is screwed up, and no matter how much I reset the
chip, the bridge still misbehaves - only a power cycle fixes it.
I know that a reset fixes the issue, but that’s a bit of an
extreme action, at least the way the driver does it. Is there
any other way ?

Tks,

Alberto.


Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256

You are currently subscribed to ntdev as: xxxxx@exgate.tek.com
To unsubscribe send a blank email to xxxxx@lists.osr.com

The question is, of course, whether resetting the secondary bus
will be enough. Actually, thinking of it, there’s a point in
hiding the chip behind a secondary bridge, so that the effects
of the chip’s PCI bus handling are minimized; but then, we need
to spend money in the primary-to-secondary PCI bridge. At least
for future products we have full control over what goes on the
peripheral board, so, an architecture that would minimize any
possible ill-effects of the chip’s PCI bus interface might be
worthwhile pursuing.

But I agree, there’s a lot of ifs!

Alberto.

----- Original Message -----
From:
To: “Windows System Software Devs Interest List”

Sent: Friday, November 25, 2005 5:22 AM
Subject: RE: [ntdev] Resetting the PCI Bus

If you reset the whole PCI bus, you’ll effectively reset
everything (not
much non pci stuff out there nowadays).
You might be ‘lucky’ if your device sits on a bus that’s behind
a
transparent bridge and that bridge has a register to issue a
secondary
bus reset.
Unfortunately transparent bridges aren’t visible to you unless
you have
your own pci bus filter, and then they still might not allow you
to
reset only the secondary bus and if they do, you’re still
resetting all
devices below this bus.
A lot of ‘ifs’, but if someone has another way, I’d also like to
know.

Robin

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Alberto
Moreira
Sent: Donnerstag, 24. November 2005 23:04
To: Windows System Software Devs Interest List
Subject: [ntdev] Resetting the PCI Bus

Guys,

Maybe someone out there knows the answer. Is there a kosher way
of resetting the PCI bus ? Or, failing that, is there an easy
way to quiet down the OS so that a hardware-level bus (and
bridge) reset doesn’t break things ? I have a chip with an
intermittent problem, every once in a blue moon the PCI
interface is screwed up, and no matter how much I reset the
chip, the bridge still misbehaves - only a power cycle fixes it.
I know that a reset fixes the issue, but that’s a bit of an
extreme action, at least the way the driver does it. Is there
any other way ?

Tks,

Alberto.


Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256

You are currently subscribed to ntdev as:
xxxxx@exgate.tek.com
To unsubscribe send a blank email to
xxxxx@lists.osr.com


Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256

You are currently subscribed to ntdev as: unknown lmsubst tag
argument: ‘’
To unsubscribe send a blank email to
xxxxx@lists.osr.com

Generally, a secondary bus reset is enough. The problem is that you’ll blow
away all configuration and state on all the devices behind the bridge. (But
you already knew that.) If you can guarantee that only your device is
behind the bridge, you might be able to get away with it at run-time,
reprogramming your device as necessary. If you can’t guarantee that, the
only way to get the entire OS to stop using all the devices and then
re-program them afterwards is to send the machine through an S3 sleep state
transition. And even that won’t work in machines where the BIOS tells the
OS that the busses in question remain fully powered in the S3 state.


Jake Oshins
Windows Kernel Group

The Virtual Machine Team at Microsoft is hiring.

This posting is provided “AS IS” with no warranties, and confers no rights.

“Alberto Moreira” wrote in message news:xxxxx@ntdev…
> The question is, of course, whether resetting the secondary bus will be
> enough. Actually, thinking of it, there’s a point in hiding the chip
> behind a secondary bridge, so that the effects of the chip’s PCI bus
> handling are minimized; but then, we need to spend money in the
> primary-to-secondary PCI bridge. At least for future products we have full
> control over what goes on the peripheral board, so, an architecture that
> would minimize any possible ill-effects of the chip’s PCI bus interface
> might be worthwhile pursuing.
>
> But I agree, there’s a lot of ifs!
>
> Alberto.
>
> ----- Original Message -----
> From:
> To: “Windows System Software Devs Interest List”
> Sent: Friday, November 25, 2005 5:22 AM
> Subject: RE: [ntdev] Resetting the PCI Bus
>
>
> If you reset the whole PCI bus, you’ll effectively reset everything (not
> much non pci stuff out there nowadays).
> You might be ‘lucky’ if your device sits on a bus that’s behind a
> transparent bridge and that bridge has a register to issue a secondary
> bus reset.
> Unfortunately transparent bridges aren’t visible to you unless you have
> your own pci bus filter, and then they still might not allow you to
> reset only the secondary bus and if they do, you’re still resetting all
> devices below this bus.
> A lot of ‘ifs’, but if someone has another way, I’d also like to know.
>
> Robin
>
> -----Original Message-----
> From: xxxxx@lists.osr.com
> [mailto:xxxxx@lists.osr.com] On Behalf Of Alberto Moreira
> Sent: Donnerstag, 24. November 2005 23:04
> To: Windows System Software Devs Interest List
> Subject: [ntdev] Resetting the PCI Bus
>
>
> Guys,
>
> Maybe someone out there knows the answer. Is there a kosher way
> of resetting the PCI bus ? Or, failing that, is there an easy
> way to quiet down the OS so that a hardware-level bus (and
> bridge) reset doesn’t break things ? I have a chip with an
> intermittent problem, every once in a blue moon the PCI
> interface is screwed up, and no matter how much I reset the
> chip, the bridge still misbehaves - only a power cycle fixes it.
> I know that a reset fixes the issue, but that’s a bit of an
> extreme action, at least the way the driver does it. Is there
> any other way ?
>
> Tks,
>
>
> Alberto.
>
>
>
> —
> Questions? First check the Kernel Driver FAQ at
> http://www.osronline.com/article.cfm?id=256
>
> You are currently subscribed to ntdev as: xxxxx@exgate.tek.com
> To unsubscribe send a blank email to xxxxx@lists.osr.com
>
>
> —
> Questions? First check the Kernel Driver FAQ at
> http://www.osronline.com/article.cfm?id=256
>
> You are currently subscribed to ntdev as: unknown lmsubst tag argument: ‘’
> To unsubscribe send a blank email to xxxxx@lists.osr.com
>
>

We’re using non-transparent bridges for our ‘intelligent’ devices.
These mostly have their own CPUs controlling a complete local PCI system

including a DMA to burst data to and from the system cpu across the non
transparent bridge.
I don’t know if that’s an option for what you’re doing.
And for ‘future’ products probably PCIe is the way to go anyway.

Robin

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Alberto Moreira
Sent: Freitag, 25. November 2005 19:31
To: Windows System Software Devs Interest List
Subject: Re: [ntdev] Resetting the PCI Bus

The question is, of course, whether resetting the secondary bus
will be enough. Actually, thinking of it, there’s a point in
hiding the chip behind a secondary bridge, so that the effects
of the chip’s PCI bus handling are minimized; but then, we need
to spend money in the primary-to-secondary PCI bridge. At least
for future products we have full control over what goes on the
peripheral board, so, an architecture that would minimize any
possible ill-effects of the chip’s PCI bus interface might be
worthwhile pursuing.

But I agree, there’s a lot of ifs!

Alberto.

----- Original Message -----
From:
To: “Windows System Software Devs Interest List”

Sent: Friday, November 25, 2005 5:22 AM
Subject: RE: [ntdev] Resetting the PCI Bus

If you reset the whole PCI bus, you’ll effectively reset
everything (not
much non pci stuff out there nowadays).
You might be ‘lucky’ if your device sits on a bus that’s behind
a
transparent bridge and that bridge has a register to issue a
secondary
bus reset.
Unfortunately transparent bridges aren’t visible to you unless
you have
your own pci bus filter, and then they still might not allow you
to
reset only the secondary bus and if they do, you’re still
resetting all
devices below this bus.
A lot of ‘ifs’, but if someone has another way, I’d also like to
know.

Robin

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Alberto
Moreira
Sent: Donnerstag, 24. November 2005 23:04
To: Windows System Software Devs Interest List
Subject: [ntdev] Resetting the PCI Bus

Guys,

Maybe someone out there knows the answer. Is there a kosher way
of resetting the PCI bus ? Or, failing that, is there an easy
way to quiet down the OS so that a hardware-level bus (and
bridge) reset doesn’t break things ? I have a chip with an
intermittent problem, every once in a blue moon the PCI
interface is screwed up, and no matter how much I reset the
chip, the bridge still misbehaves - only a power cycle fixes it.
I know that a reset fixes the issue, but that’s a bit of an
extreme action, at least the way the driver does it. Is there
any other way ?

Tks,

Alberto.


Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256

You are currently subscribed to ntdev as:
xxxxx@exgate.tek.com
To unsubscribe send a blank email to
xxxxx@lists.osr.com


Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256

You are currently subscribed to ntdev as: unknown lmsubst tag
argument: ‘’
To unsubscribe send a blank email to
xxxxx@lists.osr.com


Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256

You are currently subscribed to ntdev as: xxxxx@exgate.tek.com
To unsubscribe send a blank email to xxxxx@lists.osr.com