From patchwork Wed Sep 16 15:03:18 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Baryshkov X-Patchwork-Id: 48013 Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id n8GF4h0t017407 for ; Wed, 16 Sep 2009 15:04:43 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1759170AbZIPPDu (ORCPT ); Wed, 16 Sep 2009 11:03:50 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1759190AbZIPPDt (ORCPT ); Wed, 16 Sep 2009 11:03:49 -0400 Received: from mail-ew0-f206.google.com ([209.85.219.206]:38126 "EHLO mail-ew0-f206.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1759170AbZIPPDt (ORCPT ); Wed, 16 Sep 2009 11:03:49 -0400 Received: by ewy2 with SMTP id 2so1500658ewy.17 for ; Wed, 16 Sep 2009 08:03:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:from:to:cc:subject:date :message-id:x-mailer; bh=FlDFkTc3CSD/gcn+BcgVw6byF2sUBODgj20Dz4x7TOk=; b=G58uUdTxU4T200I4n3CKc3w5oNKES8o53J91/xfV7DE9ZLFLsUS8FhljWTykWv7uOx EyIhOR8EjYm8KUHvPkpa5NoXaY5qzI0PDphwSWRt7336Au4BqIp3Nw8rtnbGNMSh0PDW 6y7t5e0EXrgom7TGGPD+VmGopRxyE4ZXP0KB4= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:to:cc:subject:date:message-id:x-mailer; b=Y44PJu0+YDZEbyG2cZtVzGN6N2oVGm1D/Iaj/NjY5G6IYijMJ6hDOrDeD8TcEvGu4u nLkHvxCUyz8VCK8vt8vTLsV1w4D57l30pdLjLtoCrEsCRKzSOzPjFxSuycL0hJBlV/0c ruFlHCNVPne5lc3wxB91xqG7/XOBzh6Q7yTJY= Received: by 10.210.9.17 with SMTP id 17mr9236080ebi.23.1253113431447; Wed, 16 Sep 2009 08:03:51 -0700 (PDT) Received: from localhost.localdomain (iap-pxy-mow1.siemens.ru [212.248.25.26]) by mx.google.com with ESMTPS id 7sm2743824eyb.37.2009.09.16.08.03.49 (version=SSLv3 cipher=RC4-MD5); Wed, 16 Sep 2009 08:03:50 -0700 (PDT) From: Dmitry Eremin-Solenikov To: linux-input@vger.kernel.org Cc: Dmitry Torokhov Subject: [PATCH] input: make gpio-keys use IRQF_SHARED Date: Wed, 16 Sep 2009 19:03:18 +0400 Message-Id: <1253113398-22751-1-git-send-email-dbaryshkov@gmail.com> X-Mailer: git-send-email 1.6.3.3 Sender: linux-input-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-input@vger.kernel.org There is nothing that disallows gpio-keys to share it's IRQ line w/ other drivers. Make it use IRQF_SHARED in request_irq(). An example of other driver with which I'd like to share IRQ line for GPIO buttons is ledtrig-gpio. Signed-off-by: Dmitry Eremin-Solenikov --- drivers/input/keyboard/gpio_keys.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/drivers/input/keyboard/gpio_keys.c b/drivers/input/keyboard/gpio_keys.c index efed0c9..9fc2fab 100644 --- a/drivers/input/keyboard/gpio_keys.c +++ b/drivers/input/keyboard/gpio_keys.c @@ -147,6 +147,7 @@ static int __devinit gpio_keys_probe(struct platform_device *pdev) } error = request_irq(irq, gpio_keys_isr, + IRQF_SHARED | IRQF_TRIGGER_RISING | IRQF_TRIGGER_FALLING, button->desc ? button->desc : "gpio_keys", bdata);