linux/drivers/gpu/drm/i915
Chris Wilson af62610313 drm/i915: Hold a reference to the object whilst unbinding the eviction list
During heavy aperture thrashing we may be forced to wait upon several active
objects during eviction. The active list may be the last reference to
these objects and so the action of waiting upon one of them may cause
another to be freed (and itself unbound). To prevent the object
disappearing underneath us, we need to acquire and hold a reference
whilst unbinding.

This should fix the reported page refcount OOPS:

kernel BUG at drivers/gpu/drm/i915/i915_gem.c:1444!
...
RIP: 0010:[<ffffffffa0093026>]  [<ffffffffa0093026>] i915_gem_object_put_pages+0x25/0xf5 [i915]
Call Trace:
 [<ffffffffa009481d>] i915_gem_object_unbind+0xc5/0x1a7 [i915]
 [<ffffffffa0098ab2>] i915_gem_evict_something+0x3bd/0x409 [i915]
 [<ffffffffa0027923>] ? drm_gem_object_lookup+0x27/0x57 [drm]
 [<ffffffffa0093bc3>] i915_gem_object_bind_to_gtt+0x1d3/0x279 [i915]
 [<ffffffffa0095b30>] i915_gem_object_pin+0xa3/0x146 [i915]
 [<ffffffffa0027948>] ? drm_gem_object_lookup+0x4c/0x57 [drm]
 [<ffffffffa00961bc>] i915_gem_do_execbuffer+0x50d/0xe32 [i915]

Reported-by: Shawn Starr <shawn.starr@rogers.com>
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=18902
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-09-20 20:50:00 +01:00
..
dvo_ch7xxx.c drm/i915: Remove dead KMS encoder save/restore code. 2010-04-12 09:23:30 -07:00
dvo_ch7017.c drm/i915: Remove dead KMS encoder save/restore code. 2010-04-12 09:23:30 -07:00
dvo_ivch.c drm/i915: Remove dead KMS encoder save/restore code. 2010-04-12 09:23:30 -07:00
dvo_sil164.c drm/i915: Remove dead KMS encoder save/restore code. 2010-04-12 09:23:30 -07:00
dvo_tfp410.c drm/i915: Use RSEN instead of HTPLG for tfp410 monitor detection. 2010-06-04 16:39:59 -07:00
dvo.h drm/i915: Subclass intel_encoder. 2010-08-09 11:24:28 -07:00
i915_debugfs.c drm/i915: Avoid pageflipping freeze when we miss the flip prepare interrupt 2010-09-07 11:16:35 +01:00
i915_dma.c drm/i915: Allocate the PCI resource for the MCHBAR 2010-09-07 11:14:18 +01:00
i915_drv.c drm/i915,agp/intel: Add second set of PCI-IDs for B43 2010-09-17 08:22:30 +01:00
i915_drv.h drm/i915: Include a generation number in the device info 2010-09-07 11:13:00 +01:00
i915_gem_debug.c drm/i915: drop pointer to drm_gem_object 2010-04-20 13:23:14 +10:00
i915_gem_evict.c drm/i915: Hold a reference to the object whilst unbinding the eviction list 2010-09-20 20:50:00 +01:00
i915_gem_tiling.c drm: Use ENOENT consistently for the error return for an unmatched handle. 2010-08-10 10:46:55 +10:00
i915_gem.c drm/i915: Fix Sandybridge fence registers 2010-09-17 08:18:30 +01:00
i915_ioc32.c drm: convert drm_ioctl to unlocked_ioctl 2009-12-18 11:22:31 +10:00
i915_irq.c drm/i915: Double check that the wait_request is not pending before warning 2010-09-09 09:18:00 +01:00
i915_mem.c drm: Remove memory debugging infrastructure. 2009-06-18 13:00:33 -07:00
i915_opregion.c Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/anholt/drm-intel 2010-08-22 11:03:27 -07:00
i915_reg.h drm/i915: don't enable self-refresh on Ironlake 2010-09-10 15:11:43 +01:00
i915_suspend.c drm/i915: Fix Sandybridge fence registers 2010-09-17 08:18:30 +01:00
i915_trace_points.c drm/i915: Add tracepoints 2009-09-23 01:05:21 +01:00
i915_trace.h drm/i915: add tracepoints for flip requests & completions 2010-07-02 14:04:14 +10:00
intel_bios.c drm/i915: Honor sync polarity from VBT panel timing descriptors 2010-06-01 10:19:37 -07:00
intel_bios.h drm/i915: parse eDP panel color depth from VBT block 2010-01-15 14:12:47 -08:00
intel_crt.c drm/i915/crt: Downgrade warnings for hotplug failures 2010-09-17 08:05:28 +01:00
intel_display.c drm/i915: Ensure that the crtcinfo is populated during mode_fixup() 2010-09-12 21:20:41 +01:00
intel_dp.c drm/i915/dp: Really try 5 times before giving up. 2010-09-07 11:14:17 +01:00
intel_drv.h drm/i915: Avoid pageflipping freeze when we miss the flip prepare interrupt 2010-09-07 11:16:35 +01:00
intel_dvo.c drm/i915: Subclass intel_encoder. 2010-08-09 11:24:28 -07:00
intel_fb.c Merge branch 'drm-core-next' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6 2010-08-12 09:21:39 -07:00
intel_hdmi.c drm/i915: Subclass intel_encoder. 2010-08-09 11:24:28 -07:00
intel_i2c.c include cleanup: Update gfp.h and slab.h includes to prepare for breaking implicit slab.h inclusion from percpu.h 2010-03-30 22:02:32 +09:00
intel_lvds.c Revert "drm/i915: Allow LVDS on pipe A on gen4+" 2010-09-08 08:41:37 +01:00
intel_modes.c Merge remote branch 'anholt/drm-intel-next' of /home/airlied/kernel/drm-next into drm-core-next 2010-04-20 13:11:45 +10:00
intel_overlay.c drivers/gpu/drm/i915/intel_overlay.c needs seq_file.h 2010-09-06 23:09:48 +01:00
intel_panel.c drm/i915: Enable aspect/centering panel fitting for Ironlake. 2010-08-09 11:24:34 -07:00
intel_ringbuffer.c drm/i915: Enable MI_FLUSH on Sandybridge 2010-09-07 11:16:44 +01:00
intel_ringbuffer.h drm/i915: Use a common seqno for all rings. 2010-08-09 11:24:32 -07:00
intel_sdvo_regs.h drm/i915/sdvo: Add missing TV filters 2010-08-09 11:24:29 -07:00
intel_sdvo.c drm/i915/sdvo: Restore guess of the DDC bus in absence of VBIOS 2010-09-07 11:14:16 +01:00
intel_tv.c i915: Fix spurious TV detection after 9d0498a2bf + 9559fcdbff 2010-09-06 23:09:50 +01:00
Makefile drm/i915: Enable aspect/centering panel fitting for Ironlake. 2010-08-09 11:24:34 -07:00