]> git.baikalelectronics.ru Git - kernel.git/commit
[CPUFREQ] cpumask: avoid playing with cpus_allowed in speedstep-ich.c
authorRusty Russell <rusty@rustcorp.com.au>
Thu, 11 Jun 2009 13:29:58 +0000 (22:59 +0930)
committerDave Jones <davej@redhat.com>
Mon, 15 Jun 2009 15:49:43 +0000 (11:49 -0400)
commit1f63058e5c77ada0e78ca677076aff9698de7178
tree849d4f1e03cab2abacc68a25160ef023ee3da879
parentc4609f415947c3d9d730ab29f3eb65fd2a5104a8
[CPUFREQ] cpumask: avoid playing with cpus_allowed in speedstep-ich.c

Impact: don't play with current's cpumask

It's generally a very bad idea to mug some process's cpumask: it could
legitimately and reasonably be changed by root, which could break us
(if done before our code) or them (if we restore the wrong value).

We use smp_call_function_single: this had the advantage of being more
efficient, too.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
To: cpufreq@vger.kernel.org
Cc: Dominik Brodowski <linux@brodo.de>
Signed-off-by: Dave Jones <davej@redhat.com>
arch/x86/kernel/cpu/cpufreq/speedstep-ich.c
arch/x86/kernel/cpu/cpufreq/speedstep-lib.c