mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-08-23 06:05:48 -04:00
drm/fb-helper: Remove unused local variable in hotplug_event()
Remove the 'err' local variable in drm_fb_helper_hotplug_event() which only stores a return value that is never used beyond the immediate return statement. This simplifies the code without behavior changes. Signed-off-by: Cristian Ciocaltea <cristian.ciocaltea@collabora.com> Reviewed-by: Thomas Zimmermann <tzimmermann@suse.de> Acked-by: Maxime Ripard <mripard@kernel.org> Link: https://patch.msgid.link/20260602-dw-hdmi-qp-scramb-v7-1-445eb54ee1ed@collabora.com Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
This commit is contained in:
committed by
Luca Ceresoli
parent
60b5fa6edf
commit
cdeb2ccd99
@@ -1744,21 +1744,17 @@ EXPORT_SYMBOL(drm_fb_helper_initial_config);
|
||||
*/
|
||||
int drm_fb_helper_hotplug_event(struct drm_fb_helper *fb_helper)
|
||||
{
|
||||
int err = 0;
|
||||
|
||||
if (!drm_fbdev_emulation || !fb_helper)
|
||||
return 0;
|
||||
|
||||
mutex_lock(&fb_helper->lock);
|
||||
if (fb_helper->deferred_setup) {
|
||||
err = __drm_fb_helper_initial_config_and_unlock(fb_helper);
|
||||
return err;
|
||||
}
|
||||
if (fb_helper->deferred_setup)
|
||||
return __drm_fb_helper_initial_config_and_unlock(fb_helper);
|
||||
|
||||
if (!fb_helper->fb || !drm_master_internal_acquire(fb_helper->dev)) {
|
||||
fb_helper->delayed_hotplug = true;
|
||||
mutex_unlock(&fb_helper->lock);
|
||||
return err;
|
||||
return 0;
|
||||
}
|
||||
|
||||
drm_master_internal_release(fb_helper->dev);
|
||||
@@ -1802,4 +1798,3 @@ bool drm_fb_helper_gem_is_fb(const struct drm_fb_helper *fb_helper,
|
||||
return gem == obj;
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(drm_fb_helper_gem_is_fb);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user