linux-uconsole/drivers/gpu/drm/i915
Daniel Vetter 85bf36e048 drm/i915: fix tiling limits for i915 class hw v2
commit c36a2a6de5 upstream.

Current code is definitely crap: Largest pitch allowed spills into
the TILING_Y bit of the fence registers ... :(

I've rewritten the limits check under the assumption that 3rd gen hw
has a 3d pitch limit of 8kb (like 2nd gen). This is supported by an
otherwise totally misleading XXX comment.

This bug mostly resulted in tiling-corrupted pixmaps because the kernel
allowed too wide buffers to be tiled. Bug brought to the light by the
xf86-video-intel 2.11 release because that unconditionally enabled
tiling for pixmaps, relying on the kernel to check things. Tiling for
the framebuffer was not affected because the ddx does some additional
checks there ensure the buffer is within hw-limits.

v2: Instead of computing the value that would be written into the
hw fence registers and then checking the limits simply check whether
the stride is above the 8kb limit. To better document the hw, add
some WARN_ONs in i915_write_fence_reg like I've done for the i830
case (using the right limits).

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=27449
Tested-by: Alexander Lam <lambchop468@gmail.com>
Signed-off-by: Eric Anholt <eric@anholt.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-05-12 14:57:10 -07:00
..
dvo.h drm/i915: Change I2C api to pass around i2c_adapters 2009-06-18 15:53:57 -07:00
dvo_ch7xxx.c drm/i915: Change I2C api to pass around i2c_adapters 2009-06-18 15:53:57 -07:00
dvo_ch7017.c drm/i915: Change I2C api to pass around i2c_adapters 2009-06-18 15:53:57 -07:00
dvo_ivch.c drm/i915: Change I2C api to pass around i2c_adapters 2009-06-18 15:53:57 -07:00
dvo_sil164.c drm/i915: Change I2C api to pass around i2c_adapters 2009-06-18 15:53:57 -07:00
dvo_tfp410.c drm/i915: Change I2C api to pass around i2c_adapters 2009-06-18 15:53:57 -07:00
i915_debugfs.c drm/i915: remove full registers dump debug 2010-02-23 07:37:53 -08:00
i915_dma.c drm/i915: only enable hotplug for detected outputs 2010-02-09 04:50:52 -08:00
i915_drv.c i915: fix intel graphics suspend breakage due to resume/lid event confusion 2009-11-02 09:29:55 -08:00
i915_drv.h drm/i915: fix gpio register detection logic for BIOS without VBT 2010-04-01 15:58:02 -07:00
i915_gem.c drm/i915: fix tiling limits for i915 class hw v2 2010-05-12 14:57:10 -07:00
i915_gem_debug.c drm/i915: Catch up to obj_priv->page_list rename in disabled debug code. 2009-06-22 20:19:39 -07:00
i915_gem_tiling.c drm/i915: fix tiling limits for i915 class hw v2 2010-05-12 14:57:10 -07:00
i915_ioc32.c
i915_irq.c drm/i915: only enable hotplug for detected outputs 2010-02-09 04:50:52 -08:00
i915_mem.c drm: Remove memory debugging infrastructure. 2009-06-18 13:00:33 -07:00
i915_opregion.c drm/i915: fix opregion backlight chip detect and range 2009-09-17 14:32:08 -07:00
i915_reg.h drm/i915: fix tiling limits for i915 class hw v2 2010-05-12 14:57:10 -07:00
i915_suspend.c drm/i915: Fix DDC on some systems by clearing BIOS GMBUS setup. 2010-02-23 07:37:47 -08:00
i915_trace.h drm/i915: Enable irq to trace batch buffer completion. 2009-09-29 03:15:25 +01:00
i915_trace_points.c drm/i915: Add tracepoints 2009-09-23 01:05:21 +01:00
intel_bios.c drm/i915: fix gpio register detection logic for BIOS without VBT 2010-04-01 15:58:02 -07:00
intel_bios.h drm/i915: Add eDP support on IGDNG mobile chip 2009-07-29 15:16:19 -07:00
intel_crt.c drm/i915: fix gpio register detection logic for BIOS without VBT 2010-04-01 15:58:02 -07:00
intel_display.c drm/i915: fix get_core_clock_speed for G33 class desktop chips 2010-03-15 08:49:41 -07:00
intel_dp.c drm/i915: only enable hotplug for detected outputs 2010-02-09 04:50:52 -08:00
intel_dp.h drm/i915: Add Display Port support 2009-06-18 15:54:07 -07:00
intel_dp_i2c.c drm/i915: Make driver less chatty 2009-07-01 18:13:34 -07:00
intel_drv.h drm/i915: Fix DDC on some systems by clearing BIOS GMBUS setup. 2010-02-23 07:37:47 -08:00
intel_dvo.c drm/i915: Set crtc/clone mask in different output devices 2009-08-24 17:01:33 -07:00
intel_fb.c drm/i915: Increase fb alignment to 64k 2010-02-23 07:37:48 -08:00
intel_hdmi.c drm/i915: only enable hotplug for detected outputs 2010-02-09 04:50:52 -08:00
intel_i2c.c drm/i915: Fix DDC on some systems by clearing BIOS GMBUS setup. 2010-02-23 07:37:47 -08:00
intel_lvds.c drm/i915: Add no_lvds entry for the Clientron U800 2010-04-26 07:41:26 -07:00
intel_modes.c drm/i915: Change I2C api to pass around i2c_adapters 2009-06-18 15:53:57 -07:00
intel_sdvo.c drm/i915: Use a dmi quirk to skip a broken SDVO TV output. 2010-03-15 08:50:12 -07:00
intel_sdvo_regs.h drm/i915: enable sdvo lvds scaling function. 2009-07-01 11:44:45 -07:00
intel_tv.c drm/i915: disable TV hotplug status check 2010-03-15 08:49:41 -07:00
Makefile drm/i915: Add tracepoints 2009-09-23 01:05:21 +01:00