summaryrefslogtreecommitdiff
path: root/drivers/pnp
diff options
context:
space:
mode:
authorLevente Kurusa <levex@linux.com>2013-12-19 19:03:36 +0400
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>2014-01-06 01:50:06 +0400
commit75365d04cd2d6fe04c9c52c69fd97b2d0a6c82ba (patch)
tree1ed9a54c7c2eceb5062585e4c6df00db3b8ac319 /drivers/pnp
parent249135d1a2ea3c1719c48d31351413d55d2fdef4 (diff)
downloadlinux-75365d04cd2d6fe04c9c52c69fd97b2d0a6c82ba.tar.xz
PNP / card: add missing put_device() call
This is required so that we give up the last reference to the device. Signed-off-by: Levente Kurusa <levex@linux.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'drivers/pnp')
-rw-r--r--drivers/pnp/card.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/pnp/card.c b/drivers/pnp/card.c
index bc00693d0c79..874c236ac1a7 100644
--- a/drivers/pnp/card.c
+++ b/drivers/pnp/card.c
@@ -239,6 +239,7 @@ int pnp_add_card(struct pnp_card *card)
error = device_register(&card->dev);
if (error) {
dev_err(&card->dev, "could not register (err=%d)\n", error);
+ put_device(&card->dev);
return error;
}