]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
video: fbdev: sis: delete double assignment
authorJulia Lawall <Julia.Lawall@lip6.fr>
Sat, 23 Aug 2014 18:33:27 +0000 (20:33 +0200)
committerTomi Valkeinen <tomi.valkeinen@ti.com>
Tue, 26 Aug 2014 12:53:35 +0000 (15:53 +0300)
Delete successive assignments to the same location.  The second assignment
is changed to update a different field, as done in other nearby code.

A simplified version of the semantic match that finds this problem is as
follows: (http://coccinelle.lip6.fr/)

// <smpl>
@@
expression i;
@@

*i = ...;
 i = ...;
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
drivers/video/fbdev/sis/init301.c

index a89e3cafd5adbfd6c2d8a1622b97c47a339aef81..295e0dedaf1feb14908145c1bab54451c2fbf86f 100644 (file)
@@ -1714,7 +1714,7 @@ SiS_GetLCDResInfo(struct SiS_Private *SiS_Pr, unsigned short ModeNo, unsigned sh
                               SiS_Pr->PanelVCLKIdx315 = VCLK81_315; /* ? */
                            } else {
                               SiS_Pr->PanelHT   = 1688; SiS_Pr->PanelVT   =  802;
-                              SiS_Pr->PanelHRS  =   48; SiS_Pr->PanelHRS  =  112;
+                              SiS_Pr->PanelHRS  =   48; SiS_Pr->PanelHRE  =  112;
                               SiS_Pr->PanelVRS  =    3; SiS_Pr->PanelVRE  =    6;
                               SiS_Pr->PanelVCLKIdx300 = VCLK81_300;
                               SiS_Pr->PanelVCLKIdx315 = VCLK81_315;