]> www.infradead.org Git - users/dwmw2/linux.git/commit
clk: sifive: Do not register clkdevs for PRCI clocks
authorSamuel Holland <samuel.holland@sifive.com>
Tue, 28 May 2024 00:14:12 +0000 (17:14 -0700)
committerStephen Boyd <sboyd@kernel.org>
Wed, 29 May 2024 19:31:02 +0000 (12:31 -0700)
commit2607133196c35f31892ee199ce7ffa717bea4ad1
treee46908457680778f95d4f0c580166a51e87ec4a5
parent1613e604df0cd359cf2a7fbd9be7a0bcfacfabd0
clk: sifive: Do not register clkdevs for PRCI clocks

These clkdevs were unnecessary, because systems using this driver always
look up clocks using the devicetree. And as Russell King points out[1],
since the provided device name was truncated, lookups via clkdev would
never match.

Recently, commit 8d532528ff6a ("clkdev: report over-sized strings when
creating clkdev entries") caused clkdev registration to fail due to the
truncation, and this now prevents the driver from probing. Fix the
driver by removing the clkdev registration.

Link: https://lore.kernel.org/linux-clk/ZkfYqj+OcAxd9O2t@shell.armlinux.org.uk/
Fixes: 30b8e27e3b58 ("clk: sifive: add a driver for the SiFive FU540 PRCI IP block")
Fixes: 8d532528ff6a ("clkdev: report over-sized strings when creating clkdev entries")
Reported-by: Guenter Roeck <linux@roeck-us.net>
Closes: https://lore.kernel.org/linux-clk/7eda7621-0dde-4153-89e4-172e4c095d01@roeck-us.net/
Suggested-by: Russell King <linux@armlinux.org.uk>
Signed-off-by: Samuel Holland <samuel.holland@sifive.com>
Link: https://lore.kernel.org/r/20240528001432.1200403-1-samuel.holland@sifive.com
Signed-off-by: Stephen Boyd <sboyd@kernel.org>
drivers/clk/sifive/sifive-prci.c