diff options
author | Yuesong Li <liyuesong@vivo.com> | 2024-08-28 09:35:15 +0200 |
---|---|---|
committer | Stephen Boyd <sboyd@kernel.org> | 2024-08-28 22:11:21 +0200 |
commit | df7e70e38c6329016d17299431e7020c985660d3 (patch) | |
tree | a9a99f3b15b2d26161a65a5300d172e840291a93 /drivers/clk/davinci/da8xx-cfgchip.c | |
parent | clk: bcm: bcm53573: fix OF node leak in init (diff) | |
download | linux-df7e70e38c6329016d17299431e7020c985660d3.tar.xz linux-df7e70e38c6329016d17299431e7020c985660d3.zip |
clk:davinci: make use of dev_err_cast_probe()
Using dev_err_cast_probe() to simplify the code.
Signed-off-by: Yuesong Li <liyuesong@vivo.com>
Link: https://lore.kernel.org/r/20240828073515.950677-1-liyuesong@vivo.com
Reviewed-by: David Lechner <david@lechnology.com>
Signed-off-by: Stephen Boyd <sboyd@kernel.org>
Diffstat (limited to '')
-rw-r--r-- | drivers/clk/davinci/da8xx-cfgchip.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/clk/davinci/da8xx-cfgchip.c b/drivers/clk/davinci/da8xx-cfgchip.c index f6da66748573..a5109fe8b16e 100644 --- a/drivers/clk/davinci/da8xx-cfgchip.c +++ b/drivers/clk/davinci/da8xx-cfgchip.c @@ -513,8 +513,7 @@ da8xx_cfgchip_register_usb0_clk48(struct device *dev, fck_clk = devm_clk_get(dev, "fck"); if (IS_ERR(fck_clk)) { - dev_err_probe(dev, PTR_ERR(fck_clk), "Missing fck clock\n"); - return ERR_CAST(fck_clk); + return dev_err_cast_probe(dev, fck_clk, "Missing fck clock\n"); } usb0 = devm_kzalloc(dev, sizeof(*usb0), GFP_KERNEL); |