[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20210317112644.24502-1-krzysztof.kozlowski@canonical.com>
Date: Wed, 17 Mar 2021 12:26:44 +0100
From: Krzysztof Kozlowski <krzysztof.kozlowski@...onical.com>
To: John Crispin <john@...ozen.org>,
Thomas Bogendoerfer <tsbogend@...ha.franken.de>,
linux-mips@...r.kernel.org, linux-kernel@...r.kernel.org
Cc: sergei.shtylyov@...il.com, thierry.reding@...il.com,
linux-tegra@...r.kernel.org, balbi@...nel.org, digetx@...il.com,
Krzysztof Kozlowski <krzysztof.kozlowski@...onical.com>,
kernel test robot <lkp@...el.com>
Subject: [PATCH v2] MIPS: ralink: define stubs for clk_set_parent to fix compile testing
The Ralink MIPS platform does not use Common Clock Framework and does
not define certain clock operations leading to compile test failures:
/usr/bin/mips-linux-gnu-ld: drivers/usb/phy/phy-tegra-usb.o: in function `tegra_usb_phy_init':
phy-tegra-usb.c:(.text+0x1dd4): undefined reference to `clk_get_parent'
Reported-by: kernel test robot <lkp@...el.com>
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@...onical.com>
Acked-by: John Crispin <john@...ozen.org>
---
Changes since v1:
1. Use EXPORT_SYMBOL_GPL like two other stubs in the file.
2. Add Ack
---
arch/mips/ralink/clk.c | 14 ++++++++++++++
1 file changed, 14 insertions(+)
diff --git a/arch/mips/ralink/clk.c b/arch/mips/ralink/clk.c
index 2f9d5acb38ea..f0bcb1051c30 100644
--- a/arch/mips/ralink/clk.c
+++ b/arch/mips/ralink/clk.c
@@ -70,6 +70,20 @@ long clk_round_rate(struct clk *clk, unsigned long rate)
}
EXPORT_SYMBOL_GPL(clk_round_rate);
+int clk_set_parent(struct clk *clk, struct clk *parent)
+{
+ WARN_ON(clk);
+ return -1;
+}
+EXPORT_SYMBOL_GPL(clk_set_parent);
+
+struct clk *clk_get_parent(struct clk *clk)
+{
+ WARN_ON(clk);
+ return NULL;
+}
+EXPORT_SYMBOL_GPL(clk_get_parent);
+
void __init plat_time_init(void)
{
struct clk *clk;
--
2.25.1
Powered by blists - more mailing lists