Re: [PATCH] EVMS core 1/4: evms.c

From: Ingo Oeser (ingo.oeser@informatik.tu-chemnitz.de)
Date: Fri Oct 04 2002 - 11:32:38 EST


On Fri, Oct 04, 2002 at 03:56:39PM +0100, Christoph Hellwig wrote:
> > + * allocates and zeros an evms_logical_node structure.
> > + *
> > + * returns: 0 if sucessful
> > + * -ENOMEM if unsuccessful
> > + **/
> > +int
> > +evms_cs_allocate_logical_node(struct evms_logical_node **pp)
> > +{
> > + *pp = kmalloc(sizeof (struct evms_logical_node), GFP_KERNEL);
> > + if (*pp == NULL) {
> > + return -ENOMEM;
> > + }
> > + memset(*pp, 0, sizeof (struct evms_logical_node));
> > + return 0;
>
> A helper for kmalloc + memset looks rather pointles..
 
This looks, like they want to slabify it later. But a define
might be better here, indeed.

Regards

Ingo Oeser

-- 
Science is what we can tell a computer. Art is everything else. --- D.E.Knuth
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Mon Oct 07 2002 - 22:00:50 EST