From patchwork Wed Apr 1 11:40:58 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "bhupesh.sharma@freescale.com" X-Patchwork-Id: 6139681 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 8EEA8BF4A6 for ; Wed, 1 Apr 2015 11:50:06 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id B295B2012E for ; Wed, 1 Apr 2015 11:50:05 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id BB35120172 for ; Wed, 1 Apr 2015 11:50:03 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1YdH3h-0007W6-Jl; Wed, 01 Apr 2015 11:43:45 +0000 Received: from mail-bl2on0105.outbound.protection.outlook.com ([65.55.169.105] helo=na01-bl2-obe.outbound.protection.outlook.com) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1YdH2Q-0006q6-4K for linux-arm-kernel@lists.infradead.org; Wed, 01 Apr 2015 11:42:27 +0000 Received: from BY2PR03CA050.namprd03.prod.outlook.com (10.141.249.23) by BL2PR03MB179.namprd03.prod.outlook.com (10.255.230.154) with Microsoft SMTP Server (TLS) id 15.1.118.15; Wed, 1 Apr 2015 11:42:03 +0000 Received: from BN1BFFO11FD037.protection.gbl (2a01:111:f400:7c10::1:124) by BY2PR03CA050.outlook.office365.com (2a01:111:e400:2c5d::23) with Microsoft SMTP Server (TLS) id 15.1.125.19 via Frontend Transport; Wed, 1 Apr 2015 11:42:03 +0000 Authentication-Results: spf=fail (sender IP is 192.88.168.50) smtp.mailfrom=freescale.com; freescale.mail.onmicrosoft.com; dkim=none (message not signed) header.d=none; Received-SPF: Fail (protection.outlook.com: domain of freescale.com does not designate 192.88.168.50 as permitted sender) receiver=protection.outlook.com; client-ip=192.88.168.50; helo=tx30smr01.am.freescale.net; Received: from tx30smr01.am.freescale.net (192.88.168.50) by BN1BFFO11FD037.mail.protection.outlook.com (10.58.144.100) with Microsoft SMTP Server (TLS) id 15.1.136.16 via Frontend Transport; Wed, 1 Apr 2015 11:42:02 +0000 Received: from b45370.ap.freescale.net (NETWORKudp188562uds.ap.freescale.net [10.232.40.151] (may be forged)) by tx30smr01.am.freescale.net (8.14.3/8.14.0) with ESMTP id t31BfBr7019381; Wed, 1 Apr 2015 04:41:57 -0700 From: Bhupesh Sharma To: , , , Subject: [PATCH 4/8] layerscape/ftm: Add compatible string for FTM0 be used as alarm timer. Date: Wed, 1 Apr 2015 17:10:58 +0530 Message-ID: <1427888463-29549-5-git-send-email-bhupesh.sharma@freescale.com> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1427888463-29549-1-git-send-email-bhupesh.sharma@freescale.com> References: <1427888463-29549-1-git-send-email-bhupesh.sharma@freescale.com> X-EOPAttributedMessage: 0 X-Forefront-Antispam-Report: CIP:192.88.168.50; CTRY:US; IPV:NLI; EFV:NLI; BMV:1; SFV:NSPM; SFS:(10019020)(6009001)(339900001)(279900001)(189002)(199003)(50986999)(50466002)(575784001)(87936001)(2950100001)(77156002)(229853001)(105606002)(86362001)(85426001)(19580395003)(2201001)(50226001)(76176999)(77096005)(106466001)(15975445007)(47776003)(48376002)(19625305001)(104016003)(92566002)(33646002)(6806004)(19580405001)(36756003)(62966003)(46102003)(42866002); DIR:OUT; SFP:1102; SCL:1; SRVR:BL2PR03MB179; H:tx30smr01.am.freescale.net; FPR:; SPF:Fail; MLV:sfv; MX:1; A:1; LANG:en; MIME-Version: 1.0 X-Microsoft-Antispam: UriScan:;BCL:0;PCL:0;RULEID:;SRVR:BL2PR03MB179; X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(601004)(5005006)(5002010); SRVR:BL2PR03MB179; BCL:0; PCL:0; RULEID:; SRVR:BL2PR03MB179; X-Forefront-PRVS: 053315510E X-OriginatorOrg: freescale.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 01 Apr 2015 11:42:02.4871 (UTC) X-MS-Exchange-CrossTenant-Id: 710a03f5-10f6-4d38-9ff4-a80b81da590d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=710a03f5-10f6-4d38-9ff4-a80b81da590d; Ip=[192.88.168.50]; Helo=[tx30smr01.am.freescale.net] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: BL2PR03MB179 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20150401_044226_359482_BF3383F9 X-CRM114-Status: UNSURE ( 8.49 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -0.0 (/) Cc: bhupesh.sharma@freescale.com, Catalin.Marinas@arm.com, will.deacon@arm.com, stuart.yoder@freescale.com, Wang Dongsheng , olof@lixom.net, bhupesh.linux@gmail.com X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY, WEIRD_PORT autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Wang Dongsheng 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 Change-Id: Ie9a6c1c01a362ee6f0b6c995f9a104a3afff9165 Reviewed-on: http://git.am.freescale.net:8181/30167 Tested-by: Review Code-CDREVIEW Reviewed-by: Bhupesh Sharma Tested-by: Bhupesh Sharma --- .../devicetree/bindings/timer/fsl,ftm-timer.txt | 46 ++++++++++++++------ 1 file changed, 32 insertions(+), 14 deletions(-) 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. + - 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@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@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. + + ftm0: ftm0@2800000 { + compatible = "fsl,ftm-alarm"; + reg = <0x0 0x2800000 0x0 0x10000>; + interrupts = ; + };