clk: lmk04832: fix return value check in lmk04832_probe()
authorWang Hai <wanghai38@huawei.com>
Wed, 30 Jun 2021 02:03:22 +0000 (10:03 +0800)
committerStephen Boyd <sboyd@kernel.org>
Wed, 30 Jun 2021 18:18:25 +0000 (11:18 -0700)
commitb424f73b6c017f907fd4018bd109d62b237f7875
tree6d4775b4622530d63f3285517feaab36b9a2f2a6
parentb1f247714acb2a78452ba555807764b2c1115a40
clk: lmk04832: fix return value check in lmk04832_probe()

In case of error, the function devm_kzalloc() and devm_kcalloc() return
NULL pointer not ERR_PTR(). The IS_ERR() test in the return value check
should be replaced with NULL test.

Fixes: 3bc61cfd6f4a ("clk: add support for the lmk04832")
Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Wang Hai <wanghai38@huawei.com>
Link: https://lore.kernel.org/r/20210630020322.2555946-1-wanghai38@huawei.com
Reviewed-by: Liam Beguin <lvb@xiphos.com>
Signed-off-by: Stephen Boyd <sboyd@kernel.org>
drivers/clk/clk-lmk04832.c