lkml.org 
[lkml]   [2021]   [Aug]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH] drm: radeon: r600_dma: Replace cpu_to_le32() by lower_32_bits()
Date
This patch fixes the following sparse errors:
drivers/gpu/drm/radeon/r600_dma.c:247:30: warning: incorrect type in assignment (different base types)
drivers/gpu/drm/radeon/r600_dma.c:247:30: expected unsigned int volatile [usertype]
drivers/gpu/drm/radeon/r600_dma.c:247:30: got restricted __le32 [usertype]

Signed-off-by: zhaoxiao <zhaoxiao@uniontech.com>
---
drivers/gpu/drm/radeon/r600_dma.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/radeon/r600_dma.c b/drivers/gpu/drm/radeon/r600_dma.c
index fb65e6fb5c4f..a2d0b1edcd22 100644
--- a/drivers/gpu/drm/radeon/r600_dma.c
+++ b/drivers/gpu/drm/radeon/r600_dma.c
@@ -244,7 +244,7 @@ int r600_dma_ring_test(struct radeon_device *rdev,
gpu_addr = rdev->wb.gpu_addr + index;

tmp = 0xCAFEDEAD;
- rdev->wb.wb[index/4] = cpu_to_le32(tmp);
+ rdev->wb.wb[index/4] = lower_32_bits(tmp);

r = radeon_ring_lock(rdev, ring, 4);
if (r) {
--
2.20.1


\
 
 \ /
  Last update: 2021-08-13 10:55    [W:0.032 / U:0.848 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site