diff options
author | Johan Hovold <johan@kernel.org> | 2018-06-12 14:43:34 +0200 |
---|---|---|
committer | Borislav Petkov <bp@suse.de> | 2018-06-17 13:09:44 +0200 |
commit | 4708aa85d50cc6e962dfa8acf5ad4e0d290a21db (patch) | |
tree | fad36b23fc027cd1d0bb171025af0fdb4ad347cb /drivers/macintosh/windfarm_smu_sat.c | |
parent | EDAC, altera: Fix an error handling path in altr_s10_sdram_probe() (diff) | |
download | linux-4708aa85d50cc6e962dfa8acf5ad4e0d290a21db.tar.xz linux-4708aa85d50cc6e962dfa8acf5ad4e0d290a21db.zip |
EDAC: Fix memleak in module init error path
Make sure to use put_device() to free the initialised struct device so
that resources managed by driver core also gets released in the event of
a registration failure.
Signed-off-by: Johan Hovold <johan@kernel.org>
Cc: Denis Kirjanov <kirjanov@gmail.com>
Cc: Mauro Carvalho Chehab <mchehab@kernel.org>
Cc: linux-edac <linux-edac@vger.kernel.org>
Fixes: 2d56b109e3a5 ("EDAC: Handle error path in edac_mc_sysfs_init() properly")
Link: http://lkml.kernel.org/r/20180612124335.6420-1-johan@kernel.org
Signed-off-by: Borislav Petkov <bp@suse.de>
Diffstat (limited to 'drivers/macintosh/windfarm_smu_sat.c')
0 files changed, 0 insertions, 0 deletions