HI,
In my miniport, I create a device using NdisMRegisterDevice.
but i don’t know how the Dispatch routine get the adapter’s information
such as io port. Setting a global variable is a way, but it’s not a
good way.
Any suggestion will be appriciated.
What’s wrong with using global variables in a (NDIS) driver?
Stephan
On Mon, 25 Mar 2002 00:40:24 -0500, “Yee” wrote:
> >HI, > In my miniport, I create a device using NdisMRegisterDevice. >but i don’t know how the Dispatch routine get the adapter’s information >such as io port. Setting a global variable is a way, but it’s not a >good way. > Any suggestion will be appriciated. > >Thanks. >Yee
Or even better, store it in your miniport context area.
“Thomas F. Divine” wrote in message news:xxxxx@ntdev… > > > “Stephan Wolf” wrote in message news:xxxxx@ntdev… > > > > What’s wrong with using global variables in a (NDIS) driver? > > > > Stephan > > > Nothing!!! > > Thomas > > > >
How do you have access to any Miniport context in the IOCTL dispatcher
routine? The only “context” available is global variables because
AFAIK NDIS does not allow you to use the driver object for your
purposes.
Stephan
On Mon, 25 Mar 2002 08:44:05 -0800, “Scott Neugroschl”
wrote:
> >Or even better, store it in your miniport context area. > >“Thomas F. Divine” wrote in message news:xxxxx@ntdev… >> >> >> “Stephan Wolf” wrote in message news:xxxxx@ntdev… >> > >> > What’s wrong with using global variables in a (NDIS) driver? >> > >> > Stephan >> > >> Nothing!!! >> >> Thomas