Re: [PATCH] soc: rockchip: power-domain: Add a sanity check on pd->num_clks

2018-03-05 Thread Heiko Stübner
Am Montag, 5. März 2018, 10:17:22 CET schrieb Jeffy Chen: > The of_count_phandle_with_args() can fail and return error(for example, > rk3399 pd_vio doesn't have clocks). That would break the pd probe. > > Add a sanity check on pd->num_clks to avoid that. > > Fixes: 65084121d59d ("soc: rockchip:

Re: [PATCH] soc: rockchip: power-domain: Add a sanity check on pd->num_clks

2018-03-05 Thread Heiko Stübner
Am Montag, 5. März 2018, 10:17:22 CET schrieb Jeffy Chen: > The of_count_phandle_with_args() can fail and return error(for example, > rk3399 pd_vio doesn't have clocks). That would break the pd probe. > > Add a sanity check on pd->num_clks to avoid that. > > Fixes: 65084121d59d ("soc: rockchip:

Re: [PATCH] soc: rockchip: power-domain: Add a sanity check on pd->num_clks

2018-03-05 Thread Shawn Lin
Hi Jeffy, On 2018/3/5 17:17, Jeffy Chen wrote: The of_count_phandle_with_args() can fail and return error(for example, rk3399 pd_vio doesn't have clocks). That would break the pd probe. Add a sanity check on pd->num_clks to avoid that. Fixes: 65084121d59d ("soc: rockchip: power-domain: use

Re: [PATCH] soc: rockchip: power-domain: Add a sanity check on pd->num_clks

2018-03-05 Thread Shawn Lin
Hi Jeffy, On 2018/3/5 17:17, Jeffy Chen wrote: The of_count_phandle_with_args() can fail and return error(for example, rk3399 pd_vio doesn't have clocks). That would break the pd probe. Add a sanity check on pd->num_clks to avoid that. Fixes: 65084121d59d ("soc: rockchip: power-domain: use

[PATCH] soc: rockchip: power-domain: Add a sanity check on pd->num_clks

2018-03-05 Thread Jeffy Chen
The of_count_phandle_with_args() can fail and return error(for example, rk3399 pd_vio doesn't have clocks). That would break the pd probe. Add a sanity check on pd->num_clks to avoid that. Fixes: 65084121d59d ("soc: rockchip: power-domain: use clk_bulk APIs") Reported-by: Shawn Lin

[PATCH] soc: rockchip: power-domain: Add a sanity check on pd->num_clks

2018-03-05 Thread Jeffy Chen
The of_count_phandle_with_args() can fail and return error(for example, rk3399 pd_vio doesn't have clocks). That would break the pd probe. Add a sanity check on pd->num_clks to avoid that. Fixes: 65084121d59d ("soc: rockchip: power-domain: use clk_bulk APIs") Reported-by: Shawn Lin