Re: pci RESUMING by David
David
Mon Oct 20 12:11:11 CDT 2003
In order system to resume. The Installable ISR which you loaded by
info.isrDllName & info.isrHandlerName need to return SysInter
(ISRInfo.SysIntr). Are you sure this happens during the suspend.
Usually Installable ISR will check interrupt register & interrupt mask
register in this card (hardware) to determine the interrupt happens or not.
Even there is IRQ, if your interrupt register & interrupt mask register does
not set during suspend, The Installable ISR will not return SysIntr which
system needed to wake up the system.
David Liao.
"Patrick Zou" <patrick_zou_nospam@hotmail.com> wrote in message
news:%23CHq10OlDHA.3256@tk2msftngp13.phx.gbl...
> I am using the sysIntr. And here are the codes to install ISR.
>
>
> intr.isrHandle = LoadIntChainHandler(info.isrDllName, info.isrHandlerName,
> (BYTE)info.irqNumber);
>
>
> // Set up ISR handler
> ISRInfo.SysIntr = info.systemIntr;
>
> ISRInfo.CheckPort = FALSE;
> ISRInfo.UseMaskReg = FALSE;
>
> if (!KernelLibIoControl(otg->intr.isrHandle, IOCTL_GIISR_INFO, &ISRInfo,
> sizeof(ISRInfo), NULL, 0, NULL))
> {
> DEBUGMSG(ZONE_ERROR, (L"OTG242: KernelLibIoControl call failed.\r\n"));
> }
>
>
>
> As for the interrupt line, no matter it is asserted all the time (when
> entering suspend) or asserted in suspend(remote wakeup), (I did see the
> interrupt line change in scope), but system can't resume.
>
> any comments,
> ying/
>
>
> "David Liao (MS)" <davli@online.microsoft.com> wrote in message
> news:OMh1k3MlDHA.3612@TK2MSFTNGP11.phx.gbl...
> > It depends on several thing.
> > If interrupt happens, static ISR will call Installable ISR. Installable
> ISR
> > will return SysIntr(Interrupt ID). This SysIntr will used against the
> > SysInter you use to setup wakeup source. If match, it wakeup system. if
> not,
> > it go to suspend again.
> > So. You should make sure,
> > 1. Use correct SysIntr (interrupt ID, it usually generated in Registry)
to
> > enable wakeup source.
> > 2. Installable ISR should return (Correct SysInter if there is
interrupt)
> > this SysInter when the interrupt happens.
> >
> > I saw your previous mail. It said the interrupt line is on and then off.
> PCI
> > is level trigger interrupt. The line should go off after IST serve the
> > interrupt. I am afraid of the Installable ISR does not detect the
> interrupt
> > during on/off situation.
> >
> > David Liao
> >
> > "Patrick Zou" <patrick_zou_nospam@hotmail.com> wrote in message
> > news:OkRIptClDHA.372@TK2MSFTNGP11.phx.gbl...
> > >
> > > I can see my PCI is asserting the IRQ line, but how come the OS is
not
> > > wakened up? I have called
> > >
> > > KernelIoControl(IOCTL_HAL_ENABLE_WAKE, &m_dwSysIntr,
> sizeof(m_dwSysIntr),
> > > NULL, 0, NULL);
> > >
> > > to associate my interrupt with the system wakeup sources. Any
> particuliar
> > > requirement on the PCI device, I am using a PLX as the bridge.
> > >
> > > any particuliar wrong?
> > >
> > > Ying/
> > >
> > >
> > > "Ten" <nick.bartolotti@tentechnologies.com> wrote in message
> > > news:KJwjb.33095$Hs.30478@twister.nyroc.rr.com...
> > > > Are you using GIIS? Perhaps the first PCI device is handled through
> > GIIS
> > > > and yours is not.
> > > >
> > > > Did you write a device driver for your PCI card? If so, then you
> should
> > > > have written an ISR and IST to handle all the interrupts. This
> routine
> > > > should be notified of any activity on the IRQ lines for your device.
> > > >
> > > > Once the IRQ is detected, you should be able to wake up the OS. I'm
> not
> > > > sure if you need to register your device driver with the OS so the
OS
> > > > recognizes it as a source for a resume instruction.
> > > >
> > > > Search for RequestPowerNotifications and SetSystemPowerState for
> > > information
> > > > on how to wake up the system from your driver.
> > > >
> > > > Nick.
> > > >
> > > >
> > > >
> > > > "Patrick Zou" <patrick_zou_nospam@hotmail.com> wrote in message
> > > > news:ON1agf3kDHA.1800@TK2MSFTNGP10.phx.gbl...
> > > > > In a CEPC enviroment, a PCI device could resume the system. I
guess
> > the
> > > > > resuming source is the interrupt line. If there is any signalling
on
> > the
> > > > > interrupt line, system could resume. ( I guess this is correct, I
> have
> > > > > suspected it could something related to the Isrinfo structure,
there
> > are
> > > 2
> > > > > fiedls called checkmask, and checkport, I commented this out, the
> > > resuming
> > > > > still works. That means, the only source is the interrupt line).
> > > > >
> > > > > OK, I have another PCI device, which is designed by us, there are
> some
> > > > > activities on ther interrupt line, but however, system dosn't
> resume?
> > so
> > > > Is
> > > > > there any requirement on the resuming signalling? like the
interrupt
> > has
> > > > to
> > > > > be long enought for X ms?
> > > > >
> > > > > thanks
> > > > > Ying/
> > > > >
> > > > >
> > > >
> > > >
> > >
> > >
> > >
> >
> >
>
>