public inbox for linux-arm-kernel@lists.infradead.org
 help / color / mirror / Atom feed
From: mark.rutland@arm.com (Mark Rutland)
To: linux-arm-kernel@lists.infradead.org
Subject: [RESEND PATCH 4/8] layerscape/ftm: Add compatible string for FTM0 be used as alarm timer.
Date: Wed, 1 Apr 2015 14:24:00 +0100	[thread overview]
Message-ID: <20150401132400.GF11403@leverpostej> (raw)
In-Reply-To: <1427888858-29636-5-git-send-email-bhupesh.sharma@freescale.com>

On Wed, Apr 01, 2015 at 12:47:34PM +0100, Bhupesh Sharma wrote:
> From: Wang Dongsheng <dongsheng.wang@freescale.com>
> 
> Only FTM0 can be used as an alarm timer, so add a "fsl,ftm-alarm"
> compatible string to describe FTM0 alarm mode.
> 
> Signed-off-by: Wang Dongsheng <dongsheng.wang@freescale.com>
> Reviewed-by: Bhupesh Sharma <bhupesh.sharma@freescale.com>
> ---
>  .../devicetree/bindings/timer/fsl,ftm-timer.txt    |   46 ++++++++++++++------
>  1 file changed, 32 insertions(+), 14 deletions(-)

Shouldn't there be a corresponding driver update?

There wasn't one in this series.

> 
> diff --git a/Documentation/devicetree/bindings/timer/fsl,ftm-timer.txt b/Documentation/devicetree/bindings/timer/fsl,ftm-timer.txt
> index aa8c402..a372ed7 100644
> --- a/Documentation/devicetree/bindings/timer/fsl,ftm-timer.txt
> +++ b/Documentation/devicetree/bindings/timer/fsl,ftm-timer.txt
> @@ -2,12 +2,18 @@ Freescale FlexTimer Module (FTM) Timer
>  
>  Required properties:
>  
> -- compatible : should be "fsl,ftm-timer"
> +- compatible : should be "fsl,ftm-timer" & "fsl,ftm-alarm".
> +  (a) "fsl,ftm-timer", for FlexTimer compatible as normal timer.
> +  (b) "fsl,ftm-alarm", for FlexTimer compatible when FTM0 as an ALARM timer.


Lets not be redundant here. This would be better as:

- compatible: should contain one of:
  * "fsl,ftm-timer" for a FlexTimer usable as a normal timer.
  * "fsl,ftm-alarm" for a FlexTimer usable as an ALARM timer.

I don't think FTM0 is useful to mention here; it sounds like that's just
the name of an instance on a particular design.

What exactly is the difference between a "normal" timer and an "alarm"
timer?

> +
>  - reg : Specifies base physical address and size of the register sets for the
>    clock event device and clock source device.
> +
>  - interrupts : Should be the clock event device interrupt.
> +
>  - clocks : The clocks provided by the SoC to drive the timer, must contain an
>    entry for each entry in clock-names.
> +
>  - clock-names : Must include the following entries:
>    o "ftm-evt"
>    o "ftm-src"
> @@ -16,16 +22,28 @@ Required properties:
>  - big-endian: One boolean property, the big endian mode will be in use if it is
>    present, or the little endian mode will be in use for all the device registers.
>  
> -Example:
> -ftm: ftm at 400b8000 {
> -	compatible = "fsl,ftm-timer";
> -	reg = <0x400b8000 0x1000 0x400b9000 0x1000>;
> -	interrupts = <0 44 IRQ_TYPE_LEVEL_HIGH>;
> -	clock-names = "ftm-evt", "ftm-src",
> -		"ftm-evt-counter-en", "ftm-src-counter-en";
> -	clocks = <&clks VF610_CLK_FTM2>,
> -		<&clks VF610_CLK_FTM3>,
> -		<&clks VF610_CLK_FTM2_EXT_FIX_EN>,
> -		<&clks VF610_CLK_FTM3_EXT_FIX_EN>;
> -	big-endian;
> -};
> +Example 1: In this example, The FlexTimer module (FTM) is a two-to-eight,
> +	   channel timer that supports input capture, output compare, and
> +	   the generation of PWM signals to control electric motor and power
> +	   management applications.
> +
> +	ftm: ftm at 400b8000 {
> +		compatible = "fsl,ftm-timer";
> +		reg = <0x400b8000 0x1000 0x400b9000 0x1000>;
> +		interrupts = <0 44 IRQ_TYPE_LEVEL_HIGH>;
> +		clock-names = "ftm-evt", "ftm-src",
> +			"ftm-evt-counter-en", "ftm-src-counter-en";
> +		clocks = <&clks VF610_CLK_FTM2>,
> +			<&clks VF610_CLK_FTM3>,
> +			<&clks VF610_CLK_FTM2_EXT_FIX_EN>,
> +			<&clks VF610_CLK_FTM3_EXT_FIX_EN>;
> +		big-endian;
> +	};
> +
> +Example 2: In this example, FTM0 only be used as an alarm timer.

Do you mean that FTM0 is the only instance usable as an alarm timer, or
that the FTM0 instance can only be used as an alarm timer?

> +
> +	ftm0: ftm0 at 2800000 {
> +		compatible = "fsl,ftm-alarm";
> +		reg = <0x0 0x2800000 0x0 0x10000>;
> +		interrupts = <GIC_SPI 76 IRQ_TYPE_LEVEL_HIGH>;
> +	};

Missing properties?

Mark.

  reply	other threads:[~2015-04-01 13:24 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-04-01 11:47 [RESEND PATCH 0/8] ARM64: Update support for FSL's LS2085A SoC Bhupesh Sharma
2015-04-01 11:47 ` [RESEND PATCH 1/8] Documentation: DT: Add entry for FSL LS2085A QDS and RDB boards Bhupesh Sharma
2015-04-01 11:47 ` [RESEND PATCH 2/8] doc/bindings: Update PCIe devicetree binding documentation for LS2085A Bhupesh Sharma
2015-04-01 11:47 ` [RESEND PATCH 3/8] doc/bindings: Update clk-qoriq bindings for FSL's chassis-3.0 SoCs Bhupesh Sharma
2015-04-01 11:47 ` [RESEND PATCH 4/8] layerscape/ftm: Add compatible string for FTM0 be used as alarm timer Bhupesh Sharma
2015-04-01 13:24   ` Mark Rutland [this message]
2015-04-21  5:18     ` Dongsheng.Wang at freescale.com
2015-04-21 10:42       ` Mark Rutland
2015-04-21 11:01         ` Dongsheng.Wang at freescale.com
2015-04-21 11:22           ` Mark Rutland
2015-04-01 11:47 ` [RESEND PATCH 5/8] dts/ls2085a: Update DTSI to add support of various peripherals Bhupesh Sharma
2015-04-01 11:47 ` [RESEND PATCH 6/8] dts/ls2085a: Update Simulator DTS " Bhupesh Sharma
2015-04-01 11:47 ` [RESEND PATCH 7/8] dts/ls2085a: Add DTS support for LS2085a QDS & RDB boards Bhupesh Sharma
2015-04-01 11:47 ` [RESEND PATCH 8/8] dts/Makefile: Add build support for LS2085a QDS & RDB board DTS Bhupesh Sharma

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=20150401132400.GF11403@leverpostej \
    --to=mark.rutland@arm.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