Re: Is it possible to choose the *preferred* core?
κΉλν <[email protected]> Sat, 17 Feb 2018 23:04:58 +0900
| Newsgroups | org.kernel.vger.linux-smp |
|---|---|
| Message-ID | <CADLLry5C_Hi0AC1Q=wi9VCO==XT0Hd_+7nQjCbbu3H4RTN-F7Q@mail.gmail.com> |
Dear Folks
If you notice all threads are running in a specific cpu, you might
consider disabling it.
For example, below patch will disable the cpu3 during boot-up progress.
diff --git a/kernel/cpu.c b/kernel/cpu.c
index 5b4440d..14cce91 100644
--- a/kernel/cpu.c
+++ b/kernel/cpu.c
@@ -510,7 +510,7 @@ static int _cpu_up(unsigned int cpu, int tasks_frozen)
cpu_hotplug_begin();
- if (cpu_online(cpu) || !cpu_present(cpu)) {
+ if ( (cpu == 3) || cpu_online(cpu) || !cpu_present(cpu)) {
ret = -EINVAL;
goto out;
}
2018-02-14 20:06 GMT+09:00 Dark Penguin <[email protected]>:
> Greetings!
>
> I have a pretty hot quad-core CPU, and one core is running significantly
> colder than others. Under load, it only approaches the idle temperature
> for the rest of the cores.
>
> Is it possible to assign all threads to this core by default, but use
> other cores when one is not enough? Or maybe even all "heavy" threads,
> if having all cores under 1% load is better in terms of temperature than
> cramming them all into one core. (I'm not sure if it is.)
>
>
> --
> darkpenguin
> --
> To unsubscribe from this list: send the line "unsubscribe linux-smp" in
> the body of a message to [email protected]
> More majordomo info at http://vger.kernel.org/majordomo-info.html