Skip to content

Commit 0b3d494

Browse files
Yang Yingliangmlankhorst
authored andcommitted
drm/nouveau/kms/nv50-: fix file release memory leak
When using single_open() for opening, single_release() should be called, otherwise the 'op' allocated in single_open() will be leaked. Fixes: 12885ec ("drm/nouveau/kms/nvd9-: Add CRC support") Reported-by: Hulk Robot <[email protected]> Signed-off-by: Yang Yingliang <[email protected]> Reviewed-by: Karol Herbst <[email protected]> Signed-off-by: Karol Herbst <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected] Signed-off-by: Maarten Lankhorst <[email protected]>
1 parent bcf34aa commit 0b3d494

File tree

1 file changed

+1
-0
lines changed
  • drivers/gpu/drm/nouveau/dispnv50

1 file changed

+1
-0
lines changed

drivers/gpu/drm/nouveau/dispnv50/crc.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -704,6 +704,7 @@ static const struct file_operations nv50_crc_flip_threshold_fops = {
704704
.open = nv50_crc_debugfs_flip_threshold_open,
705705
.read = seq_read,
706706
.write = nv50_crc_debugfs_flip_threshold_set,
707+
.release = single_release,
707708
};
708709

709710
int nv50_head_crc_late_register(struct nv50_head *head)

0 commit comments

Comments
 (0)