Received: by 2002:a6b:fb09:0:0:0:0:0 with SMTP id h9csp661968iog; Mon, 13 Jun 2022 10:06:07 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyhsQaw6wW4EnXqCBOzyOF6HL1fCFZKAG4Y16LETcxtNv5tx6Xh/XUui4tms785w9YhPEHx X-Received: by 2002:a17:902:e54a:b0:166:50b6:a08b with SMTP id n10-20020a170902e54a00b0016650b6a08bmr39136plf.90.1655139966765; Mon, 13 Jun 2022 10:06:06 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1655139966; cv=none; d=google.com; s=arc-20160816; b=fDANRj09h4q5/1nAfylgq6XD3FWpxmXFf2wGrr1O7En7GFjPFFIqUKlCJve171v4u9 Z4/wFWU0yJwa6EYG8f57+0+zTj4hBf/weICatuYbpWbXIw0P5qCpZQWJ6UPCN0WkKoBr +MFoEQEiQPmxvHW+CNWAH+AtMD1Z1H6hiEwXlTbUf5BhE6RZKMOYKOH6ZP3XQ2oyfjCU 0VzumnTHlEHCxyD2zG99FNXBjezViJKsdIHeVDWH8wX5nCqZ/coWKrhJA9hFGDA3943P 9E9Jjbc5t4DFzQecHLGzcioaWEyyxeor8EDkjqHrCy9P4dFYwjoOsyoCitYrhg5dtbBI So2w== 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 :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=fYUHKo50EdREW3akxK4K2yVTlkfzfuiGZHHUXF089q4=; b=zhbYIbGJZC8LN7HRl5EmMaIo6YSeIwP9vFq5b+UDDfVIaQMTSLKcjESfk87puFrzNq ArSNKq5xMcgai1g15MF9L8cqJ3HaUD+WaAeKgmcGjtA8dxzuEkd6eaF0CeLm9yCKNxvK 2Zga5Wn1Fb0Ugvq5PO/+DoGXUmcsPWbVs6nzrEYmOI0mc6v6ACdKhvhP7CZHLv5IERFc LH7P+e75Au7L9AYSr14GFc+vDXWUDm6gthZ3jyCvDiHhOLPXix9mnAad3ivFHdX9KylZ FWLx+Aa7uYrC4RPigVG+RP6FGT6FFZZ6bTC0pCYytLsm5oYrdyYfA8+u5eVxhNnGjFw9 za9A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=MSi6TUSD; 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=linuxfoundation.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id 41-20020a17090a0fac00b001e31fad7db1si9663355pjz.24.2022.06.13.10.05.53; Mon, 13 Jun 2022 10:06:06 -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=@linuxfoundation.org header.s=korg header.b=MSi6TUSD; 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=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1377588AbiFMNdh (ORCPT + 99 others); Mon, 13 Jun 2022 09:33:37 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47498 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1378038AbiFMNas (ORCPT ); Mon, 13 Jun 2022 09:30:48 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [IPv6:2604:1380:4601:e00::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 87F1B6EC54; Mon, 13 Jun 2022 04:25:26 -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 ams.source.kernel.org (Postfix) with ESMTPS id B2BDFB80D31; Mon, 13 Jun 2022 11:25:24 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 12966C3411E; Mon, 13 Jun 2022 11:25:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1655119523; bh=72tc4bIMi/WzF0JQ9Pd7txZATTkGwv0vXHYtqVJ7lA4=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=MSi6TUSDh8YzIMAvGZYWTEjREUPzNdpocj/YcXvdyobejcbCfT/upbH7MJ4At+cw2 M0dbiX3y4X0uU5HE2fcehCHlLPOArJH+aLFgjsHx/LUzBswlaQH7DMLTn2xcp8ECq9 HB+2mRGYTH4kICLOwQ4iN4JwUK7TvgMO0BTzc6ts= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Krzysztof Kozlowski , Bjorn Andersson , Sasha Levin Subject: [PATCH 5.18 024/339] rpmsg: qcom_smd: Fix irq_of_parse_and_map() return value Date: Mon, 13 Jun 2022 12:07:29 +0200 Message-Id: <20220613094927.242788800@linuxfoundation.org> X-Mailer: git-send-email 2.36.1 In-Reply-To: <20220613094926.497929857@linuxfoundation.org> References: <20220613094926.497929857@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-8.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, 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 From: Krzysztof Kozlowski [ Upstream commit 1a358d35066487d228a68303d808bc4721c6b1b9 ] The irq_of_parse_and_map() returns 0 on failure, not a negative ERRNO. Fixes: 53e2822e56c7 ("rpmsg: Introduce Qualcomm SMD backend") Signed-off-by: Krzysztof Kozlowski Signed-off-by: Bjorn Andersson Link: https://lore.kernel.org/r/20220422105326.78713-1-krzysztof.kozlowski@linaro.org Signed-off-by: Sasha Levin --- drivers/rpmsg/qcom_smd.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/rpmsg/qcom_smd.c b/drivers/rpmsg/qcom_smd.c index 764c980507be..6ccfa12abd10 100644 --- a/drivers/rpmsg/qcom_smd.c +++ b/drivers/rpmsg/qcom_smd.c @@ -1407,7 +1407,7 @@ static int qcom_smd_parse_edge(struct device *dev, edge->name = node->name; irq = irq_of_parse_and_map(node, 0); - if (irq < 0) { + if (!irq) { dev_err(dev, "required smd interrupt missing\n"); ret = irq; goto put_node; -- 2.35.1