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

pwm: sifive: Simplify code to determine the pwmchip's parent device

There is already a pointer to the pwmchip, make use of it directly
instead of using the struct pwm_sifive_ddata *ddata just obtained from
it. This also has the advantage of not using struct
pwm_sifive_ddata::chip any more which will be dropped soon.

Link: https://lore.kernel.org/r/78da5070d3ff5767da6f1c053d069c1e25229375.1707900770.git.u.kleine-koenig@pengutronix.de
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>

+1 -1
+1 -1
drivers/pwm/pwm-sifive.c
··· 185 185 if (!enabled) { 186 186 ret = clk_enable(ddata->clk); 187 187 if (ret) { 188 - dev_err(ddata->chip.dev, "Enable clk failed\n"); 188 + dev_err(chip->dev, "Enable clk failed\n"); 189 189 return ret; 190 190 } 191 191 }