Skip to content

Commit

Permalink
Merge branch 'clockevents/4.13' of https://git.linaro.org/people/dani…
Browse files Browse the repository at this point in the history
…el.lezcano/linux into timers/core

Pull clockevent changes from Daniel Lezcano:

 - Factored out moxart, aspeed, cortina drivers into a generic timer fttrm010.
   Take the opportunity to add the delay timer (Linus Walleij)

 - Saved / restored tcb atmel context at suspend/resume (Alexandre Belloni)

 - Added ast2500 compatible string and fixed aspeed2500 initialization (Daniel
   Lezcano)

 - Added clock names property for aspeed (Andrew Jeffery)

 - Renamed clocksource_of to timer_of (Daniel Lezcano)

 - Added a common timer init routine (Daniel Lezcano)
  • Loading branch information
Thomas Gleixner committed Jun 20, 2017
2 parents 938e7cf + c477990 commit e707eb7
Show file tree
Hide file tree
Showing 111 changed files with 791 additions and 743 deletions.
6 changes: 5 additions & 1 deletion Documentation/devicetree/bindings/timer/faraday,fttmr010.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,11 @@ Required properties:

- compatible : Must be one of
"faraday,fttmr010"
"cortina,gemini-timer"
"cortina,gemini-timer", "faraday,fttmr010"
"moxa,moxart-timer", "faraday,fttmr010"
"aspeed,ast2400-timer"
"aspeed,ast2500-timer"

- reg : Should contain registers location and length
- interrupts : Should contain the three timer interrupts usually with
flags for falling edge
Expand Down
19 changes: 0 additions & 19 deletions Documentation/devicetree/bindings/timer/moxa,moxart-timer.txt

This file was deleted.

2 changes: 1 addition & 1 deletion arch/arc/kernel/setup.c
Original file line number Diff line number Diff line change
Expand Up @@ -470,7 +470,7 @@ void __init setup_arch(char **cmdline_p)
void __init time_init(void)
{
of_clk_init(NULL);
clocksource_probe();
timer_probe();
}

static int __init customize_machine(void)
Expand Down
10 changes: 5 additions & 5 deletions arch/arm/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -337,7 +337,7 @@ config ARCH_MULTIPLATFORM
select ARM_HAS_SG_CHAIN
select ARM_PATCH_PHYS_VIRT
select AUTO_ZRELADDR
select CLKSRC_OF
select TIMER_OF
select COMMON_CLK
select GENERIC_CLOCKEVENTS
select MIGHT_HAVE_PCI
Expand All @@ -351,7 +351,7 @@ config ARM_SINGLE_ARMV7M
depends on !MMU
select ARM_NVIC
select AUTO_ZRELADDR
select CLKSRC_OF
select TIMER_OF
select COMMON_CLK
select CPU_V7M
select GENERIC_CLOCKEVENTS
Expand Down Expand Up @@ -532,7 +532,7 @@ config ARCH_PXA
select CLKDEV_LOOKUP
select CLKSRC_PXA
select CLKSRC_MMIO
select CLKSRC_OF
select TIMER_OF
select CPU_XSCALE if !CPU_XSC3
select GENERIC_CLOCKEVENTS
select GPIO_PXA
Expand Down Expand Up @@ -571,7 +571,7 @@ config ARCH_SA1100
select CLKDEV_LOOKUP
select CLKSRC_MMIO
select CLKSRC_PXA
select CLKSRC_OF if OF
select TIMER_OF if OF
select CPU_FREQ
select CPU_SA1100
select GENERIC_CLOCKEVENTS
Expand Down Expand Up @@ -1357,7 +1357,7 @@ config HAVE_ARM_ARCH_TIMER

config HAVE_ARM_TWD
bool
select CLKSRC_OF if OF
select TIMER_OF if OF
help
This options enables support for the ARM timer and watchdog unit

Expand Down
1 change: 1 addition & 0 deletions arch/arm/boot/dts/aspeed-g4.dtsi
Original file line number Diff line number Diff line change
Expand Up @@ -893,6 +893,7 @@
//interrupts = <16 17 18 35 36 37 38 39>;
interrupts = <16>;
clocks = <&clk_apb>;
clock-names = "PCLK";
};

wdt1: wdt@1e785000 {
Expand Down
1 change: 1 addition & 0 deletions arch/arm/boot/dts/aspeed-g5.dtsi
Original file line number Diff line number Diff line change
Expand Up @@ -1000,6 +1000,7 @@
//interrupts = <16 17 18 35 36 37 38 39>;
interrupts = <16>;
clocks = <&clk_apb>;
clock-names = "PCLK";
};


