Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

iio: frequency: adf4350: Remove redundant null check before clk_disable_unprepare

Because clk_disable_unprepare() already checked NULL clock parameter,
so the additional check is unnecessary, just remove it.

Signed-off-by: Xu Wang <vulab@iscas.ac.cn>
Link: https://lore.kernel.org/r/20201218094647.1386-1-vulab@iscas.ac.cn
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>

authored by

Xu Wang and committed by
Jonathan Cameron
07fe995f cef49e5e

+2 -4
+2 -4
drivers/iio/frequency/adf4350.c
··· 582 582 if (!IS_ERR(st->reg)) 583 583 regulator_disable(st->reg); 584 584 error_disable_clk: 585 - if (clk) 586 - clk_disable_unprepare(clk); 585 + clk_disable_unprepare(clk); 587 586 588 587 return ret; 589 588 } ··· 598 599 599 600 iio_device_unregister(indio_dev); 600 601 601 - if (st->clk) 602 - clk_disable_unprepare(st->clk); 602 + clk_disable_unprepare(st->clk); 603 603 604 604 if (!IS_ERR(reg)) 605 605 regulator_disable(reg);