Source-Changes-HG archive

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

[src/trunk]: src/sys/external/bsd/drm2/i915drm Fix GTT PTE flag bits.



details:   https://anonhg.NetBSD.org/src/rev/8e941a6fe24e
branches:  trunk
changeset: 796195:8e941a6fe24e
user:      riastradh <riastradh%NetBSD.org@localhost>
date:      Fri May 23 23:02:47 2014 +0000

description:
Fix GTT PTE flag bits.

diffstat:

 sys/external/bsd/drm2/i915drm/i915_gem_gtt.c |  16 +++++++++-------
 1 files changed, 9 insertions(+), 7 deletions(-)

diffs (44 lines):

diff -r 1e644196edf0 -r 8e941a6fe24e sys/external/bsd/drm2/i915drm/i915_gem_gtt.c
--- a/sys/external/bsd/drm2/i915drm/i915_gem_gtt.c      Fri May 23 22:59:23 2014 +0000
+++ b/sys/external/bsd/drm2/i915drm/i915_gem_gtt.c      Fri May 23 23:02:47 2014 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: i915_gem_gtt.c,v 1.11 2014/05/20 15:50:11 riastradh Exp $      */
+/*     $NetBSD: i915_gem_gtt.c,v 1.12 2014/05/23 23:02:47 riastradh Exp $      */
 
 /*-
  * Copyright (c) 2013 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: i915_gem_gtt.c,v 1.11 2014/05/20 15:50:11 riastradh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: i915_gem_gtt.c,v 1.12 2014/05/23 23:02:47 riastradh Exp $");
 
 #include <sys/types.h>
 #include <sys/param.h>
@@ -89,6 +89,8 @@
         * physical addresses.
         *
         * XXX pci_set_dma_mask?  pci_set_consistent_dma_mask?
+        *
+        * XXX DMA limits
         */
        if (INTEL_INFO(dev)->gen < 4)
                drm_limit_dma_space(dev, 0,
@@ -504,11 +506,11 @@
 
 typedef uint32_t gtt_pte_t;
 
-#define        GEN6_PTE_VALID          __BIT(0)
-#define        GEN6_PTE_UNCACHED       __BIT(1)
-#define        HSW_PTE_UNCACHED        (0)
-#define        GEN6_PTE_CACHE_LLC      __BIT(2)
-#define        GEN6_PTE_CACHE_LLC_MLC  __BIT(3)
+#define        GEN6_PTE_VALID          0x01
+#define        GEN6_PTE_UNCACHED       0x02
+#define        HSW_PTE_UNCACHED        0x00
+#define        GEN6_PTE_CACHE_LLC      0x04
+#define        GEN6_PTE_CACHE_LLC_MLC  0x06
 
 static uint32_t
 gen6_pte_addr_encode(bus_addr_t addr)



Home | Main Index | Thread Index | Old Index