From: Ralf Baechle <ralf@linux-mips.org>
To: linux-mips@linux-mips.org
Subject: Loongson2 cpu_wait function
Date: Thu, 23 May 2013 14:27:37 +0200 [thread overview]
Message-ID: <20130523122737.GA12530@linux-mips.org> (raw)
During the 3.10 merge cycle many MIPS platforms were broken by the
generic idle loop patches. A patch series to fix this has already been
merged but I'm wondering if fb40bc3e94933007d3e42e96daf1ec8044821cb8
[MIPS: Idle: Re-enable irqs at the end of r3081, au1k and loongson2
cpu_wait.] is sufficient and correct for Loongson 2.
In particular:
o drivers/cpufreq/loongson2_cpufreq.c protects accesses to LOONGSON_CHIPCFG0
in loongson2_cpu_wait with a spinlock. This spinlock is not used anywhere
else in the kernel so it would appear there is still a race with other
accesses to LOONGSON_CHIPCFG0.
o It's not SMPly correct - even if cpufreq_exit restores the old value of
cpu_wait on a SMP system another processor might still be executing
loongson2_cpu_wait().
o I'd appreciate if at least some basic power saving would be used even if
CONFIG_LOONGSON2_CPUFREQ was disabled, that is loongson2_cpu_wait should
go back to arch/mips/kernel/idle.c.
o Could somebody test if Loongson 2 is working? Thanks!
Ralf
next reply other threads:[~2013-05-23 12:27 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-05-23 12:27 Ralf Baechle [this message]
2013-05-23 20:28 ` Loongson2 cpu_wait function Aaro Koskinen
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=20130523122737.GA12530@linux-mips.org \
--to=ralf@linux-mips.org \
--cc=linux-mips@linux-mips.org \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.