All of lore.kernel.org
 help / color / mirror / Atom feed
From: Simon Horman <horms+renesas@verge.net.au>
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 06/10] ARM: shmobile: Remove shmobile_setup_delay()
Date: Mon, 25 Aug 2014 01:10:11 +0000	[thread overview]
Message-ID: <7dd4cfd7f8c2976a8d65022146386480474501ca.1408927601.git.horms+renesas@verge.net.au> (raw)
In-Reply-To: <cover.1408927601.git.horms+renesas@verge.net.au>

From: Magnus Damm <damm+renesas@opensource.se>

All ARM mach-shmobile SoCs and boards now rely on DTS for
CPU Frequency information, so remove the unused function
shmobile_setup_delay(). While at it, make the function
shmobile_setup_delay_hz() static.

Signed-off-by: Magnus Damm <damm+renesas@opensource.se>
Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
---
 arch/arm/mach-shmobile/common.h |  2 --
 arch/arm/mach-shmobile/timer.c  | 21 ++-------------------
 2 files changed, 2 insertions(+), 21 deletions(-)

diff --git a/arch/arm/mach-shmobile/common.h b/arch/arm/mach-shmobile/common.h
index 9805608..72087c7 100644
--- a/arch/arm/mach-shmobile/common.h
+++ b/arch/arm/mach-shmobile/common.h
@@ -2,8 +2,6 @@
 #define __ARCH_MACH_COMMON_H
 
 extern void shmobile_earlytimer_init(void);
-extern void shmobile_setup_delay(unsigned int max_cpu_core_mhz,
-			 unsigned int mult, unsigned int div);
 extern void shmobile_init_delay(void);
 struct twd_local_timer;
 extern void shmobile_setup_console(void);
diff --git a/arch/arm/mach-shmobile/timer.c b/arch/arm/mach-shmobile/timer.c
index 942efdc..adce98b 100644
--- a/arch/arm/mach-shmobile/timer.c
+++ b/arch/arm/mach-shmobile/timer.c
@@ -23,8 +23,8 @@
 #include <linux/delay.h>
 #include <linux/of_address.h>
 
-void __init shmobile_setup_delay_hz(unsigned int max_cpu_core_hz,
-				    unsigned int mult, unsigned int div)
+static void __init shmobile_setup_delay_hz(unsigned int max_cpu_core_hz,
+					   unsigned int mult, unsigned int div)
 {
 	/* calculate a worst-case loops-per-jiffy value
 	 * based on maximum cpu core hz setting and the
@@ -40,23 +40,6 @@ void __init shmobile_setup_delay_hz(unsigned int max_cpu_core_hz,
 		preset_lpj = max_cpu_core_hz / value;
 }
 
-void __init shmobile_setup_delay(unsigned int max_cpu_core_mhz,
-				 unsigned int mult, unsigned int div)
-{
-	/* calculate a worst-case loops-per-jiffy value
-	 * based on maximum cpu core mhz setting and the
-	 * __delay() implementation in arch/arm/lib/delay.S
-	 *
-	 * this will result in a longer delay than expected
-	 * when the cpu core runs on lower frequencies.
-	 */
-
-	unsigned int value = (1000000 * mult) / (HZ * div);
-
-	if (!preset_lpj)
-		preset_lpj = max_cpu_core_mhz * value;
-}
-
 void __init shmobile_init_delay(void)
 {
 	struct device_node *np, *cpus;
-- 
2.0.1


WARNING: multiple messages have this Message-ID (diff)
From: horms+renesas@verge.net.au (Simon Horman)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 06/10] ARM: shmobile: Remove shmobile_setup_delay()
Date: Mon, 25 Aug 2014 10:10:11 +0900	[thread overview]
Message-ID: <7dd4cfd7f8c2976a8d65022146386480474501ca.1408927601.git.horms+renesas@verge.net.au> (raw)
In-Reply-To: <cover.1408927601.git.horms+renesas@verge.net.au>

From: Magnus Damm <damm+renesas@opensource.se>

All ARM mach-shmobile SoCs and boards now rely on DTS for
CPU Frequency information, so remove the unused function
shmobile_setup_delay(). While at it, make the function
shmobile_setup_delay_hz() static.

Signed-off-by: Magnus Damm <damm+renesas@opensource.se>
Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
---
 arch/arm/mach-shmobile/common.h |  2 --
 arch/arm/mach-shmobile/timer.c  | 21 ++-------------------
 2 files changed, 2 insertions(+), 21 deletions(-)

diff --git a/arch/arm/mach-shmobile/common.h b/arch/arm/mach-shmobile/common.h
index 9805608..72087c7 100644
--- a/arch/arm/mach-shmobile/common.h
+++ b/arch/arm/mach-shmobile/common.h
@@ -2,8 +2,6 @@
 #define __ARCH_MACH_COMMON_H
 
 extern void shmobile_earlytimer_init(void);
