All of lore.kernel.org
 help / color / mirror / Atom feed
From: maxime.ripard@free-electrons.com (Maxime Ripard)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 3/9] clk: sunxi: Add prcm mod0 clock driver
Date: Tue, 9 Dec 2014 09:51:37 +0100	[thread overview]
Message-ID: <20141209085137.GQ8739@lukather> (raw)
In-Reply-To: <54855EF6.1000900@redhat.com>

On Mon, Dec 08, 2014 at 09:19:02AM +0100, Hans de Goede wrote:
> Hi,
> 
> On 07-12-14 19:08, Maxime Ripard wrote:
> >On Wed, Dec 03, 2014 at 10:49:20AM +0100, Hans de Goede wrote:
> 
> <snip>
> 
> >>So it should not have a simple-bus compatible either, and as such we cannot
> >>simply change the mod0 driver from of_clk_define to a platform driver because
> >>then we need to instantiate platform devs for the mod0 clock nodes, which
> >>means making the clock node a simple-bus.
> >
> >I guess we can do that as a temporary measure until we get things
> >right on that front. I'm totally open to doing that work, so I'm not
> >asking you to do it.
> >
> >>I can see your logic in wanting the ir_clk prcm sub-node to use the
> >>mod0 compatible string, so how about we make the mod0 driver both
> >>register through of_declare and as a platform driver. Note this means
> >>that it will try to bind twice to the ir_clk node, since of_clk_declare
> >>will cause it to try and bind there too AFAIK.
> >
> >Hmmm, I could live with that for a while too. That shouldn't even
> >require too much work, since the first thing we check in the mod0 code
> >is that we actually have something in reg, which will not be the case
> >in the OF_CLK_DECLARE case.
> >
> >>The of_clk_declare bind will fail though because there is no regs
> >>property, so this double bind is not an issue as long as we do not
> >>log errors on the first bind failure.
> >
> >Yep, exactly.
> >
> >>Note that the ir_clk node will still need an "ir-clk" compatible as
> >>well for the MFD to find it and assign the proper resources to it.
> >
> >No, it really doesn't. At least for now, we have a single mod0 clock
> >under the PRCM MFD. If (and only if) one day, we find ourselves in a
> >position where we have two mod0 clocks under the PRCM, then we'll fix
> >the MFD code to deal with that, because it really should deal with it.
> 
> Ok, using only the mod0 compat string works for me. I'll respin my
> patch-set (minus the one patch you've already merged) to make the modo
> clk driver use both of_clk_declare and make it a platfrom driver, and
> use the mod0 compat string for the ir-clk node.
> 
> Not sure when I'll get this done exactly though, but we still have
> a while before 3.20 :)

Indeed :)

Thanks!
Maxime

-- 
Maxime Ripard, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: Digital signature
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20141209/3dd26c2f/attachment-0001.sig>

WARNING: multiple messages have this Message-ID (diff)
From: Maxime Ripard <maxime.ripard-wi1+55ScJUtKEb57/3fJTNBPR1lH4CV8@public.gmane.org>
To: Hans de Goede <hdegoede-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
Cc: Chen-Yu Tsai <wens-jdAy2FN1RRM@public.gmane.org>,
	Boris Brezillon
	<boris-wi1+55ScJUtKEb57/3fJTNBPR1lH4CV8@public.gmane.org>,
	Mike Turquette
	<mturquette-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>,
	Emilio Lopez <emilio-0Z03zUJReD5OxF6Tv1QG9Q@public.gmane.org>,
	Linux Media Mailing List
	<linux-media-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
	linux-arm-kernel
	<linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org>,
	devicetree <devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
	linux-sunxi <linux-sunxi-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
Subject: Re: [PATCH 3/9] clk: sunxi: Add prcm mod0 clock driver
Date: Tue, 9 Dec 2014 09:51:37 +0100	[thread overview]
Message-ID: <20141209085137.GQ8739@lukather> (raw)
In-Reply-To: <54855EF6.1000900-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>

