Commit 68f73a1b authored by Wambui Karuga's avatar Wambui Karuga Committed by Daniel Vetter

drm/omap: remove checks for return value of drm_debugfs functions

Since 987d65d0 (drm: debugfs: make
drm_debugfs_create_files() never fail), there is no need to ever check
the return value for drm_debugfs_create_files(). Therefore remove the
checks for the return value and subsequent error handling in
omap_debugfs_init().

These changes also enables the changing of omap_debugfs_init() to return
0 directly.

v2: convert omap_debugfs_init() to return 0 instead of void to avoid
introduction of build issues and enable individual driver compilation.

References: https://lists.freedesktop.org/archives/dri-devel/2020-February/257183.htmlSigned-off-by: default avatarWambui Karuga <wambui.karugax@gmail.com>
Reviewed-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: default avatarDaniel Vetter <daniel.vetter@ffwll.ch>
Link: https://patchwork.freedesktop.org/patch/msgid/20200310133121.27913-14-wambui.karugax@gmail.com
parent b4441251
...@@ -82,29 +82,16 @@ static struct drm_info_list omap_dmm_debugfs_list[] = { ...@@ -82,29 +82,16 @@ static struct drm_info_list omap_dmm_debugfs_list[] = {
int omap_debugfs_init(struct drm_minor *minor) int omap_debugfs_init(struct drm_minor *minor)
{ {
struct drm_device *dev = minor->dev; drm_debugfs_create_files(omap_debugfs_list,
int ret; ARRAY_SIZE(omap_debugfs_list),
minor->debugfs_root, minor);
ret = drm_debugfs_create_files(omap_debugfs_list,
ARRAY_SIZE(omap_debugfs_list),
minor->debugfs_root, minor);
if (ret) {
dev_err(dev->dev, "could not install omap_debugfs_list\n");
return ret;
}
if (dmm_is_available()) if (dmm_is_available())
ret = drm_debugfs_create_files(omap_dmm_debugfs_list, drm_debugfs_create_files(omap_dmm_debugfs_list,
ARRAY_SIZE(omap_dmm_debugfs_list), ARRAY_SIZE(omap_dmm_debugfs_list),
minor->debugfs_root, minor); minor->debugfs_root, minor);
if (ret) { return 0;
dev_err(dev->dev, "could not install omap_dmm_debugfs_list\n");
return ret;
}
return ret;
} }
#endif #endif
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment