summaryrefslogtreecommitdiff
path: root/linux-core
diff options
context:
space:
mode:
authorDave Airlie <airlied@linux.ie>2007-04-09 21:52:59 +1000
committerDave Airlie <airlied@linux.ie>2007-04-09 21:52:59 +1000
commita70f8e0ab265cc4a26ed2f9e92ab0618bd920a93 (patch)
treeb02b4bb9e402f5c3444378ec5590f2d4cfb25b26 /linux-core
parentb25558bb7377f6df6d457b50067a1d245f7911fd (diff)
radeon: add support for reverse engineered xpress200m
The IGPGART setup code was traced using mmio-trace on fglrx by myself and Phillip Ezolt <phillipezolt@gmail.com> on dri-devel. This code doesn't let the 3D driver work properly as the card has no vertex shader support. Thanks to Matthew Garrett + Ubuntu for providing me some hardware to do this work on.
Diffstat (limited to 'linux-core')
-rw-r--r--linux-core/ati_pcigart.c12
-rw-r--r--linux-core/drmP.h6
2 files changed, 15 insertions, 3 deletions
diff --git a/linux-core/ati_pcigart.c b/linux-core/ati_pcigart.c
index bb30dd74..52bf8922 100644
--- a/linux-core/ati_pcigart.c
+++ b/linux-core/ati_pcigart.c
@@ -205,10 +205,18 @@ int drm_ati_pcigart_init(drm_device_t *dev, drm_ati_pcigart_info *gart_info)
page_base = (u32) entry->busaddr[i];
for (j = 0; j < (PAGE_SIZE / ATI_PCIGART_PAGE_SIZE); j++) {
- if (gart_info->is_pcie)
+ switch(gart_info->gart_reg_if) {
+ case DRM_ATI_GART_IGP:
+ *pci_gart = cpu_to_le32((page_base) | 0xc);
+ break;
+ case DRM_ATI_GART_PCIE:
*pci_gart = cpu_to_le32((page_base >> 8) | 0xc);
- else
+ break;
+ default:
+ case DRM_ATI_GART_PCI:
*pci_gart = cpu_to_le32(page_base);
+ break;
+ }
pci_gart++;
page_base += ATI_PCIGART_PAGE_SIZE;
}
diff --git a/linux-core/drmP.h b/linux-core/drmP.h
index 648e29bc..d879c2a2 100644
--- a/linux-core/drmP.h
+++ b/linux-core/drmP.h
@@ -587,9 +587,13 @@ typedef struct drm_vbl_sig {
#define DRM_ATI_GART_MAIN 1
#define DRM_ATI_GART_FB 2
+#define DRM_ATI_GART_PCI 1
+#define DRM_ATI_GART_PCIE 2
+#define DRM_ATI_GART_IGP 3
+
typedef struct ati_pcigart_info {
int gart_table_location;
- int is_pcie;
+ int gart_reg_if;
void *addr;
dma_addr_t bus_addr;
drm_local_map_t mapping;