[PATCH] regulator: wm8350: remove unused variable

Subsystems: the rest, voltage and current regulator framework, wolfson microelectronics drivers

STALE4170d

3 messages, 3 authors, 2015-03-05 · open the first message on its own page

[PATCH] regulator: wm8350: remove unused variable

From: Arnd Bergmann <arnd@arndb.de>
Date: 2015-02-26 13:28:37

After the only user of the variable has been removed, we get a valid gcc
warning about it:

regulator/wm8350-regulator.c:1154:17: warning: unused variable 'wm8350' [-Wunused-variable]

The obvious fix is to remove the variable as well.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Fixes: 8f45acb5f9f34 ("regulator: wm8350: Pass NULL data with REGULATION_OUT and UNDER_VOLTAGE events")
diff --git a/drivers/regulator/wm8350-regulator.c b/drivers/regulator/wm8350-regulator.c
index 78efead3b39f..95f6b040186e 100644
--- a/drivers/regulator/wm8350-regulator.c
+++ b/drivers/regulator/wm8350-regulator.c
@@ -1151,7 +1151,6 @@ static const struct regulator_desc wm8350_reg[NUM_WM8350_REGULATORS] = {
 static irqreturn_t pmic_uv_handler(int irq, void *data)
 {
 	struct regulator_dev *rdev = (struct regulator_dev *)data;
-	struct wm8350 *wm8350 = rdev_get_drvdata(rdev);
 
 	mutex_lock(&rdev->mutex);
 	if (irq == WM8350_IRQ_CS1 || irq == WM8350_IRQ_CS2)

Re: [PATCH] regulator: wm8350: remove unused variable

From: Geert Uytterhoeven <geert@linux-m68k.org>
Date: 2015-02-26 13:32:32

On Thu, Feb 26, 2015 at 11:29 AM, Arnd Bergmann [off-list ref] wrote:
After the only user of the variable has been removed, we get a valid gcc
warning about it:

regulator/wm8350-regulator.c:1154:17: warning: unused variable 'wm8350' [-Wunused-variable]

The obvious fix is to remove the variable as well.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Fixes: 8f45acb5f9f34 ("regulator: wm8350: Pass NULL data with REGULATION_OUT and UNDER_VOLTAGE events")
Acked-by: Geert Uytterhoeven <geert+renesas@glider.be>

Mea culpa. Second ack on the same patch today...

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert at linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds

Re: [PATCH] regulator: wm8350: remove unused variable

From: Mark Brown <broonie@kernel.org>
Date: 2015-03-05 17:57:01

On Thu, Feb 26, 2015 at 11:29:29AM +0100, Arnd Bergmann wrote:
After the only user of the variable has been removed, we get a valid gcc
warning about it:
I applied another fix for this, thanks.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 473 bytes
Desc: Digital signature
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20150305/748702c4/attachment.sig>
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help