[openib-general] CHECK_NULL [was Re: SDP_CONN_LOCK]
Libor Michalek
libor at topspin.com
Wed Feb 23 11:46:34 PST 2005
On Wed, Feb 23, 2005 at 01:01:43PM +0200, Michael S. Tsirkin wrote:
> Quoting r. Libor Michalek <libor at topspin.com>:
> > Subject: Re: Re: SDP_CONN_LOCK
> >
> > On Sun, Feb 20, 2005 at 02:11:37AM +0200, Michael S. Tsirkin wrote:
> > > Quoting r. Libor Michalek <libor at topspin.com>:
> > > >
> > > > And here I would have thought SDP_CONN_HOLD as a macro would have
> > > > bugged people more. :)
> > >
> > > Didn't get that far yet :)
> > >
> > > I also wander whether we could get rid of most called to
> > > _CHECK macros, consequently turn lots of functions
> > > which cant otherwise fail into void?
> > > Given that these checks are disabled upon a compile switch, one wanders
> > > how big a debugging aid they are.
> >
> > Yes, I think the _CHECK and EXPECT macros can be gotten rid of. Getting
> > rid of _CHECK does have the added benefit of turning a lot of functions
> > into void return functions, which in turn can get rid of most of the
> > EXPECT macros. I do agree that there are quite a few function that return
> > an status which can safely be turned into void functions.
> >
> > -Libor
> >
>
> Here's a patch to remove CHECK_NULL's, as a first step.
>
> Signed-off-by: Michael s. Tsirkin <mst at mellanox.co.il>
Thanks, I've applied and commited the change. I'll make a pass at turning
some of the obvious int return functions into voids.
-Libor
More information about the general
mailing list