Expand Down
6 changes: 3 additions & 3 deletions arch/arm/kernel/smp_twd.c
Original file line number Diff line number Diff line change
Expand Up @@ -403,7 +403,7 @@ static int __init twd_local_timer_of_register(struct device_node *np)
WARN(err, "twd_local_timer_of_register failed (%d)\n", err);
return err;
}
CLOCKSOURCE_OF_DECLARE(arm_twd_a9, "arm,cortex-a9-twd-timer", twd_local_timer_of_register);
CLOCKSOURCE_OF_DECLARE(arm_twd_a5, "arm,cortex-a5-twd-timer", twd_local_timer_of_register);
CLOCKSOURCE_OF_DECLARE(arm_twd_11mp, "arm,arm11mp-twd-timer", twd_local_timer_of_register);
TIMER_OF_DECLARE(arm_twd_a9, "arm,cortex-a9-twd-timer", twd_local_timer_of_register);
TIMER_OF_DECLARE(arm_twd_a5, "arm,cortex-a5-twd-timer", twd_local_timer_of_register);
TIMER_OF_DECLARE(arm_twd_11mp, "arm,arm11mp-twd-timer", twd_local_timer_of_register);
#endif
2 changes: 1 addition & 1 deletion arch/arm/kernel/time.c
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,6 @@ void __init time_init(void)
#ifdef CONFIG_COMMON_CLK
of_clk_init(NULL);
#endif
clocksource_probe();
timer_probe();
}
}
2 changes: 1 addition & 1 deletion arch/arm/mach-aspeed/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ menuconfig ARCH_ASPEED
select SRAM
select WATCHDOG
select ASPEED_WATCHDOG
select MOXART_TIMER
select FTTMR010_TIMER
select MFD_SYSCON
select PINCTRL
help
Expand Down
2 changes: 1 addition & 1 deletion arch/arm/mach-bcm/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@ config ARCH_BCM2835
select ARM_ERRATA_411920 if ARCH_MULTI_V6
select ARM_TIMER_SP804
select HAVE_ARM_ARCH_TIMER if ARCH_MULTI_V7
select CLKSRC_OF
select TIMER_OF
select BCM2835_TIMER
select PINCTRL
select PINCTRL_BCM2835
Expand Down
2 changes: 1 addition & 1 deletion arch/arm/mach-clps711x/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ menuconfig ARCH_CLPS711X
bool "Cirrus Logic EP721x/EP731x-based"
depends on ARCH_MULTI_V4T
select AUTO_ZRELADDR
select CLKSRC_OF
select TIMER_OF
select CLPS711X_TIMER
select COMMON_CLK
select CPU_ARM720T
Expand Down
2 changes: 1 addition & 1 deletion arch/arm/mach-mediatek/mediatek.c
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ static void __init mediatek_timer_init(void)
}

of_clk_init(NULL);
clocksource_probe();
timer_probe();
};

static const char * const mediatek_board_dt_compat[] = {
Expand Down
2 changes: 1 addition & 1 deletion arch/arm/mach-moxart/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ menuconfig ARCH_MOXART
select CPU_FA526
select ARM_DMA_MEM_BUFFERABLE
select FARADAY_FTINTC010
select MOXART_TIMER
select FTTMR010_TIMER
select GPIOLIB
select PHYLIB if NETDEVICES
help
Expand Down
10 changes: 5 additions & 5 deletions arch/arm/mach-omap2/timer.c
Original file line number Diff line number Diff line change
Expand Up @@ -497,7 +497,7 @@ void __init omap_init_time(void)
__omap_sync32k_timer_init(1, "timer_32k_ck", "ti,timer-alwon",
2, "timer_sys_ck", NULL, false);

clocksource_probe();
timer_probe();
}

#if defined(CONFIG_ARCH_OMAP3) || defined(CONFIG_SOC_AM43XX)
Expand All @@ -506,7 +506,7 @@ void __init omap3_secure_sync32k_timer_init(void)
__omap_sync32k_timer_init(12, "secure_32k_fck", "ti,timer-secure",
2, "timer_sys_ck", NULL, false);

clocksource_probe();
timer_probe();
}
#endif /* CONFIG_ARCH_OMAP3 */

