Re: IRP Minor function value is wrong some times IRP_- MJ_PNP

Driver Verifier and/or Checked Build send invalid function codes, just
to see if you are paying attention. And if you use the function code
to index into an array, without first validating the index, you get
into trouble.


Dave Cox
Hewlett-Packard Co.
NSSO/SNS/SRM (Santa Barbara)
https://ecardfile.com/id/Dave+Cox

-----Original Message-----
From: Hassan I Khan [mailto:xxxxx@hotmail.com]
Sent: Monday, June 11, 2001 10:29 AM
To: NT Developers Interest List
Subject: [ntdev] Re: IRP Minor function value is wrong some times IRP_
MJ_PNP

Now this is strange. I would just pass this junk down and see
what happens.
Or complete it without changing anything. I remember seeing
0x1b but don’t
remember if I saw 0xff. In my case, everything
unknown/unexpected was driven
to my ‘default’ case and since it was a function driver I was
just passing
that stuff down. Later magically, when my driver matured a
bit I stopped
receiving this junk ! Then I never bothered to recreate that pesky
situation. Hope this ‘technique’ would work for you as well : )

regards,
Hassan

>From: Srinivasa Rao Deevi
> >Reply-To: “NT Developers Interest List”
> >To: “NT Developers Interest List”
> >Subject: [ntdev] Re: IRP Minor function value is wrong some
> times IRP_
> >MJ_PNP
> >Date: Sun, 10 Jun 2001 12:24:41 -0700
> >
> >Hi Hassan
> >
> >Thanks for the reply . I am seeing some other Minor function
> values also.
> >Like 0xff, 0x1b . I just checked the ntddk.h to see those
> values have any
> >meaning. I could not find any . When I checked Irp
> parameters except the
> >Minor function values remaining seems to be good . Have any
> idea what is
> >going on here ?
> >
> >Thanks in advance
> >srinivas
> >
> >-----Original Message-----
> >From: xxxxx@hotmail.com
> [mailto:xxxxx@hotmail.com]
> >Sent: Sunday, June 10, 2001 7:59 AM
> >To: NT Developers Interest List
> >Subject: [ntdev] Re: IRP Minor function value is wrong some times
> >IRP_MJ_PNP
> >
> >
> >When I faced the same situation, I found 0x18 corresponds to
> >IRP_MN_QUERY_LEGACY_BUS_INFORMATION which is not defined in
> wdm.h but is
> >defined in ntddk.h.
> >
> >Eliyas advised that just pass the IRP down if yours is a
> function or filter
> >driver or complete without changing the IoStatus if it is a
> bus driver.
> >
> >But I had to do
> >#defined IRP_MN_QUERY_LEGACY_BUS_INFORMATION 0x18 myself
> since I was not
> >using ntddk.h
> >
> >Hassan
> >
> >On 06/10/01, “Srinivasa Rao Deevi ” wrote:
> > > Hi all
> > >
> > > I am seeing some wrong parameters coming from IRP . In an
> IRP with major
> > > function code IRP_MJ_PNP the Minor Function value is
> sometimes morethan
> > > 0x17 which is no mean to IRP_MJ_PNP . As far as PNP is
> concerned the IRP
> > > generation is done by PNP manager I believe . Can anybody
> has any idea
> >how
> > > this problem is coming ?
> > >
> > > Thanks in advance
> > > srinivas
> > >
> > > —
> > > You are currently subscribed to ntdev as: xxxxx@transilica.com
> > > To unsubscribe send a blank email to
> leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com
> >
> >—
> >You are currently subscribed to ntdev as: xxxxx@transilica.com
> >To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com
> >
> >—
> >You are currently subscribed to ntdev as: xxxxx@hotmail.com
> >To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com
>
> ___________________________________________________
>

> Get Your Private, Free E-mail from MSN Hotmail at
> http://www.hotmail.com.
>
>
> —
> You are currently subscribed to ntdev as: david_cox2@hp.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