Skip to contentSkip to conversation

s3c-fb: Fix mixed code and variable declaration

PATCH In review Mark Brown 2 participants 2 messages Jan 15, 2010 – Jan 16, 2010 Framebuffer layer

lore
Share & tools
lore

Mark Brown

author
#0 lore raw

PATCH 1/1 s3c-fb: Fix mixed code and variable declaration

Hoist osdc_data up into the variable declaration section.

---
 drivers/video/s3c-fb.c |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)
drivers/video/s3c-fb.c +1 -2
index e2e7afd..58e2fed 100644
@@ -269,6 +269,7 @@ static int s3c_fb_set_par(struct fb_info *info)
 	int win_no = win->index;
 	u32 data;
 	u32 pagewidth;
+	u32 osdc_data;
 	int clkdiv;
 
 	dev_dbg(sfb->dev, "setting framebuffer parameters\n");
@@ -359,8 +360,6 @@ static int s3c_fb_set_par(struct fb_info *info)
 
 	data = var->xres * var->yres;
 
-	u32 osdc_data = 0;
-
 	osdc_data = VIDISD14C_ALPHA1_R(0xf) |
 		VIDISD14C_ALPHA1_G(0xf) |
 		VIDISD14C_ALPHA1_B(0xf);
Signature · 1 line
1.6.6
Acked-by on v1 1/1
#1 lore raw
Quoted 4 lines · Mark Brown

Hoist osdc_data up into the variable declaration section.

Quoted 28 lines
---
 drivers/video/s3c-fb.c |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)
drivers/video/s3c-fb.c +1 -2
index e2e7afd..58e2fed 100644
@@ -269,6 +269,7 @@ static int s3c_fb_set_par(struct fb_info *info)
 	int win_no = win->index;
 	u32 data;
 	u32 pagewidth;
+	u32 osdc_data;
 	int clkdiv;
 
 	dev_dbg(sfb->dev, "setting framebuffer parameters\n");
@@ -359,8 +360,6 @@ static int s3c_fb_set_par(struct fb_info *info)
 
 	data = var->xres * var->yres;
 
-	u32 osdc_data = 0;
-
 	osdc_data = VIDISD14C_ALPHA1_R(0xf) |
 		VIDISD14C_ALPHA1_G(0xf) |
 		VIDISD14C_ALPHA1_B(0xf);
Signature · 1 line
1.6.6
Signature · 5 lines
-- 
Ben

Q:      What's a light-year?
A:      One-third less calories than a regular year.