summary refs log tree commit diff
path: root/include/drm/ttm/ttm_bo_api.h
diff options
context:
space:
mode:
authorAlex Deucher <alexdeucher@gmail.com>2015-03-04 00:18:38 -0500
committerDave Airlie <airlied@redhat.com>2015-03-05 09:04:39 +1000
commit54c4cd68ed7abd9f245722bee39464d04ddb4cfd (patch)
tree14f301bf2259f93b8a44b1afdb46dfd40f9a721d /include/drm/ttm/ttm_bo_api.h
parent440fd5283a87345cdd4237bdf45fb01130ea0056 (diff)
downloadlinux-54c4cd68ed7abd9f245722bee39464d04ddb4cfd.tar.gz
drm/ttm: device address space != CPU address space
We need to store device offsets in 64 bit as the device
address space may be larger than the CPU's.

Fixes GPU init failures on radeons with 4GB or more of
vram on 32 bit kernels.  We put vram at the start of the
GPU's address space so the gart aperture starts at 4 GB
causing all GPU addresses in the gart aperture to get
truncated.

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

[airlied: fix warning on nouveau build]

Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Cc: thellstrom@vmware.com
Acked-by: Thomas Hellstrom <thellstrom@vmware.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'include/drm/ttm/ttm_bo_api.h')
-rw-r--r--include/drm/ttm/ttm_bo_api.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/drm/ttm/ttm_bo_api.h b/include/drm/ttm/ttm_bo_api.h
index 0ccf7f267ff9..c768ddfbe53c 100644
--- a/include/drm/ttm/ttm_bo_api.h
+++ b/include/drm/ttm/ttm_bo_api.h
@@ -249,7 +249,7 @@ struct ttm_buffer_object {
 	 * either of these locks held.
 	 */
 
-	unsigned long offset;
+	uint64_t offset; /* GPU address space is independent of CPU word size */
 	uint32_t cur_placement;
 
 	struct sg_table *sg;