From patchwork Mon Sep 19 09:10:32 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Shawn Guo X-Patchwork-Id: 4179 Return-Path: X-Original-To: patchwork@peony.canonical.com Delivered-To: patchwork@peony.canonical.com Received: from fiordland.canonical.com (fiordland.canonical.com [91.189.94.145]) by peony.canonical.com (Postfix) with ESMTP id DC9FD23F58 for ; Mon, 19 Sep 2011 09:24:06 +0000 (UTC) Received: from mail-fx0-f52.google.com (mail-fx0-f52.google.com [209.85.161.52]) by fiordland.canonical.com (Postfix) with ESMTP id CCDEFA1807A for ; Mon, 19 Sep 2011 09:24:06 +0000 (UTC) Received: by fxe23 with SMTP id 23so5246074fxe.11 for ; Mon, 19 Sep 2011 02:24:06 -0700 (PDT) Received: by 10.223.5.76 with SMTP id 12mr4779010fau.103.1316424246606; Mon, 19 Sep 2011 02:24:06 -0700 (PDT) X-Forwarded-To: linaro-patchwork@canonical.com X-Forwarded-For: patch@linaro.org linaro-patchwork@canonical.com Delivered-To: patches@linaro.org Received: by 10.152.18.198 with SMTP id y6cs29399lad; Mon, 19 Sep 2011 02:24:05 -0700 (PDT) Received: by 10.150.150.28 with SMTP id x28mr1937277ybd.198.1316424244656; Mon, 19 Sep 2011 02:24:04 -0700 (PDT) Received: from mail-yx0-f178.google.com (mail-yx0-f178.google.com [209.85.213.178]) by mx.google.com with ESMTPS id v10si9413912ybm.78.2011.09.19.02.24.04 (version=TLSv1/SSLv3 cipher=OTHER); Mon, 19 Sep 2011 02:24:04 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.213.178 is neither permitted nor denied by best guess record for domain of shawn.guo@linaro.org) client-ip=209.85.213.178; Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.213.178 is neither permitted nor denied by best guess record for domain of shawn.guo@linaro.org) smtp.mail=shawn.guo@linaro.org Received: by yxj19 with SMTP id 19so23302322yxj.37 for ; Mon, 19 Sep 2011 02:24:04 -0700 (PDT) Received: by 10.68.62.232 with SMTP id b8mr3811062pbs.523.1316424243512; Mon, 19 Sep 2011 02:24:03 -0700 (PDT) Received: from localhost.localdomain ([117.82.22.90]) by mx.google.com with ESMTPS id y5sm15355094pbe.6.2011.09.19.02.23.52 (version=TLSv1/SSLv3 cipher=OTHER); Mon, 19 Sep 2011 02:24:02 -0700 (PDT) From: Shawn Guo To: Grant Likely Cc: linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, patches@linaro.org, Shawn Guo Subject: [PATCH] gpio/mxc: make it work with imx6q Date: Mon, 19 Sep 2011 17:10:32 +0800 Message-Id: <1316423432-18333-1-git-send-email-shawn.guo@linaro.org> X-Mailer: git-send-email 1.7.4.1 The imx6q is a Cortex-A9 Quad Core SoC, which has GIC as the primary interrupt controller. GIC requires gpio irq handler to signal EOI, otherwise system will hang whenever there is a gpio irq triggered. Signed-off-by: Shawn Guo --- drivers/gpio/gpio-mxc.c | 3 +++ 1 files changed, 3 insertions(+), 0 deletions(-) diff --git a/drivers/gpio/gpio-mxc.c b/drivers/gpio/gpio-mxc.c index 4340aca..00b4c9c 100644 --- a/drivers/gpio/gpio-mxc.c +++ b/drivers/gpio/gpio-mxc.c @@ -233,6 +233,9 @@ static void mx3_gpio_irq_handler(u32 irq, struct irq_desc *desc) u32 irq_stat; struct mxc_gpio_port *port = irq_get_handler_data(irq); + if (desc->irq_data.chip->irq_eoi) + desc->irq_data.chip->irq_eoi(&desc->irq_data); + irq_stat = readl(port->base + GPIO_ISR) & readl(port->base + GPIO_IMR); mxc_gpio_irq_handler(port, irq_stat);