diff options
author | Levente Kurusa <levex@linux.com> | 2013-12-19 16:03:36 +0100 |
---|---|---|
committer | Rafael J. Wysocki <rafael.j.wysocki@intel.com> | 2014-01-05 22:50:06 +0100 |
commit | 75365d04cd2d6fe04c9c52c69fd97b2d0a6c82ba (patch) | |
tree | 1ed9a54c7c2eceb5062585e4c6df00db3b8ac319 /drivers/pnp/card.c | |
parent | PNPACPI: check return value of pnp_add_device() (diff) | |
download | linux-75365d04cd2d6fe04c9c52c69fd97b2d0a6c82ba.tar.xz linux-75365d04cd2d6fe04c9c52c69fd97b2d0a6c82ba.zip |
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/card.c')
-rw-r--r-- | drivers/pnp/card.c | 1 |
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; } |