Received: by 2002:ac0:a581:0:0:0:0:0 with SMTP id m1-v6csp3801044imm; Mon, 2 Jul 2018 05:57:37 -0700 (PDT) X-Google-Smtp-Source: ADUXVKK9EVjFvk1T2yMDUUOLZe0QXz5v2m5wqEdqXPlBIrK1xsCSDCwkq4EZMEY18NPgJ92FFgls X-Received: by 2002:a17:902:7586:: with SMTP id j6-v6mr25442696pll.262.1530536257404; Mon, 02 Jul 2018 05:57:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1530536257; cv=none; d=google.com; s=arc-20160816; b=nt4V2QAOCAhAQBt46glYImxhhpWHj54vso1YKngR2bJQ1OOhQnVSzuQoz3h2n1DbDO fPX/VCKTY6TWAQsZZv7ggiG8DcpB+gQu+pZeWR66wkt8k6GO6BJOnV22pn2l4zYosO3I Hm6GDae/TYCXFiMITk9Vrrub+NFx9bHrjmHn6S8IUD07oqx+xe+dL8ntIPzz/xrxTDJx +iaKKQDn1O3NXKmwb0xjra1yLkD61oCsqX7Y5qqcBcmk2r+OAUF68p4kKdRh/L1ydSGY 8hArHXzHLhsj23HZP25yf8i2y4g1F84pyS+NvzhRxAcJsB/wgeVaOqvAwivHQ74DtlXE go6w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:arc-authentication-results; bh=hkTUJQUDlCmuVlkCQ+atZ+e7f0DgxTNuzKKRMzRYKVg=; b=QwbkUjPtZC77KnpFoxms4BpHB8PVE8W5pn38Jmb3p7qRyU6KYci5pt78DeTkVm9VZp P1M8eHKlGWD2C7NN29RRVjia53R36yWsBVsXruDUgPbdB1nFMQ0HhF1IyHeBY6CpARXf QQh//YyB/j7Sd7BA7R+JbgF6fMxxexe4nwP+qi1fDIQg6m1qKI7NhqHY6r3MPWrNkelP OlkSX96G4z2+rtdEhL4uw23fyA1Xwe4e8lEO8yo7CiwqG7KcMogZrs7iuX0UFd9ZDZDo qQGLK/xV3Fu3skKyoOjQRW1CGwWXR/6zcdDF3mDzTJNKEL/BFixXfIlaOWM1pAhYZLXz xPSA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id w1-v6si9530146pfl.215.2018.07.02.05.57.22; Mon, 02 Jul 2018 05:57:37 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752367AbeGBM43 (ORCPT + 99 others); Mon, 2 Jul 2018 08:56:29 -0400 Received: from muru.com ([72.249.23.125]:49616 "EHLO muru.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752017AbeGBM41 (ORCPT ); Mon, 2 Jul 2018 08:56:27 -0400 Received: from atomide.com (localhost [127.0.0.1]) by muru.com (Postfix) with ESMTPS id DB88C8047; Mon, 2 Jul 2018 12:59:21 +0000 (UTC) Date: Mon, 2 Jul 2018 05:56:23 -0700 From: Tony Lindgren To: Janusz Krzysztofik Cc: Dmitry Torokhov , Aaro Koskinen , "David S . Miller " , Mauro Carvalho Chehab , Greg Kroah-Hartman , Andrew Morton , Randy Dunlap , Linus Walleij , Mark Brown , Liam Girdwood , linux-arm-kernel@lists.infradead.org, linux-omap@vger.kernel.org, linux-input@vger.kernel.org, linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v2 06/10] ARM: OMAP1: ams-delta FIQ: don't use static GPIO numbers Message-ID: <20180702125623.GX112168@atomide.com> References: <20180609140224.32606-1-jmkrzyszt@gmail.com> <20180621224128.17623-1-jmkrzyszt@gmail.com> <20180621224128.17623-6-jmkrzyszt@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20180621224128.17623-6-jmkrzyszt@gmail.com> User-Agent: Mutt/1.10.0 (2018-05-17) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org * Janusz Krzysztofik [180621 22:45]: > --- a/arch/arm/mach-omap1/board-ams-delta.c > +++ b/arch/arm/mach-omap1/board-ams-delta.c > @@ -580,6 +580,44 @@ static struct gpiod_hog ams_delta_gpio_hogs[] = { > {}, > }; > > +/* > + * Some drivers may not use GPIO lookup tables but need to be provided > + * with GPIO numbers. The same applies to GPIO based IRQ lines - some > + * drivers may even not use GPIO layer but expect just IRQ numbers. > + * We could either define GPIO lookup tables then use them on behalf > + * of those devices, or we can use GPIO driver level methods for > + * identification of GPIO and IRQ numbers. For the purpose of the latter, > + * defina a helper function which identifies GPIO chips by their labels. > + */ > +static int gpiochip_match_by_label(struct gpio_chip *chip, void *data) > +{ > + char *label = data; > + > + return !strcmp(label, chip->label); > +} I left out the duplicate gpiochip_match_by_label() above as it's already there from an earlier "ARM: OMAP1: ams-delta: assign LED GPIO numbers from descriptors". The whole series is now pushed out to omap-for-v4.19/omap1 and I'll merge it into my for-next soon. Thanks, Tony