diff options
author | David Herrmann <dh.herrmann@gmail.com> | 2014-02-24 15:32:00 +0100 |
---|---|---|
committer | David Herrmann <dh.herrmann@gmail.com> | 2014-03-16 12:25:19 +0100 |
commit | 1abbc43761793938fba9ae745e01d5b4730a9914 (patch) | |
tree | 944e3e52ff865aa29b4a0b6d12bc143c5306d269 /drivers/gpu/drm/drm_stub.c | |
parent | 5817878c6f4221c3ace4af63260080635063371e (diff) | |
download | lwn-1abbc43761793938fba9ae745e01d5b4730a9914.tar.gz lwn-1abbc43761793938fba9ae745e01d5b4730a9914.zip |
drm: coding-style fixes in minor handling
Properly name goto-labels, remove empty lines and use DRM_ERROR if
possible.
Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
Diffstat (limited to 'drivers/gpu/drm/drm_stub.c')
-rw-r--r-- | drivers/gpu/drm/drm_stub.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/drivers/gpu/drm/drm_stub.c b/drivers/gpu/drm/drm_stub.c index 96fe5dec3822..5268ffc5d94e 100644 --- a/drivers/gpu/drm/drm_stub.c +++ b/drivers/gpu/drm/drm_stub.c @@ -325,23 +325,21 @@ static int drm_minor_register(struct drm_device *dev, unsigned int type) ret = drm_debugfs_init(new_minor, minor_id, drm_debugfs_root); if (ret) { DRM_ERROR("DRM: Failed to initialize /sys/kernel/debug/dri.\n"); - goto err_mem; + goto err_id; } ret = drm_sysfs_device_add(new_minor); if (ret) { - printk(KERN_ERR - "DRM: Error sysfs_device_add.\n"); + DRM_ERROR("DRM: Error sysfs_device_add.\n"); goto err_debugfs; } DRM_DEBUG("new minor assigned %d\n", minor_id); return 0; - err_debugfs: drm_debugfs_cleanup(new_minor); -err_mem: +err_id: idr_remove(&drm_minors_idr, minor_id); return ret; } |