diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/arch/arm/boot/dts/emev2-kzm9d.dts linux-libre-4.3-gnu/arch/arm/boot/dts/emev2-kzm9d.dts
--- linux-libre-4.3-rc7-gnu/arch/arm/boot/dts/emev2-kzm9d.dts	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/arch/arm/boot/dts/emev2-kzm9d.dts	2015-11-01 19:05:25.000000000 -0500
@@ -35,28 +35,28 @@
 
 		button@1 {
 			debounce_interval = <50>;
-			wakeup = <1>;
+			wakeup-source;
 			label = "DSW2-1";
 			linux,code = <KEY_1>;
 			gpios = <&gpio0 14 GPIO_ACTIVE_HIGH>;
 		};
 		button@2 {
 			debounce_interval = <50>;
-			wakeup = <1>;
+			wakeup-source;
 			label = "DSW2-2";
 			linux,code = <KEY_2>;
 			gpios = <&gpio0 15 GPIO_ACTIVE_HIGH>;
 		};
 		button@3 {
 			debounce_interval = <50>;
-			wakeup = <1>;
+			wakeup-source;
 			label = "DSW2-3";
 			linux,code = <KEY_3>;
 			gpios = <&gpio0 16 GPIO_ACTIVE_HIGH>;
 		};
 		button@4 {
 			debounce_interval = <50>;
-			wakeup = <1>;
+			wakeup-source;
 			label = "DSW2-4";
 			linux,code = <KEY_4>;
 			gpios = <&gpio0 17 GPIO_ACTIVE_HIGH>;
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/arch/arm/boot/dts/ste-snowball.dts linux-libre-4.3-gnu/arch/arm/boot/dts/ste-snowball.dts
--- linux-libre-4.3-rc7-gnu/arch/arm/boot/dts/ste-snowball.dts	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/arch/arm/boot/dts/ste-snowball.dts	2015-11-01 19:05:25.000000000 -0500
@@ -47,35 +47,35 @@
 
 		button@1 {
 			debounce_interval = <50>;
-			wakeup = <1>;
+			wakeup-source;
 			linux,code = <2>;
 			label = "userpb";
 			gpios = <&gpio1 0 0x4>;
 		};
 		button@2 {
 			debounce_interval = <50>;
-			wakeup = <1>;
+			wakeup-source;
 			linux,code = <3>;
 			label = "extkb1";
 			gpios = <&gpio4 23 0x4>;
 		};
 		button@3 {
 			debounce_interval = <50>;
-			wakeup = <1>;
+			wakeup-source;
 			linux,code = <4>;
 			label = "extkb2";
 			gpios = <&gpio4 24 0x4>;
 		};
 		button@4 {
 			debounce_interval = <50>;
-			wakeup = <1>;
+			wakeup-source;
 			linux,code = <5>;
 			label = "extkb3";
 			gpios = <&gpio5 1 0x4>;
 		};
 		button@5 {
 			debounce_interval = <50>;
-			wakeup = <1>;
+			wakeup-source;
 			linux,code = <6>;
 			label = "extkb4";
 			gpios = <&gpio5 2 0x4>;
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/arch/arm/Kconfig linux-libre-4.3-gnu/arch/arm/Kconfig
--- linux-libre-4.3-rc7-gnu/arch/arm/Kconfig	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/arch/arm/Kconfig	2015-11-01 19:05:25.000000000 -0500
@@ -645,6 +645,7 @@ config ARCH_SHMOBILE_LEGACY
 
 config ARCH_RPC
 	bool "RiscPC"
+	depends on MMU
 	select ARCH_ACORN
 	select ARCH_MAY_HAVE_PC_FDC
 	select ARCH_SPARSEMEM_ENABLE
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/arch/arm/vdso/vdsomunge.c linux-libre-4.3-gnu/arch/arm/vdso/vdsomunge.c
--- linux-libre-4.3-rc7-gnu/arch/arm/vdso/vdsomunge.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/arch/arm/vdso/vdsomunge.c	2015-11-01 19:05:25.000000000 -0500
@@ -45,7 +45,6 @@
  * it does.
  */
 
-#include <byteswap.h>
 #include <elf.h>
 #include <errno.h>
 #include <fcntl.h>
@@ -59,6 +58,16 @@
 #include <sys/types.h>
 #include <unistd.h>
 
+#define swab16(x) \
+	((((x) & 0x00ff) << 8) | \
+	 (((x) & 0xff00) >> 8))
+
+#define swab32(x) \
+	((((x) & 0x000000ff) << 24) | \
+	 (((x) & 0x0000ff00) <<  8) | \
+	 (((x) & 0x00ff0000) >>  8) | \
+	 (((x) & 0xff000000) << 24))
+
 #if __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
 #define HOST_ORDER ELFDATA2LSB
 #elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
@@ -104,17 +113,17 @@ static void cleanup(void)
 
 static Elf32_Word read_elf_word(Elf32_Word word, bool swap)
 {
-	return swap ? bswap_32(word) : word;
+	return swap ? swab32(word) : word;
 }
 
 static Elf32_Half read_elf_half(Elf32_Half half, bool swap)
 {
-	return swap ? bswap_16(half) : half;
+	return swap ? swab16(half) : half;
 }
 
 static void write_elf_word(Elf32_Word val, Elf32_Word *dst, bool swap)
 {
-	*dst = swap ? bswap_32(val) : val;
+	*dst = swap ? swab32(val) : val;
 }
 
 int main(int argc, char **argv)
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/arch/arm64/boot/dts/arm/juno-motherboard.dtsi linux-libre-4.3-gnu/arch/arm64/boot/dts/arm/juno-motherboard.dtsi
--- linux-libre-4.3-rc7-gnu/arch/arm64/boot/dts/arm/juno-motherboard.dtsi	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/arch/arm64/boot/dts/arm/juno-motherboard.dtsi	2015-11-01 19:05:25.000000000 -0500
@@ -61,42 +61,42 @@
 
 				button@1 {
 					debounce_interval = <50>;
-					wakeup = <1>;
+					wakeup-source;
 					linux,code = <116>;
 					label = "POWER";
 					gpios = <&iofpga_gpio0 0 0x4>;
 				};
 				button@2 {
 					debounce_interval = <50>;
-					wakeup = <1>;
+					wakeup-source;
 					linux,code = <102>;
 					label = "HOME";
 					gpios = <&iofpga_gpio0 1 0x4>;
 				};
 				button@3 {
 					debounce_interval = <50>;
-					wakeup = <1>;
+					wakeup-source;
 					linux,code = <152>;
 					label = "RLOCK";
 					gpios = <&iofpga_gpio0 2 0x4>;
 				};
 				button@4 {
 					debounce_interval = <50>;
-					wakeup = <1>;
+					wakeup-source;
 					linux,code = <115>;
 					label = "VOL+";
 					gpios = <&iofpga_gpio0 3 0x4>;
 				};
 				button@5 {
 					debounce_interval = <50>;
-					wakeup = <1>;
+					wakeup-source;
 					linux,code = <114>;
 					label = "VOL-";
 					gpios = <&iofpga_gpio0 4 0x4>;
 				};
 				button@6 {
 					debounce_interval = <50>;
-					wakeup = <1>;
+					wakeup-source;
 					linux,code = <99>;
 					label = "NMI";
 					gpios = <&iofpga_gpio0 5 0x4>;
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/arch/arm64/kernel/armv8_deprecated.c linux-libre-4.3-gnu/arch/arm64/kernel/armv8_deprecated.c
--- linux-libre-4.3-rc7-gnu/arch/arm64/kernel/armv8_deprecated.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/arch/arm64/kernel/armv8_deprecated.c	2015-11-01 19:05:25.000000000 -0500
@@ -284,21 +284,23 @@ static void register_insn_emulation_sysc
 	__asm__ __volatile__(					\
 	ALTERNATIVE("nop", SET_PSTATE_PAN(0), ARM64_HAS_PAN,	\
 		    CONFIG_ARM64_PAN)				\
-	"	mov		%w2, %w1\n"			\
-	"0:	ldxr"B"		%w1, [%3]\n"			\
-	"1:	stxr"B"		%w0, %w2, [%3]\n"		\
+	"0:	ldxr"B"		%w2, [%3]\n"			\
+	"1:	stxr"B"		%w0, %w1, [%3]\n"		\
 	"	cbz		%w0, 2f\n"			\
 	"	mov		%w0, %w4\n"			\
+	"	b		3f\n"				\
 	"2:\n"							\
+	"	mov		%w1, %w2\n"			\
+	"3:\n"							\
 	"	.pushsection	 .fixup,\"ax\"\n"		\
 	"	.align		2\n"				\
-	"3:	mov		%w0, %w5\n"			\
-	"	b		2b\n"				\
+	"4:	mov		%w0, %w5\n"			\
+	"	b		3b\n"				\
 	"	.popsection"					\
 	"	.pushsection	 __ex_table,\"a\"\n"		\
 	"	.align		3\n"				\
-	"	.quad		0b, 3b\n"			\
-	"	.quad		1b, 3b\n"			\
+	"	.quad		0b, 4b\n"			\
+	"	.quad		1b, 4b\n"			\
 	"	.popsection\n"					\
 	ALTERNATIVE("nop", SET_PSTATE_PAN(1), ARM64_HAS_PAN,	\
 		CONFIG_ARM64_PAN)				\
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/arch/arm64/kernel/efi-stub.c linux-libre-4.3-gnu/arch/arm64/kernel/efi-stub.c
--- linux-libre-4.3-rc7-gnu/arch/arm64/kernel/efi-stub.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/arch/arm64/kernel/efi-stub.c	2015-11-01 19:05:25.000000000 -0500
@@ -25,10 +25,20 @@ efi_status_t __init handle_kernel_image(
 	unsigned long kernel_size, kernel_memsize = 0;
 	unsigned long nr_pages;
 	void *old_image_addr = (void *)*image_addr;
+	unsigned long preferred_offset;
+
+	/*
+	 * The preferred offset of the kernel Image is TEXT_OFFSET bytes beyond
+	 * a 2 MB aligned base, which itself may be lower than dram_base, as
+	 * long as the resulting offset equals or exceeds it.
+	 */
+	preferred_offset = round_down(dram_base, SZ_2M) + TEXT_OFFSET;
+	if (preferred_offset < dram_base)
+		preferred_offset += SZ_2M;
 
 	/* Relocate the image, if required. */
 	kernel_size = _edata - _text;
-	if (*image_addr != (dram_base + TEXT_OFFSET)) {
+	if (*image_addr != preferred_offset) {
 		kernel_memsize = kernel_size + (_end - _edata);
 
 		/*
@@ -42,7 +52,7 @@ efi_status_t __init handle_kernel_image(
 		 * Mustang), we can still place the kernel at the address
 		 * 'dram_base + TEXT_OFFSET'.
 		 */
-		*image_addr = *reserve_addr = dram_base + TEXT_OFFSET;
+		*image_addr = *reserve_addr = preferred_offset;
 		nr_pages = round_up(kernel_memsize, EFI_ALLOC_ALIGN) /
 			   EFI_PAGE_SIZE;
 		status = efi_call_early(allocate_pages, EFI_ALLOCATE_ADDRESS,
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/arch/arm64/kernel/stacktrace.c linux-libre-4.3-gnu/arch/arm64/kernel/stacktrace.c
--- linux-libre-4.3-rc7-gnu/arch/arm64/kernel/stacktrace.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/arch/arm64/kernel/stacktrace.c	2015-11-01 19:05:25.000000000 -0500
@@ -48,11 +48,7 @@ int notrace unwind_frame(struct stackfra
 
 	frame->sp = fp + 0x10;
 	frame->fp = *(unsigned long *)(fp);
-	/*
-	 * -4 here because we care about the PC at time of bl,
-	 * not where the return will go.
-	 */
-	frame->pc = *(unsigned long *)(fp + 8) - 4;
+	frame->pc = *(unsigned long *)(fp + 8);
 
 	return 0;
 }
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/arch/arm64/kernel/suspend.c linux-libre-4.3-gnu/arch/arm64/kernel/suspend.c
--- linux-libre-4.3-rc7-gnu/arch/arm64/kernel/suspend.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/arch/arm64/kernel/suspend.c	2015-11-01 19:05:25.000000000 -0500
@@ -80,17 +80,21 @@ int cpu_suspend(unsigned long arg, int (
 	if (ret == 0) {
 		/*
 		 * We are resuming from reset with TTBR0_EL1 set to the
-		 * idmap to enable the MMU; restore the active_mm mappings in
-		 * TTBR0_EL1 unless the active_mm == &init_mm, in which case
-		 * the thread entered cpu_suspend with TTBR0_EL1 set to
-		 * reserved TTBR0 page tables and should be restored as such.
+		 * idmap to enable the MMU; set the TTBR0 to the reserved
+		 * page tables to prevent speculative TLB allocations, flush
+		 * the local tlb and set the default tcr_el1.t0sz so that
+		 * the TTBR0 address space set-up is properly restored.
+		 * If the current active_mm != &init_mm we entered cpu_suspend
+		 * with mappings in TTBR0 that must be restored, so we switch
+		 * them back to complete the address space configuration
+		 * restoration before returning.
 		 */
-		if (mm == &init_mm)
-			cpu_set_reserved_ttbr0();
-		else
-			cpu_switch_mm(mm->pgd, mm);
-
+		cpu_set_reserved_ttbr0();
 		flush_tlb_all();
+		cpu_set_default_tcr_t0sz();
+
+		if (mm != &init_mm)
+			cpu_switch_mm(mm->pgd, mm);
 
 		/*
 		 * Restore per-cpu offset before any kernel
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/arch/ia64/include/asm/unistd.h linux-libre-4.3-gnu/arch/ia64/include/asm/unistd.h
--- linux-libre-4.3-rc7-gnu/arch/ia64/include/asm/unistd.h	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/arch/ia64/include/asm/unistd.h	2015-11-01 19:05:25.000000000 -0500
@@ -11,7 +11,7 @@
 
 
 
-#define NR_syscalls			321 /* length of syscall table */
+#define NR_syscalls			322 /* length of syscall table */
 
 /*
  * The following defines stop scripts/checksyscalls.sh from complaining about
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/arch/ia64/include/uapi/asm/unistd.h linux-libre-4.3-gnu/arch/ia64/include/uapi/asm/unistd.h
--- linux-libre-4.3-rc7-gnu/arch/ia64/include/uapi/asm/unistd.h	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/arch/ia64/include/uapi/asm/unistd.h	2015-11-01 19:05:25.000000000 -0500
@@ -334,5 +334,6 @@
 #define __NR_execveat			1342
 #define __NR_userfaultfd		1343
 #define __NR_membarrier			1344
+#define __NR_kcmp			1345
 
 #endif /* _UAPI_ASM_IA64_UNISTD_H */
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/arch/ia64/kernel/entry.S linux-libre-4.3-gnu/arch/ia64/kernel/entry.S
--- linux-libre-4.3-rc7-gnu/arch/ia64/kernel/entry.S	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/arch/ia64/kernel/entry.S	2015-11-01 19:05:25.000000000 -0500
@@ -1770,5 +1770,6 @@ sys_call_table:
 	data8 sys_execveat
 	data8 sys_userfaultfd
 	data8 sys_membarrier
+	data8 sys_kcmp				// 1345
 
 	.org sys_call_table + 8*NR_syscalls	// guard against failures to increase NR_syscalls
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/arch/powerpc/kernel/dma.c linux-libre-4.3-gnu/arch/powerpc/kernel/dma.c
--- linux-libre-4.3-rc7-gnu/arch/powerpc/kernel/dma.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/arch/powerpc/kernel/dma.c	2015-11-01 19:05:25.000000000 -0500
@@ -303,7 +303,7 @@ int dma_set_coherent_mask(struct device
 	dev->coherent_dma_mask = mask;
 	return 0;
 }
-EXPORT_SYMBOL_GPL(dma_set_coherent_mask);
+EXPORT_SYMBOL(dma_set_coherent_mask);
 
 #define PREALLOC_DMA_DEBUG_ENTRIES (1 << 16)
 
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/arch/x86/kernel/apic/io_apic.c linux-libre-4.3-gnu/arch/x86/kernel/apic/io_apic.c
--- linux-libre-4.3-rc7-gnu/arch/x86/kernel/apic/io_apic.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/arch/x86/kernel/apic/io_apic.c	2015-11-01 19:05:25.000000000 -0500
@@ -2547,7 +2547,9 @@ void __init setup_ioapic_dest(void)
 			mask = apic->target_cpus();
 
 		chip = irq_data_get_irq_chip(idata);
-		chip->irq_set_affinity(idata, mask, false);
+		/* Might be lapic_chip for irq 0 */
+		if (chip->irq_set_affinity)
+			chip->irq_set_affinity(idata, mask, false);
 	}
 }
 #endif
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/arch/x86/kernel/pci-dma.c linux-libre-4.3-gnu/arch/x86/kernel/pci-dma.c
--- linux-libre-4.3-rc7-gnu/arch/x86/kernel/pci-dma.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/arch/x86/kernel/pci-dma.c	2015-11-01 19:05:25.000000000 -0500
@@ -131,11 +131,12 @@ void dma_generic_free_coherent(struct de
 
 bool arch_dma_alloc_attrs(struct device **dev, gfp_t *gfp)
 {
+	if (!*dev)
+		*dev = &x86_dma_fallback_dev;
+
 	*gfp &= ~(__GFP_DMA | __GFP_HIGHMEM | __GFP_DMA32);
 	*gfp = dma_alloc_coherent_gfp_flags(*dev, *gfp);
 
-	if (!*dev)
-		*dev = &x86_dma_fallback_dev;
 	if (!is_device_dma_capable(*dev))
 		return false;
 	return true;
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/arch/x86/kernel/process.c linux-libre-4.3-gnu/arch/x86/kernel/process.c
--- linux-libre-4.3-rc7-gnu/arch/x86/kernel/process.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/arch/x86/kernel/process.c	2015-11-01 19:05:25.000000000 -0500
@@ -84,6 +84,9 @@ EXPORT_SYMBOL_GPL(idle_notifier_unregist
 int arch_dup_task_struct(struct task_struct *dst, struct task_struct *src)
 {
 	memcpy(dst, src, arch_task_struct_size);
+#ifdef CONFIG_VM86
+	dst->thread.vm86 = NULL;
+#endif
 
 	return fpu__copy(&dst->thread.fpu, &src->thread.fpu);
 }
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/block/blk-lib.c linux-libre-4.3-gnu/block/blk-lib.c
--- linux-libre-4.3-rc7-gnu/block/blk-lib.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/block/blk-lib.c	2015-11-01 19:05:25.000000000 -0500
@@ -26,13 +26,6 @@ static void bio_batch_end_io(struct bio
 	bio_put(bio);
 }
 
-/*
- * Ensure that max discard sectors doesn't overflow bi_size and hopefully
- * it is of the proper granularity as long as the granularity is a power
- * of two.
- */
-#define MAX_BIO_SECTORS ((1U << 31) >> 9)
-
 /**
  * blkdev_issue_discard - queue a discard
  * @bdev:	blockdev to issue discard for
@@ -50,6 +43,8 @@ int blkdev_issue_discard(struct block_de
 	DECLARE_COMPLETION_ONSTACK(wait);
 	struct request_queue *q = bdev_get_queue(bdev);
 	int type = REQ_WRITE | REQ_DISCARD;
+	unsigned int granularity;
+	int alignment;
 	struct bio_batch bb;
 	struct bio *bio;
 	int ret = 0;
@@ -61,6 +56,10 @@ int blkdev_issue_discard(struct block_de
 	if (!blk_queue_discard(q))
 		return -EOPNOTSUPP;
 
+	/* Zero-sector (unknown) and one-sector granularities are the same.  */
+	granularity = max(q->limits.discard_granularity >> 9, 1U);
+	alignment = (bdev_discard_alignment(bdev) >> 9) % granularity;
+
 	if (flags & BLKDEV_DISCARD_SECURE) {
 		if (!blk_queue_secdiscard(q))
 			return -EOPNOTSUPP;
@@ -74,7 +73,7 @@ int blkdev_issue_discard(struct block_de
 	blk_start_plug(&plug);
 	while (nr_sects) {
 		unsigned int req_sects;
-		sector_t end_sect;
+		sector_t end_sect, tmp;
 
 		bio = bio_alloc(gfp_mask, 1);
 		if (!bio) {
@@ -82,8 +81,22 @@ int blkdev_issue_discard(struct block_de
 			break;
 		}
 
-		req_sects = min_t(sector_t, nr_sects, MAX_BIO_SECTORS);
+		/* Make sure bi_size doesn't overflow */
+		req_sects = min_t(sector_t, nr_sects, UINT_MAX >> 9);
+
+		/*
+		 * If splitting a request, and the next starting sector would be
+		 * misaligned, stop the discard at the previous aligned sector.
+		 */
 		end_sect = sector + req_sects;
+		tmp = end_sect;
+		if (req_sects < nr_sects &&
+		    sector_div(tmp, granularity) != alignment) {
+			end_sect = end_sect - alignment;
+			sector_div(end_sect, granularity);
+			end_sect = end_sect * granularity + alignment;
+			req_sects = end_sect - sector;
+		}
 
 		bio->bi_iter.bi_sector = sector;
 		bio->bi_end_io = bio_batch_end_io;
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/crypto/ablkcipher.c linux-libre-4.3-gnu/crypto/ablkcipher.c
--- linux-libre-4.3-rc7-gnu/crypto/ablkcipher.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/crypto/ablkcipher.c	2015-11-01 19:05:25.000000000 -0500
@@ -706,7 +706,7 @@ struct crypto_ablkcipher *crypto_alloc_a
 err:
 		if (err != -EAGAIN)
 			break;
-		if (signal_pending(current)) {
+		if (fatal_signal_pending(current)) {
 			err = -EINTR;
 			break;
 		}
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/crypto/algapi.c linux-libre-4.3-gnu/crypto/algapi.c
--- linux-libre-4.3-rc7-gnu/crypto/algapi.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/crypto/algapi.c	2015-11-01 19:05:25.000000000 -0500
@@ -345,7 +345,7 @@ static void crypto_wait_for_test(struct
 		crypto_alg_tested(larval->alg.cra_driver_name, 0);
 	}
 
-	err = wait_for_completion_interruptible(&larval->completion);
+	err = wait_for_completion_killable(&larval->completion);
 	WARN_ON(err);
 
 out:
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/crypto/api.c linux-libre-4.3-gnu/crypto/api.c
--- linux-libre-4.3-rc7-gnu/crypto/api.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/crypto/api.c	2015-11-01 19:05:25.000000000 -0500
@@ -172,7 +172,7 @@ static struct crypto_alg *crypto_larval_
 	struct crypto_larval *larval = (void *)alg;
 	long timeout;
 
-	timeout = wait_for_completion_interruptible_timeout(
+	timeout = wait_for_completion_killable_timeout(
 		&larval->completion, 60 * HZ);
 
 	alg = larval->adult;
@@ -445,7 +445,7 @@ struct crypto_tfm *crypto_alloc_base(con
 err:
 		if (err != -EAGAIN)
 			break;
-		if (signal_pending(current)) {
+		if (fatal_signal_pending(current)) {
 			err = -EINTR;
 			break;
 		}
@@ -562,7 +562,7 @@ void *crypto_alloc_tfm(const char *alg_n
 err:
 		if (err != -EAGAIN)
 			break;
-		if (signal_pending(current)) {
+		if (fatal_signal_pending(current)) {
 			err = -EINTR;
 			break;
 		}
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/crypto/crypto_user.c linux-libre-4.3-gnu/crypto/crypto_user.c
--- linux-libre-4.3-rc7-gnu/crypto/crypto_user.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/crypto/crypto_user.c	2015-11-01 19:05:25.000000000 -0500
@@ -375,7 +375,7 @@ static struct crypto_alg *crypto_user_sk
 		err = PTR_ERR(alg);
 		if (err != -EAGAIN)
 			break;
-		if (signal_pending(current)) {
+		if (fatal_signal_pending(current)) {
 			err = -EINTR;
 			break;
 		}
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/Documentation/devicetree/bindings/net/cpsw.txt linux-libre-4.3-gnu/Documentation/devicetree/bindings/net/cpsw.txt
--- linux-libre-4.3-rc7-gnu/Documentation/devicetree/bindings/net/cpsw.txt	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/Documentation/devicetree/bindings/net/cpsw.txt	2015-11-01 19:05:25.000000000 -0500
@@ -39,6 +39,7 @@ Required properties:
 Optional properties:
 - dual_emac_res_vlan	: Specifies VID to be used to segregate the ports
 - mac-address		: See ethernet.txt file in the same directory
+- phy-handle		: See ethernet.txt file in the same directory
 
 Note: "ti,hwmods" field is used to fetch the base address and irq
 resources from TI, omap hwmod data base during device registration.
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/Documentation/devicetree/bindings/net/smsc-lan87xx.txt linux-libre-4.3-gnu/Documentation/devicetree/bindings/net/smsc-lan87xx.txt
--- linux-libre-4.3-rc7-gnu/Documentation/devicetree/bindings/net/smsc-lan87xx.txt	1969-12-31 19:00:00.000000000 -0500
+++ linux-libre-4.3-gnu/Documentation/devicetree/bindings/net/smsc-lan87xx.txt	2015-11-01 19:05:25.000000000 -0500
@@ -0,0 +1,24 @@
+SMSC LAN87xx Ethernet PHY
+
+Some boards require special tuning values. Configure them
+through an Ethernet OF device node.
+
+Optional properties:
+
+- smsc,disable-energy-detect:
+  If set, do not enable energy detect mode for the SMSC phy.
+  default: enable energy detect mode
+
+Examples:
+smsc phy with disabled energy detect mode on an am335x based board.
+&davinci_mdio {
+	pinctrl-names = "default", "sleep";
+	pinctrl-0 = <&davinci_mdio_default>;
+	pinctrl-1 = <&davinci_mdio_sleep>;
+	status = "okay";
+
+	ethernetphy0: ethernet-phy@0 {
+		reg = <0>;
+		smsc,disable-energy-detect;
+	};
+};
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/block/rbd.c linux-libre-4.3-gnu/drivers/block/rbd.c
--- linux-libre-4.3-rc7-gnu/drivers/block/rbd.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/block/rbd.c	2015-11-01 19:05:25.000000000 -0500
@@ -3780,6 +3780,9 @@ static int rbd_init_disk(struct rbd_devi
 	blk_queue_max_discard_sectors(q, segment_size / SECTOR_SIZE);
 	q->limits.discard_zeroes_data = 1;
 
+	if (!ceph_test_opt(rbd_dev->rbd_client->client, NOCRC))
+		q->backing_dev_info.capabilities |= BDI_CAP_STABLE_WRITES;
+
 	disk->queue = q;
 
 	q->queuedata = rbd_dev;
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/clk/clkdev.c linux-libre-4.3-gnu/drivers/clk/clkdev.c
--- linux-libre-4.3-rc7-gnu/drivers/clk/clkdev.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/clk/clkdev.c	2015-11-01 19:05:25.000000000 -0500
@@ -333,7 +333,8 @@ int clk_add_alias(const char *alias, con
 	if (IS_ERR(r))
 		return PTR_ERR(r);
 
-	l = clkdev_create(r, alias, "%s", alias_dev_name);
+	l = clkdev_create(r, alias, alias_dev_name ? "%s" : NULL,
+			  alias_dev_name);
 	clk_put(r);
 
 	return l ? 0 : -ENODEV;
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/clocksource/arm_global_timer.c linux-libre-4.3-gnu/drivers/clocksource/arm_global_timer.c
--- linux-libre-4.3-rc7-gnu/drivers/clocksource/arm_global_timer.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/clocksource/arm_global_timer.c	2015-11-01 19:05:25.000000000 -0500
@@ -60,7 +60,7 @@ static struct clock_event_device __percp
  *  different to the 32-bit upper value read previously, go back to step 2.
  *  Otherwise the 64-bit timer counter value is correct.
  */
-static u64 gt_counter_read(void)
+static u64 notrace _gt_counter_read(void)
 {
 	u64 counter;
 	u32 lower;
@@ -79,6 +79,11 @@ static u64 gt_counter_read(void)
 	return counter;
 }
 
+static u64 gt_counter_read(void)
+{
+	return _gt_counter_read();
+}
+
 /**
  * To ensure that updates to comparator value register do not set the
  * Interrupt Status Register proceed as follows:
@@ -201,7 +206,7 @@ static struct clocksource gt_clocksource
 #ifdef CONFIG_CLKSRC_ARM_GLOBAL_TIMER_SCHED_CLOCK
 static u64 notrace gt_sched_clock_read(void)
 {
-	return gt_counter_read();
+	return _gt_counter_read();
 }
 #endif
 
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/clocksource/fsl_ftm_timer.c linux-libre-4.3-gnu/drivers/clocksource/fsl_ftm_timer.c
--- linux-libre-4.3-rc7-gnu/drivers/clocksource/fsl_ftm_timer.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/clocksource/fsl_ftm_timer.c	2015-11-01 19:05:25.000000000 -0500
@@ -118,7 +118,7 @@ static inline void ftm_reset_counter(voi
 	ftm_writel(0x00, base + FTM_CNT);
 }
 
-static u64 ftm_read_sched_clock(void)
+static u64 notrace ftm_read_sched_clock(void)
 {
 	return ftm_readl(priv->clksrc_base + FTM_CNT);
 }
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/clocksource/samsung_pwm_timer.c linux-libre-4.3-gnu/drivers/clocksource/samsung_pwm_timer.c
--- linux-libre-4.3-rc7-gnu/drivers/clocksource/samsung_pwm_timer.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/clocksource/samsung_pwm_timer.c	2015-11-01 19:05:25.000000000 -0500
@@ -307,7 +307,7 @@ static void samsung_clocksource_resume(s
 	samsung_time_start(pwm.source_id, true);
 }
 
-static cycle_t samsung_clocksource_read(struct clocksource *c)
+static cycle_t notrace samsung_clocksource_read(struct clocksource *c)
 {
 	return ~readl_relaxed(pwm.source_reg);
 }
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/clocksource/sh_mtu2.c linux-libre-4.3-gnu/drivers/clocksource/sh_mtu2.c
--- linux-libre-4.3-rc7-gnu/drivers/clocksource/sh_mtu2.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/clocksource/sh_mtu2.c	2015-11-01 19:05:25.000000000 -0500
@@ -280,7 +280,9 @@ static int sh_mtu2_clock_event_shutdown(
 {
 	struct sh_mtu2_channel *ch = ced_to_sh_mtu2(ced);
 
-	sh_mtu2_disable(ch);
+	if (clockevent_state_periodic(ced))
+		sh_mtu2_disable(ch);
+
 	return 0;
 }
 
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/clocksource/time-pistachio.c linux-libre-4.3-gnu/drivers/clocksource/time-pistachio.c
--- linux-libre-4.3-rc7-gnu/drivers/clocksource/time-pistachio.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/clocksource/time-pistachio.c	2015-11-01 19:05:25.000000000 -0500
@@ -67,7 +67,8 @@ static inline void gpt_writel(void __iom
 	writel(value, base + 0x20 * gpt_id + offset);
 }
 
-static cycle_t pistachio_clocksource_read_cycles(struct clocksource *cs)
+static cycle_t notrace
+pistachio_clocksource_read_cycles(struct clocksource *cs)
 {
 	struct pistachio_clocksource *pcs = to_pistachio_clocksource(cs);
 	u32 counter, overflw;
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/clocksource/timer-digicolor.c linux-libre-4.3-gnu/drivers/clocksource/timer-digicolor.c
--- linux-libre-4.3-rc7-gnu/drivers/clocksource/timer-digicolor.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/clocksource/timer-digicolor.c	2015-11-01 19:05:25.000000000 -0500
@@ -143,7 +143,7 @@ static irqreturn_t digicolor_timer_inter
 	return IRQ_HANDLED;
 }
 
-static u64 digicolor_timer_sched_read(void)
+static u64 notrace digicolor_timer_sched_read(void)
 {
 	return ~readl(dc_timer_dev.base + COUNT(TIMER_B));
 }
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/clocksource/timer-prima2.c linux-libre-4.3-gnu/drivers/clocksource/timer-prima2.c
--- linux-libre-4.3-rc7-gnu/drivers/clocksource/timer-prima2.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/clocksource/timer-prima2.c	2015-11-01 19:05:25.000000000 -0500
@@ -73,7 +73,7 @@ static irqreturn_t sirfsoc_timer_interru
 }
 
 /* read 64-bit timer counter */
-static cycle_t sirfsoc_timer_read(struct clocksource *cs)
+static cycle_t notrace sirfsoc_timer_read(struct clocksource *cs)
 {
 	u64 cycles;
 
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/clocksource/vf_pit_timer.c linux-libre-4.3-gnu/drivers/clocksource/vf_pit_timer.c
--- linux-libre-4.3-rc7-gnu/drivers/clocksource/vf_pit_timer.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/clocksource/vf_pit_timer.c	2015-11-01 19:05:25.000000000 -0500
@@ -52,7 +52,7 @@ static inline void pit_irq_acknowledge(v
 	__raw_writel(PITTFLG_TIF, clkevt_base + PITTFLG);
 }
 
-static u64 pit_read_sched_clock(void)
+static u64 notrace pit_read_sched_clock(void)
 {
 	return ~__raw_readl(clksrc_base + PITCVAL);
 }
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/gpu/drm/amd/amdgpu/amdgpu_display.c linux-libre-4.3-gnu/drivers/gpu/drm/amd/amdgpu/amdgpu_display.c
--- linux-libre-4.3-rc7-gnu/drivers/gpu/drm/amd/amdgpu/amdgpu_display.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/gpu/drm/amd/amdgpu/amdgpu_display.c	2015-11-01 19:05:25.000000000 -0500
@@ -184,10 +184,6 @@ int amdgpu_crtc_page_flip(struct drm_crt
 		goto cleanup;
 	}
 
-	fence_get(work->excl);
-	for (i = 0; i < work->shared_count; ++i)
-		fence_get(work->shared[i]);
-
 	amdgpu_bo_get_tiling_flags(new_rbo, &tiling_flags);
 	amdgpu_bo_unreserve(new_rbo);
 
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/gpu/drm/amd/amdgpu/amdgpu.h linux-libre-4.3-gnu/drivers/gpu/drm/amd/amdgpu/amdgpu.h
--- linux-libre-4.3-rc7-gnu/drivers/gpu/drm/amd/amdgpu/amdgpu.h	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/gpu/drm/amd/amdgpu/amdgpu.h	2015-11-01 19:05:25.000000000 -0500
@@ -1654,6 +1654,7 @@ struct amdgpu_pm {
 	u8                      fan_max_rpm;
 	/* dpm */
 	bool                    dpm_enabled;
+	bool                    sysfs_initialized;
 	struct amdgpu_dpm       dpm;
 	const struct firmware	*fw;	/* SMC firmware */
 	uint32_t                fw_version;
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c linux-libre-4.3-gnu/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c
--- linux-libre-4.3-rc7-gnu/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c	2015-11-01 19:05:25.000000000 -0500
@@ -695,6 +695,9 @@ int amdgpu_pm_sysfs_init(struct amdgpu_d
 {
 	int ret;
 
+	if (adev->pm.sysfs_initialized)
+		return 0;
+
 	if (adev->pm.funcs->get_temperature == NULL)
 		return 0;
 	adev->pm.int_hwmon_dev = hwmon_device_register_with_groups(adev->dev,
@@ -723,6 +726,8 @@ int amdgpu_pm_sysfs_init(struct amdgpu_d
 		return ret;
 	}
 
+	adev->pm.sysfs_initialized = true;
+
 	return 0;
 }
 
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/gpu/drm/drm_crtc.c linux-libre-4.3-gnu/drivers/gpu/drm/drm_crtc.c
--- linux-libre-4.3-rc7-gnu/drivers/gpu/drm/drm_crtc.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/gpu/drm/drm_crtc.c	2015-11-01 19:05:25.000000000 -0500
@@ -4105,7 +4105,7 @@ drm_property_create_blob(struct drm_devi
 	struct drm_property_blob *blob;
 	int ret;
 
-	if (!length)
+	if (!length || length > ULONG_MAX - sizeof(struct drm_property_blob))
 		return ERR_PTR(-EINVAL);
 
 	blob = kzalloc(sizeof(struct drm_property_blob)+length, GFP_KERNEL);
@@ -4454,7 +4454,7 @@ int drm_mode_createblob_ioctl(struct drm
 	 * not associated with any file_priv. */
 	mutex_lock(&dev->mode_config.blob_lock);
 	out_resp->blob_id = blob->base.id;
-	list_add_tail(&file_priv->blobs, &blob->head_file);
+	list_add_tail(&blob->head_file, &file_priv->blobs);
 	mutex_unlock(&dev->mode_config.blob_lock);
 
 	return 0;
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/gpu/drm/radeon/atombios_encoders.c linux-libre-4.3-gnu/drivers/gpu/drm/radeon/atombios_encoders.c
--- linux-libre-4.3-rc7-gnu/drivers/gpu/drm/radeon/atombios_encoders.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/gpu/drm/radeon/atombios_encoders.c	2015-11-01 19:05:25.000000000 -0500
@@ -237,6 +237,7 @@ void radeon_atom_backlight_init(struct r
 	backlight_update_status(bd);
 
 	DRM_INFO("radeon atom DIG backlight initialized\n");
+	rdev->mode_info.bl_encoder = radeon_encoder;
 
 	return;
 
@@ -1624,9 +1625,14 @@ radeon_atom_encoder_dpms_avivo(struct dr
 		} else
 			atom_execute_table(rdev->mode_info.atom_context, index, (uint32_t *)&args);
 		if (radeon_encoder->devices & (ATOM_DEVICE_LCD_SUPPORT)) {
-			struct radeon_encoder_atom_dig *dig = radeon_encoder->enc_priv;
+			if (rdev->mode_info.bl_encoder) {
+				struct radeon_encoder_atom_dig *dig = radeon_encoder->enc_priv;
 
-			atombios_set_backlight_level(radeon_encoder, dig->backlight_level);
+				atombios_set_backlight_level(radeon_encoder, dig->backlight_level);
+			} else {
+				args.ucAction = ATOM_LCD_BLON;
+				atom_execute_table(rdev->mode_info.atom_context, index, (uint32_t *)&args);
+			}
 		}
 		break;
 	case DRM_MODE_DPMS_STANDBY:
@@ -1706,8 +1712,13 @@ radeon_atom_encoder_dpms_dig(struct drm_
 			if (ASIC_IS_DCE4(rdev))
 				atombios_dig_encoder_setup(encoder, ATOM_ENCODER_CMD_DP_VIDEO_ON, 0);
 		}
-		if (radeon_encoder->devices & (ATOM_DEVICE_LCD_SUPPORT))
-			atombios_set_backlight_level(radeon_encoder, dig->backlight_level);
+		if (radeon_encoder->devices & (ATOM_DEVICE_LCD_SUPPORT)) {
+			if (rdev->mode_info.bl_encoder)
+				atombios_set_backlight_level(radeon_encoder, dig->backlight_level);
+			else
+				atombios_dig_transmitter_setup(encoder,
+							       ATOM_TRANSMITTER_ACTION_LCD_BLON, 0, 0);
+		}
 		if (ext_encoder)
 			atombios_external_encoder_setup(encoder, ext_encoder, ATOM_ENABLE);
 		break;
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/gpu/drm/radeon/radeon_encoders.c linux-libre-4.3-gnu/drivers/gpu/drm/radeon/radeon_encoders.c
--- linux-libre-4.3-rc7-gnu/drivers/gpu/drm/radeon/radeon_encoders.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/gpu/drm/radeon/radeon_encoders.c	2015-11-01 19:05:25.000000000 -0500
@@ -194,7 +194,6 @@ static void radeon_encoder_add_backlight
 			radeon_atom_backlight_init(radeon_encoder, connector);
 		else
 			radeon_legacy_backlight_init(radeon_encoder, connector);
-		rdev->mode_info.bl_encoder = radeon_encoder;
 	}
 }
 
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/gpu/drm/radeon/radeon.h linux-libre-4.3-gnu/drivers/gpu/drm/radeon/radeon.h
--- linux-libre-4.3-rc7-gnu/drivers/gpu/drm/radeon/radeon.h	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/gpu/drm/radeon/radeon.h	2015-11-01 19:05:25.000000000 -0500
@@ -1658,6 +1658,7 @@ struct radeon_pm {
 	u8                      fan_max_rpm;
 	/* dpm */
 	bool                    dpm_enabled;
+	bool                    sysfs_initialized;
 	struct radeon_dpm       dpm;
 };
 
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/gpu/drm/radeon/radeon_legacy_encoders.c linux-libre-4.3-gnu/drivers/gpu/drm/radeon/radeon_legacy_encoders.c
--- linux-libre-4.3-rc7-gnu/drivers/gpu/drm/radeon/radeon_legacy_encoders.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/gpu/drm/radeon/radeon_legacy_encoders.c	2015-11-01 19:05:25.000000000 -0500
@@ -441,6 +441,7 @@ void radeon_legacy_backlight_init(struct
 	backlight_update_status(bd);
 
 	DRM_INFO("radeon legacy LVDS backlight initialized\n");
+	rdev->mode_info.bl_encoder = radeon_encoder;
 
 	return;
 
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/gpu/drm/radeon/radeon_pm.c linux-libre-4.3-gnu/drivers/gpu/drm/radeon/radeon_pm.c
--- linux-libre-4.3-rc7-gnu/drivers/gpu/drm/radeon/radeon_pm.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/gpu/drm/radeon/radeon_pm.c	2015-11-01 19:05:25.000000000 -0500
@@ -1528,19 +1528,23 @@ int radeon_pm_late_init(struct radeon_de
 
 	if (rdev->pm.pm_method == PM_METHOD_DPM) {
 		if (rdev->pm.dpm_enabled) {
-			ret = device_create_file(rdev->dev, &dev_attr_power_dpm_state);
-			if (ret)
-				DRM_ERROR("failed to create device file for dpm state\n");
-			ret = device_create_file(rdev->dev, &dev_attr_power_dpm_force_performance_level);
-			if (ret)
-				DRM_ERROR("failed to create device file for dpm state\n");
-			/* XXX: these are noops for dpm but are here for backwards compat */
-			ret = device_create_file(rdev->dev, &dev_attr_power_profile);
-			if (ret)
-				DRM_ERROR("failed to create device file for power profile\n");
-			ret = device_create_file(rdev->dev, &dev_attr_power_method);
-			if (ret)
-				DRM_ERROR("failed to create device file for power method\n");
+			if (!rdev->pm.sysfs_initialized) {
+				ret = device_create_file(rdev->dev, &dev_attr_power_dpm_state);
+				if (ret)
+					DRM_ERROR("failed to create device file for dpm state\n");
+				ret = device_create_file(rdev->dev, &dev_attr_power_dpm_force_performance_level);
+				if (ret)
+					DRM_ERROR("failed to create device file for dpm state\n");
+				/* XXX: these are noops for dpm but are here for backwards compat */
+				ret = device_create_file(rdev->dev, &dev_attr_power_profile);
+				if (ret)
+					DRM_ERROR("failed to create device file for power profile\n");
+				ret = device_create_file(rdev->dev, &dev_attr_power_method);
+				if (ret)
+					DRM_ERROR("failed to create device file for power method\n");
+				if (!ret)
+					rdev->pm.sysfs_initialized = true;
+			}
 
 			mutex_lock(&rdev->pm.mutex);
 			ret = radeon_dpm_late_enable(rdev);
@@ -1556,7 +1560,8 @@ int radeon_pm_late_init(struct radeon_de
 			}
 		}
 	} else {
-		if (rdev->pm.num_power_states > 1) {
+		if ((rdev->pm.num_power_states > 1) &&
+		    (!rdev->pm.sysfs_initialized)) {
 			/* where's the best place to put these? */
 			ret = device_create_file(rdev->dev, &dev_attr_power_profile);
 			if (ret)
@@ -1564,6 +1569,8 @@ int radeon_pm_late_init(struct radeon_de
 			ret = device_create_file(rdev->dev, &dev_attr_power_method);
 			if (ret)
 				DRM_ERROR("failed to create device file for power method\n");
+			if (!ret)
+				rdev->pm.sysfs_initialized = true;
 		}
 	}
 	return ret;
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/gpu/drm/vmwgfx/vmwgfx_cmdbuf.c linux-libre-4.3-gnu/drivers/gpu/drm/vmwgfx/vmwgfx_cmdbuf.c
--- linux-libre-4.3-rc7-gnu/drivers/gpu/drm/vmwgfx/vmwgfx_cmdbuf.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/gpu/drm/vmwgfx/vmwgfx_cmdbuf.c	2015-11-01 19:05:25.000000000 -0500
@@ -415,16 +415,16 @@ static void vmw_cmdbuf_ctx_process(struc
  *
  * Calls vmw_cmdbuf_ctx_process() on all contexts. If any context has
  * command buffers left that are not submitted to hardware, Make sure
- * IRQ handling is turned on. Otherwise, make sure it's turned off. This
- * function may return -EAGAIN to indicate it should be rerun due to
- * possibly missed IRQs if IRQs has just been turned on.
+ * IRQ handling is turned on. Otherwise, make sure it's turned off.
  */
-static int vmw_cmdbuf_man_process(struct vmw_cmdbuf_man *man)
+static void vmw_cmdbuf_man_process(struct vmw_cmdbuf_man *man)
 {
-	int notempty = 0;
+	int notempty;
 	struct vmw_cmdbuf_context *ctx;
 	int i;
 
+retry:
+	notempty = 0;
 	for_each_cmdbuf_ctx(man, i, ctx)
 		vmw_cmdbuf_ctx_process(man, ctx, &notempty);
 
@@ -440,10 +440,8 @@ static int vmw_cmdbuf_man_process(struct
 		man->irq_on = true;
 
 		/* Rerun in case we just missed an irq. */
-		return -EAGAIN;
+		goto retry;
 	}
-
-	return 0;
 }
 
 /**
@@ -468,8 +466,7 @@ static void vmw_cmdbuf_ctx_add(struct vm
 	header->cb_context = cb_context;
 	list_add_tail(&header->list, &man->ctx[cb_context].submitted);
 
-	if (vmw_cmdbuf_man_process(man) == -EAGAIN)
-		vmw_cmdbuf_man_process(man);
+	vmw_cmdbuf_man_process(man);
 }
 
 /**
@@ -488,8 +485,7 @@ static void vmw_cmdbuf_man_tasklet(unsig
 	struct vmw_cmdbuf_man *man = (struct vmw_cmdbuf_man *) data;
 
 	spin_lock(&man->lock);
-	if (vmw_cmdbuf_man_process(man) == -EAGAIN)
-		(void) vmw_cmdbuf_man_process(man);
+	vmw_cmdbuf_man_process(man);
 	spin_unlock(&man->lock);
 }
 
@@ -507,6 +503,7 @@ static void vmw_cmdbuf_work_func(struct
 	struct vmw_cmdbuf_man *man =
 		container_of(work, struct vmw_cmdbuf_man, work);
 	struct vmw_cmdbuf_header *entry, *next;
+	uint32_t dummy;
 	bool restart = false;
 
 	spin_lock_bh(&man->lock);
@@ -523,6 +520,8 @@ static void vmw_cmdbuf_work_func(struct
 	if (restart && vmw_cmdbuf_startstop(man, true))
 		DRM_ERROR("Failed restarting command buffer context 0.\n");
 
+	/* Send a new fence in case one was removed */
+	vmw_fifo_send_fence(man->dev_priv, &dummy);
 }
 
 /**
@@ -682,7 +681,7 @@ static bool vmw_cmdbuf_try_alloc(struct
 					 DRM_MM_SEARCH_DEFAULT,
 					 DRM_MM_CREATE_DEFAULT);
 	if (ret) {
-		(void) vmw_cmdbuf_man_process(man);
+		vmw_cmdbuf_man_process(man);
 		ret = drm_mm_insert_node_generic(&man->mm, info->node,
 						 info->page_size, 0, 0,
 						 DRM_MM_SEARCH_DEFAULT,
@@ -1168,7 +1167,14 @@ int vmw_cmdbuf_set_pool_size(struct vmw_
 	drm_mm_init(&man->mm, 0, size >> PAGE_SHIFT);
 
 	man->has_pool = true;
-	man->default_size = default_size;
+
+	/*
+	 * For now, set the default size to VMW_CMDBUF_INLINE_SIZE to
+	 * prevent deadlocks from happening when vmw_cmdbuf_space_pool()
+	 * needs to wait for space and we block on further command
+	 * submissions to be able to free up space.
+	 */
+	man->default_size = VMW_CMDBUF_INLINE_SIZE;
 	DRM_INFO("Using command buffers with %s pool.\n",
 		 (man->using_mob) ? "MOB" : "DMA");
 
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/i2c/busses/i2c-mv64xxx.c linux-libre-4.3-gnu/drivers/i2c/busses/i2c-mv64xxx.c
--- linux-libre-4.3-rc7-gnu/drivers/i2c/busses/i2c-mv64xxx.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/i2c/busses/i2c-mv64xxx.c	2015-11-01 19:05:25.000000000 -0500
@@ -669,8 +669,6 @@ mv64xxx_i2c_can_offload(struct mv64xxx_i
 	struct i2c_msg *msgs = drv_data->msgs;
 	int num = drv_data->num_msgs;
 
-	return false;
-
 	if (!drv_data->offload_enabled)
 		return false;
 
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/i2c/busses/i2c-pnx.c linux-libre-4.3-gnu/drivers/i2c/busses/i2c-pnx.c
--- linux-libre-4.3-rc7-gnu/drivers/i2c/busses/i2c-pnx.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/i2c/busses/i2c-pnx.c	2015-11-01 19:05:25.000000000 -0500
@@ -600,7 +600,7 @@ static int i2c_pnx_controller_suspend(st
 {
 	struct i2c_pnx_algo_data *alg_data = dev_get_drvdata(dev);
 
-	clk_disable(alg_data->clk);
+	clk_disable_unprepare(alg_data->clk);
 
 	return 0;
 }
@@ -609,7 +609,7 @@ static int i2c_pnx_controller_resume(str
 {
 	struct i2c_pnx_algo_data *alg_data = dev_get_drvdata(dev);
 
-	return clk_enable(alg_data->clk);
+	return clk_prepare_enable(alg_data->clk);
 }
 
 static SIMPLE_DEV_PM_OPS(i2c_pnx_pm,
@@ -672,7 +672,7 @@ static int i2c_pnx_probe(struct platform
 	if (IS_ERR(alg_data->ioaddr))
 		return PTR_ERR(alg_data->ioaddr);
 
-	ret = clk_enable(alg_data->clk);
+	ret = clk_prepare_enable(alg_data->clk);
 	if (ret)
 		return ret;
 
@@ -726,7 +726,7 @@ static int i2c_pnx_probe(struct platform
 	return 0;
 
 out_clock:
-	clk_disable(alg_data->clk);
+	clk_disable_unprepare(alg_data->clk);
 	return ret;
 }
 
@@ -735,7 +735,7 @@ static int i2c_pnx_remove(struct platfor
 	struct i2c_pnx_algo_data *alg_data = platform_get_drvdata(pdev);
 
 	i2c_del_adapter(&alg_data->adapter);
-	clk_disable(alg_data->clk);
+	clk_disable_unprepare(alg_data->clk);
 
 	return 0;
 }
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/input/mouse/alps.c linux-libre-4.3-gnu/drivers/input/mouse/alps.c
--- linux-libre-4.3-rc7-gnu/drivers/input/mouse/alps.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/input/mouse/alps.c	2015-11-01 19:05:25.000000000 -0500
@@ -100,7 +100,7 @@ static const struct alps_nibble_commands
 #define ALPS_FOUR_BUTTONS	0x40	/* 4 direction button present */
 #define ALPS_PS2_INTERLEAVED	0x80	/* 3-byte PS/2 packet interleaved with
 					   6-byte ALPS packet */
-#define ALPS_DELL		0x100	/* device is a Dell laptop */
+#define ALPS_STICK_BITS		0x100	/* separate stick button bits */
 #define ALPS_BUTTONPAD		0x200	/* device is a clickpad */
 
 static const struct alps_model_info alps_model_data[] = {
@@ -159,6 +159,43 @@ static const struct alps_protocol_info a
 	ALPS_PROTO_V8, 0x18, 0x18, 0
 };
 
+/*
+ * Some v2 models report the stick buttons in separate bits
+ */
+static const struct dmi_system_id alps_dmi_has_separate_stick_buttons[] = {
+#if defined(CONFIG_DMI) && defined(CONFIG_X86)
+	{
+		/* Extrapolated from other entries */
+		.matches = {
+			DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc."),
+			DMI_MATCH(DMI_PRODUCT_NAME, "Latitude D420"),
+		},
+	},
+	{
+		/* Reported-by: Hans de Bruin <jmdebruin@xmsnet.nl> */
+		.matches = {
+			DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc."),
+			DMI_MATCH(DMI_PRODUCT_NAME, "Latitude D430"),
+		},
+	},
+	{
+		/* Reported-by: Hans de Goede <hdegoede@redhat.com> */
+		.matches = {
+			DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc."),
+			DMI_MATCH(DMI_PRODUCT_NAME, "Latitude D620"),
+		},
+	},
+	{
+		/* Extrapolated from other entries */
+		.matches = {
+			DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc."),
+			DMI_MATCH(DMI_PRODUCT_NAME, "Latitude D630"),
+		},
+	},
+#endif
+	{ }
+};
+
 static void alps_set_abs_params_st(struct alps_data *priv,
 				   struct input_dev *dev1);
 static void alps_set_abs_params_semi_mt(struct alps_data *priv,
@@ -253,9 +290,8 @@ static void alps_process_packet_v1_v2(st
 		return;
 	}
 
-	/* Dell non interleaved V2 dualpoint has separate stick button bits */
-	if (priv->proto_version == ALPS_PROTO_V2 &&
-	    priv->flags == (ALPS_DELL | ALPS_PASS | ALPS_DUALPOINT)) {
+	/* Some models have separate stick button bits */
+	if (priv->flags & ALPS_STICK_BITS) {
 		left |= packet[0] & 1;
 		right |= packet[0] & 2;
 		middle |= packet[0] & 4;
@@ -2552,8 +2588,6 @@ static int alps_set_protocol(struct psmo
 	priv->byte0 = protocol->byte0;
 	priv->mask0 = protocol->mask0;
 	priv->flags = protocol->flags;
-	if (dmi_name_in_vendors("Dell"))
-		priv->flags |= ALPS_DELL;
 
 	priv->x_max = 2000;
 	priv->y_max = 1400;
@@ -2568,6 +2602,8 @@ static int alps_set_protocol(struct psmo
 		priv->set_abs_params = alps_set_abs_params_st;
 		priv->x_max = 1023;
 		priv->y_max = 767;
+		if (dmi_check_system(alps_dmi_has_separate_stick_buttons))
+			priv->flags |= ALPS_STICK_BITS;
 		break;
 
 	case ALPS_PROTO_V3:
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/input/touchscreen/Kconfig linux-libre-4.3-gnu/drivers/input/touchscreen/Kconfig
--- linux-libre-4.3-rc7-gnu/drivers/input/touchscreen/Kconfig	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/input/touchscreen/Kconfig	2015-11-01 19:05:25.000000000 -0500
@@ -1006,6 +1006,7 @@ config TOUCHSCREEN_SUN4I
 config TOUCHSCREEN_SUR40
 	tristate "Samsung SUR40 (Surface 2.0/PixelSense) touchscreen"
 	depends on USB && MEDIA_USB_SUPPORT && HAS_DMA
+	depends on VIDEO_V4L2
 	select INPUT_POLLDEV
 	select VIDEOBUF2_DMA_SG
 	help
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/input/touchscreen/lpc32xx_ts.c linux-libre-4.3-gnu/drivers/input/touchscreen/lpc32xx_ts.c
--- linux-libre-4.3-rc7-gnu/drivers/input/touchscreen/lpc32xx_ts.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/input/touchscreen/lpc32xx_ts.c	2015-11-01 19:05:25.000000000 -0500
@@ -139,14 +139,14 @@ static void lpc32xx_stop_tsc(struct lpc3
 		   tsc_readl(tsc, LPC32XX_TSC_CON) &
 			     ~LPC32XX_TSC_ADCCON_AUTO_EN);
 
-	clk_disable(tsc->clk);
+	clk_disable_unprepare(tsc->clk);
 }
 
 static void lpc32xx_setup_tsc(struct lpc32xx_tsc *tsc)
 {
 	u32 tmp;
 
-	clk_enable(tsc->clk);
+	clk_prepare_enable(tsc->clk);
 
 	tmp = tsc_readl(tsc, LPC32XX_TSC_CON) & ~LPC32XX_TSC_ADCCON_POWER_UP;
 
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/iommu/amd_iommu.c linux-libre-4.3-gnu/drivers/iommu/amd_iommu.c
--- linux-libre-4.3-rc7-gnu/drivers/iommu/amd_iommu.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/iommu/amd_iommu.c	2015-11-01 19:05:25.000000000 -0500
@@ -1974,8 +1974,8 @@ static void set_dte_entry(u16 devid, str
 static void clear_dte_entry(u16 devid)
 {
 	/* remove entry from the device table seen by the hardware */
-	amd_iommu_dev_table[devid].data[0] = IOMMU_PTE_P | IOMMU_PTE_TV;
-	amd_iommu_dev_table[devid].data[1] = 0;
+	amd_iommu_dev_table[devid].data[0]  = IOMMU_PTE_P | IOMMU_PTE_TV;
+	amd_iommu_dev_table[devid].data[1] &= DTE_FLAG_MASK;
 
 	amd_iommu_apply_erratum_63(devid);
 }
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/iommu/amd_iommu_types.h linux-libre-4.3-gnu/drivers/iommu/amd_iommu_types.h
--- linux-libre-4.3-rc7-gnu/drivers/iommu/amd_iommu_types.h	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/iommu/amd_iommu_types.h	2015-11-01 19:05:25.000000000 -0500
@@ -295,6 +295,7 @@
 #define IOMMU_PTE_IR (1ULL << 61)
 #define IOMMU_PTE_IW (1ULL << 62)
 
+#define DTE_FLAG_MASK	(0x3ffULL << 32)
 #define DTE_FLAG_IOTLB	(0x01UL << 32)
 #define DTE_FLAG_GV	(0x01ULL << 55)
 #define DTE_GLX_SHIFT	(56)
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/iommu/amd_iommu_v2.c linux-libre-4.3-gnu/drivers/iommu/amd_iommu_v2.c
--- linux-libre-4.3-rc7-gnu/drivers/iommu/amd_iommu_v2.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/iommu/amd_iommu_v2.c	2015-11-01 19:05:25.000000000 -0500
@@ -516,6 +516,13 @@ static void do_fault(struct work_struct
 		goto out;
 	}
 
+	if (!(vma->vm_flags & (VM_READ | VM_EXEC | VM_WRITE))) {
+		/* handle_mm_fault would BUG_ON() */
+		up_read(&mm->mmap_sem);
+		handle_fault_error(fault);
+		goto out;
+	}
+
 	ret = handle_mm_fault(mm, vma, address, write);
 	if (ret & VM_FAULT_ERROR) {
 		/* failed to service fault */
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/irqchip/irq-armada-370-xp.c linux-libre-4.3-gnu/drivers/irqchip/irq-armada-370-xp.c
--- linux-libre-4.3-rc7-gnu/drivers/irqchip/irq-armada-370-xp.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/irqchip/irq-armada-370-xp.c	2015-11-01 19:05:25.000000000 -0500
@@ -317,6 +317,7 @@ static int armada_370_xp_mpic_irq_map(st
 					handle_level_irq);
 	}
 	irq_set_probe(virq);
+	irq_clear_status_flags(virq, IRQ_NOAUTOEN);
 
 	return 0;
 }
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/irqchip/irq-tegra.c linux-libre-4.3-gnu/drivers/irqchip/irq-tegra.c
--- linux-libre-4.3-rc7-gnu/drivers/irqchip/irq-tegra.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/irqchip/irq-tegra.c	2015-11-01 19:05:25.000000000 -0500
@@ -214,6 +214,7 @@ static struct irq_chip tegra_ictlr_chip
 	.irq_unmask		= tegra_unmask,
 	.irq_retrigger		= tegra_retrigger,
 	.irq_set_wake		= tegra_set_wake,
+	.irq_set_type		= irq_chip_set_type_parent,
 	.flags			= IRQCHIP_MASK_ON_SUSPEND,
 #ifdef CONFIG_SMP
 	.irq_set_affinity	= irq_chip_set_affinity_parent,
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/isdn/hisax/isdnl2.c linux-libre-4.3-gnu/drivers/isdn/hisax/isdnl2.c
--- linux-libre-4.3-rc7-gnu/drivers/isdn/hisax/isdnl2.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/isdn/hisax/isdnl2.c	2015-11-01 19:05:25.000000000 -0500
@@ -1247,7 +1247,7 @@ static void
 l2_pull_iqueue(struct FsmInst *fi, int event, void *arg)
 {
 	struct PStack *st = fi->userdata;
-	struct sk_buff *skb;
+	struct sk_buff *skb, *nskb;
 	struct Layer2 *l2 = &st->l2;
 	u_char header[MAX_HEADER_LEN];
 	int i, hdr_space_needed;
@@ -1262,14 +1262,10 @@ l2_pull_iqueue(struct FsmInst *fi, int e
 		return;
 
 	hdr_space_needed = l2headersize(l2, 0);
-	if (hdr_space_needed > skb_headroom(skb)) {
-		struct sk_buff *orig_skb = skb;
-
-		skb = skb_realloc_headroom(skb, hdr_space_needed);
-		if (!skb) {
-			dev_kfree_skb(orig_skb);
-			return;
-		}
+	nskb = skb_realloc_headroom(skb, hdr_space_needed);
+	if (!nskb) {
+		skb_queue_head(&l2->i_queue, skb);
+		return;
 	}
 	spin_lock_irqsave(&l2->lock, flags);
 	if (test_bit(FLG_MOD128, &l2->flag))
@@ -1282,7 +1278,7 @@ l2_pull_iqueue(struct FsmInst *fi, int e
 		       p1);
 		dev_kfree_skb(l2->windowar[p1]);
 	}
-	l2->windowar[p1] = skb_clone(skb, GFP_ATOMIC);
+	l2->windowar[p1] = skb;
 
 	i = sethdraddr(&st->l2, header, CMD);
 
@@ -1295,8 +1291,8 @@ l2_pull_iqueue(struct FsmInst *fi, int e
 		l2->vs = (l2->vs + 1) % 8;
 	}
 	spin_unlock_irqrestore(&l2->lock, flags);
-	memcpy(skb_push(skb, i), header, i);
-	st->l2.l2l1(st, PH_PULL | INDICATION, skb);
+	memcpy(skb_push(nskb, i), header, i);
+	st->l2.l2l1(st, PH_PULL | INDICATION, nskb);
 	test_and_clear_bit(FLG_ACK_PEND, &st->l2.flag);
 	if (!test_and_set_bit(FLG_T200_RUN, &st->l2.flag)) {
 		FsmDelTimer(&st->l2.t203, 13);
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/isdn/mISDN/layer2.c linux-libre-4.3-gnu/drivers/isdn/mISDN/layer2.c
--- linux-libre-4.3-rc7-gnu/drivers/isdn/mISDN/layer2.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/isdn/mISDN/layer2.c	2015-11-01 19:05:25.000000000 -0500
@@ -1476,7 +1476,7 @@ static void
 l2_pull_iqueue(struct FsmInst *fi, int event, void *arg)
 {
 	struct layer2	*l2 = fi->userdata;
-	struct sk_buff	*skb, *nskb, *oskb;
+	struct sk_buff	*skb, *nskb;
 	u_char		header[MAX_L2HEADER_LEN];
 	u_int		i, p1;
 
@@ -1486,48 +1486,34 @@ l2_pull_iqueue(struct FsmInst *fi, int e
 	skb = skb_dequeue(&l2->i_queue);
 	if (!skb)
 		return;
-
-	if (test_bit(FLG_MOD128, &l2->flag))
-		p1 = (l2->vs - l2->va) % 128;
-	else
-		p1 = (l2->vs - l2->va) % 8;
-	p1 = (p1 + l2->sow) % l2->window;
-	if (l2->windowar[p1]) {
-		printk(KERN_WARNING "%s: l2 try overwrite ack queue entry %d\n",
-		       mISDNDevName4ch(&l2->ch), p1);
-		dev_kfree_skb(l2->windowar[p1]);
-	}
-	l2->windowar[p1] = skb;
 	i = sethdraddr(l2, header, CMD);
 	if (test_bit(FLG_MOD128, &l2->flag)) {
 		header[i++] = l2->vs << 1;
 		header[i++] = l2->vr << 1;
+	} else
+		header[i++] = (l2->vr << 5) | (l2->vs << 1);
+	nskb = skb_realloc_headroom(skb, i);
+	if (!nskb) {
+		printk(KERN_WARNING "%s: no headroom(%d) copy for IFrame\n",
+		       mISDNDevName4ch(&l2->ch), i);
+		skb_queue_head(&l2->i_queue, skb);
+		return;
+	}
+	if (test_bit(FLG_MOD128, &l2->flag)) {
+		p1 = (l2->vs - l2->va) % 128;
 		l2->vs = (l2->vs + 1) % 128;
 	} else {
-		header[i++] = (l2->vr << 5) | (l2->vs << 1);
+		p1 = (l2->vs - l2->va) % 8;
 		l2->vs = (l2->vs + 1) % 8;
 	}
-
-	nskb = skb_clone(skb, GFP_ATOMIC);
-	p1 = skb_headroom(nskb);
-	if (p1 >= i)
-		memcpy(skb_push(nskb, i), header, i);
-	else {
-		printk(KERN_WARNING
-		       "%s: L2 pull_iqueue skb header(%d/%d) too short\n",
-		       mISDNDevName4ch(&l2->ch), i, p1);
-		oskb = nskb;
-		nskb = mI_alloc_skb(oskb->len + i, GFP_ATOMIC);
-		if (!nskb) {
-			dev_kfree_skb(oskb);
-			printk(KERN_WARNING "%s: no skb mem in %s\n",
-			       mISDNDevName4ch(&l2->ch), __func__);
-			return;
-		}
-		memcpy(skb_put(nskb, i), header, i);
-		memcpy(skb_put(nskb, oskb->len), oskb->data, oskb->len);
-		dev_kfree_skb(oskb);
+	p1 = (p1 + l2->sow) % l2->window;
+	if (l2->windowar[p1]) {
+		printk(KERN_WARNING "%s: l2 try overwrite ack queue entry %d\n",
+		       mISDNDevName4ch(&l2->ch), p1);
+		dev_kfree_skb(l2->windowar[p1]);
 	}
+	l2->windowar[p1] = skb;
+	memcpy(skb_push(nskb, i), header, i);
 	l2down(l2, PH_DATA_REQ, l2_newid(l2), nskb);
 	test_and_clear_bit(FLG_ACK_PEND, &l2->flag);
 	if (!test_and_set_bit(FLG_T200_RUN, &l2->flag)) {
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/md/md.c linux-libre-4.3-gnu/drivers/md/md.c
--- linux-libre-4.3-rc7-gnu/drivers/md/md.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/md/md.c	2015-11-01 19:05:25.000000000 -0500
@@ -8040,8 +8040,7 @@ static int remove_and_add_spares(struct
 		       !test_bit(Bitmap_sync, &rdev->flags)))
 			continue;
 
-		if (rdev->saved_raid_disk < 0)
-			rdev->recovery_offset = 0;
+		rdev->recovery_offset = 0;
 		if (mddev->pers->
 		    hot_add_disk(mddev, rdev) == 0) {
 			if (sysfs_link_rdev(mddev, rdev))
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/md/raid10.c linux-libre-4.3-gnu/drivers/md/raid10.c
--- linux-libre-4.3-rc7-gnu/drivers/md/raid10.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/md/raid10.c	2015-11-01 19:05:25.000000000 -0500
@@ -39,6 +39,7 @@
  *    far_copies (stored in second byte of layout)
  *    far_offset (stored in bit 16 of layout )
  *    use_far_sets (stored in bit 17 of layout )
+ *    use_far_sets_bugfixed (stored in bit 18 of layout )
  *
  * The data to be stored is divided into chunks using chunksize.  Each device
  * is divided into far_copies sections.   In each section, chunks are laid out
@@ -1497,6 +1498,8 @@ static void status(struct seq_file *seq,
 			seq_printf(seq, " %d offset-copies", conf->geo.far_copies);
 		else
 			seq_printf(seq, " %d far-copies", conf->geo.far_copies);
+		if (conf->geo.far_set_size != conf->geo.raid_disks)
+			seq_printf(seq, " %d devices per set", conf->geo.far_set_size);
 	}
 	seq_printf(seq, " [%d/%d] [", conf->geo.raid_disks,
 					conf->geo.raid_disks - mddev->degraded);
@@ -2467,7 +2470,7 @@ static int narrow_write_error(struct r10
 				   choose_data_offset(r10_bio, rdev) +
 				   (sector - r10_bio->sector));
 		wbio->bi_bdev = rdev->bdev;
-		if (submit_bio_wait(WRITE, wbio) == 0)
+		if (submit_bio_wait(WRITE, wbio) < 0)
 			/* Failure! */
 			ok = rdev_set_badblocks(rdev, sector,
 						sectors, 0)
@@ -2654,16 +2657,17 @@ static void handle_write_completed(struc
 				rdev_dec_pending(rdev, conf->mddev);
 			}
 		}
-		if (test_bit(R10BIO_WriteError,
-			     &r10_bio->state))
-			close_write(r10_bio);
 		if (fail) {
 			spin_lock_irq(&conf->device_lock);
 			list_add(&r10_bio->retry_list, &conf->bio_end_io_list);
 			spin_unlock_irq(&conf->device_lock);
 			md_wakeup_thread(conf->mddev->thread);
-		} else
+		} else {
+			if (test_bit(R10BIO_WriteError,
+				     &r10_bio->state))
+				close_write(r10_bio);
 			raid_end_bio_io(r10_bio);
+		}
 	}
 }
 
@@ -2691,6 +2695,12 @@ static void raid10d(struct md_thread *th
 			r10_bio = list_first_entry(&tmp, struct r10bio,
 						   retry_list);
 			list_del(&r10_bio->retry_list);
+			if (mddev->degraded)
+				set_bit(R10BIO_Degraded, &r10_bio->state);
+
+			if (test_bit(R10BIO_WriteError,
+				     &r10_bio->state))
+				close_write(r10_bio);
 			raid_end_bio_io(r10_bio);
 		}
 	}
@@ -3387,7 +3397,7 @@ static int setup_geo(struct geom *geo, s
 		disks = mddev->raid_disks + mddev->delta_disks;
 		break;
 	}
-	if (layout >> 18)
+	if (layout >> 19)
 		return -1;
 	if (chunk < (PAGE_SIZE >> 9) ||
 	    !is_power_of_2(chunk))
@@ -3399,7 +3409,22 @@ static int setup_geo(struct geom *geo, s
 	geo->near_copies = nc;
 	geo->far_copies = fc;
 	geo->far_offset = fo;
-	geo->far_set_size = (layout & (1<<17)) ? disks / fc : disks;
+	switch (layout >> 17) {
+	case 0:	/* original layout.  simple but not always optimal */
+		geo->far_set_size = disks;
+		break;
+	case 1: /* "improved" layout which was buggy.  Hopefully no-one is
+		 * actually using this, but leave code here just in case.*/
+		geo->far_set_size = disks/fc;
+		WARN(geo->far_set_size < fc,
+		     "This RAID10 layout does not provide data safety - please backup and create new array\n");
+		break;
+	case 2: /* "improved" layout fixed to match documentation */
+		geo->far_set_size = fc * nc;
+		break;
+	default: /* Not a valid layout */
+		return -1;
+	}
 	geo->chunk_mask = chunk - 1;
 	geo->chunk_shift = ffz(~chunk);
 	return nc*fc;
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/md/raid1.c linux-libre-4.3-gnu/drivers/md/raid1.c
--- linux-libre-4.3-rc7-gnu/drivers/md/raid1.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/md/raid1.c	2015-11-01 19:05:25.000000000 -0500
@@ -2195,7 +2195,7 @@ static int narrow_write_error(struct r1b
 		bio_trim(wbio, sector - r1_bio->sector, sectors);
 		wbio->bi_iter.bi_sector += rdev->data_offset;
 		wbio->bi_bdev = rdev->bdev;
-		if (submit_bio_wait(WRITE, wbio) == 0)
+		if (submit_bio_wait(WRITE, wbio) < 0)
 			/* failure! */
 			ok = rdev_set_badblocks(rdev, sector,
 						sectors, 0)
@@ -2258,15 +2258,16 @@ static void handle_write_finished(struct
 			rdev_dec_pending(conf->mirrors[m].rdev,
 					 conf->mddev);
 		}
-	if (test_bit(R1BIO_WriteError, &r1_bio->state))
-		close_write(r1_bio);
 	if (fail) {
 		spin_lock_irq(&conf->device_lock);
 		list_add(&r1_bio->retry_list, &conf->bio_end_io_list);
 		spin_unlock_irq(&conf->device_lock);
 		md_wakeup_thread(conf->mddev->thread);
-	} else
+	} else {
+		if (test_bit(R1BIO_WriteError, &r1_bio->state))
+			close_write(r1_bio);
 		raid_end_bio_io(r1_bio);
+	}
 }
 
 static void handle_read_error(struct r1conf *conf, struct r1bio *r1_bio)
@@ -2385,6 +2386,10 @@ static void raid1d(struct md_thread *thr
 			r1_bio = list_first_entry(&tmp, struct r1bio,
 						  retry_list);
 			list_del(&r1_bio->retry_list);
+			if (mddev->degraded)
+				set_bit(R1BIO_Degraded, &r1_bio->state);
+			if (test_bit(R1BIO_WriteError, &r1_bio->state))
+				close_write(r1_bio);
 			raid_end_bio_io(r1_bio);
 		}
 	}
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/md/raid5.c linux-libre-4.3-gnu/drivers/md/raid5.c
--- linux-libre-4.3-rc7-gnu/drivers/md/raid5.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/md/raid5.c	2015-11-01 19:05:25.000000000 -0500
@@ -3499,6 +3499,7 @@ returnbi:
 		}
 	if (!discard_pending &&
 	    test_bit(R5_Discard, &sh->dev[sh->pd_idx].flags)) {
+		int hash;
 		clear_bit(R5_Discard, &sh->dev[sh->pd_idx].flags);
 		clear_bit(R5_UPTODATE, &sh->dev[sh->pd_idx].flags);
 		if (sh->qd_idx >= 0) {
@@ -3512,16 +3513,17 @@ returnbi:
 		 * no updated data, so remove it from hash list and the stripe
 		 * will be reinitialized
 		 */
-		spin_lock_irq(&conf->device_lock);
 unhash:
+		hash = sh->hash_lock_index;
+		spin_lock_irq(conf->hash_locks + hash);
 		remove_hash(sh);
+		spin_unlock_irq(conf->hash_locks + hash);
 		if (head_sh->batch_head) {
 			sh = list_first_entry(&sh->batch_list,
 					      struct stripe_head, batch_list);
 			if (sh != head_sh)
 					goto unhash;
 		}
-		spin_unlock_irq(&conf->device_lock);
 		sh = head_sh;
 
 		if (test_bit(STRIPE_SYNC_REQUESTED, &sh->state))
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/net/ethernet/allwinner/sun4i-emac.c linux-libre-4.3-gnu/drivers/net/ethernet/allwinner/sun4i-emac.c
--- linux-libre-4.3-rc7-gnu/drivers/net/ethernet/allwinner/sun4i-emac.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/net/ethernet/allwinner/sun4i-emac.c	2015-11-01 19:05:25.000000000 -0500
@@ -847,21 +847,25 @@ static int emac_probe(struct platform_de
 	if (ndev->irq == -ENXIO) {
 		netdev_err(ndev, "No irq resource\n");
 		ret = ndev->irq;
-		goto out;
+		goto out_iounmap;
 	}
 
 	db->clk = devm_clk_get(&pdev->dev, NULL);
 	if (IS_ERR(db->clk)) {
 		ret = PTR_ERR(db->clk);
-		goto out;
+		goto out_iounmap;
 	}
 
-	clk_prepare_enable(db->clk);
+	ret = clk_prepare_enable(db->clk);
+	if (ret) {
+		dev_err(&pdev->dev, "Error couldn't enable clock (%d)\n", ret);
+		goto out_iounmap;
+	}
 
 	ret = sunxi_sram_claim(&pdev->dev);
 	if (ret) {
 		dev_err(&pdev->dev, "Error couldn't map SRAM to device\n");
-		goto out;
+		goto out_clk_disable_unprepare;
 	}
 
 	db->phy_node = of_parse_phandle(np, "phy", 0);
@@ -910,6 +914,10 @@ static int emac_probe(struct platform_de
 
 out_release_sram:
 	sunxi_sram_release(&pdev->dev);
+out_clk_disable_unprepare:
+	clk_disable_unprepare(db->clk);
+out_iounmap:
+	iounmap(db->membase);
 out:
 	dev_err(db->dev, "not found (%d).\n", ret);
 
@@ -921,8 +929,12 @@ out:
 static int emac_remove(struct platform_device *pdev)
 {
 	struct net_device *ndev = platform_get_drvdata(pdev);
+	struct emac_board_info *db = netdev_priv(ndev);
 
 	unregister_netdev(ndev);
+	sunxi_sram_release(&pdev->dev);
+	clk_disable_unprepare(db->clk);
+	iounmap(db->membase);
 	free_netdev(ndev);
 
 	dev_dbg(&pdev->dev, "released and freed device\n");
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/net/ethernet/amd/xgbe/xgbe-dev.c linux-libre-4.3-gnu/drivers/net/ethernet/amd/xgbe/xgbe-dev.c
--- linux-libre-4.3-rc7-gnu/drivers/net/ethernet/amd/xgbe/xgbe-dev.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/net/ethernet/amd/xgbe/xgbe-dev.c	2015-11-01 19:05:25.000000000 -0500
@@ -1595,7 +1595,7 @@ static void xgbe_dev_xmit(struct xgbe_ch
 				  packet->rdesc_count, 1);
 
 	/* Make sure ownership is written to the descriptor */
-	dma_wmb();
+	smp_wmb();
 
 	ring->cur = cur_index + 1;
 	if (!packet->skb->xmit_more ||
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/net/ethernet/amd/xgbe/xgbe-drv.c linux-libre-4.3-gnu/drivers/net/ethernet/amd/xgbe/xgbe-drv.c
--- linux-libre-4.3-rc7-gnu/drivers/net/ethernet/amd/xgbe/xgbe-drv.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/net/ethernet/amd/xgbe/xgbe-drv.c	2015-11-01 19:05:25.000000000 -0500
@@ -1807,6 +1807,7 @@ static int xgbe_tx_poll(struct xgbe_chan
 	struct netdev_queue *txq;
 	int processed = 0;
 	unsigned int tx_packets = 0, tx_bytes = 0;
+	unsigned int cur;
 
 	DBGPR("-->xgbe_tx_poll\n");
 
@@ -1814,10 +1815,15 @@ static int xgbe_tx_poll(struct xgbe_chan
 	if (!ring)
 		return 0;
 
+	cur = ring->cur;
+
+	/* Be sure we get ring->cur before accessing descriptor data */
+	smp_rmb();
+
 	txq = netdev_get_tx_queue(netdev, channel->queue_index);
 
 	while ((processed < XGBE_TX_DESC_MAX_PROC) &&
-	       (ring->dirty != ring->cur)) {
+	       (ring->dirty != cur)) {
 		rdata = XGBE_GET_DESC_DATA(ring, ring->dirty);
 		rdesc = rdata->rdesc;
 
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/net/ethernet/broadcom/bcm63xx_enet.c linux-libre-4.3-gnu/drivers/net/ethernet/broadcom/bcm63xx_enet.c
--- linux-libre-4.3-rc7-gnu/drivers/net/ethernet/broadcom/bcm63xx_enet.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/net/ethernet/broadcom/bcm63xx_enet.c	2015-11-01 19:05:25.000000000 -0500
@@ -2049,7 +2049,7 @@ static void swphy_poll_timer(unsigned lo
 
 	for (i = 0; i < priv->num_ports; i++) {
 		struct bcm63xx_enetsw_port *port;
-		int val, j, up, advertise, lpa, lpa2, speed, duplex, media;
+		int val, j, up, advertise, lpa, speed, duplex, media;
 		int external_phy = bcm_enet_port_is_rgmii(i);
 		u8 override;
 
@@ -2092,22 +2092,27 @@ static void swphy_poll_timer(unsigned lo
 		lpa = bcmenet_sw_mdio_read(priv, external_phy, port->phy_id,
 					   MII_LPA);
 
-		lpa2 = bcmenet_sw_mdio_read(priv, external_phy, port->phy_id,
-					    MII_STAT1000);
-
 		/* figure out media and duplex from advertise and LPA values */
 		media = mii_nway_result(lpa & advertise);
 		duplex = (media & ADVERTISE_FULL) ? 1 : 0;
-		if (lpa2 & LPA_1000FULL)
-			duplex = 1;
 
-		if (lpa2 & (LPA_1000FULL | LPA_1000HALF))
-			speed = 1000;
-		else {
-			if (media & (ADVERTISE_100FULL | ADVERTISE_100HALF))
-				speed = 100;
-			else
-				speed = 10;
+		if (media & (ADVERTISE_100FULL | ADVERTISE_100HALF))
+			speed = 100;
+		else
+			speed = 10;
+
+		if (val & BMSR_ESTATEN) {
+			advertise = bcmenet_sw_mdio_read(priv, external_phy,
+						port->phy_id, MII_CTRL1000);
+
+			lpa = bcmenet_sw_mdio_read(priv, external_phy,
+						port->phy_id, MII_STAT1000);
+
+			if (advertise & (ADVERTISE_1000FULL | ADVERTISE_1000HALF)
+					&& lpa & (LPA_1000FULL | LPA_1000HALF)) {
+				speed = 1000;
+				duplex = (lpa & LPA_1000FULL);
+			}
 		}
 
 		dev_info(&priv->pdev->dev,
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/net/ethernet/cavium/Kconfig linux-libre-4.3-gnu/drivers/net/ethernet/cavium/Kconfig
--- linux-libre-4.3-rc7-gnu/drivers/net/ethernet/cavium/Kconfig	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/net/ethernet/cavium/Kconfig	2015-11-01 19:05:25.000000000 -0500
@@ -3,7 +3,7 @@
 #
 
 config NET_VENDOR_CAVIUM
-	tristate "Cavium ethernet drivers"
+	bool "Cavium ethernet drivers"
 	depends on PCI
 	default y
 	---help---
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/net/ethernet/cavium/thunder/nic_main.c linux-libre-4.3-gnu/drivers/net/ethernet/cavium/thunder/nic_main.c
--- linux-libre-4.3-rc7-gnu/drivers/net/ethernet/cavium/thunder/nic_main.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/net/ethernet/cavium/thunder/nic_main.c	2015-11-01 19:05:25.000000000 -0500
@@ -22,7 +22,6 @@
 
 struct nicpf {
 	struct pci_dev		*pdev;
-	u8			rev_id;
 	u8			node;
 	unsigned int		flags;
 	u8			num_vf_en;      /* No of VF enabled */
@@ -44,6 +43,7 @@ struct nicpf {
 	u8			duplex[MAX_LMAC];
 	u32			speed[MAX_LMAC];
 	u16			cpi_base[MAX_NUM_VFS_SUPPORTED];
+	u16			rssi_base[MAX_NUM_VFS_SUPPORTED];
 	u16			rss_ind_tbl_size;
 	bool			mbx_lock[MAX_NUM_VFS_SUPPORTED];
 
@@ -54,6 +54,11 @@ struct nicpf {
 	bool			irq_allocated[NIC_PF_MSIX_VECTORS];
 };
 
+static inline bool pass1_silicon(struct nicpf *nic)
+{
+	return nic->pdev->revision < 8;
+}
+
 /* Supported devices */
 static const struct pci_device_id nic_id_table[] = {
 	{ PCI_DEVICE(PCI_VENDOR_ID_CAVIUM, PCI_DEVICE_ID_THUNDER_NIC_PF) },
@@ -117,7 +122,7 @@ static void nic_send_msg_to_vf(struct ni
 	 * when PF writes to MBOX(1), in next revisions when
 	 * PF writes to MBOX(0)
 	 */
-	if (nic->rev_id == 0) {
+	if (pass1_silicon(nic)) {
 		/* see the comment for nic_reg_write()/nic_reg_read()
 		 * functions above
 		 */
@@ -305,9 +310,6 @@ static void nic_init_hw(struct nicpf *ni
 {
 	int i;
 
-	/* Reset NIC, in case the driver is repeatedly inserted and removed */
-	nic_reg_write(nic, NIC_PF_SOFT_RESET, 1);
-
 	/* Enable NIC HW block */
 	nic_reg_write(nic, NIC_PF_CFG, 0x3);
 
@@ -395,8 +397,18 @@ static void nic_config_cpi(struct nicpf
 			padd = cpi % 8; /* 3 bits CS out of 6bits DSCP */
 
 		/* Leave RSS_SIZE as '0' to disable RSS */
-		nic_reg_write(nic, NIC_PF_CPI_0_2047_CFG | (cpi << 3),
-			      (vnic << 24) | (padd << 16) | (rssi_base + rssi));
+		if (pass1_silicon(nic)) {
+			nic_reg_write(nic, NIC_PF_CPI_0_2047_CFG | (cpi << 3),
+				      (vnic << 24) | (padd << 16) |
+				      (rssi_base + rssi));
+		} else {
+			/* Set MPI_ALG to '0' to disable MCAM parsing */
+			nic_reg_write(nic, NIC_PF_CPI_0_2047_CFG | (cpi << 3),
+				      (padd << 16));
+			/* MPI index is same as CPI if MPI_ALG is not enabled */
+			nic_reg_write(nic, NIC_PF_MPI_0_2047_CFG | (cpi << 3),
+				      (vnic << 24) | (rssi_base + rssi));
+		}
 
 		if ((rssi + 1) >= cfg->rq_cnt)
 			continue;
@@ -409,6 +421,7 @@ static void nic_config_cpi(struct nicpf
 			rssi = ((cpi - cpi_base) & 0x38) >> 3;
 	}
 	nic->cpi_base[cfg->vf_id] = cpi_base;
+	nic->rssi_base[cfg->vf_id] = rssi_base;
 }
 
 /* Responsds to VF with its RSS indirection table size */
@@ -434,10 +447,9 @@ static void nic_config_rss(struct nicpf
 {
 	u8  qset, idx = 0;
 	u64 cpi_cfg, cpi_base, rssi_base, rssi;
+	u64 idx_addr;
 
-	cpi_base = nic->cpi_base[cfg->vf_id];
-	cpi_cfg = nic_reg_read(nic, NIC_PF_CPI_0_2047_CFG | (cpi_base << 3));
-	rssi_base = (cpi_cfg & 0x0FFF) + cfg->tbl_offset;
+	rssi_base = nic->rssi_base[cfg->vf_id] + cfg->tbl_offset;
 
 	rssi = rssi_base;
 	qset = cfg->vf_id;
@@ -454,9 +466,15 @@ static void nic_config_rss(struct nicpf
 		idx++;
 	}
 
+	cpi_base = nic->cpi_base[cfg->vf_id];
+	if (pass1_silicon(nic))
+		idx_addr = NIC_PF_CPI_0_2047_CFG;
+	else
+		idx_addr = NIC_PF_MPI_0_2047_CFG;
+	cpi_cfg = nic_reg_read(nic, idx_addr | (cpi_base << 3));
 	cpi_cfg &= ~(0xFULL << 20);
 	cpi_cfg |= (cfg->hash_bits << 20);
-	nic_reg_write(nic, NIC_PF_CPI_0_2047_CFG | (cpi_base << 3), cpi_cfg);
+	nic_reg_write(nic, idx_addr | (cpi_base << 3), cpi_cfg);
 }
 
 /* 4 level transmit side scheduler configutation
@@ -1001,8 +1019,6 @@ static int nic_probe(struct pci_dev *pde
 		goto err_release_regions;
 	}
 
-	pci_read_config_byte(pdev, PCI_REVISION_ID, &nic->rev_id);
-
 	nic->node = nic_get_node_id(pdev);
 
 	nic_set_lmac_vf_mapping(nic);
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/net/ethernet/cavium/thunder/nic_reg.h linux-libre-4.3-gnu/drivers/net/ethernet/cavium/thunder/nic_reg.h
--- linux-libre-4.3-rc7-gnu/drivers/net/ethernet/cavium/thunder/nic_reg.h	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/net/ethernet/cavium/thunder/nic_reg.h	2015-11-01 19:05:25.000000000 -0500
@@ -85,7 +85,11 @@
 #define   NIC_PF_ECC3_DBE_INT_W1S		(0x2708)
 #define   NIC_PF_ECC3_DBE_ENA_W1C		(0x2710)
 #define   NIC_PF_ECC3_DBE_ENA_W1S		(0x2718)
+#define   NIC_PF_MCAM_0_191_ENA			(0x100000)
+#define   NIC_PF_MCAM_0_191_M_0_5_DATA		(0x110000)
+#define   NIC_PF_MCAM_CTRL			(0x120000)
 #define   NIC_PF_CPI_0_2047_CFG			(0x200000)
+#define   NIC_PF_MPI_0_2047_CFG			(0x210000)
 #define   NIC_PF_RSSI_0_4097_RQ			(0x220000)
 #define   NIC_PF_LMAC_0_7_CFG			(0x240000)
 #define   NIC_PF_LMAC_0_7_SW_XOFF		(0x242000)
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/net/ethernet/cavium/thunder/nicvf_main.c linux-libre-4.3-gnu/drivers/net/ethernet/cavium/thunder/nicvf_main.c
--- linux-libre-4.3-rc7-gnu/drivers/net/ethernet/cavium/thunder/nicvf_main.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/net/ethernet/cavium/thunder/nicvf_main.c	2015-11-01 19:05:25.000000000 -0500
@@ -29,7 +29,7 @@
 static const struct pci_device_id nicvf_id_table[] = {
 	{ PCI_DEVICE_SUB(PCI_VENDOR_ID_CAVIUM,
 			 PCI_DEVICE_ID_THUNDER_NIC_VF,
-			 PCI_VENDOR_ID_CAVIUM, 0xA11E) },
+			 PCI_VENDOR_ID_CAVIUM, 0xA134) },
 	{ PCI_DEVICE_SUB(PCI_VENDOR_ID_CAVIUM,
 			 PCI_DEVICE_ID_THUNDER_PASS1_NIC_VF,
 			 PCI_VENDOR_ID_CAVIUM, 0xA11E) },
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/net/ethernet/cavium/thunder/thunder_bgx.c linux-libre-4.3-gnu/drivers/net/ethernet/cavium/thunder/thunder_bgx.c
--- linux-libre-4.3-rc7-gnu/drivers/net/ethernet/cavium/thunder/thunder_bgx.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/net/ethernet/cavium/thunder/thunder_bgx.c	2015-11-01 19:05:25.000000000 -0500
@@ -977,8 +977,10 @@ static int bgx_init_of_phy(struct bgx *b
 		SET_NETDEV_DEV(&bgx->lmac[lmac].netdev, &bgx->pdev->dev);
 		bgx->lmac[lmac].lmacid = lmac;
 		lmac++;
-		if (lmac == MAX_LMAC_PER_BGX)
+		if (lmac == MAX_LMAC_PER_BGX) {
+			of_node_put(np_child);
 			break;
+		}
 	}
 	return 0;
 }
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/net/ethernet/freescale/gianfar.c linux-libre-4.3-gnu/drivers/net/ethernet/freescale/gianfar.c
--- linux-libre-4.3-rc7-gnu/drivers/net/ethernet/freescale/gianfar.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/net/ethernet/freescale/gianfar.c	2015-11-01 19:05:25.000000000 -0500
@@ -341,7 +341,7 @@ static void gfar_rx_offload_en(struct gf
 	if (priv->ndev->features & (NETIF_F_RXCSUM | NETIF_F_HW_VLAN_CTAG_RX))
 		priv->uses_rxfcb = 1;
 
-	if (priv->hwts_rx_en)
+	if (priv->hwts_rx_en || priv->rx_filer_enable)
 		priv->uses_rxfcb = 1;
 }
 
@@ -351,7 +351,7 @@ static void gfar_mac_rx_config(struct gf
 	u32 rctrl = 0;
 
 	if (priv->rx_filer_enable) {
-		rctrl |= RCTRL_FILREN;
+		rctrl |= RCTRL_FILREN | RCTRL_PRSDEP_INIT;
 		/* Program the RIR0 reg with the required distribution */
 		if (priv->poll_mode == GFAR_SQ_POLLING)
 			gfar_write(&regs->rir0, DEFAULT_2RXQ_RIR0);
@@ -3462,11 +3462,9 @@ static irqreturn_t gfar_error(int irq, v
 		netif_dbg(priv, tx_err, dev, "Transmit Error\n");
 	}
 	if (events & IEVENT_BSY) {
-		dev->stats.rx_errors++;
+		dev->stats.rx_over_errors++;
 		atomic64_inc(&priv->extra_stats.rx_bsy);
 
-		gfar_receive(irq, grp_id);
-
 		netif_dbg(priv, rx_err, dev, "busy error (rstat: %x)\n",
 			  gfar_read(&regs->rstat));
 	}
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/net/ethernet/freescale/gianfar_ethtool.c linux-libre-4.3-gnu/drivers/net/ethernet/freescale/gianfar_ethtool.c
--- linux-libre-4.3-rc7-gnu/drivers/net/ethernet/freescale/gianfar_ethtool.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/net/ethernet/freescale/gianfar_ethtool.c	2015-11-01 19:05:25.000000000 -0500
@@ -676,14 +676,14 @@ static void ethflow_to_filer_rules (stru
 	u32 fcr = 0x0, fpr = FPR_FILER_MASK;
 
 	if (ethflow & RXH_L2DA) {
-		fcr = RQFCR_PID_DAH |RQFCR_CMP_NOMATCH |
+		fcr = RQFCR_PID_DAH | RQFCR_CMP_NOMATCH |
 		      RQFCR_HASH | RQFCR_AND | RQFCR_HASHTBL_0;
 		priv->ftp_rqfpr[priv->cur_filer_idx] = fpr;
 		priv->ftp_rqfcr[priv->cur_filer_idx] = fcr;
 		gfar_write_filer(priv, priv->cur_filer_idx, fcr, fpr);
 		priv->cur_filer_idx = priv->cur_filer_idx - 1;
 
-		fcr = RQFCR_PID_DAL | RQFCR_AND | RQFCR_CMP_NOMATCH |
+		fcr = RQFCR_PID_DAL | RQFCR_CMP_NOMATCH |
 		      RQFCR_HASH | RQFCR_AND | RQFCR_HASHTBL_0;
 		priv->ftp_rqfpr[priv->cur_filer_idx] = fpr;
 		priv->ftp_rqfcr[priv->cur_filer_idx] = fcr;
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/net/ethernet/intel/i40e/i40e_ethtool.c linux-libre-4.3-gnu/drivers/net/ethernet/intel/i40e/i40e_ethtool.c
--- linux-libre-4.3-rc7-gnu/drivers/net/ethernet/intel/i40e/i40e_ethtool.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/net/ethernet/intel/i40e/i40e_ethtool.c	2015-11-01 19:05:25.000000000 -0500
@@ -1344,6 +1344,12 @@ static void i40e_get_ethtool_stats(struc
 			data[i++] = (i40e_gstrings_veb_stats[j].sizeof_stat ==
 				     sizeof(u64)) ? *(u64 *)p : *(u32 *)p;
 		}
+		for (j = 0; j < I40E_MAX_TRAFFIC_CLASS; j++) {
+			data[i++] = veb->tc_stats.tc_tx_packets[j];
+			data[i++] = veb->tc_stats.tc_tx_bytes[j];
+			data[i++] = veb->tc_stats.tc_rx_packets[j];
+			data[i++] = veb->tc_stats.tc_rx_bytes[j];
+		}
 	}
 	for (j = 0; j < I40E_GLOBAL_STATS_LEN; j++) {
 		p = (char *)pf + i40e_gstrings_stats[j].stat_offset;
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/net/ethernet/intel/i40e/i40e_main.c linux-libre-4.3-gnu/drivers/net/ethernet/intel/i40e/i40e_main.c
--- linux-libre-4.3-rc7-gnu/drivers/net/ethernet/intel/i40e/i40e_main.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/net/ethernet/intel/i40e/i40e_main.c	2015-11-01 19:05:25.000000000 -0500
@@ -7911,6 +7911,7 @@ static int i40e_sw_init(struct i40e_pf *
 	if (pf->hw.func_caps.vmdq) {
 		pf->num_vmdq_vsis = I40E_DEFAULT_NUM_VMDQ_VSI;
 		pf->flags |= I40E_FLAG_VMDQ_ENABLED;
+		pf->num_vmdq_qps = i40e_default_queues_per_vmdq(pf);
 	}
 
 #ifdef I40E_FCOE
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/net/ethernet/marvell/mv643xx_eth.c linux-libre-4.3-gnu/drivers/net/ethernet/marvell/mv643xx_eth.c
--- linux-libre-4.3-rc7-gnu/drivers/net/ethernet/marvell/mv643xx_eth.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/net/ethernet/marvell/mv643xx_eth.c	2015-11-01 19:05:25.000000000 -0500
@@ -759,11 +759,23 @@ txq_put_data_tso(struct net_device *dev,
 
 	desc->l4i_chk = 0;
 	desc->byte_cnt = length;
-	desc->buf_ptr = dma_map_single(dev->dev.parent, data,
-				       length, DMA_TO_DEVICE);
-	if (unlikely(dma_mapping_error(dev->dev.parent, desc->buf_ptr))) {
-		WARN(1, "dma_map_single failed!\n");
-		return -ENOMEM;
+
+	if (length <= 8 && (uintptr_t)data & 0x7) {
+		/* Copy unaligned small data fragment to TSO header data area */
+		memcpy(txq->tso_hdrs + txq->tx_curr_desc * TSO_HEADER_SIZE,
+		       data, length);
+		desc->buf_ptr = txq->tso_hdrs_dma
+			+ txq->tx_curr_desc * TSO_HEADER_SIZE;
+	} else {
+		/* Alignment is okay, map buffer and hand off to hardware */
+		txq->tx_desc_mapping[tx_index] = DESC_DMA_MAP_SINGLE;
+		desc->buf_ptr = dma_map_single(dev->dev.parent, data,
+			length, DMA_TO_DEVICE);
+		if (unlikely(dma_mapping_error(dev->dev.parent,
+					       desc->buf_ptr))) {
+			WARN(1, "dma_map_single failed!\n");
+			return -ENOMEM;
+		}
 	}
 
 	cmd_sts = BUFFER_OWNED_BY_DMA;
@@ -779,7 +791,8 @@ txq_put_data_tso(struct net_device *dev,
 }
 
 static inline void
-txq_put_hdr_tso(struct sk_buff *skb, struct tx_queue *txq, int length)
+txq_put_hdr_tso(struct sk_buff *skb, struct tx_queue *txq, int length,
+		u32 *first_cmd_sts, bool first_desc)
 {
 	struct mv643xx_eth_private *mp = txq_to_mp(txq);
 	int hdr_len = skb_transport_offset(skb) + tcp_hdrlen(skb);
@@ -788,6 +801,7 @@ txq_put_hdr_tso(struct sk_buff *skb, str
 	int ret;
 	u32 cmd_csum = 0;
 	u16 l4i_chk = 0;
+	u32 cmd_sts;
 
 	tx_index = txq->tx_curr_desc;
 	desc = &txq->tx_desc_area[tx_index];
@@ -803,9 +817,17 @@ txq_put_hdr_tso(struct sk_buff *skb, str
 	desc->byte_cnt = hdr_len;
 	desc->buf_ptr = txq->tso_hdrs_dma +
 			txq->tx_curr_desc * TSO_HEADER_SIZE;
-	desc->cmd_sts = cmd_csum | BUFFER_OWNED_BY_DMA  | TX_FIRST_DESC |
+	cmd_sts = cmd_csum | BUFFER_OWNED_BY_DMA  | TX_FIRST_DESC |
 				   GEN_CRC;
 
+	/* Defer updating the first command descriptor until all
+	 * following descriptors have been written.
+	 */
+	if (first_desc)
+		*first_cmd_sts = cmd_sts;
+	else
+		desc->cmd_sts = cmd_sts;
+
 	txq->tx_curr_desc++;
 	if (txq->tx_curr_desc == txq->tx_ring_size)
 		txq->tx_curr_desc = 0;
@@ -819,6 +841,8 @@ static int txq_submit_tso(struct tx_queu
 	int desc_count = 0;
 	struct tso_t tso;
 	int hdr_len = skb_transport_offset(skb) + tcp_hdrlen(skb);
+	struct tx_desc *first_tx_desc;
+	u32 first_cmd_sts = 0;
 
 	/* Count needed descriptors */
 	if ((txq->tx_desc_count + tso_count_descs(skb)) >= txq->tx_ring_size) {
@@ -826,11 +850,14 @@ static int txq_submit_tso(struct tx_queu
 		return -EBUSY;
 	}
 
+	first_tx_desc = &txq->tx_desc_area[txq->tx_curr_desc];
+
 	/* Initialize the TSO handler, and prepare the first payload */
 	tso_start(skb, &tso);
 
 	total_len = skb->len - hdr_len;
 	while (total_len > 0) {
+		bool first_desc = (desc_count == 0);
 		char *hdr;
 
 		data_left = min_t(int, skb_shinfo(skb)->gso_size, total_len);
@@ -840,7 +867,8 @@ static int txq_submit_tso(struct tx_queu
 		/* prepare packet headers: MAC + IP + TCP */
 		hdr = txq->tso_hdrs + txq->tx_curr_desc * TSO_HEADER_SIZE;
 		tso_build_hdr(skb, hdr, &tso, data_left, total_len == 0);
-		txq_put_hdr_tso(skb, txq, data_left);
+		txq_put_hdr_tso(skb, txq, data_left, &first_cmd_sts,
+				first_desc);
 
 		while (data_left > 0) {
 			int size;
@@ -860,6 +888,10 @@ static int txq_submit_tso(struct tx_queu
 	__skb_queue_tail(&txq->tx_skb, skb);
 	skb_tx_timestamp(skb);
 
+	/* ensure all other descriptors are written before first cmd_sts */
+	wmb();
+	first_tx_desc->cmd_sts = first_cmd_sts;
+
 	/* clear TX_END status */
 	mp->work_tx_end &= ~(1 << txq->index);
 
@@ -2785,8 +2817,10 @@ static int mv643xx_eth_shared_of_probe(s
 
 	for_each_available_child_of_node(np, pnp) {
 		ret = mv643xx_eth_shared_of_add_port(pdev, pnp);
-		if (ret)
+		if (ret) {
+			of_node_put(pnp);
 			return ret;
+		}
 	}
 	return 0;
 }
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/net/ethernet/mellanox/mlx4/cmd.c linux-libre-4.3-gnu/drivers/net/ethernet/mellanox/mlx4/cmd.c
--- linux-libre-4.3-rc7-gnu/drivers/net/ethernet/mellanox/mlx4/cmd.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/net/ethernet/mellanox/mlx4/cmd.c	2015-11-01 19:05:25.000000000 -0500
@@ -2398,7 +2398,7 @@ int mlx4_multi_func_init(struct mlx4_dev
 			}
 		}
 
-		memset(&priv->mfunc.master.cmd_eqe, 0, dev->caps.eqe_size);
+		memset(&priv->mfunc.master.cmd_eqe, 0, sizeof(struct mlx4_eqe));
 		priv->mfunc.master.cmd_eqe.type = MLX4_EVENT_TYPE_CMD;
 		INIT_WORK(&priv->mfunc.master.comm_work,
 			  mlx4_master_comm_channel);
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/net/ethernet/mellanox/mlx4/en_tx.c linux-libre-4.3-gnu/drivers/net/ethernet/mellanox/mlx4/en_tx.c
--- linux-libre-4.3-rc7-gnu/drivers/net/ethernet/mellanox/mlx4/en_tx.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/net/ethernet/mellanox/mlx4/en_tx.c	2015-11-01 19:05:25.000000000 -0500
@@ -964,6 +964,8 @@ netdev_tx_t mlx4_en_xmit(struct sk_buff
 			tx_desc->ctrl.ins_vlan = MLX4_WQE_CTRL_INS_SVLAN;
 		else if (vlan_proto == ETH_P_8021Q)
 			tx_desc->ctrl.ins_vlan = MLX4_WQE_CTRL_INS_CVLAN;
+		else
+			tx_desc->ctrl.ins_vlan = 0;
 
 		tx_desc->ctrl.fence_size = real_size;
 
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/net/ethernet/mellanox/mlx4/eq.c linux-libre-4.3-gnu/drivers/net/ethernet/mellanox/mlx4/eq.c
--- linux-libre-4.3-rc7-gnu/drivers/net/ethernet/mellanox/mlx4/eq.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/net/ethernet/mellanox/mlx4/eq.c	2015-11-01 19:05:25.000000000 -0500
@@ -196,7 +196,7 @@ static void slave_event(struct mlx4_dev
 		return;
 	}
 
-	memcpy(s_eqe, eqe, dev->caps.eqe_size - 1);
+	memcpy(s_eqe, eqe, sizeof(struct mlx4_eqe) - 1);
 	s_eqe->slave_id = slave;
 	/* ensure all information is written before setting the ownersip bit */
 	dma_wmb();
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/net/ethernet/nvidia/forcedeth.c linux-libre-4.3-gnu/drivers/net/ethernet/nvidia/forcedeth.c
--- linux-libre-4.3-rc7-gnu/drivers/net/ethernet/nvidia/forcedeth.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/net/ethernet/nvidia/forcedeth.c	2015-11-01 19:05:25.000000000 -0500
@@ -4076,6 +4076,8 @@ static void nv_do_nic_poll(unsigned long
 	struct fe_priv *np = netdev_priv(dev);
 	u8 __iomem *base = get_hwbase(dev);
 	u32 mask = 0;
+	unsigned long flags;
+	unsigned int irq = 0;
 
 	/*
 	 * First disable irq(s) and then
@@ -4085,25 +4087,27 @@ static void nv_do_nic_poll(unsigned long
 
 	if (!using_multi_irqs(dev)) {
 		if (np->msi_flags & NV_MSI_X_ENABLED)
-			disable_irq_lockdep(np->msi_x_entry[NV_MSI_X_VECTOR_ALL].vector);
+			irq = np->msi_x_entry[NV_MSI_X_VECTOR_ALL].vector;
 		else
-			disable_irq_lockdep(np->pci_dev->irq);
+			irq = np->pci_dev->irq;
 		mask = np->irqmask;
 	} else {
 		if (np->nic_poll_irq & NVREG_IRQ_RX_ALL) {
-			disable_irq_lockdep(np->msi_x_entry[NV_MSI_X_VECTOR_RX].vector);
+			irq = np->msi_x_entry[NV_MSI_X_VECTOR_RX].vector;
 			mask |= NVREG_IRQ_RX_ALL;
 		}
 		if (np->nic_poll_irq & NVREG_IRQ_TX_ALL) {
-			disable_irq_lockdep(np->msi_x_entry[NV_MSI_X_VECTOR_TX].vector);
+			irq = np->msi_x_entry[NV_MSI_X_VECTOR_TX].vector;
 			mask |= NVREG_IRQ_TX_ALL;
 		}
 		if (np->nic_poll_irq & NVREG_IRQ_OTHER) {
-			disable_irq_lockdep(np->msi_x_entry[NV_MSI_X_VECTOR_OTHER].vector);
+			irq = np->msi_x_entry[NV_MSI_X_VECTOR_OTHER].vector;
 			mask |= NVREG_IRQ_OTHER;
 		}
 	}
-	/* disable_irq() contains synchronize_irq, thus no irq handler can run now */
+
+	disable_irq_nosync_lockdep_irqsave(irq, &flags);
+	synchronize_irq(irq);
 
 	if (np->recover_error) {
 		np->recover_error = 0;
@@ -4156,28 +4160,22 @@ static void nv_do_nic_poll(unsigned long
 			nv_nic_irq_optimized(0, dev);
 		else
 			nv_nic_irq(0, dev);
-		if (np->msi_flags & NV_MSI_X_ENABLED)
-			enable_irq_lockdep(np->msi_x_entry[NV_MSI_X_VECTOR_ALL].vector);
-		else
-			enable_irq_lockdep(np->pci_dev->irq);
 	} else {
 		if (np->nic_poll_irq & NVREG_IRQ_RX_ALL) {
 			np->nic_poll_irq &= ~NVREG_IRQ_RX_ALL;
 			nv_nic_irq_rx(0, dev);
-			enable_irq_lockdep(np->msi_x_entry[NV_MSI_X_VECTOR_RX].vector);
 		}
 		if (np->nic_poll_irq & NVREG_IRQ_TX_ALL) {
 			np->nic_poll_irq &= ~NVREG_IRQ_TX_ALL;
 			nv_nic_irq_tx(0, dev);
-			enable_irq_lockdep(np->msi_x_entry[NV_MSI_X_VECTOR_TX].vector);
 		}
 		if (np->nic_poll_irq & NVREG_IRQ_OTHER) {
 			np->nic_poll_irq &= ~NVREG_IRQ_OTHER;
 			nv_nic_irq_other(0, dev);
-			enable_irq_lockdep(np->msi_x_entry[NV_MSI_X_VECTOR_OTHER].vector);
 		}
 	}
 
+	enable_irq_lockdep_irqrestore(irq, &flags);
 }
 
 #ifdef CONFIG_NET_POLL_CONTROLLER
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/net/ethernet/renesas/sh_eth.c linux-libre-4.3-gnu/drivers/net/ethernet/renesas/sh_eth.c
--- linux-libre-4.3-rc7-gnu/drivers/net/ethernet/renesas/sh_eth.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/net/ethernet/renesas/sh_eth.c	2015-11-01 19:05:25.000000000 -0500
@@ -1127,7 +1127,7 @@ static void sh_eth_ring_format(struct ne
 	struct sh_eth_txdesc *txdesc = NULL;
 	int rx_ringsize = sizeof(*rxdesc) * mdp->num_rx_ring;
 	int tx_ringsize = sizeof(*txdesc) * mdp->num_tx_ring;
-	int skbuff_size = mdp->rx_buf_sz + SH_ETH_RX_ALIGN - 1;
+	int skbuff_size = mdp->rx_buf_sz + SH_ETH_RX_ALIGN + 32 - 1;
 	dma_addr_t dma_addr;
 
 	mdp->cur_rx = 0;
@@ -1148,8 +1148,8 @@ static void sh_eth_ring_format(struct ne
 
 		/* RX descriptor */
 		rxdesc = &mdp->rx_ring[i];
-		/* The size of the buffer is a multiple of 16 bytes. */
-		rxdesc->buffer_length = ALIGN(mdp->rx_buf_sz, 16);
+		/* The size of the buffer is a multiple of 32 bytes. */
+		rxdesc->buffer_length = ALIGN(mdp->rx_buf_sz, 32);
 		dma_addr = dma_map_single(&ndev->dev, skb->data,
 					  rxdesc->buffer_length,
 					  DMA_FROM_DEVICE);
@@ -1450,7 +1450,7 @@ static int sh_eth_rx(struct net_device *
 	struct sk_buff *skb;
 	u16 pkt_len = 0;
 	u32 desc_status;
-	int skbuff_size = mdp->rx_buf_sz + SH_ETH_RX_ALIGN - 1;
+	int skbuff_size = mdp->rx_buf_sz + SH_ETH_RX_ALIGN + 32 - 1;
 	dma_addr_t dma_addr;
 
 	boguscnt = min(boguscnt, *quota);
@@ -1506,7 +1506,7 @@ static int sh_eth_rx(struct net_device *
 			if (mdp->cd->rpadir)
 				skb_reserve(skb, NET_IP_ALIGN);
 			dma_unmap_single(&ndev->dev, rxdesc->addr,
-					 ALIGN(mdp->rx_buf_sz, 16),
+					 ALIGN(mdp->rx_buf_sz, 32),
 					 DMA_FROM_DEVICE);
 			skb_put(skb, pkt_len);
 			skb->protocol = eth_type_trans(skb, ndev);
@@ -1524,8 +1524,8 @@ static int sh_eth_rx(struct net_device *
 	for (; mdp->cur_rx - mdp->dirty_rx > 0; mdp->dirty_rx++) {
 		entry = mdp->dirty_rx % mdp->num_rx_ring;
 		rxdesc = &mdp->rx_ring[entry];
-		/* The size of the buffer is 16 byte boundary. */
-		rxdesc->buffer_length = ALIGN(mdp->rx_buf_sz, 16);
+		/* The size of the buffer is 32 byte boundary. */
+		rxdesc->buffer_length = ALIGN(mdp->rx_buf_sz, 32);
 
 		if (mdp->rx_skbuff[entry] == NULL) {
 			skb = netdev_alloc_skb(ndev, skbuff_size);
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/net/ethernet/ti/cpsw.c linux-libre-4.3-gnu/drivers/net/ethernet/ti/cpsw.c
--- linux-libre-4.3-rc7-gnu/drivers/net/ethernet/ti/cpsw.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/net/ethernet/ti/cpsw.c	2015-11-01 19:05:25.000000000 -0500
@@ -30,6 +30,7 @@
 #include <linux/delay.h>
 #include <linux/pm_runtime.h>
 #include <linux/of.h>
+#include <linux/of_mdio.h>
 #include <linux/of_net.h>
 #include <linux/of_device.h>
 #include <linux/if_vlan.h>
@@ -365,6 +366,7 @@ struct cpsw_priv {
 	spinlock_t			lock;
 	struct platform_device		*pdev;
 	struct net_device		*ndev;
+	struct device_node		*phy_node;
 	struct napi_struct		napi_rx;
 	struct napi_struct		napi_tx;
 	struct device			*dev;
@@ -1145,7 +1147,11 @@ static void cpsw_slave_open(struct cpsw_
 		cpsw_ale_add_mcast(priv->ale, priv->ndev->broadcast,
 				   1 << slave_port, 0, 0, ALE_MCAST_FWD_2);
 
-	slave->phy = phy_connect(priv->ndev, slave->data->phy_id,
+	if (priv->phy_node)
+		slave->phy = of_phy_connect(priv->ndev, priv->phy_node,
+				 &cpsw_adjust_link, 0, slave->data->phy_if);
+	else
+		slave->phy = phy_connect(priv->ndev, slave->data->phy_id,
 				 &cpsw_adjust_link, slave->data->phy_if);
 	if (IS_ERR(slave->phy)) {
 		dev_err(priv->dev, "phy %s not found on slave %d\n",
@@ -1934,11 +1940,12 @@ static void cpsw_slave_init(struct cpsw_
 	slave->port_vlan = data->dual_emac_res_vlan;
 }
 
-static int cpsw_probe_dt(struct cpsw_platform_data *data,
+static int cpsw_probe_dt(struct cpsw_priv *priv,
 			 struct platform_device *pdev)
 {
 	struct device_node *node = pdev->dev.of_node;
 	struct device_node *slave_node;
+	struct cpsw_platform_data *data = &priv->data;
 	int i = 0, ret;
 	u32 prop;
 
@@ -2029,6 +2036,7 @@ static int cpsw_probe_dt(struct cpsw_pla
 		if (strcmp(slave_node->name, "slave"))
 			continue;
 
+		priv->phy_node = of_parse_phandle(slave_node, "phy-handle", 0);
 		parp = of_get_property(slave_node, "phy_id", &lenp);
 		if ((parp == NULL) || (lenp != (sizeof(void *) * 2))) {
 			dev_err(&pdev->dev, "Missing slave[%d] phy_id property\n", i);
@@ -2044,7 +2052,6 @@ static int cpsw_probe_dt(struct cpsw_pla
 		}
 		snprintf(slave_data->phy_id, sizeof(slave_data->phy_id),
 			 PHY_ID_FMT, mdio->name, phyid);
-
 		slave_data->phy_if = of_get_phy_mode(slave_node);
 		if (slave_data->phy_if < 0) {
 			dev_err(&pdev->dev, "Missing or malformed slave[%d] phy-mode property\n",
@@ -2240,7 +2247,7 @@ static int cpsw_probe(struct platform_de
 	/* Select default pin state */
 	pinctrl_pm_select_default_state(&pdev->dev);
 
-	if (cpsw_probe_dt(&priv->data, pdev)) {
+	if (cpsw_probe_dt(priv, pdev)) {
 		dev_err(&pdev->dev, "cpsw: platform data missing\n");
 		ret = -ENODEV;
 		goto clean_runtime_disable_ret;
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/net/ethernet/ti/netcp_ethss.c linux-libre-4.3-gnu/drivers/net/ethernet/ti/netcp_ethss.c
--- linux-libre-4.3-rc7-gnu/drivers/net/ethernet/ti/netcp_ethss.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/net/ethernet/ti/netcp_ethss.c	2015-11-01 19:05:25.000000000 -0500
@@ -2637,8 +2637,10 @@ static void init_secondary_ports(struct
 			mac_phy_link = true;
 
 		slave->open = true;
-		if (gbe_dev->num_slaves >= gbe_dev->max_num_slaves)
+		if (gbe_dev->num_slaves >= gbe_dev->max_num_slaves) {
+			of_node_put(port);
 			break;
+		}
 	}
 
 	/* of_phy_connect() is needed only for MAC-PHY interface */
@@ -3137,8 +3139,10 @@ static int gbe_probe(struct netcp_device
 			continue;
 		}
 		gbe_dev->num_slaves++;
-		if (gbe_dev->num_slaves >= gbe_dev->max_num_slaves)
+		if (gbe_dev->num_slaves >= gbe_dev->max_num_slaves) {
+			of_node_put(interface);
 			break;
+		}
 	}
 	of_node_put(interfaces);
 
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/net/geneve.c linux-libre-4.3-gnu/drivers/net/geneve.c
--- linux-libre-4.3-rc7-gnu/drivers/net/geneve.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/net/geneve.c	2015-11-01 19:05:25.000000000 -0500
@@ -594,14 +594,12 @@ static struct rtable *geneve_get_rt(stru
 	rt = ip_route_output_key(geneve->net, fl4);
 	if (IS_ERR(rt)) {
 		netdev_dbg(dev, "no route to %pI4\n", &fl4->daddr);
-		dev->stats.tx_carrier_errors++;
-		return rt;
+		return ERR_PTR(-ENETUNREACH);
 	}
 	if (rt->dst.dev == dev) { /* is this necessary? */
 		netdev_dbg(dev, "circular route to %pI4\n", &fl4->daddr);
-		dev->stats.collisions++;
 		ip_rt_put(rt);
-		return ERR_PTR(-EINVAL);
+		return ERR_PTR(-ELOOP);
 	}
 	return rt;
 }
@@ -627,12 +625,12 @@ static netdev_tx_t geneve_xmit(struct sk
 	struct ip_tunnel_info *info = NULL;
 	struct rtable *rt = NULL;
 	const struct iphdr *iip; /* interior IP header */
+	int err = -EINVAL;
 	struct flowi4 fl4;
 	__u8 tos, ttl;
 	__be16 sport;
 	bool udp_csum;
 	__be16 df;
-	int err;
 
 	if (geneve->collect_md) {
 		info = skb_tunnel_info(skb);
@@ -647,7 +645,7 @@ static netdev_tx_t geneve_xmit(struct sk
 	rt = geneve_get_rt(skb, dev, &fl4, info);
 	if (IS_ERR(rt)) {
 		netdev_dbg(dev, "no route to %pI4\n", &fl4.daddr);
-		dev->stats.tx_carrier_errors++;
+		err = PTR_ERR(rt);
 		goto tx_error;
 	}
 
@@ -699,10 +697,37 @@ static netdev_tx_t geneve_xmit(struct sk
 tx_error:
 	dev_kfree_skb(skb);
 err:
-	dev->stats.tx_errors++;
+	if (err == -ELOOP)
+		dev->stats.collisions++;
+	else if (err == -ENETUNREACH)
+		dev->stats.tx_carrier_errors++;
+	else
+		dev->stats.tx_errors++;
 	return NETDEV_TX_OK;
 }
 
+static int geneve_fill_metadata_dst(struct net_device *dev, struct sk_buff *skb)
+{
+	struct ip_tunnel_info *info = skb_tunnel_info(skb);
+	struct geneve_dev *geneve = netdev_priv(dev);
+	struct rtable *rt;
+	struct flowi4 fl4;
+
+	if (ip_tunnel_info_af(info) != AF_INET)
+		return -EINVAL;
+
+	rt = geneve_get_rt(skb, dev, &fl4, info);
+	if (IS_ERR(rt))
+		return PTR_ERR(rt);
+
+	ip_rt_put(rt);
+	info->key.u.ipv4.src = fl4.saddr;
+	info->key.tp_src = udp_flow_src_port(geneve->net, skb,
+					     1, USHRT_MAX, true);
+	info->key.tp_dst = geneve->dst_port;
+	return 0;
+}
+
 static const struct net_device_ops geneve_netdev_ops = {
 	.ndo_init		= geneve_init,
 	.ndo_uninit		= geneve_uninit,
@@ -713,6 +738,7 @@ static const struct net_device_ops genev
 	.ndo_change_mtu		= eth_change_mtu,
 	.ndo_validate_addr	= eth_validate_addr,
 	.ndo_set_mac_address	= eth_mac_addr,
+	.ndo_fill_metadata_dst	= geneve_fill_metadata_dst,
 };
 
 static void geneve_get_drvinfo(struct net_device *dev,
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/net/macvtap.c linux-libre-4.3-gnu/drivers/net/macvtap.c
--- linux-libre-4.3-rc7-gnu/drivers/net/macvtap.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/net/macvtap.c	2015-11-01 19:05:25.000000000 -0500
@@ -137,7 +137,7 @@ static const struct proto_ops macvtap_so
 #define TUN_OFFLOADS (NETIF_F_HW_CSUM | NETIF_F_TSO_ECN | NETIF_F_TSO | \
 		      NETIF_F_TSO6 | NETIF_F_UFO)
 #define RX_OFFLOADS (NETIF_F_GRO | NETIF_F_LRO)
-#define TAP_FEATURES (NETIF_F_GSO | NETIF_F_SG)
+#define TAP_FEATURES (NETIF_F_GSO | NETIF_F_SG | NETIF_F_FRAGLIST)
 
 static struct macvlan_dev *macvtap_get_vlan_rcu(const struct net_device *dev)
 {
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/net/phy/dp83848.c linux-libre-4.3-gnu/drivers/net/phy/dp83848.c
--- linux-libre-4.3-rc7-gnu/drivers/net/phy/dp83848.c	1969-12-31 19:00:00.000000000 -0500
+++ linux-libre-4.3-gnu/drivers/net/phy/dp83848.c	2015-11-01 19:05:25.000000000 -0500
@@ -0,0 +1,99 @@
+/*
+ * Driver for the Texas Instruments DP83848 PHY
+ *
+ * Copyright (C) 2015 Texas Instruments Inc.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ */
+
+#include <linux/module.h>
+#include <linux/phy.h>
+
+#define DP83848_PHY_ID			0x20005c90
+
+/* Registers */
+#define DP83848_MICR			0x11
+#define DP83848_MISR			0x12
+
+/* MICR Register Fields */
+#define DP83848_MICR_INT_OE		BIT(0) /* Interrupt Output Enable */
+#define DP83848_MICR_INTEN		BIT(1) /* Interrupt Enable */
+
+/* MISR Register Fields */
+#define DP83848_MISR_RHF_INT_EN		BIT(0) /* Receive Error Counter */
+#define DP83848_MISR_FHF_INT_EN		BIT(1) /* False Carrier Counter */
+#define DP83848_MISR_ANC_INT_EN		BIT(2) /* Auto-negotiation complete */
+#define DP83848_MISR_DUP_INT_EN		BIT(3) /* Duplex Status */
+#define DP83848_MISR_SPD_INT_EN		BIT(4) /* Speed status */
+#define DP83848_MISR_LINK_INT_EN	BIT(5) /* Link status */
+#define DP83848_MISR_ED_INT_EN		BIT(6) /* Energy detect */
+#define DP83848_MISR_LQM_INT_EN		BIT(7) /* Link Quality Monitor */
+
+static int dp83848_ack_interrupt(struct phy_device *phydev)
+{
+	int err = phy_read(phydev, DP83848_MISR);
+
+	return err < 0 ? err : 0;
+}
+
+static int dp83848_config_intr(struct phy_device *phydev)
+{
+	int err;
+
+	if (phydev->interrupts == PHY_INTERRUPT_ENABLED) {
+		err = phy_write(phydev, DP83848_MICR,
+				DP83848_MICR_INT_OE |
+				DP83848_MICR_INTEN);
+		if (err < 0)
+			return err;
+
+		return phy_write(phydev, DP83848_MISR,
+				 DP83848_MISR_ANC_INT_EN |
+				 DP83848_MISR_DUP_INT_EN |
+				 DP83848_MISR_SPD_INT_EN |
+				 DP83848_MISR_LINK_INT_EN);
+	}
+
+	return phy_write(phydev, DP83848_MICR, 0x0);
+}
+
+static struct mdio_device_id __maybe_unused dp83848_tbl[] = {
+	{ DP83848_PHY_ID, 0xfffffff0 },
+	{ }
+};
+MODULE_DEVICE_TABLE(mdio, dp83848_tbl);
+
+static struct phy_driver dp83848_driver[] = {
+	{
+		.phy_id		= DP83848_PHY_ID,
+		.phy_id_mask	= 0xfffffff0,
+		.name		= "TI DP83848",
+		.features	= PHY_BASIC_FEATURES,
+		.flags		= PHY_HAS_INTERRUPT,
+
+		.soft_reset	= genphy_soft_reset,
+		.config_init	= genphy_config_init,
+		.suspend	= genphy_suspend,
+		.resume		= genphy_resume,
+		.config_aneg	= genphy_config_aneg,
+		.read_status	= genphy_read_status,
+
+		/* IRQ related */
+		.ack_interrupt	= dp83848_ack_interrupt,
+		.config_intr	= dp83848_config_intr,
+
+		.driver		= { .owner = THIS_MODULE, },
+	},
+};
+module_phy_driver(dp83848_driver);
+
+MODULE_DESCRIPTION("Texas Instruments DP83848 PHY driver");
+MODULE_AUTHOR("Andrew F. Davis <afd@ti.com");
+MODULE_LICENSE("GPL");
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/net/phy/Kconfig linux-libre-4.3-gnu/drivers/net/phy/Kconfig
--- linux-libre-4.3-rc7-gnu/drivers/net/phy/Kconfig	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/net/phy/Kconfig	2015-11-01 19:05:25.000000000 -0500
@@ -122,6 +122,11 @@ config MICREL_PHY
 	---help---
 	  Supports the KSZ9021, VSC8201, KS8001 PHYs.
 
+config DP83848_PHY
+	tristate "Driver for Texas Instruments DP83848 PHY"
+	---help---
+	  Supports the DP83848 PHY.
+
 config DP83867_PHY
 	tristate "Drivers for Texas Instruments DP83867 Gigabit PHY"
 	---help---
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/net/phy/Makefile linux-libre-4.3-gnu/drivers/net/phy/Makefile
--- linux-libre-4.3-rc7-gnu/drivers/net/phy/Makefile	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/net/phy/Makefile	2015-11-01 19:05:25.000000000 -0500
@@ -24,6 +24,7 @@ obj-$(CONFIG_MDIO_BITBANG)	+= mdio-bitba
 obj-$(CONFIG_MDIO_GPIO)		+= mdio-gpio.o
 obj-$(CONFIG_NATIONAL_PHY)	+= national.o
 obj-$(CONFIG_DP83640_PHY)	+= dp83640.o
+obj-$(CONFIG_DP83848_PHY)	+= dp83848.o
 obj-$(CONFIG_DP83867_PHY)	+= dp83867.o
 obj-$(CONFIG_STE10XP)		+= ste10Xp.o
 obj-$(CONFIG_MICREL_PHY)	+= micrel.o
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/net/phy/mdio-mux.c linux-libre-4.3-gnu/drivers/net/phy/mdio-mux.c
--- linux-libre-4.3-rc7-gnu/drivers/net/phy/mdio-mux.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/net/phy/mdio-mux.c	2015-11-01 19:05:25.000000000 -0500
@@ -144,6 +144,7 @@ int mdio_mux_init(struct device *dev,
 			dev_err(dev,
 				"Error: Failed to allocate memory for child\n");
 			ret_val = -ENOMEM;
+			of_node_put(child_bus_node);
 			break;
 		}
 		cb->bus_number = v;
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/net/phy/mdio-mux-mmioreg.c linux-libre-4.3-gnu/drivers/net/phy/mdio-mux-mmioreg.c
--- linux-libre-4.3-rc7-gnu/drivers/net/phy/mdio-mux-mmioreg.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/net/phy/mdio-mux-mmioreg.c	2015-11-01 19:05:25.000000000 -0500
@@ -113,12 +113,14 @@ static int mdio_mux_mmioreg_probe(struct
 		if (!iprop || len != sizeof(uint32_t)) {
 			dev_err(&pdev->dev, "mdio-mux child node %s is "
 				"missing a 'reg' property\n", np2->full_name);
+			of_node_put(np2);
 			return -ENODEV;
 		}
 		if (be32_to_cpup(iprop) & ~s->mask) {
 			dev_err(&pdev->dev, "mdio-mux child node %s has "
 				"a 'reg' value with unmasked bits\n",
 				np2->full_name);
+			of_node_put(np2);
 			return -ENODEV;
 		}
 	}
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/net/phy/micrel.c linux-libre-4.3-gnu/drivers/net/phy/micrel.c
--- linux-libre-4.3-rc7-gnu/drivers/net/phy/micrel.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/net/phy/micrel.c	2015-11-01 19:05:25.000000000 -0500
@@ -514,6 +514,27 @@ static int ksz8873mll_read_status(struct
 	return 0;
 }
 
+static int ksz9031_read_status(struct phy_device *phydev)
+{
+	int err;
+	int regval;
+
+	err = genphy_read_status(phydev);
+	if (err)
+		return err;
+
+	/* Make sure the PHY is not broken. Read idle error count,
+	 * and reset the PHY if it is maxed out.
+	 */
+	regval = phy_read(phydev, MII_STAT1000);
+	if ((regval & 0xFF) == 0xFF) {
+		phy_init_hw(phydev);
+		phydev->link = 0;
+	}
+
+	return 0;
+}
+
 static int ksz8873mll_config_aneg(struct phy_device *phydev)
 {
 	return 0;
@@ -772,7 +793,7 @@ static struct phy_driver ksphy_driver[]
 	.driver_data	= &ksz9021_type,
 	.config_init	= ksz9031_config_init,
 	.config_aneg	= genphy_config_aneg,
-	.read_status	= genphy_read_status,
+	.read_status	= ksz9031_read_status,
 	.ack_interrupt	= kszphy_ack_interrupt,
 	.config_intr	= kszphy_config_intr,
 	.suspend	= genphy_suspend,
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/net/phy/smsc.c linux-libre-4.3-gnu/drivers/net/phy/smsc.c
--- linux-libre-4.3-rc7-gnu/drivers/net/phy/smsc.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/net/phy/smsc.c	2015-11-01 19:05:25.000000000 -0500
@@ -43,16 +43,25 @@ static int smsc_phy_ack_interrupt(struct
 
 static int smsc_phy_config_init(struct phy_device *phydev)
 {
+	int __maybe_unused len;
+	struct device *dev __maybe_unused = &phydev->dev;
+	struct device_node *of_node __maybe_unused = dev->of_node;
 	int rc = phy_read(phydev, MII_LAN83C185_CTRL_STATUS);
+	int enable_energy = 1;
 
 	if (rc < 0)
 		return rc;
 
-	/* Enable energy detect mode for this SMSC Transceivers */
-	rc = phy_write(phydev, MII_LAN83C185_CTRL_STATUS,
-		       rc | MII_LAN83C185_EDPWRDOWN);
-	if (rc < 0)
-		return rc;
+	if (of_find_property(of_node, "smsc,disable-energy-detect", &len))
+		enable_energy = 0;
+
+	if (enable_energy) {
+		/* Enable energy detect mode for this SMSC Transceivers */
+		rc = phy_write(phydev, MII_LAN83C185_CTRL_STATUS,
+			       rc | MII_LAN83C185_EDPWRDOWN);
+		if (rc < 0)
+			return rc;
+	}
 
 	return smsc_phy_ack_interrupt(phydev);
 }
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/net/ppp/pppoe.c linux-libre-4.3-gnu/drivers/net/ppp/pppoe.c
--- linux-libre-4.3-rc7-gnu/drivers/net/ppp/pppoe.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/net/ppp/pppoe.c	2015-11-01 19:05:25.000000000 -0500
@@ -589,7 +589,7 @@ static int pppoe_release(struct socket *
 
 	po = pppox_sk(sk);
 
-	if (sk->sk_state & (PPPOX_CONNECTED | PPPOX_BOUND | PPPOX_ZOMBIE)) {
+	if (po->pppoe_dev) {
 		dev_put(po->pppoe_dev);
 		po->pppoe_dev = NULL;
 	}
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/net/usb/qmi_wwan.c linux-libre-4.3-gnu/drivers/net/usb/qmi_wwan.c
--- linux-libre-4.3-rc7-gnu/drivers/net/usb/qmi_wwan.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/net/usb/qmi_wwan.c	2015-11-01 19:05:25.000000000 -0500
@@ -765,6 +765,10 @@ static const struct usb_device_id produc
 	{QMI_FIXED_INTF(0x1199, 0x9056, 8)},	/* Sierra Wireless Modem */
 	{QMI_FIXED_INTF(0x1199, 0x9057, 8)},
 	{QMI_FIXED_INTF(0x1199, 0x9061, 8)},	/* Sierra Wireless Modem */
+	{QMI_FIXED_INTF(0x1199, 0x9070, 8)},	/* Sierra Wireless MC74xx/EM74xx */
+	{QMI_FIXED_INTF(0x1199, 0x9070, 10)},	/* Sierra Wireless MC74xx/EM74xx */
+	{QMI_FIXED_INTF(0x1199, 0x9071, 8)},	/* Sierra Wireless MC74xx/EM74xx */
+	{QMI_FIXED_INTF(0x1199, 0x9071, 10)},	/* Sierra Wireless MC74xx/EM74xx */
 	{QMI_FIXED_INTF(0x1bbb, 0x011e, 4)},	/* Telekom Speedstick LTE II (Alcatel One Touch L100V LTE) */
 	{QMI_FIXED_INTF(0x1bbb, 0x0203, 2)},	/* Alcatel L800MA */
 	{QMI_FIXED_INTF(0x2357, 0x0201, 4)},	/* TP-LINK HSUPA Modem MA180 */
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/net/vxlan.c linux-libre-4.3-gnu/drivers/net/vxlan.c
--- linux-libre-4.3-rc7-gnu/drivers/net/vxlan.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/net/vxlan.c	2015-11-01 19:05:25.000000000 -0500
@@ -2337,6 +2337,46 @@ static int vxlan_change_mtu(struct net_d
 	return 0;
 }
 
+static int egress_ipv4_tun_info(struct net_device *dev, struct sk_buff *skb,
+				struct ip_tunnel_info *info,
+				__be16 sport, __be16 dport)
+{
+	struct vxlan_dev *vxlan = netdev_priv(dev);
+	struct rtable *rt;
+	struct flowi4 fl4;
+
+	memset(&fl4, 0, sizeof(fl4));
+	fl4.flowi4_tos = RT_TOS(info->key.tos);
+	fl4.flowi4_mark = skb->mark;
+	fl4.flowi4_proto = IPPROTO_UDP;
+	fl4.daddr = info->key.u.ipv4.dst;
+
+	rt = ip_route_output_key(vxlan->net, &fl4);
+	if (IS_ERR(rt))
+		return PTR_ERR(rt);
+	ip_rt_put(rt);
+
+	info->key.u.ipv4.src = fl4.saddr;
+	info->key.tp_src = sport;
+	info->key.tp_dst = dport;
+	return 0;
+}
+
+static int vxlan_fill_metadata_dst(struct net_device *dev, struct sk_buff *skb)
+{
+	struct vxlan_dev *vxlan = netdev_priv(dev);
+	struct ip_tunnel_info *info = skb_tunnel_info(skb);
+	__be16 sport, dport;
+
+	sport = udp_flow_src_port(dev_net(dev), skb, vxlan->cfg.port_min,
+				  vxlan->cfg.port_max, true);
+	dport = info->key.tp_dst ? : vxlan->cfg.dst_port;
+
+	if (ip_tunnel_info_af(info) == AF_INET)
+		return egress_ipv4_tun_info(dev, skb, info, sport, dport);
+	return -EINVAL;
+}
+
 static const struct net_device_ops vxlan_netdev_ops = {
 	.ndo_init		= vxlan_init,
 	.ndo_uninit		= vxlan_uninit,
@@ -2351,6 +2391,7 @@ static const struct net_device_ops vxlan
 	.ndo_fdb_add		= vxlan_fdb_add,
 	.ndo_fdb_del		= vxlan_fdb_delete,
 	.ndo_fdb_dump		= vxlan_fdb_dump,
+	.ndo_fill_metadata_dst	= vxlan_fill_metadata_dst,
 };
 
 /* Info for udev, that this is a virtual tunnel endpoint */
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/net/wireless/ath/ath6kl/init.c linux-libre-4.3-gnu/drivers/net/wireless/ath/ath6kl/init.c
--- linux-libre-4.3-rc7-gnu/drivers/net/wireless/ath/ath6kl/init.c	2015-11-01 03:28:54.000000000 -0500
+++ linux-libre-4.3-gnu/drivers/net/wireless/ath/ath6kl/init.c	2015-11-01 23:35:36.000000000 -0500
@@ -712,6 +712,7 @@ static bool check_device_tree(struct ath
 				   board_filename, ret);
 			continue;
 		}
+		of_node_put(node);
 		return true;
 	}
 	return false;
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/net/xen-netfront.c linux-libre-4.3-gnu/drivers/net/xen-netfront.c
--- linux-libre-4.3-rc7-gnu/drivers/net/xen-netfront.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/net/xen-netfront.c	2015-11-01 19:05:25.000000000 -0500
@@ -1706,19 +1706,19 @@ static void xennet_destroy_queues(struct
 }
 
 static int xennet_create_queues(struct netfront_info *info,
-				unsigned int num_queues)
+				unsigned int *num_queues)
 {
 	unsigned int i;
 	int ret;
 
-	info->queues = kcalloc(num_queues, sizeof(struct netfront_queue),
+	info->queues = kcalloc(*num_queues, sizeof(struct netfront_queue),
 			       GFP_KERNEL);
 	if (!info->queues)
 		return -ENOMEM;
 
 	rtnl_lock();
 
-	for (i = 0; i < num_queues; i++) {
+	for (i = 0; i < *num_queues; i++) {
 		struct netfront_queue *queue = &info->queues[i];
 
 		queue->id = i;
@@ -1728,7 +1728,7 @@ static int xennet_create_queues(struct n
 		if (ret < 0) {
 			dev_warn(&info->netdev->dev,
 				 "only created %d queues\n", i);
-			num_queues = i;
+			*num_queues = i;
 			break;
 		}
 
@@ -1738,11 +1738,11 @@ static int xennet_create_queues(struct n
 			napi_enable(&queue->napi);
 	}
 
-	netif_set_real_num_tx_queues(info->netdev, num_queues);
+	netif_set_real_num_tx_queues(info->netdev, *num_queues);
 
 	rtnl_unlock();
 
-	if (num_queues == 0) {
+	if (*num_queues == 0) {
 		dev_err(&info->netdev->dev, "no queues\n");
 		return -EINVAL;
 	}
@@ -1788,7 +1788,7 @@ static int talk_to_netback(struct xenbus
 	if (info->queues)
 		xennet_destroy_queues(info);
 
-	err = xennet_create_queues(info, num_queues);
+	err = xennet_create_queues(info, &num_queues);
 	if (err < 0)
 		goto destroy_ring;
 
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/pci/pci-sysfs.c linux-libre-4.3-gnu/drivers/pci/pci-sysfs.c
--- linux-libre-4.3-rc7-gnu/drivers/pci/pci-sysfs.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/pci/pci-sysfs.c	2015-11-01 19:05:25.000000000 -0500
@@ -216,7 +216,7 @@ static ssize_t numa_node_store(struct de
 	if (ret)
 		return ret;
 
-	if (!node_online(node))
+	if (node >= MAX_NUMNODES || !node_online(node))
 		return -EINVAL;
 
 	add_taint(TAINT_FIRMWARE_WORKAROUND, LOCKDEP_STILL_OK);
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/scsi/mvsas/mv_sas.c linux-libre-4.3-gnu/drivers/scsi/mvsas/mv_sas.c
--- linux-libre-4.3-rc7-gnu/drivers/scsi/mvsas/mv_sas.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/scsi/mvsas/mv_sas.c	2015-11-01 19:05:25.000000000 -0500
@@ -887,6 +887,8 @@ static void mvs_slot_free(struct mvs_inf
 static void mvs_slot_task_free(struct mvs_info *mvi, struct sas_task *task,
 			  struct mvs_slot_info *slot, u32 slot_idx)
 {
+	if (!slot)
+		return;
 	if (!slot->task)
 		return;
 	if (!sas_protocol_ata(task->task_proto))
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/scsi/scsi_dh.c linux-libre-4.3-gnu/drivers/scsi/scsi_dh.c
--- linux-libre-4.3-rc7-gnu/drivers/scsi/scsi_dh.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/scsi/scsi_dh.c	2015-11-01 19:05:25.000000000 -0500
@@ -226,16 +226,20 @@ int scsi_dh_add_device(struct scsi_devic
 
 	drv = scsi_dh_find_driver(sdev);
 	if (drv)
-		devinfo = scsi_dh_lookup(drv);
+		devinfo = __scsi_dh_lookup(drv);
 	if (devinfo)
 		err = scsi_dh_handler_attach(sdev, devinfo);
 	return err;
 }
 
-void scsi_dh_remove_device(struct scsi_device *sdev)
+void scsi_dh_release_device(struct scsi_device *sdev)
 {
 	if (sdev->handler)
 		scsi_dh_handler_detach(sdev);
+}
+
+void scsi_dh_remove_device(struct scsi_device *sdev)
+{
 	device_remove_file(&sdev->sdev_gendev, &scsi_dh_state_attr);
 }
 
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/scsi/scsi_priv.h linux-libre-4.3-gnu/drivers/scsi/scsi_priv.h
--- linux-libre-4.3-rc7-gnu/drivers/scsi/scsi_priv.h	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/scsi/scsi_priv.h	2015-11-01 19:05:25.000000000 -0500
@@ -173,9 +173,11 @@ extern struct async_domain scsi_sd_probe
 /* scsi_dh.c */
 #ifdef CONFIG_SCSI_DH
 int scsi_dh_add_device(struct scsi_device *sdev);
+void scsi_dh_release_device(struct scsi_device *sdev);
 void scsi_dh_remove_device(struct scsi_device *sdev);
 #else
 static inline int scsi_dh_add_device(struct scsi_device *sdev) { return 0; }
+static inline void scsi_dh_release_device(struct scsi_device *sdev) { }
 static inline void scsi_dh_remove_device(struct scsi_device *sdev) { }
 #endif
 
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/scsi/scsi_sysfs.c linux-libre-4.3-gnu/drivers/scsi/scsi_sysfs.c
--- linux-libre-4.3-rc7-gnu/drivers/scsi/scsi_sysfs.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/scsi/scsi_sysfs.c	2015-11-01 19:05:25.000000000 -0500
@@ -399,6 +399,8 @@ static void scsi_device_dev_release_user
 
 	sdev = container_of(work, struct scsi_device, ew.work);
 
+	scsi_dh_release_device(sdev);
+
 	parent = sdev->sdev_gendev.parent;
 
 	spin_lock_irqsave(sdev->host->host_lock, flags);
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/usb/musb/omap2430.c linux-libre-4.3-gnu/drivers/usb/musb/omap2430.c
--- linux-libre-4.3-rc7-gnu/drivers/usb/musb/omap2430.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/usb/musb/omap2430.c	2015-11-01 19:05:25.000000000 -0500
@@ -391,9 +391,20 @@ static int omap2430_musb_init(struct mus
 	}
 	musb->isr = omap2430_musb_interrupt;
 
+	/*
+	 * Enable runtime PM for musb parent (this driver). We can't
+	 * do it earlier as struct musb is not yet allocated and we
+	 * need to touch the musb registers for runtime PM.
+	 */
+	pm_runtime_enable(glue->dev);
+	status = pm_runtime_get_sync(glue->dev);
+	if (status < 0)
+		goto err1;
+
 	status = pm_runtime_get_sync(dev);
 	if (status < 0) {
 		dev_err(dev, "pm_runtime_get_sync FAILED %d\n", status);
+		pm_runtime_put_sync(glue->dev);
 		goto err1;
 	}
 
@@ -426,6 +437,7 @@ static int omap2430_musb_init(struct mus
 	phy_power_on(musb->phy);
 
 	pm_runtime_put_noidle(musb->controller);
+	pm_runtime_put_noidle(glue->dev);
 	return 0;
 
 err1:
@@ -626,7 +638,11 @@ static int omap2430_probe(struct platfor
 		goto err2;
 	}
 
-	pm_runtime_enable(&pdev->dev);
+	/*
+	 * Note that we cannot enable PM runtime yet for this
+	 * driver as we need struct musb initialized first.
+	 * See omap2430_musb_init above.
+	 */
 
 	ret = platform_device_add(musb);
 	if (ret) {
@@ -675,11 +691,12 @@ static int omap2430_runtime_resume(struc
 	struct omap2430_glue		*glue = dev_get_drvdata(dev);
 	struct musb			*musb = glue_to_musb(glue);
 
-	if (musb) {
-		omap2430_low_level_init(musb);
-		musb_writel(musb->mregs, OTG_INTERFSEL,
-				musb->context.otg_interfsel);
-	}
+	if (!musb)
+		return -EPROBE_DEFER;
+
+	omap2430_low_level_init(musb);
+	musb_writel(musb->mregs, OTG_INTERFSEL,
+		    musb->context.otg_interfsel);
 
 	return 0;
 }
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/drivers/vhost/vhost.h linux-libre-4.3-gnu/drivers/vhost/vhost.h
--- linux-libre-4.3-rc7-gnu/drivers/vhost/vhost.h	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/drivers/vhost/vhost.h	2015-11-01 19:05:25.000000000 -0500
@@ -183,10 +183,17 @@ static inline bool vhost_has_feature(str
 	return vq->acked_features & (1ULL << bit);
 }
 
+#ifdef CONFIG_VHOST_CROSS_ENDIAN_LEGACY
 static inline bool vhost_is_little_endian(struct vhost_virtqueue *vq)
 {
 	return vq->is_le;
 }
+#else
+static inline bool vhost_is_little_endian(struct vhost_virtqueue *vq)
+{
+	return virtio_legacy_is_little_endian() || vq->is_le;
+}
+#endif
 
 /* Memory accessors */
 static inline u16 vhost16_to_cpu(struct vhost_virtqueue *vq, __virtio16 val)
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/fs/overlayfs/copy_up.c linux-libre-4.3-gnu/fs/overlayfs/copy_up.c
--- linux-libre-4.3-rc7-gnu/fs/overlayfs/copy_up.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/fs/overlayfs/copy_up.c	2015-11-01 19:05:25.000000000 -0500
@@ -81,11 +81,11 @@ static int ovl_copy_up_data(struct path
 	if (len == 0)
 		return 0;
 
-	old_file = ovl_path_open(old, O_RDONLY);
+	old_file = ovl_path_open(old, O_LARGEFILE | O_RDONLY);
 	if (IS_ERR(old_file))
 		return PTR_ERR(old_file);
 
-	new_file = ovl_path_open(new, O_WRONLY);
+	new_file = ovl_path_open(new, O_LARGEFILE | O_WRONLY);
 	if (IS_ERR(new_file)) {
 		error = PTR_ERR(new_file);
 		goto out_fput;
@@ -267,7 +267,7 @@ out:
 
 out_cleanup:
 	ovl_cleanup(wdir, newdentry);
-	goto out;
+	goto out2;
 }
 
 /*
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/fs/overlayfs/inode.c linux-libre-4.3-gnu/fs/overlayfs/inode.c
--- linux-libre-4.3-rc7-gnu/fs/overlayfs/inode.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/fs/overlayfs/inode.c	2015-11-01 19:05:25.000000000 -0500
@@ -363,6 +363,9 @@ struct inode *ovl_d_select_inode(struct
 		ovl_path_upper(dentry, &realpath);
 	}
 
+	if (realpath.dentry->d_flags & DCACHE_OP_SELECT_INODE)
+		return realpath.dentry->d_op->d_select_inode(realpath.dentry, file_flags);
+
 	return d_backing_inode(realpath.dentry);
 }
 
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/fs/overlayfs/super.c linux-libre-4.3-gnu/fs/overlayfs/super.c
--- linux-libre-4.3-rc7-gnu/fs/overlayfs/super.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/fs/overlayfs/super.c	2015-11-01 19:05:25.000000000 -0500
@@ -544,6 +544,7 @@ static void ovl_put_super(struct super_b
 	mntput(ufs->upper_mnt);
 	for (i = 0; i < ufs->numlower; i++)
 		mntput(ufs->lower_mnt[i]);
+	kfree(ufs->lower_mnt);
 
 	kfree(ufs->config.lowerdir);
 	kfree(ufs->config.upperdir);
@@ -1048,6 +1049,7 @@ static int ovl_fill_super(struct super_b
 		oe->lowerstack[i].dentry = stack[i].dentry;
 		oe->lowerstack[i].mnt = ufs->lower_mnt[i];
 	}
+	kfree(stack);
 
 	root_dentry->d_fsdata = oe;
 
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/include/linux/blk-cgroup.h linux-libre-4.3-gnu/include/linux/blk-cgroup.h
--- linux-libre-4.3-rc7-gnu/include/linux/blk-cgroup.h	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/include/linux/blk-cgroup.h	2015-11-01 19:05:25.000000000 -0500
@@ -713,9 +713,9 @@ static inline bool blkcg_bio_issue_check
 
 	if (!throtl) {
 		blkg = blkg ?: q->root_blkg;
-		blkg_rwstat_add(&blkg->stat_bytes, bio->bi_flags,
+		blkg_rwstat_add(&blkg->stat_bytes, bio->bi_rw,
 				bio->bi_iter.bi_size);
-		blkg_rwstat_add(&blkg->stat_ios, bio->bi_flags, 1);
+		blkg_rwstat_add(&blkg->stat_ios, bio->bi_rw, 1);
 	}
 
 	rcu_read_unlock();
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/include/linux/netdevice.h linux-libre-4.3-gnu/include/linux/netdevice.h
--- linux-libre-4.3-rc7-gnu/include/linux/netdevice.h	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/include/linux/netdevice.h	2015-11-01 19:05:25.000000000 -0500
@@ -1054,6 +1054,10 @@ typedef u16 (*select_queue_fallback_t)(s
  *	This function is used to pass protocol port error state information
  *	to the switch driver. The switch driver can react to the proto_down
  *      by doing a phys down on the associated switch port.
+ * int (*ndo_fill_metadata_dst)(struct net_device *dev, struct sk_buff *skb);
+ *	This function is used to get egress tunnel information for given skb.
+ *	This is useful for retrieving outer tunnel header parameters while
+ *	sampling packet.
  *
  */
 struct net_device_ops {
@@ -1227,6 +1231,8 @@ struct net_device_ops {
 	int			(*ndo_get_iflink)(const struct net_device *dev);
 	int			(*ndo_change_proto_down)(struct net_device *dev,
 							 bool proto_down);
+	int			(*ndo_fill_metadata_dst)(struct net_device *dev,
+						       struct sk_buff *skb);
 };
 
 /**
@@ -2203,6 +2209,7 @@ void dev_add_offload(struct packet_offlo
 void dev_remove_offload(struct packet_offload *po);
 
 int dev_get_iflink(const struct net_device *dev);
+int dev_fill_metadata_dst(struct net_device *dev, struct sk_buff *skb);
 struct net_device *__dev_get_by_flags(struct net *net, unsigned short flags,
 				      unsigned short mask);
 struct net_device *dev_get_by_name(struct net *net, const char *name);
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/include/linux/omap-dma.h linux-libre-4.3-gnu/include/linux/omap-dma.h
--- linux-libre-4.3-rc7-gnu/include/linux/omap-dma.h	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/include/linux/omap-dma.h	2015-11-01 19:05:25.000000000 -0500
@@ -17,7 +17,7 @@
 
 #include <linux/platform_device.h>
 
-#define INT_DMA_LCD			25
+#define INT_DMA_LCD			(NR_IRQS_LEGACY + 25)
 
 #define OMAP1_DMA_TOUT_IRQ		(1 << 0)
 #define OMAP_DMA_DROP_IRQ		(1 << 1)
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/include/net/dst_metadata.h linux-libre-4.3-gnu/include/net/dst_metadata.h
--- linux-libre-4.3-rc7-gnu/include/net/dst_metadata.h	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/include/net/dst_metadata.h	2015-11-01 19:05:25.000000000 -0500
@@ -60,6 +60,38 @@ static inline struct metadata_dst *tun_r
 	return tun_dst;
 }
 
+static inline struct metadata_dst *tun_dst_unclone(struct sk_buff *skb)
+{
+	struct metadata_dst *md_dst = skb_metadata_dst(skb);
+	int md_size = md_dst->u.tun_info.options_len;
+	struct metadata_dst *new_md;
+
+	if (!md_dst)
+		return ERR_PTR(-EINVAL);
+
+	new_md = metadata_dst_alloc(md_size, GFP_ATOMIC);
+	if (!new_md)
+		return ERR_PTR(-ENOMEM);
+
+	memcpy(&new_md->u.tun_info, &md_dst->u.tun_info,
+	       sizeof(struct ip_tunnel_info) + md_size);
+	skb_dst_drop(skb);
+	dst_hold(&new_md->dst);
+	skb_dst_set(skb, &new_md->dst);
+	return new_md;
+}
+
+static inline struct ip_tunnel_info *skb_tunnel_info_unclone(struct sk_buff *skb)
+{
+	struct metadata_dst *dst;
+
+	dst = tun_dst_unclone(skb);
+	if (IS_ERR(dst))
+		return NULL;
+
+	return &dst->u.tun_info;
+}
+
 static inline struct metadata_dst *ip_tun_rx_dst(struct sk_buff *skb,
 						 __be16 flags,
 						 __be64 tunnel_id,
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/include/uapi/linux/openvswitch.h linux-libre-4.3-gnu/include/uapi/linux/openvswitch.h
--- linux-libre-4.3-rc7-gnu/include/uapi/linux/openvswitch.h	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/include/uapi/linux/openvswitch.h	2015-11-01 19:05:25.000000000 -0500
@@ -620,7 +620,8 @@ struct ovs_action_hash {
  * enum ovs_ct_attr - Attributes for %OVS_ACTION_ATTR_CT action.
  * @OVS_CT_ATTR_COMMIT: If present, commits the connection to the conntrack
  * table. This allows future packets for the same connection to be identified
- * as 'established' or 'related'.
+ * as 'established' or 'related'. The flow key for the current packet will
+ * retain the pre-commit connection state.
  * @OVS_CT_ATTR_ZONE: u16 connection tracking zone.
  * @OVS_CT_ATTR_MARK: u32 value followed by u32 mask. For each bit set in the
  * mask, the corresponding bit in the value is copied to the connection
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/kernel/memremap.c linux-libre-4.3-gnu/kernel/memremap.c
--- linux-libre-4.3-rc7-gnu/kernel/memremap.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/kernel/memremap.c	2015-11-01 19:05:25.000000000 -0500
@@ -24,6 +24,16 @@ __weak void __iomem *ioremap_cache(resou
 }
 #endif
 
+static void *try_ram_remap(resource_size_t offset, size_t size)
+{
+	struct page *page = pfn_to_page(offset >> PAGE_SHIFT);
+
+	/* In the simple case just return the existing linear address */
+	if (!PageHighMem(page))
+		return __va(offset);
+	return NULL; /* fallback to ioremap_cache */
+}
+
 /**
  * memremap() - remap an iomem_resource as cacheable memory
  * @offset: iomem resource start address
@@ -66,8 +76,8 @@ void *memremap(resource_size_t offset, s
 		 * the requested range is potentially in "System RAM"
 		 */
 		if (is_ram == REGION_INTERSECTS)
-			addr = __va(offset);
-		else
+			addr = try_ram_remap(offset, size);
+		if (!addr)
 			addr = ioremap_cache(offset, size);
 	}
 
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/kernel/module.c linux-libre-4.3-gnu/kernel/module.c
--- linux-libre-4.3-rc7-gnu/kernel/module.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/kernel/module.c	2015-11-01 19:05:25.000000000 -0500
@@ -1063,11 +1063,15 @@ void symbol_put_addr(void *addr)
 	if (core_kernel_text(a))
 		return;
 
-	/* module_text_address is safe here: we're supposed to have reference
-	 * to module from symbol_get, so it can't go away. */
+	/*
+	 * Even though we hold a reference on the module; we still need to
+	 * disable preemption in order to safely traverse the data structure.
+	 */
+	preempt_disable();
 	modaddr = __module_text_address(a);
 	BUG_ON(!modaddr);
 	module_put(modaddr);
+	preempt_enable();
 }
 EXPORT_SYMBOL_GPL(symbol_put_addr);
 
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/MAINTAINERS linux-libre-4.3-gnu/MAINTAINERS
--- linux-libre-4.3-rc7-gnu/MAINTAINERS	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/MAINTAINERS	2015-11-01 19:05:25.000000000 -0500
@@ -4428,6 +4428,14 @@ L:	linuxppc-dev@lists.ozlabs.org
 S:	Maintained
 F:	drivers/net/ethernet/freescale/ucc_geth*
 
+FREESCALE eTSEC ETHERNET DRIVER (GIANFAR)
+M:	Claudiu Manoil <claudiu.manoil@freescale.com>
+L:	netdev@vger.kernel.org
+S:	Maintained
+F:	drivers/net/ethernet/freescale/gianfar*
+X:	drivers/net/ethernet/freescale/gianfar_ptp.c
+F:	Documentation/devicetree/bindings/net/fsl-tsec-phy.txt
+
 FREESCALE QUICC ENGINE UCC UART DRIVER
 M:	Timur Tabi <timur@tabi.org>
 L:	linuxppc-dev@lists.ozlabs.org
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/Makefile linux-libre-4.3-gnu/Makefile
--- linux-libre-4.3-rc7-gnu/Makefile	2015-11-01 03:14:25.000000000 -0500
+++ linux-libre-4.3-gnu/Makefile	2015-11-01 23:19:53.000000000 -0500
@@ -1,7 +1,7 @@
 VERSION = 4
 PATCHLEVEL = 3
 SUBLEVEL = 0
-EXTRAVERSION = -rc7-gnu
+EXTRAVERSION = -gnu
 NAME = Blurry Fish Butt
 
 # *DOCUMENTATION*
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/core/dev.c linux-libre-4.3-gnu/net/core/dev.c
--- linux-libre-4.3-rc7-gnu/net/core/dev.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/core/dev.c	2015-11-01 19:05:25.000000000 -0500
@@ -99,6 +99,7 @@
 #include <linux/rtnetlink.h>
 #include <linux/stat.h>
 #include <net/dst.h>
+#include <net/dst_metadata.h>
 #include <net/pkt_sched.h>
 #include <net/checksum.h>
 #include <net/xfrm.h>
@@ -682,6 +683,32 @@ int dev_get_iflink(const struct net_devi
 EXPORT_SYMBOL(dev_get_iflink);
 
 /**
+ *	dev_fill_metadata_dst - Retrieve tunnel egress information.
+ *	@dev: targeted interface
+ *	@skb: The packet.
+ *
+ *	For better visibility of tunnel traffic OVS needs to retrieve
+ *	egress tunnel information for a packet. Following API allows
+ *	user to get this info.
+ */
+int dev_fill_metadata_dst(struct net_device *dev, struct sk_buff *skb)
+{
+	struct ip_tunnel_info *info;
+
+	if (!dev->netdev_ops  || !dev->netdev_ops->ndo_fill_metadata_dst)
+		return -EINVAL;
+
+	info = skb_tunnel_info_unclone(skb);
+	if (!info)
+		return -ENOMEM;
+	if (unlikely(!(info->mode & IP_TUNNEL_INFO_TX)))
+		return -EINVAL;
+
+	return dev->netdev_ops->ndo_fill_metadata_dst(dev, skb);
+}
+EXPORT_SYMBOL_GPL(dev_fill_metadata_dst);
+
+/**
  *	__dev_get_by_name	- find a device by its name
  *	@net: the applicable net namespace
  *	@name: name to find
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/ipv4/fib_trie.c linux-libre-4.3-gnu/net/ipv4/fib_trie.c
--- linux-libre-4.3-rc7-gnu/net/ipv4/fib_trie.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/ipv4/fib_trie.c	2015-11-01 19:05:25.000000000 -0500
@@ -1569,7 +1569,7 @@ static struct key_vector *leaf_walk_rcu(
 	do {
 		/* record parent and next child index */
 		pn = n;
-		cindex = key ? get_index(key, pn) : 0;
+		cindex = (key > pn->key) ? get_index(key, pn) : 0;
 
 		if (cindex >> pn->bits)
 			break;
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/ipv4/gre_offload.c linux-libre-4.3-gnu/net/ipv4/gre_offload.c
--- linux-libre-4.3-rc7-gnu/net/ipv4/gre_offload.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/ipv4/gre_offload.c	2015-11-01 19:05:25.000000000 -0500
@@ -36,7 +36,8 @@ static struct sk_buff *gre_gso_segment(s
 				  SKB_GSO_TCP_ECN |
 				  SKB_GSO_GRE |
 				  SKB_GSO_GRE_CSUM |
-				  SKB_GSO_IPIP)))
+				  SKB_GSO_IPIP |
+				  SKB_GSO_SIT)))
 		goto out;
 
 	if (!skb->encapsulation)
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/ipv4/ip_gre.c linux-libre-4.3-gnu/net/ipv4/ip_gre.c
--- linux-libre-4.3-rc7-gnu/net/ipv4/ip_gre.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/ipv4/ip_gre.c	2015-11-01 19:05:25.000000000 -0500
@@ -498,10 +498,26 @@ static struct sk_buff *gre_handle_offloa
 					csum ? SKB_GSO_GRE_CSUM : SKB_GSO_GRE);
 }
 
+static struct rtable *gre_get_rt(struct sk_buff *skb,
+				 struct net_device *dev,
+				 struct flowi4 *fl,
+				 const struct ip_tunnel_key *key)
+{
+	struct net *net = dev_net(dev);
+
+	memset(fl, 0, sizeof(*fl));
+	fl->daddr = key->u.ipv4.dst;
+	fl->saddr = key->u.ipv4.src;
+	fl->flowi4_tos = RT_TOS(key->tos);
+	fl->flowi4_mark = skb->mark;
+	fl->flowi4_proto = IPPROTO_GRE;
+
+	return ip_route_output_key(net, fl);
+}
+
 static void gre_fb_xmit(struct sk_buff *skb, struct net_device *dev)
 {
 	struct ip_tunnel_info *tun_info;
-	struct net *net = dev_net(dev);
 	const struct ip_tunnel_key *key;
 	struct flowi4 fl;
 	struct rtable *rt;
@@ -516,14 +532,7 @@ static void gre_fb_xmit(struct sk_buff *
 		goto err_free_skb;
 
 	key = &tun_info->key;
-	memset(&fl, 0, sizeof(fl));
-	fl.daddr = key->u.ipv4.dst;
-	fl.saddr = key->u.ipv4.src;
-	fl.flowi4_tos = RT_TOS(key->tos);
-	fl.flowi4_mark = skb->mark;
-	fl.flowi4_proto = IPPROTO_GRE;
-
-	rt = ip_route_output_key(net, &fl);
+	rt = gre_get_rt(skb, dev, &fl, key);
 	if (IS_ERR(rt))
 		goto err_free_skb;
 
@@ -566,6 +575,24 @@ err_free_skb:
 	dev->stats.tx_dropped++;
 }
 
+static int gre_fill_metadata_dst(struct net_device *dev, struct sk_buff *skb)
+{
+	struct ip_tunnel_info *info = skb_tunnel_info(skb);
+	struct rtable *rt;
+	struct flowi4 fl4;
+
+	if (ip_tunnel_info_af(info) != AF_INET)
+		return -EINVAL;
+
+	rt = gre_get_rt(skb, dev, &fl4, &info->key);
+	if (IS_ERR(rt))
+		return PTR_ERR(rt);
+
+	ip_rt_put(rt);
+	info->key.u.ipv4.src = fl4.saddr;
+	return 0;
+}
+
 static netdev_tx_t ipgre_xmit(struct sk_buff *skb,
 			      struct net_device *dev)
 {
@@ -1023,6 +1050,7 @@ static const struct net_device_ops gre_t
 	.ndo_change_mtu		= ip_tunnel_change_mtu,
 	.ndo_get_stats64	= ip_tunnel_get_stats64,
 	.ndo_get_iflink		= ip_tunnel_get_iflink,
+	.ndo_fill_metadata_dst	= gre_fill_metadata_dst,
 };
 
 static void ipgre_tap_setup(struct net_device *dev)
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/ipv4/netfilter/ipt_rpfilter.c linux-libre-4.3-gnu/net/ipv4/netfilter/ipt_rpfilter.c
--- linux-libre-4.3-rc7-gnu/net/ipv4/netfilter/ipt_rpfilter.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/ipv4/netfilter/ipt_rpfilter.c	2015-11-01 19:05:25.000000000 -0500
@@ -61,9 +61,7 @@ static bool rpfilter_lookup_reverse(stru
 	if (FIB_RES_DEV(res) == dev)
 		dev_match = true;
 #endif
-	if (dev_match || flags & XT_RPFILTER_LOOSE)
-		return FIB_RES_NH(res).nh_scope <= RT_SCOPE_HOST;
-	return dev_match;
+	return dev_match || flags & XT_RPFILTER_LOOSE;
 }
 
 static bool rpfilter_is_local(const struct sk_buff *skb)
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/ipv4/netfilter/Kconfig linux-libre-4.3-gnu/net/ipv4/netfilter/Kconfig
--- linux-libre-4.3-rc7-gnu/net/ipv4/netfilter/Kconfig	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/ipv4/netfilter/Kconfig	2015-11-01 19:05:25.000000000 -0500
@@ -75,6 +75,7 @@ endif # NF_TABLES
 
 config NF_DUP_IPV4
 	tristate "Netfilter IPv4 packet duplication to alternate destination"
+	depends on !NF_CONNTRACK || NF_CONNTRACK
 	help
 	  This option enables the nf_dup_ipv4 core, which duplicates an IPv4
 	  packet to be rerouted to another destination.
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/ipv4/tcp_dctcp.c linux-libre-4.3-gnu/net/ipv4/tcp_dctcp.c
--- linux-libre-4.3-rc7-gnu/net/ipv4/tcp_dctcp.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/ipv4/tcp_dctcp.c	2015-11-01 19:05:25.000000000 -0500
@@ -209,7 +209,7 @@ static void dctcp_update_alpha(struct so
 
 		/* alpha = (1 - g) * alpha + g * F */
 
-		alpha -= alpha >> dctcp_shift_g;
+		alpha -= min_not_zero(alpha, alpha >> dctcp_shift_g);
 		if (bytes_ecn) {
 			/* If dctcp_shift_g == 1, a 32bit value would overflow
 			 * after 8 Mbytes.
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/ipv4/tcp_output.c linux-libre-4.3-gnu/net/ipv4/tcp_output.c
--- linux-libre-4.3-rc7-gnu/net/ipv4/tcp_output.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/ipv4/tcp_output.c	2015-11-01 19:05:25.000000000 -0500
@@ -3405,7 +3405,7 @@ static int tcp_xmit_probe_skb(struct soc
 	 */
 	tcp_init_nondata_skb(skb, tp->snd_una - !urgent, TCPHDR_ACK);
 	skb_mstamp_get(&skb->skb_mstamp);
-	NET_INC_STATS_BH(sock_net(sk), mib);
+	NET_INC_STATS(sock_net(sk), mib);
 	return tcp_transmit_skb(sk, skb, 0, GFP_ATOMIC);
 }
 
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/ipv4/xfrm4_output.c linux-libre-4.3-gnu/net/ipv4/xfrm4_output.c
--- linux-libre-4.3-rc7-gnu/net/ipv4/xfrm4_output.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/ipv4/xfrm4_output.c	2015-11-01 19:05:25.000000000 -0500
@@ -30,6 +30,8 @@ static int xfrm4_tunnel_check_size(struc
 
 	mtu = dst_mtu(skb_dst(skb));
 	if (skb->len > mtu) {
+		skb->protocol = htons(ETH_P_IP);
+
 		if (skb->sk)
 			xfrm_local_error(skb, mtu);
 		else
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/ipv6/fib6_rules.c linux-libre-4.3-gnu/net/ipv6/fib6_rules.c
--- linux-libre-4.3-rc7-gnu/net/ipv6/fib6_rules.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/ipv6/fib6_rules.c	2015-11-01 19:05:25.000000000 -0500
@@ -32,6 +32,7 @@ struct fib6_rule {
 struct dst_entry *fib6_rule_lookup(struct net *net, struct flowi6 *fl6,
 				   int flags, pol_lookup_t lookup)
 {
+	struct rt6_info *rt;
 	struct fib_lookup_arg arg = {
 		.lookup_ptr = lookup,
 		.flags = FIB_LOOKUP_NOREF,
@@ -40,11 +41,21 @@ struct dst_entry *fib6_rule_lookup(struc
 	fib_rules_lookup(net->ipv6.fib6_rules_ops,
 			 flowi6_to_flowi(fl6), flags, &arg);
 
-	if (arg.result)
-		return arg.result;
+	rt = arg.result;
 
-	dst_hold(&net->ipv6.ip6_null_entry->dst);
-	return &net->ipv6.ip6_null_entry->dst;
+	if (!rt) {
+		dst_hold(&net->ipv6.ip6_null_entry->dst);
+		return &net->ipv6.ip6_null_entry->dst;
+	}
+
+	if (rt->rt6i_flags & RTF_REJECT &&
+	    rt->dst.error == -EAGAIN) {
+		ip6_rt_put(rt);
+		rt = net->ipv6.ip6_null_entry;
+		dst_hold(&rt->dst);
+	}
+
+	return &rt->dst;
 }
 
 static int fib6_rule_action(struct fib_rule *rule, struct flowi *flp,
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/ipv6/ip6_fib.c linux-libre-4.3-gnu/net/ipv6/ip6_fib.c
--- linux-libre-4.3-rc7-gnu/net/ipv6/ip6_fib.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/ipv6/ip6_fib.c	2015-11-01 19:05:25.000000000 -0500
@@ -285,7 +285,17 @@ struct fib6_table *fib6_get_table(struct
 struct dst_entry *fib6_rule_lookup(struct net *net, struct flowi6 *fl6,
 				   int flags, pol_lookup_t lookup)
 {
-	return (struct dst_entry *) lookup(net, net->ipv6.fib6_main_tbl, fl6, flags);
+	struct rt6_info *rt;
+
+	rt = lookup(net, net->ipv6.fib6_main_tbl, fl6, flags);
+	if (rt->rt6i_flags & RTF_REJECT &&
+	    rt->dst.error == -EAGAIN) {
+		ip6_rt_put(rt);
+		rt = net->ipv6.ip6_null_entry;
+		dst_hold(&rt->dst);
+	}
+
+	return &rt->dst;
 }
 
 static void __net_init fib6_tables_init(struct net *net)
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/ipv6/ip6_output.c linux-libre-4.3-gnu/net/ipv6/ip6_output.c
--- linux-libre-4.3-rc7-gnu/net/ipv6/ip6_output.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/ipv6/ip6_output.c	2015-11-01 19:05:25.000000000 -0500
@@ -584,6 +584,8 @@ int ip6_fragment(struct sock *sk, struct
 		if (np->frag_size)
 			mtu = np->frag_size;
 	}
+	if (mtu < hlen + sizeof(struct frag_hdr) + 8)
+		goto fail_toobig;
 	mtu -= hlen + sizeof(struct frag_hdr);
 
 	frag_id = ipv6_select_ident(net, &ipv6_hdr(skb)->daddr,
@@ -877,7 +879,8 @@ static struct dst_entry *ip6_sk_dst_chec
 #ifdef CONFIG_IPV6_SUBTREES
 	    ip6_rt_check(&rt->rt6i_src, &fl6->saddr, np->saddr_cache) ||
 #endif
-	    (fl6->flowi6_oif && fl6->flowi6_oif != dst->dev->ifindex)) {
+	   (!(fl6->flowi6_flags & FLOWI_FLAG_SKIP_NH_OIF) &&
+	      (fl6->flowi6_oif && fl6->flowi6_oif != dst->dev->ifindex))) {
 		dst_release(dst);
 		dst = NULL;
 	}
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/ipv6/netfilter/Kconfig linux-libre-4.3-gnu/net/ipv6/netfilter/Kconfig
--- linux-libre-4.3-rc7-gnu/net/ipv6/netfilter/Kconfig	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/ipv6/netfilter/Kconfig	2015-11-01 19:05:25.000000000 -0500
@@ -58,6 +58,7 @@ endif # NF_TABLES
 
 config NF_DUP_IPV6
 	tristate "Netfilter IPv6 packet duplication to alternate destination"
+	depends on !NF_CONNTRACK || NF_CONNTRACK
 	help
 	  This option enables the nf_dup_ipv6 core, which duplicates an IPv6
 	  packet to be rerouted to another destination.
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/ipv6/netfilter/nf_conntrack_reasm.c linux-libre-4.3-gnu/net/ipv6/netfilter/nf_conntrack_reasm.c
--- linux-libre-4.3-rc7-gnu/net/ipv6/netfilter/nf_conntrack_reasm.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/ipv6/netfilter/nf_conntrack_reasm.c	2015-11-01 19:05:25.000000000 -0500
@@ -646,6 +646,7 @@ void nf_ct_frag6_consume_orig(struct sk_
 		s = s2;
 	}
 }
+EXPORT_SYMBOL_GPL(nf_ct_frag6_consume_orig);
 
 static int nf_ct_net_init(struct net *net)
 {
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/ipv6/route.c linux-libre-4.3-gnu/net/ipv6/route.c
--- linux-libre-4.3-rc7-gnu/net/ipv6/route.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/ipv6/route.c	2015-11-01 19:05:25.000000000 -0500
@@ -1068,6 +1068,9 @@ static struct rt6_info *ip6_pol_route(st
 	fn = fib6_lookup(&table->tb6_root, &fl6->daddr, &fl6->saddr);
 	saved_fn = fn;
 
+	if (fl6->flowi6_flags & FLOWI_FLAG_SKIP_NH_OIF)
+		oif = 0;
+
 redo_rt6_select:
 	rt = rt6_select(fn, oif, strict);
 	if (rt->rt6i_nsiblings)
@@ -1190,14 +1193,16 @@ struct dst_entry *ip6_route_output(struc
 				    struct flowi6 *fl6)
 {
 	int flags = 0;
+	bool any_src;
 
 	fl6->flowi6_iif = LOOPBACK_IFINDEX;
 
+	any_src = ipv6_addr_any(&fl6->saddr);
 	if ((sk && sk->sk_bound_dev_if) || rt6_need_strict(&fl6->daddr) ||
-	    fl6->flowi6_oif)
+	    (fl6->flowi6_oif && any_src))
 		flags |= RT6_LOOKUP_F_IFACE;
 
-	if (!ipv6_addr_any(&fl6->saddr))
+	if (!any_src)
 		flags |= RT6_LOOKUP_F_HAS_SADDR;
 	else if (sk)
 		flags |= rt6_srcprefs2flags(inet6_sk(sk)->srcprefs);
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/ipv6/xfrm6_output.c linux-libre-4.3-gnu/net/ipv6/xfrm6_output.c
--- linux-libre-4.3-rc7-gnu/net/ipv6/xfrm6_output.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/ipv6/xfrm6_output.c	2015-11-01 19:05:25.000000000 -0500
@@ -79,6 +79,7 @@ static int xfrm6_tunnel_check_size(struc
 
 	if (!skb->ignore_df && skb->len > mtu) {
 		skb->dev = dst->dev;
+		skb->protocol = htons(ETH_P_IPV6);
 
 		if (xfrm6_local_dontfrag(skb))
 			xfrm6_local_rxpmtu(skb, mtu);
@@ -136,6 +137,7 @@ static int __xfrm6_output(struct sock *s
 	struct dst_entry *dst = skb_dst(skb);
 	struct xfrm_state *x = dst->xfrm;
 	int mtu;
+	bool toobig;
 
 #ifdef CONFIG_NETFILTER
 	if (!x) {
@@ -144,25 +146,29 @@ static int __xfrm6_output(struct sock *s
 	}
 #endif
 
+	if (x->props.mode != XFRM_MODE_TUNNEL)
+		goto skip_frag;
+
 	if (skb->protocol == htons(ETH_P_IPV6))
 		mtu = ip6_skb_dst_mtu(skb);
 	else
 		mtu = dst_mtu(skb_dst(skb));
 
-	if (skb->len > mtu && xfrm6_local_dontfrag(skb)) {
+	toobig = skb->len > mtu && !skb_is_gso(skb);
+
+	if (toobig && xfrm6_local_dontfrag(skb)) {
 		xfrm6_local_rxpmtu(skb, mtu);
 		return -EMSGSIZE;
-	} else if (!skb->ignore_df && skb->len > mtu && skb->sk) {
+	} else if (!skb->ignore_df && toobig && skb->sk) {
 		xfrm_local_error(skb, mtu);
 		return -EMSGSIZE;
 	}
 
-	if (x->props.mode == XFRM_MODE_TUNNEL &&
-	    ((skb->len > mtu && !skb_is_gso(skb)) ||
-		dst_allfrag(skb_dst(skb)))) {
+	if (toobig || dst_allfrag(skb_dst(skb)))
 		return ip6_fragment(sk, skb,
 				    x->outer_mode->afinfo->output_finish);
-	}
+
+skip_frag:
 	return x->outer_mode->afinfo->output_finish(sk, skb);
 }
 
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/ipv6/xfrm6_policy.c linux-libre-4.3-gnu/net/ipv6/xfrm6_policy.c
--- linux-libre-4.3-rc7-gnu/net/ipv6/xfrm6_policy.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/ipv6/xfrm6_policy.c	2015-11-01 19:05:25.000000000 -0500
@@ -179,7 +179,8 @@ _decode_session6(struct sk_buff *skb, st
 			return;
 
 		case IPPROTO_ICMPV6:
-			if (!onlyproto && pskb_may_pull(skb, nh + offset + 2 - skb->data)) {
+			if (!onlyproto && (nh + offset + 2 < skb->data ||
+			    pskb_may_pull(skb, nh + offset + 2 - skb->data))) {
 				u8 *icmp;
 
 				nh = skb_network_header(skb);
@@ -193,7 +194,8 @@ _decode_session6(struct sk_buff *skb, st
 #if IS_ENABLED(CONFIG_IPV6_MIP6)
 		case IPPROTO_MH:
 			offset += ipv6_optlen(exthdr);
-			if (!onlyproto && pskb_may_pull(skb, nh + offset + 3 - skb->data)) {
+			if (!onlyproto && (nh + offset + 3 < skb->data ||
+			    pskb_may_pull(skb, nh + offset + 3 - skb->data))) {
 				struct ip6_mh *mh;
 
 				nh = skb_network_header(skb);
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/irda/irlmp.c linux-libre-4.3-gnu/net/irda/irlmp.c
--- linux-libre-4.3-rc7-gnu/net/irda/irlmp.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/irda/irlmp.c	2015-11-01 19:05:25.000000000 -0500
@@ -1839,7 +1839,7 @@ static void *irlmp_seq_hb_idx(struct irl
 	for (element = hashbin_get_first(iter->hashbin);
 	     element != NULL;
 	     element = hashbin_get_next(iter->hashbin)) {
-		if (!off || *off-- == 0) {
+		if (!off || (*off)-- == 0) {
 			/* NB: hashbin left locked */
 			return element;
 		}
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/key/af_key.c linux-libre-4.3-gnu/net/key/af_key.c
--- linux-libre-4.3-rc7-gnu/net/key/af_key.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/key/af_key.c	2015-11-01 19:05:25.000000000 -0500
@@ -261,7 +261,7 @@ static int pfkey_broadcast(struct sk_buf
 
 		err2 = pfkey_broadcast_one(skb, &skb2, GFP_ATOMIC, sk);
 
-		/* Error is cleare after succecful sending to at least one
+		/* Error is cleared after successful sending to at least one
 		 * registered KM */
 		if ((broadcast_flags & BROADCAST_REGISTERED) && err)
 			err = err2;
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/netfilter/core.c linux-libre-4.3-gnu/net/netfilter/core.c
--- linux-libre-4.3-rc7-gnu/net/netfilter/core.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/netfilter/core.c	2015-11-01 19:05:25.000000000 -0500
@@ -152,6 +152,8 @@ void nf_unregister_net_hook(struct net *
 #endif
 	synchronize_net();
 	nf_queue_nf_hook_drop(net, &entry->ops);
+	/* other cpu might still process nfqueue verdict that used reg */
+	synchronize_net();
 	kfree(entry);
 }
 EXPORT_SYMBOL(nf_unregister_net_hook);
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/netfilter/ipset/ip_set_list_set.c linux-libre-4.3-gnu/net/netfilter/ipset/ip_set_list_set.c
--- linux-libre-4.3-rc7-gnu/net/netfilter/ipset/ip_set_list_set.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/netfilter/ipset/ip_set_list_set.c	2015-11-01 19:05:25.000000000 -0500
@@ -297,7 +297,7 @@ list_set_uadd(struct ip_set *set, void *
 	      ip_set_timeout_expired(ext_timeout(n, set))))
 		n =  NULL;
 
-	e = kzalloc(set->dsize, GFP_KERNEL);
+	e = kzalloc(set->dsize, GFP_ATOMIC);
 	if (!e)
 		return -ENOMEM;
 	e->id = d->id;
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/netlink/af_netlink.c linux-libre-4.3-gnu/net/netlink/af_netlink.c
--- linux-libre-4.3-rc7-gnu/net/netlink/af_netlink.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/netlink/af_netlink.c	2015-11-01 19:05:25.000000000 -0500
@@ -2371,7 +2371,7 @@ static int netlink_getsockopt(struct soc
 		int pos, idx, shift;
 
 		err = 0;
-		netlink_table_grab();
+		netlink_lock_table();
 		for (pos = 0; pos * 8 < nlk->ngroups; pos += sizeof(u32)) {
 			if (len - pos < sizeof(u32))
 				break;
@@ -2386,7 +2386,7 @@ static int netlink_getsockopt(struct soc
 		}
 		if (put_user(ALIGN(nlk->ngroups / 8, sizeof(u32)), optlen))
 			err = -EFAULT;
-		netlink_table_ungrab();
+		netlink_unlock_table();
 		break;
 	}
 	case NETLINK_CAP_ACK:
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/openvswitch/actions.c linux-libre-4.3-gnu/net/openvswitch/actions.c
--- linux-libre-4.3-rc7-gnu/net/openvswitch/actions.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/openvswitch/actions.c	2015-11-01 19:05:25.000000000 -0500
@@ -768,7 +768,6 @@ static int output_userspace(struct datap
 			    struct sw_flow_key *key, const struct nlattr *attr,
 			    const struct nlattr *actions, int actions_len)
 {
-	struct ip_tunnel_info info;
 	struct dp_upcall_info upcall;
 	const struct nlattr *a;
 	int rem;
@@ -796,11 +795,9 @@ static int output_userspace(struct datap
 			if (vport) {
 				int err;
 
-				upcall.egress_tun_info = &info;
-				err = ovs_vport_get_egress_tun_info(vport, skb,
-								    &upcall);
-				if (err)
-					upcall.egress_tun_info = NULL;
+				err = dev_fill_metadata_dst(vport->dev, skb);
+				if (!err)
+					upcall.egress_tun_info = skb_tunnel_info(skb);
 			}
 
 			break;
@@ -1112,8 +1109,8 @@ static int do_execute_actions(struct dat
 					     nla_data(a));
 
 			/* Hide stolen IP fragments from user space. */
-			if (err == -EINPROGRESS)
-				return 0;
+			if (err)
+				return err == -EINPROGRESS ? 0 : err;
 			break;
 		}
 
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/openvswitch/conntrack.c linux-libre-4.3-gnu/net/openvswitch/conntrack.c
--- linux-libre-4.3-rc7-gnu/net/openvswitch/conntrack.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/openvswitch/conntrack.c	2015-11-01 19:05:25.000000000 -0500
@@ -151,6 +151,8 @@ static void ovs_ct_update_key(const stru
 	ct = nf_ct_get(skb, &ctinfo);
 	if (ct) {
 		state = ovs_ct_get_state(ctinfo);
+		if (!nf_ct_is_confirmed(ct))
+			state |= OVS_CS_F_NEW;
 		if (ct->master)
 			state |= OVS_CS_F_RELATED;
 		zone = nf_ct_zone(ct);
@@ -222,9 +224,6 @@ static int ovs_ct_set_labels(struct sk_b
 	struct nf_conn *ct;
 	int err;
 
-	if (!IS_ENABLED(CONFIG_NF_CONNTRACK_LABELS))
-		return -ENOTSUPP;
-
 	/* The connection could be invalid, in which case set_label is no-op.*/
 	ct = nf_ct_get(skb, &ctinfo);
 	if (!ct)
@@ -294,6 +293,9 @@ static int ovs_ct_helper(struct sk_buff
 	return helper->help(skb, protoff, ct, ctinfo);
 }
 
+/* Returns 0 on success, -EINPROGRESS if 'skb' is stolen, or other nonzero
+ * value if 'skb' is freed.
+ */
 static int handle_fragments(struct net *net, struct sw_flow_key *key,
 			    u16 zone, struct sk_buff *skb)
 {
@@ -309,8 +311,8 @@ static int handle_fragments(struct net *
 			return err;
 
 		ovs_cb.mru = IPCB(skb)->frag_max_size;
-	} else if (key->eth.type == htons(ETH_P_IPV6)) {
 #if IS_ENABLED(CONFIG_NF_DEFRAG_IPV6)
+	} else if (key->eth.type == htons(ETH_P_IPV6)) {
 		enum ip6_defrag_users user = IP6_DEFRAG_CONNTRACK_IN + zone;
 		struct sk_buff *reasm;
 
@@ -319,17 +321,25 @@ static int handle_fragments(struct net *
 		if (!reasm)
 			return -EINPROGRESS;
 
-		if (skb == reasm)
+		if (skb == reasm) {
+			kfree_skb(skb);
 			return -EINVAL;
+		}
+
+		/* Don't free 'skb' even though it is one of the original
+		 * fragments, as we're going to morph it into the head.
+		 */
+		skb_get(skb);
+		nf_ct_frag6_consume_orig(reasm);
 
 		key->ip.proto = ipv6_hdr(reasm)->nexthdr;
 		skb_morph(skb, reasm);
+		skb->next = reasm->next;
 		consume_skb(reasm);
 		ovs_cb.mru = IP6CB(skb)->frag_max_size;
-#else
-		return -EPFNOSUPPORT;
 #endif
 	} else {
+		kfree_skb(skb);
 		return -EPFNOSUPPORT;
 	}
 
@@ -377,7 +387,7 @@ static bool skb_nfct_cached(const struct
 	return true;
 }
 
-static int __ovs_ct_lookup(struct net *net, const struct sw_flow_key *key,
+static int __ovs_ct_lookup(struct net *net, struct sw_flow_key *key,
 			   const struct ovs_conntrack_info *info,
 			   struct sk_buff *skb)
 {
@@ -408,6 +418,8 @@ static int __ovs_ct_lookup(struct net *n
 		}
 	}
 
+	ovs_ct_update_key(skb, key, true);
+
 	return 0;
 }
 
@@ -430,8 +442,6 @@ static int ovs_ct_lookup(struct net *net
 		err = __ovs_ct_lookup(net, key, info, skb);
 		if (err)
 			return err;
-
-		ovs_ct_update_key(skb, key, true);
 	}
 
 	return 0;
@@ -460,8 +470,6 @@ static int ovs_ct_commit(struct net *net
 	if (nf_conntrack_confirm(skb) != NF_ACCEPT)
 		return -EINVAL;
 
-	ovs_ct_update_key(skb, key, true);
-
 	return 0;
 }
 
@@ -476,6 +484,9 @@ static bool labels_nonzero(const struct
 	return false;
 }
 
+/* Returns 0 on success, -EINPROGRESS if 'skb' is stolen, or other nonzero
+ * value if 'skb' is freed.
+ */
 int ovs_ct_execute(struct net *net, struct sk_buff *skb,
 		   struct sw_flow_key *key,
 		   const struct ovs_conntrack_info *info)
@@ -511,6 +522,8 @@ int ovs_ct_execute(struct net *net, stru
 					&info->labels.mask);
 err:
 	skb_push(skb, nh_ofs);
+	if (err)
+		kfree_skb(skb);
 	return err;
 }
 
@@ -587,6 +600,10 @@ static int parse_ct(const struct nlattr
 		case OVS_CT_ATTR_MARK: {
 			struct md_mark *mark = nla_data(a);
 
+			if (!mark->mask) {
+				OVS_NLERR(log, "ct_mark mask cannot be 0");
+				return -EINVAL;
+			}
 			info->mark = *mark;
 			break;
 		}
@@ -595,6 +612,10 @@ static int parse_ct(const struct nlattr
 		case OVS_CT_ATTR_LABELS: {
 			struct md_labels *labels = nla_data(a);
 
+			if (!labels_nonzero(&labels->mask)) {
+				OVS_NLERR(log, "ct_labels mask cannot be 0");
+				return -EINVAL;
+			}
 			info->labels = *labels;
 			break;
 		}
@@ -705,11 +726,12 @@ int ovs_ct_action_to_attr(const struct o
 	if (IS_ENABLED(CONFIG_NF_CONNTRACK_ZONES) &&
 	    nla_put_u16(skb, OVS_CT_ATTR_ZONE, ct_info->zone.id))
 		return -EMSGSIZE;
-	if (IS_ENABLED(CONFIG_NF_CONNTRACK_MARK) &&
+	if (IS_ENABLED(CONFIG_NF_CONNTRACK_MARK) && ct_info->mark.mask &&
 	    nla_put(skb, OVS_CT_ATTR_MARK, sizeof(ct_info->mark),
 		    &ct_info->mark))
 		return -EMSGSIZE;
 	if (IS_ENABLED(CONFIG_NF_CONNTRACK_LABELS) &&
+	    labels_nonzero(&ct_info->labels.mask) &&
 	    nla_put(skb, OVS_CT_ATTR_LABELS, sizeof(ct_info->labels),
 		    &ct_info->labels))
 		return -EMSGSIZE;
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/openvswitch/conntrack.h linux-libre-4.3-gnu/net/openvswitch/conntrack.h
--- linux-libre-4.3-rc7-gnu/net/openvswitch/conntrack.h	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/openvswitch/conntrack.h	2015-11-01 19:05:25.000000000 -0500
@@ -35,12 +35,9 @@ void ovs_ct_fill_key(const struct sk_buf
 int ovs_ct_put_key(const struct sw_flow_key *key, struct sk_buff *skb);
 void ovs_ct_free_action(const struct nlattr *a);
 
-static inline bool ovs_ct_state_supported(u32 state)
-{
-	return !(state & ~(OVS_CS_F_NEW | OVS_CS_F_ESTABLISHED |
-			 OVS_CS_F_RELATED | OVS_CS_F_REPLY_DIR |
-			 OVS_CS_F_INVALID | OVS_CS_F_TRACKED));
-}
+#define CT_SUPPORTED_MASK (OVS_CS_F_NEW | OVS_CS_F_ESTABLISHED | \
+			   OVS_CS_F_RELATED | OVS_CS_F_REPLY_DIR | \
+			   OVS_CS_F_INVALID | OVS_CS_F_TRACKED)
 #else
 #include <linux/errno.h>
 
@@ -53,11 +50,6 @@ static inline bool ovs_ct_verify(struct
 	return false;
 }
 
-static inline bool ovs_ct_state_supported(u32 state)
-{
-	return false;
-}
-
 static inline int ovs_ct_copy_action(struct net *net, const struct nlattr *nla,
 				     const struct sw_flow_key *key,
 				     struct sw_flow_actions **acts, bool log)
@@ -75,6 +67,7 @@ static inline int ovs_ct_execute(struct
 				 struct sw_flow_key *key,
 				 const struct ovs_conntrack_info *info)
 {
+	kfree_skb(skb);
 	return -ENOTSUPP;
 }
 
@@ -94,5 +87,7 @@ static inline int ovs_ct_put_key(const s
 }
 
 static inline void ovs_ct_free_action(const struct nlattr *a) { }
+
+#define CT_SUPPORTED_MASK 0
 #endif /* CONFIG_NF_CONNTRACK */
 #endif /* ovs_conntrack.h */
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/openvswitch/datapath.c linux-libre-4.3-gnu/net/openvswitch/datapath.c
--- linux-libre-4.3-rc7-gnu/net/openvswitch/datapath.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/openvswitch/datapath.c	2015-11-01 19:05:25.000000000 -0500
@@ -490,9 +490,8 @@ static int queue_userspace_packet(struct
 
 	if (upcall_info->egress_tun_info) {
 		nla = nla_nest_start(user_skb, OVS_PACKET_ATTR_EGRESS_TUN_KEY);
-		err = ovs_nla_put_egress_tunnel_key(user_skb,
-						    upcall_info->egress_tun_info,
-						    upcall_info->egress_tun_opts);
+		err = ovs_nla_put_tunnel_info(user_skb,
+					      upcall_info->egress_tun_info);
 		BUG_ON(err);
 		nla_nest_end(user_skb, nla);
 	}
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/openvswitch/datapath.h linux-libre-4.3-gnu/net/openvswitch/datapath.h
--- linux-libre-4.3-rc7-gnu/net/openvswitch/datapath.h	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/openvswitch/datapath.h	2015-11-01 19:05:25.000000000 -0500
@@ -117,7 +117,6 @@ struct ovs_skb_cb {
  */
 struct dp_upcall_info {
 	struct ip_tunnel_info *egress_tun_info;
-	const void *egress_tun_opts;
 	const struct nlattr *userdata;
 	const struct nlattr *actions;
 	int actions_len;
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/openvswitch/flow_netlink.c linux-libre-4.3-gnu/net/openvswitch/flow_netlink.c
--- linux-libre-4.3-rc7-gnu/net/openvswitch/flow_netlink.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/openvswitch/flow_netlink.c	2015-11-01 19:05:25.000000000 -0500
@@ -717,7 +717,7 @@ static int __ipv4_tun_to_nlattr(struct s
 	if ((output->tun_flags & TUNNEL_OAM) &&
 	    nla_put_flag(skb, OVS_TUNNEL_KEY_ATTR_OAM))
 		return -EMSGSIZE;
-	if (tun_opts) {
+	if (swkey_tun_opts_len) {
 		if (output->tun_flags & TUNNEL_GENEVE_OPT &&
 		    nla_put(skb, OVS_TUNNEL_KEY_ATTR_GENEVE_OPTS,
 			    swkey_tun_opts_len, tun_opts))
@@ -749,13 +749,12 @@ static int ipv4_tun_to_nlattr(struct sk_
 	return 0;
 }
 
-int ovs_nla_put_egress_tunnel_key(struct sk_buff *skb,
-				  const struct ip_tunnel_info *egress_tun_info,
-				  const void *egress_tun_opts)
+int ovs_nla_put_tunnel_info(struct sk_buff *skb,
+			    struct ip_tunnel_info *tun_info)
 {
-	return __ipv4_tun_to_nlattr(skb, &egress_tun_info->key,
-				    egress_tun_opts,
-				    egress_tun_info->options_len);
+	return __ipv4_tun_to_nlattr(skb, &tun_info->key,
+				    ip_tunnel_info_opts(tun_info),
+				    tun_info->options_len);
 }
 
 static int metadata_from_nlattrs(struct net *net, struct sw_flow_match *match,
@@ -816,7 +815,7 @@ static int metadata_from_nlattrs(struct
 	    ovs_ct_verify(net, OVS_KEY_ATTR_CT_STATE)) {
 		u32 ct_state = nla_get_u32(a[OVS_KEY_ATTR_CT_STATE]);
 
-		if (!is_mask && !ovs_ct_state_supported(ct_state)) {
+		if (ct_state & ~CT_SUPPORTED_MASK) {
 			OVS_NLERR(log, "ct_state flags %08x unsupported",
 				  ct_state);
 			return -EINVAL;
@@ -1099,6 +1098,9 @@ static void nlattr_set(struct nlattr *at
 		} else {
 			memset(nla_data(nla), val, nla_len(nla));
 		}
+
+		if (nla_type(nla) == OVS_KEY_ATTR_CT_STATE)
+			*(u32 *)nla_data(nla) &= CT_SUPPORTED_MASK;
 	}
 }
 
@@ -2380,10 +2382,7 @@ static int set_action_to_attr(const stru
 		if (!start)
 			return -EMSGSIZE;
 
-		err = ipv4_tun_to_nlattr(skb, &tun_info->key,
-					 tun_info->options_len ?
-					     ip_tunnel_info_opts(tun_info) : NULL,
-					 tun_info->options_len);
+		err = ovs_nla_put_tunnel_info(skb, tun_info);
 		if (err)
 			return err;
 		nla_nest_end(skb, start);
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/openvswitch/flow_netlink.h linux-libre-4.3-gnu/net/openvswitch/flow_netlink.h
--- linux-libre-4.3-rc7-gnu/net/openvswitch/flow_netlink.h	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/openvswitch/flow_netlink.h	2015-11-01 19:05:25.000000000 -0500
@@ -55,9 +55,9 @@ int ovs_nla_put_mask(const struct sw_flo
 int ovs_nla_get_match(struct net *, struct sw_flow_match *,
 		      const struct nlattr *key, const struct nlattr *mask,
 		      bool log);
-int ovs_nla_put_egress_tunnel_key(struct sk_buff *,
-				  const struct ip_tunnel_info *,
-				  const void *egress_tun_opts);
+
+int ovs_nla_put_tunnel_info(struct sk_buff *skb,
+			    struct ip_tunnel_info *tun_info);
 
 bool ovs_nla_get_ufid(struct sw_flow_id *, const struct nlattr *, bool log);
 int ovs_nla_get_identifier(struct sw_flow_id *sfid, const struct nlattr *ufid,
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/openvswitch/vport.c linux-libre-4.3-gnu/net/openvswitch/vport.c
--- linux-libre-4.3-rc7-gnu/net/openvswitch/vport.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/openvswitch/vport.c	2015-11-01 19:05:25.000000000 -0500
@@ -479,61 +479,3 @@ void ovs_vport_deferred_free(struct vpor
 	call_rcu(&vport->rcu, free_vport_rcu);
 }
 EXPORT_SYMBOL_GPL(ovs_vport_deferred_free);
-
-int ovs_tunnel_get_egress_info(struct dp_upcall_info *upcall,
-			       struct net *net,
-			       struct sk_buff *skb,
-			       u8 ipproto,
-			       __be16 tp_src,
-			       __be16 tp_dst)
-{
-	struct ip_tunnel_info *egress_tun_info = upcall->egress_tun_info;
-	const struct ip_tunnel_info *tun_info = skb_tunnel_info(skb);
-	const struct ip_tunnel_key *tun_key;
-	u32 skb_mark = skb->mark;
-	struct rtable *rt;
-	struct flowi4 fl;
-
-	if (unlikely(!tun_info))
-		return -EINVAL;
-	if (ip_tunnel_info_af(tun_info) != AF_INET)
-		return -EINVAL;
-
-	tun_key = &tun_info->key;
-
-	/* Route lookup to get srouce IP address.
-	 * The process may need to be changed if the corresponding process
-	 * in vports ops changed.
-	 */
-	rt = ovs_tunnel_route_lookup(net, tun_key, skb_mark, &fl, ipproto);
-	if (IS_ERR(rt))
-		return PTR_ERR(rt);
-
-	ip_rt_put(rt);
-
-	/* Generate egress_tun_info based on tun_info,
-	 * saddr, tp_src and tp_dst
-	 */
-	ip_tunnel_key_init(&egress_tun_info->key,
-			   fl.saddr, tun_key->u.ipv4.dst,
-			   tun_key->tos,
-			   tun_key->ttl,
-			   tp_src, tp_dst,
-			   tun_key->tun_id,
-			   tun_key->tun_flags);
-	egress_tun_info->options_len = tun_info->options_len;
-	egress_tun_info->mode = tun_info->mode;
-	upcall->egress_tun_opts = ip_tunnel_info_opts(egress_tun_info);
-	return 0;
-}
-EXPORT_SYMBOL_GPL(ovs_tunnel_get_egress_info);
-
-int ovs_vport_get_egress_tun_info(struct vport *vport, struct sk_buff *skb,
-				  struct dp_upcall_info *upcall)
-{
-	/* get_egress_tun_info() is only implemented on tunnel ports. */
-	if (unlikely(!vport->ops->get_egress_tun_info))
-		return -EINVAL;
-
-	return vport->ops->get_egress_tun_info(vport, skb, upcall);
-}
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/openvswitch/vport-geneve.c linux-libre-4.3-gnu/net/openvswitch/vport-geneve.c
--- linux-libre-4.3-rc7-gnu/net/openvswitch/vport-geneve.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/openvswitch/vport-geneve.c	2015-11-01 19:05:25.000000000 -0500
@@ -52,18 +52,6 @@ static int geneve_get_options(const stru
 	return 0;
 }
 
-static int geneve_get_egress_tun_info(struct vport *vport, struct sk_buff *skb,
-				      struct dp_upcall_info *upcall)
-{
-	struct geneve_port *geneve_port = geneve_vport(vport);
-	struct net *net = ovs_dp_get_net(vport->dp);
-	__be16 dport = htons(geneve_port->port_no);
-	__be16 sport = udp_flow_src_port(net, skb, 1, USHRT_MAX, true);
-
-	return ovs_tunnel_get_egress_info(upcall, ovs_dp_get_net(vport->dp),
-					  skb, IPPROTO_UDP, sport, dport);
-}
-
 static struct vport *geneve_tnl_create(const struct vport_parms *parms)
 {
 	struct net *net = ovs_dp_get_net(parms->dp);
@@ -130,7 +118,6 @@ static struct vport_ops ovs_geneve_vport
 	.get_options	= geneve_get_options,
 	.send		= ovs_netdev_send,
 	.owner          = THIS_MODULE,
-	.get_egress_tun_info	= geneve_get_egress_tun_info,
 };
 
 static int __init ovs_geneve_tnl_init(void)
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/openvswitch/vport-gre.c linux-libre-4.3-gnu/net/openvswitch/vport-gre.c
--- linux-libre-4.3-rc7-gnu/net/openvswitch/vport-gre.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/openvswitch/vport-gre.c	2015-11-01 19:05:25.000000000 -0500
@@ -84,18 +84,10 @@ static struct vport *gre_create(const st
 	return ovs_netdev_link(vport, parms->name);
 }
 
-static int gre_get_egress_tun_info(struct vport *vport, struct sk_buff *skb,
-				   struct dp_upcall_info *upcall)
-{
-	return ovs_tunnel_get_egress_info(upcall, ovs_dp_get_net(vport->dp),
-					  skb, IPPROTO_GRE, 0, 0);
-}
-
 static struct vport_ops ovs_gre_vport_ops = {
 	.type		= OVS_VPORT_TYPE_GRE,
 	.create		= gre_create,
 	.send		= ovs_netdev_send,
-	.get_egress_tun_info	= gre_get_egress_tun_info,
 	.destroy	= ovs_netdev_tunnel_destroy,
 	.owner		= THIS_MODULE,
 };
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/openvswitch/vport.h linux-libre-4.3-gnu/net/openvswitch/vport.h
--- linux-libre-4.3-rc7-gnu/net/openvswitch/vport.h	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/openvswitch/vport.h	2015-11-01 19:05:25.000000000 -0500
@@ -27,7 +27,6 @@
 #include <linux/skbuff.h>
 #include <linux/spinlock.h>
 #include <linux/u64_stats_sync.h>
-#include <net/route.h>
 
 #include "datapath.h"
 
@@ -53,16 +52,6 @@ int ovs_vport_set_upcall_portids(struct
 int ovs_vport_get_upcall_portids(const struct vport *, struct sk_buff *);
 u32 ovs_vport_find_upcall_portid(const struct vport *, struct sk_buff *);
 
-int ovs_tunnel_get_egress_info(struct dp_upcall_info *upcall,
-			       struct net *net,
-			       struct sk_buff *,
-			       u8 ipproto,
-			       __be16 tp_src,
-			       __be16 tp_dst);
-
-int ovs_vport_get_egress_tun_info(struct vport *vport, struct sk_buff *skb,
-				  struct dp_upcall_info *upcall);
-
 /**
  * struct vport_portids - array of netlink portids of a vport.
  *                        must be protected by rcu.
@@ -140,8 +129,6 @@ struct vport_parms {
  * have any configuration.
  * @send: Send a packet on the device.
  * zero for dropped packets or negative for error.
- * @get_egress_tun_info: Get the egress tunnel 5-tuple and other info for
- * a packet.
  */
 struct vport_ops {
 	enum ovs_vport_type type;
@@ -154,9 +141,6 @@ struct vport_ops {
 	int (*get_options)(const struct vport *, struct sk_buff *);
 
 	void (*send)(struct vport *, struct sk_buff *);
-	int (*get_egress_tun_info)(struct vport *, struct sk_buff *,
-				   struct dp_upcall_info *upcall);
-
 	struct module *owner;
 	struct list_head list;
 };
@@ -215,25 +199,6 @@ static inline const char *ovs_vport_name
 int ovs_vport_ops_register(struct vport_ops *ops);
 void ovs_vport_ops_unregister(struct vport_ops *ops);
 
-static inline struct rtable *ovs_tunnel_route_lookup(struct net *net,
-						     const struct ip_tunnel_key *key,
-						     u32 mark,
-						     struct flowi4 *fl,
-						     u8 protocol)
-{
-	struct rtable *rt;
-
-	memset(fl, 0, sizeof(*fl));
-	fl->daddr = key->u.ipv4.dst;
-	fl->saddr = key->u.ipv4.src;
-	fl->flowi4_tos = RT_TOS(key->tos);
-	fl->flowi4_mark = mark;
-	fl->flowi4_proto = protocol;
-
-	rt = ip_route_output_key(net, fl);
-	return rt;
-}
-
 static inline void ovs_vport_send(struct vport *vport, struct sk_buff *skb)
 {
 	vport->ops->send(vport, skb);
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/openvswitch/vport-internal_dev.c linux-libre-4.3-gnu/net/openvswitch/vport-internal_dev.c
--- linux-libre-4.3-rc7-gnu/net/openvswitch/vport-internal_dev.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/openvswitch/vport-internal_dev.c	2015-11-01 19:05:25.000000000 -0500
@@ -106,12 +106,45 @@ static void internal_dev_destructor(stru
 	free_netdev(dev);
 }
 
+static struct rtnl_link_stats64 *
+internal_get_stats(struct net_device *dev, struct rtnl_link_stats64 *stats)
+{
+	int i;
+
+	memset(stats, 0, sizeof(*stats));
+	stats->rx_errors  = dev->stats.rx_errors;
+	stats->tx_errors  = dev->stats.tx_errors;
+	stats->tx_dropped = dev->stats.tx_dropped;
+	stats->rx_dropped = dev->stats.rx_dropped;
+
+	for_each_possible_cpu(i) {
+		const struct pcpu_sw_netstats *percpu_stats;
+		struct pcpu_sw_netstats local_stats;
+		unsigned int start;
+
+		percpu_stats = per_cpu_ptr(dev->tstats, i);
+
+		do {
+			start = u64_stats_fetch_begin_irq(&percpu_stats->syncp);
+			local_stats = *percpu_stats;
+		} while (u64_stats_fetch_retry_irq(&percpu_stats->syncp, start));
+
+		stats->rx_bytes         += local_stats.rx_bytes;
+		stats->rx_packets       += local_stats.rx_packets;
+		stats->tx_bytes         += local_stats.tx_bytes;
+		stats->tx_packets       += local_stats.tx_packets;
+	}
+
+	return stats;
+}
+
 static const struct net_device_ops internal_dev_netdev_ops = {
 	.ndo_open = internal_dev_open,
 	.ndo_stop = internal_dev_stop,
 	.ndo_start_xmit = internal_dev_xmit,
 	.ndo_set_mac_address = eth_mac_addr,
 	.ndo_change_mtu = internal_dev_change_mtu,
+	.ndo_get_stats64 = internal_get_stats,
 };
 
 static struct rtnl_link_ops internal_dev_link_ops __read_mostly = {
@@ -161,6 +194,11 @@ static struct vport *internal_dev_create
 		err = -ENOMEM;
 		goto error_free_vport;
 	}
+	vport->dev->tstats = netdev_alloc_pcpu_stats(struct pcpu_sw_netstats);
+	if (!vport->dev->tstats) {
+		err = -ENOMEM;
+		goto error_free_netdev;
+	}
 
 	dev_net_set(vport->dev, ovs_dp_get_net(vport->dp));
 	internal_dev = internal_dev_priv(vport->dev);
@@ -173,7 +211,7 @@ static struct vport *internal_dev_create
 	rtnl_lock();
 	err = register_netdevice(vport->dev);
 	if (err)
-		goto error_free_netdev;
+		goto error_unlock;
 
 	dev_set_promiscuity(vport->dev, 1);
 	rtnl_unlock();
@@ -181,8 +219,10 @@ static struct vport *internal_dev_create
 
 	return vport;
 
-error_free_netdev:
+error_unlock:
 	rtnl_unlock();
+	free_percpu(vport->dev->tstats);
+error_free_netdev:
 	free_netdev(vport->dev);
 error_free_vport:
 	ovs_vport_free(vport);
@@ -198,7 +238,7 @@ static void internal_dev_destroy(struct
 
 	/* unregister_netdevice() waits for an RCU grace period. */
 	unregister_netdevice(vport->dev);
-
+	free_percpu(vport->dev->tstats);
 	rtnl_unlock();
 }
 
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/openvswitch/vport-vxlan.c linux-libre-4.3-gnu/net/openvswitch/vport-vxlan.c
--- linux-libre-4.3-rc7-gnu/net/openvswitch/vport-vxlan.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/openvswitch/vport-vxlan.c	2015-11-01 19:05:25.000000000 -0500
@@ -146,31 +146,12 @@ static struct vport *vxlan_create(const
 	return ovs_netdev_link(vport, parms->name);
 }
 
-static int vxlan_get_egress_tun_info(struct vport *vport, struct sk_buff *skb,
-				     struct dp_upcall_info *upcall)
-{
-	struct vxlan_dev *vxlan = netdev_priv(vport->dev);
-	struct net *net = ovs_dp_get_net(vport->dp);
-	__be16 dst_port = vxlan_dev_dst_port(vxlan);
-	__be16 src_port;
-	int port_min;
-	int port_max;
-
-	inet_get_local_port_range(net, &port_min, &port_max);
-	src_port = udp_flow_src_port(net, skb, 0, 0, true);
-
-	return ovs_tunnel_get_egress_info(upcall, net,
-					  skb, IPPROTO_UDP,
-					  src_port, dst_port);
-}
-
 static struct vport_ops ovs_vxlan_netdev_vport_ops = {
 	.type			= OVS_VPORT_TYPE_VXLAN,
 	.create			= vxlan_create,
 	.destroy		= ovs_netdev_tunnel_destroy,
 	.get_options		= vxlan_get_options,
 	.send			= ovs_netdev_send,
-	.get_egress_tun_info	= vxlan_get_egress_tun_info,
 };
 
 static int __init ovs_vxlan_tnl_init(void)
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/rds/tcp_recv.c linux-libre-4.3-gnu/net/rds/tcp_recv.c
--- linux-libre-4.3-rc7-gnu/net/rds/tcp_recv.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/rds/tcp_recv.c	2015-11-01 19:05:25.000000000 -0500
@@ -214,8 +214,15 @@ static int rds_tcp_data_recv(read_descri
 			}
 
 			to_copy = min(tc->t_tinc_data_rem, left);
-			pskb_pull(clone, offset);
-			pskb_trim(clone, to_copy);
+			if (!pskb_pull(clone, offset) ||
+			    pskb_trim(clone, to_copy)) {
+				pr_warn("rds_tcp_data_recv: pull/trim failed "
+					"left %zu data_rem %zu skb_len %d\n",
+					left, tc->t_tinc_data_rem, skb->len);
+				kfree_skb(clone);
+				desc->error = -ENOMEM;
+				goto out;
+			}
 			skb_queue_tail(&tinc->ti_skb_list, clone);
 
 			rdsdebug("skb %p data %p len %d off %u to_copy %zu -> "
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/sysctl_net.c linux-libre-4.3-gnu/net/sysctl_net.c
--- linux-libre-4.3-rc7-gnu/net/sysctl_net.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/sysctl_net.c	2015-11-01 19:05:25.000000000 -0500
@@ -94,10 +94,14 @@ __init int net_sysctl_init(void)
 		goto out;
 	ret = register_pernet_subsys(&sysctl_pernet_ops);
 	if (ret)
-		goto out;
+		goto out1;
 	register_sysctl_root(&net_sysctl_root);
 out:
 	return ret;
+out1:
+	unregister_sysctl_table(net_header);
+	net_header = NULL;
+	goto out;
 }
 
 struct ctl_table_header *register_net_sysctl(struct net *net,
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/tipc/bcast.c linux-libre-4.3-gnu/net/tipc/bcast.c
--- linux-libre-4.3-rc7-gnu/net/tipc/bcast.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/tipc/bcast.c	2015-11-01 19:05:25.000000000 -0500
@@ -42,7 +42,8 @@
 #include "core.h"
 
 #define	MAX_PKT_DEFAULT_MCAST	1500	/* bcast link max packet size (fixed) */
-#define	BCLINK_WIN_DEFAULT	20	/* bcast link window size (default) */
+#define	BCLINK_WIN_DEFAULT	50	/* bcast link window size (default) */
+#define	BCLINK_WIN_MIN	        32	/* bcast minimum link window size */
 
 const char tipc_bclink_name[] = "broadcast-link";
 
@@ -908,9 +909,10 @@ int tipc_bclink_set_queue_limits(struct
 
 	if (!bcl)
 		return -ENOPROTOOPT;
-	if ((limit < TIPC_MIN_LINK_WIN) || (limit > TIPC_MAX_LINK_WIN))
+	if (limit < BCLINK_WIN_MIN)
+		limit = BCLINK_WIN_MIN;
+	if (limit > TIPC_MAX_LINK_WIN)
 		return -EINVAL;
-
 	tipc_bclink_lock(net);
 	tipc_link_set_queue_limits(bcl, limit);
 	tipc_bclink_unlock(net);
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/tipc/msg.c linux-libre-4.3-gnu/net/tipc/msg.c
--- linux-libre-4.3-rc7-gnu/net/tipc/msg.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/tipc/msg.c	2015-11-01 19:05:25.000000000 -0500
@@ -121,7 +121,7 @@ int tipc_buf_append(struct sk_buff **hea
 {
 	struct sk_buff *head = *headbuf;
 	struct sk_buff *frag = *buf;
-	struct sk_buff *tail;
+	struct sk_buff *tail = NULL;
 	struct tipc_msg *msg;
 	u32 fragid;
 	int delta;
@@ -141,9 +141,15 @@ int tipc_buf_append(struct sk_buff **hea
 		if (unlikely(skb_unclone(frag, GFP_ATOMIC)))
 			goto err;
 		head = *headbuf = frag;
-		skb_frag_list_init(head);
-		TIPC_SKB_CB(head)->tail = NULL;
 		*buf = NULL;
+		TIPC_SKB_CB(head)->tail = NULL;
+		if (skb_is_nonlinear(head)) {
+			skb_walk_frags(head, tail) {
+				TIPC_SKB_CB(head)->tail = tail;
+			}
+		} else {
+			skb_frag_list_init(head);
+		}
 		return 0;
 	}
 
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/tipc/udp_media.c linux-libre-4.3-gnu/net/tipc/udp_media.c
--- linux-libre-4.3-rc7-gnu/net/tipc/udp_media.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/tipc/udp_media.c	2015-11-01 19:05:25.000000000 -0500
@@ -52,6 +52,8 @@
 /* IANA assigned UDP port */
 #define UDP_PORT_DEFAULT	6118
 
+#define UDP_MIN_HEADROOM        28
+
 static const struct nla_policy tipc_nl_udp_policy[TIPC_NLA_UDP_MAX + 1] = {
 	[TIPC_NLA_UDP_UNSPEC]	= {.type = NLA_UNSPEC},
 	[TIPC_NLA_UDP_LOCAL]	= {.type = NLA_BINARY,
@@ -156,6 +158,9 @@ static int tipc_udp_send_msg(struct net
 	struct sk_buff *clone;
 	struct rtable *rt;
 
+	if (skb_headroom(skb) < UDP_MIN_HEADROOM)
+		pskb_expand_head(skb, UDP_MIN_HEADROOM, 0, GFP_ATOMIC);
+
 	clone = skb_clone(skb, GFP_ATOMIC);
 	skb_set_inner_protocol(clone, htons(ETH_P_TIPC));
 	ub = rcu_dereference_rtnl(b->media_ptr);
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/vmw_vsock/af_vsock.c linux-libre-4.3-gnu/net/vmw_vsock/af_vsock.c
--- linux-libre-4.3-rc7-gnu/net/vmw_vsock/af_vsock.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/vmw_vsock/af_vsock.c	2015-11-01 19:05:25.000000000 -0500
@@ -1948,13 +1948,13 @@ int __vsock_core_init(const struct vsock
 	err = misc_register(&vsock_device);
 	if (err) {
 		pr_err("Failed to register misc device\n");
-		return -ENOENT;
+		goto err_reset_transport;
 	}
 
 	err = proto_register(&vsock_proto, 1);	/* we want our slab */
 	if (err) {
 		pr_err("Cannot register vsock protocol\n");
-		goto err_misc_deregister;
+		goto err_deregister_misc;
 	}
 
 	err = sock_register(&vsock_family_ops);
@@ -1969,8 +1969,9 @@ int __vsock_core_init(const struct vsock
 
 err_unregister_proto:
 	proto_unregister(&vsock_proto);
-err_misc_deregister:
+err_deregister_misc:
 	misc_deregister(&vsock_device);
+err_reset_transport:
 	transport = NULL;
 err_busy:
 	mutex_unlock(&vsock_register_mutex);
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/vmw_vsock/vmci_transport.c linux-libre-4.3-gnu/net/vmw_vsock/vmci_transport.c
--- linux-libre-4.3-rc7-gnu/net/vmw_vsock/vmci_transport.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/vmw_vsock/vmci_transport.c	2015-11-01 19:05:25.000000000 -0500
@@ -40,13 +40,11 @@
 
 static int vmci_transport_recv_dgram_cb(void *data, struct vmci_datagram *dg);
 static int vmci_transport_recv_stream_cb(void *data, struct vmci_datagram *dg);
-static void vmci_transport_peer_attach_cb(u32 sub_id,
-					  const struct vmci_event_data *ed,
-					  void *client_data);
 static void vmci_transport_peer_detach_cb(u32 sub_id,
 					  const struct vmci_event_data *ed,
 					  void *client_data);
 static void vmci_transport_recv_pkt_work(struct work_struct *work);
+static void vmci_transport_cleanup(struct work_struct *work);
 static int vmci_transport_recv_listen(struct sock *sk,
 				      struct vmci_transport_packet *pkt);
 static int vmci_transport_recv_connecting_server(
@@ -75,6 +73,10 @@ struct vmci_transport_recv_pkt_info {
 	struct vmci_transport_packet pkt;
 };
 
+static LIST_HEAD(vmci_transport_cleanup_list);
+static DEFINE_SPINLOCK(vmci_transport_cleanup_lock);
+static DECLARE_WORK(vmci_transport_cleanup_work, vmci_transport_cleanup);
+
 static struct vmci_handle vmci_transport_stream_handle = { VMCI_INVALID_ID,
 							   VMCI_INVALID_ID };
 static u32 vmci_transport_qp_resumed_sub_id = VMCI_INVALID_ID;
@@ -791,44 +793,6 @@ out:
 	return err;
 }
 
-static void vmci_transport_peer_attach_cb(u32 sub_id,
-					  const struct vmci_event_data *e_data,
-					  void *client_data)
-{
-	struct sock *sk = client_data;
-	const struct vmci_event_payload_qp *e_payload;
-	struct vsock_sock *vsk;
-
-	e_payload = vmci_event_data_const_payload(e_data);
-
-	vsk = vsock_sk(sk);
-
-	/* We don't ask for delayed CBs when we subscribe to this event (we
-	 * pass 0 as flags to vmci_event_subscribe()).  VMCI makes no
-	 * guarantees in that case about what context we might be running in,
-	 * so it could be BH or process, blockable or non-blockable.  So we
-	 * need to account for all possible contexts here.
-	 */
-	local_bh_disable();
-	bh_lock_sock(sk);
-
-	/* XXX This is lame, we should provide a way to lookup sockets by
-	 * qp_handle.
-	 */
-	if (vmci_handle_is_equal(vmci_trans(vsk)->qp_handle,
-				 e_payload->handle)) {
-		/* XXX This doesn't do anything, but in the future we may want
-		 * to set a flag here to verify the attach really did occur and
-		 * we weren't just sent a datagram claiming it was.
-		 */
-		goto out;
-	}
-
-out:
-	bh_unlock_sock(sk);
-	local_bh_enable();
-}
-
 static void vmci_transport_handle_detach(struct sock *sk)
 {
 	struct vsock_sock *vsk;
@@ -871,28 +835,38 @@ static void vmci_transport_peer_detach_c
 					  const struct vmci_event_data *e_data,
 					  void *client_data)
 {
-	struct sock *sk = client_data;
+	struct vmci_transport *trans = client_data;
 	const struct vmci_event_payload_qp *e_payload;
-	struct vsock_sock *vsk;
 
 	e_payload = vmci_event_data_const_payload(e_data);
-	vsk = vsock_sk(sk);
-	if (vmci_handle_is_invalid(e_payload->handle))
-		return;
-
-	/* Same rules for locking as for peer_attach_cb(). */
-	local_bh_disable();
-	bh_lock_sock(sk);
 
 	/* XXX This is lame, we should provide a way to lookup sockets by
 	 * qp_handle.
 	 */
-	if (vmci_handle_is_equal(vmci_trans(vsk)->qp_handle,
-				 e_payload->handle))
-		vmci_transport_handle_detach(sk);
+	if (vmci_handle_is_invalid(e_payload->handle) ||
+	    vmci_handle_is_equal(trans->qp_handle, e_payload->handle))
+		return;
 
-	bh_unlock_sock(sk);
-	local_bh_enable();
+	/* We don't ask for delayed CBs when we subscribe to this event (we
+	 * pass 0 as flags to vmci_event_subscribe()).  VMCI makes no
+	 * guarantees in that case about what context we might be running in,
+	 * so it could be BH or process, blockable or non-blockable.  So we
+	 * need to account for all possible contexts here.
+	 */
+	spin_lock_bh(&trans->lock);
+	if (!trans->sk)
+		goto out;
+
+	/* Apart from here, trans->lock is only grabbed as part of sk destruct,
+	 * where trans->sk isn't locked.
+	 */
+	bh_lock_sock(trans->sk);
+
+	vmci_transport_handle_detach(trans->sk);
+
+	bh_unlock_sock(trans->sk);
+ out:
+	spin_unlock_bh(&trans->lock);
 }
 
 static void vmci_transport_qp_resumed_cb(u32 sub_id,
@@ -1181,7 +1155,7 @@ vmci_transport_recv_connecting_server(st
 	 */
 	err = vmci_event_subscribe(VMCI_EVENT_QP_PEER_DETACH,
 				   vmci_transport_peer_detach_cb,
-				   pending, &detach_sub_id);
+				   vmci_trans(vpending), &detach_sub_id);
 	if (err < VMCI_SUCCESS) {
 		vmci_transport_send_reset(pending, pkt);
 		err = vmci_transport_error_to_vsock_error(err);
@@ -1321,7 +1295,6 @@ vmci_transport_recv_connecting_client(st
 		    || vmci_trans(vsk)->qpair
 		    || vmci_trans(vsk)->produce_size != 0
 		    || vmci_trans(vsk)->consume_size != 0
-		    || vmci_trans(vsk)->attach_sub_id != VMCI_INVALID_ID
 		    || vmci_trans(vsk)->detach_sub_id != VMCI_INVALID_ID) {
 			skerr = EPROTO;
 			err = -EINVAL;
@@ -1389,7 +1362,6 @@ static int vmci_transport_recv_connectin
 	struct vsock_sock *vsk;
 	struct vmci_handle handle;
 	struct vmci_qp *qpair;
-	u32 attach_sub_id;
 	u32 detach_sub_id;
 	bool is_local;
 	u32 flags;
@@ -1399,7 +1371,6 @@ static int vmci_transport_recv_connectin
 
 	vsk = vsock_sk(sk);
 	handle = VMCI_INVALID_HANDLE;
-	attach_sub_id = VMCI_INVALID_ID;
 	detach_sub_id = VMCI_INVALID_ID;
 
 	/* If we have gotten here then we should be past the point where old
@@ -1444,23 +1415,15 @@ static int vmci_transport_recv_connectin
 		goto destroy;
 	}
 
-	/* Subscribe to attach and detach events first.
+	/* Subscribe to detach events first.
 	 *
 	 * XXX We attach once for each queue pair created for now so it is easy
 	 * to find the socket (it's provided), but later we should only
 	 * subscribe once and add a way to lookup sockets by queue pair handle.
 	 */
-	err = vmci_event_subscribe(VMCI_EVENT_QP_PEER_ATTACH,
-				   vmci_transport_peer_attach_cb,
-				   sk, &attach_sub_id);
-	if (err < VMCI_SUCCESS) {
-		err = vmci_transport_error_to_vsock_error(err);
-		goto destroy;
-	}
-
 	err = vmci_event_subscribe(VMCI_EVENT_QP_PEER_DETACH,
 				   vmci_transport_peer_detach_cb,
-				   sk, &detach_sub_id);
+				   vmci_trans(vsk), &detach_sub_id);
 	if (err < VMCI_SUCCESS) {
 		err = vmci_transport_error_to_vsock_error(err);
 		goto destroy;
@@ -1496,7 +1459,6 @@ static int vmci_transport_recv_connectin
 	vmci_trans(vsk)->produce_size = vmci_trans(vsk)->consume_size =
 		pkt->u.size;
 
-	vmci_trans(vsk)->attach_sub_id = attach_sub_id;
 	vmci_trans(vsk)->detach_sub_id = detach_sub_id;
 
 	vmci_trans(vsk)->notify_ops->process_negotiate(sk);
@@ -1504,9 +1466,6 @@ static int vmci_transport_recv_connectin
 	return 0;
 
 destroy:
-	if (attach_sub_id != VMCI_INVALID_ID)
-		vmci_event_unsubscribe(attach_sub_id);
-
 	if (detach_sub_id != VMCI_INVALID_ID)
 		vmci_event_unsubscribe(detach_sub_id);
 
@@ -1607,9 +1566,11 @@ static int vmci_transport_socket_init(st
 	vmci_trans(vsk)->qp_handle = VMCI_INVALID_HANDLE;
 	vmci_trans(vsk)->qpair = NULL;
 	vmci_trans(vsk)->produce_size = vmci_trans(vsk)->consume_size = 0;
-	vmci_trans(vsk)->attach_sub_id = vmci_trans(vsk)->detach_sub_id =
-		VMCI_INVALID_ID;
+	vmci_trans(vsk)->detach_sub_id = VMCI_INVALID_ID;
 	vmci_trans(vsk)->notify_ops = NULL;
+	INIT_LIST_HEAD(&vmci_trans(vsk)->elem);
+	vmci_trans(vsk)->sk = &vsk->sk;
+	spin_lock_init(&vmci_trans(vsk)->lock);
 	if (psk) {
 		vmci_trans(vsk)->queue_pair_size =
 			vmci_trans(psk)->queue_pair_size;
@@ -1629,29 +1590,57 @@ static int vmci_transport_socket_init(st
 	return 0;
 }
 
-static void vmci_transport_destruct(struct vsock_sock *vsk)
+static void vmci_transport_free_resources(struct list_head *transport_list)
 {
-	if (vmci_trans(vsk)->attach_sub_id != VMCI_INVALID_ID) {
-		vmci_event_unsubscribe(vmci_trans(vsk)->attach_sub_id);
-		vmci_trans(vsk)->attach_sub_id = VMCI_INVALID_ID;
-	}
+	while (!list_empty(transport_list)) {
+		struct vmci_transport *transport =
+		    list_first_entry(transport_list, struct vmci_transport,
+				     elem);
+		list_del(&transport->elem);
 
-	if (vmci_trans(vsk)->detach_sub_id != VMCI_INVALID_ID) {
-		vmci_event_unsubscribe(vmci_trans(vsk)->detach_sub_id);
-		vmci_trans(vsk)->detach_sub_id = VMCI_INVALID_ID;
-	}
+		if (transport->detach_sub_id != VMCI_INVALID_ID) {
+			vmci_event_unsubscribe(transport->detach_sub_id);
+			transport->detach_sub_id = VMCI_INVALID_ID;
+		}
 
-	if (!vmci_handle_is_invalid(vmci_trans(vsk)->qp_handle)) {
-		vmci_qpair_detach(&vmci_trans(vsk)->qpair);
-		vmci_trans(vsk)->qp_handle = VMCI_INVALID_HANDLE;
-		vmci_trans(vsk)->produce_size = 0;
-		vmci_trans(vsk)->consume_size = 0;
+		if (!vmci_handle_is_invalid(transport->qp_handle)) {
+			vmci_qpair_detach(&transport->qpair);
+			transport->qp_handle = VMCI_INVALID_HANDLE;
+			transport->produce_size = 0;
+			transport->consume_size = 0;
+		}
+
+		kfree(transport);
 	}
+}
+
+static void vmci_transport_cleanup(struct work_struct *work)
+{
+	LIST_HEAD(pending);
+
+	spin_lock_bh(&vmci_transport_cleanup_lock);
+	list_replace_init(&vmci_transport_cleanup_list, &pending);
+	spin_unlock_bh(&vmci_transport_cleanup_lock);
+	vmci_transport_free_resources(&pending);
+}
+
+static void vmci_transport_destruct(struct vsock_sock *vsk)
+{
+	/* Ensure that the detach callback doesn't use the sk/vsk
+	 * we are about to destruct.
+	 */
+	spin_lock_bh(&vmci_trans(vsk)->lock);
+	vmci_trans(vsk)->sk = NULL;
+	spin_unlock_bh(&vmci_trans(vsk)->lock);
 
 	if (vmci_trans(vsk)->notify_ops)
 		vmci_trans(vsk)->notify_ops->socket_destruct(vsk);
 
-	kfree(vsk->trans);
+	spin_lock_bh(&vmci_transport_cleanup_lock);
+	list_add(&vmci_trans(vsk)->elem, &vmci_transport_cleanup_list);
+	spin_unlock_bh(&vmci_transport_cleanup_lock);
+	schedule_work(&vmci_transport_cleanup_work);
+
 	vsk->trans = NULL;
 }
 
@@ -2146,6 +2135,9 @@ module_init(vmci_transport_init);
 
 static void __exit vmci_transport_exit(void)
 {
+	cancel_work_sync(&vmci_transport_cleanup_work);
+	vmci_transport_free_resources(&vmci_transport_cleanup_list);
+
 	if (!vmci_handle_is_invalid(vmci_transport_stream_handle)) {
 		if (vmci_datagram_destroy_handle(
 			vmci_transport_stream_handle) != VMCI_SUCCESS)
@@ -2164,6 +2156,7 @@ module_exit(vmci_transport_exit);
 
 MODULE_AUTHOR("VMware, Inc.");
 MODULE_DESCRIPTION("VMCI transport for Virtual Sockets");
+MODULE_VERSION("1.0.2.0-k");
 MODULE_LICENSE("GPL v2");
 MODULE_ALIAS("vmware_vsock");
 MODULE_ALIAS_NETPROTO(PF_VSOCK);
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/vmw_vsock/vmci_transport.h linux-libre-4.3-gnu/net/vmw_vsock/vmci_transport.h
--- linux-libre-4.3-rc7-gnu/net/vmw_vsock/vmci_transport.h	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/vmw_vsock/vmci_transport.h	2015-11-01 19:05:25.000000000 -0500
@@ -119,10 +119,12 @@ struct vmci_transport {
 	u64 queue_pair_size;
 	u64 queue_pair_min_size;
 	u64 queue_pair_max_size;
-	u32 attach_sub_id;
 	u32 detach_sub_id;
 	union vmci_transport_notify notify;
 	struct vmci_transport_notify_ops *notify_ops;
+	struct list_head elem;
+	struct sock *sk;
+	spinlock_t lock; /* protects sk. */
 };
 
 int vmci_transport_register(void);
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/net/xfrm/xfrm_user.c linux-libre-4.3-gnu/net/xfrm/xfrm_user.c
--- linux-libre-4.3-rc7-gnu/net/xfrm/xfrm_user.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/net/xfrm/xfrm_user.c	2015-11-01 19:05:25.000000000 -0500
@@ -1928,8 +1928,10 @@ static int xfrm_new_ae(struct sk_buff *s
 	struct nlattr *rp = attrs[XFRMA_REPLAY_VAL];
 	struct nlattr *re = attrs[XFRMA_REPLAY_ESN_VAL];
 	struct nlattr *lt = attrs[XFRMA_LTIME_VAL];
+	struct nlattr *et = attrs[XFRMA_ETIMER_THRESH];
+	struct nlattr *rt = attrs[XFRMA_REPLAY_THRESH];
 
-	if (!lt && !rp && !re)
+	if (!lt && !rp && !re && !et && !rt)
 		return err;
 
 	/* pedantic mode - thou shalt sayeth replaceth */
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/samples/bpf/bpf_helpers.h linux-libre-4.3-gnu/samples/bpf/bpf_helpers.h
--- linux-libre-4.3-rc7-gnu/samples/bpf/bpf_helpers.h	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/samples/bpf/bpf_helpers.h	2015-11-01 19:05:25.000000000 -0500
@@ -86,5 +86,17 @@ static int (*bpf_l4_csum_replace)(void *
 #define PT_REGS_RC(x) ((x)->gprs[2])
 #define PT_REGS_SP(x) ((x)->gprs[15])
 
+#elif defined(__aarch64__)
+
+#define PT_REGS_PARM1(x) ((x)->regs[0])
+#define PT_REGS_PARM2(x) ((x)->regs[1])
+#define PT_REGS_PARM3(x) ((x)->regs[2])
+#define PT_REGS_PARM4(x) ((x)->regs[3])
+#define PT_REGS_PARM5(x) ((x)->regs[4])
+#define PT_REGS_RET(x) ((x)->regs[30])
+#define PT_REGS_FP(x) ((x)->regs[29]) /* Works only with CONFIG_FRAME_POINTER */
+#define PT_REGS_RC(x) ((x)->regs[0])
+#define PT_REGS_SP(x) ((x)->sp)
+
 #endif
 #endif
diff -druNp --no-dereference linux-libre-4.3-rc7-gnu/tools/testing/selftests/x86/entry_from_vm86.c linux-libre-4.3-gnu/tools/testing/selftests/x86/entry_from_vm86.c
--- linux-libre-4.3-rc7-gnu/tools/testing/selftests/x86/entry_from_vm86.c	2015-10-24 21:39:47.000000000 -0400
+++ linux-libre-4.3-gnu/tools/testing/selftests/x86/entry_from_vm86.c	2015-11-01 19:05:25.000000000 -0500
@@ -230,5 +230,9 @@ int main(void)
 	}
 	clearhandler(SIGSEGV);
 
+	/* Make sure nothing explodes if we fork. */
+	if (fork() > 0)
+		return 0;
+
 	return (nerrs == 0 ? 0 : 1);
 }
