]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
3.17-stable patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 27 Oct 2014 08:56:22 +0000 (16:56 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 27 Oct 2014 08:56:22 +0000 (16:56 +0800)
added patches:
alsa-alc283-codec-avoid-pop-noise-on-headphones-during-suspend-resume.patch
alsa-bebob-fix-failure-to-detect-source-of-clock-for-terratec-phase-88.patch
alsa-emu10k1-fix-deadlock-in-synth-voice-lookup.patch
alsa-hda-add-missing-terminating-entry-to-snd_hda_pin_quirk-macro.patch
alsa-hda-fix-inverted-led-gpio-setup-for-lenovo-ideapad.patch
alsa-hda-hdmi-fix-missing-eld-change-event-on-plug-unplug.patch
alsa-pcm-use-the-same-dma-mmap-codepath-both-for-arm-and-arm64.patch
alsa-usb-audio-add-support-for-steinberg-ur22-usb-interface.patch
arm-at91-dt-fix-typo-regarding-can0_clk.patch
arm-at91-fix-at91sam9263ek-dt-mmc-pinmuxing-settings.patch
arm-at91-pmc-don-t-forget-to-write-pmc_pcdr-register-to-disable-clocks.patch
arm-dts-imx28-evk-let-i2c0-run-at-100khz.patch
arm-kirkwood-fix-dt-based-dsa.patch
arm-mvebu-netgear-rn102-use-hardware-bch-ecc.patch
arm-mvebu-netgear-rn104-use-hardware-bch-ecc.patch
arm-mvebu-netgear-rn2120-use-hardware-bch-ecc.patch
arm64-compat-fix-compat-types-affecting-struct.patch
arm64-fix-compilation-error-on-up-builds.patch
clk-qcom-add-ipq8064-pll-required-for-usb.patch
ecryptfs-avoid-to-access-null-pointer-when-write-metadata-in-xattr.patch
udf-fix-loading-of-special-inodes.patch
vfio-pci-fix-remove-path-locking.patch
xfs-ensure-wb_sync_all-writeback-handles-partial-pages-correctly.patch
xfs-fix-agno-increment-in-xfs_inumbers-loop.patch

25 files changed:
queue-3.17/alsa-alc283-codec-avoid-pop-noise-on-headphones-during-suspend-resume.patch [new file with mode: 0644]
queue-3.17/alsa-bebob-fix-failure-to-detect-source-of-clock-for-terratec-phase-88.patch [new file with mode: 0644]
queue-3.17/alsa-emu10k1-fix-deadlock-in-synth-voice-lookup.patch [new file with mode: 0644]
queue-3.17/alsa-hda-add-missing-terminating-entry-to-snd_hda_pin_quirk-macro.patch [new file with mode: 0644]
queue-3.17/alsa-hda-fix-inverted-led-gpio-setup-for-lenovo-ideapad.patch [new file with mode: 0644]
queue-3.17/alsa-hda-hdmi-fix-missing-eld-change-event-on-plug-unplug.patch [new file with mode: 0644]
queue-3.17/alsa-pcm-use-the-same-dma-mmap-codepath-both-for-arm-and-arm64.patch [new file with mode: 0644]
queue-3.17/alsa-usb-audio-add-support-for-steinberg-ur22-usb-interface.patch [new file with mode: 0644]
queue-3.17/arm-at91-dt-fix-typo-regarding-can0_clk.patch [new file with mode: 0644]
queue-3.17/arm-at91-fix-at91sam9263ek-dt-mmc-pinmuxing-settings.patch [new file with mode: 0644]
queue-3.17/arm-at91-pmc-don-t-forget-to-write-pmc_pcdr-register-to-disable-clocks.patch [new file with mode: 0644]
queue-3.17/arm-dts-imx28-evk-let-i2c0-run-at-100khz.patch [new file with mode: 0644]
queue-3.17/arm-kirkwood-fix-dt-based-dsa.patch [new file with mode: 0644]
queue-3.17/arm-mvebu-netgear-rn102-use-hardware-bch-ecc.patch [new file with mode: 0644]
queue-3.17/arm-mvebu-netgear-rn104-use-hardware-bch-ecc.patch [new file with mode: 0644]
queue-3.17/arm-mvebu-netgear-rn2120-use-hardware-bch-ecc.patch [new file with mode: 0644]
queue-3.17/arm64-compat-fix-compat-types-affecting-struct.patch [new file with mode: 0644]
queue-3.17/arm64-fix-compilation-error-on-up-builds.patch [new file with mode: 0644]
queue-3.17/clk-qcom-add-ipq8064-pll-required-for-usb.patch [new file with mode: 0644]
queue-3.17/ecryptfs-avoid-to-access-null-pointer-when-write-metadata-in-xattr.patch [new file with mode: 0644]
queue-3.17/series
queue-3.17/udf-fix-loading-of-special-inodes.patch [new file with mode: 0644]
queue-3.17/vfio-pci-fix-remove-path-locking.patch [new file with mode: 0644]
queue-3.17/xfs-ensure-wb_sync_all-writeback-handles-partial-pages-correctly.patch [new file with mode: 0644]
queue-3.17/xfs-fix-agno-increment-in-xfs_inumbers-loop.patch [new file with mode: 0644]

diff --git a/queue-3.17/alsa-alc283-codec-avoid-pop-noise-on-headphones-during-suspend-resume.patch b/queue-3.17/alsa-alc283-codec-avoid-pop-noise-on-headphones-during-suspend-resume.patch
new file mode 100644 (file)
index 0000000..0820a4d
--- /dev/null
@@ -0,0 +1,32 @@
+From b450b17c156e264bc44a198046d3ebaaef5a041d Mon Sep 17 00:00:00 2001
+From: Harsha Priya <harshapriya.n@intel.com>
+Date: Thu, 9 Oct 2014 11:04:56 +0000
+Subject: ALSA: ALC283 codec - Avoid pop noise on headphones during suspend/resume
+
+From: Harsha Priya <harshapriya.n@intel.com>
+
+commit b450b17c156e264bc44a198046d3ebaaef5a041d upstream.
+
+This patch sets the headphones mode to default before suspending
+which helps avoid the pop noise on headphones
+
+Signed-off-by: Harsha Priya <harshapriya.n@intel.com>
+Signed-off-by: Takashi Iwai <tiwai@suse.de>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ sound/pci/hda/patch_realtek.c |    3 +++
+ 1 file changed, 3 insertions(+)
+
+--- a/sound/pci/hda/patch_realtek.c
++++ b/sound/pci/hda/patch_realtek.c
+@@ -3125,6 +3125,9 @@ static void alc283_shutup(struct hda_cod
+       alc_write_coef_idx(codec, 0x43, 0x9004);
++      /*depop hp during suspend*/
++      alc_write_coef_idx(codec, 0x06, 0x2100);
++
+       snd_hda_codec_write(codec, hp_pin, 0,
+                           AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_MUTE);
diff --git a/queue-3.17/alsa-bebob-fix-failure-to-detect-source-of-clock-for-terratec-phase-88.patch b/queue-3.17/alsa-bebob-fix-failure-to-detect-source-of-clock-for-terratec-phase-88.patch
new file mode 100644 (file)
index 0000000..c707f61
--- /dev/null
@@ -0,0 +1,47 @@
+From 3f4032861cfbff0b9134bf94c5c92e2146d1f068 Mon Sep 17 00:00:00 2001
+From: Takashi Sakamoto <o-takashi@sakamocchi.jp>
+Date: Fri, 10 Oct 2014 23:32:49 +0900
+Subject: ALSA: bebob: Fix failure to detect source of clock for Terratec Phase 88
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+From: Takashi Sakamoto <o-takashi@sakamocchi.jp>
+
+commit 3f4032861cfbff0b9134bf94c5c92e2146d1f068 upstream.
+
+This patch fixes a failure to open PCM device with -ENOSYS in
+Terratec Phase 88.
+
+Terratec Phase 88 has two Selector Function Blocks of AVC Audio subunit
+to switch source of clock. One is to switch internal/external for the
+source and another is to switch word/spdif for the external clock.
+
+The IDs for these Selector Function Blocks are 9 and 8. But in current
+implementation they're 0 and 0.
+
+Reported-by: András Murányi <muranyia@gmail.com>
+Tested-by: András Murányi <muranyia@gmail.com>
+Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp>
+Signed-off-by: Takashi Iwai <tiwai@suse.de>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ sound/firewire/bebob/bebob_terratec.c |    4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+--- a/sound/firewire/bebob/bebob_terratec.c
++++ b/sound/firewire/bebob/bebob_terratec.c
+@@ -17,10 +17,10 @@ phase88_rack_clk_src_get(struct snd_bebo
+       unsigned int enable_ext, enable_word;
+       int err;
+-      err = avc_audio_get_selector(bebob->unit, 0, 0, &enable_ext);
++      err = avc_audio_get_selector(bebob->unit, 0, 9, &enable_ext);
+       if (err < 0)
+               goto end;
+-      err = avc_audio_get_selector(bebob->unit, 0, 0, &enable_word);
++      err = avc_audio_get_selector(bebob->unit, 0, 8, &enable_word);
+       if (err < 0)
+               goto end;
diff --git a/queue-3.17/alsa-emu10k1-fix-deadlock-in-synth-voice-lookup.patch b/queue-3.17/alsa-emu10k1-fix-deadlock-in-synth-voice-lookup.patch
new file mode 100644 (file)
index 0000000..5c91701
--- /dev/null
@@ -0,0 +1,63 @@
+From 95926035b187cc9fee6fb61385b7da9c28123f74 Mon Sep 17 00:00:00 2001
+From: Takashi Iwai <tiwai@suse.de>
+Date: Mon, 13 Oct 2014 23:18:02 +0200
+Subject: ALSA: emu10k1: Fix deadlock in synth voice lookup
+
+From: Takashi Iwai <tiwai@suse.de>
+
+commit 95926035b187cc9fee6fb61385b7da9c28123f74 upstream.
+
+The emu10k1 voice allocator takes voice_lock spinlock.  When there is
+no empty stream available, it tries to release a voice used by synth,
+and calls get_synth_voice.  The callback function,
+snd_emu10k1_synth_get_voice(), however, also takes the voice_lock,
+thus it deadlocks.
+
+The fix is simply removing the voice_lock holds in
+snd_emu10k1_synth_get_voice(), as this is always called in the
+spinlock context.
+
+Reported-and-tested-by: Arthur Marsh <arthur.marsh@internode.on.net>
+Signed-off-by: Takashi Iwai <tiwai@suse.de>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ sound/pci/emu10k1/emu10k1_callback.c |    6 ++----
+ 1 file changed, 2 insertions(+), 4 deletions(-)
+
+--- a/sound/pci/emu10k1/emu10k1_callback.c
++++ b/sound/pci/emu10k1/emu10k1_callback.c
+@@ -85,6 +85,8 @@ snd_emu10k1_ops_setup(struct snd_emux *e
+  * get more voice for pcm
+  *
+  * terminate most inactive voice and give it as a pcm voice.
++ *
++ * voice_lock is already held.
+  */
+ int
+ snd_emu10k1_synth_get_voice(struct snd_emu10k1 *hw)
+@@ -92,12 +94,10 @@ snd_emu10k1_synth_get_voice(struct snd_e
+       struct snd_emux *emu;
+       struct snd_emux_voice *vp;
+       struct best_voice best[V_END];
+-      unsigned long flags;
+       int i;
+       emu = hw->synth;
+-      spin_lock_irqsave(&emu->voice_lock, flags);
+       lookup_voices(emu, hw, best, 1); /* no OFF voices */
+       for (i = 0; i < V_END; i++) {
+               if (best[i].voice >= 0) {
+@@ -113,11 +113,9 @@ snd_emu10k1_synth_get_voice(struct snd_e
+                       vp->emu->num_voices--;
+                       vp->ch = -1;
+                       vp->state = SNDRV_EMUX_ST_OFF;
+-                      spin_unlock_irqrestore(&emu->voice_lock, flags);
+                       return ch;
+               }
+       }
+-      spin_unlock_irqrestore(&emu->voice_lock, flags);
+       /* not found */
+       return -ENOMEM;
diff --git a/queue-3.17/alsa-hda-add-missing-terminating-entry-to-snd_hda_pin_quirk-macro.patch b/queue-3.17/alsa-hda-add-missing-terminating-entry-to-snd_hda_pin_quirk-macro.patch
new file mode 100644 (file)
index 0000000..f194abb
--- /dev/null
@@ -0,0 +1,43 @@
+From fb54a645b2739fb196446ffbbbe3f3589d117b55 Mon Sep 17 00:00:00 2001
+From: David Henningsson <david.henningsson@canonical.com>
+Date: Fri, 24 Oct 2014 10:00:38 +0200
+Subject: ALSA: hda - Add missing terminating entry to SND_HDA_PIN_QUIRK macro
+
+From: David Henningsson <david.henningsson@canonical.com>
+
+commit fb54a645b2739fb196446ffbbbe3f3589d117b55 upstream.
+
+Without this terminating entry, the pin matching would continue
+across random memory until a zero or a non-matching entry was found.
+
+The result being that in some cases, the pin quirk would not be
+applied correctly.
+
+Signed-off-by: David Henningsson <david.henningsson@canonical.com>
+Signed-off-by: Takashi Iwai <tiwai@suse.de>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ sound/pci/hda/hda_local.h |    4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+--- a/sound/pci/hda/hda_local.h
++++ b/sound/pci/hda/hda_local.h
+@@ -425,7 +425,7 @@ struct snd_hda_pin_quirk {
+         .subvendor = _subvendor,\
+         .name = _name,\
+         .value = _value,\
+-        .pins = (const struct hda_pintbl[]) { _pins } \
++        .pins = (const struct hda_pintbl[]) { _pins, {0, 0}} \
+       }
+ #else
+@@ -433,7 +433,7 @@ struct snd_hda_pin_quirk {
+       { .codec = _codec,\
+         .subvendor = _subvendor,\
+         .value = _value,\
+-        .pins = (const struct hda_pintbl[]) { _pins } \
++        .pins = (const struct hda_pintbl[]) { _pins, {0, 0}} \
+       }
+ #endif
diff --git a/queue-3.17/alsa-hda-fix-inverted-led-gpio-setup-for-lenovo-ideapad.patch b/queue-3.17/alsa-hda-fix-inverted-led-gpio-setup-for-lenovo-ideapad.patch
new file mode 100644 (file)
index 0000000..203f7e1
--- /dev/null
@@ -0,0 +1,35 @@
+From b1974f965a506c131b60cd3e483340884e831920 Mon Sep 17 00:00:00 2001
+From: Takashi Iwai <tiwai@suse.de>
+Date: Mon, 20 Oct 2014 11:26:57 +0200
+Subject: ALSA: hda - Fix inverted LED gpio setup for Lenovo Ideapad
+
+From: Takashi Iwai <tiwai@suse.de>
+
+commit b1974f965a506c131b60cd3e483340884e831920 upstream.
+
+We implemented in a wrong way for mute LED on Lenovo Ideapad; the bit
+must be flipped.
+
+Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=16373
+Fixes: 3e887f379d8a ('ALSA: hda - Add mute LED support to Lenovo Ideapad')
+Signed-off-by: Takashi Iwai <tiwai@suse.de>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ sound/pci/hda/patch_realtek.c |    4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+--- a/sound/pci/hda/patch_realtek.c
++++ b/sound/pci/hda/patch_realtek.c
+@@ -5786,9 +5786,9 @@ static void alc662_led_gpio1_mute_hook(v
+       unsigned int oldval = spec->gpio_led;
+       if (enabled)
+-              spec->gpio_led &= ~0x01;
+-      else
+               spec->gpio_led |= 0x01;
++      else
++              spec->gpio_led &= ~0x01;
+       if (spec->gpio_led != oldval)
+               snd_hda_codec_write(codec, 0x01, 0, AC_VERB_SET_GPIO_DATA,
+                                   spec->gpio_led);
diff --git a/queue-3.17/alsa-hda-hdmi-fix-missing-eld-change-event-on-plug-unplug.patch b/queue-3.17/alsa-hda-hdmi-fix-missing-eld-change-event-on-plug-unplug.patch
new file mode 100644 (file)
index 0000000..42cb0fc
--- /dev/null
@@ -0,0 +1,62 @@
+From 6acce400d9daf1353fbf497302670c90a3205e1d Mon Sep 17 00:00:00 2001
+From: Anssi Hannula <anssi.hannula@iki.fi>
+Date: Sun, 19 Oct 2014 19:25:19 +0300
+Subject: ALSA: hda - hdmi: Fix missing ELD change event on plug/unplug
+
+From: Anssi Hannula <anssi.hannula@iki.fi>
+
+commit 6acce400d9daf1353fbf497302670c90a3205e1d upstream.
+
+The ELD ALSA control change event is sent by hdmi_present_sense() when
+eld_changed is true.
+
+Currently, it is only true when the ELD buffer contents have been
+modified. However, the user-visible ELD controls also change to a
+zero-length value and back when eld_valid is unset/set, and no event is
+currently sent in such cases (such as when unplugging or replugging a
+sink).
+
+Fix the code to always set eld_changed if eld_valid value is changed,
+and therefore to always send the change event when the user-visible
+value changes.
+
+Signed-off-by: Anssi Hannula <anssi.hannula@iki.fi>
+Cc: David Henningsson <david.henningsson@canonical.com>
+Signed-off-by: Takashi Iwai <tiwai@suse.de>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ sound/pci/hda/patch_hdmi.c |   15 +++++++++------
+ 1 file changed, 9 insertions(+), 6 deletions(-)
+
+--- a/sound/pci/hda/patch_hdmi.c
++++ b/sound/pci/hda/patch_hdmi.c
+@@ -1577,19 +1577,22 @@ static bool hdmi_present_sense(struct hd
+               }
+       }
+-      if (pin_eld->eld_valid && !eld->eld_valid) {
+-              update_eld = true;
++      if (pin_eld->eld_valid != eld->eld_valid)
+               eld_changed = true;
+-      }
++
++      if (pin_eld->eld_valid && !eld->eld_valid)
++              update_eld = true;
++
+       if (update_eld) {
+               bool old_eld_valid = pin_eld->eld_valid;
+               pin_eld->eld_valid = eld->eld_valid;
+-              eld_changed = pin_eld->eld_size != eld->eld_size ||
++              if (pin_eld->eld_size != eld->eld_size ||
+                             memcmp(pin_eld->eld_buffer, eld->eld_buffer,
+-                                   eld->eld_size) != 0;
+-              if (eld_changed)
++                                   eld->eld_size) != 0) {
+                       memcpy(pin_eld->eld_buffer, eld->eld_buffer,
+                              eld->eld_size);
++                      eld_changed = true;
++              }
+               pin_eld->eld_size = eld->eld_size;
+               pin_eld->info = eld->info;
diff --git a/queue-3.17/alsa-pcm-use-the-same-dma-mmap-codepath-both-for-arm-and-arm64.patch b/queue-3.17/alsa-pcm-use-the-same-dma-mmap-codepath-both-for-arm-and-arm64.patch
new file mode 100644 (file)
index 0000000..4c7166d
--- /dev/null
@@ -0,0 +1,38 @@
+From a011e213f3700233ed2a676f1ef0a74a052d7162 Mon Sep 17 00:00:00 2001
+From: Anatol Pomozov <anatol.pomozov@gmail.com>
+Date: Fri, 17 Oct 2014 12:43:34 -0700
+Subject: ALSA: pcm: use the same dma mmap codepath both for arm and arm64
+
+From: Anatol Pomozov <anatol.pomozov@gmail.com>
+
+commit a011e213f3700233ed2a676f1ef0a74a052d7162 upstream.
+
+This avoids following kernel crash when try to playback on arm64
+
+[  107.497203] [<ffffffc00046b310>] snd_pcm_mmap_data_fault+0x90/0xd4
+[  107.503405] [<ffffffc0001541ac>] __do_fault+0xb0/0x498
+[  107.508565] [<ffffffc0001576a0>] handle_mm_fault+0x224/0x7b0
+[  107.514246] [<ffffffc000092640>] do_page_fault+0x11c/0x310
+[  107.519738] [<ffffffc000081100>] do_mem_abort+0x38/0x98
+
+Tested: backported to 3.14 and tried to playback on arm64 machine
+
+Signed-off-by: Anatol Pomozov <anatol.pomozov@gmail.com>
+Signed-off-by: Takashi Iwai <tiwai@suse.de>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ sound/core/pcm_native.c |    2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/sound/core/pcm_native.c
++++ b/sound/core/pcm_native.c
+@@ -3193,7 +3193,7 @@ static const struct vm_operations_struct
+ #ifndef ARCH_HAS_DMA_MMAP_COHERENT
+ /* This should be defined / handled globally! */
+-#ifdef CONFIG_ARM
++#if defined(CONFIG_ARM) || defined(CONFIG_ARM64)
+ #define ARCH_HAS_DMA_MMAP_COHERENT
+ #endif
+ #endif
diff --git a/queue-3.17/alsa-usb-audio-add-support-for-steinberg-ur22-usb-interface.patch b/queue-3.17/alsa-usb-audio-add-support-for-steinberg-ur22-usb-interface.patch
new file mode 100644 (file)
index 0000000..fdfad5a
--- /dev/null
@@ -0,0 +1,70 @@
+From f0b127fbfdc8756eba7437ab668f3169280bd358 Mon Sep 17 00:00:00 2001
+From: Vlad Catoi <vladcatoi@gmail.com>
+Date: Sat, 18 Oct 2014 17:45:41 -0500
+Subject: ALSA: usb-audio: Add support for Steinberg UR22 USB interface
+
+From: Vlad Catoi <vladcatoi@gmail.com>
+
+commit f0b127fbfdc8756eba7437ab668f3169280bd358 upstream.
+
+Adding support for Steinberg UR22 USB interface via quirks table patch
+
+See Ubuntu bug report:
+https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1317244
+Also see threads:
+http://linux-audio.4202.n7.nabble.com/Support-for-Steinberg-UR22-Yamaha-USB-chipset-0499-1509-tc82888.html#a82917
+http://www.steinberg.net/forums/viewtopic.php?t=62290
+
+Tested by at least 4 people judging by the threads.
+Did not test MIDI interface, but audio output and capture both are
+functional. Built 3.17 kernel with this driver on Ubuntu 14.04 & tested with mpg123
+Patch applied to 3.13 Ubuntu kernel works well enough for daily use.
+
+Signed-off-by: Vlad Catoi <vladcatoi@gmail.com>
+Acked-by: Clemens Ladisch <clemens@ladisch.de>
+Signed-off-by: Takashi Iwai <tiwai@suse.de>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ sound/usb/quirks-table.h |   30 ++++++++++++++++++++++++++++++
+ 1 file changed, 30 insertions(+)
+
+--- a/sound/usb/quirks-table.h
++++ b/sound/usb/quirks-table.h
+@@ -385,6 +385,36 @@ YAMAHA_DEVICE(0x105d, NULL),
+       }
+ },
+ {
++      USB_DEVICE(0x0499, 0x1509),
++      .driver_info = (unsigned long) & (const struct snd_usb_audio_quirk) {
++              /* .vendor_name = "Yamaha", */
++              /* .product_name = "Steinberg UR22", */
++              .ifnum = QUIRK_ANY_INTERFACE,
++              .type = QUIRK_COMPOSITE,
++              .data = (const struct snd_usb_audio_quirk[]) {
++                      {
++                              .ifnum = 1,
++                              .type = QUIRK_AUDIO_STANDARD_INTERFACE
++                      },
++                      {
++                              .ifnum = 2,
++                              .type = QUIRK_AUDIO_STANDARD_INTERFACE
++                      },
++                      {
++                              .ifnum = 3,
++                              .type = QUIRK_MIDI_YAMAHA
++                      },
++                      {
++                              .ifnum = 4,
++                              .type = QUIRK_IGNORE_INTERFACE
++                      },
++                      {
++                              .ifnum = -1
++                      }
++              }
++      }
++},
++{
+       USB_DEVICE(0x0499, 0x150a),
+       .driver_info = (unsigned long) & (const struct snd_usb_audio_quirk) {
+               /* .vendor_name = "Yamaha", */
diff --git a/queue-3.17/arm-at91-dt-fix-typo-regarding-can0_clk.patch b/queue-3.17/arm-at91-dt-fix-typo-regarding-can0_clk.patch
new file mode 100644 (file)
index 0000000..5dff217
--- /dev/null
@@ -0,0 +1,32 @@
+From 0a51d644c20f5c88fd3a659119d1903f74927082 Mon Sep 17 00:00:00 2001
+From: David Dueck <davidcdueck@googlemail.com>
+Date: Wed, 17 Sep 2014 10:33:32 +0200
+Subject: ARM: at91/dt: Fix typo regarding can0_clk
+
+From: David Dueck <davidcdueck@googlemail.com>
+
+commit 0a51d644c20f5c88fd3a659119d1903f74927082 upstream.
+
+Otherwise the clock for can0 will never get enabled.
+
+Signed-off-by: David Dueck <davidcdueck@googlemail.com>
+Signed-off-by: Anthony Harivel <anthony.harivel@emtrion.de>
+Acked-by: Boris Brezillon <boris.brezillon@free-electrons.com>
+Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ arch/arm/boot/dts/sama5d3_can.dtsi |    2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/arch/arm/boot/dts/sama5d3_can.dtsi
++++ b/arch/arm/boot/dts/sama5d3_can.dtsi
+@@ -40,7 +40,7 @@
+                                               atmel,clk-output-range = <0 66000000>;
+                                       };
+-                                      can1_clk: can0_clk {
++                                      can1_clk: can1_clk {
+                                               #clock-cells = <0>;
+                                               reg = <41>;
+                                               atmel,clk-output-range = <0 66000000>;
diff --git a/queue-3.17/arm-at91-fix-at91sam9263ek-dt-mmc-pinmuxing-settings.patch b/queue-3.17/arm-at91-fix-at91sam9263ek-dt-mmc-pinmuxing-settings.patch
new file mode 100644 (file)
index 0000000..2d48ada
--- /dev/null
@@ -0,0 +1,45 @@
+From b65e0fb3d046cc65d0a3c45d43de351fb363271b Mon Sep 17 00:00:00 2001
+From: Andreas Henriksson <andreas.henriksson@endian.se>
+Date: Tue, 23 Sep 2014 17:12:52 +0200
+Subject: ARM: at91: fix at91sam9263ek DT mmc pinmuxing settings
+
+From: Andreas Henriksson <andreas.henriksson@endian.se>
+
+commit b65e0fb3d046cc65d0a3c45d43de351fb363271b upstream.
+
+As discovered on a custom board similar to at91sam9263ek and basing
+its devicetree on that one apparently the pin muxing doesn't get
+set up properly. This was discovered since the custom boards u-boot
+does funky stuff with the pin muxing and leaved it set to SPI
+which made the MMC driver not work under Linux.
+The fix is simply to define the given configuration as the default.
+This probably worked by pure luck before, but it's better to
+make the muxing explicitly set.
+
+Signed-off-by: Andreas Henriksson <andreas.henriksson@endian.se>
+Acked-by: Boris Brezillon <boris.brezillon@free-electrons.com>
+Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ arch/arm/boot/dts/at91sam9263.dtsi |    2 ++
+ 1 file changed, 2 insertions(+)
+
+--- a/arch/arm/boot/dts/at91sam9263.dtsi
++++ b/arch/arm/boot/dts/at91sam9263.dtsi
+@@ -834,6 +834,7 @@
+                               compatible = "atmel,hsmci";
+                               reg = <0xfff80000 0x600>;
+                               interrupts = <10 IRQ_TYPE_LEVEL_HIGH 0>;
++                              pinctrl-names = "default";
+                               #address-cells = <1>;
+                               #size-cells = <0>;
+                               clocks = <&mci0_clk>;
+@@ -845,6 +846,7 @@
+                               compatible = "atmel,hsmci";
+                               reg = <0xfff84000 0x600>;
+                               interrupts = <11 IRQ_TYPE_LEVEL_HIGH 0>;
++                              pinctrl-names = "default";
+                               #address-cells = <1>;
+                               #size-cells = <0>;
+                               clocks = <&mci1_clk>;
diff --git a/queue-3.17/arm-at91-pmc-don-t-forget-to-write-pmc_pcdr-register-to-disable-clocks.patch b/queue-3.17/arm-at91-pmc-don-t-forget-to-write-pmc_pcdr-register-to-disable-clocks.patch
new file mode 100644 (file)
index 0000000..65531b3
--- /dev/null
@@ -0,0 +1,31 @@
+From cfa1950e6c6b72251e80adc736af3c3d2907ab0e Mon Sep 17 00:00:00 2001
+From: Ludovic Desroches <ludovic.desroches@atmel.com>
+Date: Mon, 22 Sep 2014 15:51:33 +0200
+Subject: ARM: at91/PMC: don't forget to write PMC_PCDR register to disable clocks
+
+From: Ludovic Desroches <ludovic.desroches@atmel.com>
+
+commit cfa1950e6c6b72251e80adc736af3c3d2907ab0e upstream.
+
+When introducing support for sama5d3, the write to PMC_PCDR register has
+been accidentally removed.
+
+Reported-by: Nathalie Cyrille <nathalie.cyrille@atmel.com>
+Signed-off-by: Ludovic Desroches <ludovic.desroches@atmel.com>
+Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ arch/arm/mach-at91/clock.c |    1 +
+ 1 file changed, 1 insertion(+)
+
+--- a/arch/arm/mach-at91/clock.c
++++ b/arch/arm/mach-at91/clock.c
+@@ -962,6 +962,7 @@ static int __init at91_clock_reset(void)
+       }
+       at91_pmc_write(AT91_PMC_SCDR, scdr);
++      at91_pmc_write(AT91_PMC_PCDR, pcdr);
+       if (cpu_is_sama5d3())
+               at91_pmc_write(AT91_PMC_PCDR1, pcdr1);
diff --git a/queue-3.17/arm-dts-imx28-evk-let-i2c0-run-at-100khz.patch b/queue-3.17/arm-dts-imx28-evk-let-i2c0-run-at-100khz.patch
new file mode 100644 (file)
index 0000000..6c11a65
--- /dev/null
@@ -0,0 +1,41 @@
+From d1e61eb443dc7512885dfe89ee2f2a1c29fcb1da Mon Sep 17 00:00:00 2001
+From: Fabio Estevam <fabio.estevam@freescale.com>
+Date: Mon, 20 Oct 2014 11:08:01 -0200
+Subject: ARM: dts: imx28-evk: Let i2c0 run at 100kHz
+
+From: Fabio Estevam <fabio.estevam@freescale.com>
+
+commit d1e61eb443dc7512885dfe89ee2f2a1c29fcb1da upstream.
+
+Commit 78b81f4666fb ("ARM: dts: imx28-evk: Run I2C0 at 400kHz") caused issues
+when doing the following sequence in loop:
+
+- Boot the kernel
+- Perform audio playback
+- Reboot the system via 'reboot' command
+
+In many times the audio card cannot be probed, which causes playback to fail.
+
+After restoring to the original i2c0 frequency of 100kHz there is no such
+problem anymore.
+
+This reverts commit 78b81f4666fbb22a20b1e63e5baf197ad2e90e88.
+
+Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
+Signed-off-by: Shawn Guo <shawn.guo@linaro.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ arch/arm/boot/dts/imx28-evk.dts |    1 -
+ 1 file changed, 1 deletion(-)
+
+--- a/arch/arm/boot/dts/imx28-evk.dts
++++ b/arch/arm/boot/dts/imx28-evk.dts
+@@ -193,7 +193,6 @@
+                       i2c0: i2c@80058000 {
+                               pinctrl-names = "default";
+                               pinctrl-0 = <&i2c0_pins_a>;
+-                              clock-frequency = <400000>;
+                               status = "okay";
+                               sgtl5000: codec@0a {
diff --git a/queue-3.17/arm-kirkwood-fix-dt-based-dsa.patch b/queue-3.17/arm-kirkwood-fix-dt-based-dsa.patch
new file mode 100644 (file)
index 0000000..31592c7
--- /dev/null
@@ -0,0 +1,325 @@
+From 4f5e01e96d424b54f5f0e89ee1ba9ccca03a3941 Mon Sep 17 00:00:00 2001
+From: Andrew Lunn <andrew@lunn.ch>
+Date: Mon, 1 Sep 2014 19:35:41 +0200
+Subject: ARM: Kirkwood: Fix DT based DSA.
+
+From: Andrew Lunn <andrew@lunn.ch>
+
+commit 4f5e01e96d424b54f5f0e89ee1ba9ccca03a3941 upstream.
+
+During the conversion of boards to use DT to instantiate Distributed
+Switch Architecture, nobody volunteered to test. As to be expected,
+the conversion was flawed. Testers and access to hardware has now
+become available, and this patch hopefully fixes the problems.
+
+dsa,mii-bus must be a phandle to the top level mdio node, not the port
+specific subnode of the mdio device.
+
+dsa,ethernet must be a phandle to the port subnode within the ethernet
+DT node, not the ethernet node.
+
+Don't pinctrl hog the card detect gpio for mvsdio.
+
+Rename the .dts files to make it clearer which file is for the Z0
+stepping and which for the A0 or later stepping.
+
+Signed-off-by: Andrew Lunn <andrew@lunn.ch>
+Cc: seugene@marvell.com
+Tested-by: Eugene Sanivsky <seugene@marvell.com>
+Fixes: e2eaa339af44: ("ARM: Kirkwood: convert rd88f6281-setup.c to DT.")
+Fixes: e7c8f3808be8: ("ARM: kirkwood: Convert mv88f6281gtw_ge switch setup to DT")
+Link: https://lkml.kernel.org/r/1409592941-22244-1-git-send-email-andrew@lunn.ch
+Signed-off-by: Jason Cooper <jason@lakedaemon.net>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ arch/arm/boot/dts/Makefile                     |    4 +-
+ arch/arm/boot/dts/kirkwood-mv88f6281gtw-ge.dts |   16 +++------
+ arch/arm/boot/dts/kirkwood-rd88f6281-a.dts     |   43 +++++++++++++++++++++++++
+ arch/arm/boot/dts/kirkwood-rd88f6281-a0.dts    |   26 ---------------
+ arch/arm/boot/dts/kirkwood-rd88f6281-a1.dts    |   31 ------------------
+ arch/arm/boot/dts/kirkwood-rd88f6281-z0.dts    |   35 ++++++++++++++++++++
+ arch/arm/boot/dts/kirkwood-rd88f6281.dtsi      |   27 ++-------------
+ arch/arm/boot/dts/kirkwood.dtsi                |    4 +-
+ 8 files changed, 93 insertions(+), 93 deletions(-)
+
+--- a/arch/arm/boot/dts/Makefile
++++ b/arch/arm/boot/dts/Makefile
+@@ -144,8 +144,8 @@ dtb-$(CONFIG_MACH_KIRKWOOD) += kirkwood-
+       kirkwood-openrd-client.dtb \
+       kirkwood-openrd-ultimate.dtb \
+       kirkwood-rd88f6192.dtb \
+-      kirkwood-rd88f6281-a0.dtb \
+-      kirkwood-rd88f6281-a1.dtb \
++      kirkwood-rd88f6281-z0.dtb \
++      kirkwood-rd88f6281-a.dtb \
+       kirkwood-rs212.dtb \
+       kirkwood-rs409.dtb \
+       kirkwood-rs411.dtb \
+--- a/arch/arm/boot/dts/kirkwood-mv88f6281gtw-ge.dts
++++ b/arch/arm/boot/dts/kirkwood-mv88f6281gtw-ge.dts
+@@ -123,11 +123,11 @@
+       dsa@0 {
+               compatible = "marvell,dsa";
+-              #address-cells = <2>;
++              #address-cells = <1>;
+               #size-cells = <0>;
+-              dsa,ethernet = <&eth0>;
+-              dsa,mii-bus = <&ethphy0>;
++              dsa,ethernet = <&eth0port>;
++              dsa,mii-bus = <&mdio>;
+               switch@0 {
+                       #address-cells = <1>;
+@@ -169,17 +169,13 @@
+ &mdio {
+       status = "okay";
+-
+-      ethphy0: ethernet-phy@ff {
+-              reg = <0xff>;   /* No phy attached */
+-              speed = <1000>;
+-              duplex = <1>;
+-      };
+ };
+ &eth0 {
+       status = "okay";
++
+       ethernet0-port@0 {
+-              phy-handle = <&ethphy0>;
++              speed = <1000>;
++              duplex = <1>;
+       };
+ };
+--- /dev/null
++++ b/arch/arm/boot/dts/kirkwood-rd88f6281-a.dts
+@@ -0,0 +1,43 @@
++/*
++ * Marvell RD88F6181 A Board descrition
++ *
++ * Andrew Lunn <andrew@lunn.ch>
++ *
++ * This file is licensed under the terms of the GNU General Public
++ * License version 2.  This program is licensed "as is" without any
++ * warranty of any kind, whether express or implied.
++ *
++ * This file contains the definitions for the board with the A0 or
++ * higher stepping of the SoC. The ethernet switch does not have a
++ * "wan" port.
++ */
++
++/dts-v1/;
++#include "kirkwood-rd88f6281.dtsi"
++
++/ {
++      model = "Marvell RD88f6281 Reference design, with A0 or higher SoC";
++      compatible = "marvell,rd88f6281-a", "marvell,rd88f6281","marvell,kirkwood-88f6281", "marvell,kirkwood";
++
++      dsa@0 {
++              switch@0 {
++                      reg = <10 0>;    /* MDIO address 10, switch 0 in tree */
++              };
++      };
++};
++
++&mdio {
++      status = "okay";
++
++      ethphy1: ethernet-phy@11 {
++               reg = <11>;
++      };
++};
++
++&eth1 {
++      status = "okay";
++
++      ethernet1-port@0 {
++               phy-handle = <&ethphy1>;
++      };
++};
+--- a/arch/arm/boot/dts/kirkwood-rd88f6281-a0.dts
++++ /dev/null
+@@ -1,26 +0,0 @@
+-/*
+- * Marvell RD88F6181 A0 Board descrition
+- *
+- * Andrew Lunn <andrew@lunn.ch>
+- *
+- * This file is licensed under the terms of the GNU General Public
+- * License version 2.  This program is licensed "as is" without any
+- * warranty of any kind, whether express or implied.
+- *
+- * This file contains the definitions for the board with the A0 variant of
+- * the SoC. The ethernet switch does not have a "wan" port.
+- */
+-
+-/dts-v1/;
+-#include "kirkwood-rd88f6281.dtsi"
+-
+-/ {
+-      model = "Marvell RD88f6281 Reference design, with A0 SoC";
+-      compatible = "marvell,rd88f6281-a0", "marvell,rd88f6281","marvell,kirkwood-88f6281", "marvell,kirkwood";
+-
+-      dsa@0 {
+-              switch@0 {
+-                      reg = <10 0>;    /* MDIO address 10, switch 0 in tree */
+-              };
+-      };
+-};
+\ No newline at end of file
+--- a/arch/arm/boot/dts/kirkwood-rd88f6281-a1.dts
++++ /dev/null
+@@ -1,31 +0,0 @@
+-/*
+- * Marvell RD88F6181 A1 Board descrition
+- *
+- * Andrew Lunn <andrew@lunn.ch>
+- *
+- * This file is licensed under the terms of the GNU General Public
+- * License version 2.  This program is licensed "as is" without any
+- * warranty of any kind, whether express or implied.
+- *
+- * This file contains the definitions for the board with the A1 variant of
+- * the SoC. The ethernet switch has a "wan" port.
+- */
+-
+-/dts-v1/;
+-
+-#include "kirkwood-rd88f6281.dtsi"
+-
+-/ {
+-      model = "Marvell RD88f6281 Reference design, with A1 SoC";
+-      compatible = "marvell,rd88f6281-a1", "marvell,rd88f6281","marvell,kirkwood-88f6281", "marvell,kirkwood";
+-
+-      dsa@0 {
+-              switch@0 {
+-                      reg = <0 0>;    /* MDIO address 0, switch 0 in tree */
+-                      port@4 {
+-                              reg = <4>;
+-                              label = "wan";
+-                      };
+-              };
+-      };
+-};
+\ No newline at end of file
+--- /dev/null
++++ b/arch/arm/boot/dts/kirkwood-rd88f6281-z0.dts
+@@ -0,0 +1,35 @@
++/*
++ * Marvell RD88F6181 Z0 stepping descrition
++ *
++ * Andrew Lunn <andrew@lunn.ch>
++ *
++ * This file is licensed under the terms of the GNU General Public
++ * License version 2.  This program is licensed "as is" without any
++ * warranty of any kind, whether express or implied.
++ *
++ * This file contains the definitions for the board using the Z0
++ * stepping of the SoC. The ethernet switch has a "wan" port.
++*/
++
++/dts-v1/;
++
++#include "kirkwood-rd88f6281.dtsi"
++
++/ {
++      model = "Marvell RD88f6281 Reference design, with Z0 SoC";
++      compatible = "marvell,rd88f6281-z0", "marvell,rd88f6281","marvell,kirkwood-88f6281", "marvell,kirkwood";
++
++      dsa@0 {
++              switch@0 {
++                      reg = <0 0>;    /* MDIO address 0, switch 0 in tree */
++                      port@4 {
++                              reg = <4>;
++                              label = "wan";
++                      };
++              };
++      };
++};
++
++&eth1 {
++      status = "disabled";
++};
+--- a/arch/arm/boot/dts/kirkwood-rd88f6281.dtsi
++++ b/arch/arm/boot/dts/kirkwood-rd88f6281.dtsi
+@@ -37,7 +37,6 @@
+       ocp@f1000000 {
+               pinctrl: pin-controller@10000 {
+-                      pinctrl-0 = <&pmx_sdio_cd>;
+                       pinctrl-names = "default";
+                       pmx_sdio_cd: pmx-sdio-cd {
+@@ -69,8 +68,8 @@
+               #address-cells = <2>;
+               #size-cells = <0>;
+-              dsa,ethernet = <&eth0>;
+-              dsa,mii-bus = <&ethphy1>;
++              dsa,ethernet = <&eth0port>;
++              dsa,mii-bus = <&mdio>;
+               switch@0 {
+                       #address-cells = <1>;
+@@ -119,35 +118,19 @@
+       };
+       partition@300000 {
+-              label = "data";
++              label = "rootfs";
+               reg = <0x0300000 0x500000>;
+       };
+ };
+ &mdio {
+       status = "okay";
+-
+-      ethphy0: ethernet-phy@0 {
+-              reg = <0>;
+-      };
+-
+-      ethphy1: ethernet-phy@ff {
+-              reg = <0xff>; /* No PHY attached */
+-              speed = <1000>;
+-              duple = <1>;
+-      };
+ };
+ &eth0 {
+       status = "okay";
+       ethernet0-port@0 {
+-              phy-handle = <&ethphy0>;
+-      };
+-};
+-
+-&eth1 {
+-      status = "okay";
+-      ethernet1-port@0 {
+-              phy-handle = <&ethphy1>;
++              speed = <1000>;
++              duplex = <1>;
+       };
+ };
+--- a/arch/arm/boot/dts/kirkwood.dtsi
++++ b/arch/arm/boot/dts/kirkwood.dtsi
+@@ -309,7 +309,7 @@
+                       marvell,tx-checksum-limit = <1600>;
+                       status = "disabled";
+-                      ethernet0-port@0 {
++                      eth0port: ethernet0-port@0 {
+                               compatible = "marvell,kirkwood-eth-port";
+                               reg = <0>;
+                               interrupts = <11>;
+@@ -342,7 +342,7 @@
+                       pinctrl-names = "default";
+                       status = "disabled";
+-                      ethernet1-port@0 {
++                      eth1port: ethernet1-port@0 {
+                               compatible = "marvell,kirkwood-eth-port";
+                               reg = <0>;
+                               interrupts = <15>;
diff --git a/queue-3.17/arm-mvebu-netgear-rn102-use-hardware-bch-ecc.patch b/queue-3.17/arm-mvebu-netgear-rn102-use-hardware-bch-ecc.patch
new file mode 100644 (file)
index 0000000..e4e73ad
--- /dev/null
@@ -0,0 +1,44 @@
+From ace8578182dc347b043c0825b9873f62fdaa5b77 Mon Sep 17 00:00:00 2001
+From: "klightspeed@killerwolves.net" <klightspeed@killerwolves.net>
+Date: Wed, 10 Sep 2014 18:55:41 +1000
+Subject: ARM: mvebu: Netgear RN102: Use Hardware BCH ECC
+
+From: "klightspeed@killerwolves.net" <klightspeed@killerwolves.net>
+
+commit ace8578182dc347b043c0825b9873f62fdaa5b77 upstream.
+
+The bootloader on the Netgear ReadyNAS RN102 uses Hardware BCH ECC
+(strength = 4), while the pxa3xx NAND driver by default uses
+Hamming ECC (strength = 1).
+
+This patch changes the ECC mode on these machines to match that
+of the bootloader and of the stock firmware. That way, it is
+now possible to update the kernel from userland (e.g. using
+standard tools from mtd-utils package); u-boot will happily
+load and boot it.
+
+Fixes: 92beaccd8b49 ("ARM: mvebu: Enable NAND controller in ReadyNAS 102 .dts file")
+Signed-off-by: Ben Peddell <klightspeed@killerwolves.net>
+Acked-by: Ezequiel Garcia <ezequiel.garcia@free-electrons.com>
+Tested-by: Arnaud Ebalard <arno@natisbad.org>
+Link: https://lkml.kernel.org/r/1410339341-3372-1-git-send-email-klightspeed@killerwolves.net
+Signed-off-by: Jason Cooper <jason@lakedaemon.net>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ arch/arm/boot/dts/armada-370-netgear-rn102.dts |    4 ++++
+ 1 file changed, 4 insertions(+)
+
+--- a/arch/arm/boot/dts/armada-370-netgear-rn102.dts
++++ b/arch/arm/boot/dts/armada-370-netgear-rn102.dts
+@@ -143,6 +143,10 @@
+                               marvell,nand-enable-arbiter;
+                               nand-on-flash-bbt;
++                              /* Use Hardware BCH ECC */
++                              nand-ecc-strength = <4>;
++                              nand-ecc-step-size = <512>;
++
+                               partition@0 {
+                                       label = "u-boot";
+                                       reg = <0x0000000 0x180000>;  /* 1.5MB */
diff --git a/queue-3.17/arm-mvebu-netgear-rn104-use-hardware-bch-ecc.patch b/queue-3.17/arm-mvebu-netgear-rn104-use-hardware-bch-ecc.patch
new file mode 100644 (file)
index 0000000..637d949
--- /dev/null
@@ -0,0 +1,46 @@
+From 225b94cdf719d0bc522a354bdafc18e5da5ff83b Mon Sep 17 00:00:00 2001
+From: Arnaud Ebalard <arno@natisbad.org>
+Date: Sat, 6 Sep 2014 22:49:25 +0200
+Subject: ARM: mvebu: Netgear RN104: Use Hardware BCH ECC
+
+From: Arnaud Ebalard <arno@natisbad.org>
+
+commit 225b94cdf719d0bc522a354bdafc18e5da5ff83b upstream.
+
+The bootloader on the Netgear ReadyNAS RN104 uses Hardware BCH
+ECC (strength = 4), while the pxa3xx NAND driver by default uses
+Hamming ECC (strength = 1).
+
+This patch changes the ECC mode on these machines to match that
+of the bootloader and of the stock firmware. That way, it is
+now possible to update the kernel from userland (e.g. using
+standard tools from mtd-utils package); u-boot will happily
+load and boot it.
+
+The issue was initially reported and fixed by Ben Pedell for
+RN102. The RN104 shares the same Hynix H27U1G8F2BTR NAND
+flash and setup. This patch is based on Ben's fix for RN102.
+
+Fixes: 0373a558bd79 ("ARM: mvebu: Enable NAND controller in ReadyNAS 104 .dts file")
+Signed-off-by: Arnaud Ebalard <arno@natisbad.org>
+Link: https://lkml.kernel.org/r/920c7e7169dc6aaaa3eb4bced2336d38e77b8864.1410035142.git.arno@natisbad.org
+Signed-off-by: Jason Cooper <jason@lakedaemon.net>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ arch/arm/boot/dts/armada-370-netgear-rn104.dts |    4 ++++
+ 1 file changed, 4 insertions(+)
+
+--- a/arch/arm/boot/dts/armada-370-netgear-rn104.dts
++++ b/arch/arm/boot/dts/armada-370-netgear-rn104.dts
+@@ -145,6 +145,10 @@
+                               marvell,nand-enable-arbiter;
+                               nand-on-flash-bbt;
++                              /* Use Hardware BCH ECC */
++                              nand-ecc-strength = <4>;
++                              nand-ecc-step-size = <512>;
++
+                               partition@0 {
+                                       label = "u-boot";
+                                       reg = <0x0000000 0x180000>;  /* 1.5MB */
diff --git a/queue-3.17/arm-mvebu-netgear-rn2120-use-hardware-bch-ecc.patch b/queue-3.17/arm-mvebu-netgear-rn2120-use-hardware-bch-ecc.patch
new file mode 100644 (file)
index 0000000..a504929
--- /dev/null
@@ -0,0 +1,46 @@
+From 500abb6ccb9e3f8d638a7f422443a8549245ef90 Mon Sep 17 00:00:00 2001
+From: Arnaud Ebalard <arno@natisbad.org>
+Date: Sat, 6 Sep 2014 22:49:38 +0200
+Subject: ARM: mvebu: Netgear RN2120: Use Hardware BCH ECC
+
+From: Arnaud Ebalard <arno@natisbad.org>
+
+commit 500abb6ccb9e3f8d638a7f422443a8549245ef90 upstream.
+
+The bootloader on the Netgear ReadyNAS RN2120 uses Hardware BCH
+ECC (strength = 4), while the pxa3xx NAND driver by default uses
+Hamming ECC (strength = 1).
+
+This patch changes the ECC mode on these machines to match that
+of the bootloader and of the stock firmware. That way, it is
+now possible to update the kernel from userland (e.g. using
+standard tools from mtd-utils package); u-boot will happily
+load and boot it.
+
+The issue was initially reported and fixed by Ben Pedell for
+RN102. The RN2120 shares the same Hynix H27U1G8F2BTR NAND
+flash and setup. This patch is based on Ben's fix for RN102.
+
+Fixes: ad51eddd95ad ("ARM: mvebu: Enable NAND controller in ReadyNAS 2120 .dts file")
+Signed-off-by: Arnaud Ebalard <arno@natisbad.org>
+Link: https://lkml.kernel.org/r/61f6a1b7ad0adc57a0e201b9680bc2e5f214a317.1410035142.git.arno@natisbad.org
+Signed-off-by: Jason Cooper <jason@lakedaemon.net>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ arch/arm/boot/dts/armada-xp-netgear-rn2120.dts |    4 ++++
+ 1 file changed, 4 insertions(+)
+
+--- a/arch/arm/boot/dts/armada-xp-netgear-rn2120.dts
++++ b/arch/arm/boot/dts/armada-xp-netgear-rn2120.dts
+@@ -223,6 +223,10 @@
+                               marvell,nand-enable-arbiter;
+                               nand-on-flash-bbt;
++                              /* Use Hardware BCH ECC */
++                              nand-ecc-strength = <4>;
++                              nand-ecc-step-size = <512>;
++
+                               partition@0 {
+                                       label = "u-boot";
+                                       reg = <0x0000000 0x180000>;  /* 1.5MB */
diff --git a/queue-3.17/arm64-compat-fix-compat-types-affecting-struct.patch b/queue-3.17/arm64-compat-fix-compat-types-affecting-struct.patch
new file mode 100644 (file)
index 0000000..ba5d6a3
--- /dev/null
@@ -0,0 +1,40 @@
+From 971a5b6fe634bb7b617d8c5f25b6a3ddbc600194 Mon Sep 17 00:00:00 2001
+From: Victor Kamensky <victor.kamensky@linaro.org>
+Date: Tue, 14 Oct 2014 06:55:05 +0100
+Subject: arm64: compat: fix compat types affecting struct
+ compat_elf_prpsinfo
+
+From: Victor Kamensky <victor.kamensky@linaro.org>
+
+commit 971a5b6fe634bb7b617d8c5f25b6a3ddbc600194 upstream.
+
+The compat_elf_prpsinfo structure does not match the arch/arm struct
+elf_pspsinfo definition. As result NT_PRPSINFO note in core file
+created by arm64 kernel for aarch32 (compat) process has wrong size.
+So gdb cannot display command that caused process crash.
+
+Fix is to change size of __compat_uid_t, __compat_gid_t so it would
+match size of similar fields in arch/arm case.
+
+Signed-off-by: Victor Kamensky <victor.kamensky@linaro.org>
+Acked-by: Arnd Bergmann <arnd@arndb.de>
+Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ arch/arm64/include/asm/compat.h |    4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+--- a/arch/arm64/include/asm/compat.h
++++ b/arch/arm64/include/asm/compat.h
+@@ -37,8 +37,8 @@ typedef s32          compat_ssize_t;
+ typedef s32           compat_time_t;
+ typedef s32           compat_clock_t;
+ typedef s32           compat_pid_t;
+-typedef u32           __compat_uid_t;
+-typedef u32           __compat_gid_t;
++typedef u16           __compat_uid_t;
++typedef u16           __compat_gid_t;
+ typedef u16           __compat_uid16_t;
+ typedef u16           __compat_gid16_t;
+ typedef u32           __compat_uid32_t;
diff --git a/queue-3.17/arm64-fix-compilation-error-on-up-builds.patch b/queue-3.17/arm64-fix-compilation-error-on-up-builds.patch
new file mode 100644 (file)
index 0000000..c8d2614
--- /dev/null
@@ -0,0 +1,55 @@
+From ceab3fe69408cb98f437dad3b4b4bb79434370ef Mon Sep 17 00:00:00 2001
+From: Catalin Marinas <catalin.marinas@arm.com>
+Date: Tue, 21 Oct 2014 17:01:07 +0100
+Subject: arm64: Fix compilation error on UP builds
+
+From: Catalin Marinas <catalin.marinas@arm.com>
+
+commit ceab3fe69408cb98f437dad3b4b4bb79434370ef upstream.
+
+In file included from ./arch/arm64/include/asm/irq_work.h:4:0,
+        from include/linux/irq_work.h:46,
+        from include/linux/perf_event.h:49,
+        from include/linux/ftrace_event.h:9,
+        from include/trace/syscall.h:6,
+        from include/linux/syscalls.h:81,
+        from init/main.c:18:
+./arch/arm64/include/asm/smp.h:24:3:
+        error: #error "<asm/smp.h> included in non-SMP build"
+ # error "<asm/smp.h> included in non-SMP build"
+
+Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
+Fixes: 3631073659d0 ("arm64: Tell irq work about self IPI support")
+Reported-by: Guenter Roeck <linux@roeck-us.net>
+Tested-by: Guenter Roeck <linux@roeck-us.net>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ arch/arm64/include/asm/irq_work.h |   11 +++++++++++
+ 1 file changed, 11 insertions(+)
+
+--- a/arch/arm64/include/asm/irq_work.h
++++ b/arch/arm64/include/asm/irq_work.h
+@@ -1,6 +1,8 @@
+ #ifndef __ASM_IRQ_WORK_H
+ #define __ASM_IRQ_WORK_H
++#ifdef CONFIG_SMP
++
+ #include <asm/smp.h>
+ static inline bool arch_irq_work_has_interrupt(void)
+@@ -8,4 +10,13 @@ static inline bool arch_irq_work_has_int
+       return !!__smp_cross_call;
+ }
++#else
++
++static inline bool arch_irq_work_has_interrupt(void)
++{
++      return false;
++}
++
++#endif
++
+ #endif /* __ASM_IRQ_WORK_H */
diff --git a/queue-3.17/clk-qcom-add-ipq8064-pll-required-for-usb.patch b/queue-3.17/clk-qcom-add-ipq8064-pll-required-for-usb.patch
new file mode 100644 (file)
index 0000000..755c4f0
--- /dev/null
@@ -0,0 +1,75 @@
+From dc1b3f657f25798b2dc9ed8928b80eb3183019a2 Mon Sep 17 00:00:00 2001
+From: Andy Gross <agross@codeaurora.org>
+Date: Tue, 16 Sep 2014 16:04:12 -0500
+Subject: clk: qcom: Add IPQ8064 PLL required for USB
+
+From: Andy Gross <agross@codeaurora.org>
+
+commit dc1b3f657f25798b2dc9ed8928b80eb3183019a2 upstream.
+
+This patch adds the PLL0 that is required for the USB clocks to
+work properly.
+
+Signed-off-by: Andy Gross <agross@codeaurora.org>
+Fixes: 24d8fba44af3 "clk: qcom: Add support for IPQ8064's global clock controller (GCC)"
+Signed-off-by: Stephen Boyd <sboyd@codeaurora.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/clk/qcom/gcc-ipq806x.c |   31 ++++++++++++++++++++++++++++++-
+ 1 file changed, 30 insertions(+), 1 deletion(-)
+
+--- a/drivers/clk/qcom/gcc-ipq806x.c
++++ b/drivers/clk/qcom/gcc-ipq806x.c
+@@ -32,6 +32,33 @@
+ #include "clk-branch.h"
+ #include "reset.h"
++static struct clk_pll pll0 = {
++      .l_reg = 0x30c4,
++      .m_reg = 0x30c8,
++      .n_reg = 0x30cc,
++      .config_reg = 0x30d4,
++      .mode_reg = 0x30c0,
++      .status_reg = 0x30d8,
++      .status_bit = 16,
++      .clkr.hw.init = &(struct clk_init_data){
++              .name = "pll0",
++              .parent_names = (const char *[]){ "pxo" },
++              .num_parents = 1,
++              .ops = &clk_pll_ops,
++      },
++};
++
++static struct clk_regmap pll0_vote = {
++      .enable_reg = 0x34c0,
++      .enable_mask = BIT(0),
++      .hw.init = &(struct clk_init_data){
++              .name = "pll0_vote",
++              .parent_names = (const char *[]){ "pll0" },
++              .num_parents = 1,
++              .ops = &clk_pll_vote_ops,
++      },
++};
++
+ static struct clk_pll pll3 = {
+       .l_reg = 0x3164,
+       .m_reg = 0x3168,
+@@ -154,7 +181,7 @@ static const u8 gcc_pxo_pll8_pll0[] = {
+ static const char *gcc_pxo_pll8_pll0_map[] = {
+       "pxo",
+       "pll8_vote",
+-      "pll0",
++      "pll0_vote",
+ };
+ static struct freq_tbl clk_tbl_gsbi_uart[] = {
+@@ -2133,6 +2160,8 @@ static struct clk_branch usb_fs1_h_clk =
+ };
+ static struct clk_regmap *gcc_ipq806x_clks[] = {
++      [PLL0] = &pll0.clkr,
++      [PLL0_VOTE] = &pll0_vote,
+       [PLL3] = &pll3.clkr,
+       [PLL8] = &pll8.clkr,
+       [PLL8_VOTE] = &pll8_vote,
diff --git a/queue-3.17/ecryptfs-avoid-to-access-null-pointer-when-write-metadata-in-xattr.patch b/queue-3.17/ecryptfs-avoid-to-access-null-pointer-when-write-metadata-in-xattr.patch
new file mode 100644 (file)
index 0000000..29dc375
--- /dev/null
@@ -0,0 +1,87 @@
+From 35425ea2492175fd39f6116481fe98b2b3ddd4ca Mon Sep 17 00:00:00 2001
+From: Chao Yu <chao2.yu@samsung.com>
+Date: Thu, 24 Jul 2014 17:25:42 +0800
+Subject: ecryptfs: avoid to access NULL pointer when write metadata in xattr
+
+From: Chao Yu <chao2.yu@samsung.com>
+
+commit 35425ea2492175fd39f6116481fe98b2b3ddd4ca upstream.
+
+Christopher Head 2014-06-28 05:26:20 UTC described:
+"I tried to reproduce this on 3.12.21. Instead, when I do "echo hello > foo"
+in an ecryptfs mount with ecryptfs_xattr specified, I get a kernel crash:
+
+BUG: unable to handle kernel NULL pointer dereference at           (null)
+IP: [<ffffffff8110eb39>] fsstack_copy_attr_all+0x2/0x61
+PGD d7840067 PUD b2c3c067 PMD 0
+Oops: 0002 [#1] SMP
+Modules linked in: nvidia(PO)
+CPU: 3 PID: 3566 Comm: bash Tainted: P           O 3.12.21-gentoo-r1 #2
+Hardware name: ASUSTek Computer Inc. G60JX/G60JX, BIOS 206 03/15/2010
+task: ffff8801948944c0 ti: ffff8800bad70000 task.ti: ffff8800bad70000
+RIP: 0010:[<ffffffff8110eb39>]  [<ffffffff8110eb39>] fsstack_copy_attr_all+0x2/0x61
+RSP: 0018:ffff8800bad71c10  EFLAGS: 00010246
+RAX: 00000000000181a4 RBX: ffff880198648480 RCX: 0000000000000000
+RDX: 0000000000000004 RSI: ffff880172010450 RDI: 0000000000000000
+RBP: ffff880198490e40 R08: 0000000000000000 R09: 0000000000000000
+R10: ffff880172010450 R11: ffffea0002c51e80 R12: 0000000000002000
+R13: 000000000000001a R14: 0000000000000000 R15: ffff880198490e40
+FS:  00007ff224caa700(0000) GS:ffff88019fcc0000(0000) knlGS:0000000000000000
+CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
+CR2: 0000000000000000 CR3: 00000000bb07f000 CR4: 00000000000007e0
+Stack:
+ffffffff811826e8 ffff8800a39d8000 0000000000000000 000000000000001a
+ffff8800a01d0000 ffff8800a39d8000 ffffffff81185fd5 ffffffff81082c2c
+00000001a39d8000 53d0abbc98490e40 0000000000000037 ffff8800a39d8220
+Call Trace:
+[<ffffffff811826e8>] ? ecryptfs_setxattr+0x40/0x52
+[<ffffffff81185fd5>] ? ecryptfs_write_metadata+0x1b3/0x223
+[<ffffffff81082c2c>] ? should_resched+0x5/0x23
+[<ffffffff8118322b>] ? ecryptfs_initialize_file+0xaf/0xd4
+[<ffffffff81183344>] ? ecryptfs_create+0xf4/0x142
+[<ffffffff810f8c0d>] ? vfs_create+0x48/0x71
+[<ffffffff810f9c86>] ? do_last.isra.68+0x559/0x952
+[<ffffffff810f7ce7>] ? link_path_walk+0xbd/0x458
+[<ffffffff810fa2a3>] ? path_openat+0x224/0x472
+[<ffffffff810fa7bd>] ? do_filp_open+0x2b/0x6f
+[<ffffffff81103606>] ? __alloc_fd+0xd6/0xe7
+[<ffffffff810ee6ab>] ? do_sys_open+0x65/0xe9
+[<ffffffff8157d022>] ? system_call_fastpath+0x16/0x1b
+RIP  [<ffffffff8110eb39>] fsstack_copy_attr_all+0x2/0x61
+RSP <ffff8800bad71c10>
+CR2: 0000000000000000
+---[ end trace df9dba5f1ddb8565 ]---"
+
+If we create a file when we mount with ecryptfs_xattr_metadata option, we will
+encounter a crash in this path:
+->ecryptfs_create
+  ->ecryptfs_initialize_file
+    ->ecryptfs_write_metadata
+      ->ecryptfs_write_metadata_to_xattr
+        ->ecryptfs_setxattr
+          ->fsstack_copy_attr_all
+It's because our dentry->d_inode used in fsstack_copy_attr_all is NULL, and it
+will be initialized when ecryptfs_initialize_file finish.
+
+So we should skip copying attr from lower inode when the value of ->d_inode is
+invalid.
+
+Signed-off-by: Chao Yu <chao2.yu@samsung.com>
+Signed-off-by: Tyler Hicks <tyhicks@canonical.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ fs/ecryptfs/inode.c |    2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/fs/ecryptfs/inode.c
++++ b/fs/ecryptfs/inode.c
+@@ -1039,7 +1039,7 @@ ecryptfs_setxattr(struct dentry *dentry,
+       }
+       rc = vfs_setxattr(lower_dentry, name, value, size, flags);
+-      if (!rc)
++      if (!rc && dentry->d_inode)
+               fsstack_copy_attr_all(dentry->d_inode, lower_dentry->d_inode);
+ out:
+       return rc;
index 79255fa6216463399ab964e2397c54db8951b8b9..1d46508da742709246153efedabccb9f59129a3a 100644 (file)
@@ -66,6 +66,30 @@ nfsv4.1-pnfs-replace-broken-pnfs_put_lseg_async.patch
 iwlwifi-mvm-disable-bt-co-running-by-default.patch
 iwlwifi-add-missing-pci-ids-for-the-7260-series.patch
 spi-dw-mid-terminate-ongoing-transfers-at-exit.patch
+arm64-fix-compilation-error-on-up-builds.patch
+arm64-compat-fix-compat-types-affecting-struct.patch
+alsa-pcm-use-the-same-dma-mmap-codepath-both-for-arm-and-arm64.patch
+alsa-bebob-fix-failure-to-detect-source-of-clock-for-terratec-phase-88.patch
+alsa-emu10k1-fix-deadlock-in-synth-voice-lookup.patch
+alsa-alc283-codec-avoid-pop-noise-on-headphones-during-suspend-resume.patch
+alsa-usb-audio-add-support-for-steinberg-ur22-usb-interface.patch
+alsa-hda-hdmi-fix-missing-eld-change-event-on-plug-unplug.patch
+alsa-hda-fix-inverted-led-gpio-setup-for-lenovo-ideapad.patch
+alsa-hda-add-missing-terminating-entry-to-snd_hda_pin_quirk-macro.patch
+clk-qcom-add-ipq8064-pll-required-for-usb.patch
+arm-at91-dt-fix-typo-regarding-can0_clk.patch
+arm-at91-fix-at91sam9263ek-dt-mmc-pinmuxing-settings.patch
+arm-at91-pmc-don-t-forget-to-write-pmc_pcdr-register-to-disable-clocks.patch
+arm-kirkwood-fix-dt-based-dsa.patch
+arm-mvebu-netgear-rn104-use-hardware-bch-ecc.patch
+arm-mvebu-netgear-rn2120-use-hardware-bch-ecc.patch
+arm-mvebu-netgear-rn102-use-hardware-bch-ecc.patch
+arm-dts-imx28-evk-let-i2c0-run-at-100khz.patch
+ecryptfs-avoid-to-access-null-pointer-when-write-metadata-in-xattr.patch
+udf-fix-loading-of-special-inodes.patch
+vfio-pci-fix-remove-path-locking.patch
+xfs-ensure-wb_sync_all-writeback-handles-partial-pages-correctly.patch
+xfs-fix-agno-increment-in-xfs_inumbers-loop.patch
 pci-mvebu-fix-uninitialized-variable-in-mvebu_get_tgt_attr.patch
 pci-add-missing-mem_64-mask-in-pci_assign_unassigned_bridge_resources.patch
 pci-increase-ibm-ipr-sas-crocodile-bars-to-at-least-system-page-size.patch
diff --git a/queue-3.17/udf-fix-loading-of-special-inodes.patch b/queue-3.17/udf-fix-loading-of-special-inodes.patch
new file mode 100644 (file)
index 0000000..ea17bf5
--- /dev/null
@@ -0,0 +1,141 @@
+From 6174c2eb8ecef271159bdcde460ce8af54d8f72f Mon Sep 17 00:00:00 2001
+From: Jan Kara <jack@suse.cz>
+Date: Thu, 9 Oct 2014 12:52:16 +0200
+Subject: udf: Fix loading of special inodes
+
+From: Jan Kara <jack@suse.cz>
+
+commit 6174c2eb8ecef271159bdcde460ce8af54d8f72f upstream.
+
+Some UDF media have special inodes (like VAT or metadata partition
+inodes) whose link_count is 0. Thus commit 4071b9136223 (udf: Properly
+detect stale inodes) broke loading these inodes because udf_iget()
+started returning -ESTALE for them. Since we still need to properly
+detect stale inodes queried by NFS, create two variants of udf_iget() -
+one which is used for looking up special inodes (which ignores
+link_count == 0) and one which is used for other cases which return
+ESTALE when link_count == 0.
+
+Fixes: 4071b913622316970d0e1919f7d82b4403fec5f2
+Signed-off-by: Jan Kara <jack@suse.cz>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ fs/udf/inode.c   |   14 +++++++++-----
+ fs/udf/super.c   |   10 +++++-----
+ fs/udf/udfdecl.h |   13 ++++++++++++-
+ 3 files changed, 26 insertions(+), 11 deletions(-)
+
+--- a/fs/udf/inode.c
++++ b/fs/udf/inode.c
+@@ -1277,7 +1277,7 @@ update_time:
+  */
+ #define UDF_MAX_ICB_NESTING 1024
+-static int udf_read_inode(struct inode *inode)
++static int udf_read_inode(struct inode *inode, bool hidden_inode)
+ {
+       struct buffer_head *bh = NULL;
+       struct fileEntry *fe;
+@@ -1436,8 +1436,11 @@ reread:
+       link_count = le16_to_cpu(fe->fileLinkCount);
+       if (!link_count) {
+-              ret = -ESTALE;
+-              goto out;
++              if (!hidden_inode) {
++                      ret = -ESTALE;
++                      goto out;
++              }
++              link_count = 1;
+       }
+       set_nlink(inode, link_count);
+@@ -1826,7 +1829,8 @@ out:
+       return err;
+ }
+-struct inode *udf_iget(struct super_block *sb, struct kernel_lb_addr *ino)
++struct inode *__udf_iget(struct super_block *sb, struct kernel_lb_addr *ino,
++                       bool hidden_inode)
+ {
+       unsigned long block = udf_get_lb_pblock(sb, ino, 0);
+       struct inode *inode = iget_locked(sb, block);
+@@ -1839,7 +1843,7 @@ struct inode *udf_iget(struct super_bloc
+               return inode;
+       memcpy(&UDF_I(inode)->i_location, ino, sizeof(struct kernel_lb_addr));
+-      err = udf_read_inode(inode);
++      err = udf_read_inode(inode, hidden_inode);
+       if (err < 0) {
+               iget_failed(inode);
+               return ERR_PTR(err);
+--- a/fs/udf/super.c
++++ b/fs/udf/super.c
+@@ -959,7 +959,7 @@ struct inode *udf_find_metadata_inode_ef
+       addr.logicalBlockNum = meta_file_loc;
+       addr.partitionReferenceNum = partition_num;
+-      metadata_fe = udf_iget(sb, &addr);
++      metadata_fe = udf_iget_special(sb, &addr);
+       if (IS_ERR(metadata_fe)) {
+               udf_warn(sb, "metadata inode efe not found\n");
+@@ -1020,7 +1020,7 @@ static int udf_load_metadata_files(struc
+               udf_debug("Bitmap file location: block = %d part = %d\n",
+                         addr.logicalBlockNum, addr.partitionReferenceNum);
+-              fe = udf_iget(sb, &addr);
++              fe = udf_iget_special(sb, &addr);
+               if (IS_ERR(fe)) {
+                       if (sb->s_flags & MS_RDONLY)
+                               udf_warn(sb, "bitmap inode efe not found but it's ok since the disc is mounted read-only\n");
+@@ -1119,7 +1119,7 @@ static int udf_fill_partdesc_info(struct
+               };
+               struct inode *inode;
+-              inode = udf_iget(sb, &loc);
++              inode = udf_iget_special(sb, &loc);
+               if (IS_ERR(inode)) {
+                       udf_debug("cannot load unallocSpaceTable (part %d)\n",
+                                 p_index);
+@@ -1154,7 +1154,7 @@ static int udf_fill_partdesc_info(struct
+               };
+               struct inode *inode;
+-              inode = udf_iget(sb, &loc);
++              inode = udf_iget_special(sb, &loc);
+               if (IS_ERR(inode)) {
+                       udf_debug("cannot load freedSpaceTable (part %d)\n",
+                                 p_index);
+@@ -1198,7 +1198,7 @@ static void udf_find_vat_block(struct su
+            vat_block >= map->s_partition_root &&
+            vat_block >= start_block - 3; vat_block--) {
+               ino.logicalBlockNum = vat_block - map->s_partition_root;
+-              inode = udf_iget(sb, &ino);
++              inode = udf_iget_special(sb, &ino);
+               if (!IS_ERR(inode)) {
+                       sbi->s_vat_inode = inode;
+                       break;
+--- a/fs/udf/udfdecl.h
++++ b/fs/udf/udfdecl.h
+@@ -138,7 +138,18 @@ extern int udf_write_fi(struct inode *in
+ /* file.c */
+ extern long udf_ioctl(struct file *, unsigned int, unsigned long);
+ /* inode.c */
+-extern struct inode *udf_iget(struct super_block *, struct kernel_lb_addr *);
++extern struct inode *__udf_iget(struct super_block *, struct kernel_lb_addr *,
++                              bool hidden_inode);
++static inline struct inode *udf_iget_special(struct super_block *sb,
++                                           struct kernel_lb_addr *ino)
++{
++      return __udf_iget(sb, ino, true);
++}
++static inline struct inode *udf_iget(struct super_block *sb,
++                                   struct kernel_lb_addr *ino)
++{
++      return __udf_iget(sb, ino, false);
++}
+ extern int udf_expand_file_adinicb(struct inode *);
+ extern struct buffer_head *udf_expand_dir_adinicb(struct inode *, int *, int *);
+ extern struct buffer_head *udf_bread(struct inode *, int, int, int *);
diff --git a/queue-3.17/vfio-pci-fix-remove-path-locking.patch b/queue-3.17/vfio-pci-fix-remove-path-locking.patch
new file mode 100644 (file)
index 0000000..c1d9676
--- /dev/null
@@ -0,0 +1,207 @@
+From 93899a679fd6b2534b5c297d9316bae039ebcbe1 Mon Sep 17 00:00:00 2001
+From: Alex Williamson <alex.williamson@redhat.com>
+Date: Mon, 29 Sep 2014 17:18:39 -0600
+Subject: vfio-pci: Fix remove path locking
+
+From: Alex Williamson <alex.williamson@redhat.com>
+
+commit 93899a679fd6b2534b5c297d9316bae039ebcbe1 upstream.
+
+Locking both the remove() and release() path results in a deadlock
+that should have been obvious.  To fix this we can get and hold the
+vfio_device reference as we evaluate whether to do a bus/slot reset.
+This will automatically block any remove() calls, allowing us to
+remove the explict lock.  Fixes 61d792562b53.
+
+Signed-off-by: Alex Williamson <alex.williamson@redhat.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/vfio/pci/vfio_pci.c |  138 ++++++++++++++++++--------------------------
+ 1 file changed, 58 insertions(+), 80 deletions(-)
+
+--- a/drivers/vfio/pci/vfio_pci.c
++++ b/drivers/vfio/pci/vfio_pci.c
+@@ -876,15 +876,11 @@ static void vfio_pci_remove(struct pci_d
+ {
+       struct vfio_pci_device *vdev;
+-      mutex_lock(&driver_lock);
+-
+       vdev = vfio_del_group_dev(&pdev->dev);
+       if (vdev) {
+               iommu_group_put(pdev->dev.iommu_group);
+               kfree(vdev);
+       }
+-
+-      mutex_unlock(&driver_lock);
+ }
+ static pci_ers_result_t vfio_pci_aer_err_detected(struct pci_dev *pdev,
+@@ -927,108 +923,90 @@ static struct pci_driver vfio_pci_driver
+       .err_handler    = &vfio_err_handlers,
+ };
+-/*
+- * Test whether a reset is necessary and possible.  We mark devices as
+- * needs_reset when they are released, but don't have a function-local reset
+- * available.  If any of these exist in the affected devices, we want to do
+- * a bus/slot reset.  We also need all of the affected devices to be unused,
+- * so we abort if any device has a non-zero refcnt.  driver_lock prevents a
+- * device from being opened during the scan or unbound from vfio-pci.
+- */
+-static int vfio_pci_test_bus_reset(struct pci_dev *pdev, void *data)
+-{
+-      bool *needs_reset = data;
+-      struct pci_driver *pci_drv = ACCESS_ONCE(pdev->driver);
+-      int ret = -EBUSY;
+-
+-      if (pci_drv == &vfio_pci_driver) {
+-              struct vfio_device *device;
+-              struct vfio_pci_device *vdev;
+-
+-              device = vfio_device_get_from_dev(&pdev->dev);
+-              if (!device)
+-                      return ret;
+-
+-              vdev = vfio_device_data(device);
+-              if (vdev) {
+-                      if (vdev->needs_reset)
+-                              *needs_reset = true;
+-
+-                      if (!vdev->refcnt)
+-                              ret = 0;
+-              }
+-
+-              vfio_device_put(device);
+-      }
+-
+-      /*
+-       * TODO: vfio-core considers groups to be viable even if some devices
+-       * are attached to known drivers, like pci-stub or pcieport.  We can't
+-       * freeze devices from being unbound to those drivers like we can
+-       * here though, so it would be racy to test for them.  We also can't
+-       * use device_lock() to prevent changes as that would interfere with
+-       * PCI-core taking device_lock during bus reset.  For now, we require
+-       * devices to be bound to vfio-pci to get a bus/slot reset on release.
+-       */
+-
+-      return ret;
+-}
++struct vfio_devices {
++      struct vfio_device **devices;
++      int cur_index;
++      int max_index;
++};
+-/* Clear needs_reset on all affected devices after successful bus/slot reset */
+-static int vfio_pci_clear_needs_reset(struct pci_dev *pdev, void *data)
++static int vfio_pci_get_devs(struct pci_dev *pdev, void *data)
+ {
++      struct vfio_devices *devs = data;
+       struct pci_driver *pci_drv = ACCESS_ONCE(pdev->driver);
+-      if (pci_drv == &vfio_pci_driver) {
+-              struct vfio_device *device;
+-              struct vfio_pci_device *vdev;
+-
+-              device = vfio_device_get_from_dev(&pdev->dev);
+-              if (!device)
+-                      return 0;
+-
+-              vdev = vfio_device_data(device);
+-              if (vdev)
+-                      vdev->needs_reset = false;
++      if (pci_drv != &vfio_pci_driver)
++              return -EBUSY;
+-              vfio_device_put(device);
+-      }
++      if (devs->cur_index == devs->max_index)
++              return -ENOSPC;
++      devs->devices[devs->cur_index] = vfio_device_get_from_dev(&pdev->dev);
++      if (!devs->devices[devs->cur_index])
++              return -EINVAL;
++
++      devs->cur_index++;
+       return 0;
+ }
+ /*
+  * Attempt to do a bus/slot reset if there are devices affected by a reset for
+  * this device that are needs_reset and all of the affected devices are unused
+- * (!refcnt).  Callers of this function are required to hold driver_lock such
+- * that devices can not be unbound from vfio-pci or opened by a user while we
+- * test for and perform a bus/slot reset.
++ * (!refcnt).  Callers are required to hold driver_lock when calling this to
++ * prevent device opens and concurrent bus reset attempts.  We prevent device
++ * unbinds by acquiring and holding a reference to the vfio_device.
++ *
++ * NB: vfio-core considers a group to be viable even if some devices are
++ * bound to drivers like pci-stub or pcieport.  Here we require all devices
++ * to be bound to vfio_pci since that's the only way we can be sure they
++ * stay put.
+  */
+ static void vfio_pci_try_bus_reset(struct vfio_pci_device *vdev)
+ {
++      struct vfio_devices devs = { .cur_index = 0 };
++      int i = 0, ret = -EINVAL;
+       bool needs_reset = false, slot = false;
+-      int ret;
++      struct vfio_pci_device *tmp;
+       if (!pci_probe_reset_slot(vdev->pdev->slot))
+               slot = true;
+       else if (pci_probe_reset_bus(vdev->pdev->bus))
+               return;
+-      if (vfio_pci_for_each_slot_or_bus(vdev->pdev,
+-                                        vfio_pci_test_bus_reset,
+-                                        &needs_reset, slot) || !needs_reset)
++      if (vfio_pci_for_each_slot_or_bus(vdev->pdev, vfio_pci_count_devs,
++                                        &i, slot) || !i)
+               return;
+-      if (slot)
+-              ret = pci_try_reset_slot(vdev->pdev->slot);
+-      else
+-              ret = pci_try_reset_bus(vdev->pdev->bus);
+-
+-      if (ret)
++      devs.max_index = i;
++      devs.devices = kcalloc(i, sizeof(struct vfio_device *), GFP_KERNEL);
++      if (!devs.devices)
+               return;
+-      vfio_pci_for_each_slot_or_bus(vdev->pdev,
+-                                    vfio_pci_clear_needs_reset, NULL, slot);
++      if (vfio_pci_for_each_slot_or_bus(vdev->pdev,
++                                        vfio_pci_get_devs, &devs, slot))
++              goto put_devs;
++
++      for (i = 0; i < devs.cur_index; i++) {
++              tmp = vfio_device_data(devs.devices[i]);
++              if (tmp->needs_reset)
++                      needs_reset = true;
++              if (tmp->refcnt)
++                      goto put_devs;
++      }
++
++      if (needs_reset)
++              ret = slot ? pci_try_reset_slot(vdev->pdev->slot) :
++                           pci_try_reset_bus(vdev->pdev->bus);
++
++put_devs:
++      for (i = 0; i < devs.cur_index; i++) {
++              if (!ret) {
++                      tmp = vfio_device_data(devs.devices[i]);
++                      tmp->needs_reset = false;
++              }
++              vfio_device_put(devs.devices[i]);
++      }
++
++      kfree(devs.devices);
+ }
+ static void __exit vfio_pci_cleanup(void)
diff --git a/queue-3.17/xfs-ensure-wb_sync_all-writeback-handles-partial-pages-correctly.patch b/queue-3.17/xfs-ensure-wb_sync_all-writeback-handles-partial-pages-correctly.patch
new file mode 100644 (file)
index 0000000..67e8289
--- /dev/null
@@ -0,0 +1,74 @@
+From 0d085a529b427d97710e6a41f8a4f23e1757cd12 Mon Sep 17 00:00:00 2001
+From: Dave Chinner <dchinner@redhat.com>
+Date: Tue, 23 Sep 2014 15:36:27 +1000
+Subject: xfs: ensure WB_SYNC_ALL writeback handles partial pages correctly
+
+From: Dave Chinner <dchinner@redhat.com>
+
+commit 0d085a529b427d97710e6a41f8a4f23e1757cd12 upstream.
+
+XFS has been having trouble with stray delayed allocation extents
+beyond EOF for a long time. Recent changes to the collapse range
+code has triggered erroneous EBUSY errors on page invalidtion for
+block size smaller than page size filesystems. These
+have been caused by dirty buffers beyond EOF on a partial page which
+do not get written to disk during a sync.
+
+The issue is that write-ahead in xfs_cluster_write() finds such a
+partial page and handles it by leaving the page dirty but pushing it
+into a writeback state. This used to work just fine, as the
+write_cache_pages() code would then find the dirty partial page in
+the next mapping tree lookup as the dirty tag is still set.
+
+Unfortunately, when we moved to a mark and sweep approach to
+writeback to fix other writeback sync issues, we broken this. THe
+act of marking the page as under writeback now clears the TOWRITE
+tag in the radix tree, even though the page is still dirty. This
+causes the TOWRITE tag to be cleared, and hence the next lookup on
+the mapping tree does not find the dirty partial page and so doesn't
+try to write it again.
+
+This same writeback bug was found recently in ext4 and fixed in
+commit 1c8349a ("ext4: fix data integrity sync in ordered mode")
+without communication to the wider filesystem community. We can use
+exactly the same fix here so the TOWRITE flag is not cleared on
+partial page writes.
+
+cc: stable@vger.kernel.org # dependent on 1c8349a17137b93f0a83f276c764a6df1b9a116e
+Root-cause-found-by: Brian Foster <bfoster@redhat.com>
+Signed-off-by: Dave Chinner <dchinner@redhat.com>
+Reviewed-by: Brian Foster <bfoster@redhat.com>
+Signed-off-by: Dave Chinner <david@fromorbit.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ fs/xfs/xfs_aops.c |   16 ++++++++++++++--
+ 1 file changed, 14 insertions(+), 2 deletions(-)
+
+--- a/fs/xfs/xfs_aops.c
++++ b/fs/xfs/xfs_aops.c
+@@ -434,10 +434,22 @@ xfs_start_page_writeback(
+ {
+       ASSERT(PageLocked(page));
+       ASSERT(!PageWriteback(page));
+-      if (clear_dirty)
++
++      /*
++       * if the page was not fully cleaned, we need to ensure that the higher
++       * layers come back to it correctly. That means we need to keep the page
++       * dirty, and for WB_SYNC_ALL writeback we need to ensure the
++       * PAGECACHE_TAG_TOWRITE index mark is not removed so another attempt to
++       * write this page in this writeback sweep will be made.
++       */
++      if (clear_dirty) {
+               clear_page_dirty_for_io(page);
+-      set_page_writeback(page);
++              set_page_writeback(page);
++      } else
++              set_page_writeback_keepwrite(page);
++
+       unlock_page(page);
++
+       /* If no buffers on the page are to be written, finish it here */
+       if (!buffers)
+               end_page_writeback(page);
diff --git a/queue-3.17/xfs-fix-agno-increment-in-xfs_inumbers-loop.patch b/queue-3.17/xfs-fix-agno-increment-in-xfs_inumbers-loop.patch
new file mode 100644 (file)
index 0000000..8d4c671
--- /dev/null
@@ -0,0 +1,46 @@
+From a8b1ee8bafc765ebf029d03c5479a69aebff9693 Mon Sep 17 00:00:00 2001
+From: Eric Sandeen <sandeen@sandeen.net>
+Date: Mon, 13 Oct 2014 10:21:53 +1100
+Subject: xfs: fix agno increment in xfs_inumbers() loop
+
+From: Eric Sandeen <sandeen@sandeen.net>
+
+commit a8b1ee8bafc765ebf029d03c5479a69aebff9693 upstream.
+
+caused a regression in xfs_inumbers, which in turn broke
+xfsdump, causing incomplete dumps.
+
+The loop in xfs_inumbers() needs to fill the user-supplied
+buffers, and iterates via xfs_btree_increment, reading new
+ags as needed.
+
+But the first time through the loop, if xfs_btree_increment()
+succeeds, we continue, which triggers the ++agno at the bottom
+of the loop, and we skip to soon to the next ag - without
+the proper setup under next_ag to read the next ag.
+
+Fix this by removing the agno increment from the loop conditional,
+and only increment agno if we have actually hit the code under
+the next_ag: target.
+
+Signed-off-by: Eric Sandeen <sandeen@redhat.com>
+Reviewed-by: Dave Chinner <dchinner@redhat.com>
+Signed-off-by: Dave Chinner <david@fromorbit.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ fs/xfs/xfs_itable.c |    3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+--- a/fs/xfs/xfs_itable.c
++++ b/fs/xfs/xfs_itable.c
+@@ -639,7 +639,8 @@ next_ag:
+               xfs_buf_relse(agbp);
+               agbp = NULL;
+               agino = 0;
+-      } while (++agno < mp->m_sb.sb_agcount);
++              agno++;
++      } while (agno < mp->m_sb.sb_agcount);
+       if (!error) {
+               if (bufidx) {