Re: To make a function get executed on cpu2

Zwane Mwaikambo (zwane@arm.linux.org.uk)
Tue, 1 Jul 2003 12:33:49 -0400 (EDT)


On Mon, 30 Jun 2003, Raghava Raju wrote:

> In multicpu systems in kernel version 2.4.19, how
> can we specify that a function be executed on
> a cpu of our choice(say cpu_2). Moreover if I call a
> function from cpu_1 to be executed on cpu_2, I dont
> want to wait in cpu_1 until complete execution of
> function on cpu_2 . Is it possible?????
>
> Any example would be really helpful. Please
> mail back to vraghava_raju@yahoo.com.

You can't really do it portably across all architectures, Alpha has
smp_call_function_on_cpu which would allow you to do this. If you're
really desperate you could always do something like the following;

http://www.osdl.org/projects/irqapi/results/patch-cpu_hotplug-smp_call_function_on_cpu_i386

Good luck,
Zwane

-- 
function.linuxpower.ca
-
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/