Re: [PATCH 34/57] fbdev: sh_mobile_lcdc: Store the format in struct

From
Guennadi Liakhovetski <hidden>
Date
2011-12-15 22:29:29
Also in
linux-sh
Reply to
Laurent Pinchart, 2011-12-13
On Tue, 13 Dec 2011, Laurent Pinchart wrote:
Store the active format in the channel structure, and use it instead of
parsing info->var all over the place when the format is needed.
Right, this is what I was wondering about, while looking at the previous 
patch:-) But:
quoted hunk ↗ jump to hunk
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
---
 drivers/video/sh_mobile_lcdcfb.c |   21 ++++++++++-----------
 drivers/video/sh_mobile_lcdcfb.h |    4 +++-
 2 files changed, 13 insertions(+), 12 deletions(-)
diff --git a/drivers/video/sh_mobile_lcdcfb.c b/drivers/video/sh_mobile_lcdcfb.c
index c6b6b9d..9829e01 100644
--- a/drivers/video/sh_mobile_lcdcfb.c
+++ b/drivers/video/sh_mobile_lcdcfb.c
[snip]
quoted hunk ↗ jump to hunk
@@ -1350,6 +1345,8 @@ static int sh_mobile_set_par(struct fb_info *info)
 		info->fix.line_length = info->var.xres
 				      * info->var.bits_per_pixel / 8;
 
+	ch->format = sh_mobile_format_info(sh_mobile_format_fourcc(&info->var));
Cannot this be NULL? As far as I could trace it back, I'm not sure with 
hotplug bits_per_pixel would be initialised correctly along the lines of 
sh_mobile_fb_reconfig().

Thanks
Guennadi
---
Guennadi Liakhovetski, Ph.D.
Freelance Open-Source Software Developer
http://www.open-technology.de/
Thread (3 messages) 3 messages, 2 authors, last reply 2011-12-16
Keyboard shortcuts
hback out one level
jnext message in thread / next series-diff position
kprevious message in thread / previous series-diff position
ldrill in
Escclose help / fold thread tree
?toggle this help