From: Magnus Damm <magnus.damm@gmail.com>
To: linux-sh@vger.kernel.org
Subject: [PATCH] mach-shmobile: Use preset_lpj with calibrate_delay()
Date: Wed, 09 May 2012 07:11:07 +0000 [thread overview]
Message-ID: <20120509071107.18870.37448.sendpatchset@w520> (raw)
From: Magnus Damm <damm@opensource.se>
Update the mach-shmobile shared delay calibration code for late
timers. All existing in-tree non-DT socs are however using early
timers today and they are unaffected by this change.
The patch modifies shmobile_setup_delay() from using lpj_fine
to preset_lpj. This change allows us to preset the worst case
loops-per-jiffy value to all CPU cores on the system.
The old code which made use of lpj_fine did not affect the
secondary CPU cores which made it impossible to boot on SMP
without early timers.
Needed for SMP SoCs using late timers like EMEV2 or any other
mach-shmobile SMP SoC that makes use of late timers via DT.
Signed-off-by: Magnus Damm <damm@opensource.se>
---
arch/arm/mach-shmobile/timer.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
--- 0003/arch/arm/mach-shmobile/timer.c
+++ work/arch/arm/mach-shmobile/timer.c 2012-05-08 18:56:03.000000000 +0900
@@ -36,7 +36,8 @@ void __init shmobile_setup_delay(unsigne
unsigned int value = (1000000 * mult) / (HZ * div);
- lpj_fine = max_cpu_core_mhz * value;
+ if (!preset_lpj)
+ preset_lpj = max_cpu_core_mhz * value;
}
static void __init shmobile_late_time_init(void)
next reply other threads:[~2012-05-09 7:11 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-05-09 7:11 Magnus Damm [this message]
2012-05-09 22:48 ` [PATCH] mach-shmobile: Use preset_lpj with calibrate_delay() Rafael J. Wysocki
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=20120509071107.18870.37448.sendpatchset@w520 \
--to=magnus.damm@gmail.com \
--cc=linux-sh@vger.kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox