* [PATCH 18/38] ia64: kernel: add missing put_device call
[not found] <1387465429-3568-2-git-send-email-levex@linux.com>
@ 2013-12-19 15:03 ` Levente Kurusa
0 siblings, 0 replies; only message in thread
From: Levente Kurusa @ 2013-12-19 15:03 UTC (permalink / raw)
To: LKML; +Cc: Levente Kurusa, Tony Luck, Fenghua Yu, Jiri Kosina, linux-ia64
This is required so that we give up the last reference to the device.
Removed kfree() as put_device() will result in tiocx_bus_release called.
Signed-off-by: Levente Kurusa <levex@linux.com>
---
arch/ia64/sn/kernel/tiocx.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/ia64/sn/kernel/tiocx.c b/arch/ia64/sn/kernel/tiocx.c
index e35f648..6f369cc 100644
--- a/arch/ia64/sn/kernel/tiocx.c
+++ b/arch/ia64/sn/kernel/tiocx.c
@@ -209,7 +209,7 @@ cx_device_register(nasid_t nasid, int part_num, int mfg_num,
dev_set_name(&cx_dev->dev, "%d", cx_dev->cx_id.nasid);
r = device_register(&cx_dev->dev);
if (r) {
- kfree(cx_dev);
+ put_device(&cx_dev->dev);
return r;
}
get_device(&cx_dev->dev);
--
1.8.3.1
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2013-12-19 15:03 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <1387465429-3568-2-git-send-email-levex@linux.com>
2013-12-19 15:03 ` [PATCH 18/38] ia64: kernel: add missing put_device call Levente Kurusa
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox