diff options
author | Jakub Kicinski <jakub.kicinski@netronome.com> | 2016-11-03 20:12:06 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2016-11-04 21:56:16 +0300 |
commit | 68f929ff2654bced015ccb9b5555667f46f88dfa (patch) | |
tree | d8b36e887a0e11a7b600f234eb83cf63e451ca50 /include/linux/debugfs.h | |
parent | 13df4c666c551bba97618d7e3908c2ecd03ceefb (diff) | |
download | linux-68f929ff2654bced015ccb9b5555667f46f88dfa.tar.xz |
debugfs: constify argument to debugfs_real_fops()
seq_file users can only access const version of file pointer,
because the ->file member of struct seq_operations is marked
as such. Make parameter to debugfs_real_fops() const.
CC: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
CC: Nicolai Stange <nicstange@gmail.com>
CC: Christian Lamparter <chunkeey@gmail.com>
CC: LKML <linux-kernel@vger.kernel.org>
Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/linux/debugfs.h')
-rw-r--r-- | include/linux/debugfs.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/include/linux/debugfs.h b/include/linux/debugfs.h index 4d3f0d1aec73..bf1907d96097 100644 --- a/include/linux/debugfs.h +++ b/include/linux/debugfs.h @@ -52,7 +52,8 @@ extern struct srcu_struct debugfs_srcu; * Must only be called under the protection established by * debugfs_use_file_start(). */ -static inline const struct file_operations *debugfs_real_fops(struct file *filp) +static inline const struct file_operations * +debugfs_real_fops(const struct file *filp) __must_hold(&debugfs_srcu) { /* |