From patchwork Fri Jul 22 14:17:12 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Philippe_R=C3=83=C2=A9tornaz?= X-Patchwork-Id: 999552 Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) by demeter1.kernel.org (8.14.4/8.14.4) with ESMTP id p6MEJGja024861 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Fri, 22 Jul 2011 14:19:37 GMT Received: from canuck.infradead.org ([2001:4978:20e::1]) by merlin.infradead.org with esmtps (Exim 4.76 #1 (Red Hat Linux)) id 1QkGZB-0003IP-9e; Fri, 22 Jul 2011 14:19:02 +0000 Received: from localhost ([127.0.0.1] helo=canuck.infradead.org) by canuck.infradead.org with esmtp (Exim 4.76 #1 (Red Hat Linux)) id 1QkGZ9-0005qG-KT; Fri, 22 Jul 2011 14:18:59 +0000 Received: from smtp3.epfl.ch ([128.178.224.226]) by canuck.infradead.org with smtp (Exim 4.76 #1 (Red Hat Linux)) id 1QkGXc-0005Uu-P7 for linux-arm-kernel@lists.infradead.org; Fri, 22 Jul 2011 14:17:26 +0000 Received: (qmail 29633 invoked by uid 107); 22 Jul 2011 14:17:22 -0000 X-Virus-Scanned: ClamAV Received: from lsro1pc40.epfl.ch (HELO discarded) (128.178.145.86) (authenticated) by smtp3.epfl.ch (AngelmatoPhylax SMTP proxy) with ESMTPA; Fri, 22 Jul 2011 16:17:22 +0200 From: =?utf-8?q?Philippe=20R=C3=A9tornaz?= To: s.hauer@pengutronix.de Subject: [PATCH 6/6] mx31moboard: Add MC13783 power button support Date: Fri, 22 Jul 2011 16:17:12 +0200 Message-Id: <1311344232-29902-7-git-send-email-philippe.retornaz@epfl.ch> X-Mailer: git-send-email 1.6.3.3 In-Reply-To: <1311344232-29902-6-git-send-email-philippe.retornaz@epfl.ch> References: <1311344232-29902-1-git-send-email-philippe.retornaz@epfl.ch> <1311344232-29902-2-git-send-email-philippe.retornaz@epfl.ch> <1311344232-29902-3-git-send-email-philippe.retornaz@epfl.ch> <1311344232-29902-4-git-send-email-philippe.retornaz@epfl.ch> <1311344232-29902-5-git-send-email-philippe.retornaz@epfl.ch> <1311344232-29902-6-git-send-email-philippe.retornaz@epfl.ch> MIME-Version: 1.0 X-CRM114-Version: 20090807-BlameThorstenAndJenny ( TRE 0.7.6 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20110722_101725_239249_CD562181 X-CRM114-Status: UNSURE ( 9.01 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -3.5 (---) X-Spam-Report: SpamAssassin version 3.3.1 on canuck.infradead.org summary: Content analysis details: (-3.5 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at http://www.dnswl.org/, medium trust [128.178.224.226 listed in list.dnswl.org] -1.2 RP_MATCHES_RCVD Envelope sender domain matches handover relay domain Cc: amit.kucheria@canonical.com, sameo@linux.intel.com, shawn.guo@freescale.com, broonie@opensource.wolfsonmicro.com, philippe.retornaz@epfl.ch, gaowanlong@cn.fujitsu.com, linux-input@vger.kernel.org, u.kleine-koenig@pengutronix.de, dmitry.torokhov@gmail.com, linux-arm-kernel@lists.infradead.org X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: linux-arm-kernel-bounces@lists.infradead.org Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.6 (demeter1.kernel.org [140.211.167.41]); Fri, 22 Jul 2011 14:19:37 +0000 (UTC) X-MIME-Autoconverted: from base64 to 8bit by demeter1.kernel.org id p6MEJGja024861 Add the power-on button on mx31moboard using MC13783 PMIC. Signed-off-by: Philippe Rétornaz --- arch/arm/mach-imx/mach-mx31moboard.c | 8 ++++++++ 1 files changed, 8 insertions(+), 0 deletions(-) diff --git a/arch/arm/mach-imx/mach-mx31moboard.c b/arch/arm/mach-imx/mach-mx31moboard.c index 579ca1f..2a43492 100644 --- a/arch/arm/mach-imx/mach-mx31moboard.c +++ b/arch/arm/mach-imx/mach-mx31moboard.c @@ -28,6 +28,7 @@ #include #include #include +#include #include #include @@ -264,12 +265,19 @@ static struct mc13783_leds_platform_data moboard_leds = { .tc2_period = MC13783_LED_PERIOD_10MS, }; +static struct mc13783_buttons_platform_data moboard_buttons = { + .b1on_flags = MC13783_BUTTON_DBNC_750MS | MC13783_BUTTON_ENABLE | + MC13783_BUTTON_POL_INVERT, + .b1on_key = KEY_POWER, +}; + static struct mc13xxx_platform_data moboard_pmic = { .regulators = { .regulators = moboard_regulators, .num_regulators = ARRAY_SIZE(moboard_regulators), }, .leds = &moboard_leds, + .buttons = &moboard_buttons, .flags = MC13XXX_USE_RTC | MC13XXX_USE_ADC, };