]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
3.4-stable patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 17 Oct 2012 21:39:08 +0000 (14:39 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 17 Oct 2012 21:39:08 +0000 (14:39 -0700)
added patches:
drm-i915-use-adjusted_mode-instead-of-mode-for-checking-the-6bpc-force-flag.patch
drm-radeon-don-t-destroy-i2c-bus-rec-in-radeon_ext_tmds_enc_destroy.patch

queue-3.4/drm-i915-use-adjusted_mode-instead-of-mode-for-checking-the-6bpc-force-flag.patch [new file with mode: 0644]
queue-3.4/drm-radeon-don-t-destroy-i2c-bus-rec-in-radeon_ext_tmds_enc_destroy.patch [new file with mode: 0644]
queue-3.4/series

diff --git a/queue-3.4/drm-i915-use-adjusted_mode-instead-of-mode-for-checking-the-6bpc-force-flag.patch b/queue-3.4/drm-i915-use-adjusted_mode-instead-of-mode-for-checking-the-6bpc-force-flag.patch
new file mode 100644 (file)
index 0000000..9b63f87
--- /dev/null
@@ -0,0 +1,65 @@
+From 0c96c65b48fba3ffe9822a554cbc0cd610765cd5 Mon Sep 17 00:00:00 2001
+From: Jani Nikula <jani.nikula@intel.com>
+Date: Wed, 26 Sep 2012 18:43:10 +0300
+Subject: drm/i915: use adjusted_mode instead of mode for checking the 6bpc force flag
+
+From: Jani Nikula <jani.nikula@intel.com>
+
+commit 0c96c65b48fba3ffe9822a554cbc0cd610765cd5 upstream.
+
+The dithering introduced in
+
+commit 3b5c78a35cf7511c15e09a9b0ffab290a42d9bcf
+Author: Adam Jackson <ajax@redhat.com>
+Date:   Tue Dec 13 15:41:00 2011 -0800
+
+    drm/i915/dp: Dither down to 6bpc if it makes the mode fit
+
+stores the INTEL_MODE_DP_FORCE_6BPC flag in the private_flags of the
+adjusted mode, while i9xx_crtc_mode_set() and ironlake_crtc_mode_set() use
+the original mode, without the flag, so it would never have any
+effect. However, the BPC was clamped by VBT settings, making things work by
+coincidence, until that part was removed in
+
+commit 4344b813f105a19f793f1fd93ad775b784648b95
+Author: Daniel Vetter <daniel.vetter@ffwll.ch>
+Date:   Fri Aug 10 11:10:20 2012 +0200
+
+Use adjusted_mode instead of mode when checking for
+INTEL_MODE_DP_FORCE_6BPC to make the flag have effect.
+
+v2: Don't forget to fix this in i9xx_crtc_mode_set() also, pointed out by
+Daniel both before and after sending the first patch.
+
+Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=47621
+CC: Adam Jackson <ajax@redhat.com>
+Signed-off-by: Jani Nikula <jani.nikula@intel.com>
+Reviewed-by: Adam Jackson <ajax@redhat.com>
+Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+
+---
+ drivers/gpu/drm/i915/intel_display.c |    4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+--- a/drivers/gpu/drm/i915/intel_display.c
++++ b/drivers/gpu/drm/i915/intel_display.c
+@@ -5318,7 +5318,7 @@ static int i9xx_crtc_mode_set(struct drm
+       /* default to 8bpc */
+       pipeconf &= ~(PIPECONF_BPP_MASK | PIPECONF_DITHER_EN);
+       if (is_dp) {
+-              if (mode->private_flags & INTEL_MODE_DP_FORCE_6BPC) {
++              if (adjusted_mode->private_flags & INTEL_MODE_DP_FORCE_6BPC) {
+                       pipeconf |= PIPECONF_BPP_6 |
+                                   PIPECONF_DITHER_EN |
+                                   PIPECONF_DITHER_TYPE_SP;
+@@ -5782,7 +5782,7 @@ static int ironlake_crtc_mode_set(struct
+       /* determine panel color depth */
+       temp = I915_READ(PIPECONF(pipe));
+       temp &= ~PIPE_BPC_MASK;
+-      dither = intel_choose_pipe_bpp_dither(crtc, &pipe_bpp, mode);
++      dither = intel_choose_pipe_bpp_dither(crtc, &pipe_bpp, adjusted_mode);
+       switch (pipe_bpp) {
+       case 18:
+               temp |= PIPE_6BPC;
diff --git a/queue-3.4/drm-radeon-don-t-destroy-i2c-bus-rec-in-radeon_ext_tmds_enc_destroy.patch b/queue-3.4/drm-radeon-don-t-destroy-i2c-bus-rec-in-radeon_ext_tmds_enc_destroy.patch
new file mode 100644 (file)
index 0000000..4320c42
--- /dev/null
@@ -0,0 +1,44 @@
+From 082918471139b07964967cfe5f70230909c82ae1 Mon Sep 17 00:00:00 2001
+From: Egbert Eich <eich@suse.de>
+Date: Mon, 15 Oct 2012 08:21:39 +0200
+Subject: drm/radeon: Don't destroy I2C Bus Rec in radeon_ext_tmds_enc_destroy().
+
+From: Egbert Eich <eich@suse.de>
+
+commit 082918471139b07964967cfe5f70230909c82ae1 upstream.
+
+radeon_i2c_fini() walks thru the list of I2C bus recs rdev->i2c_bus[]
+to destroy each of them.
+radeon_ext_tmds_enc_destroy() however also has code to destroy it's
+associated I2C bus rec which has been obtained by radeon_i2c_lookup()
+and is therefore also in the i2c_bus[] list.
+This causes a double free resulting in a kernel panic when unloading
+the radeon driver.
+Removing destroy code from radeon_ext_tmds_enc_destroy() fixes this
+problem.
+
+agd5f: fix compiler warning
+
+Signed-off-by: Egbert Eich <eich@suse.de>
+Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/gpu/drm/radeon/radeon_legacy_encoders.c |    6 +-----
+ 1 file changed, 1 insertion(+), 5 deletions(-)
+
+--- a/drivers/gpu/drm/radeon/radeon_legacy_encoders.c
++++ b/drivers/gpu/drm/radeon/radeon_legacy_encoders.c
+@@ -973,11 +973,7 @@ static void radeon_legacy_tmds_ext_mode_
+ static void radeon_ext_tmds_enc_destroy(struct drm_encoder *encoder)
+ {
+       struct radeon_encoder *radeon_encoder = to_radeon_encoder(encoder);
+-      struct radeon_encoder_ext_tmds *tmds = radeon_encoder->enc_priv;
+-      if (tmds) {
+-              if (tmds->i2c_bus)
+-                      radeon_i2c_destroy(tmds->i2c_bus);
+-      }
++      /* don't destroy the i2c bus record here, this will be done in radeon_i2c_fini */
+       kfree(radeon_encoder->enc_priv);
+       drm_encoder_cleanup(encoder);
+       kfree(radeon_encoder);
index 256ade9677b530aef1f340f6b399ddcd9887fb9a..a4bfd644d738ebb6c0f858cca5c78d6a25d9c92f 100644 (file)
@@ -42,3 +42,5 @@ netfilter-nf_ct_expect-fix-possible-access-to-uninitialized-timer.patch
 netfilter-limit-hashlimit-avoid-duplicated-inline.patch
 netfilter-xt_limit-have-r-cost-0-case-work.patch
 add-cdc-acm-support-for-the-cx93010-2x-ucmxx-usb-modem.patch
+drm-radeon-don-t-destroy-i2c-bus-rec-in-radeon_ext_tmds_enc_destroy.patch
+drm-i915-use-adjusted_mode-instead-of-mode-for-checking-the-6bpc-force-flag.patch