Re: [PATCH] hwrng: bcm2835 - remove redundant null check

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 2/8/21 10:25 PM, Tian Tao wrote:
> clk_prepare_enable() and clk_disable_unprepare() will check
> NULL clock parameter, so It is not necessary to add additional checks.
> 
> Signed-off-by: Tian Tao <tiantao6@xxxxxxxxxxxxx>

I don't believe this is going to work unless you also change
devm_clk_get() to devm_clk_get_optional() which will deal with -ENOENT
and return NULL in that case, once you do that we can remove the NULL
pointer checks.
-- 
Florian



[Index of Archives]     [Kernel]     [Gnu Classpath]     [Gnu Crypto]     [DM Crypt]     [Netfilter]     [Bugtraq]

  Powered by Linux