[-- Attachment #1: Type: text/plain, Size: 2396 bytes --]

On Mon, Dec 08, 2014 at 09:19:02AM +0100, Hans de Goede wrote:
> Hi,
> 
> On 07-12-14 19:08, Maxime Ripard wrote:
> >On Wed, Dec 03, 2014 at 10:49:20AM +0100, Hans de Goede wrote:
> 
> <snip>
> 
> >>So it should not have a simple-bus compatible either, and as such we cannot
> >>simply change the mod0 driver from of_clk_define to a platform driver because
> >>then we need to instantiate platform devs for the mod0 clock nodes, which
> >>means making the clock node a simple-bus.
> >
> >I guess we can do that as a temporary measure until we get things
> >right on that front. I'm totally open to doing that work, so I'm not
> >asking you to do it.
> >
> >>I can see your logic in wanting the ir_clk prcm sub-node to use the
> >>mod0 compatible string, so how about we make the mod0 driver both
> >>register through of_declare and as a platform driver. Note this means
> >>that it will try to bind twice to the ir_clk node, since of_clk_declare
> >>will cause it to try and bind there too AFAIK.
> >
> >Hmmm, I could live with that for a while too. That shouldn't even
> >require too much work, since the first thing we check in the mod0 code
> >is that we actually have something in reg, which will not be the case
> >in the OF_CLK_DECLARE case.
> >
> >>The of_clk_declare bind will fail though because there is no regs
> >>property, so this double bind is not an issue as long as we do not
> >>log errors on the first bind failure.
> >
> >Yep, exactly.
> >
> >>Note that the ir_clk node will still need an "ir-clk" compatible as
> >>well for the MFD to find it and assign the proper resources to it.
> >
> >No, it really doesn't. At least for now, we have a single mod0 clock
> >under the PRCM MFD. If (and only if) one day, we find ourselves in a
> >position where we have two mod0 clocks under the PRCM, then we'll fix
> >the MFD code to deal with that, because it really should deal with it.
> 
> Ok, using only the mod0 compat string works for me. I'll respin my
> patch-set (minus the one patch you've already merged) to make the modo
> clk driver use both of_clk_declare and make it a platfrom driver, and
> use the mod0 compat string for the ir-clk node.
> 
> Not sure when I'll get this done exactly though, but we still have
> a while before 3.20 :)

Indeed :)

Thanks!
Maxime

-- 
Maxime Ripard, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

WARNING: multiple messages have this Message-ID (diff)
From: Maxime Ripard <maxime.ripard@free-electrons.com>
To: Hans de Goede <hdegoede@redhat.com>
Cc: Chen-Yu Tsai <wens@csie.org>,
	Boris Brezillon <boris@free-electrons.com>,
	Mike Turquette <mturquette@linaro.org>,
	Emilio Lopez <emilio@elopez.com.ar>,
	Linux Media Mailing List <linux-media@vger.kernel.org>,
	linux-arm-kernel <linux-arm-kernel@lists.infradead.org>,
	devicetree <devicetree@vger.kernel.org>,
	linux-sunxi <linux-sunxi@googlegroups.com>
Subject: Re: [PATCH 3/9] clk: sunxi: Add prcm mod0 clock driver
Date: Tue, 9 Dec 2014 09:51:37 +0100	[thread overview]
Message-ID: <20141209085137.GQ8739@lukather> (raw)
In-Reply-To: <54855EF6.1000900@redhat.com>

[-- Attachment #1: Type: text/plain, Size: 2456 bytes --]

On Mon, Dec 08, 2014 at 09:19:02AM +0100, Hans de Goede wrote:
> Hi,
> 
> On 07-12-14 19:08, Maxime Ripard wrote:
> >On Wed, Dec 03, 2014 at 10:49:20AM +0100, Hans de Goede wrote:
> 
> <snip>
> 
> >>So it should not have a simple-bus compatible either, and as such we cannot
> >>simply change the mod0 driver from of_clk_define to a platform driver because
> >>then we need to instantiate platform devs for the mod0 clock nodes, which
> >>means making the clock node a simple-bus.
> >
> >I guess we can do that as a temporary measure until we get things
> >right on that front. I'm totally open to doing that work, so I'm not
> >asking you to do it.
> >
> >>I can see your logic in wanting the ir_clk prcm sub-node to use the
> >>mod0 compatible string, so how about we make the mod0 driver both
> >>register through of_declare and as a platform driver. Note this means
> >>that it will try to bind twice to the ir_clk node, since of_clk_declare
> >>will cause it to try and bind there too AFAIK.
> >
> >Hmmm, I could live with that for a while too. That shouldn't even
> >require too much work, since the first thing we check in the mod0 code
> >is that we actually have something in reg, which will not be the case
> >in the OF_CLK_DECLARE case.
> >
> >>The of_clk_declare bind will fail though because there is no regs
> >>property, so this double bind is not an issue as long as we do not
> >>log errors on the first bind failure.
> >
> >Yep, exactly.
> >
> >>Note that the ir_clk node will still need an "ir-clk" compatible as
> >>well for the MFD to find it and assign the proper resources to it.
> >
> >No, it really doesn't. At least for now, we have a single mod0 clock
> >under the PRCM MFD. If (and only if) one day, we find ourselves in a
> >position where we have two mod0 clocks under the PRCM, then we'll fix
> >the MFD code to deal with that, because it really should deal with it.
> 
> Ok, using only the mod0 compat string works for me. I'll respin my
> patch-set (minus the one patch you've already merged) to make the modo
> clk driver use both of_clk_declare and make it a platfrom driver, and
> use the mod0 compat string for the ir-clk node.
> 
> Not sure when I'll get this done exactly though, but we still have
> a while before 3.20 :)

Indeed :)

