Commit 154502e1 authored by Paul Mundt's avatar Paul Mundt

sh: clkfwk: Convert SH-Mobile CPUs to use CLK_ENABLE_ON_INIT.

Kill off all of the clk_always_enabled leftovers and use the new flag
directly.
Signed-off-by: default avatarPaul Mundt <lethal@linux-sh.org>
parent 4ff29ff8
...@@ -52,22 +52,6 @@ void clk_recalc_rate(struct clk *); ...@@ -52,22 +52,6 @@ void clk_recalc_rate(struct clk *);
int clk_register(struct clk *); int clk_register(struct clk *);
void clk_unregister(struct clk *); void clk_unregister(struct clk *);
static inline int clk_always_enable(const char *id)
{
struct clk *clk;
int ret;
clk = clk_get(NULL, id);
if (IS_ERR(clk))
return PTR_ERR(clk);
ret = clk_enable(clk);
if (ret)
clk_put(clk);
return ret;
}
/* the exported API, in addition to clk_set_rate */ /* the exported API, in addition to clk_set_rate */
/** /**
* clk_set_rate_ex - set the clock rate for a clock source, with additional parameter * clk_set_rate_ex - set the clock rate for a clock source, with additional parameter
......
This diff is collapsed.
...@@ -223,12 +223,6 @@ static struct platform_device *sh7343_devices[] __initdata = { ...@@ -223,12 +223,6 @@ static struct platform_device *sh7343_devices[] __initdata = {
static int __init sh7343_devices_setup(void) static int __init sh7343_devices_setup(void)
{ {
clk_always_enable("uram0"); /* URAM */
clk_always_enable("xymem0"); /* XYMEM */
clk_always_enable("veu0"); /* VEU */
clk_always_enable("vpu0"); /* VPU */
clk_always_enable("jpu0"); /* JPU */
platform_resource_setup_memory(&vpu_device, "vpu", 1 << 20); platform_resource_setup_memory(&vpu_device, "vpu", 1 << 20);
platform_resource_setup_memory(&veu_device, "veu", 2 << 20); platform_resource_setup_memory(&veu_device, "veu", 2 << 20);
platform_resource_setup_memory(&jpu_device, "jpu", 2 << 20); platform_resource_setup_memory(&jpu_device, "jpu", 2 << 20);
......
...@@ -212,12 +212,6 @@ static struct platform_device *sh7366_devices[] __initdata = { ...@@ -212,12 +212,6 @@ static struct platform_device *sh7366_devices[] __initdata = {
static int __init sh7366_devices_setup(void) static int __init sh7366_devices_setup(void)
{ {
clk_always_enable("rsmem0"); /* RSMEM */
clk_always_enable("xymem0"); /* XYMEM */
clk_always_enable("veu1"); /* VEU-2 */
clk_always_enable("veu0"); /* VEU-1 */
clk_always_enable("vpu0"); /* VPU */
platform_resource_setup_memory(&vpu_device, "vpu", 2 << 20); platform_resource_setup_memory(&vpu_device, "vpu", 2 << 20);
platform_resource_setup_memory(&veu0_device, "veu0", 2 << 20); platform_resource_setup_memory(&veu0_device, "veu0", 2 << 20);
platform_resource_setup_memory(&veu1_device, "veu1", 2 << 20); platform_resource_setup_memory(&veu1_device, "veu1", 2 << 20);
......
...@@ -352,12 +352,6 @@ static struct platform_device *sh7722_devices[] __initdata = { ...@@ -352,12 +352,6 @@ static struct platform_device *sh7722_devices[] __initdata = {
static int __init sh7722_devices_setup(void) static int __init sh7722_devices_setup(void)
{ {
clk_always_enable("uram0"); /* URAM */
clk_always_enable("xymem0"); /* XYMEM */
clk_always_enable("veu0"); /* VEU */
clk_always_enable("vpu0"); /* VPU */
clk_always_enable("jpu0"); /* JPU */
platform_resource_setup_memory(&vpu_device, "vpu", 1 << 20); platform_resource_setup_memory(&vpu_device, "vpu", 1 << 20);
platform_resource_setup_memory(&veu_device, "veu", 2 << 20); platform_resource_setup_memory(&veu_device, "veu", 2 << 20);
platform_resource_setup_memory(&jpu_device, "jpu", 2 << 20); platform_resource_setup_memory(&jpu_device, "jpu", 2 << 20);
......
...@@ -460,11 +460,6 @@ static struct platform_device *sh7723_devices[] __initdata = { ...@@ -460,11 +460,6 @@ static struct platform_device *sh7723_devices[] __initdata = {
static int __init sh7723_devices_setup(void) static int __init sh7723_devices_setup(void)
{ {
clk_always_enable("meram0"); /* MERAM */
clk_always_enable("veu1"); /* VEU2H1 */
clk_always_enable("veu0"); /* VEU2H0 */
clk_always_enable("vpu0"); /* VPU */
platform_resource_setup_memory(&vpu_device, "vpu", 2 << 20); platform_resource_setup_memory(&vpu_device, "vpu", 2 << 20);
platform_resource_setup_memory(&veu0_device, "veu0", 2 << 20); platform_resource_setup_memory(&veu0_device, "veu0", 2 << 20);
platform_resource_setup_memory(&veu1_device, "veu1", 2 << 20); platform_resource_setup_memory(&veu1_device, "veu1", 2 << 20);
......
...@@ -281,10 +281,6 @@ static struct platform_device *sh7724_devices[] __initdata = { ...@@ -281,10 +281,6 @@ static struct platform_device *sh7724_devices[] __initdata = {
static int __init sh7724_devices_setup(void) static int __init sh7724_devices_setup(void)
{ {
clk_always_enable("vpu0"); /* VPU */
clk_always_enable("veu1"); /* VEU3F1 */
clk_always_enable("veu0"); /* VEU3F0 */
platform_resource_setup_memory(&vpu_device, "vpu", 2 << 20); platform_resource_setup_memory(&vpu_device, "vpu", 2 << 20);
platform_resource_setup_memory(&veu0_device, "veu0", 2 << 20); platform_resource_setup_memory(&veu0_device, "veu0", 2 << 20);
platform_resource_setup_memory(&veu1_device, "veu1", 2 << 20); platform_resource_setup_memory(&veu1_device, "veu1", 2 << 20);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment