Re: Another Ndis MinportXXX question
From: Pavel A. (pavel_a_at_NOwritemeNO.com)
Date: 01/16/05
- Next message: Vasu S: "Re: Supplemental Device Queues with Ke Insert/Remove DeviceQueue.."
- Previous message: Don Burn: "Re: Reasonable to put the encryption module for an encrypted filesystem driver outside the kernel?"
- In reply to: Arkady Frenkel: "Re: Another Ndis MinportXXX question"
- Next in thread: Alireza Dabagh [MS]: "Re: Another Ndis MinportXXX question"
- Messages sorted by: [ date ] [ thread ]
Date: Sun, 16 Jan 2005 09:35:02 -0800
Arkady Frenkel wrote:
> Correct , reentrancy can be supported but not in the same context
> Arkady
This is what I called RECURSION earlier - as opposite to REENTRANCY.
It occurs in the same "context" (same thread, same CPU).
--PA
> "Alexander Grigoriev" <alegr@earthlink.net> wrote in message
> news:#DxA1Yp9EHA.1392@tk2msftngp13.phx.gbl...
> > With a spinlock, a deadlock occures just by acquiring the same lock second
> > time in the same context.
> >
> > "Pavel A." <pavel_a@NOwritemeNO.com> wrote in message
> > news:eqtQENo9EHA.2316@TK2MSFTNGP15.phx.gbl...
> > > No, *I* can (of course, not by raising irql alone).
> > > It *is* possible to handle reentrancy. The only real problem here
> > > (as Alireza. pointed out) boils down to possibility of deadlock, when
> > > a. Two or more locks are acquired in the code path;
> > > b. Another path exists that acquires same locks in reverse order.
> > > Now I'm trying to understand, are there other ways for NDIS miniport
> > > to raise to dispatch, besides acquiring a spinlock.
> > >
> > > --PA
> > >
> > > "Alexander Grigoriev" <alegr@earthlink.net> wrote in message
> > > news:u4qTQOm9EHA.2680@TK2MSFTNGP09.phx.gbl...
> > >> You cannot sync between passive and DPC by raising IRQL.
> > >> In your protected code sections, you should not call any external
> > >> functions
> > >> that can cause reentrancy.
> > >>
> > >> "Pavel A." <pavel_a@NOwritemeNO.com> wrote in message
> > >> news:6E11725C-3DE1-4661-AAD6-927F4A8B4A74@microsoft.com...
> > >> > "Alireza Dabagh [MS]" wrote:
> > >> >> Without going through details below, I want to point out that if you
> > >> >> use
> > >> >> a
> > >> >> flag that by checking it you could figure out if it is safe to call
> > >> >> NDIS
> > >> >> or
> > >> >> not, you could use the same flag for protecting whatever it is that
> > >> >> you
> > >> >> want
> > >> >> to protect by holding the spinlock. This is why I said by the time
> you
> > >> >> put
> > >> >> the safeguard in, you can end up with a situation that you don't
> need
> > >> >> to
> > >> >> acquire the spinlock.
> > >> >
> > >> > Ali, could you please explain how we can do this without spinlock.
> > >> > When I need to sync between passive and DPCs, I have to get to
> > >> > dispatch.
> > >> > But NDIS spinlock seems to be the only way to raise to dispatch -
> > >> > KeRaiseIrql is forbidden?
> > >> >
> > >> > Thanks
> > >> > Pavel
> > >> >
> > >>
> > >>
> > >
> > >
> >
> >
>
>
>
- Next message: Vasu S: "Re: Supplemental Device Queues with Ke Insert/Remove DeviceQueue.."
- Previous message: Don Burn: "Re: Reasonable to put the encryption module for an encrypted filesystem driver outside the kernel?"
- In reply to: Arkady Frenkel: "Re: Another Ndis MinportXXX question"
- Next in thread: Alireza Dabagh [MS]: "Re: Another Ndis MinportXXX question"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|