Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp2205442rwd; Sun, 28 May 2023 10:11:12 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ4552zAuPb19r8Kkbv/CeUI8ZVYdBbuD9C/eGCKFtwdUsngKWpbGuStHXBjGGPH0BeCrcqH X-Received: by 2002:a05:6a20:3d1c:b0:104:d7e6:a8f2 with SMTP id y28-20020a056a203d1c00b00104d7e6a8f2mr7380706pzi.3.1685293871993; Sun, 28 May 2023 10:11:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1685293871; cv=none; d=google.com; s=arc-20160816; b=dqibNwqPnDCY+cypFX344MXwrQbNmnhKKPwvyWQJXx5g8H8AM0G6IA0FS9qYaQZ8zN 8Atz27PcIgcNf5EmTNI55PrTNlkcEXXM3LO7Iab7SqGmYUwOgTUr1EKwppw6SS09ZaBD 59TGlPEozeXS8bgO2eSuCePrgCjEGyP6nfuEdanb5DHIZEJfVNyRSqMmZk6qgTyTh7hO T8bAOjHLEjJsk0p8TUwfwWx4pmB0ppSELKx2c4KJAKbJXfy8+QBuKSsi+PJdgdpxETzO AAEj8wZRZvudKVuDv9anC31XSLXZXp4Z9KjTYOt7yhzIbHB2NfbDJksvj2HhZwo32HXJ 9Xug== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date :dkim-signature; bh=eOKMx5k+JLymazS0EDJ71U6IvJOVnduFheZtjB7heH0=; b=gd15+umZzZ8D3/w/qVkj7GlV3WrrTW5h+Horh9qD7USdmQQwOWVjxPtOb7bs2mPrfj 543TIstsPvusM7vFW3PSJ/jREIzWPQPMjItw+tSeLIzxckLl39+yoXa6xHmjMnXVOOj4 UXECbrqljms0ObSvjHZ0+ahLhMDynEQpmHpDuCzkkm/+l364Jz/xB/HuByYgGJ69I7tg wpe8mUOo9BzBVI16vWudZzkxYgksYHjMcVD7Wt9dWECKYJEksLxrDxuvcFP2xe4rdTwR hKwWgz7GQz6s7f6Dwv5gpy8sX8Mfi6y0dFRnt4kZdvsVgxd5Lyda9IqivNlE4z0YFgPb SgnQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=h3do2+xO; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id a9-20020aa78e89000000b0064d44f6fd24si7715455pfr.56.2023.05.28.10.10.57; Sun, 28 May 2023 10:11:11 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=h3do2+xO; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229660AbjE1RBi (ORCPT + 99 others); Sun, 28 May 2023 13:01:38 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36722 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229468AbjE1RBh (ORCPT ); Sun, 28 May 2023 13:01:37 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id EFB94AD; Sun, 28 May 2023 10:01:35 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 84C2260B08; Sun, 28 May 2023 17:01:35 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id CC785C433EF; Sun, 28 May 2023 17:01:29 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1685293294; bh=puQYi3Gammo1pbYrhpE6z2DzxrD82G53/ALPZGIYroI=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=h3do2+xOi7KHj2BdXbEoyVOWTqtt9V9UBpP1ug1xnrpWvs6djl9+HOzu1I3HQlbm1 r/lL7bhBdw5TYULJNq+K1BEeSwAkRNExCtpl4/+yqV3XIe0QZ/np8eFdVbxTI5TRzD sMv21zoaFQZXsgxSFkH+Mb4IC38lE+Ra2zC2EGXYtbyNr6RXrmb4g8RXwBugrakkzt HypfKRBjLNQJnA/VxHyoCkHQJA1dE3w4oIa0h/HN09lX8MJLbdCA6pj992/awD5hDE FtH7vXEYiyUpFcIoLSZ+XGXAoq59wK+O9YrvT9fhdFRCXR9hb1W8uKwjNbJW34KrIh bjpX8xye3tTsA== Date: Sun, 28 May 2023 18:17:50 +0100 From: Jonathan Cameron To: Matti Vaittinen Cc: Matti Vaittinen , Andy Shevchenko , Daniel Scally , Heikki Krogerus , Sakari Ailus , Greg Kroah-Hartman , "Rafael J. Wysocki" , Wolfram Sang , Lars-Peter Clausen , Michael Hennerich , Andreas Klinger , Marcin Wojtas , Russell King , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Jonathan =?UTF-8?B?TmV1c2Now6RmZXI=?= , Linus Walleij , Paul Cercueil , Akhil R , linux-acpi@vger.kernel.org, linux-kernel@vger.kernel.org, linux-i2c@vger.kernel.org, linux-iio@vger.kernel.org, netdev@vger.kernel.org, openbmc@lists.ozlabs.org, linux-gpio@vger.kernel.org, linux-mips@vger.kernel.org Subject: Re: [PATCH v6 4/8] pinctrl: wpcm450: relax return value check for IRQ get Message-ID: <20230528181750.599035ac@jic23-huawei> In-Reply-To: <830e6e61cf51d43cb7a99b846ab4676823e4e78a.1685082026.git.mazziesaccount@gmail.com> References: <830e6e61cf51d43cb7a99b846ab4676823e4e78a.1685082026.git.mazziesaccount@gmail.com> X-Mailer: Claws Mail 4.1.1 (GTK 3.24.38; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-4.6 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, 26 May 2023 09:38:05 +0300 Matti Vaittinen wrote: > fwnode_irq_get[_byname]() were changed to not return 0 anymore. The > special error case where device-tree based IRQ mapping fails can't no > longer be reliably detected from this return value. This yields a > functional change in the driver where the mapping failure is treated as > an error. >=20 > The mapping failure can occur for example when the device-tree IRQ > information translation call-back(s) (xlate) fail, IRQ domain is not > found, IRQ type conflicts, etc. In most cases this indicates an error in > the device-tree and special handling is not really required. >=20 > One more thing to note is that ACPI APIs do not return zero for any > failures so this special handling did only apply on device-tree based > systems. >=20 > Drop the special (no error, just skip the IRQ) handling for DT mapping > failures as these can no longer be separated from other errors at driver > side. >=20 > Signed-off-by: Matti Vaittinen > Reviewed-by: Jonathan Neusch=C3=A4fer > Acked-by: Linus Walleij >=20 Seems fine Reviewed-by: Jonathan Cameron > --- > Revision history: > v5 =3D> : > - No changes > v4 =3D> v5: > Fix typo in subject "elax" =3D> "relax" >=20 > Please note, I took Linus' reply to v4 cover-letter as ack && added the > tag. Please let me know if this was not Ok. >=20 > The first patch of the series changes the fwnode_irq_get() so this depends > on the first patch of the series and should not be applied alone. > --- > drivers/pinctrl/nuvoton/pinctrl-wpcm450.c | 2 -- > 1 file changed, 2 deletions(-) >=20 > diff --git a/drivers/pinctrl/nuvoton/pinctrl-wpcm450.c b/drivers/pinctrl/= nuvoton/pinctrl-wpcm450.c > index 2d1c1652cfd9..f9326210b5eb 100644 > --- a/drivers/pinctrl/nuvoton/pinctrl-wpcm450.c > +++ b/drivers/pinctrl/nuvoton/pinctrl-wpcm450.c > @@ -1106,8 +1106,6 @@ static int wpcm450_gpio_register(struct platform_de= vice *pdev, > irq =3D fwnode_irq_get(child, i); > if (irq < 0) > break; > - if (!irq) > - continue; > =20 > girq->parents[i] =3D irq; > girq->num_parents++;