Message ID | 143e6d7a1d2b1fb692097f6c855f2553aca93589.1690890774.git.mazziesaccount@gmail.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:918b:0:b0:3e4:2afc:c1 with SMTP id s11csp2678132vqg; Tue, 1 Aug 2023 06:43:48 -0700 (PDT) X-Google-Smtp-Source: APBJJlFgzmSsArPo1Y5CPgIROvtOgl62qCtDEPbL6RaMRe6jis+XtnA54IA+im1QDSdWo7JLqdB4 X-Received: by 2002:a17:90a:4046:b0:268:5ebc:34a with SMTP id k6-20020a17090a404600b002685ebc034amr12275556pjg.16.1690897428113; Tue, 01 Aug 2023 06:43:48 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1690897428; cv=none; d=google.com; s=arc-20160816; b=jDMyMSWlC/M0Ujq14yK3ouiQfG5zKN4JQF/ONnUyjhZgfmAEx0d4NL7oGWToNChRTV EYEW3LEHU/1i9Bg4Jga7UwO/e1Oqfj7IJc8bE6ri2NsLGlqSxqhvYbDKukBNPrFiWJjZ q7uRvS0lA6wNmSPOArhJnWrxo7vyVVOP6ok9H7StIHCr77zsIy2pno6nxT7KcIIXr77J ueEAAWglhDrfxBtP9ZtOCjwEfotybHZE2NgOoAROOz65mNjHczeAyqSKbRC74wT3m/Lg KwC4RhiWQDDF5cPiWUG8xbtEPLH2LaOZtrYePj7VV/oXD1/BJe7KdTPgGoNGo57MK7FZ XAeQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=UBlaVyXcRzijB9wVsQtSzeKEzoa3c6OzUppL627hjBw=; fh=WqpbqIGd97GiVrS0HAirD6PimKjpSR4oUh5B/VTSqdw=; b=ErvvWb4O6MmFjgZV3m85woLQUbobhqc4KP3PoK42InKSzdJvTWyFNqXqoIidCEIAAD PakUHcDcc9XZx6IoGv3ihzCyGE+cg5pbQlXIUe+/Ij92RO6bk7Bvs8Sdl84+B5/f85ho bmaJy+PfD4xb4QwhLveQnY8j+7ULPW9bZ3ijB5nBeoKZ6ebDkdZa9rDTpforMX5xL+9q cOBOFoB8kaBFsnFecv09evZ8B2+PbUilPSMhLyrji2qHFZa84/IDaAVlI4QVsiNuZq2b Mfa7bQnqRoFhPl3AhvD1bejOS66imXTmGuBAQysLF6yYqsVlC9CcCz6H7bsEmdcusO8Y rEFA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20221208 header.b=Dp+olNtZ; 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=QUARANTINE dis=NONE) header.from=gmail.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id na3-20020a17090b4c0300b002682c370e32si9631779pjb.188.2023.08.01.06.43.34; Tue, 01 Aug 2023 06:43:48 -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=@gmail.com header.s=20221208 header.b=Dp+olNtZ; 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=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232806AbjHAMEC (ORCPT <rfc822;maxi.paulin@gmail.com> + 99 others); Tue, 1 Aug 2023 08:04:02 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50528 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234011AbjHAMDn (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Tue, 1 Aug 2023 08:03:43 -0400 Received: from mail-lj1-x22a.google.com (mail-lj1-x22a.google.com [IPv6:2a00:1450:4864:20::22a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 07D61173A; Tue, 1 Aug 2023 05:03:18 -0700 (PDT) Received: by mail-lj1-x22a.google.com with SMTP id 38308e7fff4ca-2b9b9f0387dso85806121fa.0; Tue, 01 Aug 2023 05:03:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1690891396; x=1691496196; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=UBlaVyXcRzijB9wVsQtSzeKEzoa3c6OzUppL627hjBw=; b=Dp+olNtZ83HKky4tQkPpItoL1j6tF9PvKT3p59x9ZfNBmmu0TfyG3TIuy6hK1f9Rha 3aiYIsQo7odhJYsCIJkONjN0YUBgZDzXi3LI82N8CaCwO+TGficuuo8GYjvRdf64T37n kMwJyJ2Y18lZybPYi/ouE09kSKf2l9iHNyFQvJS9JMhHuRuS74e5vF2Losvm75sd0nqz BTsoc5XFbbyRDKrFZSQU+2ouda7GeyKMwgXgGLd7AGqJIkPoFDIaTgIBsgWa5a5MNrXw UcQZ3feLzpdqSDo+2WrDVstNwC4P84Kx8A4dq7Pz7aqh6ZJmSSYauIV/y9+bYXbr+fxG lB+g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1690891396; x=1691496196; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=UBlaVyXcRzijB9wVsQtSzeKEzoa3c6OzUppL627hjBw=; b=jMjylBmoiCjF1zEhTjngoOsgPJ0lPhdhGglsbtjTtz2p01pxi+sBta0yCtgwno43AI MUXolZdap3HBVGbH5JhMQMNgJ0fVwIbpb84aQQ7BygJ+iAktJo/+iN2mSPesPhVSGDYm ZPSykGpBJs8YCx/VMeJnzVZYxtTiM2rmV4vJrrN+plqrfGe1AvUm+3TbEkL5XiwqAcni BqIwk0pkGNlpRigwbYqtga/RliO3bN4IES4S2luGKnqTcG9a0n5BB2HdGouuoDf66p2M I60BsMKKANXkdZETkWF9NS7Pw5Kw7cVHT6QY42PUtjqD3KMM2FpBq9sZeqtI7o1mKJcg 6gqA== X-Gm-Message-State: ABy/qLaO2Q9hAXyi1lTM6bKrKSzNQBw2ndk93/NbQ3W6Rhf/ndChSDwo LyfaCac8O7AzuRDHZB89s4U= X-Received: by 2002:a2e:3610:0:b0:2b5:974f:385 with SMTP id d16-20020a2e3610000000b002b5974f0385mr2369426lja.9.1690891395968; Tue, 01 Aug 2023 05:03:15 -0700 (PDT) Received: from fedora ([213.255.186.46]) by smtp.gmail.com with ESMTPSA id s23-20020a2e9c17000000b002b6fe751b6esm3048819lji.124.2023.08.01.05.03.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 01 Aug 2023 05:03:15 -0700 (PDT) Date: Tue, 1 Aug 2023 15:03:11 +0300 From: Matti Vaittinen <mazziesaccount@gmail.com> To: Matti Vaittinen <matti.vaittinen@fi.rohmeurope.com>, Matti Vaittinen <mazziesaccount@gmail.com> Cc: Jonathan =?iso-8859-1?q?Neusch=E4fer?= <j.neuschaefer@gmx.net>, Linus Walleij <linus.walleij@linaro.org>, openbmc@lists.ozlabs.org, linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v8 3/8] pinctrl: wpcm450: relax return value check for IRQ get Message-ID: <143e6d7a1d2b1fb692097f6c855f2553aca93589.1690890774.git.mazziesaccount@gmail.com> References: <cover.1690890774.git.mazziesaccount@gmail.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="zUmjDOxnj7pSg+hf" Content-Disposition: inline In-Reply-To: <cover.1690890774.git.mazziesaccount@gmail.com> X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,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: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1773034461954770866 X-GMAIL-MSGID: 1773034461954770866 |
Series |
fix fwnode_irq_get[_byname()] returnvalue
|
|
Commit Message
Matti Vaittinen
Aug. 1, 2023, 12:03 p.m. UTC
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. 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. 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. 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. Signed-off-by: Matti Vaittinen <mazziesaccount@gmail.com> Reviewed-by: Jonathan Neuschäfer <j.neuschaefer@gmx.net> Acked-by: Linus Walleij <linus.walleij@linaro.org> Reviewed-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> --- Revision history: v5 => : - No changes v4 => v5: Fix typo in subject "elax" => "relax" Please note, I took Linus' reply to v4 cover-letter as ack && added the tag. Please let me know if this was not Ok. The patch changing the fwnode_irq_get() got merged during 5.4: https://lore.kernel.org/all/fb7241d3-d1d1-1c37-919b-488d6d007484@gmail.com/ This is a clean-up as agreed. --- drivers/pinctrl/nuvoton/pinctrl-wpcm450.c | 2 -- 1 file changed, 2 deletions(-)
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_device *pdev, irq = fwnode_irq_get(child, i); if (irq < 0) break; - if (!irq) - continue; girq->parents[i] = irq; girq->num_parents++;