Expand All @@ -517,7 +517,7 @@ void __init omap3_gptimer_timer_init(void)
__omap_sync32k_timer_init(2, "timer_sys_ck", NULL,
1, "timer_sys_ck", "ti,timer-alwon", true);
if (of_have_populated_dt())
clocksource_probe();
timer_probe();
}
#endif

Expand All @@ -532,7 +532,7 @@ static void __init omap4_sync32k_timer_init(void)
void __init omap4_local_timer_init(void)
{
omap4_sync32k_timer_init();
clocksource_probe();
timer_probe();
}
#endif

Expand Down Expand Up @@ -656,7 +656,7 @@ void __init omap5_realtime_timer_init(void)
omap4_sync32k_timer_init();
realtime_counter_init();

clocksource_probe();
timer_probe();
}
#endif /* CONFIG_SOC_OMAP5 || CONFIG_SOC_DRA7XX */

Expand Down
2 changes: 1 addition & 1 deletion arch/arm/mach-rockchip/rockchip.c
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ static void __init rockchip_timer_init(void)
}

of_clk_init(NULL);
clocksource_probe();
timer_probe();
}

static void __init rockchip_dt_init(void)
Expand Down
2 changes: 1 addition & 1 deletion arch/arm/mach-s3c24xx/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -394,7 +394,7 @@ config MACH_SMDK2416

config MACH_S3C2416_DT
bool "Samsung S3C2416 machine using devicetree"
select CLKSRC_OF
select TIMER_OF
select USE_OF
select PINCTRL
select PINCTRL_S3C24XX
Expand Down
2 changes: 1 addition & 1 deletion arch/arm/mach-s3c64xx/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -336,7 +336,7 @@ config MACH_WLF_CRAGG_6410

config MACH_S3C64XX_DT
bool "Samsung S3C6400/S3C6410 machine using Device Tree"
select CLKSRC_OF
select TIMER_OF
select CPU_S3C6400
select CPU_S3C6410
select PINCTRL
Expand Down
2 changes: 1 addition & 1 deletion arch/arm/mach-shmobile/setup-rcar-gen2.c
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ void __init rcar_gen2_timer_init(void)
#endif /* CONFIG_ARM_ARCH_TIMER */

of_clk_init(NULL);
clocksource_probe();
timer_probe();
}

struct memory_reserve_config {
Expand Down
2 changes: 1 addition & 1 deletion arch/arm/mach-spear/spear13xx.c
Original file line number Diff line number Diff line change
Expand Up @@ -124,5 +124,5 @@ void __init spear13xx_timer_init(void)
clk_put(pclk);

spear_setup_of_timer();
clocksource_probe();
timer_probe();
}
2 changes: 1 addition & 1 deletion arch/arm/mach-sunxi/sunxi.c
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ static void __init sun6i_timer_init(void)
of_clk_init(NULL);
if (IS_ENABLED(CONFIG_RESET_CONTROLLER))
sun6i_reset_init();
clocksource_probe();
timer_probe();
}

