All of lore.kernel.org
 help / color / mirror / Atom feed
From: Damien Le Moal <Damien.LeMoal@wdc.com>
To: Stephen Boyd <sboyd@kernel.org>,
	Linus Walleij <linus.walleij@linaro.org>,
	Palmer Dabbelt <palmer@dabbelt.com>,
	Philipp Zabel <p.zabel@pengutronix.de>,
	Rob Herring <robh+dt@kernel.org>,
	"devicetree@vger.kernel.org" <devicetree@vger.kernel.org>,
	"linux-clk@vger.kernel.org" <linux-clk@vger.kernel.org>,
	"linux-gpio@vger.kernel.org" <linux-gpio@vger.kernel.org>,
	"linux-riscv@lists.infradead.org"
	<linux-riscv@lists.infradead.org>
Cc: Sean Anderson <seanga2@gmail.com>
Subject: Re: [PATCH v10 09/23] dt-binding: clock: Document canaan,k210-clk bindings
Date: Thu, 17 Dec 2020 10:43:50 +0000	[thread overview]
Message-ID: <CH2PR04MB6522E9EC44FF8FFA5981107CE7C40@CH2PR04MB6522.namprd04.prod.outlook.com> (raw)
In-Reply-To: 160820021596.1580929.1686334340234415270@swboyd.mtv.corp.google.com

On 2020/12/17 19:17, Stephen Boyd wrote:
> Quoting Damien Le Moal (2020-12-17 00:13:57)
>> On 2020/12/17 17:10, Stephen Boyd wrote:
>>> Quoting Damien Le Moal (2020-12-13 05:50:42)
>>>> diff --git a/include/dt-bindings/clock/k210-clk.h b/include/dt-bindings/clock/k210-clk.h
>>>> index 5a2fd64d1a49..b2de702cbf75 100644
>>>> --- a/include/dt-bindings/clock/k210-clk.h
>>>> +++ b/include/dt-bindings/clock/k210-clk.h
>>>> @@ -3,18 +3,51 @@
>>>>   * Copyright (C) 2019-20 Sean Anderson <seanga2@gmail.com>
>>>>   * Copyright (c) 2020 Western Digital Corporation or its affiliates.
>>>>   */
>>>> -#ifndef K210_CLK_H
>>>> -#define K210_CLK_H
>>>> +#ifndef CLOCK_K210_CLK_H
>>>> +#define CLOCK_K210_CLK_H
>>>>  
>>>>  /*
>>>> - * Arbitrary identifiers for clocks.
>>>> - * The structure is: in0 -> pll0 -> aclk -> cpu
>>>> - *
>>>> - * Since we use the hardware defaults for now, set all these to the same clock.
>>>> + * Kendryte K210 SoC clock identifiers (arbitrary values).
>>>>   */
>>>> -#define K210_CLK_PLL0   0
>>>> -#define K210_CLK_PLL1   0
>>>> -#define K210_CLK_ACLK   0
>>>> -#define K210_CLK_CPU    0
>>>
>>> This seems to open a bisection hole. I see that ACLK is used in the
>>> existing dtsi file, and that is the same as CLK_CPU, but after this
>>> patch it will change to not exist anymore. Can we leave ACLK around
>>> defined to be 0? I imagine it won't be used in the future so we can
>>> remove it later. I can then apply this for v5.11-rc1 and then merge the
>>> clk driver patch in clk tree.
>>>
>>>> +#define K210_CLK_CPU   0
>>>> +#define K210_CLK_SRAM0 1
>>>> +#define K210_CLK_SRAM1 2
>>>
>>
>> Patch 6 of the series removes the use of K210_CLK_CPU and K210_CLK_ACLK from the
>> device trees. I added that patch as the DT modification proper comes only at
>> patch 16. Maybe I should squash patch 6 into this one ?
>>
> 
> Preferably the defines are just left alone forever and then forgotten.
> The dt-bindings directory is almost ABI and so changing numbers or
> removing defines is hard to do. Usually patches in this directory are an
> additive thing.

I just did that. It works.

Ideally, patches 7, 8 and 9 need to go in together with the clk driver patch.
Since the builtin DTB patch precedes the clock driver patch that touches the
sysctl driver, I need to rework it a little, keeping the
SOC_DECLARE_BUILTIN_DTB() for now. And finally, a small DTS update patch needs
to be added too for the sysctl & sysclk nodes update. That would make it a 5
patch series for the clock driver addition. Would this work ?

Or, you just take patch 9 (clk doc) and patch 13 (clk driver), slightly modified
to move the sysctl register definitions into a common header (currently part of
patch 7). 2 patches only, without any other change, resulting in the clock
driver not being used until the rest of the series goes into 5.12. Do you prefer
that solution ?


-- 
Damien Le Moal
Western Digital Research

