ISR gets called although device does not interrupt

Hi All,

In my WDM for a PCI memory mapped device, I call IoConnectInterrupt as
follows:

Status = IoConnectInterrupt(&(pDevExt->pIntObj),
(PKSERVICE_ROUTINE)FifoIsr,
(PVOID)pDevExt,NULL,pDevExt->ulVector,
pDevExt->IRQL,pDevExt->IRQL,
pDevExt -> InterruptMode,
pDevExt->bShareVector,
pDevExt->Affinity,FALSE );

Evrything goes fine, and my device is assigned interrupt 9. (In my machine
interrupt 9 seems to be shared by all PCI devices.) Now,
my ISR seems to get called during system boot. I do the following check in
the ISR to check that the interrupt is indeed from my device

if ( pDevExt->ulMyDriverId == MY_DRIVER_ID )
{
DbgPrint (“FIFO5W: pDevExt -> pMemRegs\n”);
return TRUE ;
}
return FALSE;
}

The problem is that the system hangs while boot up if I am returning a TRUE
anywhere in the ISR although my device does not issue any interrupt. Does
anybody have an idea why this is happening ??

I also tried this

if ( pDevExt->ulMyDriverId == MY_DRIVER_ID )
{
DbgPrint (“FIFO5W: pDevExt -> pMemRegs\n”);
return FALSE ;//unlike earler case
}
return FALSE;
}

Again, although my device does not issue interrupts, the ISR is called and
enters into the if loop and prints the message. But now, the machine does
not hang and boots properly. What mistake am I making ??Please guide me.

Also, I seem to be getting a CmResourceTypeDevicePrivate parameter in
IRP_MN_START_DEVICE along with CmResourceTypeMemory and
CmResourceTypeInterrupt. How am I supposed to process it ??

Thanks a lot for all help.
Madhu


You are currently subscribed to ntdev as: $subst(‘Recip.EmailAddr’)
To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com

You need to very carefully re-read the DDK manual regarding how to process
interrupts. You only return TRUE if the interrupt is for you. You have to
use a hardware specific mechanism to determine if the interrupt is for you.
Testing your device extension does not help - that simply validates that the
device object is your device object. If it wasn’t your device object you
should bugcheck as the operating system is seriously compromised. As you are
sharing interrupts (and that is very normal for PCI devices,) it is very
likely that your ISR will be invoked a lot when the interrupt is NOT from
your device. The OS has no idea who requested the interrupt, it just calls
in turn each ISR linked to the same interrupt vector.

Generally your hardware will have some status register that will have a bit
that is asserted when the device has requested an interrupt. Like I said,
this is hardware specific, I can’t tell you which register it is, but unless
your PCI device is seriously brain-dead, it has such a register. Your ISR
should look at this register in order to decide if the interrupt is for your
device. If it is then you will be returning TRUE from your ISR, otherwise
you will be returning FALSE.

But wait! There’s more! If it is your interrupt, you absolutely have to tell
your device to shut up (stop asserting an interrupt,) or you will just be
back in your ISR again as soon as you return from it. That will be very bad,
perhaps even evil. Once again, how you tell your PCI device to stop
interrupting is hardware specific. Generally you clear one or more bits in
some register or registers indicating that you have seen and/or processed
whatever it was that caused your device to assert an interrupt to begin
with.

-----Original Message-----
From: xxxxx@yahoo.com [mailto:xxxxx@yahoo.com]
Sent: Tuesday, June 05, 2001 9:01 PM
To: NT Developers Interest List
Subject: [ntdev] ISR gets called although device does not interrupt

Hi All,

In my WDM for a PCI memory mapped device, I call IoConnectInterrupt as
follows:

Status = IoConnectInterrupt(&(pDevExt->pIntObj),
(PKSERVICE_ROUTINE)FifoIsr,
(PVOID)pDevExt,NULL,pDevExt->ulVector,
pDevExt->IRQL,pDevExt->IRQL,
pDevExt -> InterruptMode,
pDevExt->bShareVector,
pDevExt->Affinity,FALSE );

Evrything goes fine, and my device is assigned interrupt 9. (In my machine
interrupt 9 seems to be shared by all PCI devices.) Now,
my ISR seems to get called during system boot. I do the following check in
the ISR to check that the interrupt is indeed from my device

if ( pDevExt->ulMyDriverId == MY_DRIVER_ID )
{
DbgPrint (“FIFO5W: pDevExt -> pMemRegs\n”);
return TRUE ;
}
return FALSE;
}

The problem is that the system hangs while boot up if I am returning a TRUE
anywhere in the ISR although my device does not issue any interrupt. Does
anybody have an idea why this is happening ??

I also tried this

if ( pDevExt->ulMyDriverId == MY_DRIVER_ID )
{
DbgPrint (“FIFO5W: pDevExt -> pMemRegs\n”);
return FALSE ;//unlike earler case
}
return FALSE;
}

Again, although my device does not issue interrupts, the ISR is called and
enters into the if loop and prints the message. But now, the machine does
not hang and boots properly. What mistake am I making ??Please guide me.

Also, I seem to be getting a CmResourceTypeDevicePrivate parameter in
IRP_MN_START_DEVICE along with CmResourceTypeMemory and
CmResourceTypeInterrupt. How am I supposed to process it ??

Thanks a lot for all help.
Madhu


You are currently subscribed to ntdev as: xxxxx@stratus.com To
unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com


You are currently subscribed to ntdev as: $subst(‘Recip.EmailAddr’)
To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com

Thanks for the quick reply. Actually initially I was reading the status
register of my device and verifying whether it is my interrupt or not. But
even then, it would always tell me that I have an interrupt although I am
sure that my device is not interrupting. ( My device is a FIFO card. It
needs to be connected to a testor which sends data to it. Only after the
FIFO is half full, it sends an interrupt. As of now, I have not connected
the testor at all).

Madhu

On 06/06/01, ““Roddy, Mark” ” wrote:
> You need to very carefully re-read the DDK manual regarding how to process
> interrupts. You only return TRUE if the interrupt is for you. You have to
> use a hardware specific mechanism to determine if the interrupt is for you.
> Testing your device extension does not help - that simply validates that the
> device object is your device object. If it wasn’t your device object you
> should bugcheck as the operating system is seriously compromised. As you are
> sharing interrupts (and that is very normal for PCI devices,) it is very
> likely that your ISR will be invoked a lot when the interrupt is NOT from
> your device. The OS has no idea who requested the interrupt, it just calls
> in turn each ISR linked to the same interrupt vector.
>
> Generally your hardware will have some status register that will have a bit
> that is asserted when the device has requested an interrupt. Like I said,
> this is hardware specific, I can’t tell you which register it is, but unless
> your PCI device is seriously brain-dead, it has such a register. Your ISR
> should look at this register in order to decide if the interrupt is for your
> device. If it is then you will be returning TRUE from your ISR, otherwise
> you will be returning FALSE.
>
> But wait! There’s more! If it is your interrupt, you absolutely have to tell
> your device to shut up (stop asserting an interrupt,) or you will just be
> back in your ISR again as soon as you return from it. That will be very bad,
> perhaps even evil. Once again, how you tell your PCI device to stop
> interrupting is hardware specific. Generally you clear one or more bits in
> some register or registers indicating that you have seen and/or processed
> whatever it was that caused your device to assert an interrupt to begin
> with.
>
>
> -----Original Message-----
> From: xxxxx@yahoo.com [mailto:xxxxx@yahoo.com]
> Sent: Tuesday, June 05, 2001 9:01 PM
> To: NT Developers Interest List
> Subject: [ntdev] ISR gets called although device does not interrupt
>
>
> Hi All,
>
> In my WDM for a PCI memory mapped device, I call IoConnectInterrupt as
> follows:
>
> Status = IoConnectInterrupt(&(pDevExt->pIntObj),
> (PKSERVICE_ROUTINE)FifoIsr,
> (PVOID)pDevExt,NULL,pDevExt->ulVector,
> pDevExt->IRQL,pDevExt->IRQL,
> pDevExt -> InterruptMode,
> pDevExt->bShareVector,
> pDevExt->Affinity,FALSE );
>
> Evrything goes fine, and my device is assigned interrupt 9. (In my machine
> interrupt 9 seems to be shared by all PCI devices.) Now,
> my ISR seems to get called during system boot. I do the following check in
> the ISR to check that the interrupt is indeed from my device
>
> if ( pDevExt->ulMyDriverId == MY_DRIVER_ID )
> {
> DbgPrint (“FIFO5W: pDevExt -> pMemRegs\n”);
> return TRUE ;
> }
> return FALSE;
> }
>
> The problem is that the system hangs while boot up if I am returning a TRUE
> anywhere in the ISR although my device does not issue any interrupt. Does
> anybody have an idea why this is happening ??
>
> I also tried this
>
> if ( pDevExt->ulMyDriverId == MY_DRIVER_ID )
> {
> DbgPrint (“FIFO5W: pDevExt -> pMemRegs\n”);
> return FALSE ;//unlike earler case
> }
> return FALSE;
> }
>
> Again, although my device does not issue interrupts, the ISR is called and
> enters into the if loop and prints the message. But now, the machine does
> not hang and boots properly. What mistake am I making ??Please guide me.
>
> Also, I seem to be getting a CmResourceTypeDevicePrivate parameter in
> IRP_MN_START_DEVICE along with CmResourceTypeMemory and
> CmResourceTypeInterrupt. How am I supposed to process it ??
>
> Thanks a lot for all help.
> Madhu
>
> —
> You are currently subscribed to ntdev as: xxxxx@stratus.com To
> unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com
>
> —
> You are currently subscribed to ntdev as: $subst(‘Recip.EmailAddr’)
> To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com


You are currently subscribed to ntdev as: $subst(‘Recip.EmailAddr’)
To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com

If your device is indicating that it is interrupting, yet it is not
interrupting, it is broken. (Is that a haiku?)

You’ll have to find some way to work around that limitation of the hardware
(or go yell at/ask nicely the hardware designer to fix it).

-Tim

