mirror of https://gitee.com/openkylin/linux.git
hsi: fix double kfree
When device_register() fails, kfree() is called in hsi_client_release(),
hence there is no need to call kfree in err3 again.
Fixes: a2aa24734d
("HSI: Add common DT binding for HSI client devices")
Signed-off-by: Geliang Tang <geliangtang@163.com>
Signed-off-by: Sebastian Reichel <sre@kernel.org>
This commit is contained in:
parent
c616ac28a5
commit
f098a04535
|
@ -300,7 +300,6 @@ static void hsi_add_client_from_dt(struct hsi_port *port,
|
|||
if (device_register(&cl->device) < 0) {
|
||||
pr_err("hsi: failed to register client: %s\n", name);
|
||||
put_device(&cl->device);
|
||||
goto err3;
|
||||
}
|
||||
|
||||
return;
|
||||
|
|
Loading…
Reference in New Issue