From patchwork Tue Dec 6 17:10:48 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dario Binacchi X-Patchwork-Id: 13066176 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 4C80AC352A1 for ; Tue, 6 Dec 2022 17:13:10 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=JJZk+BZqZ+Am1BVrBALPINDUJsTHiunNeuJOLqcUFoM=; b=sKI9SIMwZfu4UM aEE93aGHRUpSVtSBm+pmx5/LHOnQFPGI5p916lN4b0e5e97PMGliMyrX3KDYnifeZZCPPvYZMXyff 3WkalP9ZL5mUKSoG47mWKhuQZcZ1CxBECY0vOUoBsfMHYrFsb7PJiI9+wwaMk8fSmwuIkO/q7FcXH VqKf8Y0RosFdCmDPN/NmUy+KoHLMfNT2AZ4Cuig/AKq2wwSLXko5Bh9QvBKkzo0dPOWNYe5BPWBDF kCSAw+66XwUSdVh8IKUsWtPwz5Zg7Xh5+oEhTOGxfU8sj0XntI3JzJIPhjWQwS3gfVts0tWhzglhR iHbuVj0401oEwboQkupw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1p2bUB-00Fhoi-EG; Tue, 06 Dec 2022 17:12:03 +0000 Received: from mail-wr1-x42a.google.com ([2a00:1450:4864:20::42a]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1p2bTP-00FhDb-DB for linux-arm-kernel@lists.infradead.org; Tue, 06 Dec 2022 17:11:16 +0000 Received: by mail-wr1-x42a.google.com with SMTP id y16so24445907wrm.2 for ; Tue, 06 Dec 2022 09:11:13 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amarulasolutions.com; s=google; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=JTKzSC4xiELtOhvYcPg625CE+pmvLexXVke2DqyU21Q=; b=jBQD+O7XNs5SbP+46Ou8Fyj8CECu5cE2sdTpHJmBujn+wNPZOhaoLoKc0GCA9Gwq+G 1W76vEZ8MT1Ki6hKHJmSamfFN23/9WUPMg3FLo5RE+CBZw8/MKoEOrQcCBc6raTMcr6m awNNnOPDL1KREISMcuOhPUhoWkJRWzRXpKnqw= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=JTKzSC4xiELtOhvYcPg625CE+pmvLexXVke2DqyU21Q=; b=OcVn5U0YjxzfHmjvEpzfWRuyKLMmyZx3jpwYT/bMq3GaqW6TXE3GEfsfeijz9AL7HG NO2BtJZWfqbEzOinlALC/f3BY5mDKcV8kIlU9YwVgd0TaVR7UKA1qzQOdrqoC6HL5Dz2 vjTR4AolvQW694gKxDxlT90NTgDAiOjdIyOxWjRJQO6ZnHGHjLK9FVAZ1w6WC6NWdEyC kEObDtiivpyIruFFsHp3C5PnweBoyukUjHK6W9IN22vzwNpVYpAYSVquBFs3UCuTnuM5 hB1/ZNe4GYO6wbOYgvQrMHuiACJGIY9HNkGfQqvoIqiDAPUE7PyYnAHkT08ANuoTConI DoYQ== X-Gm-Message-State: ANoB5plnnKyJs2guheRCsseHmjD92iQkxvihgumsVzxve0XUFmyEOU2L L4Jg/IXltGKb4uO9on5JX025kw== X-Google-Smtp-Source: AA0mqf46qOghPsTK5SHdLa1G/B2hktQOKTAgXMfUJJ8bJ8Lem5+VEr3rDWh1zK2Rir3AyuSd6Vrewg== X-Received: by 2002:adf:f54e:0:b0:242:1534:7b57 with SMTP id j14-20020adff54e000000b0024215347b57mr26622429wrp.404.1670346671934; Tue, 06 Dec 2022 09:11:11 -0800 (PST) Received: from dario-ThinkPad-T14s-Gen-2i.pdxnet.pdxeng.ch (host-82-54-95-136.retail.telecomitalia.it. [82.54.95.136]) by smtp.gmail.com with ESMTPSA id k10-20020a056000004a00b002365730eae8sm17298534wrx.55.2022.12.06.09.11.10 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 06 Dec 2022 09:11:11 -0800 (PST) From: Dario Binacchi To: linux-kernel@vger.kernel.org Cc: Amarula patchwork , Dario Binacchi , Arnd Bergmann , Fabio Estevam , NXP Linux Team , Pengutronix Kernel Team , Russell King , Sascha Hauer , Shawn Guo , linux-arm-kernel@lists.infradead.org Subject: [PATCH 4/5] ARM: imx35: add missing of_node_put() Date: Tue, 6 Dec 2022 18:10:48 +0100 Message-Id: <20221206171049.3316611-5-dario.binacchi@amarulasolutions.com> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20221206171049.3316611-1-dario.binacchi@amarulasolutions.com> References: <20221206171049.3316611-1-dario.binacchi@amarulasolutions.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20221206_091115_485660_DC738EE8 X-CRM114-Status: UNSURE ( 9.88 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org In mx35_read_cpu_rev(), of_find_compatible_node() returns a node pointer with refcount incremented. Use of_node_put() on it when done. Fixes: f68ea682d1da7 ("ARM: imx35: Retrieve the IIM base address from devicetree") Signed-off-by: Dario Binacchi --- arch/arm/mach-imx/cpu-imx35.c | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/arm/mach-imx/cpu-imx35.c b/arch/arm/mach-imx/cpu-imx35.c index 80e7d8ab9f1b..1fe75b39c2d9 100644 --- a/arch/arm/mach-imx/cpu-imx35.c +++ b/arch/arm/mach-imx/cpu-imx35.c @@ -21,6 +21,7 @@ static int mx35_read_cpu_rev(void) np = of_find_compatible_node(NULL, NULL, "fsl,imx35-iim"); iim_base = of_iomap(np, 0); + of_node_put(np); BUG_ON(!iim_base); rev = imx_readl(iim_base + MXC_IIMSREV);