Timothy A. Johns — xxxxx@driverdev.com
Driver Development Corporation — 800.841.0092
Bring Up Your Hardware — Fast. www.driverdev.com

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com]On Behalf Of xxxxx@yahoo.com
Sent: Wednesday, June 06, 2001 1:19 PM
To: NT Developers Interest List
Subject: [ntdev] RE: ISR gets called although device does not interrupt

Thanks for the quick reply. Actually initially I was reading the status
register of my device and verifying whether it is my interrupt or
not. But
even then, it would always tell me that I have an interrupt although I am
sure that my device is not interrupting. ( My device is a FIFO card. It
needs to be connected to a testor which sends data to it. Only after the
FIFO is half full, it sends an interrupt. As of now, I have not connected
the testor at all).

Madhu

On 06/06/01, ““Roddy, Mark” ” wrote:
> > You need to very carefully re-read the DDK manual regarding how
> to process
> > interrupts. You only return TRUE if the interrupt is for you.
> You have to
> > use a hardware specific mechanism to determine if the interrupt
> is for you.
> > Testing your device extension does not help - that simply
> validates that the
> > device object is your device object. If it wasn’t your device object you
> > should bugcheck as the operating system is seriously
> compromised. As you are
> > sharing interrupts (and that is very normal for PCI devices,) it is very
> > likely that your ISR will be invoked a lot when the interrupt
> is NOT from
> > your device. The OS has no idea who requested the interrupt, it
> just calls
> > in turn each ISR linked to the same interrupt vector.
> >
> > Generally your hardware will have some status register that
> will have a bit
> > that is asserted when the device has requested an interrupt.
> Like I said,
> > this is hardware specific, I can’t tell you which register it
> is, but unless
> > your PCI device is seriously brain-dead, it has such a
> register. Your ISR
> > should look at this register in order to decide if the
> interrupt is for your
> > device. If it is then you will be returning TRUE from your ISR,
> otherwise
> > you will be returning FALSE.
> >
> > But wait! There’s more! If it is your interrupt, you absolutely
> have to tell
> > your device to shut up (stop asserting an interrupt,) or you
> will just be
> > back in your ISR again as soon as you return from it. That will
> be very bad,
> > perhaps even evil. Once again, how you tell your PCI device to stop
> > interrupting is hardware specific. Generally you clear one or
> more bits in
> > some register or registers indicating that you have seen and/or
> processed
> > whatever it was that caused your device to assert an interrupt to begin
> > with.
> >
> >
> > -----Original Message-----
> > From: xxxxx@yahoo.com [mailto:xxxxx@yahoo.com]
> > Sent: Tuesday, June 05, 2001 9:01 PM
> > To: NT Developers Interest List
> > Subject: [ntdev] ISR gets called although device does not interrupt
> >
> >
> > Hi All,
> >
> > In my WDM for a PCI memory mapped device, I call IoConnectInterrupt as
> > follows:
> >
> > Status = IoConnectInterrupt(&(pDevExt->pIntObj),
> > (PKSERVICE_ROUTINE)FifoIsr,
> > (PVOID)pDevExt,NULL,pDevExt->ulVector,
> > pDevExt->IRQL,pDevExt->IRQL,
> > pDevExt -> InterruptMode,
> > pDevExt->bShareVector,
> > pDevExt->Affinity,FALSE );
> >
> > Evrything goes fine, and my device is assigned interrupt 9. (In
> my machine
> > interrupt 9 seems to be shared by all PCI devices.) Now,
> > my ISR seems to get called during system boot. I do the
> following check in
> > the ISR to check that the interrupt is indeed from my device
> >
> > if ( pDevExt->ulMyDriverId == MY_DRIVER_ID )
> > {
> > DbgPrint (“FIFO5W: pDevExt -> pMemRegs\n”);
> > return TRUE ;
> > }
> > return FALSE;
> > }
> >
> > The problem is that the system hangs while boot up if I am
> returning a TRUE
> > anywhere in the ISR although my device does not issue any
> interrupt. Does
> > anybody have an idea why this is happening ??
> >
> > I also tried this
> >
> > if ( pDevExt->ulMyDriverId == MY_DRIVER_ID )
> > {
> > DbgPrint (“FIFO5W: pDevExt -> pMemRegs\n”);
> > return FALSE ;//unlike earler case
> > }
> > return FALSE;
> > }
> >
> > Again, although my device does not issue interrupts, the ISR is
> called and
> > enters into the if loop and prints the message. But now, the
> machine does
> > not hang and boots properly. What mistake am I making ??Please guide me.
> >
> > Also, I seem to be getting a CmResourceTypeDevicePrivate parameter in
> > IRP_MN_START_DEVICE along with CmResourceTypeMemory and
> > CmResourceTypeInterrupt. How am I supposed to process it ??
> >
> > Thanks a lot for all help.
> > Madhu
> >
> > —
> > You are currently subscribed to ntdev as: xxxxx@stratus.com To
> > unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com
> >
> > —
> > You are currently subscribed to ntdev as: xxxxx@driverdev.com
> > To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com
>
> —
> You are currently subscribed to ntdev as: xxxxx@driverdev.com
> To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com
>


You are currently subscribed to ntdev as: $subst(‘Recip.EmailAddr’)
To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com

My ISR is working. Thanks to your suggestion. I am not
checking any parameter in device extnsion structure
but I am reading the status register of my device.

Thanks
Madhu

— “Roddy, Mark” wrote:
> You need to very carefully re-read the DDK manual
> regarding how to process
> interrupts. You only return TRUE if the interrupt is
> for you. You have to
> use a hardware specific mechanism to determine if
> the interrupt is for you.
> Testing your device extension does not help - that
> simply validates that the
> device object is your device object. If it wasn’t
> your device object you
> should bugcheck as the operating system is seriously
> compromised. As you are
> sharing interrupts (and that is very normal for PCI
> devices,) it is very
> likely that your ISR will be invoked a lot when the
> interrupt is NOT from
> your device. The OS has no idea who requested the
> interrupt, it just calls
> in turn each ISR linked to the same interrupt
> vector.
>
> Generally your hardware will have some status
> register that will have a bit
> that is asserted when the device has requested an
> interrupt. Like I said,
> this is hardware specific, I can’t tell you which
> register it is, but unless
> your PCI device is seriously brain-dead, it has such
> a register. Your ISR
> should look at this register in order to decide if
> the interrupt is for your
> device. If it is then you will be returning TRUE
> from your ISR, otherwise
> you will be returning FALSE.
>
> But wait! There’s more! If it is your interrupt, you
> absolutely have to tell
> your device to shut up (stop asserting an
> interrupt,) or you will just be
> back in your ISR again as soon as you return from
> it. That will be very bad,
> perhaps even evil. Once again, how you tell your PCI
> device to stop
> interrupting is hardware specific. Generally you
> clear one or more bits in
> some register or registers indicating that you have
> seen and/or processed
> whatever it was that caused your device to assert an
> interrupt to begin
> with.
>
>
> -----Original Message-----
> From: xxxxx@yahoo.com [mailto:xxxxx@yahoo.com]
> Sent: Tuesday, June 05, 2001 9:01 PM
> To: NT Developers Interest List
> Subject: [ntdev] ISR gets called although device
> does not interrupt
>
>
> Hi All,
>
> In my WDM for a PCI memory mapped device, I call
> IoConnectInterrupt as
> follows:
>
> Status = IoConnectInterrupt(&(pDevExt->pIntObj),
> (PKSERVICE_ROUTINE)FifoIsr,
> (PVOID)pDevExt,NULL,pDevExt->ulVector,
>
> pDevExt->IRQL,pDevExt->IRQL,
> pDevExt ->
> InterruptMode,
> pDevExt->bShareVector,
> pDevExt->Affinity,FALSE
> );
>
> Evrything goes fine, and my device is assigned
> interrupt 9. (In my machine
> interrupt 9 seems to be shared by all PCI devices.)
> Now,
> my ISR seems to get called during system boot. I do
> the following check in
> the ISR to check that the interrupt is indeed from
> my device
>
> if ( pDevExt->ulMyDriverId == MY_DRIVER_ID )
> {
> DbgPrint (“FIFO5W: pDevExt -> pMemRegs\n”);
> return TRUE ;
> }
> return FALSE;
> }
>
> The problem is that the system hangs while boot up
> if I am returning a TRUE
> anywhere in the ISR although my device does not
> issue any interrupt. Does
> anybody have an idea why this is happening ??
>
> I also tried this
>
> if ( pDevExt->ulMyDriverId == MY_DRIVER_ID )
> {
> DbgPrint (“FIFO5W: pDevExt -> pMemRegs\n”);
> return FALSE ;//unlike earler case
> }
> return FALSE;
> }
>
> Again, although my device does not issue interrupts,
> the ISR is called and
> enters into the if loop and prints the message. But
> now, the machine does
> not hang and boots properly. What mistake am I
> making ??Please guide me.
>
> Also, I seem to be getting a
> CmResourceTypeDevicePrivate parameter in
> IRP_MN_START_DEVICE along with CmResourceTypeMemory
> and
> CmResourceTypeInterrupt. How am I supposed to
> process it ??
>
> Thanks a lot for all help.
> Madhu
>
> —
> You are currently subscribed to ntdev as:
> xxxxx@stratus.com To
> unsubscribe send a blank email to
> leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com
>
> —
> You are currently subscribed to ntdev as:
> xxxxx@yahoo.com
> To unsubscribe send a blank email to
leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com

__________________________________________________
Do You Yahoo!?
Get personalized email addresses from Yahoo! Mail - only $35
a year! http://personal.mail.yahoo.com/


You are currently subscribed to ntdev as: $subst(‘Recip.EmailAddr’)
To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com

In continuation with the last message, my ISR is
working fine now. But I am facing a strange problem. I
install the WDM (without booting after
installation)and send data to my FIFO device so that
it interrupts. I receive all the interrupts and read
all data. Everything is fine. But if I boot my machine
anytime after installation and then send data to the
device so that it interrupts, I receive some
interrupts and after that the machine hangs. Why would
this be happening ? Is there any problem in my
installation ? I have decared my service to be of
SERVICE_DEMAND_START and have not specified anything
in the LoadOrderGroup.Can this be a problem ?

Thanks for all help
Madhu

