diff options
Diffstat (limited to 'drivers/video/amba-clcd.c')
-rw-r--r-- | drivers/video/amba-clcd.c | 16 |
1 files changed, 4 insertions, 12 deletions
diff --git a/drivers/video/amba-clcd.c b/drivers/video/amba-clcd.c index a3c2c45e29e0..0da4083ba908 100644 --- a/drivers/video/amba-clcd.c +++ b/drivers/video/amba-clcd.c | |||
@@ -21,12 +21,11 @@ | |||
21 | #include <linux/init.h> | 21 | #include <linux/init.h> |
22 | #include <linux/ioport.h> | 22 | #include <linux/ioport.h> |
23 | #include <linux/list.h> | 23 | #include <linux/list.h> |
24 | #include <linux/amba/bus.h> | ||
25 | #include <linux/amba/clcd.h> | ||
26 | #include <linux/clk.h> | ||
24 | 27 | ||
25 | #include <asm/sizes.h> | 28 | #include <asm/sizes.h> |
26 | #include <asm/hardware/amba.h> | ||
27 | #include <asm/hardware/clock.h> | ||
28 | |||
29 | #include <asm/hardware/amba_clcd.h> | ||
30 | 29 | ||
31 | #define to_clcd(info) container_of(info, struct clcd_fb, fb) | 30 | #define to_clcd(info) container_of(info, struct clcd_fb, fb) |
32 | 31 | ||
@@ -346,10 +345,6 @@ static int clcdfb_register(struct clcd_fb *fb) | |||
346 | goto out; | 345 | goto out; |
347 | } | 346 | } |
348 | 347 | ||
349 | ret = clk_use(fb->clk); | ||
350 | if (ret) | ||
351 | goto free_clk; | ||
352 | |||
353 | fb->fb.fix.mmio_start = fb->dev->res.start; | 348 | fb->fb.fix.mmio_start = fb->dev->res.start; |
354 | fb->fb.fix.mmio_len = SZ_4K; | 349 | fb->fb.fix.mmio_len = SZ_4K; |
355 | 350 | ||
@@ -357,7 +352,7 @@ static int clcdfb_register(struct clcd_fb *fb) | |||
357 | if (!fb->regs) { | 352 | if (!fb->regs) { |
358 | printk(KERN_ERR "CLCD: unable to remap registers\n"); | 353 | printk(KERN_ERR "CLCD: unable to remap registers\n"); |
359 | ret = -ENOMEM; | 354 | ret = -ENOMEM; |
360 | goto unuse_clk; | 355 | goto free_clk; |
361 | } | 356 | } |
362 | 357 | ||
363 | fb->fb.fbops = &clcdfb_ops; | 358 | fb->fb.fbops = &clcdfb_ops; |
@@ -427,8 +422,6 @@ static int clcdfb_register(struct clcd_fb *fb) | |||
427 | printk(KERN_ERR "CLCD: cannot register framebuffer (%d)\n", ret); | 422 | printk(KERN_ERR "CLCD: cannot register framebuffer (%d)\n", ret); |
428 | 423 | ||
429 | iounmap(fb->regs); | 424 | iounmap(fb->regs); |
430 | unuse_clk: | ||
431 | clk_unuse(fb->clk); | ||
432 | free_clk: | 425 | free_clk: |
433 | clk_put(fb->clk); | 426 | clk_put(fb->clk); |
434 | out: | 427 | out: |
@@ -489,7 +482,6 @@ static int clcdfb_remove(struct amba_device *dev) | |||
489 | clcdfb_disable(fb); | 482 | clcdfb_disable(fb); |
490 | unregister_framebuffer(&fb->fb); | 483 | unregister_framebuffer(&fb->fb); |
491 | iounmap(fb->regs); | 484 | iounmap(fb->regs); |
492 | clk_unuse(fb->clk); | ||
493 | clk_put(fb->clk); | 485 | clk_put(fb->clk); |
494 | 486 | ||
495 | fb->board->remove(fb); | 487 | fb->board->remove(fb); |