drm: convert .debugfs_init() hook to return void.
As a result of commit 987d65d013
(drm: debugfs: make
drm_debugfs_create_files() never fail) and changes to various debugfs
functions in drm/core and across various drivers, there is no need for
the drm_driver.debugfs_init() hook to have a return value. Therefore,
declare it as void.
This also includes refactoring all users of the .debugfs_init() hook to
return void across the subsystem.
v2: include changes to the hook and drivers that use it in one patch to
prevent driver breakage and enable individual successful compilation of
this change.
References: https://lists.freedesktop.org/archives/dri-devel/2020-February/257183.html
Signed-off-by: Wambui Karuga <wambui.karugax@gmail.com>
Reviewed-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Link: https://patchwork.freedesktop.org/patch/msgid/20200310133121.27913-18-wambui.karugax@gmail.com
This commit is contained in:

committed by
Daniel Vetter

parent
0df1082374
commit
7ce84471e3
@@ -1308,10 +1308,8 @@ static const struct file_operations mipi_dbi_debugfs_command_fops = {
|
||||
* controller or getting the read command values.
|
||||
* Drivers can use this as their &drm_driver->debugfs_init callback.
|
||||
*
|
||||
* Returns:
|
||||
* Zero on success, negative error code on failure.
|
||||
*/
|
||||
int mipi_dbi_debugfs_init(struct drm_minor *minor)
|
||||
void mipi_dbi_debugfs_init(struct drm_minor *minor)
|
||||
{
|
||||
struct mipi_dbi_dev *dbidev = drm_to_mipi_dbi_dev(minor->dev);
|
||||
umode_t mode = S_IFREG | S_IWUSR;
|
||||
@@ -1320,8 +1318,6 @@ int mipi_dbi_debugfs_init(struct drm_minor *minor)
|
||||
mode |= S_IRUGO;
|
||||
debugfs_create_file("command", mode, minor->debugfs_root, dbidev,
|
||||
&mipi_dbi_debugfs_command_fops);
|
||||
|
||||
return 0;
|
||||
}
|
||||
EXPORT_SYMBOL(mipi_dbi_debugfs_init);
|
||||
|
||||
|
Reference in New Issue
Block a user