Skip to contentSkip to conversation

drm/ttm: fix, avoid iomapping system memory

PATCH In review Jerome Glisse 2 participants 2 messages May 5, 2010

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 drm/ttm: fix, avoid iomapping system memory

If the memory is not iomem we should not try to
ioremap it. Should fix :

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

---
 drivers/gpu/drm/ttm/ttm_bo_util.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
drivers/gpu/drm/ttm/ttm_bo_util.c +1 -1
index a37a948..13012a1 100644
@@ -113,7 +113,7 @@ int ttm_mem_reg_ioremap(struct ttm_bo_device *bdev, struct ttm_mem_reg *mem,
 
 	*virtual = NULL;
 	ret = ttm_mem_io_reserve(bdev, mem);
-	if (ret)
+	if (ret || !mem->bus.is_iomem)
 		return ret;
 
 	if (mem->bus.addr) {
Signature · 1 line
1.7.0.1
Tested-by on v1 1/1
#1 lore raw

2010/5/5 Jerome Glisse <[email protected]>:

Quoted 6 lines

If the memory is not iomem we should not try to
ioremap it. Should fix :

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

Thanks!

Signature · 5 lines
Rafał
_______________________________________________
dri-devel mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/dri-devel