All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] video: fbdev: aty: remove useless variable assignments in aty_var_to_crtc()
@ 2017-06-26 22:05   ` Gustavo A. R. Silva
  0 siblings, 0 replies; 4+ messages in thread
From: Gustavo A. R. Silva @ 2017-06-26 22:05 UTC (permalink / raw)
  To: Bartlomiej Zolnierkiewicz; +Cc: linux-fbdev, linux-kernel, Gustavo A. R. Silva

Value assigned to variable vdisplay at line 990 is overwritten
at line 1039 before it can be used. Also, variable assignment
at line 987 is the same as at line 1039. This makes such
variable assignments useless.

Remove these variable assignments and the code related.

Addresses-Covertity-ID: 1226900
Signed-off-by: Gustavo A. R. Silva <garsilva@embeddedor.com>
---
 drivers/video/fbdev/aty/atyfb_base.c | 6 ------
 1 file changed, 6 deletions(-)

diff --git a/drivers/video/fbdev/aty/atyfb_base.c b/drivers/video/fbdev/aty/atyfb_base.c
index 11026e7..3142d7f 100644
--- a/drivers/video/fbdev/aty/atyfb_base.c
+++ b/drivers/video/fbdev/aty/atyfb_base.c
@@ -984,12 +984,6 @@ static int aty_var_to_crtc(const struct fb_info *info,
 		v_total <<= 1;
 	}
 
-	vdisplay = yres;
-#ifdef CONFIG_FB_ATY_GENERIC_LCD
-	if ((par->lcd_table != 0) && (crtc->lcd_gen_cntl & LCD_ON))
-		vdisplay  = par->lcd_height;
-#endif
-
 	v_disp--;
 	v_sync_strt--;
 	v_sync_end--;
-- 
2.5.0

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [PATCH] video: fbdev: aty: remove useless variable assignments in aty_var_to_crtc()
@ 2017-06-26 22:05   ` Gustavo A. R. Silva
  0 siblings, 0 replies; 4+ messages in thread
From: Gustavo A. R. Silva @ 2017-06-26 22:05 UTC (permalink / raw)
  To: Bartlomiej Zolnierkiewicz; +Cc: linux-fbdev, linux-kernel, Gustavo A. R. Silva

Value assigned to variable vdisplay at line 990 is overwritten
at line 1039 before it can be used. Also, variable assignment
at line 987 is the same as at line 1039. This makes such
variable assignments useless.

Remove these variable assignments and the code related.

Addresses-Covertity-ID: 1226900
Signed-off-by: Gustavo A. R. Silva <garsilva@embeddedor.com>
---
 drivers/video/fbdev/aty/atyfb_base.c | 6 ------
 1 file changed, 6 deletions(-)

diff --git a/drivers/video/fbdev/aty/atyfb_base.c b/drivers/video/fbdev/aty/atyfb_base.c
index 11026e7..3142d7f 100644
--- a/drivers/video/fbdev/aty/atyfb_base.c
+++ b/drivers/video/fbdev/aty/atyfb_base.c
@@ -984,12 +984,6 @@ static int aty_var_to_crtc(const struct fb_info *info,
 		v_total <<= 1;
 	}
 
-	vdisplay = yres;
-#ifdef CONFIG_FB_ATY_GENERIC_LCD
-	if ((par->lcd_table != 0) && (crtc->lcd_gen_cntl & LCD_ON))
-		vdisplay  = par->lcd_height;
-#endif
-
 	v_disp--;
 	v_sync_strt--;
 	v_sync_end--;
-- 
2.5.0


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] video: fbdev: aty: remove useless variable assignments in aty_var_to_crtc()
  2017-06-26 22:05   ` Gustavo A. R. Silva
@ 2017-07-04 15:00     ` Bartlomiej Zolnierkiewicz
  -1 siblings, 0 replies; 4+ messages in thread
From: Bartlomiej Zolnierkiewicz @ 2017-07-04 15:00 UTC (permalink / raw)
  To: Gustavo A. R. Silva; +Cc: linux-fbdev, linux-kernel

On Monday, June 26, 2017 05:05:18 PM Gustavo A. R. Silva wrote:
> Value assigned to variable vdisplay at line 990 is overwritten
> at line 1039 before it can be used. Also, variable assignment
> at line 987 is the same as at line 1039. This makes such
> variable assignments useless.
> 
> Remove these variable assignments and the code related.
> 
> Addresses-Covertity-ID: 1226900
> Signed-off-by: Gustavo A. R. Silva <garsilva@embeddedor.com>

Patch queued for 4.13, thanks.

Best regards,
--
Bartlomiej Zolnierkiewicz
Samsung R&D Institute Poland
Samsung Electronics

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] video: fbdev: aty: remove useless variable assignments in aty_var_to_crtc()
@ 2017-07-04 15:00     ` Bartlomiej Zolnierkiewicz
  0 siblings, 0 replies; 4+ messages in thread
From: Bartlomiej Zolnierkiewicz @ 2017-07-04 15:00 UTC (permalink / raw)
  To: Gustavo A. R. Silva; +Cc: linux-fbdev, linux-kernel

On Monday, June 26, 2017 05:05:18 PM Gustavo A. R. Silva wrote:
> Value assigned to variable vdisplay at line 990 is overwritten
> at line 1039 before it can be used. Also, variable assignment
> at line 987 is the same as at line 1039. This makes such
> variable assignments useless.
> 
> Remove these variable assignments and the code related.
> 
> Addresses-Covertity-ID: 1226900
> Signed-off-by: Gustavo A. R. Silva <garsilva@embeddedor.com>

Patch queued for 4.13, thanks.

Best regards,
--
Bartlomiej Zolnierkiewicz
Samsung R&D Institute Poland
Samsung Electronics


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2017-07-04 15:01 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <CGME20170626220521epcas2p21e20ebaf7d36ec6d7a5cd54b81afdb4c@epcas2p2.samsung.com>
2017-06-26 22:05 ` [PATCH] video: fbdev: aty: remove useless variable assignments in aty_var_to_crtc() Gustavo A. R. Silva
2017-06-26 22:05   ` Gustavo A. R. Silva
2017-07-04 15:00   ` Bartlomiej Zolnierkiewicz
2017-07-04 15:00     ` Bartlomiej Zolnierkiewicz

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.