Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756886Ab3JKIQz (ORCPT ); Fri, 11 Oct 2013 04:16:55 -0400 Received: from mail-wg0-f52.google.com ([74.125.82.52]:59898 "EHLO mail-wg0-f52.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754239Ab3JKIQu (ORCPT ); Fri, 11 Oct 2013 04:16:50 -0400 MIME-Version: 1.0 In-Reply-To: <5241C4DB.9090200@wwwdotorg.org> References: <1377526030-32024-1-git-send-email-larsi@wh2.tu-dresden.de> <522FBED9.9000305@collabora.co.uk> <5230C7F6.3080803@wwwdotorg.org> <3653629.tapNZSuWhS@lem-wkst-02> <52373B34.4060709@wwwdotorg.org> <5240A2D3.20105@wwwdotorg.org> <5241C4DB.9090200@wwwdotorg.org> Date: Fri, 11 Oct 2013 10:16:49 +0200 Message-ID: Subject: Re: [PATCH v3] gpio: interrupt consistency check for OF GPIO IRQs From: Linus Walleij To: Stephen Warren Cc: Lars Poeschel , Javier Martinez Canillas , Mark Brown , Lars Poeschel , Grant Likely , "linux-gpio@vger.kernel.org" , "linux-kernel@vger.kernel.org" , "devicetree@vger.kernel.org" , Mark Rutland , Ian Campbell , Kumar Gala , Pawel Moll , Tomasz Figa , Enric Balletbo i Serra , Jean-Christophe PLAGNIOL-VILLARD , Santosh Shilimkar , Kevin Hilman , Balaji T K , Tony Lindgren , Jon Hunter , joelf@ti.com, Laurent Pinchart Content-Type: text/plain; charset=ISO-8859-1 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1160 Lines: 26 On Tue, Sep 24, 2013 at 6:59 PM, Stephen Warren wrote: > On 09/24/2013 02:31 AM, Linus Walleij wrote: >> On Mon, Sep 23, 2013 at 10:21 PM, Stephen Warren wrote: > ... >>> Perhaps rather than having the gpio_chip/irq_chip drivers physically >>> implement a function which calls this common code, they could set some >>> flags/data/... in the struct gpio_chip/irq_chip indicating that they >>> desire the core code that implements the error-checking to be enabled. >> >> I think it should more be like a function they can call to flag >> a GPIO as used for IRQ. > > For the record, that's pretty much exactly what I meant by implementing > it in the drivers. The irq_chip driver knows when the IRQ has been > requested, and calls some gpiolib function to mark the GPIO as > in-use-as-an-IRQ. Ah OK we're on the same page, this is progressing :-) Yours, Linus Walleij -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/