linux-i2c.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] i2c: mux: Remove unneeded platform_set_drvdata to NULL in remove
@ 2013-02-15 18:41 Doug Anderson
       [not found] ` <1360953682-25066-1-git-send-email-dianders-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>
  2013-02-15 23:18 ` [PATCH] i2c: Remove unneeded xxx_set_drvdata(..., NULL) calls Doug Anderson
  0 siblings, 2 replies; 11+ messages in thread
From: Doug Anderson @ 2013-02-15 18:41 UTC (permalink / raw)
  To: Wolfram Sang
  Cc: Stephen Warren, Doug Anderson, Peter Korsgaard,
	Ben Dooks (embedded platforms), linux-i2c, linux-kernel

Stephen Warren pointed out as part of a code review of another mux
driver that there should be no need to have
"platform_set_drvdata(pdev, NULL)" in the remove function.  Get rid of
it in the i2c-mux-gpio driver.

See Stephen's comment at:
  http://www.gossamer-threads.com/lists/linux/kernel/1678627?do=post_view_threaded#1678627

Signed-off-by: Doug Anderson <dianders@chromium.org>
---
 drivers/i2c/muxes/i2c-mux-gpio.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/i2c/muxes/i2c-mux-gpio.c b/drivers/i2c/muxes/i2c-mux-gpio.c
index 9f50ef0..abc2e55a 100644
--- a/drivers/i2c/muxes/i2c-mux-gpio.c
+++ b/drivers/i2c/muxes/i2c-mux-gpio.c
@@ -250,7 +250,6 @@ static int i2c_mux_gpio_remove(struct platform_device *pdev)
 	for (i = 0; i < mux->data.n_gpios; i++)
 		gpio_free(mux->gpio_base + mux->data.gpios[i]);
 
-	platform_set_drvdata(pdev, NULL);
 	i2c_put_adapter(mux->parent);
 
 	return 0;
-- 
1.8.1

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

end of thread, other threads:[~2013-02-21 10:48 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-02-15 18:41 [PATCH] i2c: mux: Remove unneeded platform_set_drvdata to NULL in remove Doug Anderson
     [not found] ` <1360953682-25066-1-git-send-email-dianders-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>
2013-02-15 19:37   ` Wolfram Sang
     [not found]     ` <20130215193736.GD4351-z923LK4zBo2bacvFa/9K2g@public.gmane.org>
2013-02-15 19:43       ` Doug Anderson
2013-02-15 19:53         ` Wolfram Sang
     [not found]           ` <20130215195347.GF4351-z923LK4zBo2bacvFa/9K2g@public.gmane.org>
2013-02-15 23:17             ` Doug Anderson
2013-02-15 23:18 ` [PATCH] i2c: Remove unneeded xxx_set_drvdata(..., NULL) calls Doug Anderson
     [not found]   ` <1360970315-32116-1-git-send-email-dianders-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>
2013-02-16 19:52     ` Jean Delvare
2013-02-21 10:48     ` Wolfram Sang
2013-02-17 15:12   ` Peter Korsgaard
2013-02-18 10:35   ` Mika Westerberg
2013-02-18 12:17   ` Marek Vasut

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).