From patchwork Mon Apr 4 17:11:04 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marcin Niestroj X-Patchwork-Id: 8743221 Return-Path: X-Original-To: patchwork-linux-input@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id F33AC9F39A for ; Mon, 4 Apr 2016 17:17:28 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 2A9D520154 for ; Mon, 4 Apr 2016 17:17:28 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 5210620160 for ; Mon, 4 Apr 2016 17:17:27 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756180AbcDDRRY (ORCPT ); Mon, 4 Apr 2016 13:17:24 -0400 Received: from 2780.rev.megiteam.pl ([91.227.39.128]:55927 "EHLO vk1046.megiteam.com.pl" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1755633AbcDDRRW (ORCPT ); Mon, 4 Apr 2016 13:17:22 -0400 Received: from gm.localdomain (unknown [95.143.241.142]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (No client certificate requested) (Authenticated sender: marcin.niestroj@grinn-global.com) by vk1046.megiteam.com.pl (Postfix) with ESMTP id 026B1622738B; Mon, 4 Apr 2016 19:11:34 +0200 (CEST) From: Marcin Niestroj To: Lee Jones Cc: Tony Lindgren , Sebastian Reichel , Dmitry Eremin-Solenikov , David Woodhouse , Rob Herring , Pawel Moll , linux-omap@vger.kernel.org, linux-pm@vger.kernel.org, linux-input@vger.kernel.org, devicetree@vger.kernel.org, Marcin Niestroj Subject: [PATCH 4/5] mfd: tps65217: Add power button as subdevice Date: Mon, 4 Apr 2016 19:11:04 +0200 Message-Id: <1459789865-3704-6-git-send-email-m.niestroj@grinn-global.com> X-Mailer: git-send-email 2.8.0 In-Reply-To: <1459789865-3704-1-git-send-email-m.niestroj@grinn-global.com> References: <1459789865-3704-1-git-send-email-m.niestroj@grinn-global.com> X-Virus-Scanned: by amavisd-new Sender: linux-input-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-input@vger.kernel.org X-Spam-Status: No, score=-7.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, UNPARSEABLE_RELAY 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 Add tps65217 power buttor subdevice with assigned IRQ resources. Signed-off-by: Marcin Niestroj --- drivers/mfd/tps65217.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/drivers/mfd/tps65217.c b/drivers/mfd/tps65217.c index a20980f..fd3b5d8 100644 --- a/drivers/mfd/tps65217.c +++ b/drivers/mfd/tps65217.c @@ -38,6 +38,10 @@ static struct resource charger_resources[] = { DEFINE_RES_IRQ_NAMED(TPS65217_IRQ_USB, "USB"), }; +static struct resource pb_resources[] = { + DEFINE_RES_IRQ_NAMED(TPS65217_IRQ_PB, "PB"), +}; + struct tps65217_irq { int mask; int interrupt; @@ -122,6 +126,12 @@ static struct mfd_cell tps65217s[] = { .resources = charger_resources, .of_compatible = "ti,tps65217-charger", }, + { + .name = "tps65217-pwrbutton", + .num_resources = ARRAY_SIZE(pb_resources), + .resources = pb_resources, + .of_compatible = "ti,tps65217-pwrbutton", + }, }; static irqreturn_t tps65217_irq_thread(int irq, void *data)