Patch "clk: sifive: Do not register clkdevs for PRCI clocks" has been added to the 5.4-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    clk: sifive: Do not register clkdevs for PRCI clocks

to the 5.4-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     clk-sifive-do-not-register-clkdevs-for-prci-clocks.patch
and it can be found in the queue-5.4 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit b0091af68f4e670ec34dedc4d0a8b6abb5833e72
Author: Samuel Holland <samuel.holland@xxxxxxxxxx>
Date:   Mon May 27 17:14:12 2024 -0700

    clk: sifive: Do not register clkdevs for PRCI clocks
    
    [ Upstream commit 2607133196c35f31892ee199ce7ffa717bea4ad1 ]
    
    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@xxxxxxxxxxxxxxxxxxxxx/ [1]
    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@xxxxxxxxxxxx>
    Closes: https://lore.kernel.org/linux-clk/7eda7621-0dde-4153-89e4-172e4c095d01@xxxxxxxxxxxx/
    Suggested-by: Russell King <linux@xxxxxxxxxxxxxxx>
    Signed-off-by: Samuel Holland <samuel.holland@xxxxxxxxxx>
    Link: https://lore.kernel.org/r/20240528001432.1200403-1-samuel.holland@xxxxxxxxxx
    Signed-off-by: Stephen Boyd <sboyd@xxxxxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/drivers/clk/sifive/sifive-prci.c b/drivers/clk/sifive/sifive-prci.c
index 70653d33f33fe..b043180ad3e5d 100644
--- a/drivers/clk/sifive/sifive-prci.c
+++ b/drivers/clk/sifive/sifive-prci.c
@@ -4,7 +4,6 @@
  * Copyright (C) 2020 Zong Li
  */
 
-#include <linux/clkdev.h>
 #include <linux/delay.h>
 #include <linux/io.h>
 #include <linux/of_device.h>
@@ -317,13 +316,6 @@ static int __prci_register_clocks(struct device *dev, struct __prci_data *pd,
 			return r;
 		}
 
-		r = clk_hw_register_clkdev(&pic->hw, pic->name, dev_name(dev));
-		if (r) {
-			dev_warn(dev, "Failed to register clkdev for %s: %d\n",
-				 init.name, r);
-			return r;
-		}
-
 		pd->hw_clks.hws[i] = &pic->hw;
 	}
 




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux