--- /dev/null
+From 673681cafa99776e334c3e61cafa2cf115950c32 Mon Sep 17 00:00:00 2001
+From: Nicholas Bellinger <nab@linux-iscsi.org>
+Date: Tue, 22 Sep 2015 22:32:14 -0700
+Subject: iscsi-target: Avoid OFMarker + IFMarker negotiation
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+From: Nicholas Bellinger <nab@linux-iscsi.org>
+
+commit 673681cafa99776e334c3e61cafa2cf115950c32 upstream.
+
+This patch fixes a v4.2+ regression introduced by commit c04a6091
+that removed support for obsolete sync-and-steering markers usage
+as originally defined in RFC-3720.
+
+The regression would involve attempting to send OFMarker=No +
+IFMarker=No keys during opertional negotiation login phase,
+including when initiators did not actually propose these keys.
+
+The result for MSFT iSCSI initiators would be random junk in
+TCP stream after the last successful login request was been sent
+signaling the move to full feature phase (FFP) operation.
+
+To address this bug, go ahead and avoid negotiating these keys
+by default unless the initiator explicitly proposes them, but
+still respond to them with 'No' if they are proposed.
+
+Reported-by: Dragan Milivojević <galileo@pkm-inc.com>
+Bisected-by: Christophe Vu-Brugier <cvubrugier@fastmail.fm>
+Tested-by: Christophe Vu-Brugier <cvubrugier@fastmail.fm>
+Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
+Cc: Andy Grover <agrover@redhat.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/target/iscsi/iscsi_target_parameters.c | 5 +++--
+ 1 file changed, 3 insertions(+), 2 deletions(-)
+
+--- a/drivers/target/iscsi/iscsi_target_parameters.c
++++ b/drivers/target/iscsi/iscsi_target_parameters.c
+@@ -407,6 +407,7 @@ int iscsi_create_default_params(struct i
+ TYPERANGE_UTF8, USE_INITIAL_ONLY);
+ if (!param)
+ goto out;
++
+ /*
+ * Extra parameters for ISER from RFC-5046
+ */
+@@ -496,9 +497,9 @@ int iscsi_set_keys_to_negotiate(
+ } else if (!strcmp(param->name, SESSIONTYPE)) {
+ SET_PSTATE_NEGOTIATE(param);
+ } else if (!strcmp(param->name, IFMARKER)) {
+- SET_PSTATE_NEGOTIATE(param);
++ SET_PSTATE_REJECT(param);
+ } else if (!strcmp(param->name, OFMARKER)) {
+- SET_PSTATE_NEGOTIATE(param);
++ SET_PSTATE_REJECT(param);
+ } else if (!strcmp(param->name, IFMARKINT)) {
+ SET_PSTATE_REJECT(param);
+ } else if (!strcmp(param->name, OFMARKINT)) {
--- /dev/null
+From 21343ac21ec7d871e94e98e288f3398a4207d9c0 Mon Sep 17 00:00:00 2001
+From: Sudip Mukherjee <sudipm.mukherjee@gmail.com>
+Date: Thu, 24 Sep 2015 15:46:53 +0530
+Subject: net: via/Kconfig: GENERIC_PCI_IOMAP required if PCI not selected
+
+From: Sudip Mukherjee <sudipm.mukherjee@gmail.com>
+
+commit 21343ac21ec7d871e94e98e288f3398a4207d9c0 upstream.
+
+The builds of allmodconfig of avr32 is failing with:
+
+drivers/net/ethernet/via/via-rhine.c:1098:2: error: implicit declaration
+of function 'pci_iomap' [-Werror=implicit-function-declaration]
+drivers/net/ethernet/via/via-rhine.c:1119:2: error: implicit declaration
+of function 'pci_iounmap' [-Werror=implicit-function-declaration]
+
+The generic empty pci_iomap and pci_iounmap is used only if CONFIG_PCI
+is not defined and CONFIG_GENERIC_PCI_IOMAP is defined.
+
+Add GENERIC_PCI_IOMAP in the dependency list for VIA_RHINE as we are
+getting build failure when CONFIG_PCI and CONFIG_GENERIC_PCI_IOMAP both
+are not defined.
+
+Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/net/ethernet/via/Kconfig | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/drivers/net/ethernet/via/Kconfig
++++ b/drivers/net/ethernet/via/Kconfig
+@@ -17,7 +17,7 @@ if NET_VENDOR_VIA
+
+ config VIA_RHINE
+ tristate "VIA Rhine support"
+- depends on (PCI || OF_IRQ)
++ depends on PCI || (OF_IRQ && GENERIC_PCI_IOMAP)
+ depends on HAS_DMA
+ select CRC32
+ select MII
tools-lib-traceevent-fix-string-handling-in-heterogeneous-arch-environments.patch
powerpc-msi-fix-race-condition-in-tearing-down-msi-interrupts.patch
rsi-fix-possible-leak-when-loading-firmware.patch
+ubifs-kill-unneeded-locking-in-ubifs_init_security.patch
+ubi-validate-data_size.patch
+ubi-return-enospc-if-no-enough-space-available.patch
+net-via-kconfig-generic_pci_iomap-required-if-pci-not-selected.patch
+iscsi-target-avoid-ofmarker-ifmarker-negotiation.patch
--- /dev/null
+From 7c7feb2ebfc9c0552c51f0c050db1d1a004faac5 Mon Sep 17 00:00:00 2001
+From: shengyong <shengyong1@huawei.com>
+Date: Mon, 28 Sep 2015 17:57:19 +0000
+Subject: UBI: return ENOSPC if no enough space available
+
+From: shengyong <shengyong1@huawei.com>
+
+commit 7c7feb2ebfc9c0552c51f0c050db1d1a004faac5 upstream.
+
+UBI: attaching mtd1 to ubi0
+UBI: scanning is finished
+UBI error: init_volumes: not enough PEBs, required 706, available 686
+UBI error: ubi_wl_init: no enough physical eraseblocks (-20, need 1)
+UBI error: ubi_attach_mtd_dev: failed to attach mtd1, error -12 <= NOT ENOMEM
+UBI error: ubi_init: cannot attach mtd1
+
+If available PEBs are not enough when initializing volumes, return -ENOSPC
+directly. If available PEBs are not enough when initializing WL, return
+-ENOSPC instead of -ENOMEM.
+
+Signed-off-by: Sheng Yong <shengyong1@huawei.com>
+Signed-off-by: Richard Weinberger <richard@nod.at>
+Reviewed-by: David Gstir <david@sigma-star.at>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/mtd/ubi/vtbl.c | 1 +
+ drivers/mtd/ubi/wl.c | 1 +
+ 2 files changed, 2 insertions(+)
+
+--- a/drivers/mtd/ubi/vtbl.c
++++ b/drivers/mtd/ubi/vtbl.c
+@@ -649,6 +649,7 @@ static int init_volumes(struct ubi_devic
+ if (ubi->corr_peb_count)
+ ubi_err(ubi, "%d PEBs are corrupted and not used",
+ ubi->corr_peb_count);
++ return -ENOSPC;
+ }
+ ubi->rsvd_pebs += reserved_pebs;
+ ubi->avail_pebs -= reserved_pebs;
+--- a/drivers/mtd/ubi/wl.c
++++ b/drivers/mtd/ubi/wl.c
+@@ -1601,6 +1601,7 @@ int ubi_wl_init(struct ubi_device *ubi,
+ if (ubi->corr_peb_count)
+ ubi_err(ubi, "%d PEBs are corrupted and not used",
+ ubi->corr_peb_count);
++ err = -ENOSPC;
+ goto out_free;
+ }
+ ubi->avail_pebs -= reserved_pebs;
--- /dev/null
+From 281fda27673f833a01d516658a64d22a32c8e072 Mon Sep 17 00:00:00 2001
+From: Richard Weinberger <richard@nod.at>
+Date: Tue, 22 Sep 2015 23:58:07 +0200
+Subject: UBI: Validate data_size
+
+From: Richard Weinberger <richard@nod.at>
+
+commit 281fda27673f833a01d516658a64d22a32c8e072 upstream.
+
+Make sure that data_size is less than LEB size.
+Otherwise a handcrafted UBI image is able to trigger
+an out of bounds memory access in ubi_compare_lebs().
+
+Signed-off-by: Richard Weinberger <richard@nod.at>
+Reviewed-by: David Gstir <david@sigma-star.at>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/mtd/ubi/io.c | 5 +++++
+ 1 file changed, 5 insertions(+)
+
+--- a/drivers/mtd/ubi/io.c
++++ b/drivers/mtd/ubi/io.c
+@@ -926,6 +926,11 @@ static int validate_vid_hdr(const struct
+ goto bad;
+ }
+
++ if (data_size > ubi->leb_size) {
++ ubi_err(ubi, "bad data_size");
++ goto bad;
++ }
++
+ if (vol_type == UBI_VID_STATIC) {
+ /*
+ * Although from high-level point of view static volumes may
--- /dev/null
+From cf6f54e3f133229f02a90c04fe0ff9dd9d3264b4 Mon Sep 17 00:00:00 2001
+From: Richard Weinberger <richard@nod.at>
+Date: Wed, 8 Jul 2015 11:46:36 +0200
+Subject: UBIFS: Kill unneeded locking in ubifs_init_security
+
+From: Richard Weinberger <richard@nod.at>
+
+commit cf6f54e3f133229f02a90c04fe0ff9dd9d3264b4 upstream.
+
+Fixes the following lockdep splat:
+[ 1.244527] =============================================
+[ 1.245193] [ INFO: possible recursive locking detected ]
+[ 1.245193] 4.2.0-rc1+ #37 Not tainted
+[ 1.245193] ---------------------------------------------
+[ 1.245193] cp/742 is trying to acquire lock:
+[ 1.245193] (&sb->s_type->i_mutex_key#9){+.+.+.}, at: [<ffffffff812b3f69>] ubifs_init_security+0x29/0xb0
+[ 1.245193]
+[ 1.245193] but task is already holding lock:
+[ 1.245193] (&sb->s_type->i_mutex_key#9){+.+.+.}, at: [<ffffffff81198e7f>] path_openat+0x3af/0x1280
+[ 1.245193]
+[ 1.245193] other info that might help us debug this:
+[ 1.245193] Possible unsafe locking scenario:
+[ 1.245193]
+[ 1.245193] CPU0
+[ 1.245193] ----
+[ 1.245193] lock(&sb->s_type->i_mutex_key#9);
+[ 1.245193] lock(&sb->s_type->i_mutex_key#9);
+[ 1.245193]
+[ 1.245193] *** DEADLOCK ***
+[ 1.245193]
+[ 1.245193] May be due to missing lock nesting notation
+[ 1.245193]
+[ 1.245193] 2 locks held by cp/742:
+[ 1.245193] #0: (sb_writers#5){.+.+.+}, at: [<ffffffff811ad37f>] mnt_want_write+0x1f/0x50
+[ 1.245193] #1: (&sb->s_type->i_mutex_key#9){+.+.+.}, at: [<ffffffff81198e7f>] path_openat+0x3af/0x1280
+[ 1.245193]
+[ 1.245193] stack backtrace:
+[ 1.245193] CPU: 2 PID: 742 Comm: cp Not tainted 4.2.0-rc1+ #37
+[ 1.245193] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS rel-1.7.5-0-ge51488c-20140816_022509-build35 04/01/2014
+[ 1.245193] ffffffff8252d530 ffff88007b023a38 ffffffff814f6f49 ffffffff810b56c5
+[ 1.245193] ffff88007c30cc80 ffff88007b023af8 ffffffff810a150d ffff88007b023a68
+[ 1.245193] 000000008101302a ffff880000000000 00000008f447e23f ffffffff8252d500
+[ 1.245193] Call Trace:
+[ 1.245193] [<ffffffff814f6f49>] dump_stack+0x4c/0x65
+[ 1.245193] [<ffffffff810b56c5>] ? console_unlock+0x1c5/0x510
+[ 1.245193] [<ffffffff810a150d>] __lock_acquire+0x1a6d/0x1ea0
+[ 1.245193] [<ffffffff8109fa78>] ? __lock_is_held+0x58/0x80
+[ 1.245193] [<ffffffff810a1a93>] lock_acquire+0xd3/0x270
+[ 1.245193] [<ffffffff812b3f69>] ? ubifs_init_security+0x29/0xb0
+[ 1.245193] [<ffffffff814fc83b>] mutex_lock_nested+0x6b/0x3a0
+[ 1.245193] [<ffffffff812b3f69>] ? ubifs_init_security+0x29/0xb0
+[ 1.245193] [<ffffffff812b3f69>] ? ubifs_init_security+0x29/0xb0
+[ 1.245193] [<ffffffff812b3f69>] ubifs_init_security+0x29/0xb0
+[ 1.245193] [<ffffffff8128e286>] ubifs_create+0xa6/0x1f0
+[ 1.245193] [<ffffffff81198e7f>] ? path_openat+0x3af/0x1280
+[ 1.245193] [<ffffffff81195d15>] vfs_create+0x95/0xc0
+[ 1.245193] [<ffffffff8119929c>] path_openat+0x7cc/0x1280
+[ 1.245193] [<ffffffff8109ffe3>] ? __lock_acquire+0x543/0x1ea0
+[ 1.245193] [<ffffffff81088f20>] ? sched_clock_cpu+0x90/0xc0
+[ 1.245193] [<ffffffff81088c00>] ? calc_global_load_tick+0x60/0x90
+[ 1.245193] [<ffffffff81088f20>] ? sched_clock_cpu+0x90/0xc0
+[ 1.245193] [<ffffffff811a9cef>] ? __alloc_fd+0xaf/0x180
+[ 1.245193] [<ffffffff8119ac55>] do_filp_open+0x75/0xd0
+[ 1.245193] [<ffffffff814ffd86>] ? _raw_spin_unlock+0x26/0x40
+[ 1.245193] [<ffffffff811a9cef>] ? __alloc_fd+0xaf/0x180
+[ 1.245193] [<ffffffff81189bd9>] do_sys_open+0x129/0x200
+[ 1.245193] [<ffffffff81189cc9>] SyS_open+0x19/0x20
+[ 1.245193] [<ffffffff81500717>] entry_SYSCALL_64_fastpath+0x12/0x6f
+
+While the lockdep splat is a false positive, becuase path_openat holds i_mutex
+of the parent directory and ubifs_init_security() tries to acquire i_mutex
+of a new inode, it reveals that taking i_mutex in ubifs_init_security() is
+in vain because it is only being called in the inode allocation path
+and therefore nobody else can see the inode yet.
+
+Reported-and-tested-by: Boris Brezillon <boris.brezillon@free-electrons.com>
+Reviewed-and-tested-by: Dongsheng Yang <yangds.fnst@cn.fujitsu.com>
+Signed-off-by: Richard Weinberger <richard@nod.at>
+Signed-off-by: dedekind1@gmail.com
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ fs/ubifs/xattr.c | 3 ---
+ 1 file changed, 3 deletions(-)
+
+--- a/fs/ubifs/xattr.c
++++ b/fs/ubifs/xattr.c
+@@ -652,11 +652,8 @@ int ubifs_init_security(struct inode *de
+ {
+ int err;
+
+- mutex_lock(&inode->i_mutex);
+ err = security_inode_init_security(inode, dentry, qstr,
+ &init_xattrs, 0);
+- mutex_unlock(&inode->i_mutex);
+-
+ if (err) {
+ struct ubifs_info *c = dentry->i_sb->s_fs_info;
+ ubifs_err(c, "cannot initialize security for inode %lu, error %d",