From: Peter Zijlstra <peterz@infradead.org>
To: Arjan van de Ven <arjan@linux.intel.com>
Cc: lenb@kernel.org, rjw@rjwysocki.net, linux-acpi@vger.kernel.org,
linux-kernel@vger.kernel.org, shaohua.li@intel.com,
rui.zhang@intel.com, jacob.jun.pan@linux.intel.com,
Mike Galbraith <bitbucket@online.de>,
Ingo Molnar <mingo@kernel.org>,
Thomas Gleixner <tglx@linutronix.de>,
hpa@zytor.com
Subject: Re: [PATCH] x86, acpi, idle: Restructure the mwait idle routines
Date: Tue, 19 Nov 2013 15:51:43 +0100 [thread overview]
Message-ID: <20131119145143.GK10022@twins.programming.kicks-ass.net> (raw)
In-Reply-To: <528B7433.7020507@linux.intel.com>
On Tue, Nov 19, 2013 at 06:22:43AM -0800, Arjan van de Ven wrote:
> >diff --git a/drivers/thermal/intel_powerclamp.c b/drivers/thermal/intel_powerclamp.c
> >index 8f181b3f842b..e8275f2df9af 100644
> >--- a/drivers/thermal/intel_powerclamp.c
> >+++ b/drivers/thermal/intel_powerclamp.c
> >@@ -438,9 +438,7 @@ static int clamp_thread(void *arg)
> > */
> > local_touch_nmi();
> > stop_critical_timings();
> >- __monitor((void *)¤t_thread_info()->flags, 0, 0);
> >- cpu_relax(); /* allow HT sibling to run */
> >- __mwait(eax, ecx);
> >+ mwait_idle_with_hints(eax, ecx);
> > start_critical_timings();
> > atomic_inc(&idle_wakeup_counter);
> > }
> >
>
> hmm I take it that mwait_idle_with_hints is the one that also checks need_resched() ?
> if so... powerclamp may not want to use that (the whole point is to NOT give the cpu
> to tasks!)
That said, that drive is completely wrecked. It uses
preempt_enable_no_resched() wrong too, it has uncommented barriers..
Dude, wtf are you guys smoking?
next prev parent reply other threads:[~2013-11-19 14:51 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-11-19 9:00 acpi_pad mwait usage Peter Zijlstra
2013-11-19 9:08 ` Peter Zijlstra
2013-11-19 11:31 ` [PATCH] x86, acpi, idle: Restructure the mwait idle routines Peter Zijlstra
2013-11-19 13:06 ` Rafael J. Wysocki
2013-11-19 13:21 ` Mike Galbraith
2013-11-19 14:22 ` Arjan van de Ven
2013-11-19 14:46 ` Peter Zijlstra
2013-11-19 14:51 ` Peter Zijlstra [this message]
2013-11-19 15:13 ` Peter Zijlstra
2013-11-19 21:06 ` Jacob Pan
2013-11-20 10:28 ` Peter Zijlstra
2013-11-20 10:58 ` Peter Zijlstra
2013-11-20 16:24 ` Arjan van de Ven
2013-11-20 16:33 ` Peter Zijlstra
2013-11-20 16:38 ` Arjan van de Ven
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20131119145143.GK10022@twins.programming.kicks-ass.net \
--to=peterz@infradead.org \
--cc=arjan@linux.intel.com \
--cc=bitbucket@online.de \
--cc=hpa@zytor.com \
--cc=jacob.jun.pan@linux.intel.com \
--cc=lenb@kernel.org \
--cc=linux-acpi@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@kernel.org \
--cc=rjw@rjwysocki.net \
--cc=rui.zhang@intel.com \
--cc=shaohua.li@intel.com \
--cc=tglx@linutronix.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).