From patchwork Fri Apr 12 19:17:21 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tomasz Figa X-Patchwork-Id: 2437691 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork2.kernel.org Received: from casper.infradead.org (casper.infradead.org [85.118.1.10]) by patchwork2.kernel.org (Postfix) with ESMTP id 8F64CDF2A1 for ; Fri, 12 Apr 2013 19:20:45 +0000 (UTC) Received: from merlin.infradead.org ([2001:4978:20e::2]) by casper.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1UQjVd-0004My-UU; Fri, 12 Apr 2013 19:19:43 +0000 Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1UQjV5-0002Na-67; Fri, 12 Apr 2013 19:19:07 +0000 Received: from mailout1.samsung.com ([203.254.224.24]) by merlin.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1UQjUW-0002KS-Vg for linux-arm-kernel@lists.infradead.org; Fri, 12 Apr 2013 19:18:34 +0000 Received: from epcpsbgm2.samsung.com (epcpsbgm2 [203.254.230.27]) by mailout1.samsung.com (Oracle Communications Messaging Server 7u4-24.01(7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTP id <0ML500BYKPMS9DC0@mailout1.samsung.com> for linux-arm-kernel@lists.infradead.org; Sat, 13 Apr 2013 04:18:28 +0900 (KST) X-AuditID: cbfee61b-b7f076d0000034b6-d6-51685e03be32 Received: from epmmp2 ( [203.254.227.17]) by epcpsbgm2.samsung.com (EPCPMTA) with SMTP id ED.8C.13494.30E58615; Sat, 13 Apr 2013 04:18:28 +0900 (KST) Received: from mcdsrvbld02.digital.local ([106.116.37.23]) by mmp2.samsung.com (Oracle Communications Messaging Server 7u4-24.01 (7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTPA id <0ML500CT6PL8T090@mmp2.samsung.com>; Sat, 13 Apr 2013 04:18:27 +0900 (KST) From: Tomasz Figa To: linux-arm-kernel@lists.infradead.org Subject: [PATCH v5 05/14] ARM: SAMSUNG: Add new PWM platform device Date: Fri, 12 Apr 2013 21:17:21 +0200 Message-id: <1365794250-14436-6-git-send-email-t.figa@samsung.com> X-Mailer: git-send-email 1.7.10 In-reply-to: <1365794250-14436-1-git-send-email-t.figa@samsung.com> References: <1365794250-14436-1-git-send-email-t.figa@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAAzWRW0hTcQDG+29n5xxnB0/HS4cJButCFJpdHv6ViCXEgYIa4otFtfS4iZvO TSWTaFk+tLxfajhYGik5NHHqcpWhVprNnBotsZa0NUNmkg2ttdxyk95+H98PvocP51L3EQGe k1fIKvPEMiHKRyx+55Z45LxUlDiqxeBa3QgGB777AfTr3qBw1uPAYHf7MgoHdV948FVFMgw4 3DxombYBOPSolQfHffGwsvk9Ch/2TSLwbdkiBo1OGw9qrc858OM7AvpM1xHY+dKOwdYPUxw4 rS9D4K/VVRTqPWYO7NK6EdhjbORCw5O/IEXAdOg7AHPzRgXK+P7UAcbcZMeYT7ZnKLM0MYEx PQ+uMVZtC2AWan0oU9VrAIx1sRFhHtv0XOaO24oyHmMc457RgTMRGfykLFaWU8wq9yVf5Eub 5n+jik7i8mhtG6IG/eEaEIbT5CE68NQHNjiGnvzchWoAH6fIu4AO6GaxjaDh0GNeHydooeQu 2qN2oEGOInfTDRpnSOKSPxG6298QKiLJVHqkfYkXZITcSRvHB5EgE+Rx2mha4WzMbaNdc1Uh P2zdr7fPh5had6q7q0ENIJrBJgOIZhWZCtUlifxAgkosVxXlSRIy8+VGEHpuPrYfGNRwGJA4 EG4mpAKpiOKJi1Ul8mFA41xhFHFuIFtEEVnikiusMv+CskjGqoZBLI4ItxJD5UdFFCkRF7K5 LKtglf9bDh4mUAPcZdY3oOHjYynR1d6FkybNjnJ4z7W6V3yi5eqt9MG0FEtFkqivMIBEoEfC E3mO21RN5AidyZRMWcYOFjjnskHM6bXKF3Jrbdth0Vczb7k0d6bepO7rpVIz0jtWDKdKTd6u 10bibEHxj7TVgYjt3jhZge1YzJSdLpV863QJEZVUvH8PV6kS/wOtNWzKtQIAAA== X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20130412_151833_323155_22323BFF X-CRM114-Status: UNSURE ( 9.95 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -7.5 (-------) X-Spam-Report: SpamAssassin version 3.3.2 on merlin.infradead.org summary: Content analysis details: (-7.5 points) pts rule name description ---- ---------------------- -------------------------------------------------- -5.0 RCVD_IN_DNSWL_HI RBL: Sender listed at http://www.dnswl.org/, high trust [203.254.224.24 listed in list.dnswl.org] 1.7 KHOP_BIG_TO_CC Sent to 10+ recipients instaed of Bcc or a list -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -2.4 RP_MATCHES_RCVD Envelope sender domain matches handover relay domain -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] Cc: mark.rutland@arm.com, heiko@sntech.de, Tomasz Figa , tomasz.figa@gmail.com, buserror@gmail.com, jacmet@sunsite.dk, augulis.darius@gmail.com, christer@weinigel.se, sylvester.nawrocki@gmail.com, m.szyprowski@samsung.com, kgene.kim@samsung.com, linux@arm.linux.org.uk, kwangwoo.lee@gmail.com, mcuelenaere@gmail.com, arnd@arndb.de, devicetree-discuss@lists.ozlabs.org, linux-samsung-soc@vger.kernel.org, john.stultz@linaro.org, ghcstop@gmail.com, linux@simtec.co.uk, broonie@opensource.wolfsonmicro.com, jekhor@gmail.com, kyungmin.park@samsung.com, tglx@linutronix.de X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org This patch adds new samsung_device_pwm platform device that represents the whole PWM/timer block and includes memory and IRQ resources. Signed-off-by: Tomasz Figa Signed-off-by: Kyungmin Park --- arch/arm/plat-samsung/devs.c | 16 ++++++++++++++++ arch/arm/plat-samsung/include/plat/devs.h | 1 + 2 files changed, 17 insertions(+) diff --git a/arch/arm/plat-samsung/devs.c b/arch/arm/plat-samsung/devs.c index e1124d9..bfae4dd 100644 --- a/arch/arm/plat-samsung/devs.c +++ b/arch/arm/plat-samsung/devs.c @@ -1168,6 +1168,22 @@ struct platform_device s3c_device_timer[] = { }; #endif /* CONFIG_SAMSUNG_DEV_PWM */ +static struct resource samsung_pwm_resource[] = { + DEFINE_RES_IRQ(IRQ_TIMER0), + DEFINE_RES_IRQ(IRQ_TIMER1), + DEFINE_RES_IRQ(IRQ_TIMER2), + DEFINE_RES_IRQ(IRQ_TIMER3), + DEFINE_RES_IRQ(IRQ_TIMER4), + DEFINE_RES_MEM(SAMSUNG_PA_TIMER, SZ_4K), +}; + +struct platform_device samsung_device_pwm = { + .name = "samsung-pwm", + .id = -1, + .num_resources = ARRAY_SIZE(samsung_pwm_resource), + .resource = samsung_pwm_resource, +}; + /* RTC */ #ifdef CONFIG_PLAT_S3C24XX diff --git a/arch/arm/plat-samsung/include/plat/devs.h b/arch/arm/plat-samsung/include/plat/devs.h index 87d501f..0dc4ac4 100644 --- a/arch/arm/plat-samsung/include/plat/devs.h +++ b/arch/arm/plat-samsung/include/plat/devs.h @@ -134,6 +134,7 @@ extern struct platform_device exynos4_device_spdif; extern struct platform_device samsung_asoc_idma; extern struct platform_device samsung_device_keypad; +extern struct platform_device samsung_device_pwm; /* s3c2440 specific devices */