On 06/06/01, ““Roddy, Mark”
” wrote:
> > Well that sounds very much like you are not
> looking at the correct location
> > for this status register, or you are looking at
> the correct location and
> > have not interpreted the interrupt reason
> correctly and not done the proper
> > handshaking with your device to convince it to
> stop generating an interrupt.
> >
> > The fact that when you return FALSE the system
> works correctly argues for
> > the case that you are looking at the wrong
> locations on the PCI bus for your
> > status register. You are of course talking about
> some register located off
> > of BAR0 or BAR1, right? Not some value in the
> config space for your device?
> > And you did do all the right things to obtain the
> NT safe ‘translated’
> > resource addresses, rather than using raw values,
> right? And finally you are
> > of course using the HAL API to access your device
> rather than using raw
> > pointers, right?
> >
> > It is also possible that your device has
> malfunctioned, but as I said the
> > fact that when you do not process the interrupt
> (you return FALSE) the
> > system behaves normally, strongly suggests that
> your ISR is defective.
> >
> >
> > -----Original Message-----
> > From: xxxxx@yahoo.com [mailto:xxxxx@yahoo.com]
> > Sent: Wednesday, June 06, 2001 9:19 AM
> > To: NT Developers Interest List
> > Subject: [ntdev] RE: ISR gets called although
> device does not interrupt
> >
> >
> > Thanks for the quick reply. Actually initially I
> was reading the status
> > register of my device and verifying whether it is
> my interrupt or not. But
> > even then, it would always tell me that I have an
> interrupt although I am
> > sure that my device is not interrupting. ( My
> device is a FIFO card. It
> > needs to be connected to a testor which sends data
> to it. Only after the
> > FIFO is half full, it sends an interrupt. As of
> now, I have not connected
> > the testor at all).
> >
> > Madhu
> >
> > On 06/06/01, ““Roddy, Mark”
> ” wrote:
> > > You need to very carefully re-read the DDK
> manual regarding how to
> > > process interrupts. You only return TRUE if the
> interrupt is for you.
> > > You have to use a hardware specific mechanism to
> determine if the
> > > interrupt is for you. Testing your device
> extension does not help -
> > > that simply validates that the device object is
> your device object. If
> > > it wasn’t your device object you should bugcheck
> as the operating
> > > system is seriously compromised. As you are
> sharing interrupts (and
> > > that is very normal for PCI devices,) it is very
> likely that your ISR
> > > will be invoked a lot when the interrupt is NOT
> from your device. The
> > > OS has no idea who requested the interrupt, it
> just calls in turn each
> > > ISR linked to the same interrupt vector.
> > >
> > > Generally your hardware will have some status
> register that will have
> > > a bit that is asserted when the device has
> requested an interrupt.
> > > Like I said, this is hardware specific, I can’t
> tell you which
> > > register it is, but unless your PCI device is
> seriously brain-dead, it
> > > has such a register. Your ISR should look at
> this register in order to
> > > decide if the interrupt is for your device. If
> it is then you will be
> > > returning TRUE from your ISR, otherwise you will
> be returning FALSE.
> > >
> > > But wait! There’s more! If it is your interrupt,
> you absolutely have
> > > to tell your device to shut up (stop asserting
> an interrupt,) or you
> > > will just be back in your ISR again as soon as
> you return from it.
> > > That will be very bad, perhaps even evil. Once
> again, how you tell
> > > your PCI device to stop interrupting is hardware
> specific. Generally
> > > you clear one or more bits in some register or
> registers indicating
> > > that you have seen and/or processed whatever it
> was that caused your
> > > device to assert an interrupt to begin with.
> > >
> > >
> > > -----Original Message-----
> > > From: xxxxx@yahoo.com [mailto:xxxxx@yahoo.com]
> > > Sent: Tuesday, June 05, 2001 9:01 PM
> > > To: NT Developers Interest List
> > > Subject: [ntdev] ISR gets called although device
> does not interrupt
> > >
> > >
> > > Hi All,
> > >
> > > In my WDM for a PCI memory mapped device, I call
> IoConnectInterrupt as
> > > follows:
> > >
> > > Status = IoConnectInterrupt(&(pDevExt->pIntObj),
> > > (PKSERVICE_ROUTINE)FifoIsr,
> > >
> (PVOID)pDevExt,NULL,pDevExt->ulVector,
> > >
> pDevExt->IRQL,pDevExt->IRQL,
> > > pDevExt ->
> InterruptMode,
> > >
> pDevExt->bShareVector,
> > >
> pDevExt->Affinity,FALSE );
> > >
> > > Evrything goes fine, and my device is assigned
> interrupt 9. (In my
> > > machine interrupt 9 seems to be shared by all
> PCI devices.) Now, my
> > > ISR seems to get called during system boot. I do
> the following check
> > > in the ISR to check that the interrupt is indeed
> from my device
> > >
> > > if ( pDevExt->ulMyDriverId == MY_DRIVER_ID )
> > > {
> > > DbgPrint (“FIFO5W: pDevExt -> pMemRegs\n”);
> > > return TRUE ;
> > > }
> > > return FALSE;
> > > }
> > >
> > > The problem is that the system hangs while boot
> up if I am returning a
> > > TRUE anywhere in the ISR although my device does
> not issue any
> > > interrupt. Does anybody have an idea why this is
> happening ??
> > >
> > > I also tried this
> > >
> > > if ( pDevExt->ulMyDriverId == MY_DRIVER_ID )
> > > {
> > > DbgPrint (“FIFO5W: pDevExt -> pMemRegs\n”);
> > > return FALSE ;//unlike earler case
> > > }
> > > return FALSE;
> > > }
> > >
> > > Again, although my device does not issue
> interrupts, the ISR is called
> > > and enters into the if loop and prints the
> message.
=== message truncated ===

__________________________________________________
Do You Yahoo!?
Get personalized email addresses from Yahoo! Mail - only $35
a year! http://personal.mail.yahoo.com/


You are currently subscribed to ntdev as: $subst(‘Recip.EmailAddr’)
To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com

Madhu,

That ‘hang’ sounds like an unhandled PCI interrupt. Is your ISR being
called repeatedly while this hang is occuring, and if so, can you verify
100% (using a logic analyzer or oscilliscope, if you’re going to have to
take your evidence to the proverbial hardware person) that your device is
not asserting the interrupt?

Also, it could be a PCI bus access problem, or either a master or target
abort. It’s also possible that it may be that your driver is getting an
interrupt that a different device is already using, and the ‘other’ device
is not sharing it properly, but I’d view that as a last resort, since the
driver you added is new and changing the behavior. You can move it to a
different slot and if the problem goes away or changes, the problem is very
likely in either your driver’s ISR or some other device’s ISR.

In any case, the registry entries for Start and LoadOrderGroup that you have
below are almost certainly correct for a PnP driver.

-Tim

Timothy A. Johns — xxxxx@driverdev.com
Driver Development Corporation — 800.841.0092
Bring Up Your Hardware — Fast. www.driverdev.com

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com]On Behalf Of M V
Sent: Tuesday, June 12, 2001 5:50 AM
To: NT Developers Interest List
Subject: [ntdev] ISR gets called although device does not interrupt

In continuation with the last message, my ISR is
working fine now. But I am facing a strange problem. I
install the WDM (without booting after
installation)and send data to my FIFO device so that
it interrupts. I receive all the interrupts and read
all data. Everything is fine. But if I boot my machine
anytime after installation and then send data to the
device so that it interrupts, I receive some
interrupts and after that the machine hangs. Why would
this be happening ? Is there any problem in my
installation ? I have decared my service to be of
SERVICE_DEMAND_START and have not specified anything
in the LoadOrderGroup.Can this be a problem ?

Thanks for all help
Madhu

