Subject: Re: workqueue(9), per-CPU queues [was: Re: soc zfs: taskqueue /
To: None <tech-kern@netbsd.org>
From: Mindaugas R. <rmind@NetBSD.org>
List: tech-kern
Date: 07/11/2007 15:29:56
yamt@mwd.biglobe.ne.jp (YAMAMOTO Takashi) wrote:
> - i'm not happy with iterating a list on each enqueue operations.
>   probably it's ok for now, but, at least, please make it a function
>   rather than having two copies.
Inline it?

>   for long term, probably it's useful to have "dense" cpuid which can be
>   used as an array index.
I was thinking how to make it friendly for dynamic CPU attaching/detaching,
and considered ci->ci_cpuid. But AFAIK, currently, it is not OK to use it as
an array index, is it?

> - why s/kmem_alloc/kmem_zalloc/ ?
To make sure, that structure will always be zeroed.

> - why removed the check of kmem_alloc failure?
>   iirc, at least currently, it can fail.
It has KM_SLEEP flag. How can it fail?

> - i doubt if it's worth to have a pool for workqueue_queue.
You would suggest to use kmem?

In general - are you OK with the patch?

-- 
Best regards,
Mindaugas
www.NetBSD.org