]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
3.9-stable patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 6 May 2013 17:05:44 +0000 (10:05 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 6 May 2013 17:05:44 +0000 (10:05 -0700)
added patches:
do_mount-fix-a-leak-introduced-in-3.9-mount-consolidate-permission-checks.patch
mmc-at91-avr32-atmel-mci-fix-dma-channel-leak-on-module-unload.patch

queue-3.9/do_mount-fix-a-leak-introduced-in-3.9-mount-consolidate-permission-checks.patch [new file with mode: 0644]
queue-3.9/mmc-at91-avr32-atmel-mci-fix-dma-channel-leak-on-module-unload.patch [new file with mode: 0644]
queue-3.9/series

diff --git a/queue-3.9/do_mount-fix-a-leak-introduced-in-3.9-mount-consolidate-permission-checks.patch b/queue-3.9/do_mount-fix-a-leak-introduced-in-3.9-mount-consolidate-permission-checks.patch
new file mode 100644 (file)
index 0000000..8efef21
--- /dev/null
@@ -0,0 +1,34 @@
+From 0d5cadb87e0fa764db7fa0b78d8a6f173cb475a1 Mon Sep 17 00:00:00 2001
+From: Al Viro <viro@zeniv.linux.org.uk>
+Date: Sat, 4 May 2013 14:40:51 -0400
+Subject: do_mount(): fix a leak introduced in 3.9 ("mount: consolidate permission checks")
+
+From: Al Viro <viro@zeniv.linux.org.uk>
+
+commit 0d5cadb87e0fa764db7fa0b78d8a6f173cb475a1 upstream.
+
+Bisected-by: Michael Leun <lkml20130126@newton.leun.net>
+Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ fs/namespace.c |    5 ++---
+ 1 file changed, 2 insertions(+), 3 deletions(-)
+
+--- a/fs/namespace.c
++++ b/fs/namespace.c
+@@ -2238,12 +2238,11 @@ long do_mount(const char *dev_name, cons
+       retval = security_sb_mount(dev_name, &path,
+                                  type_page, flags, data_page);
++      if (!retval && !may_mount())
++              retval = -EPERM;
+       if (retval)
+               goto dput_out;
+-      if (!may_mount())
+-              return -EPERM;
+-
+       /* Default to relatime unless overriden */
+       if (!(flags & MS_NOATIME))
+               mnt_flags |= MNT_RELATIME;
diff --git a/queue-3.9/mmc-at91-avr32-atmel-mci-fix-dma-channel-leak-on-module-unload.patch b/queue-3.9/mmc-at91-avr32-atmel-mci-fix-dma-channel-leak-on-module-unload.patch
new file mode 100644 (file)
index 0000000..3db4f43
--- /dev/null
@@ -0,0 +1,93 @@
+From 91cf54feecf815bec0b6a8d6d9dbd0e219f2f2cc Mon Sep 17 00:00:00 2001
+From: Johan Hovold <jhovold@gmail.com>
+Date: Wed, 13 Mar 2013 17:11:59 +0100
+Subject: mmc: at91/avr32/atmel-mci: fix DMA-channel leak on module unload
+
+From: Johan Hovold <jhovold@gmail.com>
+
+commit 91cf54feecf815bec0b6a8d6d9dbd0e219f2f2cc upstream.
+
+Fix regression introduced by commit 796211b7953 ("mmc: atmel-mci: add
+pdc support and runtime capabilities detection") which removed the need
+for CONFIG_MMC_ATMELMCI_DMA but kept the Kconfig-entry as well as the
+compile guards around dma_release_channel() in remove(). Consequently,
+DMA is always enabled (if supported), but the DMA-channel is not
+released on module unload unless the DMA-config option is selected.
+
+Remove the no longer used CONFIG_MMC_ATMELMCI_DMA option completely.
+
+Signed-off-by: Johan Hovold <jhovold@gmail.com>
+Acked-by: Ludovic Desroches <ludovic.desroches@atmel.com>
+Signed-off-by: Chris Ball <cjb@laptop.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ arch/arm/configs/at91sam9g45_defconfig |    1 -
+ arch/avr32/configs/favr-32_defconfig   |    1 -
+ arch/avr32/configs/merisc_defconfig    |    1 -
+ drivers/mmc/host/Kconfig               |   10 ----------
+ drivers/mmc/host/atmel-mci.c           |    2 --
+ 5 files changed, 15 deletions(-)
+
+--- a/arch/arm/configs/at91sam9g45_defconfig
++++ b/arch/arm/configs/at91sam9g45_defconfig
+@@ -173,7 +173,6 @@ CONFIG_MMC=y
+ # CONFIG_MMC_BLOCK_BOUNCE is not set
+ CONFIG_SDIO_UART=m
+ CONFIG_MMC_ATMELMCI=y
+-CONFIG_MMC_ATMELMCI_DMA=y
+ CONFIG_LEDS_ATMEL_PWM=y
+ CONFIG_LEDS_GPIO=y
+ CONFIG_LEDS_TRIGGER_TIMER=y
+--- a/arch/avr32/configs/favr-32_defconfig
++++ b/arch/avr32/configs/favr-32_defconfig
+@@ -122,7 +122,6 @@ CONFIG_USB_G_SERIAL=m
+ CONFIG_USB_CDC_COMPOSITE=m
+ CONFIG_MMC=y
+ CONFIG_MMC_ATMELMCI=y
+-CONFIG_MMC_ATMELMCI_DMA=y
+ CONFIG_NEW_LEDS=y
+ CONFIG_LEDS_CLASS=y
+ CONFIG_LEDS_ATMEL_PWM=m
+--- a/arch/avr32/configs/merisc_defconfig
++++ b/arch/avr32/configs/merisc_defconfig
+@@ -102,7 +102,6 @@ CONFIG_FRAMEBUFFER_CONSOLE=y
+ CONFIG_LOGO=y
+ CONFIG_MMC=y
+ CONFIG_MMC_ATMELMCI=y
+-CONFIG_MMC_ATMELMCI_DMA=y
+ CONFIG_NEW_LEDS=y
+ CONFIG_LEDS_CLASS=y
+ CONFIG_LEDS_ATMEL_PWM=y
+--- a/drivers/mmc/host/Kconfig
++++ b/drivers/mmc/host/Kconfig
+@@ -300,16 +300,6 @@ config MMC_ATMELMCI
+         If unsure, say N.
+-config MMC_ATMELMCI_DMA
+-      bool "Atmel MCI DMA support"
+-      depends on MMC_ATMELMCI && (AVR32 || ARCH_AT91SAM9G45) && DMA_ENGINE
+-      help
+-        Say Y here to have the Atmel MCI driver use a DMA engine to
+-        do data transfers and thus increase the throughput and
+-        reduce the CPU utilization.
+-
+-        If unsure, say N.
+-
+ config MMC_MSM
+       tristate "Qualcomm SDCC Controller Support"
+       depends on MMC && ARCH_MSM
+--- a/drivers/mmc/host/atmel-mci.c
++++ b/drivers/mmc/host/atmel-mci.c
+@@ -2487,10 +2487,8 @@ static int __exit atmci_remove(struct pl
+       atmci_readl(host, ATMCI_SR);
+       clk_disable(host->mck);
+-#ifdef CONFIG_MMC_ATMELMCI_DMA
+       if (host->dma.chan)
+               dma_release_channel(host->dma.chan);
+-#endif
+       free_irq(platform_get_irq(pdev, 0), host);
+       iounmap(host->regs);
index 6a44b60a3cef2d7dd81f51499ccd4865e3b31f28..aeba67386f4eba25321a4de250a85fdbc9c71033 100644 (file)
@@ -104,3 +104,5 @@ ext4-unregister-es_shrinker-if-mount-failed.patch
 ext4-fix-big-endian-bug-in-metadata-checksum-calculations.patch
 ext4-fix-online-resizing-for-ext3-compat-file-systems.patch
 ext4-fix-kconfig-documentation-for-config_ext4_debug.patch
+do_mount-fix-a-leak-introduced-in-3.9-mount-consolidate-permission-checks.patch
+mmc-at91-avr32-atmel-mci-fix-dma-channel-leak-on-module-unload.patch