aboutsummaryrefslogtreecommitdiffstats
path: root/fs/resctrl/pseudo_lock.c
diff options
context:
space:
mode:
authorAl Viro <[email protected]>2025-07-02 21:16:50 +0000
committerGreg Kroah-Hartman <[email protected]>2025-07-09 11:30:28 +0000
commit460e36ee6f84c2df4d194ee788e3ca116e8c563b (patch)
tree73ff925fad37dbbc32a1827e14a6849c3713b823 /fs/resctrl/pseudo_lock.c
parentregmap: get rid of redundant debugfs_file_{get,put}() (diff)
downloadkernel-460e36ee6f84c2df4d194ee788e3ca116e8c563b.tar.gz
kernel-460e36ee6f84c2df4d194ee788e3ca116e8c563b.zip
resctrl: get rid of pointless debugfs_file_{get,put}()
->write() of file_operations that gets used only via debugfs_create_file() is called only under debugfs_file_get() Signed-off-by: Al Viro <[email protected]> Acked-by: Reinette Chatre <[email protected]> Link: https://lore.kernel.org/r/20250702211650.GD3406663@ZenIV Signed-off-by: Greg Kroah-Hartman <[email protected]>
Diffstat (limited to 'fs/resctrl/pseudo_lock.c')
-rw-r--r--fs/resctrl/pseudo_lock.c4
1 files changed, 0 insertions, 4 deletions
diff --git a/fs/resctrl/pseudo_lock.c b/fs/resctrl/pseudo_lock.c
index ccc2f9213b4b..87bbc2605de1 100644
--- a/fs/resctrl/pseudo_lock.c
+++ b/fs/resctrl/pseudo_lock.c
@@ -764,13 +764,9 @@ static ssize_t pseudo_lock_measure_trigger(struct file *file,
if (ret == 0) {
if (sel != 1 && sel != 2 && sel != 3)
return -EINVAL;
- ret = debugfs_file_get(file->f_path.dentry);
- if (ret)
- return ret;
ret = pseudo_lock_measure_cycles(rdtgrp, sel);
if (ret == 0)
ret = count;
- debugfs_file_put(file->f_path.dentry);
}
return ret;