clk: boston: fix possible memory leak in clk_boston_setup()
authorYi Wang <wang.yi59@zte.com.cn>
Wed, 31 Oct 2018 07:41:41 +0000 (15:41 +0800)
committerStephen Boyd <sboyd@kernel.org>
Thu, 8 Nov 2018 18:14:39 +0000 (10:14 -0800)
commit46fda5b5067a391912cf73bf3d32c26b6a22ad09
treea81650fcf3e40e03691ee8464541b3a73c94d70a
parent651022382c7f8da46cb4872a545ee1da6d097d2a
clk: boston: fix possible memory leak in clk_boston_setup()

Smatch report warnings:
drivers/clk/imgtec/clk-boston.c:76 clk_boston_setup() warn: possible memory leak of 'onecell'
drivers/clk/imgtec/clk-boston.c:83 clk_boston_setup() warn: possible memory leak of 'onecell'
drivers/clk/imgtec/clk-boston.c:90 clk_boston_setup() warn: possible memory leak of 'onecell'

'onecell' is malloced in clk_boston_setup(), but not be freed
before leaving from the error handling cases.

Signed-off-by: Yi Wang <wang.yi59@zte.com.cn>
Signed-off-by: Stephen Boyd <sboyd@kernel.org>
drivers/clk/imgtec/clk-boston.c