Received: by 2002:a6b:fb09:0:0:0:0:0 with SMTP id h9csp446156iog; Mon, 13 Jun 2022 06:08:46 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzixCuMzSrtUiZTR2/MhhLy28ldb+wqAnwceTEI5oDBEzZ6sUXeIKuD1Z040CePKeLMFhEt X-Received: by 2002:a17:906:9c82:b0:6e1:1d6c:914c with SMTP id fj2-20020a1709069c8200b006e11d6c914cmr52331403ejc.769.1655125606750; Mon, 13 Jun 2022 06:06:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1655125606; cv=none; d=google.com; s=arc-20160816; b=HRyaci13jAQ2nruRwB2mQnRFfIxFHXq+WBL4OMB0lCH19KH1loiqpCibcBNk7mJOHb H72IiCAamYy8f24SSSSzxS6WE6gsAecJE0HmKV3Uisen3ktbEHb183vuXSRfSbFeIa1J UOjuCm7LZR0p9vn2KgD21NqThLzBkR7iC2JGb8VMkH1SqQLuQjD1suOAwag2VRMIuQ6T pBpQjMcumU/19iCXROY4MBeoV0epN1k/+PTaBbGPuUa70xTSJGRfY3HgcKm1LQY3dumM EURh6tZ06J4+GQWehgoc1u3e1GEg53QXbts1lLIS9PGuMi4Cjdw91fCjvZSgIl1cb0KV 8oIA== 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=lDd3dVf+pSwK9qc/wMEOhR1CYIuvdOnUGjzmgDvPwQo=; b=uw7BEUSuCwUVllcd14erRWwFDROgeKF27udGHCaLZ5Pp9RJTnYtbjOrhuXT9N4c+V/ UZ8e1t71tFAv591bPYLmSBIe9kKYV08YgpKqQ7S4LfJ2YxjYq49oaaprmvNQRiHKPF2y OBie7zECBQ2XUpwfIGLJaCxxj12Vvq0xo0I9B6F2ahYY0GpKMSAPJSU9HZWcQLRShgJo ZkapWAKxCr4PI8KU293OsZYhT8xzNyu9BHF4tz0McnoH0j7/NIfO+6kHMbdyi4mjUeQr HlvZtAAKVsn4KblvG0Mmebn1gZGKi4+X+NSUnATNtScZOKKi//BM9eaVbIAmHmK7pqGF UxWw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=b04Qx3YK; 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 ib1-20020a1709072c6100b00711cdee84a5si6820863ejc.570.2022.06.13.06.06.09; Mon, 13 Jun 2022 06:06:46 -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=b04Qx3YK; 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 S242797AbiFMKVf (ORCPT + 99 others); Mon, 13 Jun 2022 06:21:35 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60016 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S243280AbiFMKTI (ORCPT ); Mon, 13 Jun 2022 06:19:08 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 58D2920F73; Mon, 13 Jun 2022 03:16:58 -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 A5CACB80E5C; Mon, 13 Jun 2022 10:16:56 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 1A1C8C34114; Mon, 13 Jun 2022 10:16:54 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1655115415; bh=z9ZVZvLTkZIpAPfLBywKcJvGM8+KiNdtryLagDHFcN8=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=b04Qx3YKVEYkFJY7v8UfG7DUjREyO6dQHtEZn78lk5n9Eirgk4PrHZwAr3FHVWxfr SpdH/uYG9pEujLshdGGs97swtisCcJmEqj3/yI7dzJTf5TGoF+mJ6OuYf6lxJSit25 ZK8w/8LzfrBUq2HIVpPviH0952p6UaOYuSrm4x3E= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Miaoqian Lin , Bjorn Andersson , Sasha Levin Subject: [PATCH 4.9 064/167] soc: qcom: smsm: Fix missing of_node_put() in smsm_parse_ipc Date: Mon, 13 Jun 2022 12:08:58 +0200 Message-Id: <20220613094855.940213495@linuxfoundation.org> X-Mailer: git-send-email 2.36.1 In-Reply-To: <20220613094840.720778945@linuxfoundation.org> References: <20220613094840.720778945@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: Miaoqian Lin [ Upstream commit aad66a3c78da668f4506356c2fdb70b7a19ecc76 ] The device_node pointer is returned by of_parse_phandle() with refcount incremented. We should use of_node_put() on it when done. Fixes: c97c4090ff72 ("soc: qcom: smsm: Add driver for Qualcomm SMSM") Signed-off-by: Miaoqian Lin Signed-off-by: Bjorn Andersson Link: https://lore.kernel.org/r/20220308073648.24634-1-linmq006@gmail.com Signed-off-by: Sasha Levin --- drivers/soc/qcom/smsm.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/soc/qcom/smsm.c b/drivers/soc/qcom/smsm.c index 783cb3364599..01bc8528f24d 100644 --- a/drivers/soc/qcom/smsm.c +++ b/drivers/soc/qcom/smsm.c @@ -367,6 +367,7 @@ static int smsm_parse_ipc(struct qcom_smsm *smsm, unsigned host_id) return 0; host->ipc_regmap = syscon_node_to_regmap(syscon); + of_node_put(syscon); if (IS_ERR(host->ipc_regmap)) return PTR_ERR(host->ipc_regmap); -- 2.35.1