[PATCH 1/2] drm/i915: stolen_reserved_base is also dma_addr_t

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The chunk added by this patch was missed by these commits:
* 920bcd1820a6 ("drm/i915: make i915_stolen_to_physical() return phys_addr_t")
* c88473878d47 ("drm/i915: Treat stolen memory as DMA addresses")

The stolen_reserved_base variable contains a memory address for stolen
memory and our code uses dma_addr_t for pointers to stolen, so it
makes sense to make it also be dma_addr_t. Notice that the local
variable inside i915_gem_init_stolen() that stores this pointer is
even already dma_addr_t.

This change essentially converts the size to 64 bits where applicable,
making sure things work in case we ever get crazy enough to put stolen
that far in memory.

Cc: Chris Wilson <chris@xxxxxxxxxxxxxxxxxx>
Signed-off-by: Paulo Zanoni <paulo.r.zanoni@xxxxxxxxx>
---
 drivers/gpu/drm/i915/i915_gem_gtt.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/i915/i915_gem_gtt.h b/drivers/gpu/drm/i915/i915_gem_gtt.h
index f62fb90..dd2ef5b 100644
--- a/drivers/gpu/drm/i915/i915_gem_gtt.h
+++ b/drivers/gpu/drm/i915/i915_gem_gtt.h
@@ -365,7 +365,7 @@ struct i915_ggtt {
 	 */
 	u32 stolen_size;		/* Total size of stolen memory */
 	u32 stolen_usable_size;	/* Total size minus reserved ranges */
-	u32 stolen_reserved_base;
+	dma_addr_t stolen_reserved_base;
 	u32 stolen_reserved_size;
 
 	/** "Graphics Stolen Memory" holds the global PTEs */
-- 
2.9.5

_______________________________________________
Intel-gfx mailing list
Intel-gfx@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/intel-gfx




[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]
  Powered by Linux