From mboxrd@z Thu Jan 1 00:00:00 1970 From: Alexandre Belloni Subject: Re: [PATCH v3] ARM: at91: Document new TCB bindings Date: Mon, 4 Jul 2016 14:11:27 +0200 Message-ID: <20160704121127.GG20045@piout.net> References: <1467409925-17761-1-git-send-email-alexandre.belloni@free-electrons.com> <20160704122452.69dcddf0@bbrezillon> <20160704103631.GE20045@piout.net> <20160704140358.53ea7ad7@bbrezillon> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Content-Disposition: inline In-Reply-To: <20160704140358.53ea7ad7@bbrezillon> Sender: linux-pwm-owner@vger.kernel.org To: Boris Brezillon Cc: Nicolas Ferre , Jean-Christophe Plagniol-Villard , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Daniel Lezcano , Thierry Reding , linux-pwm@vger.kernel.org, Rob Herring , devicetree@vger.kernel.org List-Id: devicetree@vger.kernel.org On 04/07/2016 at 14:03:58 +0200, Boris Brezillon wrote : > On Mon, 4 Jul 2016 12:36:31 +0200 > Alexandre Belloni wrote: > > > On 04/07/2016 at 12:24:52 +0200, Boris Brezillon wrote : > > > On Fri, 1 Jul 2016 23:52:05 +0200 > > > Alexandre Belloni wrote: > > > > +One interrupt per TC block: > > > > + tcb0: timer@fff7c000 { > > > > + compatible = "atmel,at91rm9200-tcb", "simple-mfd", "syscon"; > > > > + #address-cells = <1>; > > > > + #size-cells = <0>; > > > > + reg = <0xfff7c000 0x100>; > > > > + interrupts = <18 4>; > > > > + clocks = <&tcb0_clk>, <&clk32k>; > > > > + clock-names = "t0_clk", "slow_clk"; > > > > + > > > > + timer@0 { > > > > + compatible = "atmel,tcb-timer"; > > > > + reg = <0>, <1>; > > > > + }; > > > > + > > > > + timer@2 { > > > > + compatible = "atmel,tcb-timer"; > > > > + reg = <2>; > > > > + }; > > > > > > And how can you differentiate the clocksource from the clkevent? > > > > > > > It doesn't really matter actually, I'll do the selection in the driver, > > as suggested by Rob. > > > > Yes, I've read Rob's review, but then what's the point of defining 2 > timer nodes, just do the detection based on the number of channels > you've reserved for the timer and define a single node. I agree this is a really hypothetical use case but one may want to have the clocksource on one TCB and the clockevent on another. This would allow to have for example a quadrature decoder and the clocksource on one TCB and another quadrature decoder and the clockevent device on another TCB. -- Alexandre Belloni, Free Electrons Embedded Linux and Kernel engineering http://free-electrons.com