Lines Matching +full:vco +full:- +full:offset

1 // SPDX-License-Identifier: GPL-2.0
12 * +-------+
14 * +------------------>0 |
16 * PLL/2 | SMUX +----+
17 * +------->1 | |
19 * | +-------+ | +-------+
20 * | +---->0 |
22 * +---------------+ | +----------->1 | CPU clk
23 * |Primary PLL +----+ PLL_EARLY | | +------>
24 * | +------+-----------+ +------>2 PMUX |
25 * +---------------+ | | | |
26 * | +------+ | +-->3 |
27 * +--^+ ACD +-----+ | +-------+
28 * +---------------+ +------+ |
30 * | +---------------------------+
31 * +---------------+ PLL_EARLY
37 * The primary PLL operates on a single VCO range, between 600MHz
44 * Primary PLL --> PLL_EARLY --> PMUX(1) --> CPU clk
46 * Primary PLL --> PLL/2 --> SMUX(1) --> PMUX(0) --> CPU clk
54 #include <linux/clk-provider.h>
59 #include <soc/qcom/kryo-l2-accessors.h>
61 #include "clk-alpha-pll.h"
62 #include "clk-regmap.h"
63 #include "clk-regmap-mux.h"
123 .offset = PWRCL_REG_OFFSET,
135 .offset = PERFCL_REG_OFFSET,
203 VCO(3, 250000000, 500000000),
204 VCO(2, 500000000, 750000000),
205 VCO(1, 750000000, 1000000000),
206 VCO(0, 1000000000, 2150400000),
221 .offset = PWRCL_REG_OFFSET + ALT_PLL_OFFSET,
235 .offset = PERFCL_REG_OFFSET + ALT_PLL_OFFSET,
271 regmap_read(clkr->regmap, cpuclk->reg, &val); in clk_cpu_8996_pmux_get_parent()
284 return regmap_update_bits(clkr->regmap, cpuclk->reg, PMUX_MASK, val); in clk_cpu_8996_pmux_set_parent()
292 if (req->rate < (DIV_2_THRESHOLD / 2)) in clk_cpu_8996_pmux_determine_rate()
293 return -EINVAL; in clk_cpu_8996_pmux_determine_rate()
295 if (req->rate < DIV_2_THRESHOLD) in clk_cpu_8996_pmux_determine_rate()
300 return -EINVAL; in clk_cpu_8996_pmux_determine_rate()
302 req->best_parent_rate = clk_hw_round_rate(parent, req->rate); in clk_cpu_8996_pmux_determine_rate()
303 req->best_parent_hw = parent; in clk_cpu_8996_pmux_determine_rate()
496 ret = clk_cpu_8996_pmux_set_parent(&cpuclk->clkr.hw, ALT_INDEX); in cpu_clk_notifier_cb()
500 if (cnd->new_rate < DIV_2_THRESHOLD) in cpu_clk_notifier_cb()
501 ret = clk_cpu_8996_pmux_set_parent(&cpuclk->clkr.hw, in cpu_clk_notifier_cb()
504 ret = clk_cpu_8996_pmux_set_parent(&cpuclk->clkr.hw, in cpu_clk_notifier_cb()
519 struct device *dev = &pdev->dev; in qcom_cpu_clk_msm8996_driver_probe()
524 return -ENOMEM; in qcom_cpu_clk_msm8996_driver_probe()
540 data->hws[0] = &pwrcl_pmux.clkr.hw; in qcom_cpu_clk_msm8996_driver_probe()
541 data->hws[1] = &perfcl_pmux.clkr.hw; in qcom_cpu_clk_msm8996_driver_probe()
542 data->num = 2; in qcom_cpu_clk_msm8996_driver_probe()
548 { .compatible = "qcom,msm8996-apcc" },
556 .name = "qcom-msm8996-apcc",