[Openib-windows] assert fix

Leonid Keller leonid at mellanox.co.il
Mon Jul 10 08:35:10 PDT 2006


 

> -----Original Message-----
> From: Fab Tillier [mailto:ftillier at silverstorm.com] 
> Sent: Monday, July 10, 2006 6:21 PM
> To: Leonid Keller
> Cc: openib-windows at openib.org
> Subject: RE: [Openib-windows] assert fix
> 
> Hi Leo,
> 
> > -----Original Message-----
> > From: Leonid Keller [mailto:leonid at mellanox.co.il]
> > Sent: Monday, July 10, 2006 11:22 AM
> > To: Tillier, Fabian
> > Cc: openib-windows at openib.org
> > Subject: RE: [Openib-windows] assert fix
> > 
> > > -----Original Message-----
> > > From: ftillier.sst at gmail.com [mailto:ftillier.sst at gmail.com] On 
> > > Behalf Of Fabian Tillier
> > > Sent: Monday, July 10, 2006 5:05 PM
> > > To: Leonid Keller
> > > Cc: openib-windows at openib.org
> > > Subject: Re: [Openib-windows] assert fix
> > >
> > > Hi Leo,
> > >
> > > On 7/10/06, Leonid Keller <leonid at mellanox.co.il> wrote:
> > > >
> > > > Hi Fab,
> > > >
> > > > I suggest to change ASSERTS as shown in the patch, 
> because system 
> > > > drivers sometimes return non-zero success return codes, e.g. 2
> > > > (STATUS_WAIT_2)
> > >
> > > For these two cases, the DDK docs say that drivers must return 
> > > STATUS_SUCCESS, so I think these are fine.  Have you seen a case 
> > > where a driver returned something else?
> >
> > Yes, I have. I've got STATUS_WAIT_2 and the ASSERT as a consequence.
> > I also saw the reports about it in Internet.
> 
> Did the MTHCA driver return STATUS_WAIT_2, or some other 
> driver?  I'm fine with the patch, just weary of the 
> consequences given the DDK docs.
> 
> Go ahead and check it in if the STATUS_WAIT_2 isn't coming 
> from any of our code.
> 
No, it's not our driver, it seems like Driver Verifier.
See, what I found on the net:

"Doron Holan [MS]" wrote:

> you should not check for specific values in the pnp irp handler other
then
> STATUS_NOT_SUPPORTED, even for that check is in very limited
scenarios. You
> can use STATUS_PENDING checks to check for pended requests that you
want to
> wait on as well. You should use NT_SUCCESS to evaluate the result of
the
> IRP.
>
> Driver verifier inserts STATUS_WAIT_2 instead of STATUS_SUCCESS to
make sure
> that your driver is not making the check if (status == STATUS_SUCCESS)
to
> check for success. 

So, I'll do the fix.

> - Fab
> 
> 
> 




More information about the ofw mailing list