lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [day] [month] [year] [list]
Message-Id: <1485334247-28996-1-git-send-email-benjamin.gaignard@st.com>
Date:   Wed, 25 Jan 2017 09:50:47 +0100
From:   Benjamin Gaignard <benjamin.gaignard@...aro.org>
To:     sfr@...b.auug.org.au, linux-next@...r.kernel.org,
        linux-kernel@...r.kernel.org, thierry.reding@...il.com,
        lee.jones@...aro.org
Cc:     Benjamin Gaignard <benjamin.gaignard@...com>
Subject: [PATCH] pwm: STM32 fix compilation warning

remove useless curstate variable.

Fixes: bafffb6e7bd1 ("pwm: Add driver for STM32 plaftorm")
Signed-off-by: Benjamin Gaignard <benjamin.gaignard@...com>
---
 drivers/pwm/pwm-stm32.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/pwm/pwm-stm32.c b/drivers/pwm/pwm-stm32.c
index ce6232e..6139512 100644
--- a/drivers/pwm/pwm-stm32.c
+++ b/drivers/pwm/pwm-stm32.c
@@ -189,7 +189,6 @@ static void stm32_pwm_disable(struct stm32_pwm *priv, int ch)
 static int stm32_pwm_apply(struct pwm_chip *chip, struct pwm_device *pwm,
 			   struct pwm_state *state)
 {
-	struct pwm_state curstate;
 	bool enabled;
 	struct stm32_pwm *priv = to_stm32_pwm_dev(chip);
 	int ret;
@@ -201,7 +200,7 @@ static int stm32_pwm_apply(struct pwm_chip *chip, struct pwm_device *pwm,
 		return 0;
 	}
 
-	if (state->polarity != curstate.polarity)
+	if (state->polarity != pwm->state.polarity)
 		stm32_pwm_set_polarity(priv, pwm->hwpwm, state->polarity);
 
 	ret = stm32_pwm_config(priv, pwm->hwpwm,
-- 
1.9.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