diff options
author | Dave Airlie <airlied@redhat.com> | 2008-12-19 00:38:34 -0500 |
---|---|---|
committer | Dave Airlie <airlied@redhat.com> | 2008-12-19 00:38:34 -0500 |
commit | ac5c4e76180a74c7f922f6fa71ace0cef45fa433 (patch) | |
tree | 04ba893ac3b43fb24fa413f1ad8f37bff5cb7ee5 /drivers/gpu/drm/i915 | |
parent | c4de0a5d671e3af38dc3496538e391782aecc3a5 (diff) |
drm/i915: GEM on PAE has problems - disable it for now.
On PAE systems, GEM allocates pages using shmem, and passes these
pages to be bound into AGP, however the AGP interfaces + the x86
set_memory interfaces all take unsigned long not dma_addr_t.
The initial fix for this was a mess, so we need to do this correctly
for 2.6.29.
Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/i915')
-rw-r--r-- | drivers/gpu/drm/i915/i915_dma.c | 10 | ||||
-rw-r--r-- | drivers/gpu/drm/i915/i915_drv.h | 2 |
2 files changed, 11 insertions, 1 deletions
diff --git a/drivers/gpu/drm/i915/i915_dma.c b/drivers/gpu/drm/i915/i915_dma.c index 553dd4bc3075..afa8a12cd009 100644 --- a/drivers/gpu/drm/i915/i915_dma.c +++ b/drivers/gpu/drm/i915/i915_dma.c | |||
@@ -717,7 +717,7 @@ static int i915_getparam(struct drm_device *dev, void *data, | |||
717 | value = dev->pci_device; | 717 | value = dev->pci_device; |
718 | break; | 718 | break; |
719 | case I915_PARAM_HAS_GEM: | 719 | case I915_PARAM_HAS_GEM: |
720 | value = 1; | 720 | value = dev_priv->has_gem; |
721 | break; | 721 | break; |
722 | default: | 722 | default: |
723 | DRM_ERROR("Unknown parameter %d\n", param->param); | 723 | DRM_ERROR("Unknown parameter %d\n", param->param); |
@@ -830,6 +830,14 @@ int i915_driver_load(struct drm_device *dev, unsigned long flags) | |||
830 | 830 | ||
831 | dev_priv->regs = ioremap(base, size); | 831 | dev_priv->regs = ioremap(base, size); |
832 | 832 | ||
833 | #ifdef CONFIG_HIGHMEM64G | ||
834 | /* don't enable GEM on PAE - needs agp + set_memory_* interface fixes */ | ||
835 | dev_priv->has_gem = 0; | ||
836 | #else | ||
837 | /* enable GEM by default */ | ||
838 | dev_priv->has_gem = 1; | ||
839 | #endif | ||
840 | |||
833 | i915_gem_load(dev); | 841 | i915_gem_load(dev); |
834 | 842 | ||
835 | /* Init HWS */ | 843 | /* Init HWS */ |
diff --git a/drivers/gpu/drm/i915/i915_drv.h b/drivers/gpu/drm/i915/i915_drv.h index adc972cc6bfc..b3cc4731aa7c 100644 --- a/drivers/gpu/drm/i915/i915_drv.h +++ b/drivers/gpu/drm/i915/i915_drv.h | |||
@@ -106,6 +106,8 @@ struct intel_opregion { | |||
106 | typedef struct drm_i915_private { | 106 | typedef struct drm_i915_private { |
107 | struct drm_device *dev; | 107 | struct drm_device *dev; |
108 | 108 | ||
109 | int has_gem; | ||
110 | |||
109 | void __iomem *regs; | 111 | void __iomem *regs; |
110 | drm_local_map_t *sarea; | 112 | drm_local_map_t *sarea; |
111 | 113 | ||