> On 06/06/01, ““Roddy, Mark”
> ” wrote:
> > > Well that sounds very much like you are not
> > looking at the correct location
> > > for this status register, or you are looking at
> > the correct location and
> > > have not interpreted the interrupt reason
> > correctly and not done the proper
> > > handshaking with your device to convince it to
> > stop generating an interrupt.
> > >
> > > The fact that when you return FALSE the system
> > works correctly argues for
> > > the case that you are looking at the wrong
> > locations on the PCI bus for your
> > > status register. You are of course talking about
> > some register located off
> > > of BAR0 or BAR1, right? Not some value in the
> > config space for your device?
> > > And you did do all the right things to obtain the
> > NT safe ‘translated’
> > > resource addresses, rather than using raw values,
> > right? And finally you are
> > > of course using the HAL API to access your device
> > rather than using raw
> > > pointers, right?
> > >
> > > It is also possible that your device has
> > malfunctioned, but as I said the
> > > fact that when you do not process the interrupt
> > (you return FALSE) the
> > > system behaves normally, strongly suggests that
> > your ISR is defective.
> > >
> > >
> > > -----Original Message-----
> > > From: xxxxx@yahoo.com [mailto:xxxxx@yahoo.com]
> > > Sent: Wednesday, June 06, 2001 9:19 AM
> > > To: NT Developers Interest List
> > > Subject: [ntdev] RE: ISR gets called although
> > device does not interrupt
> > >
> > >
> > > Thanks for the quick reply. Actually initially I
> > was reading the status
> > > register of my device and verifying whether it is
> > my interrupt or not. But
> > > even then, it would always tell me that I have an
> > interrupt although I am
> > > sure that my device is not interrupting. ( My
> > device is a FIFO card. It
> > > needs to be connected to a testor which sends data
> > to it. Only after the
> > > FIFO is half full, it sends an interrupt. As of
> > now, I have not connected
> > > the testor at all).
> > >
> > > Madhu
> > >
> > > On 06/06/01, ““Roddy, Mark”
> > ” wrote:
> > > > You need to very carefully re-read the DDK
> > manual regarding how to
> > > > process interrupts. You only return TRUE if the
> > interrupt is for you.
> > > > You have to use a hardware specific mechanism to
> > determine if the
> > > > interrupt is for you. Testing your device
> > extension does not help -
> > > > that simply validates that the device object is
> > your device object. If
> > > > it wasn’t your device object you should bugcheck
> > as the operating
> > > > system is seriously compromised. As you are
> > sharing interrupts (and
> > > > that is very normal for PCI devices,) it is very
> > likely that your ISR
> > > > will be invoked a lot when the interrupt is NOT
> > from your device. The
> > > > OS has no idea who requested the interrupt, it
> > just calls in turn each
> > > > ISR linked to the same interrupt vector.
> > > >
> > > > Generally your hardware will have some status
> > register that will have
> > > > a bit that is asserted when the device has
> > requested an interrupt.
> > > > Like I said, this is hardware specific, I can’t
> > tell you which
> > > > register it is, but unless your PCI device is
> > seriously brain-dead, it
> > > > has such a register. Your ISR should look at
> > this register in order to
> > > > decide if the interrupt is for your device. If
> > it is then you will be
> > > > returning TRUE from your ISR, otherwise you will
> > be returning FALSE.
> > > >
> > > > But wait! There’s more! If it is your interrupt,
> > you absolutely have
> > > > to tell your device to shut up (stop asserting
> > an interrupt,) or you
> > > > will just be back in your ISR again as soon as
> > you return from it.
> > > > That will be very bad, perhaps even evil. Once
> > again, how you tell
> > > > your PCI device to stop interrupting is hardware
> > specific. Generally
> > > > you clear one or more bits in some register or
> > registers indicating
> > > > that you have seen and/or processed whatever it
> > was that caused your
> > > > device to assert an interrupt to begin with.
> > > >
> > > >
> > > > -----Original Message-----
> > > > From: xxxxx@yahoo.com [mailto:xxxxx@yahoo.com]
> > > > Sent: Tuesday, June 05, 2001 9:01 PM
> > > > To: NT Developers Interest List
> > > > Subject: [ntdev] ISR gets called although device
> > does not interrupt
> > > >
> > > >
> > > > Hi All,
> > > >
> > > > In my WDM for a PCI memory mapped device, I call
> > IoConnectInterrupt as
> > > > follows:
> > > >
> > > > Status = IoConnectInterrupt(&(pDevExt->pIntObj),
> > > > (PKSERVICE_ROUTINE)FifoIsr,
> > > >
> > (PVOID)pDevExt,NULL,pDevExt->ulVector,
> > > >
> > pDevExt->IRQL,pDevExt->IRQL,
> > > > pDevExt ->
> > InterruptMode,
> > > >
> > pDevExt->bShareVector,
> > > >
> > pDevExt->Affinity,FALSE );
> > > >
> > > > Evrything goes fine, and my device is assigned
> > interrupt 9. (In my
> > > > machine interrupt 9 seems to be shared by all
> > PCI devices.) Now, my
> > > > ISR seems to get called during system boot. I do
> > the following check
> > > > in the ISR to check that the interrupt is indeed
> > from my device
> > > >
> > > > if ( pDevExt->ulMyDriverId == MY_DRIVER_ID )
> > > > {
> > > > DbgPrint (“FIFO5W: pDevExt -> pMemRegs\n”);
> > > > return TRUE ;
> > > > }
> > > > return FALSE;
> > > > }
> > > >
> > > > The problem is that the system hangs while boot
> > up if I am returning a
> > > > TRUE anywhere in the ISR although my device does
> > not issue any
> > > > interrupt. Does anybody have an idea why this is
> > happening ??
> > > >
> > > > I also tried this
> > > >
> > > > if ( pDevExt->ulMyDriverId == MY_DRIVER_ID )
> > > > {
> > > > DbgPrint (“FIFO5W: pDevExt -> pMemRegs\n”);
> > > > return FALSE ;//unlike earler case
> > > > }
> > > > return FALSE;
> > > > }
> > > >
> > > > Again, although my device does not issue
> > interrupts, the ISR is called
> > > > and enters into the if loop and prints the
> > message.
> === message truncated ===
>
>
> __________________________________________________
> Do You Yahoo!?
> Get personalized email addresses from Yahoo! Mail - only $35
> a year! http://personal.mail.yahoo.com/
>
> —
> You are currently subscribed to ntdev as: xxxxx@driverdev.com
> To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com
>


You are currently subscribed to ntdev as: $subst(‘Recip.EmailAddr’)
To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com

Hi Tim.

My device is accessing an interrupt that seems to be
shared by all PCI devices including a network adapter.

  1. When I boot the system, my ISR gets a lot of
    interrupts from other devices as well, probably
    because it may be among the the first ISRs available
    in that interrupt vector chain. When my device ( a
    FIFO card which sends an interrupt every time it is
    half full) starts sending interrupts, in between these
    interrupts I get interrupts from other devices as
    well. After some time, the machine just freezes
    although the device still is interrupting. It freezes
    at the point where I am trying to read a status
    register of the device to determine whether it is my
    interrupt or not.

  2. When I install the driver and then send interrupts
    from the device( without rebooting), my ISR gets only
    the interrupts that are meant for my device and
    nothing else. Probably this is because my ISR is the
    last in the interrupt vector chain for that particular
    interrupt. In this case everything works fine.

Is there any way to make sure that my ISR is the last
ISR available in that interrupt vector chain ? Or is
there any way to make sure that I use an interrupt
which is not shared by other devices ?

Thanks for all help

Madhu
— “Timothy A. Johns” wrote:
> Madhu,
>
> That ‘hang’ sounds like an unhandled PCI interrupt.
> Is your ISR being
> called repeatedly while this hang is occuring, and
> if so, can you verify
> 100% (using a logic analyzer or oscilliscope, if
> you’re going to have to
> take your evidence to the proverbial hardware
> person) that your device is
> not asserting the interrupt?
>
> Also, it could be a PCI bus access problem, or
> either a master or target
> abort. It’s also possible that it may be that your
> driver is getting an
> interrupt that a different device is already using,
> and the ‘other’ device
> is not sharing it properly, but I’d view that as a
> last resort, since the
> driver you added is new and changing the behavior.
> You can move it to a
> different slot and if the problem goes away or
> changes, the problem is very
> likely in either your driver’s ISR or some other
> device’s ISR.
>
> In any case, the registry entries for Start and
> LoadOrderGroup that you have
> below are almost certainly correct for a PnP driver.
>
> -Tim
>
> Timothy A. Johns — xxxxx@driverdev.com
> Driver Development Corporation — 800.841.0092
> Bring Up Your Hardware — Fast. www.driverdev.com
>
>
> > -----Original Message-----
> > From: xxxxx@lists.osr.com
> > [mailto:xxxxx@lists.osr.com]On Behalf
> Of M V
> > Sent: Tuesday, June 12, 2001 5:50 AM
> > To: NT Developers Interest List
> > Subject: [ntdev] ISR gets called although device
> does not interrupt
> >
> >
> > In continuation with the last message, my ISR is
> > working fine now. But I am facing a strange
> problem. I
> > install the WDM (without booting after
> > installation)and send data to my FIFO device so
> that
> > it interrupts. I receive all the interrupts and
> read
> > all data. Everything is fine. But if I boot my
> machine
> > anytime after installation and then send data to
> the
> > device so that it interrupts, I receive some
> > interrupts and after that the machine hangs. Why
> would
> > this be happening ? Is there any problem in my
> > installation ? I have decared my service to be of
> > SERVICE_DEMAND_START and have not specified
> anything
> > in the LoadOrderGroup.Can this be a problem ?
> >
> > Thanks for all help
> > Madhu
> >
> > > On 06/06/01, ““Roddy, Mark”
> > > ” wrote:
> > > > Well that sounds very much like you are not
> > > looking at the correct location
> > > > for this status register, or you are looking
> at
> > > the correct location and
> > > > have not interpreted the interrupt reason
> > > correctly and not done the proper
> > > > handshaking with your device to convince it to
> > > stop generating an interrupt.
> > > >
> > > > The fact that when you return FALSE the system
> > > works correctly argues for
> > > > the case that you are looking at the wrong
> > > locations on the PCI bus for your
> > > > status register. You are of course talking
> about
> > > some register located off
> > > > of BAR0 or BAR1, right? Not some value in the
> > > config space for your device?
> > > > And you did do all the right things to obtain
> the
> > > NT safe ‘translated’
> > > > resource addresses, rather than using raw
> values,
> > > right? And finally you are
> > > > of course using the HAL API to access your
> device
> > > rather than using raw
> > > > pointers, right?
> > > >
> > > > It is also possible that your device has
> > > malfunctioned, but as I said the
> > > > fact that when you do not process the
> interrupt
> > > (you return FALSE) the
> > > > system behaves normally, strongly suggests
> that
> > > your ISR is defective.
> > > >
> > > >
> > > > -----Original Message-----
> > > > From: xxxxx@yahoo.com [mailto:xxxxx@yahoo.com]
> > > > Sent: Wednesday, June 06, 2001 9:19 AM
> > > > To: NT Developers Interest List
> > > > Subject: [ntdev] RE: ISR gets called although
> > > device does not interrupt
> > > >
> > > >
> > > > Thanks for the quick reply. Actually initially
> I
> > > was reading the status
> > > > register of my device and verifying whether it
> is
> > > my interrupt or not. But
> > > > even then, it would always tell me that I have
> an
> > > interrupt although I am
> > > > sure that my device is not interrupting. ( My
> > > device is a FIFO card. It
> > > > needs to be connected to a testor which sends
> data
> > > to it. Only after the
> > > > FIFO is half full, it sends an interrupt. As
> of
> > > now, I have not connected
> > > > the testor at all).
> > > >
> > > > Madhu
> > > >
> > > > On 06/06/01, ““Roddy, Mark”
> > > ” wrote:
> > > > > You need to very carefully re-read the DDK
> > > manual regarding how to
> > > > > process interrupts. You only return TRUE if
> the
> > > interrupt is for you.
> > > > > You have to use a hardware specific
> mechanism to
> > > determine if the
> > > > > interrupt is for you. Testing your device
> > > extension does not help -
> > > > > that simply validates that the device object
> is
> > > your device object. If
> > > > > it wasn’t your device object you should
> bugcheck
> > > as the operating
> > > > > system is seriously compromised. As you are
> > > sharing interrupts (and
> > > > > that is very normal for PCI devices,) it is
> very
> > > likely that your ISR
> > > > > will be invoked a lot when the interrupt is
> NOT
> > > from your device. The
> > > > > OS has no idea who requested the interrupt,
> it
> > > just calls in turn each
> > > > > ISR linked to the same interrupt vector.
> > > > >
> > > > > Generally your hardware will have some
> status
> > > register that will have
> > > > > a bit that is asserted when the device has
> > > requested an interrupt.
> > > > > Like I said, this is hardware specific, I
> can’t
> > > tell you which
> > > > > register it is, but unless your PCI device
> is
> > > seriously brain-dead, it
> > > > > has such a register. Your ISR should look at
> > > this register in order to
> > > > > decide if the interrupt is for your device.
> If
> > > it is then you will be
> > > > > returning TRUE from your ISR, otherwise you
> will
> > > be returning FALSE.
> > > > >
> > > > > But wait! There’s more! If it is your
> interrupt,
> > > you absolutely have
> > > > > to tell your device to shut up (stop
> asserting
> > > an interrupt,) or you
> > > > > will just be back in your ISR again as soon
> as
>
=== message truncated ===