DT_MACHINE_START(SUN6I_DT, "Allwinner sun6i (A31) Family")
Expand Down
2 changes: 1 addition & 1 deletion arch/arm/mach-u300/core.c
Original file line number Diff line number Diff line change
Expand Up @@ -407,7 +407,7 @@ static const char * u300_board_compat[] = {
DT_MACHINE_START(U300_DT, "U300 S335/B335 (Device Tree)")
.map_io = u300_map_io,
.init_irq = u300_init_irq_dt,
.init_time = clocksource_probe,
.init_time = timer_probe,
.init_machine = u300_init_machine_dt,
.restart = u300_restart,
.dt_compat = u300_board_compat,
Expand Down
2 changes: 1 addition & 1 deletion arch/arm/mach-zynq/common.c
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@ static void __init zynq_timer_init(void)
{
zynq_clock_init();
of_clk_init(NULL);
clocksource_probe();
timer_probe();
}

static struct map_desc zynq_cortex_a9_scu_map __initdata = {
Expand Down
4 changes: 2 additions & 2 deletions arch/arm64/Kconfig.platforms
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ config ARCH_ALPINE

config ARCH_BCM2835
bool "Broadcom BCM2835 family"
select CLKSRC_OF
select TIMER_OF
select GPIOLIB
select PINCTRL
select PINCTRL_BCM2835
Expand Down Expand Up @@ -178,7 +178,7 @@ config ARCH_TEGRA
select ARCH_HAS_RESET_CONTROLLER
select CLKDEV_LOOKUP
select CLKSRC_MMIO
select CLKSRC_OF
select TIMER_OF
select GENERIC_CLOCKEVENTS
select GPIOLIB
select PINCTRL
Expand Down
2 changes: 1 addition & 1 deletion arch/arm64/kernel/time.c
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ void __init time_init(void)
u32 arch_timer_rate;

of_clk_init(NULL);
clocksource_probe();
timer_probe();

tick_setup_hrtimer_broadcast();

Expand Down
2 changes: 1 addition & 1 deletion arch/h8300/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ config H8300
select OF_IRQ
select OF_EARLY_FLATTREE
select HAVE_MEMBLOCK
select CLKSRC_OF
select TIMER_OF
select H8300_TMR8
select HAVE_KERNEL_GZIP
select HAVE_KERNEL_LZO
Expand Down
2 changes: 1 addition & 1 deletion arch/h8300/kernel/setup.c
Original file line number Diff line number Diff line change
Expand Up @@ -246,5 +246,5 @@ void __init calibrate_delay(void)
void __init time_init(void)
{
of_clk_init(NULL);
clocksource_probe();
timer_probe();
}
2 changes: 1 addition & 1 deletion arch/microblaze/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ config MICROBLAZE
select ARCH_MIGHT_HAVE_PC_PARPORT
select ARCH_WANT_IPC_PARSE_VERSION
select BUILDTIME_EXTABLE_SORT
select CLKSRC_OF
select TIMER_OF
select CLONE_BACKWARDS3
select COMMON_CLK
select GENERIC_ATOMIC64
Expand Down
2 changes: 1 addition & 1 deletion arch/microblaze/kernel/setup.c
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,7 @@ void __init time_init(void)
{
of_clk_init(NULL);
setup_cpuinfo_clk();
clocksource_probe();
timer_probe();
}

#ifdef CONFIG_DEBUG_FS
Expand Down
2 changes: 1 addition & 1 deletion arch/microblaze/kernel/timer.c
Original file line number Diff line number Diff line change
Expand Up @@ -333,5 +333,5 @@ static int __init xilinx_timer_init(struct device_node *timer)
return 0;
}

CLOCKSOURCE_OF_DECLARE(xilinx_timer, "xlnx,xps-timer-1.00.a",
TIMER_OF_DECLARE(xilinx_timer, "xlnx,xps-timer-1.00.a",
xilinx_timer_init);
2 changes: 1 addition & 1 deletion arch/mips/generic/init.c
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ void __init plat_time_init(void)
}
}

clocksource_probe();
timer_probe();
}

void __init arch_init_irq(void)
Expand Down
2 changes: 1 addition & 1 deletion arch/mips/mti-malta/malta-time.c
Original file line number Diff line number Diff line change
Expand Up @@ -265,7 +265,7 @@ void __init plat_time_init(void)
(freq%1000000)*100/1000000);
#ifdef CONFIG_CLKSRC_MIPS_GIC
update_gic_frequency_dt();
clocksource_probe();
timer_probe();
#endif
}
#endif
Expand Down
2 changes: 1 addition & 1 deletion arch/mips/pic32/pic32mzda/time.c
Original file line number Diff line number Diff line change
Expand Up @@ -64,5 +64,5 @@ void __init plat_time_init(void)
pr_info("CPU Clock: %ldMHz\n", rate / 1000000);
mips_hpt_frequency = rate / 2;

clocksource_probe();
timer_probe();
}
2 changes: 1 addition & 1 deletion arch/mips/pistachio/time.c
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ void __init plat_time_init(void)
struct clk *clk;

of_clk_init(NULL);
clocksource_probe();
timer_probe();

np = of_get_cpu_node(0, NULL);
if (!np) {
Expand Down
2 changes: 1 addition & 1 deletion arch/mips/ralink/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ config CLKEVT_RT3352
bool
depends on SOC_RT305X || SOC_MT7620
default y
select CLKSRC_OF
select TIMER_OF
select CLKSRC_MMIO

config RALINK_ILL_ACC
Expand Down
2 changes: 1 addition & 1 deletion arch/mips/ralink/cevt-rt3352.c
Original file line number Diff line number Diff line change
Expand Up @@ -152,4 +152,4 @@ static int __init ralink_systick_init(struct device_node *np)
return 0;
}

CLOCKSOURCE_OF_DECLARE(systick, "ralink,cevt-systick", ralink_systick_init);
TIMER_OF_DECLARE(systick, "ralink,cevt-systick", ralink_systick_init);
Loading

0 comments on commit e707eb7

Please sign in to comment.