drm/tegra: remove checks for debugfs functions return value
Since 987d65d013
(drm: debugfs: make
drm_debugfs_create_files() never fail) there is no need to check the
return value of drm_debugfs_create_files(). Therefore, remove the
return checks and error handling of the drm_debugfs_create_files()
function from various debugfs init functions in drm/tegra and have
them return 0 directly.
v2: remove conversion of tegra_debugfs_init() to void to avoid build
breakage.
References: https://lists.freedesktop.org/archives/dri-devel/2020-February/257183.html
Signed-off-by: Wambui Karuga <wambui.karugax@gmail.com>
Acked-by: Thierry Reding <treding@nvidia.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-2-wambui.karugax@gmail.com
This commit is contained in:

committed by
Daniel Vetter

parent
82c0ef94b9
commit
ad6d94f24f
@@ -1496,7 +1496,6 @@ static int tegra_dc_late_register(struct drm_crtc *crtc)
|
||||
struct drm_minor *minor = crtc->dev->primary;
|
||||
struct dentry *root;
|
||||
struct tegra_dc *dc = to_tegra_dc(crtc);
|
||||
int err;
|
||||
|
||||
#ifdef CONFIG_DEBUG_FS
|
||||
root = crtc->debugfs_entry;
|
||||
@@ -1512,17 +1511,9 @@ static int tegra_dc_late_register(struct drm_crtc *crtc)
|
||||
for (i = 0; i < count; i++)
|
||||
dc->debugfs_files[i].data = dc;
|
||||
|
||||
err = drm_debugfs_create_files(dc->debugfs_files, count, root, minor);
|
||||
if (err < 0)
|
||||
goto free;
|
||||
drm_debugfs_create_files(dc->debugfs_files, count, root, minor);
|
||||
|
||||
return 0;
|
||||
|
||||
free:
|
||||
kfree(dc->debugfs_files);
|
||||
dc->debugfs_files = NULL;
|
||||
|
||||
return err;
|
||||
}
|
||||
|
||||
static void tegra_dc_early_unregister(struct drm_crtc *crtc)
|
||||
|
Reference in New Issue
Block a user