From: Miaoqian Lin <linmq006@xxxxxxxxx> commit 4b2dc39ca024990abe36ad5d145c4fe0c06afd34 upstream. The of_find_compatible_node() function returns a node pointer with refcount incremented, We should use of_node_put() on it when done Add the missing of_node_put() to release the refcount. Fixes: 86559400b3ef ("rtc: gamecube: Add a RTC driver for the GameCube, Wii and Wii U") Signed-off-by: Miaoqian Lin <linmq006@xxxxxxxxx> Signed-off-by: Alexandre Belloni <alexandre.belloni@xxxxxxxxxxx> Link: https://lore.kernel.org/r/20220309092225.6930-1-linmq006@xxxxxxxxx Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx> --- drivers/rtc/rtc-gamecube.c | 1 + 1 file changed, 1 insertion(+) --- a/drivers/rtc/rtc-gamecube.c +++ b/drivers/rtc/rtc-gamecube.c @@ -235,6 +235,7 @@ static int gamecube_rtc_read_offset_from } ret = of_address_to_resource(np, 0, &res); + of_node_put(np); if (ret) { pr_err("no io memory range found\n"); return -1; Patches currently in stable-queue which might be from linmq006@xxxxxxxxx are queue-5.17/coresight-syscfg-fix-memleak-on-registration-failure-in-cscfg_create_device.patch queue-5.17/asoc-rk817-fix-missing-clk_disable_unprepare-in-rk81.patch queue-5.17/remoteproc-qcom_q6v5_mss-fix-some-leaks-in-q6v5_allo.patch queue-5.17/asoc-msm8916-wcd-digital-fix-missing-clk_disable_unp.patch queue-5.17/remoteproc-qcom-fix-missing-of_node_put-in-adsp_allo.patch queue-5.17/rtc-gamecube-fix-refcount-leak-in-gamecube_rtc_read_offset_from_sram.patch queue-5.17/asoc-mediatek-fix-error-handling-in-mt8183_da7219_ma.patch queue-5.17/drm-tegra-fix-reference-leak-in-tegra_dsi_ganged_pro.patch queue-5.17/asoc-msm8916-wcd-analog-fix-error-handling-in-pm8916.patch queue-5.17/asoc-rockchip-i2s-fix-missing-clk_disable_unprepare-.patch queue-5.17/power-reset-gemini-poweroff-fix-irq-check-in-gemini_.patch queue-5.17/clk-tegra-tegra124-emc-fix-missing-put_device-call-i.patch queue-5.17/hwrng-nomadik-change-clk_disable-to-clk_disable_unpr.patch queue-5.17/mfd-asic3-add-missing-iounmap-on-error-asic3_mfd_pro.patch queue-5.17/asoc-atmel-add-missing-of_node_put-in-at91sam9g20ek_.patch queue-5.17/soc-ti-wkup_m3_ipc-fix-irq-check-in-wkup_m3_ipc_prob.patch queue-5.17/drm-bridge-add-missing-pm_runtime_disable-in-__dw_mi.patch queue-5.17/mips-cdmm-fix-refcount-leak-in-mips_cdmm_phys_base.patch queue-5.17/asoc-mediatek-mt8195-fix-error-handling-in-mt8195_mt.patch queue-5.17/pinctrl-rockchip-add-missing-of_node_put-in-rockchip.patch queue-5.17/asoc-atmel-fix-error-handling-in-snd_proto_probe.patch queue-5.17/drm-bridge-nwl-dsi-fix-pm-disable-depth-imbalance-in.patch queue-5.17/soc-qcom-aoss-fix-missing-put_device-call-in-qmp_get.patch queue-5.17/firmware-sysfb-fix-platform-device-leak-in-error-path.patch queue-5.17/spi-tegra114-add-missing-irq-check-in-tegra_spi_prob.patch queue-5.17/ath10k-fix-error-handling-in-ath10k_setup_msa_resour.patch queue-5.17/asoc-mediatek-mt8192-mt6359-fix-error-handling-in-mt.patch queue-5.17/pinctrl-nomadik-add-missing-of_node_put-in-nmk_pinct.patch queue-5.17/asoc-sof-add-missing-of_node_put-in-imx8m_probe.patch queue-5.17/remoteproc-qcom_wcnss-add-missing-of_node_put-in-wcn.patch queue-5.17/asoc-mxs-fix-error-handling-in-mxs_sgtl5000_probe.patch queue-5.17/pinctrl-mediatek-fix-missing-of_node_put-in-mtk_pctr.patch queue-5.17/drm-bridge-fix-free-wrong-object-in-sii8620_init_rcp.patch queue-5.17/soc-qcom-ocmem-fix-missing-put_device-call-in-of_get.patch queue-5.17/video-fbdev-omapfb-add-missing-of_node_put-in-dvic_p.patch queue-5.17/media-coda-fix-missing-put_device-call-in-coda_get_v.patch queue-5.17/asoc-codecs-wcd934x-add-missing-of_node_put-in-wcd93.patch queue-5.17/spi-tegra210-quad-fix-missin-irq-check-in-tegra_qspi.patch queue-5.17/power-supply-ab8500-fix-memory-leak-in-ab8500_fg_sys.patch queue-5.17/asoc-atmel-fix-error-handling-in-sam9x5_wm8731_drive.patch