Thread (3 messages) 3 messages, 2 authors, 2011-03-01

Re: [PATCH 3/6] FBDEV: JZ4740: Initialize framebuffer properly

flat view

From: Maurus Cuelenaere <hidden>
Date: 2011-03-01 17:21:36

On 03/01/2011 01:06 PM, Maurus Cuelenaere wrote:
quoted
Use the jzfb_enable() function instead of manually faking it in jzfb_probe().
Also add the reverse operation when the framebuffer couldn't be registered.

Signed-off-by: Maurus Cuelenaere <redacted>
---
 drivers/video/jz4740_fb.c |    8 +++-----
 1 files changed, 3 insertions(+), 5 deletions(-)
diff --git a/drivers/video/jz4740_fb.c b/drivers/video/jz4740_fb.c
index cea7b7e..2f3ea57 100644
--- a/drivers/video/jz4740_fb.c
+++ b/drivers/video/jz4740_fb.c
@@ -707,16 +707,13 @@ static int __devinit jzfb_probe(struct platform_device *pdev)
 
 	fb_alloc_cmap(&fb->cmap, 256, 0);
 
-	clk_enable(jzfb->ldclk);
-	jzfb->is_enabled = 1;
-
-	writel(jzfb->framedesc->next, jzfb->base + JZ_REG_LCD_DA0);
-
 	fb->mode = NULL;
 	jzfb_set_par(fb);
 
 	jzfb_pins_operation(jzfb, REQUEST_PINS);
 
+	jzfb_blank(FB_BLANK_UNBLANK, fb);
+
I'd prefer:
jzfb_enable(jzfb);
jzfb->is_enabled = 1;

since there is no need for locking here.
Ok.

-- 
Maurus Cuelenaere
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help