]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commit
debugfs: Document that debugfs_create functions need not be error checked
authorDouglas Anderson <dianders@chromium.org>
Tue, 22 Feb 2022 23:46:00 +0000 (15:46 -0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 25 Feb 2022 10:56:13 +0000 (11:56 +0100)
commit8bcbde2bb1374112264826aa26ff959149f318e4
tree43dd3d4749ece94dfaa7b02234d1ed1d5a415097
parentf2eb478f2f322217aa642e11c1cc011f99c797e6
debugfs: Document that debugfs_create functions need not be error checked

As talked about in commit b792e64021ec ("drm: no need to check return
value of debugfs_create functions"), in many cases we can get away
with totally skipping checking the errors of debugfs functions. Let's
document that so people don't add new code that needlessly checks
these errors.

Probably this note could be added to a boatload of functions, but
that's a lot of duplication.  Let's just add it to the two most
frequent ones and hope people will get the idea.

Suggested-by: Javier Martinez Canillas <javierm@redhat.com>
Reviewed-by: Javier Martinez Canillas <javierm@redhat.com>
Signed-off-by: Douglas Anderson <dianders@chromium.org>
Link: https://lore.kernel.org/r/20220222154555.1.I26d364db7a007f8995e8f0dac978673bc8e9f5e2@changeid
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
fs/debugfs/inode.c