-extern void shmobile_setup_delay(unsigned int max_cpu_core_mhz,
-			 unsigned int mult, unsigned int div);
 extern void shmobile_init_delay(void);
 struct twd_local_timer;
 extern void shmobile_setup_console(void);
diff --git a/arch/arm/mach-shmobile/timer.c b/arch/arm/mach-shmobile/timer.c
index 942efdc..adce98b 100644
--- a/arch/arm/mach-shmobile/timer.c
+++ b/arch/arm/mach-shmobile/timer.c
@@ -23,8 +23,8 @@
 #include <linux/delay.h>
 #include <linux/of_address.h>
 
-void __init shmobile_setup_delay_hz(unsigned int max_cpu_core_hz,
-				    unsigned int mult, unsigned int div)
+static void __init shmobile_setup_delay_hz(unsigned int max_cpu_core_hz,
+					   unsigned int mult, unsigned int div)
 {
 	/* calculate a worst-case loops-per-jiffy value
 	 * based on maximum cpu core hz setting and the
@@ -40,23 +40,6 @@ void __init shmobile_setup_delay_hz(unsigned int max_cpu_core_hz,
 		preset_lpj = max_cpu_core_hz / value;
 }
 
-void __init shmobile_setup_delay(unsigned int max_cpu_core_mhz,
-				 unsigned int mult, unsigned int div)
-{
-	/* calculate a worst-case loops-per-jiffy value
-	 * based on maximum cpu core mhz setting and the
-	 * __delay() implementation in arch/arm/lib/delay.S
-	 *
-	 * this will result in a longer delay than expected
-	 * when the cpu core runs on lower frequencies.
-	 */
-
-	unsigned int value = (1000000 * mult) / (HZ * div);
-
-	if (!preset_lpj)
-		preset_lpj = max_cpu_core_mhz * value;
-}
-
 void __init shmobile_init_delay(void)
 {
 	struct device_node *np, *cpus;
-- 
2.0.1

  parent reply	other threads:[~2014-08-25  1:10 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-08-25  1:10 [GIT PULL] Renesas ARM Based SoC Init Delay Updates For v3.18 Simon Horman
2014-08-25  1:10 ` Simon Horman
2014-08-25  1:10 ` [PATCH 01/10] ARM: shmobile: sh7372: Update DTS to include CPU frequency Simon Horman
2014-08-25  1:10   ` Simon Horman
2014-08-25  1:10 ` [PATCH 02/10] ARM: shmobile: sh73a0: " Simon Horman
2014-08-25  1:10   ` Simon Horman
2014-08-25  1:10 ` [PATCH 03/10] ARM: shmobile: r8a7778: " Simon Horman
2014-08-25  1:10   ` Simon Horman
2014-08-25  1:10 ` [PATCH 04/10] ARM: shmobile: sh7372: Use shmobile_init_delay() Simon Horman
2014-08-25  1:10   ` Simon Horman
2014-08-25  1:10 ` [PATCH 05/10] ARM: shmobile: r8a73a4: " Simon Horman
2014-08-25  1:10   ` Simon Horman
2014-08-25  1:10 ` Simon Horman [this message]
2014-08-25  1:10   ` [PATCH 06/10] ARM: shmobile: Remove shmobile_setup_delay() Simon Horman
2014-08-25  1:10 ` [PATCH 07/10] ARM: shmobile: sh73a0: Use shmobile_init_delay() Simon Horman
2014-08-25  1:10   ` Simon Horman
2014-08-25  1:10 ` [PATCH 08/10] ARM: shmobile: r8a7778: " Simon Horman
2014-08-25  1:10   ` Simon Horman
2014-08-25  1:10 ` [PATCH 09/10] ARM: shmobile: bockw: " Simon Horman
2014-08-25  1:10   ` Simon Horman
2014-08-25  1:10 ` [PATCH 10/10] ARM: shmobile: kzm9g: " Simon Horman
2014-08-25  1:10   ` Simon Horman
2014-09-05 15:27 ` [GIT PULL] Renesas ARM Based SoC Init Delay Updates For v3.18 Arnd Bergmann
2014-09-05 15:27   ` Arnd Bergmann
2014-09-09  2:02   ` Simon Horman
2014-09-09  2:02     ` Simon Horman
2014-09-09  8:50     ` Arnd Bergmann
2014-09-09  8:50       ` Arnd Bergmann
2014-09-05 16:13 ` Arnd Bergmann
2014-09-05 16:13   ` Arnd Bergmann

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=7dd4cfd7f8c2976a8d65022146386480474501ca.1408927601.git.horms+renesas@verge.net.au \
    --to=horms+renesas@verge.net.au \
    --cc=linux-arm-kernel@lists.infradead.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.