aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/amd/amdgpu/amdgpu_irq.c
diff options
context:
space:
mode:
authorDaniel Vetter <daniel.vetter@ffwll.ch>2016-12-13 18:08:04 -0500
committerDaniel Vetter <daniel.vetter@ffwll.ch>2016-12-18 08:18:12 -0500
commit2babdc850cc4f58753b7fb5332a57b513e3313cb (patch)
treead3764a4ba1b43f2cc60d01b23f3b4dc76391eb5 /drivers/gpu/drm/amd/amdgpu/amdgpu_irq.c
parent5bc9cb4dfbe8fcae02f8421e3102c78681f53b8c (diff)
drm/radeon|amdgpu: Remove redundant num_connectors check
The list walk will shortcircuit anyway. Cc: Alex Deucher <alexdeucher@gmail.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/20161213230814.19598-4-daniel.vetter@ffwll.ch
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_irq.c')
-rw-r--r--drivers/gpu/drm/amd/amdgpu/amdgpu_irq.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_irq.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_irq.c
index fb902932f571..e63ece049b05 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_irq.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_irq.c
@@ -61,10 +61,8 @@ static void amdgpu_hotplug_work_func(struct work_struct *work)
61 struct drm_connector *connector; 61 struct drm_connector *connector;
62 62
63 mutex_lock(&mode_config->mutex); 63 mutex_lock(&mode_config->mutex);
64 if (mode_config->num_connector) { 64 list_for_each_entry(connector, &mode_config->connector_list, head)
65 list_for_each_entry(connector, &mode_config->connector_list, head) 65 amdgpu_connector_hotplug(connector);
66 amdgpu_connector_hotplug(connector);
67 }
68 mutex_unlock(&mode_config->mutex); 66 mutex_unlock(&mode_config->mutex);
69 /* Just fire off a uevent and let userspace tell us what to do */ 67 /* Just fire off a uevent and let userspace tell us what to do */
70 drm_helper_hpd_irq_event(dev); 68 drm_helper_hpd_irq_event(dev);