Thanks!
Maxime

-- 
Maxime Ripard, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 819 bytes --]

  reply	other threads:[~2014-12-09  8:51 UTC|newest]

Thread overview: 125+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-11-20 15:55 [PATCH 0/9] sun6i / A31 ir receiver support Hans de Goede
2014-11-20 15:55 ` Hans de Goede
2014-11-20 15:55 ` Hans de Goede
2014-11-20 15:55 ` [PATCH 1/9] clk: sunxi: Give sunxi_factors_register a registers parameter Hans de Goede
2014-11-20 15:55   ` Hans de Goede
2014-11-20 15:55   ` Hans de Goede
2014-11-21  8:35   ` Maxime Ripard
2014-11-21  8:35     ` Maxime Ripard
2014-11-21  8:44     ` Hans de Goede
2014-11-21  8:44       ` Hans de Goede
2014-11-21  8:44       ` Hans de Goede
2014-11-21 11:15       ` Maxime Ripard
2014-11-21 11:15         ` Maxime Ripard
2014-11-21 11:15         ` Maxime Ripard
2014-11-20 15:55 ` [PATCH 2/9] clk: sunxi: Make sun4i_a10_mod0_data available outside of clk-mod0.c Hans de Goede
2014-11-20 15:55   ` Hans de Goede
2014-11-20 15:55   ` Hans de Goede
2014-11-20 15:55 ` [PATCH 3/9] clk: sunxi: Add prcm mod0 clock driver Hans de Goede
2014-11-20 15:55   ` Hans de Goede
2014-11-20 15:55   ` Hans de Goede
2014-11-20 18:24   ` [linux-sunxi] " Chen-Yu Tsai
2014-11-20 18:24     ` Chen-Yu Tsai
2014-11-20 18:24     ` Chen-Yu Tsai
2014-11-20 19:32     ` [linux-sunxi] " Hans de Goede
2014-11-20 19:32       ` Hans de Goede
2014-11-20 19:32       ` Hans de Goede
2014-11-21  8:49   ` Maxime Ripard
2014-11-21  8:49     ` Maxime Ripard
2014-11-21  8:49     ` Maxime Ripard
2014-11-21  9:13     ` Hans de Goede
2014-11-21  9:13       ` Hans de Goede
2014-11-21  9:13       ` Hans de Goede
2014-11-24 22:03       ` Maxime Ripard
2014-11-24 22:03         ` Maxime Ripard
2014-11-24 22:03         ` Maxime Ripard
2014-11-25  8:29         ` Hans de Goede
2014-11-25  8:29           ` Hans de Goede
2014-11-25  8:29           ` Hans de Goede
2014-11-25  8:37           ` Hans de Goede
2014-11-25  8:37             ` Hans de Goede
2014-11-25  8:37             ` Hans de Goede
2014-11-26 21:13           ` Maxime Ripard
2014-11-26 21:13             ` Maxime Ripard
2014-11-26 21:13             ` Maxime Ripard
2014-11-27  8:41             ` Hans de Goede
2014-11-27  8:41               ` Hans de Goede
2014-11-27  8:41               ` Hans de Goede
2014-11-27  9:28               ` Chen-Yu Tsai
2014-11-27  9:28                 ` Chen-Yu Tsai
2014-11-27  9:28                 ` Chen-Yu Tsai
2014-11-27 10:10                 ` Hans de Goede
2014-11-27 10:10                   ` Hans de Goede
2014-11-27 10:10                   ` Hans de Goede
2014-11-27 19:05                   ` Maxime Ripard
2014-11-27 19:05                     ` Maxime Ripard
2014-11-27 19:05                     ` Maxime Ripard
2014-11-28 13:37                     ` Hans de Goede
2014-11-28 13:37                       ` Hans de Goede
2014-11-28 13:37                       ` Hans de Goede
2014-12-02 15:45                       ` Maxime Ripard
2014-12-02 15:45                         ` Maxime Ripard
2014-12-02 15:45                         ` Maxime Ripard
2014-12-03  9:49                         ` Hans de Goede
2014-12-03  9:49                           ` Hans de Goede
2014-12-03  9:49                           ` Hans de Goede
2014-12-07 18:08                           ` Maxime Ripard
2014-12-07 18:08                             ` Maxime Ripard
2014-12-07 18:08                             ` Maxime Ripard
2014-12-08  8:19                             ` Hans de Goede
2014-12-08  8:19                               ` Hans de Goede
2014-12-08  8:19                               ` Hans de Goede
2014-12-09  8:51                               ` Maxime Ripard [this message]
2014-12-09  8:51                                 ` Maxime Ripard
2014-12-09  8:51                                 ` Maxime Ripard
2014-11-27 18:51               ` Maxime Ripard
2014-11-27 18:51                 ` Maxime Ripard
2014-11-27 18:51                 ` Maxime Ripard
2014-11-27 16:40             ` Boris Brezillon
2014-11-27 16:40               ` Boris Brezillon
2014-11-27 16:40               ` Boris Brezillon
2014-11-27 19:15               ` Maxime Ripard
2014-11-27 19:15                 ` Maxime Ripard
2014-11-27 19:15                 ` Maxime Ripard
2014-11-20 15:55 ` [PATCH 4/9] rc: sunxi-cir: Add support for an optional reset controller Hans de Goede
2014-11-20 15:55   ` Hans de Goede
2014-11-20 15:55   ` Hans de Goede
2014-11-20 16:28   ` Mauro Carvalho Chehab
2014-11-20 16:28     ` Mauro Carvalho Chehab
2014-11-21  8:51     ` Maxime Ripard
2014-11-21  8:51       ` Maxime Ripard
2014-11-21  8:51       ` Maxime Ripard
2014-11-20 23:05   ` [linux-sunxi] " Julian Calaby
2014-11-20 23:05     ` Julian Calaby
2014-11-20 23:05     ` Julian Calaby
2014-11-20 15:55 ` [PATCH 5/9] rc: sunxi-cir: Add support for the larger fifo found on sun5i and sun6i Hans de Goede
2014-11-20 15:55   ` Hans de Goede
2014-11-20 15:55   ` Hans de Goede
2014-11-20 16:28   ` Mauro Carvalho Chehab
2014-11-20 16:28     ` Mauro Carvalho Chehab
2014-11-21  8:26     ` Maxime Ripard
2014-11-21  8:26       ` Maxime Ripard
2014-11-21  8:42       ` Hans de Goede
2014-11-21  8:42         ` Hans de Goede
2014-11-21  8:42         ` Hans de Goede
2014-11-21  9:59         ` Maxime Ripard
2014-11-21  9:59           ` Maxime Ripard
2014-11-21  9:59           ` Maxime Ripard
2014-11-21 10:13           ` Hans de Goede
2014-11-21 10:13             ` Hans de Goede
2014-11-21 10:13             ` Hans de Goede
2014-11-23 15:47             ` Maxime Ripard
2014-11-23 15:47               ` Maxime Ripard
2014-11-23 15:47               ` Maxime Ripard
2014-11-20 15:55 ` [PATCH 6/9] ARM: dts: sun6i: Add ir_clk node Hans de Goede
2014-11-20 15:55   ` Hans de Goede
2014-11-20 15:55   ` Hans de Goede
2014-11-20 15:55 ` [PATCH 7/9] ARM: dts: sun6i: Add ir node Hans de Goede
2014-11-20 15:55   ` Hans de Goede
2014-11-20 15:55   ` Hans de Goede
2014-11-20 15:55 ` [PATCH 8/9] ARM: dts: sun6i: Add pinmux settings for the ir pins Hans de Goede
2014-11-20 15:55   ` Hans de Goede
2014-11-20 15:55   ` Hans de Goede
2014-11-20 15:55 ` [PATCH 9/9] ARM: dts: sun6i: Enable ir receiver on the Mele M9 Hans de Goede
2014-11-20 15:55   ` Hans de Goede
2014-11-20 15:55   ` Hans de Goede

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=20141209085137.GQ8739@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 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.