diff options
| author | Alex Deucher <alexander.deucher@amd.com> | 2016-09-28 12:41:50 -0400 |
|---|---|---|
| committer | Alex Deucher <alexander.deucher@amd.com> | 2016-09-28 16:13:17 -0400 |
| commit | e96ec90f496603c48e0945f8bdeb4cdf3088cbba (patch) | |
| tree | b4d54a29c135d90548870cefc5b5fa0427d9b109 /drivers/gpu/drm/amd/amdgpu | |
| parent | bdbdb571c807b927867bd391159c9872a952533f (diff) | |
drm/amdgpu/dce10: disable hpd on local panels
Otherwise we can get a hotplug interrupt storm when
we turn the panel off if hpd interrupts were enabled
by the bios.
bug:
https://bugs.freedesktop.org/show_bug.cgi?id=97471
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Cc: stable@vger.kernel.org
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu')
| -rw-r--r-- | drivers/gpu/drm/amd/amdgpu/dce_v10_0.c | 23 |
1 files changed, 13 insertions, 10 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/dce_v10_0.c b/drivers/gpu/drm/amd/amdgpu/dce_v10_0.c index 9a63d7766604..55e346e0d1dc 100644 --- a/drivers/gpu/drm/amd/amdgpu/dce_v10_0.c +++ b/drivers/gpu/drm/amd/amdgpu/dce_v10_0.c | |||
| @@ -427,16 +427,6 @@ static void dce_v10_0_hpd_init(struct amdgpu_device *adev) | |||
| 427 | list_for_each_entry(connector, &dev->mode_config.connector_list, head) { | 427 | list_for_each_entry(connector, &dev->mode_config.connector_list, head) { |
| 428 | struct amdgpu_connector *amdgpu_connector = to_amdgpu_connector(connector); | 428 | struct amdgpu_connector *amdgpu_connector = to_amdgpu_connector(connector); |
| 429 | 429 | ||
| 430 | if (connector->connector_type == DRM_MODE_CONNECTOR_eDP || | ||
| 431 | connector->connector_type == DRM_MODE_CONNECTOR_LVDS) { | ||
| 432 | /* don't try to enable hpd on eDP or LVDS avoid breaking the | ||
| 433 | * aux dp channel on imac and help (but not completely fix) | ||
| 434 | * https://bugzilla.redhat.com/show_bug.cgi?id=726143 | ||
| 435 | * also avoid interrupt storms during dpms. | ||
| 436 | */ | ||
| 437 | continue; | ||
| 438 | } | ||
| 439 | |||
| 440 | switch (amdgpu_connector->hpd.hpd) { | 430 | switch (amdgpu_connector->hpd.hpd) { |
| 441 | case AMDGPU_HPD_1: | 431 | case AMDGPU_HPD_1: |
| 442 | idx = 0; | 432 | idx = 0; |
| @@ -460,6 +450,19 @@ static void dce_v10_0_hpd_init(struct amdgpu_device *adev) | |||
| 460 | continue; | 450 | continue; |
| 461 | } | 451 | } |
| 462 | 452 | ||
| 453 | if (connector->connector_type == DRM_MODE_CONNECTOR_eDP || | ||
| 454 | connector->connector_type == DRM_MODE_CONNECTOR_LVDS) { | ||
| 455 | /* don't try to enable hpd on eDP or LVDS avoid breaking the | ||
| 456 | * aux dp channel on imac and help (but not completely fix) | ||
| 457 | * https://bugzilla.redhat.com/show_bug.cgi?id=726143 | ||
| 458 | * also avoid interrupt storms during dpms. | ||
| 459 | */ | ||
| 460 | tmp = RREG32(mmDC_HPD_INT_CONTROL + hpd_offsets[idx]); | ||
| 461 | tmp = REG_SET_FIELD(tmp, DC_HPD_INT_CONTROL, DC_HPD_INT_EN, 0); | ||
| 462 | WREG32(mmDC_HPD_INT_CONTROL + hpd_offsets[idx], tmp); | ||
| 463 | continue; | ||
| 464 | } | ||
| 465 | |||
| 463 | tmp = RREG32(mmDC_HPD_CONTROL + hpd_offsets[idx]); | 466 | tmp = RREG32(mmDC_HPD_CONTROL + hpd_offsets[idx]); |
| 464 | tmp = REG_SET_FIELD(tmp, DC_HPD_CONTROL, DC_HPD_EN, 1); | 467 | tmp = REG_SET_FIELD(tmp, DC_HPD_CONTROL, DC_HPD_EN, 1); |
| 465 | WREG32(mmDC_HPD_CONTROL + hpd_offsets[idx], tmp); | 468 | WREG32(mmDC_HPD_CONTROL + hpd_offsets[idx], tmp); |
