Patch "drm/amd/display: fix memory leak when using debugfs_lookup()" has been added to the 5.19-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    drm/amd/display: fix memory leak when using debugfs_lookup()

to the 5.19-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     drm-amd-display-fix-memory-leak-when-using-debugfs_lookup.patch
and it can be found in the queue-5.19 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.


>From cbfac7fa491651c57926c99edeb7495c6c1aeac2 Mon Sep 17 00:00:00 2001
From: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx>
Date: Fri, 2 Sep 2022 15:01:05 +0200
Subject: drm/amd/display: fix memory leak when using debugfs_lookup()
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

From: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx>

commit cbfac7fa491651c57926c99edeb7495c6c1aeac2 upstream.

When calling debugfs_lookup() the result must have dput() called on it,
otherwise the memory will leak over time.  Fix this up by properly
calling dput().

Cc: Harry Wentland <harry.wentland@xxxxxxx>
Cc: Leo Li <sunpeng.li@xxxxxxx>
Cc: Rodrigo Siqueira <Rodrigo.Siqueira@xxxxxxx>
Cc: Alex Deucher <alexander.deucher@xxxxxxx>
Cc: "Christian König" <christian.koenig@xxxxxxx>
Cc: "Pan, Xinhui" <Xinhui.Pan@xxxxxxx>
Cc: David Airlie <airlied@xxxxxxxx>
Cc: Daniel Vetter <daniel@xxxxxxxx>
Cc: Wayne Lin <Wayne.Lin@xxxxxxx>
Cc: hersen wu <hersenxs.wu@xxxxxxx>
Cc: Wenjing Liu <wenjing.liu@xxxxxxx>
Cc: Patrik Jakobsson <patrik.r.jakobsson@xxxxxxxxx>
Cc: Thelford Williams <tdwilliamsiv@xxxxxxxxx>
Cc: Fangzhi Zuo <Jerry.Zuo@xxxxxxx>
Cc: Yongzhi Liu <lyz_cs@xxxxxxxxxx>
Cc: Mikita Lipski <mikita.lipski@xxxxxxx>
Cc: Jiapeng Chong <jiapeng.chong@xxxxxxxxxxxxxxxxx>
Cc: Bhanuprakash Modem <bhanuprakash.modem@xxxxxxxxx>
Cc: Sean Paul <seanpaul@xxxxxxxxxxxx>
Cc: amd-gfx@xxxxxxxxxxxxxxxxxxxxx
Cc: dri-devel@xxxxxxxxxxxxxxxxxxxxx
Cc: stable@xxxxxxxxxxxxxxx
Reviewed-by: Rodrigo Siqueira <Rodrigo.Siqueira@xxxxxxx>
Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx>
Signed-off-by: Rodrigo Siqueira <Rodrigo.Siqueira@xxxxxxx>
Signed-off-by: Alex Deucher <alexander.deucher@xxxxxxx>
Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx>
---
 drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_debugfs.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_debugfs.c
+++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_debugfs.c
@@ -3188,7 +3188,7 @@ void crtc_debugfs_init(struct drm_crtc *
 				   &crc_win_y_end_fops);
 	debugfs_create_file_unsafe("crc_win_update", 0644, dir, crtc,
 				   &crc_win_update_fops);
-
+	dput(dir);
 }
 #endif
 /*


Patches currently in stable-queue which might be from gregkh@xxxxxxxxxxxxxxxxxxx are

queue-5.19/alsa-aloop-fix-random-zeros-in-capture-data-when-using-jiffies-timer.patch
queue-5.19/driver-core-fix-driver_set_override-issue-with-empty-strings.patch
queue-5.19/alsa-usb-audio-split-endpoint-setups-for-hw_params-and-prepare.patch
queue-5.19/soc-fsl-select-fsl_guts-driver-for-dpio.patch
queue-5.19/fs-only-do-a-memory-barrier-for-the-first-set_buffer_uptodate.patch
queue-5.19/tracefs-only-clobber-mode-uid-gid-on-remount-if-asked.patch
queue-5.19/efi-capsule-loader-fix-use-after-free-in-efi_capsule_write.patch
queue-5.19/alsa-emu10k1-fix-out-of-bounds-access-in-snd_emu10k1_pcm_channel_alloc.patch
queue-5.19/net-mvpp2-debugfs-fix-memory-leak-when-using-debugfs_lookup.patch
queue-5.19/efi-libstub-disable-struct-randomization.patch
queue-5.19/revert-mm-kmemleak-take-a-full-lowmem-check-in-kmemleak_-_phys.patch
queue-5.19/sched-debug-fix-dentry-leak-in-update_sched_domain_debugfs.patch
queue-5.19/alsa-usb-audio-fix-an-out-of-bounds-bug-in-__snd_usb_parse_audio_interface.patch
queue-5.19/kprobes-prohibit-probes-in-gate-area.patch
queue-5.19/tracing-hold-caller_addr-to-hardirq_-enable-disable-_ip.patch
queue-5.19/wifi-iwlegacy-4965-corrected-fix-for-potential-off-by-one-overflow-in-il4965_rs_fill_link_cmd.patch
queue-5.19/alsa-pcm-oss-fix-race-at-sndctl_dsp_sync.patch
queue-5.19/perf-risc-v-fix-access-beyond-allocated-array.patch
queue-5.19/debugfs-add-debugfs_lookup_and_remove.patch
queue-5.19/wifi-mt76-mt7921e-fix-crash-in-chip-reset-fail.patch
queue-5.19/btrfs-zoned-fix-api-misuse-of-zone-finish-waiting.patch
queue-5.19/vfio-type1-unpin-zero-pages.patch
queue-5.19/tracing-fix-to-check-event_mutex-is-held-while-accessing-trigger-list.patch
queue-5.19/alsa-hda-once-again-fix-regression-of-page-allocations-with-iommu.patch
queue-5.19/btrfs-zoned-set-pseudo-max-append-zone-limit-in-zone-emulation-mode.patch
queue-5.19/drm-amd-display-fix-memory-leak-when-using-debugfs_lookup.patch
queue-5.19/alsa-usb-audio-clear-fixed-clock-rate-at-closing-ep.patch



[Index of Archives]     [Linux DRI Users]     [Linux Intel Graphics]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux