debugfs: add API to allow debugfs operations cancellation
authorJohannes Berg <johannes.berg@intel.com>
Fri, 24 Nov 2023 16:25:26 +0000 (17:25 +0100)
committerJohannes Berg <johannes.berg@intel.com>
Mon, 27 Nov 2023 10:24:55 +0000 (11:24 +0100)
commit8c88a474357ead632b07c70bf7f119ace8c3b39e
tree31c18cdb506b19cef567f05306f958c3d65c9dfa
parentf4acfcd4deb158b96595250cc332901b282d15b0
debugfs: add API to allow debugfs operations cancellation

In some cases there might be longer-running hardware accesses
in debugfs files, or attempts to acquire locks, and we want
to still be able to quickly remove the files.

Introduce a cancellations API to use inside the debugfs handler
functions to be able to cancel such operations on a per-file
basis.

Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
fs/debugfs/file.c
fs/debugfs/inode.c
fs/debugfs/internal.h
include/linux/debugfs.h