diff options
author | Keith Packard <keithp@keithp.com> | 2011-07-12 13:40:25 -0400 |
---|---|---|
committer | Keith Packard <keithp@keithp.com> | 2011-07-12 13:40:25 -0400 |
commit | 9aa73a51c91cb0d0af4caaa9823969c1a1179a12 (patch) | |
tree | 4a7b4fa5f2b9915154fbd9cc678d279026071909 /drivers/gpu | |
parent | c7c369472dad852f6fe06a8be94dea72de784934 (diff) | |
parent | a94919eaddaa3fede1df8563ce4d761a75374645 (diff) |
Merge branch 'drm-intel-fixes' into drm-intel-next
Diffstat (limited to 'drivers/gpu')
-rw-r--r-- | drivers/gpu/drm/i915/i915_dma.c | 14 | ||||
-rw-r--r-- | drivers/gpu/drm/i915/i915_drv.c | 2 | ||||
-rw-r--r-- | drivers/gpu/drm/i915/intel_ringbuffer.h | 2 |
3 files changed, 13 insertions, 5 deletions
diff --git a/drivers/gpu/drm/i915/i915_dma.c b/drivers/gpu/drm/i915/i915_dma.c index 1315a882275c..12712824a6d2 100644 --- a/drivers/gpu/drm/i915/i915_dma.c +++ b/drivers/gpu/drm/i915/i915_dma.c | |||
@@ -1945,7 +1945,7 @@ int i915_driver_load(struct drm_device *dev, unsigned long flags) | |||
1945 | if (!dev_priv->mm.gtt) { | 1945 | if (!dev_priv->mm.gtt) { |
1946 | DRM_ERROR("Failed to initialize GTT\n"); | 1946 | DRM_ERROR("Failed to initialize GTT\n"); |
1947 | ret = -ENODEV; | 1947 | ret = -ENODEV; |
1948 | goto out_iomapfree; | 1948 | goto out_rmmap; |
1949 | } | 1949 | } |
1950 | 1950 | ||
1951 | agp_size = dev_priv->mm.gtt->gtt_mappable_entries << PAGE_SHIFT; | 1951 | agp_size = dev_priv->mm.gtt->gtt_mappable_entries << PAGE_SHIFT; |
@@ -1989,7 +1989,7 @@ int i915_driver_load(struct drm_device *dev, unsigned long flags) | |||
1989 | if (dev_priv->wq == NULL) { | 1989 | if (dev_priv->wq == NULL) { |
1990 | DRM_ERROR("Failed to create our workqueue.\n"); | 1990 | DRM_ERROR("Failed to create our workqueue.\n"); |
1991 | ret = -ENOMEM; | 1991 | ret = -ENOMEM; |
1992 | goto out_iomapfree; | 1992 | goto out_mtrrfree; |
1993 | } | 1993 | } |
1994 | 1994 | ||
1995 | /* enable GEM by default */ | 1995 | /* enable GEM by default */ |
@@ -2076,13 +2076,21 @@ int i915_driver_load(struct drm_device *dev, unsigned long flags) | |||
2076 | return 0; | 2076 | return 0; |
2077 | 2077 | ||
2078 | out_gem_unload: | 2078 | out_gem_unload: |
2079 | if (dev_priv->mm.inactive_shrinker.shrink) | ||
2080 | unregister_shrinker(&dev_priv->mm.inactive_shrinker); | ||
2081 | |||
2079 | if (dev->pdev->msi_enabled) | 2082 | if (dev->pdev->msi_enabled) |
2080 | pci_disable_msi(dev->pdev); | 2083 | pci_disable_msi(dev->pdev); |
2081 | 2084 | ||
2082 | intel_teardown_gmbus(dev); | 2085 | intel_teardown_gmbus(dev); |
2083 | intel_teardown_mchbar(dev); | 2086 | intel_teardown_mchbar(dev); |
2084 | destroy_workqueue(dev_priv->wq); | 2087 | destroy_workqueue(dev_priv->wq); |
2085 | out_iomapfree: | 2088 | out_mtrrfree: |
2089 | if (dev_priv->mm.gtt_mtrr >= 0) { | ||
2090 | mtrr_del(dev_priv->mm.gtt_mtrr, dev->agp->base, | ||
2091 | dev->agp->agp_info.aper_size * 1024 * 1024); | ||
2092 | dev_priv->mm.gtt_mtrr = -1; | ||
2093 | } | ||
2086 | io_mapping_free(dev_priv->mm.gtt_mapping); | 2094 | io_mapping_free(dev_priv->mm.gtt_mapping); |
2087 | out_rmmap: | 2095 | out_rmmap: |
2088 | pci_iounmap(dev->pdev, dev_priv->regs); | 2096 | pci_iounmap(dev->pdev, dev_priv->regs); |
diff --git a/drivers/gpu/drm/i915/i915_drv.c b/drivers/gpu/drm/i915/i915_drv.c index 629d24ca73e2..6ed73ae2133a 100644 --- a/drivers/gpu/drm/i915/i915_drv.c +++ b/drivers/gpu/drm/i915/i915_drv.c | |||
@@ -52,7 +52,7 @@ module_param_named(powersave, i915_powersave, int, 0600); | |||
52 | unsigned int i915_semaphores = 0; | 52 | unsigned int i915_semaphores = 0; |
53 | module_param_named(semaphores, i915_semaphores, int, 0600); | 53 | module_param_named(semaphores, i915_semaphores, int, 0600); |
54 | 54 | ||
55 | unsigned int i915_enable_rc6 = 1; | 55 | unsigned int i915_enable_rc6 = 0; |
56 | module_param_named(i915_enable_rc6, i915_enable_rc6, int, 0600); | 56 | module_param_named(i915_enable_rc6, i915_enable_rc6, int, 0600); |
57 | 57 | ||
58 | unsigned int i915_enable_fbc = 1; | 58 | unsigned int i915_enable_fbc = 1; |
diff --git a/drivers/gpu/drm/i915/intel_ringbuffer.h b/drivers/gpu/drm/i915/intel_ringbuffer.h index c0e0ee63fbf4..39ac2b634ae5 100644 --- a/drivers/gpu/drm/i915/intel_ringbuffer.h +++ b/drivers/gpu/drm/i915/intel_ringbuffer.h | |||
@@ -165,7 +165,7 @@ void intel_cleanup_ring_buffer(struct intel_ring_buffer *ring); | |||
165 | int __must_check intel_wait_ring_buffer(struct intel_ring_buffer *ring, int n); | 165 | int __must_check intel_wait_ring_buffer(struct intel_ring_buffer *ring, int n); |
166 | static inline int intel_wait_ring_idle(struct intel_ring_buffer *ring) | 166 | static inline int intel_wait_ring_idle(struct intel_ring_buffer *ring) |
167 | { | 167 | { |
168 | return intel_wait_ring_buffer(ring, ring->space - 8); | 168 | return intel_wait_ring_buffer(ring, ring->size - 8); |
169 | } | 169 | } |
170 | 170 | ||
171 | int __must_check intel_ring_begin(struct intel_ring_buffer *ring, int n); | 171 | int __must_check intel_ring_begin(struct intel_ring_buffer *ring, int n); |