1. 09 5月, 2016 1 次提交
  2. 28 4月, 2016 4 次提交
  3. 22 4月, 2016 1 次提交
  4. 23 3月, 2016 1 次提交
  5. 01 3月, 2016 1 次提交
  6. 25 2月, 2016 9 次提交
  7. 26 1月, 2016 2 次提交
  8. 15 1月, 2016 1 次提交
    • A
      clockevents/tcb_clksrc: Prevent disabling an already disabled clock · f02b4b72
      Alexandre Belloni 提交于
      clockevents_exchange_device is calling clockevents_shutdown() on the new
      clockenvents device but it may have never been enabled in the first place.
      This results in the tcb clock being disabled without being enabled first:
      
      ------------[ cut here ]------------
      WARNING: CPU: 0 PID: 1 at drivers/clk/clk.c:680 clk_disable+0x28/0x34()
      Modules linked in:
      CPU: 0 PID: 1 Comm: swapper Not tainted 4.4.0+ #6
      Hardware name: Atmel AT91SAM9
      [<c000f2b8>] (unwind_backtrace) from [<c000d01c>] (show_stack+0x10/0x14)
      [<c000d01c>] (show_stack) from [<c00172f0>] (warn_slowpath_common+0x78/0xa0)
      [<c00172f0>] (warn_slowpath_common) from [<c00173a8>] (warn_slowpath_null+0x18/0x20)
      [<c00173a8>] (warn_slowpath_null) from [<c0361528>] (clk_disable+0x28/0x34)
      [<c0361528>] (clk_disable) from [<c034d560>] (tc_shutdown+0x38/0x4c)
      [<c034d560>] (tc_shutdown) from [<c0059ad4>] (clockevents_switch_state+0x38/0x6c)
      [<c0059ad4>] (clockevents_switch_state) from [<c0059b18>] (clockevents_shutdown+0x10/0x24)
      [<c0059b18>] (clockevents_shutdown) from [<c005a458>] (tick_check_new_device+0x84/0xac)
      [<c005a458>] (tick_check_new_device) from [<c0059660>] (clockevents_register_device+0x7c/0x108)
      [<c0059660>] (clockevents_register_device) from [<c06b5a68>] (tcb_clksrc_init+0x390/0x3e8)
      [<c06b5a68>] (tcb_clksrc_init) from [<c00097cc>] (do_one_initcall+0x114/0x1d4)
      [<c00097cc>] (do_one_initcall) from [<c069bd54>] (kernel_init_freeable+0xfc/0x1b8)
      [<c069bd54>] (kernel_init_freeable) from [<c04c3818>] (kernel_init+0x8/0xe0)
      [<c04c3818>] (kernel_init) from [<c000a410>] (ret_from_fork+0x14/0x24)
      ---[ end trace 0000000000000001 ]---
      
      Check what state we were in before trying to disable the clock.
      
      Fixes: cf4541c1 ("clockevents/drivers/tcb_clksrc: Migrate to new 'set-state' interface")
      Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
      Cc: Nicolas Ferre <nicolas.ferre@atmel.com>
      Cc: Boris Brezillon <boris.brezillon@free-electrons.com>
      Cc: linux-arm-kernel@lists.infradead.org
      Cc: Daniel Lezcano <daniel.lezcano@linaro.org>
      Cc: stable@vger.kernel.org
      Link: http://lkml.kernel.org/r/1452854061-30370-1-git-send-email-alexandre.belloni@free-electrons.comSigned-off-by: NThomas Gleixner <tglx@linutronix.de>
      f02b4b72
  9. 12 1月, 2016 3 次提交
    • R
      clocksource/drivers/vt8500: Increase the minimum delta · f9eccf24
      Roman Volkov 提交于
      The vt8500 clocksource driver declares itself as capable to handle the
      minimum delay of 4 cycles by passing the value into
      clockevents_config_and_register(). The vt8500_timer_set_next_event()
      requires the passed cycles value to be at least 16. The impact is that
      userspace hangs in nanosleep() calls with small delay intervals.
      
      This problem is reproducible in Linux 4.2 starting from:
      c6eb3f70 ('hrtimer: Get rid of hrtimer softirq')
      
      From Russell King, more detailed explanation:
      
      "It's a speciality of the StrongARM/PXA hardware. It takes a certain
      number of OSCR cycles for the value written to hit the compare registers.
      So, if a very small delta is written (eg, the compare register is written
      with a value of OSCR + 1), the OSCR will have incremented past this value
      before it hits the underlying hardware. The result is, that you end up
      waiting a very long time for the OSCR to wrap before the event fires.
      
      So, we introduce a check in set_next_event() to detect this and return
      -ETIME if the calculated delta is too small, which causes the generic
      clockevents code to retry after adding the min_delta specified in
      clockevents_config_and_register() to the current time value.
      
      min_delta must be sufficient that we don't re-trip the -ETIME check - if
      we do, we will return -ETIME, forward the next event time, try to set it,
      return -ETIME again, and basically lock the system up. So, min_delta
      must be larger than the check inside set_next_event(). A factor of two
      was chosen to ensure that this situation would never occur.
      
      The PXA code worked on PXA systems for years, and I'd suggest no one
      changes this mechanism without access to a wide range of PXA systems,
      otherwise they're risking breakage."
      
      Cc: stable@vger.kernel.org
      Cc: Russell King <linux@arm.linux.org.uk>
      Acked-by: NAlexey Charkov <alchark@gmail.com>
      Signed-off-by: NRoman Volkov <rvolkov@v1ros.org>
      Signed-off-by: NDaniel Lezcano <daniel.lezcano@linaro.org>
      f9eccf24
    • D
      clocksource/drivers/fsl_ftm_timer: Fix CLKSRC_MMIO dependency · 03724ac3
      Daniel Lezcano 提交于
      Select CLKSRC_MMIO when FSL_FTM_TIMER is enabled. Otherwise it fails to
      compile on i386 with COMPILE_TEST=y.
      
      "
      on i386:
      when CLKSRC_MMIO is not enabled:
      
      drivers/built-in.o: In function `ftm_timer_init':
      fsl_ftm_timer.c:(.init.text+0x6842): undefined reference to `clocksource_mmio_readl_up'
      fsl_ftm_timer.c:(.init.text+0x6855): undefined reference to `clocksource_mmio_init'
      "
      Reported-by: NRandy Dunlap <rdunlap@infradead.org>
      Signed-off-by: NDaniel Lezcano <daniel.lezcano@linaro.org>
      03724ac3
    • R
      clocksource/drivers: Fix dependencies for !HAS_IOMEM archs · 863ee050
      Richard Weinberger 提交于
      Not every arch has io memory.
      
      So, unbreak the build by fixing the dependencies.
      Signed-off-by: NRichard Weinberger <richard@nod.at>
      Signed-off-by: NDaniel Lezcano <daniel.lezcano@linaro.org>
      863ee050
  10. 29 12月, 2015 1 次提交
  11. 17 12月, 2015 1 次提交
  12. 16 12月, 2015 11 次提交
  13. 15 12月, 2015 4 次提交