[PATCH v1 12/34] j1939: main: add netdev_dbg on priv create and release

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



so we can make sure priv is always freed

Signed-off-by: Oleksij Rempel <o.rempel@xxxxxxxxxxxxxx>
---
 net/can/j1939/main.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/net/can/j1939/main.c b/net/can/j1939/main.c
index 8481c46c6b08..bdb6de2a25da 100644
--- a/net/can/j1939/main.c
+++ b/net/can/j1939/main.c
@@ -116,6 +116,7 @@ static struct j1939_priv *j1939_priv_create(struct net_device *ndev)
 	priv->ndev = ndev;
 	kref_init(&priv->kref);
 	dev_hold(ndev);
+	netdev_dbg(priv->ndev, "j1939_priv_create: 0x%p\n", priv);
 
 	return priv;
 }
@@ -141,6 +142,7 @@ static void __j1939_priv_release(struct kref *kref)
 
 	/* unlink from netdev */
 	j1939_priv_set(ndev, NULL);
+	netdev_dbg(priv->ndev, "__j1939_priv_release: 0x%p\n", priv);
 
 	dev_put(ndev);
 	kfree(priv);
-- 
2.20.1




[Index of Archives]     [Automotive Discussions]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]     [CAN Bus]

  Powered by Linux