__________________________________________________
Do You Yahoo!?
Get personalized email addresses from Yahoo! Mail - only $35
a year! http://personal.mail.yahoo.com/


You are currently subscribed to ntdev as: $subst(‘Recip.EmailAddr’)
To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com

Madhu,

If this hang is narrowed down such that it only appears exactly on the read
of the status port, I’d recommend going to the hardware folks or looking at
what’s on the PCI bus with a logic analyzer. Sounds like hardware/firmware
to me given that information.

-Tim

Timothy A. Johns — xxxxx@driverdev.com
Driver Development Corporation — 800.841.0092
Bring Up Your Hardware — Fast. www.driverdev.com

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com]On Behalf Of M V
Sent: Tuesday, June 12, 2001 10:01 AM
To: NT Developers Interest List
Subject: [ntdev] RE: ISR gets called although device does not interrupt

Hi Tim.

My device is accessing an interrupt that seems to be
shared by all PCI devices including a network adapter.

  1. When I boot the system, my ISR gets a lot of
    interrupts from other devices as well, probably
    because it may be among the the first ISRs available
    in that interrupt vector chain. When my device ( a
    FIFO card which sends an interrupt every time it is
    half full) starts sending interrupts, in between these
    interrupts I get interrupts from other devices as
    well. After some time, the machine just freezes
    although the device still is interrupting. It freezes
    at the point where I am trying to read a status
    register of the device to determine whether it is my
    interrupt or not.

  2. When I install the driver and then send interrupts
    from the device( without rebooting), my ISR gets only
    the interrupts that are meant for my device and
    nothing else. Probably this is because my ISR is the
    last in the interrupt vector chain for that particular
    interrupt. In this case everything works fine.

Is there any way to make sure that my ISR is the last
ISR available in that interrupt vector chain ? Or is
there any way to make sure that I use an interrupt
which is not shared by other devices ?

Thanks for all help

Madhu
— “Timothy A. Johns” wrote:
> > Madhu,
> >
> > That ‘hang’ sounds like an unhandled PCI interrupt.
> > Is your ISR being
> > called repeatedly while this hang is occuring, and
> > if so, can you verify
> > 100% (using a logic analyzer or oscilliscope, if
> > you’re going to have to
> > take your evidence to the proverbial hardware
> > person) that your device is
> > not asserting the interrupt?
> >
> > Also, it could be a PCI bus access problem, or
> > either a master or target
> > abort. It’s also possible that it may be that your
> > driver is getting an
> > interrupt that a different device is already using,
> > and the ‘other’ device
> > is not sharing it properly, but I’d view that as a
> > last resort, since the
> > driver you added is new and changing the behavior.
> > You can move it to a
> > different slot and if the problem goes away or
> > changes, the problem is very
> > likely in either your driver’s ISR or some other
> > device’s ISR.
> >
> > In any case, the registry entries for Start and
> > LoadOrderGroup that you have
> > below are almost certainly correct for a PnP driver.
> >
> > -Tim
> >
> > Timothy A. Johns — xxxxx@driverdev.com
> > Driver Development Corporation — 800.841.0092
> > Bring Up Your Hardware — Fast. www.driverdev.com
> >
> >
> > > -----Original Message-----
> > > From: xxxxx@lists.osr.com
> > > [mailto:xxxxx@lists.osr.com]On Behalf
> > Of M V
> > > Sent: Tuesday, June 12, 2001 5:50 AM
> > > To: NT Developers Interest List
> > > Subject: [ntdev] ISR gets called although device
> > does not interrupt
> > >
> > >
> > > In continuation with the last message, my ISR is
> > > working fine now. But I am facing a strange
> > problem. I
> > > install the WDM (without booting after
> > > installation)and send data to my FIFO device so
> > that
> > > it interrupts. I receive all the interrupts and
> > read
> > > all data. Everything is fine. But if I boot my
> > machine
> > > anytime after installation and then send data to
> > the
> > > device so that it interrupts, I receive some
> > > interrupts and after that the machine hangs. Why
> > would
> > > this be happening ? Is there any problem in my
> > > installation ? I have decared my service to be of
> > > SERVICE_DEMAND_START and have not specified
> > anything
> > > in the LoadOrderGroup.Can this be a problem ?
> > >
> > > Thanks for all help
> > > Madhu
> > >
> > > > On 06/06/01, ““Roddy, Mark”
> > > > ” wrote:
> > > > > Well that sounds very much like you are not
> > > > looking at the correct location
> > > > > for this status register, or you are looking
> > at
> > > > the correct location and
> > > > > have not interpreted the interrupt reason
> > > > correctly and not done the proper
> > > > > handshaking with your device to convince it to
> > > > stop generating an interrupt.
> > > > >
> > > > > The fact that when you return FALSE the system
> > > > works correctly argues for
> > > > > the case that you are looking at the wrong
> > > > locations on the PCI bus for your
> > > > > status register. You are of course talking
> > about
> > > > some register located off
> > > > > of BAR0 or BAR1, right? Not some value in the
> > > > config space for your device?
> > > > > And you did do all the right things to obtain
> > the
> > > > NT safe ‘translated’
> > > > > resource addresses, rather than using raw
> > values,
> > > > right? And finally you are
> > > > > of course using the HAL API to access your
> > device
> > > > rather than using raw
> > > > > pointers, right?
> > > > >
> > > > > It is also possible that your device has
> > > > malfunctioned, but as I said the
> > > > > fact that when you do not process the
> > interrupt
> > > > (you return FALSE) the
> > > > > system behaves normally, strongly suggests
> > that
> > > > your ISR is defective.
> > > > >
> > > > >
> > > > > -----Original Message-----
> > > > > From: xxxxx@yahoo.com [mailto:xxxxx@yahoo.com]
> > > > > Sent: Wednesday, June 06, 2001 9:19 AM
> > > > > To: NT Developers Interest List
> > > > > Subject: [ntdev] RE: ISR gets called although
> > > > device does not interrupt
> > > > >
> > > > >
> > > > > Thanks for the quick reply. Actually initially
> > I
> > > > was reading the status
> > > > > register of my device and verifying whether it
> > is
> > > > my interrupt or not. But
> > > > > even then, it would always tell me that I have
> > an
> > > > interrupt although I am
> > > > > sure that my device is not interrupting. ( My
> > > > device is a FIFO card. It
> > > > > needs to be connected to a testor which sends
> > data
> > > > to it. Only after the
> > > > > FIFO is half full, it sends an interrupt. As
> > of
> > > > now, I have not connected
> > > > > the testor at all).
> > > > >
> > > > > Madhu
> > > > >
> > > > > On 06/06/01, ““Roddy, Mark”
> > > > ” wrote:
> > > > > > You need to very carefully re-read the DDK
> > > > manual regarding how to
> > > > > > process interrupts. You only return TRUE if
> > the
> > > > interrupt is for you.
> > > > > > You have to use a hardware specific
> > mechanism to
> > > > determine if the
> > > > > > interrupt is for you. Testing your device
> > > > extension does not help -
> > > > > > that simply validates that the device object
> > is
> > > > your device object. If
> > > > > > it wasn’t your device object you should
> > bugcheck
> > > > as the operating
> > > > > > system is seriously compromised. As you are
> > > > sharing interrupts (and
> > > > > > that is very normal for PCI devices,) it is
> > very
> > > > likely that your ISR
> > > > > > will be invoked a lot when the interrupt is
> > NOT
> > > > from your device. The
> > > > > > OS has no idea who requested the interrupt,
> > it
> > > > just calls in turn each
> > > > > > ISR linked to the same interrupt vector.
> > > > > >
> > > > > > Generally your hardware will have some
> > status
> > > > register that will have
> > > > > > a bit that is asserted when the device has
> > > > requested an interrupt.
> > > > > > Like I said, this is hardware specific, I
> > can’t
> > > > tell you which
> > > > > > register it is, but unless your PCI device
> > is
> > > > seriously brain-dead, it
> > > > > > has such a register. Your ISR should look at
> > > > this register in order to
> > > > > > decide if the interrupt is for your device.
> > If
> > > > it is then you will be
> > > > > > returning TRUE from your ISR, otherwise you
> > will
> > > > be returning FALSE.
> > > > > >
> > > > > > But wait! There’s more! If it is your
> > interrupt,
> > > > you absolutely have
> > > > > > to tell your device to shut up (stop
> > asserting
> > > > an interrupt,) or you
> > > > > > will just be back in your ISR again as soon
> > as
> >
> === message truncated ===
>
>
> __________________________________________________
> Do You Yahoo!?
> Get personalized email addresses from Yahoo! Mail - only $35
> a year! http://personal.mail.yahoo.com/
>
> —
> You are currently subscribed to ntdev as: xxxxx@driverdev.com
> To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com
>


You are currently subscribed to ntdev as: $subst(‘Recip.EmailAddr’)
To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com

