summaryrefslogtreecommitdiff
path: root/shared-core
diff options
context:
space:
mode:
authorKristian Høgsberg <krh@redhat.com>2008-02-12 16:08:18 -0500
committerKristian Høgsberg <krh@sasori.boston.redhat.com>2008-02-13 13:34:02 -0500
commitdb3f03ae3538bea3d29ef66ac24d9a1f54cff418 (patch)
treecb42f08617542f7c7842a95e24765aedfee7ba01 /shared-core
parentee15459483d50b2efe630051b45f36cfbb351683 (diff)
i915: Only look up dev_priv->mmio_map if it's not already set up
Diffstat (limited to 'shared-core')
-rw-r--r--shared-core/i915_dma.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/shared-core/i915_dma.c b/shared-core/i915_dma.c
index 0682a334..fc009204 100644
--- a/shared-core/i915_dma.c
+++ b/shared-core/i915_dma.c
@@ -117,7 +117,8 @@ static int i915_initialize(struct drm_device * dev, drm_i915_init_t * init)
return -EINVAL;
}
- dev_priv->mmio_map = drm_core_findmap(dev, init->mmio_offset);
+ if (init->mmio_offset != 0)
+ dev_priv->mmio_map = drm_core_findmap(dev, init->mmio_offset);
if (!dev_priv->mmio_map) {
i915_dma_cleanup(dev);
DRM_ERROR("can not find mmio map!\n");