diff mbox

[4/4] ARM: ep93xx: stop using mach/timex.h

Message ID 1384292466-31725-5-git-send-email-u.kleine-koenig@pengutronix.de
State New
Headers show

Commit Message

Uwe Kleine-König Nov. 12, 2013, 9:41 p.m. UTC
mach/timex.h is the last remaining header that is unused for multiarch
builds but necessary for singlearch builds. To allow to get rid of it
for singlearch builds, too, drop its usage in ep93xx arch code by
substituting CLOCK_TICK_RATE by a local cpp symbol.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
---
 arch/arm/mach-ep93xx/core.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

Comments

Hartley Sweeten Nov. 18, 2013, 5:07 p.m. UTC | #1
On Tuesday, November 12, 2013 2:41 PM, Uwe Kleine-König wrote:
> mach/timex.h is the last remaining header that is unused for multiarch

> builds but necessary for singlearch builds. To allow to get rid of it

> for singlearch builds, too, drop its usage in ep93xx arch code by

> substituting CLOCK_TICK_RATE by a local cpp symbol.

>

> Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>

> ---

>  arch/arm/mach-ep93xx/core.c | 3 ++-

>  1 file changed, 2 insertions(+), 1 deletion(-)

>

> diff --git a/arch/arm/mach-ep93xx/core.c b/arch/arm/mach-ep93xx/core.c

> index 157ba88..615244b 100644

> --- a/arch/arm/mach-ep93xx/core.c

> +++ b/arch/arm/mach-ep93xx/core.c

> @@ -116,8 +116,9 @@ void __init ep93xx_map_io(void)

>  #define EP93XX_TIMER123_CLOCK		508469

>  #define EP93XX_TIMER4_CLOCK		983040

>  

> +#define EP93XX_CLOCK_FREQ		983040


I would prefer that the already defined symbol EP93XX_TIMER4_CLOCK be used
instead of adding a new one.

>  #define TIMER1_RELOAD			((EP93XX_TIMER123_CLOCK / HZ) - 1)

> -#define TIMER4_TICKS_PER_JIFFY		DIV_ROUND_CLOSEST(CLOCK_TICK_RATE, HZ)

> +#define TIMER4_TICKS_PER_JIFFY		DIV_ROUND_CLOSEST(EP93XX_CLOCK_FREQ, HZ)

>

>  static unsigned int last_jiffy_time;


Other than that comment, I have no issues with this.

Acked-by: H Hartley Sweeten <hsweeten@visionengravers.com>
diff mbox

Patch

diff --git a/arch/arm/mach-ep93xx/core.c b/arch/arm/mach-ep93xx/core.c
index 157ba88..615244b 100644
--- a/arch/arm/mach-ep93xx/core.c
+++ b/arch/arm/mach-ep93xx/core.c
@@ -116,8 +116,9 @@  void __init ep93xx_map_io(void)
 #define EP93XX_TIMER123_CLOCK		508469
 #define EP93XX_TIMER4_CLOCK		983040
 
+#define EP93XX_CLOCK_FREQ		983040
 #define TIMER1_RELOAD			((EP93XX_TIMER123_CLOCK / HZ) - 1)
-#define TIMER4_TICKS_PER_JIFFY		DIV_ROUND_CLOSEST(CLOCK_TICK_RATE, HZ)
+#define TIMER4_TICKS_PER_JIFFY		DIV_ROUND_CLOSEST(EP93XX_CLOCK_FREQ, HZ)
 
 static unsigned int last_jiffy_time;