If you suspect that it’s PCI interrupt sharing, you can
make your driver to use one interrupt that it’s not used
by other PCI devices in your system and reserve that
Interrupt in BIOS settings and then when ur driver comes
up it would be having exclusive access to that
Interrupt.
Otherway of achieveing this, not to share the
interrupt at all. Just check out the API that u use to
register your ISR and rest with OS. But in principle PCI
should be able to share interrupts with other PCI
peripherals.
Please let us know about these.

  1. What type of device is this?
  2. R u checking status register directly in your ISR or
    in a DPC?

thanks


Girish H.

Madhu,

If this hang is narrowed down such that it only appears exactly on the read
of the status port, I’d recommend going to the hardware folks or looking at
what’s on the PCI bus with a logic analyzer. Sounds like hardware/firmware
to me given that information.

-Tim

Timothy A. Johns — xxxxx@driverdev.com
Driver Development Corporation — 800.841.0092
Bring Up Your Hardware — Fast. www.driverdev.com

> -----Original Message-----
> From: xxxxx@lists.osr.com
> [mailto:xxxxx@lists.osr.com]On Behalf Of M V
> Sent: Tuesday, June 12, 2001 10:01 AM
> To: NT Developers Interest List
> Subject: [ntdev] RE: ISR gets called although device does not interrupt
>
>
> Hi Tim.
>
> My device is accessing an interrupt that seems to be
> shared by all PCI devices including a network adapter.
>
> 1. When I boot the system, my ISR gets a lot of
> interrupts from other devices as well, probably
> because it may be among the the first ISRs available
> in that interrupt vector chain. When my device ( a
> FIFO card which sends an interrupt every time it is
> half full) starts sending interrupts, in between these
> interrupts I get interrupts from other devices as
> well. After some time, the machine just freezes
> although the device still is interrupting. It freezes
> at the point where I am trying to read a status
> register of the device to determine whether it is my
> interrupt or not.
>
> 2. When I install the driver and then send interrupts
> from the device( without rebooting), my ISR gets only
> the interrupts that are meant for my device and
> nothing else. Probably this is because my ISR is the
> last in the interrupt vector chain for that particular
> interrupt. In this case everything works fine.
>
> Is there any way to make sure that my ISR is the last
> ISR available in that interrupt vector chain ? Or is
> there any way to make sure that I use an interrupt
> which is not shared by other devices ?
>
> Thanks for all help
>
> Madhu
> — “Timothy A. Johns” wrote:
> > > Madhu,
> > >
> > > That ‘hang’ sounds like an unhandled PCI interrupt.
> > > Is your ISR being
> > > called repeatedly while this hang is occuring, and
> > > if so, can you verify
> > > 100% (using a logic analyzer or oscilliscope, if
> > > you’re going to have to
> > > take your evidence to the proverbial hardware
> > > person) that your device is
> > > not asserting the interrupt?
> > >
> > > Also, it could be a PCI bus access problem, or
> > > either a master or target
> > > abort. It’s also possible that it may be that your
> > > driver is getting an
> > > interrupt that a different device is already using,
> > > and the ‘other’ device
> > > is not sharing it properly, but I’d view that as a
> > > last resort, since the
> > > driver you added is new and changing the behavior.
> > > You can move it to a
> > > different slot and if the problem goes away or
> > > changes, the problem is very
> > > likely in either your driver’s ISR or some other
> > > device’s ISR.
> > >
> > > In any case, the registry entries for Start and
> > > LoadOrderGroup that you have
> > > below are almost certainly correct for a PnP driver.
> > >
> > > -Tim
> > >
> > > Timothy A. Johns — xxxxx@driverdev.com
> > > Driver Development Corporation — 800.841.0092
> > > Bring Up Your Hardware — Fast. www.driverdev.com
> > >
> > >
> > > > -----Original Message-----
> > > > From: xxxxx@lists.osr.com
> > > > [mailto:xxxxx@lists.osr.com]On Behalf
> > > Of M V
> > > > Sent: Tuesday, June 12, 2001 5:50 AM
> > > > To: NT Developers Interest List
> > > > Subject: [ntdev] ISR gets called although device
> > > does not interrupt
> > > >
> > > >
> > > > In continuation with the last message, my ISR is
> > > > working fine now. But I am facing a strange
> > > problem. I
> > > > install the WDM (without booting after
> > > > installation)and send data to my FIFO device so
> > > that
> > > > it interrupts. I receive all the interrupts and
> > > read
> > > > all data. Everything is fine. But if I boot my
> > > machine
> > > > anytime after installation and then send data to
> > > the
> > > > device so that it interrupts, I receive some
> > > > interrupts and after that the machine hangs. Why
> > > would
> > > > this be happening ? Is there any problem in my
> > > > installation ? I have decared my service to be of
> > > > SERVICE_DEMAND_START and have not specified
> > > anything
> > > > in the LoadOrderGroup.Can this be a problem ?
> > > >
> > > > Thanks for all help
> > > > Madhu
> > > >
> > > > > On 06/06/01, ““Roddy, Mark”
> > > > > ” wrote:
> > > > > > Well that sounds very much like you are not
> > > > > looking at the correct location
> > > > > > for this status register, or you are looking
> > > at
> > > > > the correct location and
> > > > > > have not interpreted the interrupt reason
> > > > > correctly and not done the proper
> > > > > > handshaking with your device to convince it to
> > > > > stop generating an interrupt.
> > > > > >
> > > > > > The fact that when you return FALSE the system
> > > > > works correctly argues for
> > > > > > the case that you are looking at the wrong
> > > > > locations on the PCI bus for your
> > > > > > status register. You are of course talking
> > > about
> > > > > some register located off
> > > > > > of BAR0 or BAR1, right? Not some value in the
> > > > > config space for your device?
> > > > > > And you did do all the right things to obtain
> > > the
> > > > > NT safe ‘translated’
> > > > > > resource addresses, rather than using raw
> > > values,
> > > > > right? And finally you are
> > > > > > of course using the HAL API to access your
> > > device
> > > > > rather than using raw
> > > > > > pointers, right?
> > > > > >
> > > > > > It is also possible that your device has
> > > > > malfunctioned, but as I said the
> > > > > > fact that when you do not process the
> > > interrupt
> > > > > (you return FALSE) the
> > > > > > system behaves normally, strongly suggests
> > > that
> > > > > your ISR is defective.
> > > > > >
> > > > > >
> > > > > > -----Original Message-----
> > > > > > From: xxxxx@yahoo.com [mailto:xxxxx@yahoo.com]
> > > > > > Sent: Wednesday, June 06, 2001 9:19 AM
> > > > > > To: NT Developers Interest List
> > > > > > Subject: [ntdev] RE: ISR gets called although
> > > > > device does not interrupt
> > > > > >
> > > > > >
> > > > > > Thanks for the quick reply. Actually initially
> > > I
> > > > > was reading the status
> > > > > > register of my device and verifying whether it
> > > is
> > > > > my interrupt or not. But
> > > > > > even then, it would always tell me that I have
> > > an
> > > > > interrupt although I am
> > > > > > sure that my device is not interrupting. ( My
> > > > > device is a FIFO card. It
> > > > > > needs to be connected to a testor which sends
> > > data
> > > > > to it. Only after the
> > > > > > FIFO is half full, it sends an interrupt. As
> > > of
> > > > > now, I have not connected
> > > > > > the testor at all).
> > > > > >
> > > > > > Madhu
> > > > > >
> > > > > > On 06/06/01, ““Roddy, Mark”
> > > > > ” wrote:
> > > > > > > You need to very carefully re-read the DDK
> > > > > manual regarding how to
> > > > > > > process interrupts. You only return TRUE if
> > > the
> > > > > interrupt is for you.
> > > > > > > You have to use a hardware specific
> > > mechanism to
> > > > > determine if the
> > > > > > > interrupt is for you. Testing your device
> > > > > extension does not help -
> > > > > > > that simply validates that the device object
> > > is
> > > > > your device object. If
> > > > > > > it wasn’t your device object you should
> > > bugcheck
> > > > > as the operating
> > > > > > > system is seriously compromised. As you are
> > > > > sharing interrupts (and
> > > > > > > that is very normal for PCI devices,) it is
> > > very
> > > > > likely that your ISR
> > > > > > > will be invoked a lot when the interrupt is
> > > NOT
> > > > > from your device. The
> > > > > > > OS has no idea who requested the interrupt,
> > > it
> > > > > just calls in turn each
> > > > > > > ISR linked to the same interrupt vector.
> > > > > > >
> > > > > > > Generally your hardware will have some
> > > status
> > > > > register that will have
> > > > > > > a bit that is asserted when the device has
> > > > > requested an interrupt.
> > > > > > > Like I said, this is hardware specific, I
> > > can’t
> > > > > tell you which
> > > > > > > register it is, but unless your PCI device
> > > is
> > > > > seriously brain-dead, it
> > > > > > > has such a register. Your ISR should look at
> > > > > this register in order to
> > > > > > > decide if the interrupt is for your device.
> > > If
> > > > > it is then you will be
> > > > > > > returning TRUE from your ISR, otherwise you
> > > will
> > > > > be returning FALSE.
> > > > > > >
> > > > > > > But wait! There’s more! If it is your
> > > interrupt,
> > > > > you absolutely have
> > > > > > > to tell your device to shut up (stop
> > > asserting
> > > > > an interrupt,) or you
> > > > > > > will just be back in your ISR again as soon
> > > as
> > >
> > === message truncated ===
> >
> >
> > __________________________________________________
> > Do You Yahoo!?
> > Get personalized email addresses from Yahoo! Mail - only $35
> > a year! http://personal.mail.yahoo.com/
> >
> > —
> > You are currently subscribed to ntdev as: xxxxx@driverdev.com
> > To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com
> >
>
>
> —
> You are currently subscribed to ntdev as: xxxxx@att.net
> To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com


You are currently subscribed to ntdev as: $subst(‘Recip.EmailAddr’)
To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com

My machine has ACPI installed on it, which I think is
responsible for interrupt sharing by PCI devices. When
I call IoCOnnectInterrupt(), for the ShareVector
parameter, I just use the parameter
pPartialDescriptor->ShareDisposition, which is given
by the
PnPManager. How do I reserve an interrupt for myself
in the BIOS setting ?

Thanks
Madhu

xxxxx@att.net wrote:

