ARM: shmobile: r8a7791: Wait for status on all MSTP clocks
authorShinya Kuribayashi <shinya.kuribayashi.px@renesas.com>
Wed, 8 Jan 2014 07:54:46 +0000 (08:54 +0100)
committerSimon Horman <horms@verge.net.au>
Fri, 5 Dec 2014 00:21:58 +0000 (09:21 +0900)
commit9dfb301c23fb1b89f8f7cc23457e773d0ec8f8a1
tree284ef061ab983cab702fe4b3f12006e40586431c
parentb0de4d028a4a02e9d68e9e10dc12afea8511e44d
ARM: shmobile: r8a7791: Wait for status on all MSTP clocks

When enabling a module clock by clearing its bit in the MSTP control
register, the CPG requires waiting for the status register to signal
that the clock has started. Failure to do so will result in returning
from the clk_enable() call with the clock potentially still disabled,
leading to various race conditions and difficult to debug errors.

Enable status wait for all MSTP clocks on the r8a7791.

Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Acked-by: Magnus Damm <damm@opensource.se>
Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
(cherry picked from commit dd6fc76d2f61e732a14f3592bdd83c2c0b7d2dcc)
Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
arch/arm/mach-shmobile/clock-r8a7791.c