forked from luck/tmp_suning_uos_patched
remoteproc: qcom: Fix potential device node leaks
Add missing of_node_put()s at two places for device nodes returned by
of_parse_phandle().
Fixes: 051fb70fd4
("remoteproc: qcom: Driver for the self-authenticating
Hexagon v5")
Signed-off-by: Tobias Jordan <Tobias.Jordan@elektrobit.com>
Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
This commit is contained in:
parent
fcd58037f2
commit
278d744c46
|
@ -1083,6 +1083,7 @@ static int q6v5_alloc_memory_region(struct q6v5 *qproc)
|
|||
dev_err(qproc->dev, "unable to resolve mba region\n");
|
||||
return ret;
|
||||
}
|
||||
of_node_put(node);
|
||||
|
||||
qproc->mba_phys = r.start;
|
||||
qproc->mba_size = resource_size(&r);
|
||||
|
@ -1100,6 +1101,7 @@ static int q6v5_alloc_memory_region(struct q6v5 *qproc)
|
|||
dev_err(qproc->dev, "unable to resolve mpss region\n");
|
||||
return ret;
|
||||
}
|
||||
of_node_put(node);
|
||||
|
||||
qproc->mpss_phys = qproc->mpss_reloc = r.start;
|
||||
qproc->mpss_size = resource_size(&r);
|
||||
|
|
Loading…
Reference in New Issue
Block a user