Re: [Evms-devel] Re: [PATCH] EVMS core 4/4: evms_biosplit.h

Christoph Hellwig (hch@infradead.org)
Fri, 4 Oct 2002 15:16:56 +0100


On Thu, Oct 03, 2002 at 03:36:24PM -0500, Mark Peloquin wrote:
>
> On 10/03/2002 at 10:05 AM, Christoph Hellwig wrote:
>
> >> +static mempool_t *my_bio_split_pool, *my_bio_pool;
> >> +static kmem_cache_t *my_bio_split_slab, *my_bio_pool_slab;
>
> > Umm, static variables in header files?
>
> Yupp, that wasn't accidental.
>
> Based on the conclusions mutually agreed on in the OLS
> BOF on bio splitting, it was decided that each driver
> having the need to split bios *should* have their own
> private bio pools to use exclusively for this purpose.
> Thus any plugin that includes this header gets their
> own private copies of these variables.

Having variables and (non-inline) functions is very bad style and a
perfect method for the obsfucated C contest. Just let every module
that needs bio-splitting declare it's own variables.

-
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/