From: Greg Kroah-Hartman Date: Mon, 16 Mar 2015 13:20:01 +0000 (+0100) Subject: 3.19-stable patches X-Git-Tag: v3.10.72~6 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=d177b8381b28f7b083630e25b537ab61076ec4eb;p=thirdparty%2Fkernel%2Fstable-queue.git 3.19-stable patches added patches: acpi-lpss-provide-con_id-for-the-clkdev.patch acpi-video-load-the-module-even-if-acpi-is-disabled.patch drm-i915-avoid-processing-spurious-shared-interrupts-in-low-power-states.patch drm-i915-bdw-pci-ids-ending-in-0xb-are-ult.patch drm-i915-check-for-driver-readyness-before-handling-an-underrun-interrupt.patch drm-i915-check-obj-vma_list-under-the-struct_mutex.patch drm-i915-dell-chromebook-11-has-pwm-backlight.patch drm-radeon-enable-native-backlight-control-on-old-macs.patch drm-radeon-fix-1-rb-harvest-config-setup-for-tn-rl.patch drm-radeon-use-drm_mode_vrefresh-rather-than-mode-vrefresh.patch ecryptfs-don-t-pass-fs-specific-ioctl-commands-through.patch efi-libstub-fix-boundary-checking-in-efi_high_alloc.patch efi-small-leak-on-error-in-runtime-map-code.patch nfsd-fix-clp-cl_revoked-list-deletion-causing-softlock-in-nfsd.patch reservation-remove-shadowing-local-variable-ret.patch --- diff --git a/queue-3.19/acpi-lpss-provide-con_id-for-the-clkdev.patch b/queue-3.19/acpi-lpss-provide-con_id-for-the-clkdev.patch new file mode 100644 index 00000000000..3dbd2b177ac --- /dev/null +++ b/queue-3.19/acpi-lpss-provide-con_id-for-the-clkdev.patch @@ -0,0 +1,62 @@ +From fcf0789a96777d79d20290e08bf43943a5619387 Mon Sep 17 00:00:00 2001 +From: Heikki Krogerus +Date: Fri, 6 Mar 2015 15:48:38 +0200 +Subject: ACPI / LPSS: provide con_id for the clkdev + +From: Heikki Krogerus + +commit fcf0789a96777d79d20290e08bf43943a5619387 upstream. + +Commit 7d78cbefaa (serial: 8250_dw: add ability to handle +the peripheral clock) introduces handling for a second clk +to 8250_dw.c which is the driver also for LPSS UART. The +second clk forces us to provide identifier (con_id) for the +clkdev we create. + +This fixes an issue where 8250_dw.c is getting the same +handler for both clocks. + +Fixes: 7d78cbefaa (serial: 8250_dw: add ability to handle the peripheral clock) +Signed-off-by: Heikki Krogerus +Signed-off-by: Rafael J. Wysocki +Signed-off-by: Greg Kroah-Hartman + +--- + drivers/acpi/acpi_lpss.c | 5 ++++- + 1 file changed, 4 insertions(+), 1 deletion(-) + +--- a/drivers/acpi/acpi_lpss.c ++++ b/drivers/acpi/acpi_lpss.c +@@ -65,6 +65,7 @@ struct lpss_private_data; + + struct lpss_device_desc { + unsigned int flags; ++ const char *clk_con_id; + unsigned int prv_offset; + size_t prv_size_override; + void (*setup)(struct lpss_private_data *pdata); +@@ -140,6 +141,7 @@ static struct lpss_device_desc lpt_i2c_d + + static struct lpss_device_desc lpt_uart_dev_desc = { + .flags = LPSS_CLK | LPSS_CLK_GATE | LPSS_CLK_DIVIDER | LPSS_LTR, ++ .clk_con_id = "baudclk", + .prv_offset = 0x800, + .setup = lpss_uart_setup, + }; +@@ -156,6 +158,7 @@ static struct lpss_device_desc byt_pwm_d + + static struct lpss_device_desc byt_uart_dev_desc = { + .flags = LPSS_CLK | LPSS_CLK_GATE | LPSS_CLK_DIVIDER | LPSS_SAVE_CTX, ++ .clk_con_id = "baudclk", + .prv_offset = 0x800, + .setup = lpss_uart_setup, + }; +@@ -313,7 +316,7 @@ out: + return PTR_ERR(clk); + + pdata->clk = clk; +- clk_register_clkdev(clk, NULL, devname); ++ clk_register_clkdev(clk, dev_desc->clk_con_id, devname); + return 0; + } + diff --git a/queue-3.19/acpi-video-load-the-module-even-if-acpi-is-disabled.patch b/queue-3.19/acpi-video-load-the-module-even-if-acpi-is-disabled.patch new file mode 100644 index 00000000000..56ee547a482 --- /dev/null +++ b/queue-3.19/acpi-video-load-the-module-even-if-acpi-is-disabled.patch @@ -0,0 +1,48 @@ +From 6e17cb12881ba8d5e456b89f072dc6b70048af36 Mon Sep 17 00:00:00 2001 +From: Chris Wilson +Date: Sun, 1 Mar 2015 10:41:37 +0000 +Subject: ACPI / video: Load the module even if ACPI is disabled + +From: Chris Wilson + +commit 6e17cb12881ba8d5e456b89f072dc6b70048af36 upstream. + +i915.ko depends upon the acpi/video.ko module and so refuses to load if +ACPI is disabled at runtime if for example the BIOS is broken beyond +repair. acpi/video provides an optional service for i915.ko and so we +should just allow the modules to load, but do no nothing in order to let +the machines boot correctly. + +Reported-by: Bill Augur +Signed-off-by: Chris Wilson +Cc: Daniel Vetter +Cc: Jani Nikula +Acked-by: Aaron Lu +[ rjw: Fixed up the new comment in acpi_video_init() ] +Signed-off-by: Rafael J. Wysocki +Signed-off-by: Greg Kroah-Hartman + +--- + drivers/acpi/video.c | 11 +++++++++++ + 1 file changed, 11 insertions(+) + +--- a/drivers/acpi/video.c ++++ b/drivers/acpi/video.c +@@ -2149,6 +2149,17 @@ EXPORT_SYMBOL(acpi_video_unregister_back + + static int __init acpi_video_init(void) + { ++ /* ++ * Let the module load even if ACPI is disabled (e.g. due to ++ * a broken BIOS) so that i915.ko can still be loaded on such ++ * old systems without an AcpiOpRegion. ++ * ++ * acpi_video_register() will report -ENODEV later as well due ++ * to acpi_disabled when i915.ko tries to register itself afterwards. ++ */ ++ if (acpi_disabled) ++ return 0; ++ + dmi_check_system(video_dmi_table); + + if (intel_opregion_present()) diff --git a/queue-3.19/drm-i915-avoid-processing-spurious-shared-interrupts-in-low-power-states.patch b/queue-3.19/drm-i915-avoid-processing-spurious-shared-interrupts-in-low-power-states.patch new file mode 100644 index 00000000000..8ef42eed0f9 --- /dev/null +++ b/queue-3.19/drm-i915-avoid-processing-spurious-shared-interrupts-in-low-power-states.patch @@ -0,0 +1,138 @@ +From 2dd2a883aad7c852400027c2261bcab69d9e238e Mon Sep 17 00:00:00 2001 +From: Imre Deak +Date: Tue, 24 Feb 2015 11:14:30 +0200 +Subject: drm/i915: avoid processing spurious/shared interrupts in low-power states + +From: Imre Deak + +commit 2dd2a883aad7c852400027c2261bcab69d9e238e upstream. + +Atm, it's possible that the interrupt handler is called when the device +is in D3 or some other low-power state. It can be due to another device +that is still in D0 state and shares the interrupt line with i915, or on +some platforms there could be spurious interrupts even without sharing +the interrupt line. The latter case was reported by Klaus Ethgen using a +Lenovo x61p machine (gen 4). He noticed this issue via a system +suspend/resume hang and bisected it to the following commit: + +commit e11aa362308f5de467ce355a2a2471321b15a35c +Author: Jesse Barnes +Date: Wed Jun 18 09:52:55 2014 -0700 + + drm/i915: use runtime irq suspend/resume in freeze/thaw + +This is a problem, since in low-power states IIR will always read +0xffffffff resulting in an endless IRQ servicing loop. + +Fix this by handling interrupts only when the driver explicitly enables +them and so it's guaranteed that the interrupt registers return a valid +value. + +Note that this issue existed even before the above commit, since during +runtime suspend/resume we never unregistered the handler. + +v2: +- clarify the purpose of smp_mb() vs. synchronize_irq() in the + code comment (Chris) + +v3: +- no need for an explicit smp_mb(), we can assume that synchronize_irq() + and the mmio read/writes in the install hooks provide for this (Daniel) +- remove code comment as the remaining synchronize_irq() is self + explanatory (Daniel) + +v4: +- drm_irq_uninstall() implies synchronize_irq(), so no need to call it + explicitly (Daniel) + +Reference: https://lkml.org/lkml/2015/2/11/205 +Reported-and-bisected-by: Klaus Ethgen +Signed-off-by: Imre Deak +Reviewed-by: Daniel Vetter +Signed-off-by: Jani Nikula +Signed-off-by: Greg Kroah-Hartman + +--- + drivers/gpu/drm/i915/i915_irq.c | 22 ++++++++++++++++++++++ + 1 file changed, 22 insertions(+) + +--- a/drivers/gpu/drm/i915/i915_irq.c ++++ b/drivers/gpu/drm/i915/i915_irq.c +@@ -1884,6 +1884,9 @@ static irqreturn_t valleyview_irq_handle + u32 iir, gt_iir, pm_iir; + irqreturn_t ret = IRQ_NONE; + ++ if (!intel_irqs_enabled(dev_priv)) ++ return IRQ_NONE; ++ + while (true) { + /* Find, clear, then process each source of interrupt */ + +@@ -1928,6 +1931,9 @@ static irqreturn_t cherryview_irq_handle + u32 master_ctl, iir; + irqreturn_t ret = IRQ_NONE; + ++ if (!intel_irqs_enabled(dev_priv)) ++ return IRQ_NONE; ++ + for (;;) { + master_ctl = I915_READ(GEN8_MASTER_IRQ) & ~GEN8_MASTER_IRQ_CONTROL; + iir = I915_READ(VLV_IIR); +@@ -2200,6 +2206,9 @@ static irqreturn_t ironlake_irq_handler( + u32 de_iir, gt_iir, de_ier, sde_ier = 0; + irqreturn_t ret = IRQ_NONE; + ++ if (!intel_irqs_enabled(dev_priv)) ++ return IRQ_NONE; ++ + /* We get interrupts on unclaimed registers, so check for this before we + * do any I915_{READ,WRITE}. */ + intel_uncore_check_errors(dev); +@@ -2271,6 +2280,9 @@ static irqreturn_t gen8_irq_handler(int + enum pipe pipe; + u32 aux_mask = GEN8_AUX_CHANNEL_A; + ++ if (!intel_irqs_enabled(dev_priv)) ++ return IRQ_NONE; ++ + if (IS_GEN9(dev)) + aux_mask |= GEN9_AUX_CHANNEL_B | GEN9_AUX_CHANNEL_C | + GEN9_AUX_CHANNEL_D; +@@ -3770,6 +3782,9 @@ static irqreturn_t i8xx_irq_handler(int + I915_DISPLAY_PLANE_A_FLIP_PENDING_INTERRUPT | + I915_DISPLAY_PLANE_B_FLIP_PENDING_INTERRUPT; + ++ if (!intel_irqs_enabled(dev_priv)) ++ return IRQ_NONE; ++ + iir = I915_READ16(IIR); + if (iir == 0) + return IRQ_NONE; +@@ -3950,6 +3965,9 @@ static irqreturn_t i915_irq_handler(int + I915_DISPLAY_PLANE_B_FLIP_PENDING_INTERRUPT; + int pipe, ret = IRQ_NONE; + ++ if (!intel_irqs_enabled(dev_priv)) ++ return IRQ_NONE; ++ + iir = I915_READ(IIR); + do { + bool irq_received = (iir & ~flip_mask) != 0; +@@ -4172,6 +4190,9 @@ static irqreturn_t i965_irq_handler(int + I915_DISPLAY_PLANE_A_FLIP_PENDING_INTERRUPT | + I915_DISPLAY_PLANE_B_FLIP_PENDING_INTERRUPT; + ++ if (!intel_irqs_enabled(dev_priv)) ++ return IRQ_NONE; ++ + iir = I915_READ(IIR); + + for (;;) { +@@ -4523,6 +4544,7 @@ void intel_runtime_pm_disable_interrupts + { + dev_priv->dev->driver->irq_uninstall(dev_priv->dev); + dev_priv->pm.irqs_enabled = false; ++ synchronize_irq(dev_priv->dev->irq); + } + + /** diff --git a/queue-3.19/drm-i915-bdw-pci-ids-ending-in-0xb-are-ult.patch b/queue-3.19/drm-i915-bdw-pci-ids-ending-in-0xb-are-ult.patch new file mode 100644 index 00000000000..bf70587caf9 --- /dev/null +++ b/queue-3.19/drm-i915-bdw-pci-ids-ending-in-0xb-are-ult.patch @@ -0,0 +1,49 @@ +From 0dc6f20b9803f09726bbb682649d35cda8ef5b5d Mon Sep 17 00:00:00 2001 +From: Rodrigo Vivi +Date: Wed, 21 Jan 2015 11:46:32 -0800 +Subject: drm/i915/bdw: PCI IDs ending in 0xb are ULT. + +From: Rodrigo Vivi + +commit 0dc6f20b9803f09726bbb682649d35cda8ef5b5d upstream. + +When reviewing patch that fixes VGA on BDW Halo Jani noticed that +we also had other ULT IDs that weren't listed there. + +So this follow-up patch add these pci-ids as halo and fix comments +on i915_pciids.h + +Cc: Jani Nikula +Signed-off-by: Rodrigo Vivi +Signed-off-by: Jani Nikula +Signed-off-by: Greg Kroah-Hartman + +--- + drivers/gpu/drm/i915/i915_drv.h | 1 + + include/drm/i915_pciids.h | 4 ++-- + 2 files changed, 3 insertions(+), 2 deletions(-) + +--- a/drivers/gpu/drm/i915/i915_drv.h ++++ b/drivers/gpu/drm/i915/i915_drv.h +@@ -2160,6 +2160,7 @@ struct drm_i915_cmd_table { + (INTEL_DEVID(dev) & 0xFF00) == 0x0C00) + #define IS_BDW_ULT(dev) (IS_BROADWELL(dev) && \ + ((INTEL_DEVID(dev) & 0xf) == 0x6 || \ ++ (INTEL_DEVID(dev) & 0xf) == 0xb || \ + (INTEL_DEVID(dev) & 0xf) == 0xe)) + #define IS_BDW_GT3(dev) (IS_BROADWELL(dev) && \ + (INTEL_DEVID(dev) & 0x00F0) == 0x0020) +--- a/include/drm/i915_pciids.h ++++ b/include/drm/i915_pciids.h +@@ -214,9 +214,9 @@ + INTEL_VGA_DEVICE((((gt) - 1) << 4) | (id), info) + + #define _INTEL_BDW_M_IDS(gt, info) \ +- _INTEL_BDW_M(gt, 0x1602, info), /* ULT */ \ ++ _INTEL_BDW_M(gt, 0x1602, info), /* Halo */ \ + _INTEL_BDW_M(gt, 0x1606, info), /* ULT */ \ +- _INTEL_BDW_M(gt, 0x160B, info), /* Iris */ \ ++ _INTEL_BDW_M(gt, 0x160B, info), /* ULT */ \ + _INTEL_BDW_M(gt, 0x160E, info) /* ULX */ + + #define _INTEL_BDW_D_IDS(gt, info) \ diff --git a/queue-3.19/drm-i915-check-for-driver-readyness-before-handling-an-underrun-interrupt.patch b/queue-3.19/drm-i915-check-for-driver-readyness-before-handling-an-underrun-interrupt.patch new file mode 100644 index 00000000000..2ace61aea67 --- /dev/null +++ b/queue-3.19/drm-i915-check-for-driver-readyness-before-handling-an-underrun-interrupt.patch @@ -0,0 +1,67 @@ +From 54fc7c1c961cb39edfe31f8a3f5ba6414e134b37 Mon Sep 17 00:00:00 2001 +From: Chris Wilson +Date: Thu, 26 Feb 2015 15:53:02 +0000 +Subject: drm/i915: Check for driver readyness before handling an underrun interrupt + +From: Chris Wilson + +commit 54fc7c1c961cb39edfe31f8a3f5ba6414e134b37 upstream. + +When we takeover from the BIOS and install our interrupt handler, the +BIOS may have left us a few surprises in the form of spontaneous +interrupts. (This is especially likely on hardware like 965gm where +display fifo underruns are continuous and the GMCH cannot filter that +interrupt souce.) As we enable our IRQ early so that we can use it +during hardware probing, our interrupt handler must be prepared to +handle a few sources prior to being fully configured. As such, we need +to add a simple is-ready check prior to dereferencing our KMS state for +reporting underruns. + +Reported-by: Rob Clark +Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=1193972 +Signed-off-by: Chris Wilson +Reviewed-by: Daniel Vetter +[Jani: dropped the extra !] +Signed-off-by: Jani Nikula +Signed-off-by: Greg Kroah-Hartman + +--- + drivers/gpu/drm/i915/intel_fifo_underrun.c | 18 +++++++----------- + 1 file changed, 7 insertions(+), 11 deletions(-) + +--- a/drivers/gpu/drm/i915/intel_fifo_underrun.c ++++ b/drivers/gpu/drm/i915/intel_fifo_underrun.c +@@ -282,16 +282,6 @@ bool intel_set_cpu_fifo_underrun_reporti + return ret; + } + +-static bool +-__cpu_fifo_underrun_reporting_enabled(struct drm_i915_private *dev_priv, +- enum pipe pipe) +-{ +- struct drm_crtc *crtc = dev_priv->pipe_to_crtc_mapping[pipe]; +- struct intel_crtc *intel_crtc = to_intel_crtc(crtc); +- +- return !intel_crtc->cpu_fifo_underrun_disabled; +-} +- + /** + * intel_set_pch_fifo_underrun_reporting - set PCH fifo underrun reporting state + * @dev_priv: i915 device instance +@@ -352,9 +342,15 @@ bool intel_set_pch_fifo_underrun_reporti + void intel_cpu_fifo_underrun_irq_handler(struct drm_i915_private *dev_priv, + enum pipe pipe) + { ++ struct drm_crtc *crtc = dev_priv->pipe_to_crtc_mapping[pipe]; ++ ++ /* We may be called too early in init, thanks BIOS! */ ++ if (crtc == NULL) ++ return; ++ + /* GMCH can't disable fifo underruns, filter them. */ + if (HAS_GMCH_DISPLAY(dev_priv->dev) && +- !__cpu_fifo_underrun_reporting_enabled(dev_priv, pipe)) ++ to_intel_crtc(crtc)->cpu_fifo_underrun_disabled) + return; + + if (intel_set_cpu_fifo_underrun_reporting(dev_priv, pipe, false)) diff --git a/queue-3.19/drm-i915-check-obj-vma_list-under-the-struct_mutex.patch b/queue-3.19/drm-i915-check-obj-vma_list-under-the-struct_mutex.patch new file mode 100644 index 00000000000..e32f7d34ebd --- /dev/null +++ b/queue-3.19/drm-i915-check-obj-vma_list-under-the-struct_mutex.patch @@ -0,0 +1,61 @@ +From 6c31a614c43ae274546f736b2a33363e149c3dc2 Mon Sep 17 00:00:00 2001 +From: Chris Wilson +Date: Thu, 12 Feb 2015 07:53:18 +0000 +Subject: drm/i915: Check obj->vma_list under the struct_mutex + +From: Chris Wilson + +commit 6c31a614c43ae274546f736b2a33363e149c3dc2 upstream. + +When we walk the list of vma, or even for protecting against concurrent +framebuffer creation, we must hold the struct_mutex or else a second +thread can corrupt the list as we walk it. + +Fixes regression from +commit d7f46fc4e7323887494db13f063a8e59861fefb0 +Author: Ben Widawsky +Date: Fri Dec 6 14:10:55 2013 -0800 + + drm/i915: Make pin count per VMA + +References: https://bugs.freedesktop.org/show_bug.cgi?id=89085 +Signed-off-by: Chris Wilson +Reviewed-by: Daniel Vetter +Signed-off-by: Jani Nikula +Signed-off-by: Greg Kroah-Hartman + +--- + drivers/gpu/drm/i915/i915_gem_tiling.c | 7 ++++--- + 1 file changed, 4 insertions(+), 3 deletions(-) + +--- a/drivers/gpu/drm/i915/i915_gem_tiling.c ++++ b/drivers/gpu/drm/i915/i915_gem_tiling.c +@@ -335,9 +335,10 @@ i915_gem_set_tiling(struct drm_device *d + return -EINVAL; + } + ++ mutex_lock(&dev->struct_mutex); + if (i915_gem_obj_is_pinned(obj) || obj->framebuffer_references) { +- drm_gem_object_unreference_unlocked(&obj->base); +- return -EBUSY; ++ ret = -EBUSY; ++ goto err; + } + + if (args->tiling_mode == I915_TILING_NONE) { +@@ -369,7 +370,6 @@ i915_gem_set_tiling(struct drm_device *d + } + } + +- mutex_lock(&dev->struct_mutex); + if (args->tiling_mode != obj->tiling_mode || + args->stride != obj->stride) { + /* We need to rebind the object if its current allocation +@@ -424,6 +424,7 @@ i915_gem_set_tiling(struct drm_device *d + obj->bit_17 = NULL; + } + ++err: + drm_gem_object_unreference(&obj->base); + mutex_unlock(&dev->struct_mutex); + diff --git a/queue-3.19/drm-i915-dell-chromebook-11-has-pwm-backlight.patch b/queue-3.19/drm-i915-dell-chromebook-11-has-pwm-backlight.patch new file mode 100644 index 00000000000..368d10714bc --- /dev/null +++ b/queue-3.19/drm-i915-dell-chromebook-11-has-pwm-backlight.patch @@ -0,0 +1,33 @@ +From cf6f0af9fbdd90b81af14fa6375387131cd8adf1 Mon Sep 17 00:00:00 2001 +From: Jani Nikula +Date: Thu, 19 Feb 2015 10:53:39 +0200 +Subject: drm/i915: Dell Chromebook 11 has PWM backlight + +From: Jani Nikula + +commit cf6f0af9fbdd90b81af14fa6375387131cd8adf1 upstream. + +Add quirk for Dell Chromebook 11 backlight. + +Reported-and-tested-by: Owen Garland +Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=93451 +Acked-by: Damien Lespiau +Signed-off-by: Jani Nikula +Signed-off-by: Greg Kroah-Hartman + +--- + drivers/gpu/drm/i915/intel_display.c | 3 +++ + 1 file changed, 3 insertions(+) + +--- a/drivers/gpu/drm/i915/intel_display.c ++++ b/drivers/gpu/drm/i915/intel_display.c +@@ -13019,6 +13019,9 @@ static struct intel_quirk intel_quirks[] + + /* HP Chromebook 14 (Celeron 2955U) */ + { 0x0a06, 0x103c, 0x21ed, quirk_backlight_present }, ++ ++ /* Dell Chromebook 11 */ ++ { 0x0a06, 0x1028, 0x0a35, quirk_backlight_present }, + }; + + static void intel_init_quirks(struct drm_device *dev) diff --git a/queue-3.19/drm-radeon-enable-native-backlight-control-on-old-macs.patch b/queue-3.19/drm-radeon-enable-native-backlight-control-on-old-macs.patch new file mode 100644 index 00000000000..ac67b6bccaf --- /dev/null +++ b/queue-3.19/drm-radeon-enable-native-backlight-control-on-old-macs.patch @@ -0,0 +1,37 @@ +From 7a26f9ad1b5badfd0200ce2262ad696e2a6b7fbb Mon Sep 17 00:00:00 2001 +From: "Nathan-J. Hirschauer" +Date: Wed, 18 Feb 2015 02:01:19 +0100 +Subject: drm/radeon: enable native backlight control on old macs + +From: "Nathan-J. Hirschauer" + +commit 7a26f9ad1b5badfd0200ce2262ad696e2a6b7fbb upstream. + +Commit b7bc596ebbe0 ("drm/radeon: disable native +backlight control on pre-r6xx asics (v2)") accidently +broke backlight control on old mac laptops that use the +on-GPU backlight controller. + +Signed-off-by: Nathan-J. Hirschauer +Signed-off-by: Alex Deucher +Signed-off-by: Greg Kroah-Hartman + +--- + drivers/gpu/drm/radeon/radeon_encoders.c | 3 +++ + 1 file changed, 3 insertions(+) + +--- a/drivers/gpu/drm/radeon/radeon_encoders.c ++++ b/drivers/gpu/drm/radeon/radeon_encoders.c +@@ -179,9 +179,12 @@ static void radeon_encoder_add_backlight + (rdev->pdev->subsystem_vendor == 0x1734) && + (rdev->pdev->subsystem_device == 0x1107)) + use_bl = false; ++/* Older PPC macs use on-GPU backlight controller */ ++#ifndef CONFIG_PPC_PMAC + /* disable native backlight control on older asics */ + else if (rdev->family < CHIP_R600) + use_bl = false; ++#endif + else + use_bl = true; + } diff --git a/queue-3.19/drm-radeon-fix-1-rb-harvest-config-setup-for-tn-rl.patch b/queue-3.19/drm-radeon-fix-1-rb-harvest-config-setup-for-tn-rl.patch new file mode 100644 index 00000000000..1b308a160cb --- /dev/null +++ b/queue-3.19/drm-radeon-fix-1-rb-harvest-config-setup-for-tn-rl.patch @@ -0,0 +1,38 @@ +From dbfb00c3e7e18439f2ebf67fe99bf7a50b5bae1e Mon Sep 17 00:00:00 2001 +From: Alex Deucher +Date: Thu, 19 Feb 2015 16:02:15 -0500 +Subject: drm/radeon: fix 1 RB harvest config setup for TN/RL + +From: Alex Deucher + +commit dbfb00c3e7e18439f2ebf67fe99bf7a50b5bae1e upstream. + +The logic was reversed from what the hw actually exposed. +Fixes graphics corruption in certain harvest configurations. + +Signed-off-by: Alex Deucher +Signed-off-by: Greg Kroah-Hartman + +--- + drivers/gpu/drm/radeon/ni.c | 8 ++++---- + 1 file changed, 4 insertions(+), 4 deletions(-) + +--- a/drivers/gpu/drm/radeon/ni.c ++++ b/drivers/gpu/drm/radeon/ni.c +@@ -1085,12 +1085,12 @@ static void cayman_gpu_init(struct radeo + + if ((rdev->config.cayman.max_backends_per_se == 1) && + (rdev->flags & RADEON_IS_IGP)) { +- if ((disabled_rb_mask & 3) == 1) { +- /* RB0 disabled, RB1 enabled */ +- tmp = 0x11111111; +- } else { ++ if ((disabled_rb_mask & 3) == 2) { + /* RB1 disabled, RB0 enabled */ + tmp = 0x00000000; ++ } else { ++ /* RB0 disabled, RB1 enabled */ ++ tmp = 0x11111111; + } + } else { + tmp = gb_addr_config & NUM_PIPES_MASK; diff --git a/queue-3.19/drm-radeon-use-drm_mode_vrefresh-rather-than-mode-vrefresh.patch b/queue-3.19/drm-radeon-use-drm_mode_vrefresh-rather-than-mode-vrefresh.patch new file mode 100644 index 00000000000..b1c0ee3d18c --- /dev/null +++ b/queue-3.19/drm-radeon-use-drm_mode_vrefresh-rather-than-mode-vrefresh.patch @@ -0,0 +1,29 @@ +From 3d2d98ee1af0cf6eebfbd6bff4c17d3601ac1284 Mon Sep 17 00:00:00 2001 +From: Alex Deucher +Date: Wed, 18 Feb 2015 01:05:30 -0500 +Subject: drm/radeon: use drm_mode_vrefresh() rather than mode->vrefresh + +From: Alex Deucher + +commit 3d2d98ee1af0cf6eebfbd6bff4c17d3601ac1284 upstream. + +Just in case it hasn't been calculated for the mode. + +Signed-off-by: Alex Deucher +Signed-off-by: Greg Kroah-Hartman + +--- + drivers/gpu/drm/radeon/r600_dpm.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +--- a/drivers/gpu/drm/radeon/r600_dpm.c ++++ b/drivers/gpu/drm/radeon/r600_dpm.c +@@ -188,7 +188,7 @@ u32 r600_dpm_get_vrefresh(struct radeon_ + list_for_each_entry(crtc, &dev->mode_config.crtc_list, head) { + radeon_crtc = to_radeon_crtc(crtc); + if (crtc->enabled && radeon_crtc->enabled && radeon_crtc->hw_mode.clock) { +- vrefresh = radeon_crtc->hw_mode.vrefresh; ++ vrefresh = drm_mode_vrefresh(&radeon_crtc->hw_mode); + break; + } + } diff --git a/queue-3.19/ecryptfs-don-t-pass-fs-specific-ioctl-commands-through.patch b/queue-3.19/ecryptfs-don-t-pass-fs-specific-ioctl-commands-through.patch new file mode 100644 index 00000000000..92fa061ca63 --- /dev/null +++ b/queue-3.19/ecryptfs-don-t-pass-fs-specific-ioctl-commands-through.patch @@ -0,0 +1,93 @@ +From 6d65261a09adaa374c05de807f73a144d783669e Mon Sep 17 00:00:00 2001 +From: Tyler Hicks +Date: Tue, 24 Feb 2015 19:28:10 -0600 +Subject: eCryptfs: don't pass fs-specific ioctl commands through + +From: Tyler Hicks + +commit 6d65261a09adaa374c05de807f73a144d783669e upstream. + +eCryptfs can't be aware of what to expect when after passing an +arbitrary ioctl command through to the lower filesystem. The ioctl +command may trigger an action in the lower filesystem that is +incompatible with eCryptfs. + +One specific example is when one attempts to use the Btrfs clone +ioctl command when the source file is in the Btrfs filesystem that +eCryptfs is mounted on top of and the destination fd is from a new file +created in the eCryptfs mount. The ioctl syscall incorrectly returns +success because the command is passed down to Btrfs which thinks that it +was able to do the clone operation. However, the result is an empty +eCryptfs file. + +This patch allows the trim, {g,s}etflags, and {g,s}etversion ioctl +commands through and then copies up the inode metadata from the lower +inode to the eCryptfs inode to catch any changes made to the lower +inode's metadata. Those five ioctl commands are mostly common across all +filesystems but the whitelist may need to be further pruned in the +future. + +https://bugzilla.kernel.org/show_bug.cgi?id=93691 +https://launchpad.net/bugs/1305335 + +Signed-off-by: Tyler Hicks +Cc: Rocko +Cc: Colin Ian King +Signed-off-by: Greg Kroah-Hartman + +--- + fs/ecryptfs/file.c | 34 ++++++++++++++++++++++++++++++---- + 1 file changed, 30 insertions(+), 4 deletions(-) + +--- a/fs/ecryptfs/file.c ++++ b/fs/ecryptfs/file.c +@@ -303,9 +303,22 @@ ecryptfs_unlocked_ioctl(struct file *fil + struct file *lower_file = ecryptfs_file_to_lower(file); + long rc = -ENOTTY; + +- if (lower_file->f_op->unlocked_ioctl) ++ if (!lower_file->f_op->unlocked_ioctl) ++ return rc; ++ ++ switch (cmd) { ++ case FITRIM: ++ case FS_IOC_GETFLAGS: ++ case FS_IOC_SETFLAGS: ++ case FS_IOC_GETVERSION: ++ case FS_IOC_SETVERSION: + rc = lower_file->f_op->unlocked_ioctl(lower_file, cmd, arg); +- return rc; ++ fsstack_copy_attr_all(file_inode(file), file_inode(lower_file)); ++ ++ return rc; ++ default: ++ return rc; ++ } + } + + #ifdef CONFIG_COMPAT +@@ -315,9 +328,22 @@ ecryptfs_compat_ioctl(struct file *file, + struct file *lower_file = ecryptfs_file_to_lower(file); + long rc = -ENOIOCTLCMD; + +- if (lower_file->f_op->compat_ioctl) ++ if (!lower_file->f_op->compat_ioctl) ++ return rc; ++ ++ switch (cmd) { ++ case FITRIM: ++ case FS_IOC32_GETFLAGS: ++ case FS_IOC32_SETFLAGS: ++ case FS_IOC32_GETVERSION: ++ case FS_IOC32_SETVERSION: + rc = lower_file->f_op->compat_ioctl(lower_file, cmd, arg); +- return rc; ++ fsstack_copy_attr_all(file_inode(file), file_inode(lower_file)); ++ ++ return rc; ++ default: ++ return rc; ++ } + } + #endif + diff --git a/queue-3.19/efi-libstub-fix-boundary-checking-in-efi_high_alloc.patch b/queue-3.19/efi-libstub-fix-boundary-checking-in-efi_high_alloc.patch new file mode 100644 index 00000000000..11b0c9f9150 --- /dev/null +++ b/queue-3.19/efi-libstub-fix-boundary-checking-in-efi_high_alloc.patch @@ -0,0 +1,63 @@ +From 7ed620bb343f434f8a85f830020c04988df2a140 Mon Sep 17 00:00:00 2001 +From: Yinghai Lu +Date: Thu, 19 Feb 2015 20:18:03 -0800 +Subject: efi/libstub: Fix boundary checking in efi_high_alloc() + +From: Yinghai Lu + +commit 7ed620bb343f434f8a85f830020c04988df2a140 upstream. + +While adding support loading kernel and initrd above 4G to grub2 in legacy +mode, I was referring to efi_high_alloc(). +That will allocate buffer for kernel and then initrd, and initrd will +use kernel buffer start as limit. + +During testing found two buffers will be overlapped when initrd size is +very big like 400M. + +It turns out efi_high_alloc() boundary checking is not right. +end - size will be the new start, and should not compare new +start with max, we need to make sure end is smaller than max. + +[ Basically, with the current efi_high_alloc() code it's possible to + allocate memory above 'max', because efi_high_alloc() doesn't check + that the tail of the allocation is below 'max'. + + If you have an EFI memory map with a single entry that looks like so, + + [0xc0000000-0xc0004000] + + And want to allocate 0x3000 bytes below 0xc0003000 the current code + will allocate [0xc0001000-0xc0004000], not [0xc0000000-0xc0003000] + like you would expect. - Matt ] + +Signed-off-by: Yinghai Lu +Reviewed-by: Ard Biesheuvel +Reviewed-by: Mark Rutland +Tested-by: Mark Rutland +Signed-off-by: Matt Fleming +Signed-off-by: Greg Kroah-Hartman + +--- + drivers/firmware/efi/libstub/efi-stub-helper.c | 8 ++++---- + 1 file changed, 4 insertions(+), 4 deletions(-) + +--- a/drivers/firmware/efi/libstub/efi-stub-helper.c ++++ b/drivers/firmware/efi/libstub/efi-stub-helper.c +@@ -170,12 +170,12 @@ again: + start = desc->phys_addr; + end = start + desc->num_pages * (1UL << EFI_PAGE_SHIFT); + +- if ((start + size) > end || (start + size) > max) +- continue; +- +- if (end - size > max) ++ if (end > max) + end = max; + ++ if ((start + size) > end) ++ continue; ++ + if (round_down(end - size, align) < start) + continue; + diff --git a/queue-3.19/efi-small-leak-on-error-in-runtime-map-code.patch b/queue-3.19/efi-small-leak-on-error-in-runtime-map-code.patch new file mode 100644 index 00000000000..adeddd1add0 --- /dev/null +++ b/queue-3.19/efi-small-leak-on-error-in-runtime-map-code.patch @@ -0,0 +1,32 @@ +From 86d68a58d00db3770735b5919ef2c6b12d7f06f3 Mon Sep 17 00:00:00 2001 +From: Dan Carpenter +Date: Thu, 15 Jan 2015 12:21:21 +0300 +Subject: efi: Small leak on error in runtime map code + +From: Dan Carpenter + +commit 86d68a58d00db3770735b5919ef2c6b12d7f06f3 upstream. + +The "> 0" here should ">= 0" so we free map_entries[0]. + +Fixes: 926172d46038 ('efi: Export EFI runtime memory mapping to sysfs') +Signed-off-by: Dan Carpenter +Acked-by: Dave Young +Signed-off-by: Matt Fleming +Signed-off-by: Greg Kroah-Hartman + +--- + drivers/firmware/efi/runtime-map.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +--- a/drivers/firmware/efi/runtime-map.c ++++ b/drivers/firmware/efi/runtime-map.c +@@ -191,7 +191,7 @@ int __init efi_runtime_map_init(struct k + + return 0; + out_add_entry: +- for (j = i - 1; j > 0; j--) { ++ for (j = i - 1; j >= 0; j--) { + entry = *(map_entries + j); + kobject_put(&entry->kobj); + } diff --git a/queue-3.19/nfsd-fix-clp-cl_revoked-list-deletion-causing-softlock-in-nfsd.patch b/queue-3.19/nfsd-fix-clp-cl_revoked-list-deletion-causing-softlock-in-nfsd.patch new file mode 100644 index 00000000000..ffc21f8b7cc --- /dev/null +++ b/queue-3.19/nfsd-fix-clp-cl_revoked-list-deletion-causing-softlock-in-nfsd.patch @@ -0,0 +1,37 @@ +From c876486be17aeefe0da569f3d111cbd8de6f675d Mon Sep 17 00:00:00 2001 +From: Andrew Elble +Date: Wed, 25 Feb 2015 17:46:27 -0500 +Subject: nfsd: fix clp->cl_revoked list deletion causing softlock in nfsd + +From: Andrew Elble + +commit c876486be17aeefe0da569f3d111cbd8de6f675d upstream. + +commit 2d4a532d385f ("nfsd: ensure that clp->cl_revoked list is +protected by clp->cl_lock") removed the use of the reaplist to +clean out clp->cl_revoked. It failed to change list_entry() to +walk clp->cl_revoked.next instead of reaplist.next + +Fixes: 2d4a532d385f ("nfsd: ensure that clp->cl_revoked list is protected by clp->cl_lock") +Reported-by: Eric Meddaugh +Tested-by: Eric Meddaugh +Signed-off-by: Andrew Elble +Reviewed-by: Jeff Layton +Signed-off-by: J. Bruce Fields +Signed-off-by: Greg Kroah-Hartman + +--- + fs/nfsd/nfs4state.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +--- a/fs/nfsd/nfs4state.c ++++ b/fs/nfsd/nfs4state.c +@@ -1653,7 +1653,7 @@ __destroy_client(struct nfs4_client *clp + nfs4_put_stid(&dp->dl_stid); + } + while (!list_empty(&clp->cl_revoked)) { +- dp = list_entry(reaplist.next, struct nfs4_delegation, dl_recall_lru); ++ dp = list_entry(clp->cl_revoked.next, struct nfs4_delegation, dl_recall_lru); + list_del_init(&dp->dl_recall_lru); + nfs4_put_stid(&dp->dl_stid); + } diff --git a/queue-3.19/reservation-remove-shadowing-local-variable-ret.patch b/queue-3.19/reservation-remove-shadowing-local-variable-ret.patch new file mode 100644 index 00000000000..03c9203ce9e --- /dev/null +++ b/queue-3.19/reservation-remove-shadowing-local-variable-ret.patch @@ -0,0 +1,36 @@ +From 4eb2440ed60fb5793f7aa6da89b3d517cc59de43 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Michel=20D=C3=A4nzer?= +Date: Thu, 22 Jan 2015 16:00:17 +0900 +Subject: reservation: Remove shadowing local variable 'ret' +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +From: =?UTF-8?q?Michel=20D=C3=A4nzer?= + +commit 4eb2440ed60fb5793f7aa6da89b3d517cc59de43 upstream. + +It was causing the return value of fence_is_signaled to be ignored, making +reservation objects signal too early. + +Reviewed-by: Maarten Lankhorst +Reviewed-by: Alex Deucher +Signed-off-by: Michel Dänzer +Signed-off-by: Sumit Semwal +Signed-off-by: Greg Kroah-Hartman + +--- + drivers/dma-buf/reservation.c | 2 -- + 1 file changed, 2 deletions(-) + +--- a/drivers/dma-buf/reservation.c ++++ b/drivers/dma-buf/reservation.c +@@ -402,8 +402,6 @@ reservation_object_test_signaled_single( + int ret = 1; + + if (!test_bit(FENCE_FLAG_SIGNALED_BIT, &lfence->flags)) { +- int ret; +- + fence = fence_get_rcu(lfence); + if (!fence) + return -1; diff --git a/queue-3.19/series b/queue-3.19/series index 1f9767c5702..138bc3dbda4 100644 --- a/queue-3.19/series +++ b/queue-3.19/series @@ -141,3 +141,18 @@ staging-comedi-cb_pcidas64-fix-incorrect-ai-range-code-handling.patch hid-input-fix-confusion-on-conflicting-mappings.patch hid-fixup-the-conflicting-keyboard-mappings-quirk.patch hid-wacom-report-abs_misc-event-for-cintiq-companion-hybrid.patch +drm-radeon-enable-native-backlight-control-on-old-macs.patch +drm-radeon-use-drm_mode_vrefresh-rather-than-mode-vrefresh.patch +drm-radeon-fix-1-rb-harvest-config-setup-for-tn-rl.patch +drm-i915-bdw-pci-ids-ending-in-0xb-are-ult.patch +drm-i915-check-obj-vma_list-under-the-struct_mutex.patch +drm-i915-dell-chromebook-11-has-pwm-backlight.patch +drm-i915-avoid-processing-spurious-shared-interrupts-in-low-power-states.patch +drm-i915-check-for-driver-readyness-before-handling-an-underrun-interrupt.patch +reservation-remove-shadowing-local-variable-ret.patch +nfsd-fix-clp-cl_revoked-list-deletion-causing-softlock-in-nfsd.patch +efi-small-leak-on-error-in-runtime-map-code.patch +efi-libstub-fix-boundary-checking-in-efi_high_alloc.patch +ecryptfs-don-t-pass-fs-specific-ioctl-commands-through.patch +acpi-video-load-the-module-even-if-acpi-is-disabled.patch +acpi-lpss-provide-con_id-for-the-clkdev.patch