From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id E3017143C43; Wed, 19 Jun 2024 13:03:45 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1718802226; cv=none; b=Bjsbvmd4aWK/ifIqwGnyFwbcqEGunLGonT4027vBI3Wn2+iELrBTb87Pyd2QK2oyDowhRlNlfijdf97ZqLJbf1m4ck6T8CN+xUrY/Ai5hg0S48/4ClucflXsyllgaqbo8dnJmyj6lfdGD5NRO3Sdj5O/AMGP1IN6F3l++6+tZTk= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1718802226; c=relaxed/simple; bh=covD3/NXmQmhfX8tkQ+nBcyVDLUyt/zJgZxwKRQILVs=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=koaBg08AgHpR+30ATvLpFGRc977t8dICCNbz0vH9fGgiuOAVOOGzR2FVW80QwcCXwjiYgxdl/g40H/Fcfypx82LYKz7ve9pqI42dlUow5v6xh4K48nNBearXPRUOvc3v603teIo0QSVins++/28Aw39NvQGPteBY5sdSFnLEwzU= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=F4UePSC2; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="F4UePSC2" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 340DCC2BBFC; Wed, 19 Jun 2024 13:03:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1718802225; bh=covD3/NXmQmhfX8tkQ+nBcyVDLUyt/zJgZxwKRQILVs=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=F4UePSC2d2FpOMBh7+N7QvP5ojkVd2Rt5yf4nmYOHrjff/NrRlE1C9WhYmj5vSCJ4 e7lNXAojQ8lOhPHeLe/DLuMMvYWJF4gSsE2OpMLfoVMREXhhSyIx5kDQHnBpTmn4R3 W2m+DlkpWXVcR4GwEAD3Mdo07CririyFHXDWtFOA= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Guenter Roeck , Russell King , Samuel Holland , Stephen Boyd , Sasha Levin Subject: [PATCH 6.6 117/267] clk: sifive: Do not register clkdevs for PRCI clocks Date: Wed, 19 Jun 2024 14:54:28 +0200 Message-ID: <20240619125610.841815223@linuxfoundation.org> X-Mailer: git-send-email 2.45.2 In-Reply-To: <20240619125606.345939659@linuxfoundation.org> References: <20240619125606.345939659@linuxfoundation.org> User-Agent: quilt/0.67 X-stable: review X-Patchwork-Hint: ignore Precedence: bulk X-Mailing-List: stable@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 6.6-stable review patch. If anyone has any objections, please let me know. ------------------ From: Samuel Holland [ 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@shell.armlinux.org.uk/ [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 Closes: https://lore.kernel.org/linux-clk/7eda7621-0dde-4153-89e4-172e4c095d01@roeck-us.net/ Suggested-by: Russell King Signed-off-by: Samuel Holland Link: https://lore.kernel.org/r/20240528001432.1200403-1-samuel.holland@sifive.com Signed-off-by: Stephen Boyd Signed-off-by: Sasha Levin --- drivers/clk/sifive/sifive-prci.c | 8 -------- 1 file changed, 8 deletions(-) diff --git a/drivers/clk/sifive/sifive-prci.c b/drivers/clk/sifive/sifive-prci.c index af81eb835bc23..b1be6a2d24aa9 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 #include #include #include @@ -536,13 +535,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; } -- 2.43.0