Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753222Ab3HUX1T (ORCPT ); Wed, 21 Aug 2013 19:27:19 -0400 Received: from mail-ob0-f174.google.com ([209.85.214.174]:45527 "EHLO mail-ob0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752806Ab3HUX1R (ORCPT ); Wed, 21 Aug 2013 19:27:17 -0400 MIME-Version: 1.0 In-Reply-To: <521548E3.6010703@wwwdotorg.org> References: <1377092334-770-1-git-send-email-larsi@wh2.tu-dresden.de> <1507189.CRWvzVJqTV@flatron> <521548E3.6010703@wwwdotorg.org> Date: Thu, 22 Aug 2013 01:27:17 +0200 Message-ID: Subject: Re: [PATCH v2] gpio: interrupt consistency check for OF GPIO IRQs From: Linus Walleij To: Stephen Warren Cc: Tomasz Figa , Lars Poeschel , Lars Poeschel , Grant Likely , "linux-gpio@vger.kernel.org" , "linux-kernel@vger.kernel.org" , "devicetree@vger.kernel.org" , Mark Rutland , Ian Campbell , galak@codeaurora.org, Pawel Moll , Javier Martinez Canillas , Enric Balletbo i Serra , Jean-Christophe PLAGNIOL-VILLARD , Santosh Shilimkar , Kevin Hilman , Balaji T K , Tony Lindgren , Jon Hunter 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: 1303 Lines: 30 On Thu, Aug 22, 2013 at 1:10 AM, Stephen Warren wrote: >> On Wednesday 21 of August 2013 15:38:54 Lars Poeschel wrote: >>> To solve this dilemma, perform an interrupt consistency check >>> when adding a GPIO chip: if the chip is both gpio-controller and >>> interrupt-controller, walk all children of the device tree, > > It seems a little odd to solve this only for DT. What about the non-DT case? DT is the hardware configuration system that lets you request the same resource in two ways, i.e. it allows one and the same node to be both gpio-controller and interrupt-controller, and start handing out the same line as both GPIO and IRQ independently. I asked if ACPI had this ambiguity, and the answer appears to be either "no" (which I suspect) or just "nobody knows" :-/ In either way, checking the consistency of ACPI IRQs vs GPIOs will be fundamentally different, should it have the same problem, and does it appear we can certainly refactor this to be shared, should there be something to gain from. 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/