linux/drivers/firmware
Johan Hovold 796594990b firmware: meson_sm: fix device leak at probe
commit 8ece3173f8 upstream.

Make sure to drop the reference to the secure monitor device taken by
of_find_device_by_node() when looking up its driver data on behalf of
other drivers (e.g. during probe).

Note that holding a reference to the platform device does not prevent
its driver data from going away so there is no point in keeping the
reference after the helper returns.

Fixes: 8cde3c2153 ("firmware: meson_sm: Rework driver as a proper platform driver")
Cc: stable@vger.kernel.org	# 5.5
Cc: Carlo Caione <ccaione@baylibre.com>
Signed-off-by: Johan Hovold <johan@kernel.org>
Acked-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
Link: https://lore.kernel.org/r/20250725074019.8765-1-johan@kernel.org
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
History 2025-10-19 16:23:11 +02:00
..
arm_ffa firmware: arm_ffa: Set dma_mask for ffa devices 2025-06-04 14:40:10 +02:00
arm_scmi firmware: arm_scmi: Ensure that the message-id supports fastchannel 2025-07-06 10:58:04 +02:00
broadcom firmware: tee_bnxt: Use UUID API for exporting the UUID 2022-05-05 18:14:29 -07:00
cirrus firmware: cs_dsp: Don't allow writes to read-only controls 2024-09-12 11:10:22 +02:00
efi efi/libstub: Describe missing 'out' parameter in efi_load_initrd 2025-06-27 11:07:10 +01:00
google firmware: google: Unregister driver_info on failure 2024-12-14 19:53:16 +01:00
imx firmware: imx-scu: fix OF node leak in .probe() 2025-03-28 21:58:59 +01:00
meson firmware: meson_sm: fix device leak at probe 2025-10-19 16:23:11 +02:00
psci firmware: psci: Fix refcount leak in psci_dt_init 2025-06-27 11:07:08 +01:00
smccc arm64: smccc: Remove broken support for SMCCCv1.3 SVE discard hint 2024-12-14 19:54:53 +01:00
tegra firmware: tegra: bpmp: Drop unused mbox_client_to_bpmp() 2024-10-17 15:21:51 +02:00
xilinx firmware: xilinx: don't make a sleepable memory allocation from an atomic context 2023-03-22 13:33:56 +01:00
arm_scpi.c firmware: arm_scpi: Check the DVFS OPP count returned by the firmware 2024-12-14 19:53:23 +01:00
arm_sdei.c firmware: SDEI: Allow sdei initialization without ACPI_APEI_GHES 2025-06-27 11:07:08 +01:00
dmi-id.c firmware: dmi-id: add a release callback function 2024-06-12 11:03:34 +02:00
dmi-sysfs.c firmware: dmi-sysfs: Fix null-ptr-deref in dmi_sysfs_register_handle 2023-03-10 09:33:34 +01:00
dmi_scan.c firmware: dmi: Stop decoding on broken entry 2024-07-11 12:47:07 +02:00
edd.c edd: simplify the check of 'attr->test' in edd_populate_dir() 2022-05-19 18:57:04 +02:00
iscsi_ibft.c iscsi_ibft: Fix UBSAN shift-out-of-bounds warning in ibft_attr_show_nic() 2025-03-28 21:58:50 +01:00
iscsi_ibft_find.c iscsi_ibft: fix warning in reserve_ibft_region() 2021-08-05 19:47:57 -04:00
Kconfig firmware: SDEI: Allow sdei initialization without ACPI_APEI_GHES 2025-06-27 11:07:08 +01:00
Makefile Follow-up tweaks for the EFI changes in v5.19 2022-06-03 13:39:30 -07:00
memmap.c firmware: memmap: use default_groups in kobj_type 2022-01-05 19:17:29 +01:00
mtk-adsp-ipc.c firmware: mediatek: Use meaningful names for mbox 2022-06-22 13:39:30 +01:00
pcdp.c efi/ia64: Move HCDP and MPS table handling into IA64 arch code 2020-02-23 21:59:42 +01:00
pcdp.h firmware: pcdp: Replace zero-length array with flexible-array 2020-06-15 23:08:32 -05:00
qcom_scm-legacy.c firmware: qcom_scm-legacy: correct kerneldoc 2022-06-25 22:04:31 -05:00
qcom_scm-smc.c firmware: qcom_scm: Reduce locking section for __get_convention() 2021-04-06 21:25:23 -05:00
qcom_scm.c firmware: qcom_scm: disable clocks if qcom_scm_bw_enable() fails 2024-06-21 14:35:40 +02:00
qcom_scm.h firmware: qcom: scm: remove unused __qcom_scm_init declaration 2022-09-13 15:14:54 -05:00
qemu_fw_cfg.c firmware: qemu_fw_cfg: remove sysfs entries explicitly 2022-01-14 18:50:52 -05:00
raspberrypi.c firmware: raspberrypi: Use correct device for DMA mappings 2024-06-12 11:03:04 +02:00
scpi_pm_domain.c firmware: arm_scpi: Fix string overflow in SCPI genpd driver 2021-12-13 15:17:37 +01:00
stratix10-rsu.c firmware: stratix10-rsu: extend RSU driver to get DCMF status 2022-07-14 16:55:09 +02:00
stratix10-svc.c firmware: stratix10-svc: Fix an NULL vs IS_ERR() bug in probe 2023-09-06 21:27:02 +01:00
sysfb.c efi: sysfb_efi: Fix DMI quirks not working for simpledrm 2023-03-30 12:49:22 +02:00
sysfb_simplefb.c efi: sysfb_efi: Fix DMI quirks not working for simpledrm 2023-03-30 12:49:22 +02:00
ti_sci.c firmware: ti_sci: Fix an off-by-one in ti_sci_debugfs_create() 2024-01-25 15:27:24 -08:00
ti_sci.h firmware: ti_sci: rm: Add new ops for ring configuration 2020-11-01 19:38:02 -08:00
trusted_foundations.c firmware: tf: Different way of L2 cache enabling after LP2 suspend 2020-05-06 18:27:26 +02:00
turris-mox-rwtm.c firmware: turris-mox-rwtm: Initialize completion before mailbox 2024-08-03 08:49:03 +02:00