Re: SLUB: simplify re on_each_cpu()

From: Vegard Nossum
Date: Thu Jul 17 2008 - 08:55:37 EST


On Thu, Jul 17, 2008 at 2:39 PM, Robin Holt <holt@xxxxxxx> wrote:
> On Thu, Jul 17, 2008 at 03:26:46PM +0300, Pekka Enberg wrote:
>> Hi Robin,
>>
>> On Wed, Jul 16, 2008 at 09:29:02PM +0400, Alexey Dobriyan wrote:
>> >> on_each_cpu() expands to function call on UP, too.
>>
>> On Thu, Jul 17, 2008 at 2:38 PM, Robin Holt <holt@xxxxxxx> wrote:
>> > It looks to me like on_each_cpu is a #define for !SMP. Are you certain
>> > of the need for this change? Are you looking at a different tree than
>> > Linus'?
>>
>> I think it's actually you who is looking at an older tree.
>
> I did a git-checkout of
> git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6.git
> which got me commit id 33af79d12e0fa25545d49e86afc67ea8ad5f2f40
> and looked at include/linux/smp.h line 123. It has:
>
> #define on_each_cpu(func,info,wait) \
> ({ \
> local_irq_disable(); \
> func(info); \

That's the function call right there :-)


Vegard

--
"The animistic metaphor of the bug that maliciously sneaked in while
the programmer was not looking is intellectually dishonest as it
disguises that the error is the programmer's own creation."
-- E. W. Dijkstra, EWD1036
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/