linux/fs/debugfs
Nicolai Stange 4d45f7974c debugfs: unproxify files created through debugfs_create_bool()
Currently, the struct file_operations fops_bool associated with files
created through the debugfs_create_bool() helpers are not file
lifetime aware.

Thus, a lifetime managing proxy is created around fops_bool each time such
a file is opened which is an unnecessary waste of resources.

Implement file lifetime management for the fops_bool file_operations.
Namely, make debugfs_read_file_bool() and debugfs_write_file_bool() safe
against file removals by means of debugfs_use_file_start() and
debugfs_use_file_finish().

Make debugfs_create_bool() create its files in non-proxying operation mode
through debugfs_create_mode_unsafe().

Finally, purge debugfs_create_mode() as debugfs_create_bool() had been its
last user.

Signed-off-by: Nicolai Stange <nicstange@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-04-12 14:14:21 -07:00
..
file.c debugfs: unproxify files created through debugfs_create_bool() 2016-04-12 14:14:21 -07:00
inode.c debugfs: add support for self-protecting attribute file fops 2016-04-12 14:14:21 -07:00
internal.h debugfs: prevent access to removed files' private data 2016-04-12 14:14:21 -07:00
Makefile Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00