public inbox for linux-arm-kernel@lists.infradead.org
 help / color / mirror / Atom feed
From: maxime.ripard@free-electrons.com (Maxime Ripard)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 6/10] clk: sunxi-ng: Add A10s CCU driver
Date: Mon, 21 Nov 2016 22:45:52 +0100	[thread overview]
Message-ID: <20161121214552.yvt7r4jntusb5vx3@lukather> (raw)
In-Reply-To: <CAGb2v64cft9nWh13c+8jG8qhrD_RnVFc+s8btMTHbdDS155eQA@mail.gmail.com>

On Sun, Nov 13, 2016 at 05:34:44PM +0800, Chen-Yu Tsai wrote:
> > +static struct ccu_nkmp pll_ve_clk = {
> > +       .enable         = BIT(31),
> > +       .n              = _SUNXI_CCU_MULT_OFFSET(8, 5, 0),
> > +       .k              = _SUNXI_CCU_MULT(4, 2),
> > +       .m              = _SUNXI_CCU_DIV(0, 2),
> > +       .p              = _SUNXI_CCU_DIV(16, 2),
> 
> Any chance we'll support the bypass switch on this one?

I'm not sure this will be useful to have it running at 24MHz.

> > +static SUNXI_CCU_M(pll_ddr_clk, "pll-ddr", "pll-ddr-base", 0x020, 0, 2, 0);
> 
> Maybe we should set CLK_IS_CRITICAL on this one as well... in case the
> bootloader uses pll-periph for mbus, and none of the dram gates are enabled.

Ack.

> > +static SUNXI_CCU_GATE(hosc_clk,        "hosc", "osc24M", 0x050, BIT(0), 0);
> 
> Why the extra "hosc" clock here? You should probably just internalize "osc24M".

I'd prefer to model it as it is modelled in hardware: you have two
crystals, and then a gate within the CCU.

> > +static const char * const csi_parents[] = { "hosc", "pll-video0", "pll-video1",
> > +                                           "pll-video0-2x", "pll-video1-2x" };
> > +static const u8 csi_table[] = { 0, 1, 2, 5, 6 };
> > +static SUNXI_CCU_M_WITH_MUX_TABLE_GATE(csi_clk, "csi",
> > +                                      csi_parents, csi_table,
> > +                                      0x134, 0, 5, 24, 2, BIT(31), 0);
> 
> Do you know if CSI needs to change the module clock?

Apparently not.

Thanks!
Maxime

-- 
Maxime Ripard, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 801 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20161121/bb431cdc/attachment.sig>

  reply	other threads:[~2016-11-21 21:45 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-11-08 17:23 [PATCH 0/10] ARM: sun5i: Convert sun5i SoCs to sunxi-ng Maxime Ripard
2016-11-08 17:23 ` [PATCH 1/10] clk: sunxi-ng: multiplier: Add fractionnal support Maxime Ripard
2016-11-10  6:18   ` Chen-Yu Tsai
2016-11-08 17:23 ` [PATCH 2/10] clk: sunxi-ng: nkm: Deal with fixed post dividers Maxime Ripard
2016-11-13  3:48   ` Chen-Yu Tsai
2016-11-13  3:49     ` Chen-Yu Tsai
2016-11-08 17:23 ` [PATCH 3/10] clk: sunxi-ng: Implement multiplier offsets Maxime Ripard
2016-11-13  4:18   ` Chen-Yu Tsai
2016-11-08 17:23 ` [PATCH 4/10] clk: sunxi-ng: Add clocks and resets indices for sun5i Maxime Ripard
2016-11-13  4:29   ` Chen-Yu Tsai
2016-11-08 17:23 ` [PATCH 5/10] clk: sunxi-ng: Implement multiplier maximum Maxime Ripard
2016-11-13  4:30   ` Chen-Yu Tsai
2016-11-08 17:23 ` [PATCH 6/10] clk: sunxi-ng: Add A10s CCU driver Maxime Ripard
2016-11-13  9:34   ` Chen-Yu Tsai
2016-11-21 21:45     ` Maxime Ripard [this message]
2016-11-08 17:23 ` [PATCH 7/10] clk: sunxi-ng: Add A13 " Maxime Ripard
2016-11-13  9:55   ` Chen-Yu Tsai
2016-11-08 17:23 ` [PATCH 8/10] clk: sunxi-ng: Add GR8 driver Maxime Ripard
2016-11-08 17:23 ` [PATCH 9/10] ARM: sun5i: Convert to CCU Maxime Ripard
2016-11-13 15:01   ` Chen-Yu Tsai
2016-11-21 22:04     ` Maxime Ripard
2016-11-08 17:23 ` [PATCH 10/10] ARM: gr8: " Maxime Ripard
2016-11-12 23:51   ` kbuild test robot

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20161121214552.yvt7r4jntusb5vx3@lukather \
    --to=maxime.ripard@free-electrons.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox