mirror of
https://github.com/openwrt/openwrt.git
synced 2024-12-26 00:41:17 +00:00
659f4a13dd
With Linux 6.1 many of our downstream patches and out-of-tree files can be removed or at least replaced by backported upstream commits. Signed-off-by: Daniel Golle <daniel@makrotopia.org> [fix CMDLINE_OVERRIDE for arm64] Signed-off-by: Bjørn Mork <bjorn@mork.no>
25 lines
802 B
Diff
25 lines
802 B
Diff
--- a/drivers/clk/mediatek/clk-pll.c
|
|
+++ b/drivers/clk/mediatek/clk-pll.c
|
|
@@ -141,7 +141,10 @@ static void mtk_pll_set_rate_regs(struct
|
|
pll->data->pcw_shift);
|
|
val |= pcw << pll->data->pcw_shift;
|
|
writel(val, pll->pcw_addr);
|
|
- chg = readl(pll->pcw_chg_addr) | PCW_CHG_MASK;
|
|
+ if (pll->data->pcw_chg_shift)
|
|
+ chg = readl(pll->pcw_chg_addr) | BIT(pll->data->pcw_chg_shift);
|
|
+ else
|
|
+ chg = readl(pll->pcw_chg_addr) | PCW_CHG_MASK;
|
|
writel(chg, pll->pcw_chg_addr);
|
|
if (pll->tuner_addr)
|
|
writel(val + 1, pll->tuner_addr);
|
|
--- a/drivers/clk/mediatek/clk-pll.h
|
|
+++ b/drivers/clk/mediatek/clk-pll.h
|
|
@@ -42,6 +42,7 @@ struct mtk_pll_data {
|
|
u32 pcw_reg;
|
|
int pcw_shift;
|
|
u32 pcw_chg_reg;
|
|
+ int pcw_chg_shift;
|
|
const struct mtk_pll_div_table *div_table;
|
|
const char *parent_name;
|
|
u32 en_reg;
|