If you suspect that it’s PCI interrupt sharing, you
can
make your driver to use one interrupt that it’s not
used
by other PCI devices in your system and reserve that

Interrupt in BIOS settings and then when ur driver
comes
up it would be having exclusive access to that
Interrupt.
Otherway of achieveing this, not to share the
interrupt at all. Just check out the API that u use
to
register your ISR and rest with OS. But in principle
PCI
should be able to share interrupts with other PCI
peripherals.
Please let us know about these.

  1. What type of device is this?
  2. R u checking status register directly in your ISR
    or
    in a DPC?

thanks


Girish H.
> Madhu,
>
> If this hang is narrowed down such that it only
appears exactly on the read
> of the status port, I’d recommend going to the
hardware folks or looking at
> what’s on the PCI bus with a logic analyzer.
Sounds like hardware/firmware
> to me given that information.
>
> -Tim
>
>
> Timothy A. Johns — xxxxx@driverdev.com
> Driver Development Corporation — 800.841.0092
> Bring Up Your Hardware — Fast. www.driverdev.com
>
>
> > -----Original Message-----
> > From: xxxxx@lists.osr.com
> > [mailto:xxxxx@lists.osr.com]On
Behalf Of M V
> > Sent: Tuesday, June 12, 2001 10:01 AM
> > To: NT Developers Interest List
> > Subject: [ntdev] RE: ISR gets called although
device does not interrupt
> >
> >
> > Hi Tim.
> >
> > My device is accessing an interrupt that seems
to be
> > shared by all PCI devices including a network
adapter.
> >
> > 1. When I boot the system, my ISR gets a lot of
> > interrupts from other devices as well, probably
> > because it may be among the the first ISRs
available
> > in that interrupt vector chain. When my device (
a
> > FIFO card which sends an interrupt every time it
is
> > half full) starts sending interrupts, in between
these
> > interrupts I get interrupts from other devices
as
> > well. After some time, the machine just freezes
> > although the device still is interrupting. It
freezes
> > at the point where I am trying to read a status
> > register of the device to determine whether it
is my
> > interrupt or not.
> >
> > 2. When I install the driver and then send
interrupts
> > from the device( without rebooting), my ISR gets
only
> > the interrupts that are meant for my device and
> > nothing else. Probably this is because my ISR is
the
> > last in the interrupt vector chain for that
particular
> > interrupt. In this case everything works fine.
> >
> > Is there any way to make sure that my ISR is the
last
> > ISR available in that interrupt vector chain ?
Or is
> > there any way to make sure that I use an
interrupt
> > which is not shared by other devices ?
> >
> > Thanks for all help
> >
> > Madhu
> > — “Timothy A. Johns”
> wrote:
> > > > Madhu,
> > > >
> > > > That ‘hang’ sounds like an unhandled PCI
> interrupt.
> > > > Is your ISR being
> > > > called repeatedly while this hang is occuring,
> and
> > > > if so, can you verify
> > > > 100% (using a logic analyzer or oscilliscope,
> if
> > > > you’re going to have to
> > > > take your evidence to the proverbial hardware
> > > > person) that your device is
> > > > not asserting the interrupt?
> > > >
> > > > Also, it could be a PCI bus access problem, or
> > > > either a master or target
> > > > abort. It’s also possible that it may be that
> your
> > > > driver is getting an
> > > > interrupt that a different device is already
> using,
> > > > and the ‘other’ device
> > > > is not sharing it properly, but I’d view that
> as a
> > > > last resort, since the
> > > > driver you added is new and changing the
> behavior.
> > > > You can move it to a
> > > > different slot and if the problem goes away or
> > > > changes, the problem is very
> > > > likely in either your driver’s ISR or some
> other
> > > > device’s ISR.
> > > >
> > > > In any case, the registry entries for Start
> and
> > > > LoadOrderGroup that you have
> > > > below are almost certainly correct for a PnP
> driver.
> > > >
> > > > -Tim
> > > >
> > > > Timothy A. Johns — xxxxx@driverdev.com
> > > > Driver Development Corporation —
> 800.841.0092
> > > > Bring Up Your Hardware — Fast.
> www.driverdev.com
> > > >
> > > >
> > > > > -----Original Message-----
> > > > > From: xxxxx@lists.osr.com
> > > > > [mailto:xxxxx@lists.osr.com]On
> Behalf
> > > > Of M V
> > > > > Sent: Tuesday, June 12, 2001 5:50 AM
> > > > > To: NT Developers Interest List
> > > > > Subject: [ntdev] ISR gets called although
> device
> > > > does not interrupt
> > > > >
> > > > >
> > > > > In continuation with the last message, my
> ISR is
> > > > > working fine now. But I am facing a strange
> > > > problem. I
> > > > > install the WDM (without booting after
> > > > > installation)and send data to my FIFO device
> so
> > > > that
> > > > > it interrupts. I receive all the interrupts
> and
> > > > read
> > > > > all data. Everything is fine. But if I boot
> my
> > > > machine
> > > > > anytime after installation and then send
> data to
> > > > the
> > > > > device so that it interrupts, I receive some
> > > > > interrupts and after that the machine hangs.
> Why
> > > > would
> > > > > this be happening ? Is there any problem in
> my
> > > > > installation ? I have decared my service to
> be of
> > > > > SERVICE_DEMAND_START and have not specified
> > > > anything
> > > > > in the LoadOrderGroup.Can this be a problem
> ?
> > > > >
> > > > > Thanks for all help
> > > > > Madhu
> > > > >
>
=== message truncated ===

__________________________________________________
Do You Yahoo!?
Get personalized email addresses from Yahoo! Mail - only $35
a year! http://personal.mail.yahoo.com/


You are currently subscribed to ntdev as: $subst(‘Recip.EmailAddr’)
To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com

  1. This is a FIFO card to which a testor sends data.
    Every time the FIFO is half full, it sends an
    interrupt.

2.I am checking status register directly in the ISR.

This is how my ISR looks like…

BOOLEAN FifoIsr( IN PKINTERRUPT pIntObj, IN PVOID
pServiceContext )
{
PDEVICE_EXTENSION pDevExt ;
ULONG ulFifoState = 0,ulCumWordsHwCnt=0, ulIrqType
= 0;

pDevExt = (PDEVICE_EXTENSION)pServiceContext ;

if ( pDevExt->bStatusFlag)/*This is initialised to
TRUE*/
{
pDevExt->bStatusFlag = FALSE ;
ulFifoState =
MAC_READSTATUS(pDevExt->pMemRegs);/*calls
READ_REGISTER_ULONG to read status register*/
}
if (ulFifoState != ulMyInterrupt)
{
/*Not our interrupt*/
pDevExt->bStatusFlag = TRUE ;
return (FALSE) ;
}
DbgPrint (“FIFO5W: My interrupt \n”);
pDevExt->bStatusFlag = TRUE ;
EnableDeviceInterrupt(pDevExt);/*Enabling the device
to interrupt again by writing to the control
register*/
return TRUE;
}

xxxxx@att.net wrote:

If you suspect that it’s PCI interrupt sharing, you
can
make your driver to use one interrupt that it’s not
used
by other PCI devices in your system and reserve that

Interrupt in BIOS settings and then when ur driver
comes
up it would be having exclusive access to that
Interrupt.
Otherway of achieveing this, not to share the
interrupt at all. Just check out the API that u use
to
register your ISR and rest with OS. But in principle
PCI
should be able to share interrupts with other PCI
peripherals.
Please let us know about these.

  1. What type of device is this?
  2. R u checking status register directly in your ISR
    or
    in a DPC?

thanks


Girish H.
> Madhu,
>
> If this hang is narrowed down such that it only
appears exactly on the read
> of the status port, I’d recommend going to the
hardware folks or looking at
> what’s on the PCI bus with a logic analyzer.
Sounds like hardware/firmware
> to me given that information.
>
> -Tim
>
>
> Timothy A. Johns — xxxxx@driverdev.com
> Driver Development Corporation — 800.841.0092
> Bring Up Your Hardware — Fast. www.driverdev.com
>
>
> > -----Original Message-----
> > From: xxxxx@lists.osr.com
> > [mailto:xxxxx@lists.osr.com]On
Behalf Of M V
> > Sent: Tuesday, June 12, 2001 10:01 AM
> > To: NT Developers Interest List
> > Subject: [ntdev] RE: ISR gets called although
device does not interrupt
> >
> >
> > Hi Tim.
> >
> > My device is accessing an interrupt that seems
to be
> > shared by all PCI devices including a network
adapter.
> >
> > 1. When I boot the system, my ISR gets a lot of
> > interrupts from other devices as well, probably
> > because it may be among the the first ISRs
available
> > in that interrupt vector chain. When my device (
a
> > FIFO card which sends an interrupt every time it
is
> > half full) starts sending interrupts, in between
these
> > interrupts I get interrupts from other devices
as
> > well. After some time, the machine just freezes
> > although the device still is interrupting. It
freezes
> > at the point where I am trying to read a status
> > register of the device to determine whether it
is my
> > interrupt or not.
> >
> > 2. When I install the driver and then send
interrupts
> > from the device( without rebooting), my ISR gets
only
> > the interrupts that are meant for my device and
> > nothing else. Probably this is because my ISR is
the
> > last in the interrupt vector chain for that
particular
> > interrupt. In this case everything works fine.
> >
> > Is there any way to make sure that my ISR is the
last
> > ISR available in that interrupt vector chain ?
Or is
> > there any way to make sure that I use an
interrupt
> > which is not shared by other devices ?
> >
> > Thanks for all help
> >
> > Madhu
> > — “Timothy A. Johns”
> wrote:
> > > > Madhu,
> > > >
> > > > That ‘hang’ sounds like an unhandled PCI
> interrupt.
> > > > Is your ISR being
> > > > called repeatedly while this hang is occuring,
> and
> > > > if so, can you verify
> > > > 100% (using a logic analyzer or oscilliscope,
> if
> > > > you’re going to have to
> > > > take your evidence to the proverbial hardware
> > > > person) that your device is
> > > > not asserting the interrupt?
> > > >
> > > > Also, it could be a PCI bus access problem, or
> > > > either a master or target
> > > > abort. It’s also possible that it may be that
> your
> > > > driver is getting an
> > > > interrupt that a different device is already
> using,
> > > > and the ‘other’ device
> > > > is not sharing it properly, but I’d view that
> as a
> > > > last resort, since the
> > > > driver you added is new and changing the
> behavior.
> > > > You can move it to a
> > > > different slot and if the problem goes away or
> > > > changes, the problem is very
> > > > likely in either your driver’s ISR or some
> other
> > > > device’s ISR.
> > > >
> > > > In any case, the registry entries for Start
> and
> > > > LoadOrderGroup that you have
> > > > below are almost certainly correct for a PnP
> driver.
> > > >
> > > > -Tim
> > > >
> > > > Timothy A. Johns — xxxxx@driverdev.com
> > > > Driver Development Corporation —
> 800.841.0092
> > > > Bring Up Your Hardware — Fast.
> www.driverdev.com
> > > >
> > > >
> > > > > -----Original Message-----
> > > > > From: xxxxx@lists.osr.com
> > > > > [mailto:xxxxx@lists.osr.com]On
> Behalf
> > > > Of M V
> > > > > Sent: Tuesday, June 12, 2001 5:50 AM
> > > > > To: NT Developers Interest List
> > > > > Subject: [ntdev] ISR gets called although
> device
> > > > does not interrupt
> > > > >
> > > > >
> > > > > In continuation with the last message, my
> ISR is
> > > > > working fine now. But I am facing a strange
> > > > problem. I
> > > > > install the WDM (without booting after
> > > > > installation)and send data to my FIFO device
> so
> > > > that
> > > > > it interrupts. I receive all the interrupts
> and
> > > > read
> > > > > all data. Everything is fine. But if I boot
> my
> > > > machine
> > > > > anytime after installation and then send
> data to
> > > > the
> > > > > device so that it interrupts, I receive some
> > > > > interrupts and after that the machine hangs.
> Why
> > > > would
> > > > > this be happening ? Is there any problem in
> my
> > > > > installation ? I have decared my service to
> be of
> > > > > SERVICE_DEMAND_START and have not specified
> > > > anything
> > > > > in the LoadOrderGroup.Can this be a problem
> ?
> > > > >
> > > > > Thanks for all help
> > > > > Madhu
> > > > >
>
=== message truncated ===

