Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1438130
| From | Michael Turquette <mturquette@baylibre.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH v3 13/14] clk: sunxi-ng: Add H3 clocks |
| Date | 2016-07-07 04:40 +0200 |
| Message-ID | <rS7ol-NG-1@gated-at.bofh.it> (permalink) |
| References | <rPt22-85k-5@gated-at.bofh.it> <rPt22-85k-31@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
Hi Maxime,
Quoting Maxime Ripard (2016-06-29 12:05:34)
> +static void __init sun8i_h3_ccu_setup(struct device_node *node)
> +{
> + void __iomem *reg;
> + u32 val;
> +
> + reg = of_io_request_and_map(node, 0, of_node_full_name(node));
> + if (IS_ERR(reg)) {
> + pr_err("%s: Could not map the clock registers\n",
> + of_node_full_name(node));
> + return;
> + }
> +
> + /* Force the PLL-Audio-1x divider to 4 */
> + val = readl(reg + SUN8I_H3_PLL_AUDIO_REG);
> + val &= ~GENMASK(4, 0);
> + writel(val | 3, reg + SUN8I_H3_PLL_AUDIO_REG);
> +
> + sunxi_ccu_probe(node, reg, &sun8i_h3_ccu_desc);
> +}
> +CLK_OF_DECLARE(sun8i_h3_ccu, "allwinner,sun8i-h3-ccu",
> + sun8i_h3_ccu_setup);
There are several examples of drivers that split the clocks between
"early" CLK_OF_DECLARE clocks and "late" module clocks. If you really
need early clocks (which is less likely on a 64-bit platform with
architected timers), it would be nice to pair that with a proper
platform_driver (using builtin_platform_driver most likely).
Otherwise that is my only nitpick with this series. Looks good!
Best regards,
Mike
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH v3 00/14] clk: sunxi: introduce "modern" clock support Maxime Ripard <maxime.ripard@free-electrons.com> - 2016-06-29 21:10 +0200
[PATCH v3 08/14] clk: sunxi-ng: Add M-P factor clock support Maxime Ripard <maxime.ripard@free-electrons.com> - 2016-06-29 21:10 +0200
[PATCH v3 11/14] clk: sunxi-ng: Add N-K-M Factor clock Maxime Ripard <maxime.ripard@free-electrons.com> - 2016-06-29 21:20 +0200
[PATCH v3 12/14] clk: sunxi-ng: Add N-K-M-P factor clock Maxime Ripard <maxime.ripard@free-electrons.com> - 2016-06-29 21:20 +0200
Re: [PATCH v3 13/14] clk: sunxi-ng: Add H3 clocks Jean-Francois Moine <moinejf@free.fr> - 2016-06-30 10:40 +0200
Re: [PATCH v3 13/14] clk: sunxi-ng: Add H3 clocks Michael Turquette <mturquette@baylibre.com> - 2016-07-07 04:40 +0200
Re: [PATCH v3 13/14] clk: sunxi-ng: Add H3 clocks Maxime Ripard <maxime.ripard@free-electrons.com> - 2016-07-08 23:40 +0200
csiph-web