Received: by 2002:a25:e7d8:0:0:0:0:0 with SMTP id e207csp1832210ybh; Fri, 13 Mar 2020 08:11:14 -0700 (PDT) X-Google-Smtp-Source: ADFU+vtXTPnH8vctZkz3wYAMv5zcCcmmfdschWkwnb52F0SOVW+6W0W9pTEdjqd7mRWunT1XFlHS X-Received: by 2002:a05:6830:2105:: with SMTP id i5mr11007615otc.141.1584112274144; Fri, 13 Mar 2020 08:11:14 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1584112274; cv=none; d=google.com; s=arc-20160816; b=EMqdpIFgzYpOwQINlWg3Qb74hpRuhftw8uH/pZ+jw77V4lz+4xsNMG1xLHjXzBAtkG wP8Pog1VTqN04w8/TDt4Fj4weHuy4SbSMQ+VD33fTCJNv75MZaDkudvdEf79yxoOznlV Z2mdQnbYD+Q6QDBFoywnzyfwGIjM6phk9G3uPZI8VTW8/JlPJshzcp4gCXXyVQx7W0Sp bQNh/wT/AcDk25NY8KsGVnRQHAltGakk1B03+strZA7TkDpNbkqJEMC8YTWAqnmWrgJf e9OehvT0Ull1XPNKBs/S5SuFhEZ8BQiOwsHqjgumAN6uU0ZqWRNnMCNiRci2o3FBURTz GNoA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=SOOQlRRgzDlXulXRP8XRTEOcJ9Vn73cRLOCRvsC8k8k=; b=uhaEJ4QhYSwLi4CUqFS12ldUmP/pVnIe1xlUUMG+dCab2snRFo/n3JIF3wzUQLhzwh sR8e1PmIvYJt6JQc0MT+pzEZ/+ajlWfpZpWjPlgQpEuoOTL/pLG/wTxGLsUklBjMVcGV JxsrhzvGr0z2cOsTOzlehOz1DACOM8koxfsKdEW731TFn3EcXJQgswJDqLyVRO779WoA gJBiw7cFVryxd1kH8Ctx7OmXZwiGmUV09++4ISzOioP4FJmx669ScQUB1SipfRDtLlV2 TNaXPhH1g9zceYhDsw1i6KdlULHqzeIXIpDskzgZ4F7osnAzqAv/A55ms+r9WdGFcHUK 1ucg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@baylibre-com.20150623.gappssmtp.com header.s=20150623 header.b=HCDXxq87; 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 e7si4765152otp.110.2020.03.13.08.10.55; Fri, 13 Mar 2020 08:11:14 -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; dkim=pass header.i=@baylibre-com.20150623.gappssmtp.com header.s=20150623 header.b=HCDXxq87; 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 S1726988AbgCMPIE (ORCPT + 99 others); Fri, 13 Mar 2020 11:08:04 -0400 Received: from mail-qv1-f65.google.com ([209.85.219.65]:40482 "EHLO mail-qv1-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726477AbgCMPIE (ORCPT ); Fri, 13 Mar 2020 11:08:04 -0400 Received: by mail-qv1-f65.google.com with SMTP id u17so4725181qvv.7 for ; Fri, 13 Mar 2020 08:08:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc:content-transfer-encoding; bh=SOOQlRRgzDlXulXRP8XRTEOcJ9Vn73cRLOCRvsC8k8k=; b=HCDXxq87aocDekRum4B/LXDX9SF1VI2U+P9KwqgPbKzYarJVy8BfnZxuSi0CfRdDOQ wY9ozP3dhoaFPnHp3A6aHq2UUlIzxamc3mePHE7ZWqPT8AuwxOPp9dN3BsM0r2lGdovp hVu3BuiuGkVp+gNVnOQB+HJ418WHtW/Klwdii3BwJaJ5vYFiLeY9x7jEzCW/5P8wzkJ6 uil2kUfMIaGFP6fh8Hd8Hyfy78Y7eqqBYertUSSx6cXnsj9S9xLh8A/mcaXtPo20sNQI WBqbzzD6DjJzo338cFMAXIwuzeoW6LXILLI4NiHYnuAZZPwwmfPpgvbBLOa1RRize2hh WxMQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc:content-transfer-encoding; bh=SOOQlRRgzDlXulXRP8XRTEOcJ9Vn73cRLOCRvsC8k8k=; b=pZT8LC3x/W3I5UzJZ3+38PfcgZSggAREW/UhoKN/dl0lk1Cn92TfnAPsvsjLgfFlrR jLS9y942s2pr+XoYdhEkPdBxNnDZF//EeuYGPskJY2Qu2VNlKKU0CwHExaSpWK+BR9Zi yCZiPcZWcckZGzen63MkvHfHs8ZmrD4AHhgcPTg2VIjSM+FC2w6k3MOaIuHbY3Frk/Ry Z1jM1HMmOLrgy9lYswOfmrkhOOWz9pmD4otNbyuyJsHHzHf1gTQcN7JwH8a12zoKEzOX VbyT057QtMaRsJ8wO0Z+4xPXI7JJpN16cHv1ZOGxOrLzGy0f9gxYbERA/sBW3PqH4hNM UWxw== X-Gm-Message-State: ANhLgQ18WQYrmsc6Fx3I9uNQeAmt7Fs/IVUIpuu6BN1gLZoGrQBF0KZP D+2IPgf/0OQQIPgdlJTdwOZXS6WPUpqfrCGmFsJmfA== X-Received: by 2002:a0c:9104:: with SMTP id q4mr4269547qvq.61.1584112082892; Fri, 13 Mar 2020 08:08:02 -0700 (PDT) MIME-Version: 1.0 References: <20200313034244.26336-1-chris.packham@alliedtelesis.co.nz> In-Reply-To: <20200313034244.26336-1-chris.packham@alliedtelesis.co.nz> From: Bartosz Golaszewski Date: Fri, 13 Mar 2020 16:07:49 +0100 Message-ID: Subject: Re: [PATCH] gpio: mvebu: avoid error message for optional IRQ To: Chris Packham Cc: Thierry Reding , =?UTF-8?Q?Uwe_Kleine=2DK=C3=B6nig?= , Linus Walleij , linux-pwm@vger.kernel.org, linux-gpio , LKML Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org pt., 13 mar 2020 o 04:42 Chris Packham napisa=C5=82(a): > > platform_get_irq() will generate an error message if the requested irq > is not present > > mvebu-gpio f1010140.gpio: IRQ index 3 not found > > use platform_get_irq_optional() to avoid the error message being > generated. > > Signed-off-by: Chris Packham > --- > drivers/gpio/gpio-mvebu.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/gpio/gpio-mvebu.c b/drivers/gpio/gpio-mvebu.c > index d2b999c7987f..3c9f4fb3d5a2 100644 > --- a/drivers/gpio/gpio-mvebu.c > +++ b/drivers/gpio/gpio-mvebu.c > @@ -1247,7 +1247,7 @@ static int mvebu_gpio_probe(struct platform_device = *pdev) > * pins. > */ > for (i =3D 0; i < 4; i++) { > - int irq =3D platform_get_irq(pdev, i); > + int irq =3D platform_get_irq_optional(pdev, i); > > if (irq < 0) > continue; > -- > 2.25.1 > Patch applied, thanks! Bartosz