From patchwork Mon Dec 23 20:45:58 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Boyd X-Patchwork-Id: 3398391 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.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 6194AC0D4A for ; Mon, 23 Dec 2013 20:48:48 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 85B952078C for ; Mon, 23 Dec 2013 20:48:47 +0000 (UTC) Received: from casper.infradead.org (casper.infradead.org [85.118.1.10]) (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 A120D20787 for ; Mon, 23 Dec 2013 20:48:46 +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 1VvCPT-0003Si-8I; Mon, 23 Dec 2013 20:47:32 +0000 Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1VvCP8-0007nE-Ej; Mon, 23 Dec 2013 20:47:10 +0000 Received: from smtp.codeaurora.org ([198.145.11.231]) by merlin.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1VvCOS-0007hj-BX for linux-arm-kernel@lists.infradead.org; Mon, 23 Dec 2013 20:46:31 +0000 Received: from smtp.codeaurora.org (localhost [127.0.0.1]) by smtp.codeaurora.org (Postfix) with ESMTP id 6B2B613EFA3; Mon, 23 Dec 2013 20:46:08 +0000 (UTC) Received: by smtp.codeaurora.org (Postfix, from userid 486) id 5D23013EF89; Mon, 23 Dec 2013 20:46:08 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Spam-Level: X-Spam-Status: No, score=-4.7 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 Received: from sboyd-linux.qualcomm.com (i-global252.qualcomm.com [199.106.103.252]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) (Authenticated sender: sboyd@smtp.codeaurora.org) by smtp.codeaurora.org (Postfix) with ESMTPSA id C56A613EF89; Mon, 23 Dec 2013 20:46:06 +0000 (UTC) From: Stephen Boyd To: Samuel Ortiz , Lee Jones Subject: [PATCH v2 2/7] mfd: pm8921: Update for genirq changes Date: Mon, 23 Dec 2013 12:45:58 -0800 Message-Id: <1387831563-13535-3-git-send-email-sboyd@codeaurora.org> X-Mailer: git-send-email 1.8.5.1.163.gd7aced9 In-Reply-To: <1387831563-13535-1-git-send-email-sboyd@codeaurora.org> References: <1387831563-13535-1-git-send-email-sboyd@codeaurora.org> X-Virus-Scanned: ClamAV using ClamSMTP X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20131223_154628_577841_C4488159 X-CRM114-Status: GOOD ( 17.59 ) X-Spam-Score: -2.5 (--) Cc: linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org 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 X-Virus-Scanned: ClamAV using ClamSMTP Since this code has been marked broken for some time a few genirq tree wide changes weren't made. set_irq_wake() was renamed to irq_set_irq_wake() in commit a0cd9ca2b (genirq: Namespace cleanup, 2011-02-10) and commit 10a8c383 (irq: introduce entry and exit functions for chained handlers) introduced the chained irq functions but this driver wasn't updated to use them. Fix these problems and remove the BROKEN marking on this driver. Acked-by: Lee Jones Signed-off-by: Stephen Boyd --- drivers/mfd/Kconfig | 1 - drivers/mfd/pm8921-core.c | 7 +++++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/drivers/mfd/Kconfig b/drivers/mfd/Kconfig index 9ee4ce6..35007ed 100644 --- a/drivers/mfd/Kconfig +++ b/drivers/mfd/Kconfig @@ -453,7 +453,6 @@ config MFD_PM8XXX config MFD_PM8921_CORE tristate "Qualcomm PM8921 PMIC chip" depends on (ARCH_MSM || HEXAGON) - depends on BROKEN select MFD_CORE select MFD_PM8XXX help diff --git a/drivers/mfd/pm8921-core.c b/drivers/mfd/pm8921-core.c index 669f8f2..7964932 100644 --- a/drivers/mfd/pm8921-core.c +++ b/drivers/mfd/pm8921-core.c @@ -15,6 +15,7 @@ #include #include +#include #include #include #include @@ -174,6 +175,8 @@ static void pm8xxx_irq_handler(unsigned int irq, struct irq_desc *desc) u8 root; int i, ret, masters = 0; + chained_irq_enter(irq_chip, desc); + ret = pm8xxx_read_root_irq(chip, &root); if (ret) { pr_err("Can't read root status ret=%d\n", ret); @@ -188,7 +191,7 @@ static void pm8xxx_irq_handler(unsigned int irq, struct irq_desc *desc) if (masters & (1 << i)) pm8xxx_irq_master_handler(chip, i); - irq_chip->irq_ack(&desc->irq_data); + chained_irq_exit(irq_chip, desc); } static void pm8xxx_irq_mask_ack(struct irq_data *d) @@ -367,7 +370,7 @@ static struct pm_irq_chip *pm8xxx_irq_init(struct device *dev, irq_set_irq_type(devirq, pdata->irq_trigger_flag); irq_set_handler_data(devirq, chip); irq_set_chained_handler(devirq, pm8xxx_irq_handler); - set_irq_wake(devirq, 1); + irq_set_irq_wake(devirq, 1); return chip; }