All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] pwm: sun4i: redundant assignment to variable pval
@ 2019-10-02 10:08 ` Colin King
  0 siblings, 0 replies; 34+ messages in thread
From: Colin King @ 2019-10-02 10:08 UTC (permalink / raw)
  To: Thierry Reding, Uwe Kleine-König, Maxime Ripard,
	Chen-Yu Tsai, linux-pwm, linux-arm-kernel
  Cc: kernel-janitors, linux-kernel

From: Colin Ian King <colin.king@canonical.com>

Variable pval is being assigned a value that is never read. The
assignment is redundant and hence can be removed.

Addresses-Coverity: ("Unused value")
Signed-off-by: Colin Ian King <colin.king@canonical.com>
---
 drivers/pwm/pwm-sun4i.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/pwm/pwm-sun4i.c b/drivers/pwm/pwm-sun4i.c
index 6f5840a1a82d..53970d4ba695 100644
--- a/drivers/pwm/pwm-sun4i.c
+++ b/drivers/pwm/pwm-sun4i.c
@@ -156,7 +156,6 @@ static int sun4i_pwm_calculate(struct sun4i_pwm_chip *sun4i_pwm,
 	if (sun4i_pwm->data->has_prescaler_bypass) {
 		/* First, test without any prescaler when available */
 		prescaler = PWM_PRESCAL_MASK;
-		pval = 1;
 		/*
 		 * When not using any prescaler, the clock period in nanoseconds
 		 * is not an integer so round it half up instead of
-- 
2.20.1


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

end of thread, other threads:[~2019-12-10 10:24 UTC | newest]

Thread overview: 34+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-10-02 10:08 [PATCH] pwm: sun4i: redundant assignment to variable pval Colin King
2019-10-02 10:08 ` Colin King
2019-10-02 10:08 ` Colin King
2019-10-02 10:16 ` Uwe Kleine-König
2019-10-02 10:16   ` Uwe Kleine-König
2019-10-02 10:16   ` Uwe Kleine-König
2019-12-05  7:24   ` [PATCH] pwm: sun4i: Narrow scope of local variable Uwe Kleine-König
2019-12-05  7:24     ` Uwe Kleine-König
2019-12-05  8:37     ` walter harms
2019-12-05  8:37       ` walter harms
2019-12-10 10:12       ` Uwe Kleine-König
2019-12-10 10:12         ` Uwe Kleine-König
2019-12-10 10:12         ` Uwe Kleine-König
2019-12-10 10:24         ` [PATCH v2] " Uwe Kleine-König
2019-12-10 10:24           ` Uwe Kleine-König
2019-10-02 10:39 ` [PATCH] pwm: sun4i: redundant assignment to variable pval Thierry Reding
2019-10-02 10:39   ` Thierry Reding
2019-10-02 10:39   ` Thierry Reding
2019-10-02 13:25 ` Dan Carpenter
2019-10-02 13:25   ` Dan Carpenter
2019-10-02 13:25   ` Dan Carpenter
2019-10-02 13:25   ` Dan Carpenter
2019-10-02 13:28   ` Colin Ian King
2019-10-02 13:28     ` Colin Ian King
2019-10-02 13:28     ` Colin Ian King
2019-10-02 13:28     ` Colin Ian King
2019-10-02 13:29   ` Dan Carpenter
2019-10-02 13:29     ` Dan Carpenter
2019-10-02 13:29     ` Dan Carpenter
2019-10-02 13:29     ` Dan Carpenter
2019-10-02 13:30     ` Colin Ian King
2019-10-02 13:30       ` Colin Ian King
2019-10-02 13:30       ` Colin Ian King
2019-10-02 13:30       ` Colin Ian King

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.