powerpc/cacheinfo: Remove double free
kfree() after kobject_put(). Who ever wrote this was on crack.
Fixes: 7e8039795a
("powerpc/cacheinfo: Fix kobject memleak")
Signed-off-by: Tobin C. Harding <tobin@kernel.org>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
This commit is contained in:
parent
c179976cf4
commit
672eaf37db
|
@ -767,7 +767,6 @@ static void cacheinfo_create_index_dir(struct cache *cache, int index,
|
||||||
cache_dir->kobj, "index%d", index);
|
cache_dir->kobj, "index%d", index);
|
||||||
if (rc) {
|
if (rc) {
|
||||||
kobject_put(&index_dir->kobj);
|
kobject_put(&index_dir->kobj);
|
||||||
kfree(index_dir);
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue