netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/4] ptp: do not explicitly set drvdata in ptp_clock_register()
@ 2017-02-14  3:51 Dmitry Torokhov
  2017-02-14  3:51 ` [PATCH 2/4] ptp: use kcalloc/kmallco_array when allocating arrays Dmitry Torokhov
                   ` (3 more replies)
  0 siblings, 4 replies; 9+ messages in thread
From: Dmitry Torokhov @ 2017-02-14  3:51 UTC (permalink / raw)
  To: Richard Cochran; +Cc: netdev, linux-kernel

We do not need explicitly call dev_set_drvdata(), as it is done for us by
device_create().

Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
---
 drivers/ptp/ptp_clock.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/drivers/ptp/ptp_clock.c b/drivers/ptp/ptp_clock.c
index 9c13381b6966..b4e5e8022c29 100644
--- a/drivers/ptp/ptp_clock.c
+++ b/drivers/ptp/ptp_clock.c
@@ -227,8 +227,6 @@ struct ptp_clock *ptp_clock_register(struct ptp_clock_info *info,
 	if (IS_ERR(ptp->dev))
 		goto no_device;
 
-	dev_set_drvdata(ptp->dev, ptp);
-
 	err = ptp_populate_sysfs(ptp);
 	if (err)
 		goto no_sysfs;
-- 
2.11.0.483.g087da7b7c-goog

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

end of thread, other threads:[~2017-02-14 18:13 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-02-14  3:51 [PATCH 1/4] ptp: do not explicitly set drvdata in ptp_clock_register() Dmitry Torokhov
2017-02-14  3:51 ` [PATCH 2/4] ptp: use kcalloc/kmallco_array when allocating arrays Dmitry Torokhov
2017-02-14  8:38   ` Richard Cochran
2017-02-14  3:51 ` [PATCH 3/4] ptp: use is_visible method to hide unused attributes Dmitry Torokhov
2017-02-14  8:42   ` Richard Cochran
2017-02-14 18:07     ` Dmitry Torokhov
2017-02-14 18:13       ` Richard Cochran
2017-02-14  3:51 ` [PATCH 4/4] ptp: create "pins" together with the rest of attributes Dmitry Torokhov
2017-02-14  8:30 ` [PATCH 1/4] ptp: do not explicitly set drvdata in ptp_clock_register() Richard Cochran

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).