__________________________________________________
Do You Yahoo!?
Get personalized email addresses from Yahoo! Mail - only $35
a year! http://personal.mail.yahoo.com/


You are currently subscribed to ntdev as: $subst(‘Recip.EmailAddr’)
To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com

PCI interrupt sharing is a function of the PCI specification itself and the
physical layout of the motherboard, not ACPI. An ACPI compliant motherboard
(particularly one with an EC) is likely to share interrupts, but it’s also
perfectly legal and very likely on a non-ACPI machine.

(with some notable exceptions WRT legacy hard drive interfaces…) If the
device cannot share interrupts, it is not fair to call it a PCI device -
it’s just a device that happens to be plugged into a PCI bus.

I’d keep pushing your supplier for a hardware fix - if it can’t share
interrupts, this hardware is just not correct PCI.

-Tim

Timothy A. Johns — xxxxx@driverdev.com
Driver Development Corporation — 800.841.0092
Bring Up Your Hardware — Fast. www.driverdev.com

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com]On Behalf Of M V
Sent: Wednesday, June 13, 2001 5:25 AM
To: NT Developers Interest List
Subject: [ntdev] RE: ISR gets called although device does not interrupt

My machine has ACPI installed on it, which I think is
responsible for interrupt sharing by PCI devices. When
I call IoCOnnectInterrupt(), for the ShareVector
parameter, I just use the parameter
pPartialDescriptor->ShareDisposition, which is given
by the
PnPManager. How do I reserve an interrupt for myself
in the BIOS setting ?

Thanks
Madhu

xxxxx@att.net wrote:
> If you suspect that it’s PCI interrupt sharing, you
> can
> make your driver to use one interrupt that it’s not
> used
> by other PCI devices in your system and reserve that
>
> Interrupt in BIOS settings and then when ur driver
> comes
> up it would be having exclusive access to that
> Interrupt.
> Otherway of achieveing this, not to share the
> interrupt at all. Just check out the API that u use
> to
> register your ISR and rest with OS. But in principle
> PCI
> should be able to share interrupts with other PCI
> peripherals.
> Please let us know about these.
> 1. What type of device is this?
> 2. R u checking status register directly in your ISR
> or
> in a DPC?
>
> thanks
>
> –
> Girish H.
> > Madhu,
> >
> > If this hang is narrowed down such that it only
> appears exactly on the read
> > of the status port, I’d recommend going to the
> hardware folks or looking at
> > what’s on the PCI bus with a logic analyzer.
> Sounds like hardware/firmware
> > to me given that information.
> >
> > -Tim
> >
> >
> > Timothy A. Johns — xxxxx@driverdev.com
> > Driver Development Corporation — 800.841.0092
> > Bring Up Your Hardware — Fast. www.driverdev.com
> >
> >
> > > -----Original Message-----
> > > From: xxxxx@lists.osr.com
> > > [mailto:xxxxx@lists.osr.com]On
> Behalf Of M V
> > > Sent: Tuesday, June 12, 2001 10:01 AM
> > > To: NT Developers Interest List
> > > Subject: [ntdev] RE: ISR gets called although
> device does not interrupt
> > >
> > >
> > > Hi Tim.
> > >
> > > My device is accessing an interrupt that seems
> to be
> > > shared by all PCI devices including a network
> adapter.
> > >
> > > 1. When I boot the system, my ISR gets a lot of
> > > interrupts from other devices as well, probably
> > > because it may be among the the first ISRs
> available
> > > in that interrupt vector chain. When my device (
> a
> > > FIFO card which sends an interrupt every time it
> is
> > > half full) starts sending interrupts, in between
> these
> > > interrupts I get interrupts from other devices
> as
> > > well. After some time, the machine just freezes
> > > although the device still is interrupting. It
> freezes
> > > at the point where I am trying to read a status
> > > register of the device to determine whether it
> is my
> > > interrupt or not.
> > >
> > > 2. When I install the driver and then send
> interrupts
> > > from the device( without rebooting), my ISR gets
> only
> > > the interrupts that are meant for my device and
> > > nothing else. Probably this is because my ISR is
> the
> > > last in the interrupt vector chain for that
> particular
> > > interrupt. In this case everything works fine.
> > >
> > > Is there any way to make sure that my ISR is the
> last
> > > ISR available in that interrupt vector chain ?
> Or is
> > > there any way to make sure that I use an
> interrupt
> > > which is not shared by other devices ?
> > >
> > > Thanks for all help
> > >
> > > Madhu
> > > — “Timothy A. Johns”
> > wrote:
> > > > > Madhu,
> > > > >
> > > > > That ‘hang’ sounds like an unhandled PCI
> > interrupt.
> > > > > Is your ISR being
> > > > > called repeatedly while this hang is occuring,
> > and
> > > > > if so, can you verify
> > > > > 100% (using a logic analyzer or oscilliscope,
> > if
> > > > > you’re going to have to
> > > > > take your evidence to the proverbial hardware
> > > > > person) that your device is
> > > > > not asserting the interrupt?
> > > > >
> > > > > Also, it could be a PCI bus access problem, or
> > > > > either a master or target
> > > > > abort. It’s also possible that it may be that
> > your
> > > > > driver is getting an
> > > > > interrupt that a different device is already
> > using,
> > > > > and the ‘other’ device
> > > > > is not sharing it properly, but I’d view that
> > as a
> > > > > last resort, since the
> > > > > driver you added is new and changing the
> > behavior.
> > > > > You can move it to a
> > > > > different slot and if the problem goes away or
> > > > > changes, the problem is very
> > > > > likely in either your driver’s ISR or some
> > other
> > > > > device’s ISR.
> > > > >
> > > > > In any case, the registry entries for Start
> > and
> > > > > LoadOrderGroup that you have
> > > > > below are almost certainly correct for a PnP
> > driver.
> > > > >
> > > > > -Tim
> > > > >
> > > > > Timothy A. Johns — xxxxx@driverdev.com
> > > > > Driver Development Corporation —
> > 800.841.0092
> > > > > Bring Up Your Hardware — Fast.
> > www.driverdev.com
> > > > >
> > > > >
> > > > > > -----Original Message-----
> > > > > > From: xxxxx@lists.osr.com
> > > > > > [mailto:xxxxx@lists.osr.com]On
> > Behalf
> > > > > Of M V
> > > > > > Sent: Tuesday, June 12, 2001 5:50 AM
> > > > > > To: NT Developers Interest List
> > > > > > Subject: [ntdev] ISR gets called although
> > device
> > > > > does not interrupt
> > > > > >
> > > > > >
> > > > > > In continuation with the last message, my
> > ISR is
> > > > > > working fine now. But I am facing a strange
> > > > > problem. I
> > > > > > install the WDM (without booting after
> > > > > > installation)and send data to my FIFO device
> > so
> > > > > that
> > > > > > it interrupts. I receive all the interrupts
> > and
> > > > > read
> > > > > > all data. Everything is fine. But if I boot
> > my
> > > > > machine
> > > > > > anytime after installation and then send
> > data to
> > > > > the
> > > > > > device so that it interrupts, I receive some
> > > > > > interrupts and after that the machine hangs.
> > Why
> > > > > would
> > > > > > this be happening ? Is there any problem in
> > my
> > > > > > installation ? I have decared my service to
> > be of
> > > > > > SERVICE_DEMAND_START and have not specified
> > > > > anything
> > > > > > in the LoadOrderGroup.Can this be a problem
> > ?
> > > > > >
> > > > > > Thanks for all help
> > > > > > Madhu
> > > > > >
> >
> === message truncated ===
>
>
> __________________________________________________
> Do You Yahoo!?
> Get personalized email addresses from Yahoo! Mail - only $35
> a year! http://personal.mail.yahoo.com/
>
> —
> You are currently subscribed to ntdev as: xxxxx@driverdev.com
> To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com
>


You are currently subscribed to ntdev as: $subst(‘Recip.EmailAddr’)
To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com