summaryrefslogtreecommitdiffstats
path: root/sys/dev/drm
diff options
context:
space:
mode:
authorrnoland <rnoland@FreeBSD.org>2010-04-22 18:47:30 +0000
committerrnoland <rnoland@FreeBSD.org>2010-04-22 18:47:30 +0000
commit3e04ac896af79c4f043b6e6850bc75f5c6f53396 (patch)
tree8c0990c40aa7e566bc681b82d1645398bc338ac0 /sys/dev/drm
parent811be862d0fc3cf0d7225fc542e805a6efb93b30 (diff)
downloadFreeBSD-src-3e04ac896af79c4f043b6e6850bc75f5c6f53396.zip
FreeBSD-src-3e04ac896af79c4f043b6e6850bc75f5c6f53396.tar.gz
Now that we properly set write-combining on the pages that back the GART,
disable snooping on radeons. MFC after: 2 weeks
Diffstat (limited to 'sys/dev/drm')
-rw-r--r--sys/dev/drm/ati_pcigart.c11
-rw-r--r--sys/dev/drm/r600_cp.c2
2 files changed, 8 insertions, 5 deletions
diff --git a/sys/dev/drm/ati_pcigart.c b/sys/dev/drm/ati_pcigart.c
index e3fecd1..063288e 100644
--- a/sys/dev/drm/ati_pcigart.c
+++ b/sys/dev/drm/ati_pcigart.c
@@ -39,8 +39,9 @@ __FBSDID("$FreeBSD$");
#define ATI_PCIGART_PAGE_SIZE 4096 /* PCI GART page size */
#define ATI_PCIGART_PAGE_MASK (~(ATI_PCIGART_PAGE_SIZE-1))
-#define ATI_PCIE_WRITE 0x4
-#define ATI_PCIE_READ 0x8
+#define ATI_GART_NOSNOOP 0x1
+#define ATI_GART_WRITE 0x4
+#define ATI_GART_READ 0x8
static void
drm_ati_alloc_pcigart_table_cb(void *arg, bus_dma_segment_t *segs,
@@ -196,13 +197,15 @@ drm_ati_pcigart_init(struct drm_device *dev,
case DRM_ATI_GART_IGP:
page_base |=
(upper_32_bits(entry_addr) & 0xff) << 4;
- page_base |= 0xc;
+ page_base |= ATI_GART_READ | ATI_GART_WRITE;
+ page_base |= ATI_GART_NOSNOOP;
break;
case DRM_ATI_GART_PCIE:
page_base >>= 8;
page_base |=
(upper_32_bits(entry_addr) & 0xff) << 24;
- page_base |= ATI_PCIE_READ | ATI_PCIE_WRITE;
+ page_base |= ATI_GART_READ | ATI_GART_WRITE;
+ page_base |= ATI_GART_NOSNOOP;
break;
default:
case DRM_ATI_GART_PCI:
diff --git a/sys/dev/drm/r600_cp.c b/sys/dev/drm/r600_cp.c
index f5c3b97..c2b8770 100644
--- a/sys/dev/drm/r600_cp.c
+++ b/sys/dev/drm/r600_cp.c
@@ -180,7 +180,7 @@ int r600_page_table_init(struct drm_device *dev)
entry_addr = entry->busaddr[i];
for (j = 0; j < (PAGE_SIZE / ATI_PCIGART_PAGE_SIZE); j++) {
page_base = (u64) entry_addr & ATI_PCIGART_PAGE_MASK;
- page_base |= R600_PTE_VALID | R600_PTE_SYSTEM | R600_PTE_SNOOPED;
+ page_base |= R600_PTE_VALID | R600_PTE_SYSTEM;
page_base |= R600_PTE_READABLE | R600_PTE_WRITEABLE;
*pci_gart = page_base;
OpenPOWER on IntegriCloud