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

From: Christoph Hellwig (hch@infradead.org)
Date: Fri Oct 04 2002 - 09:16:56 EST


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/



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