WARNING: multiple messages have this Message-ID (diff)
From: Damien Le Moal <Damien.LeMoal@wdc.com>
To: Stephen Boyd <sboyd@kernel.org>,
	Linus Walleij <linus.walleij@linaro.org>,
	 Palmer Dabbelt <palmer@dabbelt.com>,
	Philipp Zabel <p.zabel@pengutronix.de>,
	Rob Herring <robh+dt@kernel.org>,
	"devicetree@vger.kernel.org" <devicetree@vger.kernel.org>,
	"linux-clk@vger.kernel.org" <linux-clk@vger.kernel.org>,
	"linux-gpio@vger.kernel.org" <linux-gpio@vger.kernel.org>,
	"linux-riscv@lists.infradead.org"
	<linux-riscv@lists.infradead.org>
Cc: Sean Anderson <seanga2@gmail.com>
Subject: Re: [PATCH v10 09/23] dt-binding: clock: Document canaan,k210-clk bindings
Date: Thu, 17 Dec 2020 10:43:50 +0000	[thread overview]
Message-ID: <CH2PR04MB6522E9EC44FF8FFA5981107CE7C40@CH2PR04MB6522.namprd04.prod.outlook.com> (raw)
In-Reply-To: 160820021596.1580929.1686334340234415270@swboyd.mtv.corp.google.com

On 2020/12/17 19:17, Stephen Boyd wrote:
> Quoting Damien Le Moal (2020-12-17 00:13:57)
>> On 2020/12/17 17:10, Stephen Boyd wrote:
>>> Quoting Damien Le Moal (2020-12-13 05:50:42)
>>>> diff --git a/include/dt-bindings/clock/k210-clk.h b/include/dt-bindings/clock/k210-clk.h
>>>> index 5a2fd64d1a49..b2de702cbf75 100644
>>>> --- a/include/dt-bindings/clock/k210-clk.h
>>>> +++ b/include/dt-bindings/clock/k210-clk.h
>>>> @@ -3,18 +3,51 @@
>>>>   * Copyright (C) 2019-20 Sean Anderson <seanga2@gmail.com>
>>>>   * Copyright (c) 2020 Western Digital Corporation or its affiliates.
>>>>   */
>>>> -#ifndef K210_CLK_H
>>>> -#define K210_CLK_H
>>>> +#ifndef CLOCK_K210_CLK_H
>>>> +#define CLOCK_K210_CLK_H
>>>>  
>>>>  /*
>>>> - * Arbitrary identifiers for clocks.
>>>> - * The structure is: in0 -> pll0 -> aclk -> cpu
>>>> - *
>>>> - * Since we use the hardware defaults for now, set all these to the same clock.
>>>> + * Kendryte K210 SoC clock identifiers (arbitrary values).
>>>>   */
>>>> -#define K210_CLK_PLL0   0
>>>> -#define K210_CLK_PLL1   0
>>>> -#define K210_CLK_ACLK   0
>>>> -#define K210_CLK_CPU    0
>>>
>>> This seems to open a bisection hole. I see that ACLK is used in the
>>> existing dtsi file, and that is the same as CLK_CPU, but after this
>>> patch it will change to not exist anymore. Can we leave ACLK around
>>> defined to be 0? I imagine it won't be used in the future so we can
>>> remove it later. I can then apply this for v5.11-rc1 and then merge the
>>> clk driver patch in clk tree.
>>>
>>>> +#define K210_CLK_CPU   0
>>>> +#define K210_CLK_SRAM0 1
>>>> +#define K210_CLK_SRAM1 2
>>>
>>
>> Patch 6 of the series removes the use of K210_CLK_CPU and K210_CLK_ACLK from the
>> device trees. I added that patch as the DT modification proper comes only at
>> patch 16. Maybe I should squash patch 6 into this one ?
>>
> 
> Preferably the defines are just left alone forever and then forgotten.
> The dt-bindings directory is almost ABI and so changing numbers or
> removing defines is hard to do. Usually patches in this directory are an
> additive thing.

I just did that. It works.

Ideally, patches 7, 8 and 9 need to go in together with the clk driver patch.
Since the builtin DTB patch precedes the clock driver patch that touches the
sysctl driver, I need to rework it a little, keeping the
SOC_DECLARE_BUILTIN_DTB() for now. And finally, a small DTS update patch needs
to be added too for the sysctl & sysclk nodes update. That would make it a 5
patch series for the clock driver addition. Would this work ?

Or, you just take patch 9 (clk doc) and patch 13 (clk driver), slightly modified
to move the sysctl register definitions into a common header (currently part of
patch 7). 2 patches only, without any other change, resulting in the clock
driver not being used until the rest of the series goes into 5.12. Do you prefer
that solution ?


-- 
Damien Le Moal
Western Digital Research

_______________________________________________
linux-riscv mailing list
linux-riscv@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-riscv

  reply	other threads:[~2020-12-17 10:45 UTC|newest]

Thread overview: 98+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-12-13 13:50 [PATCH v10 00/23] RISC-V Kendryte K210 support improvements Damien Le Moal
2020-12-13 13:50 ` Damien Le Moal
2020-12-13 13:50 ` [PATCH v10 01/23] riscv: Fix kernel time_init() Damien Le Moal
2020-12-13 13:50   ` Damien Le Moal
2020-12-13 13:50 ` [PATCH v10 02/23] riscv: Fix sifive serial driver Damien Le Moal
2020-12-13 13:50   ` Damien Le Moal
2020-12-13 13:50 ` [PATCH v10 03/23] riscv: Enable interrupts during syscalls with M-Mode Damien Le Moal
2020-12-13 13:50   ` Damien Le Moal
2020-12-13 13:50 ` [PATCH v10 04/23] riscv: Fix builtin DTB handling Damien Le Moal
2020-12-13 13:50   ` Damien Le Moal
2020-12-13 13:50 ` [PATCH v10 05/23] riscv: Use vendor name for K210 SoC support Damien Le Moal
2020-12-13 13:50   ` Damien Le Moal
2020-12-28 12:03   ` Anup Patel
2020-12-28 12:03     ` Anup Patel
2020-12-13 13:50 ` [PATCH v10 06/23] riscv: Fix Canaan Kendryte K210 device tree Damien Le Moal
2020-12-13 13:50   ` Damien Le Moal
2020-12-28 12:03   ` Anup Patel
2020-12-28 12:03     ` Anup Patel
2020-12-13 13:50 ` [PATCH v10 07/23] riscv: cleanup Canaan Kendryte K210 sysctl driver Damien Le Moal
2020-12-13 13:50   ` Damien Le Moal
2020-12-13 13:50 ` [PATCH v10 08/23] dt-bindings: Add Canaan vendor prefix Damien Le Moal
2020-12-13 13:50   ` Damien Le Moal
2020-12-13 13:50 ` [PATCH v10 09/23] dt-binding: clock: Document canaan,k210-clk bindings Damien Le Moal
2020-12-13 13:50   ` [PATCH v10 09/23] dt-binding: clock: Document canaan, k210-clk bindings Damien Le Moal
2020-12-17  8:09   ` [PATCH v10 09/23] dt-binding: clock: Document canaan,k210-clk bindings Stephen Boyd
2020-12-17  8:09     ` [PATCH v10 09/23] dt-binding: clock: Document canaan, k210-clk bindings Stephen Boyd
2020-12-17  8:13     ` [PATCH v10 09/23] dt-binding: clock: Document canaan,k210-clk bindings Damien Le Moal
2020-12-17  8:13       ` Damien Le Moal
2020-12-17 10:16       ` Stephen Boyd
2020-12-17 10:16         ` [PATCH v10 09/23] dt-binding: clock: Document canaan, k210-clk bindings Stephen Boyd
2020-12-17 10:43         ` Damien Le Moal [this message]
2020-12-17 10:43           ` [PATCH v10 09/23] dt-binding: clock: Document canaan,k210-clk bindings Damien Le Moal
2020-12-17 10:49           ` Stephen Boyd
2020-12-17 10:49             ` [PATCH v10 09/23] dt-binding: clock: Document canaan, k210-clk bindings Stephen Boyd
2020-12-17 10:51             ` [PATCH v10 09/23] dt-binding: clock: Document canaan,k210-clk bindings Damien Le Moal
2020-12-17 10:51               ` Damien Le Moal
2020-12-20  5:35               ` Stephen Boyd
2020-12-20  5:35                 ` [PATCH v10 09/23] dt-binding: clock: Document canaan, k210-clk bindings Stephen Boyd
2020-12-20  8:58                 ` [PATCH v10 09/23] dt-binding: clock: Document canaan,k210-clk bindings Damien Le Moal
2020-12-20  8:58                   ` Damien Le Moal
2020-12-17 10:54             ` Damien Le Moal
2020-12-17 10:54               ` Damien Le Moal
2020-12-19 19:44               ` Stephen Boyd
2020-12-19 19:44                 ` [PATCH v10 09/23] dt-binding: clock: Document canaan, k210-clk bindings Stephen Boyd
2020-12-13 13:50 ` [PATCH v10 10/23] dt-bindings: reset: Document canaan,k210-rst bindings Damien Le Moal
2020-12-13 13:50   ` [PATCH v10 10/23] dt-bindings: reset: Document canaan, k210-rst bindings Damien Le Moal
2020-12-13 13:50 ` [PATCH v10 11/23] dt-bindings: pinctrl: Document canaan,k210-fpioa bindings Damien Le Moal
2020-12-13 13:50   ` [PATCH v10 11/23] dt-bindings: pinctrl: Document canaan, k210-fpioa bindings Damien Le Moal
2020-12-13 13:50 ` [PATCH v10 12/23] dt-binding: mfd: Document canaan,k210-sysctl bindings Damien Le Moal
2020-12-13 13:50   ` [PATCH v10 12/23] dt-binding: mfd: Document canaan, k210-sysctl bindings Damien Le Moal
2020-12-15 17:00   ` [PATCH v10 12/23] dt-binding: mfd: Document canaan,k210-sysctl bindings Rob Herring
2020-12-15 17:00     ` Rob Herring
2020-12-13 13:50 ` [PATCH v10 13/23] riscv: Add Canaan Kendryte K210 clock driver Damien Le Moal
2020-12-13 13:50   ` Damien Le Moal
2020-12-13 13:50 ` [PATCH v10 14/23] riscv: Add Canaan Kendryte K210 reset controller Damien Le Moal
2020-12-13 13:50   ` Damien Le Moal
2020-12-13 13:50 ` [PATCH v10 15/23] riscv: Add Canaan Kendryte K210 FPIOA driver Damien Le Moal
2020-12-13 13:50   ` Damien Le Moal
2020-12-13 13:50 ` [PATCH v10 16/23] riscv: Update Canaan Kendryte K210 device tree Damien Le Moal
2020-12-13 13:50   ` Damien Le Moal
2020-12-28 12:07   ` Anup Patel
2020-12-28 12:07     ` Anup Patel
2020-12-13 13:50 ` [PATCH v10 17/23] riscv: Add SiPeed MAIX BiT board " Damien Le Moal
2020-12-13 13:50   ` Damien Le Moal
2020-12-28 12:08   ` Anup Patel
2020-12-28 12:08     ` Anup Patel
2020-12-13 13:50 ` [PATCH v10 18/23] riscv: Add SiPeed MAIX DOCK " Damien Le Moal
2020-12-13 13:50   ` Damien Le Moal
2020-12-28 12:08   ` Anup Patel
2020-12-28 12:08     ` Anup Patel
2020-12-13 13:50 ` [PATCH v10 19/23] riscv: Add SiPeed MAIX GO " Damien Le Moal
2020-12-13 13:50   ` Damien Le Moal
2020-12-28 12:09   ` Anup Patel
2020-12-28 12:09     ` Anup Patel
2020-12-13 13:50 ` [PATCH v10 20/23] riscv: Add SiPeed MAIXDUINO " Damien Le Moal
2020-12-13 13:50   ` Damien Le Moal
2020-12-28 12:10   ` Anup Patel
2020-12-28 12:10     ` Anup Patel
2020-12-13 13:50 ` [PATCH v10 21/23] riscv: Add Kendryte KD233 " Damien Le Moal
2020-12-13 13:50   ` Damien Le Moal
2020-12-28 12:10   ` Anup Patel
2020-12-28 12:10     ` Anup Patel
2020-12-13 13:50 ` [PATCH v10 22/23] riscv: Update Canaan Kendryte K210 defconfig Damien Le Moal
2020-12-13 13:50   ` Damien Le Moal
2020-12-28 12:11   ` Anup Patel
2020-12-28 12:11     ` Anup Patel
2020-12-13 13:50 ` [PATCH v10 23/23] riscv: Add Canaan Kendryte K210 SD card defconfig Damien Le Moal
2020-12-13 13:50   ` Damien Le Moal
2020-12-28 12:12   ` Anup Patel
2020-12-28 12:12     ` Anup Patel
2020-12-15 23:02 ` [PATCH v10 00/23] RISC-V Kendryte K210 support improvements Damien Le Moal
2020-12-15 23:02   ` Damien Le Moal
2021-01-09 17:32 ` Palmer Dabbelt
2021-01-09 17:32   ` Palmer Dabbelt
2021-01-11  1:56   ` Damien Le Moal
2021-01-11  1:56     ` Damien Le Moal
2021-01-11  2:34     ` Sean Anderson
2021-01-11  2:34       ` Sean Anderson

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=CH2PR04MB6522E9EC44FF8FFA5981107CE7C40@CH2PR04MB6522.namprd04.prod.outlook.com \
    --to=damien.lemoal@wdc.com \
    --cc=devicetree@vger.kernel.org \
    --cc=linus.walleij@linaro.org \
    --cc=linux-clk@vger.kernel.org \
    --cc=linux-gpio@vger.kernel.org \
    --cc=linux-riscv@lists.infradead.org \
    --cc=p.zabel@pengutronix.de \
    --cc=palmer@dabbelt.com \
    --cc=robh+dt@kernel.org \
    --cc=sboyd@kernel.org \
    --cc=seanga2@gmail.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.