[1/3] drm/radeon: Disable uncacheable CPU mappings of GTT with RV6xx
diff mbox

Message ID 1446711928-14788-1-git-send-email-michel@daenzer.net
State New
Headers show

Commit Message

Michel Dänzer Nov. 5, 2015, 8:25 a.m. UTC
From: Michel Dänzer <michel.daenzer@amd.com>

They reportedly cause random GPU hangs.

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=91268

Cc: stable@vger.kernel.org
Signed-off-by: Michel Dänzer <michel.daenzer@amd.com>
---
 drivers/gpu/drm/radeon/radeon_object.c | 6 ++++++
 1 file changed, 6 insertions(+)

Comments

Christian König Nov. 5, 2015, 10:41 a.m. UTC | #1
On 05.11.2015 09:25, Michel Dänzer wrote:
> From: Michel Dänzer <michel.daenzer@amd.com>
>
> They reportedly cause random GPU hangs.
>
> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=91268
>
> Cc: stable@vger.kernel.org
> Signed-off-by: Michel Dänzer <michel.daenzer@amd.com>

For this series Reviewed-by: Christian König <christian.koenig@amd.com>

> ---
>   drivers/gpu/drm/radeon/radeon_object.c | 6 ++++++
>   1 file changed, 6 insertions(+)
>
> diff --git a/drivers/gpu/drm/radeon/radeon_object.c b/drivers/gpu/drm/radeon/radeon_object.c
> index d302488..a35f5af 100644
> --- a/drivers/gpu/drm/radeon/radeon_object.c
> +++ b/drivers/gpu/drm/radeon/radeon_object.c
> @@ -221,6 +221,12 @@ int radeon_bo_create(struct radeon_device *rdev,
>   	if (!(rdev->flags & RADEON_IS_PCIE))
>   		bo->flags &= ~(RADEON_GEM_GTT_WC | RADEON_GEM_GTT_UC);
>   
> +	/* Write-combined CPU mappings of GTT cause GPU hangs with RV6xx
> +	 * See https://bugs.freedesktop.org/show_bug.cgi?id=91268
> +	 */
> +	if (rdev->family >= CHIP_RV610 && rdev->family <= CHIP_RV635)
> +		bo->flags &= ~(RADEON_GEM_GTT_WC | RADEON_GEM_GTT_UC);
> +
>   #ifdef CONFIG_X86_32
>   	/* XXX: Write-combined CPU mappings of GTT seem broken on 32-bit
>   	 * See https://bugs.freedesktop.org/show_bug.cgi?id=84627
Alex Deucher Nov. 5, 2015, 7:03 p.m. UTC | #2
On Thu, Nov 5, 2015 at 5:41 AM, Christian König <deathsimple@vodafone.de> wrote:
> On 05.11.2015 09:25, Michel Dänzer wrote:
>>
>> From: Michel Dänzer <michel.daenzer@amd.com>
>>
>> They reportedly cause random GPU hangs.
>>
>> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=91268
>>
>> Cc: stable@vger.kernel.org
>> Signed-off-by: Michel Dänzer <michel.daenzer@amd.com>
>
>
> For this series Reviewed-by: Christian König <christian.koenig@amd.com>

Applied.  thanks!

Alex

>
>> ---
>>   drivers/gpu/drm/radeon/radeon_object.c | 6 ++++++
>>   1 file changed, 6 insertions(+)
>>
>> diff --git a/drivers/gpu/drm/radeon/radeon_object.c
>> b/drivers/gpu/drm/radeon/radeon_object.c
>> index d302488..a35f5af 100644
>> --- a/drivers/gpu/drm/radeon/radeon_object.c
>> +++ b/drivers/gpu/drm/radeon/radeon_object.c
>> @@ -221,6 +221,12 @@ int radeon_bo_create(struct radeon_device *rdev,
>>         if (!(rdev->flags & RADEON_IS_PCIE))
>>                 bo->flags &= ~(RADEON_GEM_GTT_WC | RADEON_GEM_GTT_UC);
>>   +     /* Write-combined CPU mappings of GTT cause GPU hangs with RV6xx
>> +        * See https://bugs.freedesktop.org/show_bug.cgi?id=91268
>> +        */
>> +       if (rdev->family >= CHIP_RV610 && rdev->family <= CHIP_RV635)
>> +               bo->flags &= ~(RADEON_GEM_GTT_WC | RADEON_GEM_GTT_UC);
>> +
>>   #ifdef CONFIG_X86_32
>>         /* XXX: Write-combined CPU mappings of GTT seem broken on 32-bit
>>          * See https://bugs.freedesktop.org/show_bug.cgi?id=84627
>
>
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/dri-devel

Patch
diff mbox

diff --git a/drivers/gpu/drm/radeon/radeon_object.c b/drivers/gpu/drm/radeon/radeon_object.c
index d302488..a35f5af 100644
--- a/drivers/gpu/drm/radeon/radeon_object.c
+++ b/drivers/gpu/drm/radeon/radeon_object.c
@@ -221,6 +221,12 @@  int radeon_bo_create(struct radeon_device *rdev,
 	if (!(rdev->flags & RADEON_IS_PCIE))
 		bo->flags &= ~(RADEON_GEM_GTT_WC | RADEON_GEM_GTT_UC);
 
+	/* Write-combined CPU mappings of GTT cause GPU hangs with RV6xx
+	 * See https://bugs.freedesktop.org/show_bug.cgi?id=91268
+	 */
+	if (rdev->family >= CHIP_RV610 && rdev->family <= CHIP_RV635)
+		bo->flags &= ~(RADEON_GEM_GTT_WC | RADEON_GEM_GTT_UC);
+
 #ifdef CONFIG_X86_32
 	/* XXX: Write-combined CPU mappings of GTT seem broken on 32-bit
 	 * See https://bugs.freedesktop.org/show_bug.cgi?id=84627