diff -druNp --no-dereference linux-libre-4.14.27-gnu/arch/arm/boot/dts/am335x-pepper.dts linux-libre-4.14.28-gnu/arch/arm/boot/dts/am335x-pepper.dts
--- linux-libre-4.14.27-gnu/arch/arm/boot/dts/am335x-pepper.dts	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/arch/arm/boot/dts/am335x-pepper.dts	2018-03-19 03:42:57.000000000 -0400
@@ -139,7 +139,7 @@
 &audio_codec {
 	status = "okay";
 
-	gpio-reset = <&gpio1 16 GPIO_ACTIVE_LOW>;
+	reset-gpios = <&gpio1 16 GPIO_ACTIVE_LOW>;
 	AVDD-supply = <&ldo3_reg>;
 	IOVDD-supply = <&ldo3_reg>;
 	DRVDD-supply = <&ldo3_reg>;
diff -druNp --no-dereference linux-libre-4.14.27-gnu/arch/arm/boot/dts/exynos4412-trats2.dts linux-libre-4.14.28-gnu/arch/arm/boot/dts/exynos4412-trats2.dts
--- linux-libre-4.14.27-gnu/arch/arm/boot/dts/exynos4412-trats2.dts	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/arch/arm/boot/dts/exynos4412-trats2.dts	2018-03-19 03:42:57.000000000 -0400
@@ -395,7 +395,7 @@
 		reg = <0>;
 		vdd3-supply = <&lcd_vdd3_reg>;
 		vci-supply = <&ldo25_reg>;
-		reset-gpios = <&gpy4 5 GPIO_ACTIVE_HIGH>;
+		reset-gpios = <&gpf2 1 GPIO_ACTIVE_HIGH>;
 		power-on-delay= <50>;
 		reset-delay = <100>;
 		init-delay = <100>;
diff -druNp --no-dereference linux-libre-4.14.27-gnu/arch/arm/boot/dts/omap3-n900.dts linux-libre-4.14.28-gnu/arch/arm/boot/dts/omap3-n900.dts
--- linux-libre-4.14.27-gnu/arch/arm/boot/dts/omap3-n900.dts	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/arch/arm/boot/dts/omap3-n900.dts	2018-03-19 03:42:57.000000000 -0400
@@ -558,7 +558,7 @@
 	tlv320aic3x: tlv320aic3x@18 {
 		compatible = "ti,tlv320aic3x";
 		reg = <0x18>;
-		gpio-reset = <&gpio2 28 GPIO_ACTIVE_HIGH>; /* 60 */
+		reset-gpios = <&gpio2 28 GPIO_ACTIVE_LOW>; /* 60 */
 		ai3x-gpio-func = <
 			0 /* AIC3X_GPIO1_FUNC_DISABLED */
 			5 /* AIC3X_GPIO2_FUNC_DIGITAL_MIC_INPUT */
@@ -575,7 +575,7 @@
 	tlv320aic3x_aux: tlv320aic3x@19 {
 		compatible = "ti,tlv320aic3x";
 		reg = <0x19>;
-		gpio-reset = <&gpio2 28 GPIO_ACTIVE_HIGH>; /* 60 */
+		reset-gpios = <&gpio2 28 GPIO_ACTIVE_LOW>; /* 60 */
 
 		AVDD-supply = <&vmmc2>;
 		DRVDD-supply = <&vmmc2>;
diff -druNp --no-dereference linux-libre-4.14.27-gnu/arch/arm/boot/dts/r8a7791-koelsch.dts linux-libre-4.14.28-gnu/arch/arm/boot/dts/r8a7791-koelsch.dts
--- linux-libre-4.14.27-gnu/arch/arm/boot/dts/r8a7791-koelsch.dts	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/arch/arm/boot/dts/r8a7791-koelsch.dts	2018-03-19 03:42:57.000000000 -0400
@@ -278,6 +278,12 @@
 		};
 	};
 
+	cec_clock: cec-clock {
+		compatible = "fixed-clock";
+		#clock-cells = <0>;
+		clock-frequency = <12000000>;
+	};
+
 	hdmi-out {
 		compatible = "hdmi-connector";
 		type = "a";
@@ -642,12 +648,6 @@
 		};
 	};
 
-	cec_clock: cec-clock {
-		compatible = "fixed-clock";
-		#clock-cells = <0>;
-		clock-frequency = <12000000>;
-	};
-
 	hdmi@39 {
 		compatible = "adi,adv7511w";
 		reg = <0x39>;
diff -druNp --no-dereference linux-libre-4.14.27-gnu/arch/arm64/boot/dts/renesas/salvator-common.dtsi linux-libre-4.14.28-gnu/arch/arm64/boot/dts/renesas/salvator-common.dtsi
--- linux-libre-4.14.27-gnu/arch/arm64/boot/dts/renesas/salvator-common.dtsi	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/arch/arm64/boot/dts/renesas/salvator-common.dtsi	2018-03-19 03:42:57.000000000 -0400
@@ -264,6 +264,7 @@
 		reg = <0>;
 		interrupt-parent = <&gpio2>;
 		interrupts = <11 IRQ_TYPE_LEVEL_LOW>;
+		reset-gpios = <&gpio2 10 GPIO_ACTIVE_LOW>;
 	};
 };
 
diff -druNp --no-dereference linux-libre-4.14.27-gnu/arch/powerpc/include/asm/code-patching.h linux-libre-4.14.28-gnu/arch/powerpc/include/asm/code-patching.h
--- linux-libre-4.14.27-gnu/arch/powerpc/include/asm/code-patching.h	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/arch/powerpc/include/asm/code-patching.h	2018-03-19 03:42:57.000000000 -0400
@@ -33,6 +33,7 @@ int patch_branch(unsigned int *addr, uns
 int patch_instruction(unsigned int *addr, unsigned int instr);
 
 int instr_is_relative_branch(unsigned int instr);
+int instr_is_relative_link_branch(unsigned int instr);
 int instr_is_branch_to_addr(const unsigned int *instr, unsigned long addr);
 unsigned long branch_target(const unsigned int *instr);
 unsigned int translate_branch(const unsigned int *dest,
diff -druNp --no-dereference linux-libre-4.14.27-gnu/arch/powerpc/kernel/entry_64.S linux-libre-4.14.28-gnu/arch/powerpc/kernel/entry_64.S
--- linux-libre-4.14.27-gnu/arch/powerpc/kernel/entry_64.S	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/arch/powerpc/kernel/entry_64.S	2018-03-19 03:42:57.000000000 -0400
@@ -939,9 +939,13 @@ END_FTR_SECTION_IFSET(CPU_FTR_HAS_PPR)
 	beq	1f
 	rlwinm	r7,r7,0,~PACA_IRQ_HARD_DIS
 	stb	r7,PACAIRQHAPPENED(r13)
-1:	li	r0,0
-	stb	r0,PACASOFTIRQEN(r13);
-	TRACE_DISABLE_INTS
+1:
+#if defined(CONFIG_TRACE_IRQFLAGS) && defined(CONFIG_BUG)
+	/* The interrupt should not have soft enabled. */
+	lbz	r7,PACASOFTIRQEN(r13)
+1:	tdnei	r7,0
+	EMIT_BUG_ENTRY 1b,__FILE__,__LINE__,BUGFLAG_WARNING
+#endif
 	b	.Ldo_restore
 
 	/*
diff -druNp --no-dereference linux-libre-4.14.27-gnu/arch/powerpc/kernel/module_64.c linux-libre-4.14.28-gnu/arch/powerpc/kernel/module_64.c
--- linux-libre-4.14.27-gnu/arch/powerpc/kernel/module_64.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/arch/powerpc/kernel/module_64.c	2018-03-19 03:42:57.000000000 -0400
@@ -486,7 +486,17 @@ static bool is_early_mcount_callsite(u32
    restore r2. */
 static int restore_r2(u32 *instruction, struct module *me)
 {
-	if (is_early_mcount_callsite(instruction - 1))
+	u32 *prev_insn = instruction - 1;
+
+	if (is_early_mcount_callsite(prev_insn))
+		return 1;
+
+	/*
+	 * Make sure the branch isn't a sibling call.  Sibling calls aren't
+	 * "link" branches and they don't return, so they don't need the r2
+	 * restore afterwards.
+	 */
+	if (!instr_is_relative_link_branch(*prev_insn))
 		return 1;
 
 	if (*instruction != PPC_INST_NOP) {
diff -druNp --no-dereference linux-libre-4.14.27-gnu/arch/powerpc/lib/code-patching.c linux-libre-4.14.28-gnu/arch/powerpc/lib/code-patching.c
--- linux-libre-4.14.27-gnu/arch/powerpc/lib/code-patching.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/arch/powerpc/lib/code-patching.c	2018-03-19 03:42:57.000000000 -0400
@@ -302,6 +302,11 @@ int instr_is_relative_branch(unsigned in
 	return instr_is_branch_iform(instr) || instr_is_branch_bform(instr);
 }
 
+int instr_is_relative_link_branch(unsigned int instr)
+{
+	return instr_is_relative_branch(instr) && (instr & BRANCH_SET_LINK);
+}
+
 static unsigned long branch_iform_target(const unsigned int *instr)
 {
 	signed long imm;
diff -druNp --no-dereference linux-libre-4.14.27-gnu/arch/x86/kernel/machine_kexec_64.c linux-libre-4.14.28-gnu/arch/x86/kernel/machine_kexec_64.c
--- linux-libre-4.14.27-gnu/arch/x86/kernel/machine_kexec_64.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/arch/x86/kernel/machine_kexec_64.c	2018-03-19 03:42:57.000000000 -0400
@@ -542,6 +542,7 @@ int arch_kexec_apply_relocations_add(con
 				goto overflow;
 			break;
 		case R_X86_64_PC32:
+		case R_X86_64_PLT32:
 			value -= (u64)address;
 			*(u32 *)location = value;
 			break;
diff -druNp --no-dereference linux-libre-4.14.27-gnu/arch/x86/kernel/module.c linux-libre-4.14.28-gnu/arch/x86/kernel/module.c
--- linux-libre-4.14.27-gnu/arch/x86/kernel/module.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/arch/x86/kernel/module.c	2018-03-19 03:42:57.000000000 -0400
@@ -191,6 +191,7 @@ int apply_relocate_add(Elf64_Shdr *sechd
 				goto overflow;
 			break;
 		case R_X86_64_PC32:
+		case R_X86_64_PLT32:
 			if (*(u32 *)loc != 0)
 				goto invalid_relocation;
 			val -= (u64)loc;
diff -druNp --no-dereference linux-libre-4.14.27-gnu/arch/x86/tools/relocs.c linux-libre-4.14.28-gnu/arch/x86/tools/relocs.c
--- linux-libre-4.14.27-gnu/arch/x86/tools/relocs.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/arch/x86/tools/relocs.c	2018-03-19 03:42:57.000000000 -0400
@@ -770,9 +770,12 @@ static int do_reloc64(struct section *se
 		break;
 
 	case R_X86_64_PC32:
+	case R_X86_64_PLT32:
 		/*
 		 * PC relative relocations don't need to be adjusted unless
 		 * referencing a percpu symbol.
+		 *
+		 * NB: R_X86_64_PLT32 can be treated as R_X86_64_PC32.
 		 */
 		if (is_percpu_sym(sym, symname))
 			add_reloc(&relocs32neg, offset);
diff -druNp --no-dereference linux-libre-4.14.27-gnu/crypto/ecc.c linux-libre-4.14.28-gnu/crypto/ecc.c
--- linux-libre-4.14.27-gnu/crypto/ecc.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/crypto/ecc.c	2018-03-19 03:42:57.000000000 -0400
@@ -964,7 +964,7 @@ int ecc_gen_privkey(unsigned int curve_i
 	 * DRBG with a security strength of 256.
 	 */
 	if (crypto_get_default_rng())
-		err = -EFAULT;
+		return -EFAULT;
 
 	err = crypto_rng_get_bytes(crypto_default_rng, (u8 *)priv, nbytes);
 	crypto_put_default_rng();
diff -druNp --no-dereference linux-libre-4.14.27-gnu/Documentation/devicetree/bindings/usb/usb-xhci.txt linux-libre-4.14.28-gnu/Documentation/devicetree/bindings/usb/usb-xhci.txt
--- linux-libre-4.14.27-gnu/Documentation/devicetree/bindings/usb/usb-xhci.txt	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/Documentation/devicetree/bindings/usb/usb-xhci.txt	2018-03-19 03:42:57.000000000 -0400
@@ -12,6 +12,7 @@ Required properties:
     - "renesas,xhci-r8a7793" for r8a7793 SoC
     - "renesas,xhci-r8a7795" for r8a7795 SoC
     - "renesas,xhci-r8a7796" for r8a7796 SoC
+    - "renesas,xhci-r8a77965" for r8a77965 SoC
     - "renesas,rcar-gen2-xhci" for a generic R-Car Gen2 compatible device
     - "renesas,rcar-gen3-xhci" for a generic R-Car Gen3 compatible device
     - "xhci-platform" (deprecated)
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/base/Kconfig linux-libre-4.14.28-gnu/drivers/base/Kconfig
--- linux-libre-4.14.27-gnu/drivers/base/Kconfig	2018-03-15 08:40:14.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/base/Kconfig	2018-03-19 08:48:00.000000000 -0400
@@ -249,6 +249,7 @@ config DMA_SHARED_BUFFER
 	bool
 	default n
 	select ANON_INODES
+	select IRQ_WORK
 	help
 	  This option enables the framework for buffer-sharing between
 	  multiple drivers. A buffer is associated with a file using driver
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/char/agp/intel-gtt.c linux-libre-4.14.28-gnu/drivers/char/agp/intel-gtt.c
--- linux-libre-4.14.27-gnu/drivers/char/agp/intel-gtt.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/char/agp/intel-gtt.c	2018-03-19 03:42:57.000000000 -0400
@@ -872,6 +872,8 @@ void intel_gtt_insert_sg_entries(struct
 		}
 	}
 	wmb();
+	if (intel_private.driver->chipset_flush)
+		intel_private.driver->chipset_flush();
 }
 EXPORT_SYMBOL(intel_gtt_insert_sg_entries);
 
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/clk/meson/gxbb.c linux-libre-4.14.28-gnu/drivers/clk/meson/gxbb.c
--- linux-libre-4.14.27-gnu/drivers/clk/meson/gxbb.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/clk/meson/gxbb.c	2018-03-19 03:42:57.000000000 -0400
@@ -1139,7 +1139,7 @@ static MESON_GATE(gxbb_pl301, HHI_GCLK_M
 static MESON_GATE(gxbb_periphs, HHI_GCLK_MPEG0, 7);
 static MESON_GATE(gxbb_spicc, HHI_GCLK_MPEG0, 8);
 static MESON_GATE(gxbb_i2c, HHI_GCLK_MPEG0, 9);
-static MESON_GATE(gxbb_sar_adc, HHI_GCLK_MPEG0, 10);
+static MESON_GATE(gxbb_sana, HHI_GCLK_MPEG0, 10);
 static MESON_GATE(gxbb_smart_card, HHI_GCLK_MPEG0, 11);
 static MESON_GATE(gxbb_rng0, HHI_GCLK_MPEG0, 12);
 static MESON_GATE(gxbb_uart0, HHI_GCLK_MPEG0, 13);
@@ -1190,7 +1190,7 @@ static MESON_GATE(gxbb_usb0_ddr_bridge,
 static MESON_GATE(gxbb_mmc_pclk, HHI_GCLK_MPEG2, 11);
 static MESON_GATE(gxbb_dvin, HHI_GCLK_MPEG2, 12);
 static MESON_GATE(gxbb_uart2, HHI_GCLK_MPEG2, 15);
-static MESON_GATE(gxbb_sana, HHI_GCLK_MPEG2, 22);
+static MESON_GATE(gxbb_sar_adc, HHI_GCLK_MPEG2, 22);
 static MESON_GATE(gxbb_vpu_intr, HHI_GCLK_MPEG2, 25);
 static MESON_GATE(gxbb_sec_ahb_ahb3_bridge, HHI_GCLK_MPEG2, 26);
 static MESON_GATE(gxbb_clk81_a53, HHI_GCLK_MPEG2, 29);
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/clk/qcom/gcc-msm8916.c linux-libre-4.14.28-gnu/drivers/clk/qcom/gcc-msm8916.c
--- linux-libre-4.14.27-gnu/drivers/clk/qcom/gcc-msm8916.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/clk/qcom/gcc-msm8916.c	2018-03-19 03:42:57.000000000 -0400
@@ -1438,6 +1438,7 @@ static const struct freq_tbl ftbl_codec_
 
 static struct clk_rcg2 codec_digcodec_clk_src = {
 	.cmd_rcgr = 0x1c09c,
+	.mnd_width = 8,
 	.hid_width = 5,
 	.parent_map = gcc_xo_gpll1_emclk_sleep_map,
 	.freq_tbl = ftbl_codec_clk,
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/cpufreq/cpufreq.c linux-libre-4.14.28-gnu/drivers/cpufreq/cpufreq.c
--- linux-libre-4.14.27-gnu/drivers/cpufreq/cpufreq.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/cpufreq/cpufreq.c	2018-03-19 03:42:57.000000000 -0400
@@ -631,6 +631,8 @@ static int cpufreq_parse_governor(char *
 			*governor = t;
 			err = 0;
 		}
+		if (t && !try_module_get(t->owner))
+			t = NULL;
 
 		mutex_unlock(&cpufreq_governor_mutex);
 	}
@@ -759,6 +761,10 @@ static ssize_t store_scaling_governor(st
 		return -EINVAL;
 
 	ret = cpufreq_set_policy(policy, &new_policy);
+
+	if (new_policy.governor)
+		module_put(new_policy.governor->owner);
+
 	return ret ? ret : count;
 }
 
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/crypto/caam/caamalg_qi.c linux-libre-4.14.28-gnu/drivers/crypto/caam/caamalg_qi.c
--- linux-libre-4.14.27-gnu/drivers/crypto/caam/caamalg_qi.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/crypto/caam/caamalg_qi.c	2018-03-19 03:42:57.000000000 -0400
@@ -668,7 +668,7 @@ static struct aead_edesc *aead_edesc_all
 	qm_sg_ents = 1 + !!ivsize + mapped_src_nents +
 		     (mapped_dst_nents > 1 ? mapped_dst_nents : 0);
 	if (unlikely(qm_sg_ents > CAAM_QI_MAX_AEAD_SG)) {
-		dev_err(qidev, "Insufficient S/G entries: %d > %lu\n",
+		dev_err(qidev, "Insufficient S/G entries: %d > %zu\n",
 			qm_sg_ents, CAAM_QI_MAX_AEAD_SG);
 		caam_unmap(qidev, req->src, req->dst, src_nents, dst_nents,
 			   iv_dma, ivsize, op_type, 0, 0);
@@ -905,7 +905,7 @@ static struct ablkcipher_edesc *ablkciph
 
 	qm_sg_ents += mapped_dst_nents > 1 ? mapped_dst_nents : 0;
 	if (unlikely(qm_sg_ents > CAAM_QI_MAX_ABLKCIPHER_SG)) {
-		dev_err(qidev, "Insufficient S/G entries: %d > %lu\n",
+		dev_err(qidev, "Insufficient S/G entries: %d > %zu\n",
 			qm_sg_ents, CAAM_QI_MAX_ABLKCIPHER_SG);
 		caam_unmap(qidev, req->src, req->dst, src_nents, dst_nents,
 			   iv_dma, ivsize, op_type, 0, 0);
@@ -1058,7 +1058,7 @@ static struct ablkcipher_edesc *ablkciph
 	}
 
 	if (unlikely(qm_sg_ents > CAAM_QI_MAX_ABLKCIPHER_SG)) {
-		dev_err(qidev, "Insufficient S/G entries: %d > %lu\n",
+		dev_err(qidev, "Insufficient S/G entries: %d > %zu\n",
 			qm_sg_ents, CAAM_QI_MAX_ABLKCIPHER_SG);
 		caam_unmap(qidev, req->src, req->dst, src_nents, dst_nents,
 			   iv_dma, ivsize, GIVENCRYPT, 0, 0);
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/crypto/cavium/cpt/cptvf_reqmanager.c linux-libre-4.14.28-gnu/drivers/crypto/cavium/cpt/cptvf_reqmanager.c
--- linux-libre-4.14.27-gnu/drivers/crypto/cavium/cpt/cptvf_reqmanager.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/crypto/cavium/cpt/cptvf_reqmanager.c	2018-03-19 03:42:57.000000000 -0400
@@ -459,7 +459,8 @@ int process_request(struct cpt_vf *cptvf
 	info->completion_addr = kzalloc(sizeof(union cpt_res_s), GFP_KERNEL);
 	if (unlikely(!info->completion_addr)) {
 		dev_err(&pdev->dev, "Unable to allocate memory for completion_addr\n");
-		return -ENOMEM;
+		ret = -ENOMEM;
+		goto request_cleanup;
 	}
 
 	result = (union cpt_res_s *)info->completion_addr;
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/dma/qcom/hidma_ll.c linux-libre-4.14.28-gnu/drivers/dma/qcom/hidma_ll.c
--- linux-libre-4.14.27-gnu/drivers/dma/qcom/hidma_ll.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/dma/qcom/hidma_ll.c	2018-03-19 03:42:57.000000000 -0400
@@ -393,6 +393,8 @@ static int hidma_ll_reset(struct hidma_l
  */
 static void hidma_ll_int_handler_internal(struct hidma_lldev *lldev, int cause)
 {
+	unsigned long irqflags;
+
 	if (cause & HIDMA_ERR_INT_MASK) {
 		dev_err(lldev->dev, "error 0x%x, disabling...\n",
 				cause);
@@ -410,6 +412,10 @@ static void hidma_ll_int_handler_interna
 		return;
 	}
 
+	spin_lock_irqsave(&lldev->lock, irqflags);
+	writel_relaxed(cause, lldev->evca + HIDMA_EVCA_IRQ_CLR_REG);
+	spin_unlock_irqrestore(&lldev->lock, irqflags);
+
 	/*
 	 * Fine tuned for this HW...
 	 *
@@ -421,9 +427,6 @@ static void hidma_ll_int_handler_interna
 	 * Try to consume as many EVREs as possible.
 	 */
 	hidma_handle_tre_completion(lldev);
-
-	/* We consumed TREs or there are pending TREs or EVREs. */
-	writel_relaxed(cause, lldev->evca + HIDMA_EVCA_IRQ_CLR_REG);
 }
 
 irqreturn_t hidma_ll_inthandler(int chirq, void *arg)
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/dma-buf/dma-fence-array.c linux-libre-4.14.28-gnu/drivers/dma-buf/dma-fence-array.c
--- linux-libre-4.14.27-gnu/drivers/dma-buf/dma-fence-array.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/dma-buf/dma-fence-array.c	2018-03-19 03:42:57.000000000 -0400
@@ -31,6 +31,14 @@ static const char *dma_fence_array_get_t
 	return "unbound";
 }
 
+static void irq_dma_fence_array_work(struct irq_work *wrk)
+{
+	struct dma_fence_array *array = container_of(wrk, typeof(*array), work);
+
+	dma_fence_signal(&array->base);
+	dma_fence_put(&array->base);
+}
+
 static void dma_fence_array_cb_func(struct dma_fence *f,
 				    struct dma_fence_cb *cb)
 {
@@ -39,8 +47,9 @@ static void dma_fence_array_cb_func(stru
 	struct dma_fence_array *array = array_cb->array;
 
 	if (atomic_dec_and_test(&array->num_pending))
-		dma_fence_signal(&array->base);
-	dma_fence_put(&array->base);
+		irq_work_queue(&array->work);
+	else
+		dma_fence_put(&array->base);
 }
 
 static bool dma_fence_array_enable_signaling(struct dma_fence *fence)
@@ -136,6 +145,7 @@ struct dma_fence_array *dma_fence_array_
 	spin_lock_init(&array->lock);
 	dma_fence_init(&array->base, &dma_fence_array_ops, &array->lock,
 		       context, seqno);
+	init_irq_work(&array->work, irq_dma_fence_array_work);
 
 	array->num_fences = num_fences;
 	atomic_set(&array->num_pending, signal_on_any ? 1 : num_fences);
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd.c linux-libre-4.14.28-gnu/drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd.c
--- linux-libre-4.14.27-gnu/drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd.c	2018-03-19 03:42:57.000000000 -0400
@@ -265,6 +265,9 @@ uint32_t get_max_engine_clock_in_mhz(str
 {
 	struct amdgpu_device *adev = (struct amdgpu_device *)kgd;
 
-	/* The sclk is in quantas of 10kHz */
-	return adev->pm.dpm.dyn_state.max_clock_voltage_on_ac.sclk / 100;
+	/* the sclk is in quantas of 10kHz */
+	if (amdgpu_sriov_vf(adev))
+		return adev->clock.default_sclk / 100;
+
+	return amdgpu_dpm_get_sclk(adev, false) / 100;
 }
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/gpu/drm/amd/amdgpu/dce_virtual.c linux-libre-4.14.28-gnu/drivers/gpu/drm/amd/amdgpu/dce_virtual.c
--- linux-libre-4.14.27-gnu/drivers/gpu/drm/amd/amdgpu/dce_virtual.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/gpu/drm/amd/amdgpu/dce_virtual.c	2018-03-19 03:42:57.000000000 -0400
@@ -437,6 +437,8 @@ static int dce_virtual_sw_fini(void *han
 	drm_kms_helper_poll_fini(adev->ddev);
 
 	drm_mode_config_cleanup(adev->ddev);
+	/* clear crtcs pointer to avoid dce irq finish routine access freed data */
+	memset(adev->mode_info.crtcs, 0, sizeof(adev->mode_info.crtcs[0]) * AMDGPU_MAX_CRTCS);
 	adev->mode_info.mode_config_initialized = false;
 	return 0;
 }
@@ -723,7 +725,7 @@ static void dce_virtual_set_crtc_vblank_
 							int crtc,
 							enum amdgpu_interrupt_state state)
 {
-	if (crtc >= adev->mode_info.num_crtc) {
+	if (crtc >= adev->mode_info.num_crtc || !adev->mode_info.crtcs[crtc]) {
 		DRM_DEBUG("invalid crtc %d\n", crtc);
 		return;
 	}
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/gpu/drm/amd/amdgpu/mxgpu_ai.c linux-libre-4.14.28-gnu/drivers/gpu/drm/amd/amdgpu/mxgpu_ai.c
--- linux-libre-4.14.27-gnu/drivers/gpu/drm/amd/amdgpu/mxgpu_ai.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/gpu/drm/amd/amdgpu/mxgpu_ai.c	2018-03-19 03:42:57.000000000 -0400
@@ -276,9 +276,17 @@ static int xgpu_ai_mailbox_rcv_irq(struc
 		/* see what event we get */
 		r = xgpu_ai_mailbox_rcv_msg(adev, IDH_FLR_NOTIFICATION);
 
-		/* only handle FLR_NOTIFY now */
-		if (!r)
-			schedule_work(&adev->virt.flr_work);
+		/* sometimes the interrupt is delayed to inject to VM, so under such case
+		 * the IDH_FLR_NOTIFICATION is overwritten by VF FLR from GIM side, thus
+		 * above recieve message could be failed, we should schedule the flr_work
+		 * anyway
+		 */
+		if (r) {
+			DRM_ERROR("FLR_NOTIFICATION is missed\n");
+			xgpu_ai_mailbox_send_ack(adev);
+		}
+
+		schedule_work(&adev->virt.flr_work);
 	}
 
 	return 0;
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/gpu/drm/amd/amdkfd/kfd_topology.c linux-libre-4.14.28-gnu/drivers/gpu/drm/amd/amdkfd/kfd_topology.c
--- linux-libre-4.14.27-gnu/drivers/gpu/drm/amd/amdkfd/kfd_topology.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/gpu/drm/amd/amdkfd/kfd_topology.c	2018-03-19 03:42:57.000000000 -0400
@@ -501,11 +501,17 @@ static ssize_t sysprops_show(struct kobj
 	return ret;
 }
 
+static void kfd_topology_kobj_release(struct kobject *kobj)
+{
+	kfree(kobj);
+}
+
 static const struct sysfs_ops sysprops_ops = {
 	.show = sysprops_show,
 };
 
 static struct kobj_type sysprops_type = {
+	.release = kfd_topology_kobj_release,
 	.sysfs_ops = &sysprops_ops,
 };
 
@@ -541,6 +547,7 @@ static const struct sysfs_ops iolink_ops
 };
 
 static struct kobj_type iolink_type = {
+	.release = kfd_topology_kobj_release,
 	.sysfs_ops = &iolink_ops,
 };
 
@@ -568,6 +575,7 @@ static const struct sysfs_ops mem_ops =
 };
 
 static struct kobj_type mem_type = {
+	.release = kfd_topology_kobj_release,
 	.sysfs_ops = &mem_ops,
 };
 
@@ -607,6 +615,7 @@ static const struct sysfs_ops cache_ops
 };
 
 static struct kobj_type cache_type = {
+	.release = kfd_topology_kobj_release,
 	.sysfs_ops = &cache_ops,
 };
 
@@ -729,6 +738,7 @@ static const struct sysfs_ops node_ops =
 };
 
 static struct kobj_type node_type = {
+	.release = kfd_topology_kobj_release,
 	.sysfs_ops = &node_ops,
 };
 
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/gpu/drm/drm_edid.c linux-libre-4.14.28-gnu/drivers/gpu/drm/drm_edid.c
--- linux-libre-4.14.27-gnu/drivers/gpu/drm/drm_edid.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/gpu/drm/drm_edid.c	2018-03-19 03:42:57.000000000 -0400
@@ -3823,8 +3823,7 @@ EXPORT_SYMBOL(drm_edid_get_monitor_name)
  * @edid: EDID to parse
  *
  * Fill the ELD (EDID-Like Data) buffer for passing to the audio driver. The
- * Conn_Type, HDCP and Port_ID ELD fields are left for the graphics driver to
- * fill in.
+ * HDCP and Port_ID ELD fields are left for the graphics driver to fill in.
  */
 void drm_edid_to_eld(struct drm_connector *connector, struct edid *edid)
 {
@@ -3905,6 +3904,12 @@ void drm_edid_to_eld(struct drm_connecto
 	}
 	eld[5] |= total_sad_count << 4;
 
+	if (connector->connector_type == DRM_MODE_CONNECTOR_DisplayPort ||
+	    connector->connector_type == DRM_MODE_CONNECTOR_eDP)
+		eld[DRM_ELD_SAD_COUNT_CONN_TYPE] |= DRM_ELD_CONN_TYPE_DP;
+	else
+		eld[DRM_ELD_SAD_COUNT_CONN_TYPE] |= DRM_ELD_CONN_TYPE_HDMI;
+
 	eld[DRM_ELD_BASELINE_ELD_LEN] =
 		DIV_ROUND_UP(drm_eld_calc_baseline_block_size(eld), 4);
 
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/gpu/drm/etnaviv/etnaviv_gpu.c linux-libre-4.14.28-gnu/drivers/gpu/drm/etnaviv/etnaviv_gpu.c
--- linux-libre-4.14.27-gnu/drivers/gpu/drm/etnaviv/etnaviv_gpu.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/gpu/drm/etnaviv/etnaviv_gpu.c	2018-03-19 03:42:57.000000000 -0400
@@ -1622,7 +1622,7 @@ static int etnaviv_gpu_bind(struct devic
 	struct etnaviv_gpu *gpu = dev_get_drvdata(dev);
 	int ret;
 
-	if (IS_ENABLED(CONFIG_THERMAL)) {
+	if (IS_ENABLED(CONFIG_DRM_ETNAVIV_THERMAL)) {
 		gpu->cooling = thermal_of_cooling_device_register(dev->of_node,
 				(char *)dev_name(dev), gpu, &cooling_ops);
 		if (IS_ERR(gpu->cooling))
@@ -1635,7 +1635,8 @@ static int etnaviv_gpu_bind(struct devic
 	ret = etnaviv_gpu_clk_enable(gpu);
 #endif
 	if (ret < 0) {
-		thermal_cooling_device_unregister(gpu->cooling);
+		if (IS_ENABLED(CONFIG_DRM_ETNAVIV_THERMAL))
+			thermal_cooling_device_unregister(gpu->cooling);
 		return ret;
 	}
 
@@ -1692,7 +1693,8 @@ static void etnaviv_gpu_unbind(struct de
 
 	gpu->drm = NULL;
 
-	thermal_cooling_device_unregister(gpu->cooling);
+	if (IS_ENABLED(CONFIG_DRM_ETNAVIV_THERMAL))
+		thermal_cooling_device_unregister(gpu->cooling);
 	gpu->cooling = NULL;
 }
 
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/gpu/drm/etnaviv/Kconfig linux-libre-4.14.28-gnu/drivers/gpu/drm/etnaviv/Kconfig
--- linux-libre-4.14.27-gnu/drivers/gpu/drm/etnaviv/Kconfig	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/gpu/drm/etnaviv/Kconfig	2018-03-19 03:42:57.000000000 -0400
@@ -6,6 +6,7 @@ config DRM_ETNAVIV
 	depends on MMU
 	select SHMEM
 	select SYNC_FILE
+	select THERMAL if DRM_ETNAVIV_THERMAL
 	select TMPFS
 	select IOMMU_API
 	select IOMMU_SUPPORT
@@ -15,6 +16,14 @@ config DRM_ETNAVIV
 	help
 	  DRM driver for Vivante GPUs.
 
+config DRM_ETNAVIV_THERMAL
+	bool "enable ETNAVIV thermal throttling"
+	depends on DRM_ETNAVIV
+	default y
+	help
+	  Compile in support for thermal throttling.
+	  Say Y unless you want to risk burning your SoC.
+
 config DRM_ETNAVIV_REGISTER_LOGGING
 	bool "enable ETNAVIV register logging"
 	depends on DRM_ETNAVIV
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/gpu/drm/i915/intel_guc_loader.c linux-libre-4.14.28-gnu/drivers/gpu/drm/i915/intel_guc_loader.c
--- linux-libre-4.14.27-gnu/drivers/gpu/drm/i915/intel_guc_loader.c	2018-03-15 08:14:46.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/gpu/drm/i915/intel_guc_loader.c	2018-03-19 08:20:35.000000000 -0400
@@ -61,9 +61,6 @@
 #define KBL_FW_MAJOR 9
 #define KBL_FW_MINOR 14
 
-#define GLK_FW_MAJOR 10
-#define GLK_FW_MINOR 56
-
 #define GUC_FW_PATH(platform, major, minor) \
        "/*(DEBLOBBED)*/"
 
@@ -76,8 +73,6 @@
 #define I915_KBL_GUC_UCODE GUC_FW_PATH(kbl, KBL_FW_MAJOR, KBL_FW_MINOR)
 /*(DEBLOBBED)*/
 
-#define I915_GLK_GUC_UCODE GUC_FW_PATH(glk, GLK_FW_MAJOR, GLK_FW_MINOR)
-
 
 static u32 get_gttype(struct drm_i915_private *dev_priv)
 {
@@ -406,10 +401,6 @@ int intel_guc_select_fw(struct intel_guc
 		guc->fw.path = I915_KBL_GUC_UCODE;
 		guc->fw.major_ver_wanted = KBL_FW_MAJOR;
 		guc->fw.minor_ver_wanted = KBL_FW_MINOR;
-	} else if (IS_GEMINILAKE(dev_priv)) {
-		guc->fw.path = I915_GLK_GUC_UCODE;
-		guc->fw.major_ver_wanted = GLK_FW_MAJOR;
-		guc->fw.minor_ver_wanted = GLK_FW_MINOR;
 	} else {
 		DRM_ERROR("No GuC firmware known for platform with GuC!\n");
 		return -ENOENT;
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/gpu/drm/i915/intel_huc.c linux-libre-4.14.28-gnu/drivers/gpu/drm/i915/intel_huc.c
--- linux-libre-4.14.27-gnu/drivers/gpu/drm/i915/intel_huc.c	2018-03-15 08:14:49.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/gpu/drm/i915/intel_huc.c	2018-03-19 08:20:37.000000000 -0400
@@ -52,10 +52,6 @@
 #define KBL_HUC_FW_MINOR 00
 #define KBL_BLD_NUM 1810
 
-#define GLK_HUC_FW_MAJOR 02
-#define GLK_HUC_FW_MINOR 00
-#define GLK_BLD_NUM 1748
-
 #define HUC_FW_PATH(platform, major, minor, bld_num) \
 	"/*(DEBLOBBED)*/"
 
@@ -71,9 +67,6 @@
 	KBL_HUC_FW_MINOR, KBL_BLD_NUM)
 /*(DEBLOBBED)*/
 
-#define I915_GLK_HUC_UCODE HUC_FW_PATH(glk, GLK_HUC_FW_MAJOR, \
-	GLK_HUC_FW_MINOR, GLK_BLD_NUM)
-
 /**
  * huc_ucode_xfer() - DMA's the firmware
  * @dev_priv: the drm_i915_private device
@@ -170,10 +163,6 @@ void intel_huc_select_fw(struct intel_hu
 		huc->fw.path = I915_KBL_HUC_UCODE;
 		huc->fw.major_ver_wanted = KBL_HUC_FW_MAJOR;
 		huc->fw.minor_ver_wanted = KBL_HUC_FW_MINOR;
-	} else if (IS_GEMINILAKE(dev_priv)) {
-		huc->fw.path = I915_GLK_HUC_UCODE;
-		huc->fw.major_ver_wanted = GLK_HUC_FW_MAJOR;
-		huc->fw.minor_ver_wanted = GLK_HUC_FW_MINOR;
 	} else {
 		DRM_ERROR("No HuC firmware known for platform with HuC!\n");
 		return;
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/gpu/drm/sun4i/sun8i_mixer.h linux-libre-4.14.28-gnu/drivers/gpu/drm/sun4i/sun8i_mixer.h
--- linux-libre-4.14.27-gnu/drivers/gpu/drm/sun4i/sun8i_mixer.h	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/gpu/drm/sun4i/sun8i_mixer.h	2018-03-19 03:42:57.000000000 -0400
@@ -80,7 +80,7 @@
 
 #define SUN8I_MIXER_CHAN_UI_LAYER_ATTR_EN		BIT(0)
 #define SUN8I_MIXER_CHAN_UI_LAYER_ATTR_ALPHA_MODE_MASK	GENMASK(2, 1)
-#define SUN8I_MIXER_CHAN_UI_LAYER_ATTR_FBFMT_MASK	GENMASK(11, 8)
+#define SUN8I_MIXER_CHAN_UI_LAYER_ATTR_FBFMT_MASK	GENMASK(12, 8)
 #define SUN8I_MIXER_CHAN_UI_LAYER_ATTR_ALPHA_MASK	GENMASK(31, 24)
 #define SUN8I_MIXER_CHAN_UI_LAYER_ATTR_ALPHA_MODE_DEF	(1 << 1)
 #define SUN8I_MIXER_CHAN_UI_LAYER_ATTR_FBFMT_ARGB8888	(0 << 8)
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/hid/hid-elo.c linux-libre-4.14.28-gnu/drivers/hid/hid-elo.c
--- linux-libre-4.14.27-gnu/drivers/hid/hid-elo.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/hid/hid-elo.c	2018-03-19 03:42:57.000000000 -0400
@@ -42,6 +42,12 @@ static int elo_input_configured(struct h
 {
 	struct input_dev *input = hidinput->input;
 
+	/*
+	 * ELO devices have one Button usage in GenDesk field, which makes
+	 * hid-input map it to BTN_LEFT; that confuses userspace, which then
+	 * considers the device to be a mouse/touchpad instead of touchscreen.
+	 */
+	clear_bit(BTN_LEFT, input->keybit);
 	set_bit(BTN_TOUCH, input->keybit);
 	set_bit(ABS_PRESSURE, input->absbit);
 	input_set_abs_params(input, ABS_PRESSURE, 0, 256, 0, 0);
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/hid/hid-multitouch.c linux-libre-4.14.28-gnu/drivers/hid/hid-multitouch.c
--- linux-libre-4.14.27-gnu/drivers/hid/hid-multitouch.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/hid/hid-multitouch.c	2018-03-19 03:42:57.000000000 -0400
@@ -738,9 +738,11 @@ static int mt_touch_event(struct hid_dev
 }
 
 static void mt_process_mt_event(struct hid_device *hid, struct hid_field *field,
-				struct hid_usage *usage, __s32 value)
+				struct hid_usage *usage, __s32 value,
+				bool first_packet)
 {
 	struct mt_device *td = hid_get_drvdata(hid);
+	__s32 cls = td->mtclass.name;
 	__s32 quirks = td->mtclass.quirks;
 	struct input_dev *input = field->hidinput->input;
 
@@ -794,6 +796,15 @@ static void mt_process_mt_event(struct h
 			break;
 
 		default:
+			/*
+			 * For Win8 PTP touchpads we should only look at
+			 * non finger/touch events in the first_packet of
+			 * a (possible) multi-packet frame.
+			 */
+			if ((cls == MT_CLS_WIN_8 || cls == MT_CLS_WIN_8_DUAL) &&
+			    !first_packet)
+				return;
+
 			if (usage->type)
 				input_event(input, usage->type, usage->code,
 						value);
@@ -813,6 +824,7 @@ static void mt_touch_report(struct hid_d
 {
 	struct mt_device *td = hid_get_drvdata(hid);
 	struct hid_field *field;
+	bool first_packet;
 	unsigned count;
 	int r, n;
 
@@ -831,6 +843,7 @@ static void mt_touch_report(struct hid_d
 			td->num_expected = value;
 	}
 
+	first_packet = td->num_received == 0;
 	for (r = 0; r < report->maxfield; r++) {
 		field = report->field[r];
 		count = field->report_count;
@@ -840,7 +853,7 @@ static void mt_touch_report(struct hid_d
 
 		for (n = 0; n < count; n++)
 			mt_process_mt_event(hid, field, &field->usage[n],
-					field->value[n]);
+					    field->value[n], first_packet);
 	}
 
 	if (td->num_received >= td->num_expected)
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/iio/adc/ina2xx-adc.c linux-libre-4.14.28-gnu/drivers/iio/adc/ina2xx-adc.c
--- linux-libre-4.14.27-gnu/drivers/iio/adc/ina2xx-adc.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/iio/adc/ina2xx-adc.c	2018-03-19 03:42:57.000000000 -0400
@@ -44,7 +44,6 @@
 
 #define INA226_MASK_ENABLE		0x06
 #define INA226_CVRF			BIT(3)
-#define INA219_CNVR			BIT(1)
 
 #define INA2XX_MAX_REGISTERS            8
 
@@ -79,6 +78,11 @@
 #define INA226_ITS_MASK		GENMASK(5, 3)
 #define INA226_SHIFT_ITS(val)	((val) << 3)
 
+/* INA219 Bus voltage register, low bits are flags */
+#define INA219_OVF		BIT(0)
+#define INA219_CNVR		BIT(1)
+#define INA219_BUS_VOLTAGE_SHIFT	3
+
 /* Cosmetic macro giving the sampling period for a full P=UxI cycle */
 #define SAMPLING_PERIOD(c)	((c->int_time_vbus + c->int_time_vshunt) \
 				 * c->avg)
@@ -112,7 +116,7 @@ struct ina2xx_config {
 	u16 config_default;
 	int calibration_factor;
 	int shunt_div;
-	int bus_voltage_shift;
+	int bus_voltage_shift;	/* position of lsb */
 	int bus_voltage_lsb;	/* uV */
 	int power_lsb;		/* uW */
 	enum ina2xx_ids chip_id;
@@ -135,7 +139,7 @@ static const struct ina2xx_config ina2xx
 		.config_default = INA219_CONFIG_DEFAULT,
 		.calibration_factor = 40960000,
 		.shunt_div = 100,
-		.bus_voltage_shift = 3,
+		.bus_voltage_shift = INA219_BUS_VOLTAGE_SHIFT,
 		.bus_voltage_lsb = 4000,
 		.power_lsb = 20000,
 		.chip_id = ina219,
@@ -170,6 +174,9 @@ static int ina2xx_read_raw(struct iio_de
 		else
 			*val  = regval;
 
+		if (chan->address == INA2XX_BUS_VOLTAGE)
+			*val >>= chip->config->bus_voltage_shift;
+
 		return IIO_VAL_INT;
 
 	case IIO_CHAN_INFO_OVERSAMPLING_RATIO:
@@ -203,9 +210,9 @@ static int ina2xx_read_raw(struct iio_de
 			return IIO_VAL_FRACTIONAL;
 
 		case INA2XX_BUS_VOLTAGE:
-			/* processed (mV) = raw*lsb (uV) / (1000 << shift) */
+			/* processed (mV) = raw * lsb (uV) / 1000 */
 			*val = chip->config->bus_voltage_lsb;
-			*val2 = 1000 << chip->config->bus_voltage_shift;
+			*val2 = 1000;
 			return IIO_VAL_FRACTIONAL;
 
 		case INA2XX_POWER:
@@ -532,7 +539,7 @@ static ssize_t ina2xx_shunt_resistor_sto
  * Sampling Freq is a consequence of the integration times of
  * the Voltage channels.
  */
-#define INA219_CHAN_VOLTAGE(_index, _address) { \
+#define INA219_CHAN_VOLTAGE(_index, _address, _shift) { \
 	.type = IIO_VOLTAGE, \
 	.address = (_address), \
 	.indexed = 1, \
@@ -544,7 +551,8 @@ static ssize_t ina2xx_shunt_resistor_sto
 	.scan_index = (_index), \
 	.scan_type = { \
 		.sign = 'u', \
-		.realbits = 16, \
+		.shift = _shift, \
+		.realbits = 16 - _shift, \
 		.storagebits = 16, \
 		.endianness = IIO_LE, \
 	} \
@@ -579,8 +587,8 @@ static const struct iio_chan_spec ina226
 };
 
 static const struct iio_chan_spec ina219_channels[] = {
-	INA219_CHAN_VOLTAGE(0, INA2XX_SHUNT_VOLTAGE),
-	INA219_CHAN_VOLTAGE(1, INA2XX_BUS_VOLTAGE),
+	INA219_CHAN_VOLTAGE(0, INA2XX_SHUNT_VOLTAGE, 0),
+	INA219_CHAN_VOLTAGE(1, INA2XX_BUS_VOLTAGE, INA219_BUS_VOLTAGE_SHIFT),
 	INA219_CHAN(IIO_POWER, 2, INA2XX_POWER),
 	INA219_CHAN(IIO_CURRENT, 3, INA2XX_CURRENT),
 	IIO_CHAN_SOFT_TIMESTAMP(4),
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/iio/health/max30102.c linux-libre-4.14.28-gnu/drivers/iio/health/max30102.c
--- linux-libre-4.14.27-gnu/drivers/iio/health/max30102.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/iio/health/max30102.c	2018-03-19 03:42:57.000000000 -0400
@@ -329,20 +329,31 @@ static int max30102_read_temp(struct max
 	return 0;
 }
 
-static int max30102_get_temp(struct max30102_data *data, int *val)
+static int max30102_get_temp(struct max30102_data *data, int *val, bool en)
 {
 	int ret;
 
+	if (en) {
+		ret = max30102_set_powermode(data, true);
+		if (ret)
+			return ret;
+	}
+
 	/* start acquisition */
 	ret = regmap_update_bits(data->regmap, MAX30102_REG_TEMP_CONFIG,
 				 MAX30102_REG_TEMP_CONFIG_TEMP_EN,
 				 MAX30102_REG_TEMP_CONFIG_TEMP_EN);
 	if (ret)
-		return ret;
+		goto out;
 
 	msleep(35);
+	ret = max30102_read_temp(data, val);
 
-	return max30102_read_temp(data, val);
+out:
+	if (en)
+		max30102_set_powermode(data, false);
+
+	return ret;
 }
 
 static int max30102_read_raw(struct iio_dev *indio_dev,
@@ -355,20 +366,19 @@ static int max30102_read_raw(struct iio_
 	switch (mask) {
 	case IIO_CHAN_INFO_RAW:
 		/*
-		 * Temperature reading can only be acquired while engine
-		 * is running
+		 * Temperature reading can only be acquired when not in
+		 * shutdown; leave shutdown briefly when buffer not running
 		 */
 		mutex_lock(&indio_dev->mlock);
-
 		if (!iio_buffer_enabled(indio_dev))
-			ret = -EBUSY;
-		else {
-			ret = max30102_get_temp(data, val);
-			if (!ret)
-				ret = IIO_VAL_INT;
-		}
-
+			ret = max30102_get_temp(data, val, true);
+		else
+			ret = max30102_get_temp(data, val, false);
 		mutex_unlock(&indio_dev->mlock);
+		if (ret)
+			return ret;
+
+		ret = IIO_VAL_INT;
 		break;
 	case IIO_CHAN_INFO_SCALE:
 		*val = 1000;  /* 62.5 */
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/infiniband/hw/mlx5/mr.c linux-libre-4.14.28-gnu/drivers/infiniband/hw/mlx5/mr.c
--- linux-libre-4.14.27-gnu/drivers/infiniband/hw/mlx5/mr.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/infiniband/hw/mlx5/mr.c	2018-03-19 03:42:57.000000000 -0400
@@ -1206,6 +1206,9 @@ struct ib_mr *mlx5_ib_reg_user_mr(struct
 	int err;
 	bool use_umr = true;
 
+	if (!IS_ENABLED(CONFIG_INFINIBAND_USER_MEM))
+		return ERR_PTR(-EINVAL);
+
 	mlx5_ib_dbg(dev, "start 0x%llx, virt_addr 0x%llx, length 0x%llx, access_flags 0x%x\n",
 		    start, virt_addr, length, access_flags);
 
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/leds/leds-pm8058.c linux-libre-4.14.28-gnu/drivers/leds/leds-pm8058.c
--- linux-libre-4.14.27-gnu/drivers/leds/leds-pm8058.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/leds/leds-pm8058.c	2018-03-19 03:42:57.000000000 -0400
@@ -106,7 +106,7 @@ static int pm8058_led_probe(struct platf
 	if (!led)
 		return -ENOMEM;
 
-	led->ledtype = (u32)of_device_get_match_data(&pdev->dev);
+	led->ledtype = (u32)(unsigned long)of_device_get_match_data(&pdev->dev);
 
 	map = dev_get_regmap(pdev->dev.parent, NULL);
 	if (!map) {
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/md/dm-mpath.c linux-libre-4.14.28-gnu/drivers/md/dm-mpath.c
--- linux-libre-4.14.27-gnu/drivers/md/dm-mpath.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/md/dm-mpath.c	2018-03-19 03:42:57.000000000 -0400
@@ -1941,8 +1941,9 @@ static int multipath_busy(struct dm_targ
  *---------------------------------------------------------------*/
 static struct target_type multipath_target = {
 	.name = "multipath",
-	.version = {1, 12, 0},
-	.features = DM_TARGET_SINGLETON | DM_TARGET_IMMUTABLE,
+	.version = {1, 13, 0},
+	.features = DM_TARGET_SINGLETON | DM_TARGET_IMMUTABLE |
+		    DM_TARGET_PASSES_INTEGRITY,
 	.module = THIS_MODULE,
 	.ctr = multipath_ctr,
 	.dtr = multipath_dtr,
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/md/dm-raid.c linux-libre-4.14.28-gnu/drivers/md/dm-raid.c
--- linux-libre-4.14.27-gnu/drivers/md/dm-raid.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/md/dm-raid.c	2018-03-19 03:42:57.000000000 -0400
@@ -675,15 +675,11 @@ static struct raid_type *get_raid_type_b
 	return NULL;
 }
 
-/*
- * Conditionally change bdev capacity of @rs
- * in case of a disk add/remove reshape
- */
-static void rs_set_capacity(struct raid_set *rs)
+/* Adjust rdev sectors */
+static void rs_set_rdev_sectors(struct raid_set *rs)
 {
 	struct mddev *mddev = &rs->md;
 	struct md_rdev *rdev;
-	struct gendisk *gendisk = dm_disk(dm_table_get_md(rs->ti->table));
 
 	/*
 	 * raid10 sets rdev->sector to the device size, which
@@ -692,8 +688,16 @@ static void rs_set_capacity(struct raid_
 	rdev_for_each(rdev, mddev)
 		if (!test_bit(Journal, &rdev->flags))
 			rdev->sectors = mddev->dev_sectors;
+}
 
-	set_capacity(gendisk, mddev->array_sectors);
+/*
+ * Change bdev capacity of @rs in case of a disk add/remove reshape
+ */
+static void rs_set_capacity(struct raid_set *rs)
+{
+	struct gendisk *gendisk = dm_disk(dm_table_get_md(rs->ti->table));
+
+	set_capacity(gendisk, rs->md.array_sectors);
 	revalidate_disk(gendisk);
 }
 
@@ -1674,8 +1678,11 @@ static void do_table_event(struct work_s
 	struct raid_set *rs = container_of(ws, struct raid_set, md.event_work);
 
 	smp_rmb(); /* Make sure we access most actual mddev properties */
-	if (!rs_is_reshaping(rs))
+	if (!rs_is_reshaping(rs)) {
+		if (rs_is_raid10(rs))
+			rs_set_rdev_sectors(rs);
 		rs_set_capacity(rs);
+	}
 	dm_table_event(rs->ti->table);
 }
 
@@ -3845,11 +3852,10 @@ static int raid_preresume(struct dm_targ
 		mddev->resync_min = mddev->recovery_cp;
 	}
 
-	rs_set_capacity(rs);
-
 	/* Check for any reshape request unless new raid set */
 	if (test_and_clear_bit(RT_FLAG_RESHAPE_RS, &rs->runtime_flags)) {
 		/* Initiate a reshape. */
+		rs_set_rdev_sectors(rs);
 		mddev_lock_nointr(mddev);
 		r = rs_start_reshape(rs);
 		mddev_unlock(mddev);
@@ -3878,6 +3884,10 @@ static void raid_resume(struct dm_target
 	mddev->ro = 0;
 	mddev->in_sync = 0;
 
+	/* Only reduce raid set size before running a disk removing reshape. */
+	if (mddev->delta_disks < 0)
+		rs_set_capacity(rs);
+
 	/*
 	 * Keep the RAID set frozen if reshape/rebuild flags are set.
 	 * The RAID set is unfrozen once the next table load/resume,
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/media/platform/davinci/vpif_capture.c linux-libre-4.14.28-gnu/drivers/media/platform/davinci/vpif_capture.c
--- linux-libre-4.14.27-gnu/drivers/media/platform/davinci/vpif_capture.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/media/platform/davinci/vpif_capture.c	2018-03-19 03:42:57.000000000 -0400
@@ -1545,6 +1545,8 @@ vpif_capture_get_pdata(struct platform_d
 					    sizeof(*chan->inputs) *
 					    VPIF_CAPTURE_NUM_CHANNELS,
 					    GFP_KERNEL);
+		if (!chan->inputs)
+			return NULL;
 
 		chan->input_count++;
 		chan->inputs[i].input.type = V4L2_INPUT_TYPE_CAMERA;
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/media/platform/vsp1/vsp1_drv.c linux-libre-4.14.28-gnu/drivers/media/platform/vsp1/vsp1_drv.c
--- linux-libre-4.14.27-gnu/drivers/media/platform/vsp1/vsp1_drv.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/media/platform/vsp1/vsp1_drv.c	2018-03-19 03:42:57.000000000 -0400
@@ -571,7 +571,13 @@ static int __maybe_unused vsp1_pm_suspen
 {
 	struct vsp1_device *vsp1 = dev_get_drvdata(dev);
 
-	vsp1_pipelines_suspend(vsp1);
+	/*
+	 * When used as part of a display pipeline, the VSP is stopped and
+	 * restarted explicitly by the DU.
+	 */
+	if (!vsp1->drm)
+		vsp1_pipelines_suspend(vsp1);
+
 	pm_runtime_force_suspend(vsp1->dev);
 
 	return 0;
@@ -582,7 +588,13 @@ static int __maybe_unused vsp1_pm_resume
 	struct vsp1_device *vsp1 = dev_get_drvdata(dev);
 
 	pm_runtime_force_resume(vsp1->dev);
-	vsp1_pipelines_resume(vsp1);
+
+	/*
+	 * When used as part of a display pipeline, the VSP is stopped and
+	 * restarted explicitly by the DU.
+	 */
+	if (!vsp1->drm)
+		vsp1_pipelines_resume(vsp1);
 
 	return 0;
 }
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/media/usb/cpia2/cpia2_v4l.c linux-libre-4.14.28-gnu/drivers/media/usb/cpia2/cpia2_v4l.c
--- linux-libre-4.14.27-gnu/drivers/media/usb/cpia2/cpia2_v4l.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/media/usb/cpia2/cpia2_v4l.c	2018-03-19 03:42:57.000000000 -0400
@@ -808,7 +808,7 @@ static int cpia2_querybuf(struct file *f
 	struct camera_data *cam = video_drvdata(file);
 
 	if(buf->type != V4L2_BUF_TYPE_VIDEO_CAPTURE ||
-	   buf->index > cam->num_frames)
+	   buf->index >= cam->num_frames)
 		return -EINVAL;
 
 	buf->m.offset = cam->buffers[buf->index].data - cam->frame_buffer;
@@ -859,7 +859,7 @@ static int cpia2_qbuf(struct file *file,
 
 	if(buf->type != V4L2_BUF_TYPE_VIDEO_CAPTURE ||
 	   buf->memory != V4L2_MEMORY_MMAP ||
-	   buf->index > cam->num_frames)
+	   buf->index >= cam->num_frames)
 		return -EINVAL;
 
 	DBG("QBUF #%d\n", buf->index);
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/mmc/core/mmc_test.c linux-libre-4.14.28-gnu/drivers/mmc/core/mmc_test.c
--- linux-libre-4.14.27-gnu/drivers/mmc/core/mmc_test.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/mmc/core/mmc_test.c	2018-03-19 03:42:57.000000000 -0400
@@ -2328,10 +2328,17 @@ static int mmc_test_reset(struct mmc_tes
 	int err;
 
 	err = mmc_hw_reset(host);
-	if (!err)
+	if (!err) {
+		/*
+		 * Reset will re-enable the card's command queue, but tests
+		 * expect it to be disabled.
+		 */
+		if (card->ext_csd.cmdq_en)
+			mmc_cmdq_disable(card);
 		return RESULT_OK;
-	else if (err == -EOPNOTSUPP)
+	} else if (err == -EOPNOTSUPP) {
 		return RESULT_UNSUP_HOST;
+	}
 
 	return RESULT_FAIL;
 }
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/mtd/nand/fsl_ifc_nand.c linux-libre-4.14.28-gnu/drivers/mtd/nand/fsl_ifc_nand.c
--- linux-libre-4.14.27-gnu/drivers/mtd/nand/fsl_ifc_nand.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/mtd/nand/fsl_ifc_nand.c	2018-03-19 03:42:57.000000000 -0400
@@ -916,6 +916,13 @@ static int fsl_ifc_chip_init(struct fsl_
 	if (ctrl->version >= FSL_IFC_VERSION_1_1_0)
 		fsl_ifc_sram_init(priv);
 
+	/*
+	 * As IFC version 2.0.0 has 16KB of internal SRAM as compared to older
+	 * versions which had 8KB. Hence bufnum mask needs to be updated.
+	 */
+	if (ctrl->version >= FSL_IFC_VERSION_2_0_0)
+		priv->bufnum_mask = (priv->bufnum_mask * 2) + 1;
+
 	return 0;
 }
 
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/mtd/nand/nand_base.c linux-libre-4.14.28-gnu/drivers/mtd/nand/nand_base.c
--- linux-libre-4.14.27-gnu/drivers/mtd/nand/nand_base.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/mtd/nand/nand_base.c	2018-03-19 03:42:57.000000000 -0400
@@ -710,7 +710,8 @@ static void nand_command(struct mtd_info
 		chip->cmd_ctrl(mtd, readcmd, ctrl);
 		ctrl &= ~NAND_CTRL_CHANGE;
 	}
-	chip->cmd_ctrl(mtd, command, ctrl);
+	if (command != NAND_CMD_NONE)
+		chip->cmd_ctrl(mtd, command, ctrl);
 
 	/* Address cycle, when necessary */
 	ctrl = NAND_CTRL_ALE | NAND_CTRL_CHANGE;
@@ -739,6 +740,7 @@ static void nand_command(struct mtd_info
 	 */
 	switch (command) {
 
+	case NAND_CMD_NONE:
 	case NAND_CMD_PAGEPROG:
 	case NAND_CMD_ERASE1:
 	case NAND_CMD_ERASE2:
@@ -832,7 +834,9 @@ static void nand_command_lp(struct mtd_i
 	}
 
 	/* Command latch cycle */
-	chip->cmd_ctrl(mtd, command, NAND_NCE | NAND_CLE | NAND_CTRL_CHANGE);
+	if (command != NAND_CMD_NONE)
+		chip->cmd_ctrl(mtd, command,
+			       NAND_NCE | NAND_CLE | NAND_CTRL_CHANGE);
 
 	if (column != -1 || page_addr != -1) {
 		int ctrl = NAND_CTRL_CHANGE | NAND_NCE | NAND_ALE;
@@ -868,6 +872,7 @@ static void nand_command_lp(struct mtd_i
 	 */
 	switch (command) {
 
+	case NAND_CMD_NONE:
 	case NAND_CMD_CACHEDPROG:
 	case NAND_CMD_PAGEPROG:
 	case NAND_CMD_ERASE1:
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/net/ethernet/broadcom/bnxt/bnxt.c linux-libre-4.14.28-gnu/drivers/net/ethernet/broadcom/bnxt/bnxt.c
--- linux-libre-4.14.27-gnu/drivers/net/ethernet/broadcom/bnxt/bnxt.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/net/ethernet/broadcom/bnxt/bnxt.c	2018-03-19 03:42:57.000000000 -0400
@@ -1698,12 +1698,16 @@ static int bnxt_async_event_process(stru
 
 		if (BNXT_VF(bp))
 			goto async_event_process_exit;
-		if (data1 & 0x20000) {
+
+		/* print unsupported speed warning in forced speed mode only */
+		if (!(link_info->autoneg & BNXT_AUTONEG_SPEED) &&
+		    (data1 & 0x20000)) {
 			u16 fw_speed = link_info->force_link_speed;
 			u32 speed = bnxt_fw_to_ethtool_speed(fw_speed);
 
-			netdev_warn(bp->dev, "Link speed %d no longer supported\n",
-				    speed);
+			if (speed != SPEED_UNKNOWN)
+				netdev_warn(bp->dev, "Link speed %d no longer supported\n",
+					    speed);
 		}
 		set_bit(BNXT_LINK_SPEED_CHNG_SP_EVENT, &bp->sp_event);
 		/* fall thru */
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/net/ethernet/cavium/thunder/nicvf_main.c linux-libre-4.14.28-gnu/drivers/net/ethernet/cavium/thunder/nicvf_main.c
--- linux-libre-4.14.27-gnu/drivers/net/ethernet/cavium/thunder/nicvf_main.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/net/ethernet/cavium/thunder/nicvf_main.c	2018-03-19 03:42:57.000000000 -0400
@@ -1832,6 +1832,11 @@ static int nicvf_probe(struct pci_dev *p
 	nic->pdev = pdev;
 	nic->pnicvf = nic;
 	nic->max_queues = qcount;
+	/* If no of CPUs are too low, there won't be any queues left
+	 * for XDP_TX, hence double it.
+	 */
+	if (!nic->t88)
+		nic->max_queues *= 2;
 
 	/* MAP VF's configuration registers */
 	nic->reg_base = pcim_iomap(pdev, PCI_CFG_REG_BAR_NUM, 0);
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/net/ieee802154/adf7242.c linux-libre-4.14.28-gnu/drivers/net/ieee802154/adf7242.c
--- linux-libre-4.14.27-gnu/drivers/net/ieee802154/adf7242.c	2018-03-15 08:31:48.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/net/ieee802154/adf7242.c	2018-03-19 08:38:44.000000000 -0400
@@ -888,7 +888,7 @@ static const struct ieee802154_ops adf72
 	.set_cca_ed_level = adf7242_set_cca_ed_level,
 };
 
-static void adf7242_debug(u8 irq1)
+static void adf7242_debug(struct adf7242_local *lp, u8 irq1)
 {
 #ifdef DEBUG
 	u8 stat;
@@ -932,7 +932,7 @@ static irqreturn_t adf7242_isr(int irq,
 		dev_err(&lp->spi->dev, "%s :ERROR IRQ1 = 0x%X\n",
 			__func__, irq1);
 
-	adf7242_debug(irq1);
+	adf7242_debug(lp, irq1);
 
 	xmit = test_bit(FLAG_XMIT, &lp->flags);
 
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/net/ipvlan/ipvlan_core.c linux-libre-4.14.28-gnu/drivers/net/ipvlan/ipvlan_core.c
--- linux-libre-4.14.27-gnu/drivers/net/ipvlan/ipvlan_core.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/net/ipvlan/ipvlan_core.c	2018-03-19 03:42:57.000000000 -0400
@@ -304,6 +304,10 @@ static int ipvlan_rcv_frame(struct ipvl_
 		if (dev_forward_skb(ipvlan->dev, skb) == NET_RX_SUCCESS)
 			success = true;
 	} else {
+		if (!ether_addr_equal_64bits(eth_hdr(skb)->h_dest,
+					     ipvlan->phy_dev->dev_addr))
+			skb->pkt_type = PACKET_OTHERHOST;
+
 		ret = RX_HANDLER_ANOTHER;
 		success = true;
 	}
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/net/phy/at803x.c linux-libre-4.14.28-gnu/drivers/net/phy/at803x.c
--- linux-libre-4.14.27-gnu/drivers/net/phy/at803x.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/net/phy/at803x.c	2018-03-19 03:42:57.000000000 -0400
@@ -239,14 +239,10 @@ static int at803x_resume(struct phy_devi
 {
 	int value;
 
-	mutex_lock(&phydev->lock);
-
 	value = phy_read(phydev, MII_BMCR);
 	value &= ~(BMCR_PDOWN | BMCR_ISOLATE);
 	phy_write(phydev, MII_BMCR, value);
 
-	mutex_unlock(&phydev->lock);
-
 	return 0;
 }
 
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/net/phy/phy.c linux-libre-4.14.28-gnu/drivers/net/phy/phy.c
--- linux-libre-4.14.27-gnu/drivers/net/phy/phy.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/net/phy/phy.c	2018-03-19 03:42:57.000000000 -0400
@@ -828,7 +828,6 @@ EXPORT_SYMBOL(phy_stop);
  */
 void phy_start(struct phy_device *phydev)
 {
-	bool do_resume = false;
 	int err = 0;
 
 	mutex_lock(&phydev->lock);
@@ -841,6 +840,9 @@ void phy_start(struct phy_device *phydev
 		phydev->state = PHY_UP;
 		break;
 	case PHY_HALTED:
+		/* if phy was suspended, bring the physical link up again */
+		__phy_resume(phydev);
+
 		/* make sure interrupts are re-enabled for the PHY */
 		if (phy_interrupt_is_valid(phydev)) {
 			err = phy_enable_interrupts(phydev);
@@ -849,17 +851,12 @@ void phy_start(struct phy_device *phydev
 		}
 
 		phydev->state = PHY_RESUMING;
-		do_resume = true;
 		break;
 	default:
 		break;
 	}
 	mutex_unlock(&phydev->lock);
 
-	/* if phy was suspended, bring the physical link up again */
-	if (do_resume)
-		phy_resume(phydev);
-
 	phy_trigger_machine(phydev, true);
 }
 EXPORT_SYMBOL(phy_start);
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/net/phy/phy_device.c linux-libre-4.14.28-gnu/drivers/net/phy/phy_device.c
--- linux-libre-4.14.27-gnu/drivers/net/phy/phy_device.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/net/phy/phy_device.c	2018-03-19 03:42:57.000000000 -0400
@@ -1152,11 +1152,13 @@ int phy_suspend(struct phy_device *phyde
 }
 EXPORT_SYMBOL(phy_suspend);
 
-int phy_resume(struct phy_device *phydev)
+int __phy_resume(struct phy_device *phydev)
 {
 	struct phy_driver *phydrv = to_phy_driver(phydev->mdio.dev.driver);
 	int ret = 0;
 
+	WARN_ON(!mutex_is_locked(&phydev->lock));
+
 	if (phydev->drv && phydrv->resume)
 		ret = phydrv->resume(phydev);
 
@@ -1167,6 +1169,18 @@ int phy_resume(struct phy_device *phydev
 
 	return ret;
 }
+EXPORT_SYMBOL(__phy_resume);
+
+int phy_resume(struct phy_device *phydev)
+{
+	int ret;
+
+	mutex_lock(&phydev->lock);
+	ret = __phy_resume(phydev);
+	mutex_unlock(&phydev->lock);
+
+	return ret;
+}
 EXPORT_SYMBOL(phy_resume);
 
 int phy_loopback(struct phy_device *phydev, bool enable)
@@ -1639,13 +1653,9 @@ int genphy_resume(struct phy_device *phy
 {
 	int value;
 
-	mutex_lock(&phydev->lock);
-
 	value = phy_read(phydev, MII_BMCR);
 	phy_write(phydev, MII_BMCR, value & ~BMCR_PDOWN);
 
-	mutex_unlock(&phydev->lock);
-
 	return 0;
 }
 EXPORT_SYMBOL(genphy_resume);
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/net/veth.c linux-libre-4.14.28-gnu/drivers/net/veth.c
--- linux-libre-4.14.27-gnu/drivers/net/veth.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/net/veth.c	2018-03-19 03:42:57.000000000 -0400
@@ -410,6 +410,9 @@ static int veth_newlink(struct net *src_
 	if (ifmp && (dev->ifindex != 0))
 		peer->ifindex = ifmp->ifi_index;
 
+	peer->gso_max_size = dev->gso_max_size;
+	peer->gso_max_segs = dev->gso_max_segs;
+
 	err = register_netdevice(peer);
 	put_net(net);
 	net = NULL;
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/net/virtio_net.c linux-libre-4.14.28-gnu/drivers/net/virtio_net.c
--- linux-libre-4.14.27-gnu/drivers/net/virtio_net.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/net/virtio_net.c	2018-03-19 03:42:57.000000000 -0400
@@ -260,9 +260,12 @@ static void virtqueue_napi_complete(stru
 	int opaque;
 
 	opaque = virtqueue_enable_cb_prepare(vq);
-	if (napi_complete_done(napi, processed) &&
-	    unlikely(virtqueue_poll(vq, opaque)))
-		virtqueue_napi_schedule(napi, vq);
+	if (napi_complete_done(napi, processed)) {
+		if (unlikely(virtqueue_poll(vq, opaque)))
+			virtqueue_napi_schedule(napi, vq);
+	} else {
+		virtqueue_disable_cb(vq);
+	}
 }
 
 static void skb_xmit_done(struct virtqueue *vq)
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/net/wireless/ath/ath10k/mac.c linux-libre-4.14.28-gnu/drivers/net/wireless/ath/ath10k/mac.c
--- linux-libre-4.14.27-gnu/drivers/net/wireless/ath/ath10k/mac.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/net/wireless/ath/ath10k/mac.c	2018-03-19 03:42:57.000000000 -0400
@@ -6183,6 +6183,16 @@ static int ath10k_sta_state(struct ieee8
 			   "mac vdev %d peer delete %pM sta %pK (sta gone)\n",
 			   arvif->vdev_id, sta->addr, sta);
 
+		if (sta->tdls) {
+			ret = ath10k_mac_tdls_peer_update(ar, arvif->vdev_id,
+							  sta,
+							  WMI_TDLS_PEER_STATE_TEARDOWN);
+			if (ret)
+				ath10k_warn(ar, "failed to update tdls peer state for %pM state %d: %i\n",
+					    sta->addr,
+					    WMI_TDLS_PEER_STATE_TEARDOWN, ret);
+		}
+
 		ret = ath10k_peer_delete(ar, arvif->vdev_id, sta->addr);
 		if (ret)
 			ath10k_warn(ar, "failed to delete peer %pM for vdev %d: %i\n",
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/net/wireless/ath/ath10k/wmi.h linux-libre-4.14.28-gnu/drivers/net/wireless/ath/ath10k/wmi.h
--- linux-libre-4.14.27-gnu/drivers/net/wireless/ath/ath10k/wmi.h	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/net/wireless/ath/ath10k/wmi.h	2018-03-19 03:42:57.000000000 -0400
@@ -5235,7 +5235,8 @@ enum wmi_10_4_vdev_param {
 #define WMI_VDEV_PARAM_TXBF_MU_TX_BFER BIT(3)
 
 #define WMI_TXBF_STS_CAP_OFFSET_LSB	4
-#define WMI_TXBF_STS_CAP_OFFSET_MASK	0xf0
+#define WMI_TXBF_STS_CAP_OFFSET_MASK	0x70
+#define WMI_TXBF_CONF_IMPLICIT_BF       BIT(7)
 #define WMI_BF_SOUND_DIM_OFFSET_LSB	8
 #define WMI_BF_SOUND_DIM_OFFSET_MASK	0xf00
 
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/net/wireless/intel/iwlwifi/mvm/rs.c linux-libre-4.14.28-gnu/drivers/net/wireless/intel/iwlwifi/mvm/rs.c
--- linux-libre-4.14.27-gnu/drivers/net/wireless/intel/iwlwifi/mvm/rs.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/net/wireless/intel/iwlwifi/mvm/rs.c	2018-03-19 03:42:57.000000000 -0400
@@ -1881,12 +1881,10 @@ static int rs_switch_to_column(struct iw
 	struct rs_rate *rate = &search_tbl->rate;
 	const struct rs_tx_column *column = &rs_tx_columns[col_id];
 	const struct rs_tx_column *curr_column = &rs_tx_columns[tbl->column];
-	u32 sz = (sizeof(struct iwl_scale_tbl_info) -
-		  (sizeof(struct iwl_rate_scale_data) * IWL_RATE_COUNT));
 	unsigned long rate_mask = 0;
 	u32 rate_idx = 0;
 
-	memcpy(search_tbl, tbl, sz);
+	memcpy(search_tbl, tbl, offsetof(struct iwl_scale_tbl_info, win));
 
 	rate->sgi = column->sgi;
 	rate->ant = column->ant;
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/net/wireless/intel/iwlwifi/mvm/utils.c linux-libre-4.14.28-gnu/drivers/net/wireless/intel/iwlwifi/mvm/utils.c
--- linux-libre-4.14.27-gnu/drivers/net/wireless/intel/iwlwifi/mvm/utils.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/net/wireless/intel/iwlwifi/mvm/utils.c	2018-03-19 03:42:57.000000000 -0400
@@ -603,6 +603,12 @@ static void iwl_mvm_dump_lmac_error_log(
 
 void iwl_mvm_dump_nic_error_log(struct iwl_mvm *mvm)
 {
+	if (!test_bit(STATUS_DEVICE_ENABLED, &mvm->trans->status)) {
+		IWL_ERR(mvm,
+			"DEVICE_ENABLED bit is not set. Aborting dump.\n");
+		return;
+	}
+
 	iwl_mvm_dump_lmac_error_log(mvm, mvm->error_event_table[0]);
 
 	if (mvm->error_event_table[1])
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/net/wireless/mac80211_hwsim.c linux-libre-4.14.28-gnu/drivers/net/wireless/mac80211_hwsim.c
--- linux-libre-4.14.27-gnu/drivers/net/wireless/mac80211_hwsim.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/net/wireless/mac80211_hwsim.c	2018-03-19 03:42:57.000000000 -0400
@@ -727,16 +727,21 @@ static int hwsim_fops_ps_write(void *dat
 	    val != PS_MANUAL_POLL)
 		return -EINVAL;
 
-	old_ps = data->ps;
-	data->ps = val;
-
-	local_bh_disable();
 	if (val == PS_MANUAL_POLL) {
+		if (data->ps != PS_ENABLED)
+			return -EINVAL;
+		local_bh_disable();
 		ieee80211_iterate_active_interfaces_atomic(
 			data->hw, IEEE80211_IFACE_ITER_NORMAL,
 			hwsim_send_ps_poll, data);
-		data->ps_poll_pending = true;
-	} else if (old_ps == PS_DISABLED && val != PS_DISABLED) {
+		local_bh_enable();
+		return 0;
+	}
+	old_ps = data->ps;
+	data->ps = val;
+
+	local_bh_disable();
+	if (old_ps == PS_DISABLED && val != PS_DISABLED) {
 		ieee80211_iterate_active_interfaces_atomic(
 			data->hw, IEEE80211_IFACE_ITER_NORMAL,
 			hwsim_send_nullfunc_ps, data);
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/net/wireless/marvell/mwifiex/cfg80211.c linux-libre-4.14.28-gnu/drivers/net/wireless/marvell/mwifiex/cfg80211.c
--- linux-libre-4.14.27-gnu/drivers/net/wireless/marvell/mwifiex/cfg80211.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/net/wireless/marvell/mwifiex/cfg80211.c	2018-03-19 03:42:57.000000000 -0400
@@ -1116,6 +1116,12 @@ mwifiex_cfg80211_change_virtual_intf(str
 	struct mwifiex_private *priv = mwifiex_netdev_get_priv(dev);
 	enum nl80211_iftype curr_iftype = dev->ieee80211_ptr->iftype;
 
+	if (priv->scan_request) {
+		mwifiex_dbg(priv->adapter, ERROR,
+			    "change virtual interface: scan in process\n");
+		return -EBUSY;
+	}
+
 	switch (curr_iftype) {
 	case NL80211_IFTYPE_ADHOC:
 		switch (type) {
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/pinctrl/sh-pfc/pfc-r8a7791.c linux-libre-4.14.28-gnu/drivers/pinctrl/sh-pfc/pfc-r8a7791.c
--- linux-libre-4.14.27-gnu/drivers/pinctrl/sh-pfc/pfc-r8a7791.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/pinctrl/sh-pfc/pfc-r8a7791.c	2018-03-19 03:42:57.000000000 -0400
@@ -4826,6 +4826,10 @@ static const char * const can0_groups[]
 	"can0_data_d",
 	"can0_data_e",
 	"can0_data_f",
+	/*
+	 * Retained for backwards compatibility, use can_clk_groups in new
+	 * designs.
+	 */
 	"can_clk",
 	"can_clk_b",
 	"can_clk_c",
@@ -4837,6 +4841,21 @@ static const char * const can1_groups[]
 	"can1_data_b",
 	"can1_data_c",
 	"can1_data_d",
+	/*
+	 * Retained for backwards compatibility, use can_clk_groups in new
+	 * designs.
+	 */
+	"can_clk",
+	"can_clk_b",
+	"can_clk_c",
+	"can_clk_d",
+};
+
+/*
+ * can_clk_groups allows for independent configuration, use can_clk function
+ * in new designs.
+ */
+static const char * const can_clk_groups[] = {
 	"can_clk",
 	"can_clk_b",
 	"can_clk_c",
@@ -5308,7 +5327,7 @@ static const char * const vin2_groups[]
 };
 
 static const struct {
-	struct sh_pfc_function common[56];
+	struct sh_pfc_function common[57];
 	struct sh_pfc_function r8a779x[2];
 } pinmux_functions = {
 	.common = {
@@ -5316,6 +5335,7 @@ static const struct {
 		SH_PFC_FUNCTION(avb),
 		SH_PFC_FUNCTION(can0),
 		SH_PFC_FUNCTION(can1),
+		SH_PFC_FUNCTION(can_clk),
 		SH_PFC_FUNCTION(du),
 		SH_PFC_FUNCTION(du0),
 		SH_PFC_FUNCTION(du1),
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/pinctrl/sh-pfc/pfc-r8a7795-es1.c linux-libre-4.14.28-gnu/drivers/pinctrl/sh-pfc/pfc-r8a7795-es1.c
--- linux-libre-4.14.27-gnu/drivers/pinctrl/sh-pfc/pfc-r8a7795-es1.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/pinctrl/sh-pfc/pfc-r8a7795-es1.c	2018-03-19 03:42:57.000000000 -0400
@@ -1397,7 +1397,7 @@ static const u16 pinmux_data[] = {
 	PINMUX_IPSR_MSEL(IP16_27_24,	AUDIO_CLKOUT_B,		SEL_ADG_1),
 	PINMUX_IPSR_MSEL(IP16_27_24,	SSI_SCK2_B,		SEL_SSI_1),
 	PINMUX_IPSR_MSEL(IP16_27_24,	TS_SDEN1_D,		SEL_TSIF1_3),
-	PINMUX_IPSR_MSEL(IP16_27_24,	STP_ISEN_1_D,		SEL_SSP1_1_2),
+	PINMUX_IPSR_MSEL(IP16_27_24,	STP_ISEN_1_D,		SEL_SSP1_1_3),
 	PINMUX_IPSR_MSEL(IP16_27_24,	STP_OPWM_0_E,		SEL_SSP1_0_4),
 	PINMUX_IPSR_MSEL(IP16_27_24,	RIF3_D0_B,		SEL_DRIF3_1),
 	PINMUX_IPSR_MSEL(IP16_27_24,	TCLK2_B,		SEL_TIMER_TMU_1),
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/power/supply/ab8500_charger.c linux-libre-4.14.28-gnu/drivers/power/supply/ab8500_charger.c
--- linux-libre-4.14.27-gnu/drivers/power/supply/ab8500_charger.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/power/supply/ab8500_charger.c	2018-03-19 03:42:57.000000000 -0400
@@ -3218,11 +3218,13 @@ static int ab8500_charger_init_hw_regist
 	}
 
 	/* Enable backup battery charging */
-	abx500_mask_and_set_register_interruptible(di->dev,
+	ret = abx500_mask_and_set_register_interruptible(di->dev,
 		AB8500_RTC, AB8500_RTC_CTRL_REG,
 		RTC_BUP_CH_ENA, RTC_BUP_CH_ENA);
-	if (ret < 0)
+	if (ret < 0) {
 		dev_err(di->dev, "%s mask and set failed\n", __func__);
+		goto out;
+	}
 
 	if (is_ab8540(di->parent)) {
 		ret = abx500_mask_and_set_register_interruptible(di->dev,
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/pwm/pwm-stmpe.c linux-libre-4.14.28-gnu/drivers/pwm/pwm-stmpe.c
--- linux-libre-4.14.27-gnu/drivers/pwm/pwm-stmpe.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/pwm/pwm-stmpe.c	2018-03-19 03:42:57.000000000 -0400
@@ -145,7 +145,7 @@ static int stmpe_24xx_pwm_config(struct
 		break;
 
 	case 2:
-		offset = STMPE24XX_PWMIC1;
+		offset = STMPE24XX_PWMIC2;
 		break;
 
 	default:
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/rtc/rtc-brcmstb-waketimer.c linux-libre-4.14.28-gnu/drivers/rtc/rtc-brcmstb-waketimer.c
--- linux-libre-4.14.27-gnu/drivers/rtc/rtc-brcmstb-waketimer.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/rtc/rtc-brcmstb-waketimer.c	2018-03-19 03:42:57.000000000 -0400
@@ -253,7 +253,7 @@ static int brcmstb_waketmr_probe(struct
 	ret = devm_request_irq(dev, timer->irq, brcmstb_waketmr_irq, 0,
 			       "brcmstb-waketimer", timer);
 	if (ret < 0)
-		return ret;
+		goto err_clk;
 
 	timer->reboot_notifier.notifier_call = brcmstb_waketmr_reboot;
 	register_reboot_notifier(&timer->reboot_notifier);
@@ -262,12 +262,21 @@ static int brcmstb_waketmr_probe(struct
 					 &brcmstb_waketmr_ops, THIS_MODULE);
 	if (IS_ERR(timer->rtc)) {
 		dev_err(dev, "unable to register device\n");
-		unregister_reboot_notifier(&timer->reboot_notifier);
-		return PTR_ERR(timer->rtc);
+		ret = PTR_ERR(timer->rtc);
+		goto err_notifier;
 	}
 
 	dev_info(dev, "registered, with irq %d\n", timer->irq);
 
+	return 0;
+
+err_notifier:
+	unregister_reboot_notifier(&timer->reboot_notifier);
+
+err_clk:
+	if (timer->clk)
+		clk_disable_unprepare(timer->clk);
+
 	return ret;
 }
 
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/scsi/scsi_devinfo.c linux-libre-4.14.28-gnu/drivers/scsi/scsi_devinfo.c
--- linux-libre-4.14.27-gnu/drivers/scsi/scsi_devinfo.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/scsi/scsi_devinfo.c	2018-03-19 03:42:57.000000000 -0400
@@ -181,7 +181,7 @@ static struct {
 	{"HITACHI", "6586-", "*", BLIST_SPARSELUN | BLIST_LARGELUN},
 	{"HITACHI", "6588-", "*", BLIST_SPARSELUN | BLIST_LARGELUN},
 	{"HP", "A6189A", NULL, BLIST_SPARSELUN | BLIST_LARGELUN},	/* HP VA7400 */
-	{"HP", "OPEN-", "*", BLIST_REPORTLUN2}, /* HP XP Arrays */
+	{"HP", "OPEN-", "*", BLIST_REPORTLUN2 | BLIST_TRY_VPD_PAGES}, /* HP XP Arrays */
 	{"HP", "NetRAID-4M", NULL, BLIST_FORCELUN},
 	{"HP", "HSV100", NULL, BLIST_REPORTLUN2 | BLIST_NOSTARTONADD},
 	{"HP", "C1557A", NULL, BLIST_FORCELUN},
@@ -595,17 +595,12 @@ int scsi_get_device_flags_keyed(struct s
 				int key)
 {
 	struct scsi_dev_info_list *devinfo;
-	int err;
 
 	devinfo = scsi_dev_info_list_find(vendor, model, key);
 	if (!IS_ERR(devinfo))
 		return devinfo->flags;
 
-	err = PTR_ERR(devinfo);
-	if (err != -ENOENT)
-		return err;
-
-	/* nothing found, return nothing */
+	/* key or device not found: return nothing */
 	if (key != SCSI_DEVINFO_GLOBAL)
 		return 0;
 
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/scsi/scsi_dh.c linux-libre-4.14.28-gnu/drivers/scsi/scsi_dh.c
--- linux-libre-4.14.27-gnu/drivers/scsi/scsi_dh.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/scsi/scsi_dh.c	2018-03-19 03:42:57.000000000 -0400
@@ -56,10 +56,13 @@ static const struct scsi_dh_blist scsi_d
 	{"IBM", "1815",			"rdac", },
 	{"IBM", "1818",			"rdac", },
 	{"IBM", "3526",			"rdac", },
+	{"IBM", "3542",			"rdac", },
+	{"IBM", "3552",			"rdac", },
 	{"SGI", "TP9",			"rdac", },
 	{"SGI", "IS",			"rdac", },
-	{"STK", "OPENstorage D280",	"rdac", },
+	{"STK", "OPENstorage",		"rdac", },
 	{"STK", "FLEXLINE 380",		"rdac", },
+	{"STK", "BladeCtlr",		"rdac", },
 	{"SUN", "CSM",			"rdac", },
 	{"SUN", "LCSM100",		"rdac", },
 	{"SUN", "STK6580_6780",		"rdac", },
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/scsi/ses.c linux-libre-4.14.28-gnu/drivers/scsi/ses.c
--- linux-libre-4.14.27-gnu/drivers/scsi/ses.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/scsi/ses.c	2018-03-19 03:42:57.000000000 -0400
@@ -615,13 +615,16 @@ static void ses_enclosure_data_process(s
 }
 
 static void ses_match_to_enclosure(struct enclosure_device *edev,
-				   struct scsi_device *sdev)
+				   struct scsi_device *sdev,
+				   int refresh)
 {
+	struct scsi_device *edev_sdev = to_scsi_device(edev->edev.parent);
 	struct efd efd = {
 		.addr = 0,
 	};
 
-	ses_enclosure_data_process(edev, to_scsi_device(edev->edev.parent), 0);
+	if (refresh)
+		ses_enclosure_data_process(edev, edev_sdev, 0);
 
 	if (scsi_is_sas_rphy(sdev->sdev_target->dev.parent))
 		efd.addr = sas_get_address(sdev);
@@ -652,7 +655,7 @@ static int ses_intf_add(struct device *c
 		struct enclosure_device *prev = NULL;
 
 		while ((edev = enclosure_find(&sdev->host->shost_gendev, prev)) != NULL) {
-			ses_match_to_enclosure(edev, sdev);
+			ses_match_to_enclosure(edev, sdev, 1);
 			prev = edev;
 		}
 		return -ENODEV;
@@ -768,7 +771,7 @@ page2_not_supported:
 	shost_for_each_device(tmp_sdev, sdev->host) {
 		if (tmp_sdev->lun != 0 || scsi_device_enclosure(tmp_sdev))
 			continue;
-		ses_match_to_enclosure(edev, tmp_sdev);
+		ses_match_to_enclosure(edev, tmp_sdev, 0);
 	}
 
 	return 0;
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/spi/spi-sun6i.c linux-libre-4.14.28-gnu/drivers/spi/spi-sun6i.c
--- linux-libre-4.14.27-gnu/drivers/spi/spi-sun6i.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/spi/spi-sun6i.c	2018-03-19 03:42:57.000000000 -0400
@@ -541,7 +541,7 @@ err_free_master:
 
 static int sun6i_spi_remove(struct platform_device *pdev)
 {
-	pm_runtime_disable(&pdev->dev);
+	pm_runtime_force_suspend(&pdev->dev);
 
 	return 0;
 }
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/staging/android/ashmem.c linux-libre-4.14.28-gnu/drivers/staging/android/ashmem.c
--- linux-libre-4.14.27-gnu/drivers/staging/android/ashmem.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/staging/android/ashmem.c	2018-03-19 03:42:57.000000000 -0400
@@ -334,24 +334,23 @@ static loff_t ashmem_llseek(struct file
 	mutex_lock(&ashmem_mutex);
 
 	if (asma->size == 0) {
-		ret = -EINVAL;
-		goto out;
+		mutex_unlock(&ashmem_mutex);
+		return -EINVAL;
 	}
 
 	if (!asma->file) {
-		ret = -EBADF;
-		goto out;
+		mutex_unlock(&ashmem_mutex);
+		return -EBADF;
 	}
 
+	mutex_unlock(&ashmem_mutex);
+
 	ret = vfs_llseek(asma->file, offset, origin);
 	if (ret < 0)
-		goto out;
+		return ret;
 
 	/** Copy f_pos from backing file, since f_ops->llseek() sets it */
 	file->f_pos = asma->file->f_pos;
-
-out:
-	mutex_unlock(&ashmem_mutex);
 	return ret;
 }
 
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/staging/comedi/drivers.c linux-libre-4.14.28-gnu/drivers/staging/comedi/drivers.c
--- linux-libre-4.14.27-gnu/drivers/staging/comedi/drivers.c	2018-03-15 08:33:58.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/staging/comedi/drivers.c	2018-03-19 08:41:12.000000000 -0400
@@ -484,8 +484,7 @@ unsigned int comedi_nsamples_left(struct
 	struct comedi_cmd *cmd = &async->cmd;
 
 	if (cmd->stop_src == TRIG_COUNT) {
-		unsigned int nscans = nsamples / cmd->scan_end_arg;
-		unsigned int scans_left = __comedi_nscans_left(s, nscans);
+		unsigned int scans_left = __comedi_nscans_left(s, cmd->stop_arg);
 		unsigned int scan_pos =
 		    comedi_bytes_to_samples(s, async->scan_progress);
 		unsigned long long samples_left = 0;
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/staging/rtlwifi/rtl8822be/fw.c linux-libre-4.14.28-gnu/drivers/staging/rtlwifi/rtl8822be/fw.c
--- linux-libre-4.14.27-gnu/drivers/staging/rtlwifi/rtl8822be/fw.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/staging/rtlwifi/rtl8822be/fw.c	2018-03-19 03:42:57.000000000 -0400
@@ -464,6 +464,8 @@ bool rtl8822b_halmac_cb_write_data_rsvd_
 	int count;
 
 	skb = dev_alloc_skb(size);
+	if (!skb)
+		return false;
 	memcpy((u8 *)skb_put(skb, size), buf, size);
 
 	if (!_rtl8822be_send_bcn_or_cmd_packet(rtlpriv->hw, skb, BEACON_QUEUE))
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/staging/typec/fusb302/fusb302.c linux-libre-4.14.28-gnu/drivers/staging/typec/fusb302/fusb302.c
--- linux-libre-4.14.27-gnu/drivers/staging/typec/fusb302/fusb302.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/staging/typec/fusb302/fusb302.c	2018-03-19 03:42:57.000000000 -0400
@@ -1552,6 +1552,21 @@ static int fusb302_pd_read_message(struc
 	fusb302_log(chip, "PD message header: %x", msg->header);
 	fusb302_log(chip, "PD message len: %d", len);
 
+	/*
+	 * Check if we've read off a GoodCRC message. If so then indicate to
+	 * TCPM that the previous transmission has completed. Otherwise we pass
+	 * the received message over to TCPM for processing.
+	 *
+	 * We make this check here instead of basing the reporting decision on
+	 * the IRQ event type, as it's possible for the chip to report the
+	 * TX_SUCCESS and GCRCSENT events out of order on occasion, so we need
+	 * to check the message type to ensure correct reporting to TCPM.
+	 */
+	if ((!len) && (pd_header_type_le(msg->header) == PD_CTRL_GOOD_CRC))
+		tcpm_pd_transmit_complete(chip->tcpm_port, TCPC_TX_SUCCESS);
+	else
+		tcpm_pd_receive(chip->tcpm_port, msg);
+
 	return ret;
 }
 
@@ -1659,13 +1674,12 @@ static irqreturn_t fusb302_irq_intn(int
 
 	if (interrupta & FUSB_REG_INTERRUPTA_TX_SUCCESS) {
 		fusb302_log(chip, "IRQ: PD tx success");
-		/* read out the received good CRC */
 		ret = fusb302_pd_read_message(chip, &pd_msg);
 		if (ret < 0) {
-			fusb302_log(chip, "cannot read in GCRC, ret=%d", ret);
+			fusb302_log(chip,
+				    "cannot read in PD message, ret=%d", ret);
 			goto done;
 		}
-		tcpm_pd_transmit_complete(chip->tcpm_port, TCPC_TX_SUCCESS);
 	}
 
 	if (interrupta & FUSB_REG_INTERRUPTA_HARDRESET) {
@@ -1686,7 +1700,6 @@ static irqreturn_t fusb302_irq_intn(int
 				    "cannot read in PD message, ret=%d", ret);
 			goto done;
 		}
-		tcpm_pd_receive(chip->tcpm_port, &pd_msg);
 	}
 done:
 	mutex_unlock(&chip->lock);
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/tty/serial/8250/8250_pci.c linux-libre-4.14.28-gnu/drivers/tty/serial/8250/8250_pci.c
--- linux-libre-4.14.27-gnu/drivers/tty/serial/8250/8250_pci.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/tty/serial/8250/8250_pci.c	2018-03-19 03:42:57.000000000 -0400
@@ -4701,6 +4701,17 @@ static const struct pci_device_id serial
 		PCI_ANY_ID, PCI_ANY_ID, 0, 0,    /* 135a.0dc0 */
 		pbn_b2_4_115200 },
 	/*
+	 * BrainBoxes UC-260
+	 */
+	{	PCI_VENDOR_ID_INTASHIELD, 0x0D21,
+		PCI_ANY_ID, PCI_ANY_ID,
+		PCI_CLASS_COMMUNICATION_MULTISERIAL << 8, 0xffff00,
+		pbn_b2_4_115200 },
+	{	PCI_VENDOR_ID_INTASHIELD, 0x0E34,
+		PCI_ANY_ID, PCI_ANY_ID,
+		 PCI_CLASS_COMMUNICATION_MULTISERIAL << 8, 0xffff00,
+		pbn_b2_4_115200 },
+	/*
 	 * Perle PCI-RAS cards
 	 */
 	{       PCI_VENDOR_ID_PLX, PCI_DEVICE_ID_PLX_9030,
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/tty/serial/atmel_serial.c linux-libre-4.14.28-gnu/drivers/tty/serial/atmel_serial.c
--- linux-libre-4.14.27-gnu/drivers/tty/serial/atmel_serial.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/tty/serial/atmel_serial.c	2018-03-19 03:42:57.000000000 -0400
@@ -1763,6 +1763,7 @@ static void atmel_get_ip_name(struct uar
 		switch (version) {
 		case 0x302:
 		case 0x10213:
+		case 0x10302:
 			dev_dbg(port->dev, "This version is usart\n");
 			atmel_port->has_frac_baudrate = true;
 			atmel_port->has_hw_timer = true;
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/tty/serial/earlycon.c linux-libre-4.14.28-gnu/drivers/tty/serial/earlycon.c
--- linux-libre-4.14.27-gnu/drivers/tty/serial/earlycon.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/tty/serial/earlycon.c	2018-03-19 03:42:57.000000000 -0400
@@ -253,11 +253,12 @@ int __init of_setup_earlycon(const struc
 	}
 	port->mapbase = addr;
 	port->uartclk = BASE_BAUD * 16;
-	port->membase = earlycon_map(port->mapbase, SZ_4K);
 
 	val = of_get_flat_dt_prop(node, "reg-offset", NULL);
 	if (val)
 		port->mapbase += be32_to_cpu(*val);
+	port->membase = earlycon_map(port->mapbase, SZ_4K);
+
 	val = of_get_flat_dt_prop(node, "reg-shift", NULL);
 	if (val)
 		port->regshift = be32_to_cpu(*val);
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/tty/serial/serial_core.c linux-libre-4.14.28-gnu/drivers/tty/serial/serial_core.c
--- linux-libre-4.14.27-gnu/drivers/tty/serial/serial_core.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/tty/serial/serial_core.c	2018-03-19 03:42:57.000000000 -0400
@@ -1157,6 +1157,8 @@ static int uart_do_autoconfig(struct tty
 		uport->ops->config_port(uport, flags);
 
 		ret = uart_startup(tty, state, 1);
+		if (ret == 0)
+			tty_port_set_initialized(port, true);
 		if (ret > 0)
 			ret = 0;
 	}
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/tty/serial/sh-sci.c linux-libre-4.14.28-gnu/drivers/tty/serial/sh-sci.c
--- linux-libre-4.14.27-gnu/drivers/tty/serial/sh-sci.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/tty/serial/sh-sci.c	2018-03-19 03:42:57.000000000 -0400
@@ -886,6 +886,8 @@ static void sci_receive_chars(struct uar
 		/* Tell the rest of the system the news. New characters! */
 		tty_flip_buffer_push(tport);
 	} else {
+		/* TTY buffers full; read from RX reg to prevent lockup */
+		serial_port_in(port, SCxRDR);
 		serial_port_in(port, SCxSR); /* dummy read */
 		sci_clear_SCxSR(port, SCxSR_RDxF_CLEAR(port));
 	}
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/usb/core/ledtrig-usbport.c linux-libre-4.14.28-gnu/drivers/usb/core/ledtrig-usbport.c
--- linux-libre-4.14.27-gnu/drivers/usb/core/ledtrig-usbport.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/usb/core/ledtrig-usbport.c	2018-03-19 03:42:57.000000000 -0400
@@ -140,11 +140,17 @@ static bool usbport_trig_port_observed(s
 	if (!led_np)
 		return false;
 
-	/* Get node of port being added */
+	/*
+	 * Get node of port being added
+	 *
+	 * FIXME: This is really the device node of the connected device
+	 */
 	port_np = usb_of_get_child_node(usb_dev->dev.of_node, port1);
 	if (!port_np)
 		return false;
 
+	of_node_put(port_np);
+
 	/* Amount of trigger sources for this LED */
 	count = of_count_phandle_with_args(led_np, "trigger-sources",
 					   "#trigger-source-cells");
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/usb/core/message.c linux-libre-4.14.28-gnu/drivers/usb/core/message.c
--- linux-libre-4.14.27-gnu/drivers/usb/core/message.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/usb/core/message.c	2018-03-19 03:42:57.000000000 -0400
@@ -150,6 +150,10 @@ int usb_control_msg(struct usb_device *d
 
 	ret = usb_internal_control_msg(dev, pipe, dr, data, size, timeout);
 
+	/* Linger a bit, prior to the next control message. */
+	if (dev->quirks & USB_QUIRK_DELAY_CTRL_MSG)
+		msleep(200);
+
 	kfree(dr);
 
 	return ret;
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/usb/core/quirks.c linux-libre-4.14.28-gnu/drivers/usb/core/quirks.c
--- linux-libre-4.14.27-gnu/drivers/usb/core/quirks.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/usb/core/quirks.c	2018-03-19 03:42:57.000000000 -0400
@@ -229,7 +229,8 @@ static const struct usb_device_id usb_qu
 	{ USB_DEVICE(0x1b1c, 0x1b13), .driver_info = USB_QUIRK_DELAY_INIT },
 
 	/* Corsair Strafe RGB */
-	{ USB_DEVICE(0x1b1c, 0x1b20), .driver_info = USB_QUIRK_DELAY_INIT },
+	{ USB_DEVICE(0x1b1c, 0x1b20), .driver_info = USB_QUIRK_DELAY_INIT |
+	  USB_QUIRK_DELAY_CTRL_MSG },
 
 	/* Corsair K70 LUX */
 	{ USB_DEVICE(0x1b1c, 0x1b36), .driver_info = USB_QUIRK_DELAY_INIT },
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/usb/dwc3/core.c linux-libre-4.14.28-gnu/drivers/usb/dwc3/core.c
--- linux-libre-4.14.27-gnu/drivers/usb/dwc3/core.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/usb/dwc3/core.c	2018-03-19 03:42:57.000000000 -0400
@@ -186,7 +186,7 @@ void dwc3_set_mode(struct dwc3 *dwc, u32
 	dwc->desired_dr_role = mode;
 	spin_unlock_irqrestore(&dwc->lock, flags);
 
-	queue_work(system_power_efficient_wq, &dwc->drd_work);
+	queue_work(system_freezable_wq, &dwc->drd_work);
 }
 
 u32 dwc3_core_fifo_space(struct dwc3_ep *dep, u8 type)
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/usb/gadget/function/f_fs.c linux-libre-4.14.28-gnu/drivers/usb/gadget/function/f_fs.c
--- linux-libre-4.14.27-gnu/drivers/usb/gadget/function/f_fs.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/usb/gadget/function/f_fs.c	2018-03-19 03:42:57.000000000 -0400
@@ -1539,7 +1539,6 @@ ffs_fs_kill_sb(struct super_block *sb)
 	if (sb->s_fs_info) {
 		ffs_release_dev(sb->s_fs_info);
 		ffs_data_closed(sb->s_fs_info);
-		ffs_data_put(sb->s_fs_info);
 	}
 }
 
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/usb/host/xhci.c linux-libre-4.14.28-gnu/drivers/usb/host/xhci.c
--- linux-libre-4.14.27-gnu/drivers/usb/host/xhci.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/usb/host/xhci.c	2018-03-19 03:42:57.000000000 -0400
@@ -887,6 +887,9 @@ int xhci_suspend(struct xhci_hcd *xhci,
 	clear_bit(HCD_FLAG_POLL_RH, &xhci->shared_hcd->flags);
 	del_timer_sync(&xhci->shared_hcd->rh_timer);
 
+	if (xhci->quirks & XHCI_SUSPEND_DELAY)
+		usleep_range(1000, 1500);
+
 	spin_lock_irq(&xhci->lock);
 	clear_bit(HCD_FLAG_HW_ACCESSIBLE, &hcd->flags);
 	clear_bit(HCD_FLAG_HW_ACCESSIBLE, &xhci->shared_hcd->flags);
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/usb/host/xhci.h linux-libre-4.14.28-gnu/drivers/usb/host/xhci.h
--- linux-libre-4.14.27-gnu/drivers/usb/host/xhci.h	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/usb/host/xhci.h	2018-03-19 03:42:57.000000000 -0400
@@ -728,11 +728,12 @@ struct xhci_ep_ctx {
 /* bits 10:14 are Max Primary Streams */
 /* bit 15 is Linear Stream Array */
 /* Interval - period between requests to an endpoint - 125u increments. */
-#define EP_INTERVAL(p)		(((p) & 0xff) << 16)
-#define EP_INTERVAL_TO_UFRAMES(p)		(1 << (((p) >> 16) & 0xff))
-#define CTX_TO_EP_INTERVAL(p)	(((p) >> 16) & 0xff)
-#define EP_MAXPSTREAMS_MASK	(0x1f << 10)
-#define EP_MAXPSTREAMS(p)	(((p) << 10) & EP_MAXPSTREAMS_MASK)
+#define EP_INTERVAL(p)			(((p) & 0xff) << 16)
+#define EP_INTERVAL_TO_UFRAMES(p)	(1 << (((p) >> 16) & 0xff))
+#define CTX_TO_EP_INTERVAL(p)		(((p) >> 16) & 0xff)
+#define EP_MAXPSTREAMS_MASK		(0x1f << 10)
+#define EP_MAXPSTREAMS(p)		(((p) << 10) & EP_MAXPSTREAMS_MASK)
+#define CTX_TO_EP_MAXPSTREAMS(p)	(((p) & EP_MAXPSTREAMS_MASK) >> 10)
 /* Endpoint is set up with a Linear Stream Array (vs. Secondary Stream Array) */
 #define	EP_HAS_LSA		(1 << 15)
 /* hosts with LEC=1 use bits 31:24 as ESIT high bits. */
@@ -1830,6 +1831,7 @@ struct xhci_hcd {
 #define XHCI_LIMIT_ENDPOINT_INTERVAL_7	(1 << 26)
 /* Reserved. It was XHCI_U2_DISABLE_WAKE */
 #define XHCI_ASMEDIA_MODIFY_FLOWCONTROL	(1 << 28)
+#define XHCI_SUSPEND_DELAY	(1 << 30)
 
 	unsigned int		num_active_eps;
 	unsigned int		limit_active_eps;
@@ -2539,21 +2541,22 @@ static inline const char *xhci_decode_ep
 	u8 burst;
 	u8 cerr;
 	u8 mult;
-	u8 lsa;
-	u8 hid;
+
+	bool lsa;
+	bool hid;
 
 	esit = CTX_TO_MAX_ESIT_PAYLOAD_HI(info) << 16 |
 		CTX_TO_MAX_ESIT_PAYLOAD(tx_info);
 
 	ep_state = info & EP_STATE_MASK;
-	max_pstr = info & EP_MAXPSTREAMS_MASK;
+	max_pstr = CTX_TO_EP_MAXPSTREAMS(info);
 	interval = CTX_TO_EP_INTERVAL(info);
 	mult = CTX_TO_EP_MULT(info) + 1;
-	lsa = info & EP_HAS_LSA;
+	lsa = !!(info & EP_HAS_LSA);
 
 	cerr = (info2 & (3 << 1)) >> 1;
 	ep_type = CTX_TO_EP_TYPE(info2);
-	hid = info2 & (1 << 7);
+	hid = !!(info2 & (1 << 7));
 	burst = CTX_TO_MAX_BURST(info2);
 	maxp = MAX_PACKET_DECODED(info2);
 
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/usb/host/xhci-pci.c linux-libre-4.14.28-gnu/drivers/usb/host/xhci-pci.c
--- linux-libre-4.14.27-gnu/drivers/usb/host/xhci-pci.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/usb/host/xhci-pci.c	2018-03-19 03:42:57.000000000 -0400
@@ -134,6 +134,9 @@ static void xhci_pci_quirks(struct devic
 	if (pdev->vendor == PCI_VENDOR_ID_AMD && usb_amd_find_chipset_info())
 		xhci->quirks |= XHCI_AMD_PLL_FIX;
 
+	if (pdev->vendor == PCI_VENDOR_ID_AMD && pdev->device == 0x43bb)
+		xhci->quirks |= XHCI_SUSPEND_DELAY;
+
 	if (pdev->vendor == PCI_VENDOR_ID_AMD)
 		xhci->quirks |= XHCI_TRUST_TX_LENGTH;
 
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/usb/host/xhci-rcar.c linux-libre-4.14.28-gnu/drivers/usb/host/xhci-rcar.c
--- linux-libre-4.14.27-gnu/drivers/usb/host/xhci-rcar.c	2018-03-15 08:35:17.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/usb/host/xhci-rcar.c	2018-03-19 08:42:43.000000000 -0400
@@ -84,6 +84,10 @@ static const struct soc_device_attribute
 		.soc_id = "r8a7796",
 		.data = (void *)RCAR_XHCI_FIRMWARE_V3,
 	},
+	{
+		.soc_id = "r8a77965",
+		.data = (void *)RCAR_XHCI_FIRMWARE_V3,
+	},
 	{ /* sentinel */ },
 };
 
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/usb/mon/mon_text.c linux-libre-4.14.28-gnu/drivers/usb/mon/mon_text.c
--- linux-libre-4.14.27-gnu/drivers/usb/mon/mon_text.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/usb/mon/mon_text.c	2018-03-19 03:42:57.000000000 -0400
@@ -85,6 +85,8 @@ struct mon_reader_text {
 
 	wait_queue_head_t wait;
 	int printf_size;
+	size_t printf_offset;
+	size_t printf_togo;
 	char *printf_buf;
 	struct mutex printf_lock;
 
@@ -376,75 +378,103 @@ err_alloc:
 	return rc;
 }
 
-/*
- * For simplicity, we read one record in one system call and throw out
- * what does not fit. This means that the following does not work:
- *   dd if=/dbg/usbmon/0t bs=10
- * Also, we do not allow seeks and do not bother advancing the offset.
- */
+static ssize_t mon_text_copy_to_user(struct mon_reader_text *rp,
+    char __user * const buf, const size_t nbytes)
+{
+	const size_t togo = min(nbytes, rp->printf_togo);
+
+	if (copy_to_user(buf, &rp->printf_buf[rp->printf_offset], togo))
+		return -EFAULT;
+	rp->printf_togo -= togo;
+	rp->printf_offset += togo;
+	return togo;
+}
+
+/* ppos is not advanced since the llseek operation is not permitted. */
 static ssize_t mon_text_read_t(struct file *file, char __user *buf,
-				size_t nbytes, loff_t *ppos)
+    size_t nbytes, loff_t *ppos)
 {
 	struct mon_reader_text *rp = file->private_data;
 	struct mon_event_text *ep;
 	struct mon_text_ptr ptr;
+	ssize_t ret;
 
-	ep = mon_text_read_wait(rp, file);
-	if (IS_ERR(ep))
-		return PTR_ERR(ep);
 	mutex_lock(&rp->printf_lock);
-	ptr.cnt = 0;
-	ptr.pbuf = rp->printf_buf;
-	ptr.limit = rp->printf_size;
 
-	mon_text_read_head_t(rp, &ptr, ep);
-	mon_text_read_statset(rp, &ptr, ep);
-	ptr.cnt += snprintf(ptr.pbuf + ptr.cnt, ptr.limit - ptr.cnt,
-	    " %d", ep->length);
-	mon_text_read_data(rp, &ptr, ep);
+	if (rp->printf_togo == 0) {
 
-	if (copy_to_user(buf, rp->printf_buf, ptr.cnt))
-		ptr.cnt = -EFAULT;
+		ep = mon_text_read_wait(rp, file);
+		if (IS_ERR(ep)) {
+			mutex_unlock(&rp->printf_lock);
+			return PTR_ERR(ep);
+		}
+		ptr.cnt = 0;
+		ptr.pbuf = rp->printf_buf;
+		ptr.limit = rp->printf_size;
+
+		mon_text_read_head_t(rp, &ptr, ep);
+		mon_text_read_statset(rp, &ptr, ep);
+		ptr.cnt += snprintf(ptr.pbuf + ptr.cnt, ptr.limit - ptr.cnt,
+		    " %d", ep->length);
+		mon_text_read_data(rp, &ptr, ep);
+
+		rp->printf_togo = ptr.cnt;
+		rp->printf_offset = 0;
+
+		kmem_cache_free(rp->e_slab, ep);
+	}
+
+	ret = mon_text_copy_to_user(rp, buf, nbytes);
 	mutex_unlock(&rp->printf_lock);
-	kmem_cache_free(rp->e_slab, ep);
-	return ptr.cnt;
+	return ret;
 }
 
+/* ppos is not advanced since the llseek operation is not permitted. */
 static ssize_t mon_text_read_u(struct file *file, char __user *buf,
-				size_t nbytes, loff_t *ppos)
+    size_t nbytes, loff_t *ppos)
 {
 	struct mon_reader_text *rp = file->private_data;
 	struct mon_event_text *ep;
 	struct mon_text_ptr ptr;
+	ssize_t ret;
 
-	ep = mon_text_read_wait(rp, file);
-	if (IS_ERR(ep))
-		return PTR_ERR(ep);
 	mutex_lock(&rp->printf_lock);
-	ptr.cnt = 0;
-	ptr.pbuf = rp->printf_buf;
-	ptr.limit = rp->printf_size;
 
-	mon_text_read_head_u(rp, &ptr, ep);
-	if (ep->type == 'E') {
-		mon_text_read_statset(rp, &ptr, ep);
-	} else if (ep->xfertype == USB_ENDPOINT_XFER_ISOC) {
-		mon_text_read_isostat(rp, &ptr, ep);
-		mon_text_read_isodesc(rp, &ptr, ep);
-	} else if (ep->xfertype == USB_ENDPOINT_XFER_INT) {
-		mon_text_read_intstat(rp, &ptr, ep);
-	} else {
-		mon_text_read_statset(rp, &ptr, ep);
+	if (rp->printf_togo == 0) {
+
+		ep = mon_text_read_wait(rp, file);
+		if (IS_ERR(ep)) {
+			mutex_unlock(&rp->printf_lock);
+			return PTR_ERR(ep);
+		}
+		ptr.cnt = 0;
+		ptr.pbuf = rp->printf_buf;
+		ptr.limit = rp->printf_size;
+
+		mon_text_read_head_u(rp, &ptr, ep);
+		if (ep->type == 'E') {
+			mon_text_read_statset(rp, &ptr, ep);
+		} else if (ep->xfertype == USB_ENDPOINT_XFER_ISOC) {
+			mon_text_read_isostat(rp, &ptr, ep);
+			mon_text_read_isodesc(rp, &ptr, ep);
+		} else if (ep->xfertype == USB_ENDPOINT_XFER_INT) {
+			mon_text_read_intstat(rp, &ptr, ep);
+		} else {
+			mon_text_read_statset(rp, &ptr, ep);
+		}
+		ptr.cnt += snprintf(ptr.pbuf + ptr.cnt, ptr.limit - ptr.cnt,
+		    " %d", ep->length);
+		mon_text_read_data(rp, &ptr, ep);
+
+		rp->printf_togo = ptr.cnt;
+		rp->printf_offset = 0;
+
+		kmem_cache_free(rp->e_slab, ep);
 	}
-	ptr.cnt += snprintf(ptr.pbuf + ptr.cnt, ptr.limit - ptr.cnt,
-	    " %d", ep->length);
-	mon_text_read_data(rp, &ptr, ep);
 
-	if (copy_to_user(buf, rp->printf_buf, ptr.cnt))
-		ptr.cnt = -EFAULT;
+	ret = mon_text_copy_to_user(rp, buf, nbytes);
 	mutex_unlock(&rp->printf_lock);
-	kmem_cache_free(rp->e_slab, ep);
-	return ptr.cnt;
+	return ret;
 }
 
 static struct mon_event_text *mon_text_read_wait(struct mon_reader_text *rp,
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/usb/storage/uas.c linux-libre-4.14.28-gnu/drivers/usb/storage/uas.c
--- linux-libre-4.14.27-gnu/drivers/usb/storage/uas.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/usb/storage/uas.c	2018-03-19 03:42:57.000000000 -0400
@@ -1076,7 +1076,7 @@ static int uas_post_reset(struct usb_int
 		return 0;
 
 	err = uas_configure_endpoints(devinfo);
-	if (err && err != ENODEV)
+	if (err && err != -ENODEV)
 		shost_printk(KERN_ERR, shost,
 			     "%s: alloc streams error %d after reset",
 			     __func__, err);
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/usb/storage/unusual_devs.h linux-libre-4.14.28-gnu/drivers/usb/storage/unusual_devs.h
--- linux-libre-4.14.27-gnu/drivers/usb/storage/unusual_devs.h	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/usb/storage/unusual_devs.h	2018-03-19 03:42:57.000000000 -0400
@@ -2137,6 +2137,13 @@ UNUSUAL_DEV(  0x152d, 0x2566, 0x0114, 0x
 		USB_SC_DEVICE, USB_PR_DEVICE, NULL,
 		US_FL_BROKEN_FUA ),
 
+/* Reported by Teijo Kinnunen <teijo.kinnunen@code-q.fi> */
+UNUSUAL_DEV(  0x152d, 0x2567, 0x0117, 0x0117,
+		"JMicron",
+		"USB to ATA/ATAPI Bridge",
+		USB_SC_DEVICE, USB_PR_DEVICE, NULL,
+		US_FL_BROKEN_FUA ),
+
 /* Reported-by George Cherian <george.cherian@cavium.com> */
 UNUSUAL_DEV(0x152d, 0x9561, 0x0000, 0x9999,
 		"JMicron",
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/usb/usbip/vudc_sysfs.c linux-libre-4.14.28-gnu/drivers/usb/usbip/vudc_sysfs.c
--- linux-libre-4.14.27-gnu/drivers/usb/usbip/vudc_sysfs.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/usb/usbip/vudc_sysfs.c	2018-03-19 03:42:57.000000000 -0400
@@ -117,10 +117,14 @@ static ssize_t store_sockfd(struct devic
 	if (rv != 0)
 		return -EINVAL;
 
+	if (!udc) {
+		dev_err(dev, "no device");
+		return -ENODEV;
+	}
 	spin_lock_irqsave(&udc->lock, flags);
 	/* Don't export what we don't have */
-	if (!udc || !udc->driver || !udc->pullup) {
-		dev_err(dev, "no device or gadget not bound");
+	if (!udc->driver || !udc->pullup) {
+		dev_err(dev, "gadget not bound");
 		ret = -ENODEV;
 		goto unlock;
 	}
diff -druNp --no-dereference linux-libre-4.14.27-gnu/drivers/video/hdmi.c linux-libre-4.14.28-gnu/drivers/video/hdmi.c
--- linux-libre-4.14.27-gnu/drivers/video/hdmi.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/drivers/video/hdmi.c	2018-03-19 03:42:57.000000000 -0400
@@ -321,6 +321,17 @@ int hdmi_vendor_infoframe_init(struct hd
 }
 EXPORT_SYMBOL(hdmi_vendor_infoframe_init);
 
+static int hdmi_vendor_infoframe_length(const struct hdmi_vendor_infoframe *frame)
+{
+	/* for side by side (half) we also need to provide 3D_Ext_Data */
+	if (frame->s3d_struct >= HDMI_3D_STRUCTURE_SIDE_BY_SIDE_HALF)
+		return 6;
+	else if (frame->vic != 0 || frame->s3d_struct != HDMI_3D_STRUCTURE_INVALID)
+		return 5;
+	else
+		return 4;
+}
+
 /**
  * hdmi_vendor_infoframe_pack() - write a HDMI vendor infoframe to binary buffer
  * @frame: HDMI infoframe
@@ -341,19 +352,11 @@ ssize_t hdmi_vendor_infoframe_pack(struc
 	u8 *ptr = buffer;
 	size_t length;
 
-	/* empty info frame */
-	if (frame->vic == 0 && frame->s3d_struct == HDMI_3D_STRUCTURE_INVALID)
-		return -EINVAL;
-
 	/* only one of those can be supplied */
 	if (frame->vic != 0 && frame->s3d_struct != HDMI_3D_STRUCTURE_INVALID)
 		return -EINVAL;
 
-	/* for side by side (half) we also need to provide 3D_Ext_Data */
-	if (frame->s3d_struct >= HDMI_3D_STRUCTURE_SIDE_BY_SIDE_HALF)
-		frame->length = 6;
-	else
-		frame->length = 5;
+	frame->length = hdmi_vendor_infoframe_length(frame);
 
 	length = HDMI_INFOFRAME_HEADER_SIZE + frame->length;
 
@@ -372,14 +375,16 @@ ssize_t hdmi_vendor_infoframe_pack(struc
 	ptr[5] = 0x0c;
 	ptr[6] = 0x00;
 
-	if (frame->vic) {
-		ptr[7] = 0x1 << 5;	/* video format */
-		ptr[8] = frame->vic;
-	} else {
+	if (frame->s3d_struct != HDMI_3D_STRUCTURE_INVALID) {
 		ptr[7] = 0x2 << 5;	/* video format */
 		ptr[8] = (frame->s3d_struct & 0xf) << 4;
 		if (frame->s3d_struct >= HDMI_3D_STRUCTURE_SIDE_BY_SIDE_HALF)
 			ptr[9] = (frame->s3d_ext_data & 0xf) << 4;
+	} else if (frame->vic) {
+		ptr[7] = 0x1 << 5;	/* video format */
+		ptr[8] = frame->vic;
+	} else {
+		ptr[7] = 0x0 << 5;	/* video format */
 	}
 
 	hdmi_infoframe_set_checksum(buffer, length);
@@ -1165,7 +1170,7 @@ hdmi_vendor_any_infoframe_unpack(union h
 
 	if (ptr[0] != HDMI_INFOFRAME_TYPE_VENDOR ||
 	    ptr[1] != 1 ||
-	    (ptr[2] != 5 && ptr[2] != 6))
+	    (ptr[2] != 4 && ptr[2] != 5 && ptr[2] != 6))
 		return -EINVAL;
 
 	length = ptr[2];
@@ -1193,16 +1198,22 @@ hdmi_vendor_any_infoframe_unpack(union h
 
 	hvf->length = length;
 
-	if (hdmi_video_format == 0x1) {
-		hvf->vic = ptr[4];
-	} else if (hdmi_video_format == 0x2) {
+	if (hdmi_video_format == 0x2) {
+		if (length != 5 && length != 6)
+			return -EINVAL;
 		hvf->s3d_struct = ptr[4] >> 4;
 		if (hvf->s3d_struct >= HDMI_3D_STRUCTURE_SIDE_BY_SIDE_HALF) {
-			if (length == 6)
-				hvf->s3d_ext_data = ptr[5] >> 4;
-			else
+			if (length != 6)
 				return -EINVAL;
+			hvf->s3d_ext_data = ptr[5] >> 4;
 		}
+	} else if (hdmi_video_format == 0x1) {
+		if (length != 5)
+			return -EINVAL;
+		hvf->vic = ptr[4];
+	} else {
+		if (length != 4)
+			return -EINVAL;
 	}
 
 	return 0;
diff -druNp --no-dereference linux-libre-4.14.27-gnu/fs/btrfs/sysfs.c linux-libre-4.14.28-gnu/fs/btrfs/sysfs.c
--- linux-libre-4.14.27-gnu/fs/btrfs/sysfs.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/fs/btrfs/sysfs.c	2018-03-19 03:42:57.000000000 -0400
@@ -422,7 +422,7 @@ static ssize_t btrfs_nodesize_show(struc
 {
 	struct btrfs_fs_info *fs_info = to_fs_info(kobj);
 
-	return snprintf(buf, PAGE_SIZE, "%u\n", fs_info->nodesize);
+	return snprintf(buf, PAGE_SIZE, "%u\n", fs_info->super_copy->nodesize);
 }
 
 BTRFS_ATTR(nodesize, btrfs_nodesize_show);
@@ -432,7 +432,8 @@ static ssize_t btrfs_sectorsize_show(str
 {
 	struct btrfs_fs_info *fs_info = to_fs_info(kobj);
 
-	return snprintf(buf, PAGE_SIZE, "%u\n", fs_info->sectorsize);
+	return snprintf(buf, PAGE_SIZE, "%u\n",
+			fs_info->super_copy->sectorsize);
 }
 
 BTRFS_ATTR(sectorsize, btrfs_sectorsize_show);
@@ -442,7 +443,8 @@ static ssize_t btrfs_clone_alignment_sho
 {
 	struct btrfs_fs_info *fs_info = to_fs_info(kobj);
 
-	return snprintf(buf, PAGE_SIZE, "%u\n", fs_info->sectorsize);
+	return snprintf(buf, PAGE_SIZE, "%u\n",
+			fs_info->super_copy->sectorsize);
 }
 
 BTRFS_ATTR(clone_alignment, btrfs_clone_alignment_show);
diff -druNp --no-dereference linux-libre-4.14.27-gnu/fs/btrfs/transaction.c linux-libre-4.14.28-gnu/fs/btrfs/transaction.c
--- linux-libre-4.14.27-gnu/fs/btrfs/transaction.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/fs/btrfs/transaction.c	2018-03-19 03:42:57.000000000 -0400
@@ -1722,23 +1722,19 @@ static void update_super_roots(struct bt
 
 	super = fs_info->super_copy;
 
-	/* update latest btrfs_super_block::chunk_root refs */
 	root_item = &fs_info->chunk_root->root_item;
-	btrfs_set_super_chunk_root(super, root_item->bytenr);
-	btrfs_set_super_chunk_root_generation(super, root_item->generation);
-	btrfs_set_super_chunk_root_level(super, root_item->level);
+	super->chunk_root = root_item->bytenr;
+	super->chunk_root_generation = root_item->generation;
+	super->chunk_root_level = root_item->level;
 
-	/* update latest btrfs_super_block::root refs */
 	root_item = &fs_info->tree_root->root_item;
-	btrfs_set_super_root(super, root_item->bytenr);
-	btrfs_set_super_generation(super, root_item->generation);
-	btrfs_set_super_root_level(super, root_item->level);
-
+	super->root = root_item->bytenr;
+	super->generation = root_item->generation;
+	super->root_level = root_item->level;
 	if (btrfs_test_opt(fs_info, SPACE_CACHE))
-		btrfs_set_super_cache_generation(super, root_item->generation);
+		super->cache_generation = root_item->generation;
 	if (test_bit(BTRFS_FS_UPDATE_UUID_TREE_GEN, &fs_info->flags))
-		btrfs_set_super_uuid_tree_generation(super,
-						     root_item->generation);
+		super->uuid_tree_generation = root_item->generation;
 }
 
 int btrfs_transaction_in_commit(struct btrfs_fs_info *info)
diff -druNp --no-dereference linux-libre-4.14.27-gnu/fs/namei.c linux-libre-4.14.28-gnu/fs/namei.c
--- linux-libre-4.14.27-gnu/fs/namei.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/fs/namei.c	2018-03-19 03:42:57.000000000 -0400
@@ -1133,9 +1133,6 @@ static int follow_automount(struct path
 	    path->dentry->d_inode)
 		return -EISDIR;
 
-	if (path->dentry->d_sb->s_user_ns != &init_user_ns)
-		return -EACCES;
-
 	nd->total_link_count++;
 	if (nd->total_link_count >= 40)
 		return -ELOOP;
diff -druNp --no-dereference linux-libre-4.14.27-gnu/include/linux/dma-fence-array.h linux-libre-4.14.28-gnu/include/linux/dma-fence-array.h
--- linux-libre-4.14.27-gnu/include/linux/dma-fence-array.h	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/include/linux/dma-fence-array.h	2018-03-19 03:42:57.000000000 -0400
@@ -21,6 +21,7 @@
 #define __LINUX_DMA_FENCE_ARRAY_H
 
 #include <linux/dma-fence.h>
+#include <linux/irq_work.h>
 
 /**
  * struct dma_fence_array_cb - callback helper for fence array
@@ -47,6 +48,8 @@ struct dma_fence_array {
 	unsigned num_fences;
 	atomic_t num_pending;
 	struct dma_fence **fences;
+
+	struct irq_work work;
 };
 
 extern const struct dma_fence_ops dma_fence_array_ops;
diff -druNp --no-dereference linux-libre-4.14.27-gnu/include/linux/phy.h linux-libre-4.14.28-gnu/include/linux/phy.h
--- linux-libre-4.14.27-gnu/include/linux/phy.h	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/include/linux/phy.h	2018-03-19 03:42:57.000000000 -0400
@@ -817,6 +817,7 @@ void phy_device_remove(struct phy_device
 int phy_init_hw(struct phy_device *phydev);
 int phy_suspend(struct phy_device *phydev);
 int phy_resume(struct phy_device *phydev);
+int __phy_resume(struct phy_device *phydev);
 int phy_loopback(struct phy_device *phydev, bool enable);
 struct phy_device *phy_attach(struct net_device *dev, const char *bus_id,
 			      phy_interface_t interface);
diff -druNp --no-dereference linux-libre-4.14.27-gnu/include/linux/usb/quirks.h linux-libre-4.14.28-gnu/include/linux/usb/quirks.h
--- linux-libre-4.14.27-gnu/include/linux/usb/quirks.h	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/include/linux/usb/quirks.h	2018-03-19 03:42:57.000000000 -0400
@@ -57,4 +57,7 @@
  */
 #define USB_QUIRK_LINEAR_FRAME_INTR_BINTERVAL	BIT(11)
 
+/* Device needs a pause after every control message. */
+#define USB_QUIRK_DELAY_CTRL_MSG		BIT(13)
+
 #endif /* __LINUX_USB_QUIRKS_H */
diff -druNp --no-dereference linux-libre-4.14.27-gnu/kernel/locking/locktorture.c linux-libre-4.14.28-gnu/kernel/locking/locktorture.c
--- linux-libre-4.14.27-gnu/kernel/locking/locktorture.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/kernel/locking/locktorture.c	2018-03-19 03:42:57.000000000 -0400
@@ -715,8 +715,7 @@ static void __torture_print_stats(char *
 {
 	bool fail = 0;
 	int i, n_stress;
-	long max = 0;
-	long min = statp[0].n_lock_acquired;
+	long max = 0, min = statp ? statp[0].n_lock_acquired : 0;
 	long long sum = 0;
 
 	n_stress = write ? cxt.nrealwriters_stress : cxt.nrealreaders_stress;
@@ -823,7 +822,7 @@ static void lock_torture_cleanup(void)
 	 * such, only perform the underlying torture-specific cleanups,
 	 * and avoid anything related to locktorture.
 	 */
-	if (!cxt.lwsa)
+	if (!cxt.lwsa && !cxt.lrsa)
 		goto end;
 
 	if (writer_tasks) {
@@ -898,6 +897,13 @@ static int __init lock_torture_init(void
 		firsterr = -EINVAL;
 		goto unwind;
 	}
+
+	if (nwriters_stress == 0 && nreaders_stress == 0) {
+		pr_alert("lock-torture: must run at least one locking thread\n");
+		firsterr = -EINVAL;
+		goto unwind;
+	}
+
 	if (cxt.cur_ops->init)
 		cxt.cur_ops->init();
 
@@ -921,17 +927,19 @@ static int __init lock_torture_init(void
 #endif
 
 	/* Initialize the statistics so that each run gets its own numbers. */
+	if (nwriters_stress) {
+		lock_is_write_held = 0;
+		cxt.lwsa = kmalloc(sizeof(*cxt.lwsa) * cxt.nrealwriters_stress, GFP_KERNEL);
+		if (cxt.lwsa == NULL) {
+			VERBOSE_TOROUT_STRING("cxt.lwsa: Out of memory");
+			firsterr = -ENOMEM;
+			goto unwind;
+		}
 
-	lock_is_write_held = 0;
-	cxt.lwsa = kmalloc(sizeof(*cxt.lwsa) * cxt.nrealwriters_stress, GFP_KERNEL);
-	if (cxt.lwsa == NULL) {
-		VERBOSE_TOROUT_STRING("cxt.lwsa: Out of memory");
-		firsterr = -ENOMEM;
-		goto unwind;
-	}
-	for (i = 0; i < cxt.nrealwriters_stress; i++) {
-		cxt.lwsa[i].n_lock_fail = 0;
-		cxt.lwsa[i].n_lock_acquired = 0;
+		for (i = 0; i < cxt.nrealwriters_stress; i++) {
+			cxt.lwsa[i].n_lock_fail = 0;
+			cxt.lwsa[i].n_lock_acquired = 0;
+		}
 	}
 
 	if (cxt.cur_ops->readlock) {
@@ -948,19 +956,21 @@ static int __init lock_torture_init(void
 			cxt.nrealreaders_stress = cxt.nrealwriters_stress;
 		}
 
-		lock_is_read_held = 0;
-		cxt.lrsa = kmalloc(sizeof(*cxt.lrsa) * cxt.nrealreaders_stress, GFP_KERNEL);
-		if (cxt.lrsa == NULL) {
-			VERBOSE_TOROUT_STRING("cxt.lrsa: Out of memory");
-			firsterr = -ENOMEM;
-			kfree(cxt.lwsa);
-			cxt.lwsa = NULL;
-			goto unwind;
-		}
+		if (nreaders_stress) {
+			lock_is_read_held = 0;
+			cxt.lrsa = kmalloc(sizeof(*cxt.lrsa) * cxt.nrealreaders_stress, GFP_KERNEL);
+			if (cxt.lrsa == NULL) {
+				VERBOSE_TOROUT_STRING("cxt.lrsa: Out of memory");
+				firsterr = -ENOMEM;
+				kfree(cxt.lwsa);
+				cxt.lwsa = NULL;
+				goto unwind;
+			}
 
-		for (i = 0; i < cxt.nrealreaders_stress; i++) {
-			cxt.lrsa[i].n_lock_fail = 0;
-			cxt.lrsa[i].n_lock_acquired = 0;
+			for (i = 0; i < cxt.nrealreaders_stress; i++) {
+				cxt.lrsa[i].n_lock_fail = 0;
+				cxt.lrsa[i].n_lock_acquired = 0;
+			}
 		}
 	}
 
@@ -990,12 +1000,14 @@ static int __init lock_torture_init(void
 			goto unwind;
 	}
 
-	writer_tasks = kzalloc(cxt.nrealwriters_stress * sizeof(writer_tasks[0]),
-			       GFP_KERNEL);
-	if (writer_tasks == NULL) {
-		VERBOSE_TOROUT_ERRSTRING("writer_tasks: Out of memory");
-		firsterr = -ENOMEM;
-		goto unwind;
+	if (nwriters_stress) {
+		writer_tasks = kzalloc(cxt.nrealwriters_stress * sizeof(writer_tasks[0]),
+				       GFP_KERNEL);
+		if (writer_tasks == NULL) {
+			VERBOSE_TOROUT_ERRSTRING("writer_tasks: Out of memory");
+			firsterr = -ENOMEM;
+			goto unwind;
+		}
 	}
 
 	if (cxt.cur_ops->readlock) {
diff -druNp --no-dereference linux-libre-4.14.27-gnu/kernel/sched/core.c linux-libre-4.14.28-gnu/kernel/sched/core.c
--- linux-libre-4.14.27-gnu/kernel/sched/core.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/kernel/sched/core.c	2018-03-19 03:42:57.000000000 -0400
@@ -506,7 +506,8 @@ void resched_cpu(int cpu)
 	unsigned long flags;
 
 	raw_spin_lock_irqsave(&rq->lock, flags);
-	resched_curr(rq);
+	if (cpu_online(cpu) || cpu == smp_processor_id())
+		resched_curr(rq);
 	raw_spin_unlock_irqrestore(&rq->lock, flags);
 }
 
diff -druNp --no-dereference linux-libre-4.14.27-gnu/kernel/sched/rt.c linux-libre-4.14.28-gnu/kernel/sched/rt.c
--- linux-libre-4.14.27-gnu/kernel/sched/rt.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/kernel/sched/rt.c	2018-03-19 03:42:57.000000000 -0400
@@ -2218,7 +2218,7 @@ static void switched_to_rt(struct rq *rq
 		if (p->nr_cpus_allowed > 1 && rq->rt.overloaded)
 			queue_push_tasks(rq);
 #endif /* CONFIG_SMP */
-		if (p->prio < rq->curr->prio)
+		if (p->prio < rq->curr->prio && cpu_online(cpu_of(rq)))
 			resched_curr(rq);
 	}
 }
diff -druNp --no-dereference linux-libre-4.14.27-gnu/lib/usercopy.c linux-libre-4.14.28-gnu/lib/usercopy.c
--- linux-libre-4.14.27-gnu/lib/usercopy.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/lib/usercopy.c	2018-03-19 03:42:57.000000000 -0400
@@ -20,7 +20,7 @@ EXPORT_SYMBOL(_copy_from_user);
 #endif
 
 #ifndef INLINE_COPY_TO_USER
-unsigned long _copy_to_user(void *to, const void __user *from, unsigned long n)
+unsigned long _copy_to_user(void __user *to, const void *from, unsigned long n)
 {
 	might_fault();
 	if (likely(access_ok(VERIFY_WRITE, to, n))) {
diff -druNp --no-dereference linux-libre-4.14.27-gnu/Makefile linux-libre-4.14.28-gnu/Makefile
--- linux-libre-4.14.27-gnu/Makefile	2018-03-15 08:11:08.000000000 -0400
+++ linux-libre-4.14.28-gnu/Makefile	2018-03-19 08:11:03.000000000 -0400
@@ -1,7 +1,7 @@
 # SPDX-License-Identifier: GPL-2.0
 VERSION = 4
 PATCHLEVEL = 14
-SUBLEVEL = 27
+SUBLEVEL = 28
 EXTRAVERSION = -gnu
 NAME = Petit Gorille
 
diff -druNp --no-dereference linux-libre-4.14.27-gnu/net/mac80211/iface.c linux-libre-4.14.28-gnu/net/mac80211/iface.c
--- linux-libre-4.14.27-gnu/net/mac80211/iface.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/net/mac80211/iface.c	2018-03-19 03:42:57.000000000 -0400
@@ -1493,7 +1493,7 @@ static void ieee80211_setup_sdata(struct
 		break;
 	case NL80211_IFTYPE_UNSPECIFIED:
 	case NUM_NL80211_IFTYPES:
-		BUG();
+		WARN_ON(1);
 		break;
 	}
 
diff -druNp --no-dereference linux-libre-4.14.27-gnu/net/sched/sch_generic.c linux-libre-4.14.28-gnu/net/sched/sch_generic.c
--- linux-libre-4.14.27-gnu/net/sched/sch_generic.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/net/sched/sch_generic.c	2018-03-19 03:42:57.000000000 -0400
@@ -743,10 +743,6 @@ struct Qdisc *dev_graft_qdisc(struct net
 	root_lock = qdisc_lock(oqdisc);
 	spin_lock_bh(root_lock);
 
-	/* Prune old scheduler */
-	if (oqdisc && refcount_read(&oqdisc->refcnt) <= 1)
-		qdisc_reset(oqdisc);
-
 	/* ... and graft new one */
 	if (qdisc == NULL)
 		qdisc = &noop_qdisc;
@@ -897,6 +893,16 @@ static bool some_qdisc_is_busy(struct ne
 	return false;
 }
 
+static void dev_qdisc_reset(struct net_device *dev,
+			    struct netdev_queue *dev_queue,
+			    void *none)
+{
+	struct Qdisc *qdisc = dev_queue->qdisc_sleeping;
+
+	if (qdisc)
+		qdisc_reset(qdisc);
+}
+
 /**
  * 	dev_deactivate_many - deactivate transmissions on several devices
  * 	@head: list of devices to deactivate
@@ -907,7 +913,6 @@ static bool some_qdisc_is_busy(struct ne
 void dev_deactivate_many(struct list_head *head)
 {
 	struct net_device *dev;
-	bool sync_needed = false;
 
 	list_for_each_entry(dev, head, close_list) {
 		netdev_for_each_tx_queue(dev, dev_deactivate_queue,
@@ -917,20 +922,25 @@ void dev_deactivate_many(struct list_hea
 					     &noop_qdisc);
 
 		dev_watchdog_down(dev);
-		sync_needed |= !dev->dismantle;
 	}
 
 	/* Wait for outstanding qdisc-less dev_queue_xmit calls.
 	 * This is avoided if all devices are in dismantle phase :
 	 * Caller will call synchronize_net() for us
 	 */
-	if (sync_needed)
-		synchronize_net();
+	synchronize_net();
 
 	/* Wait for outstanding qdisc_run calls. */
-	list_for_each_entry(dev, head, close_list)
+	list_for_each_entry(dev, head, close_list) {
 		while (some_qdisc_is_busy(dev))
 			yield();
+		/* The new qdisc is assigned at this point so we can safely
+		 * unwind stale skb lists and qdisc statistics
+		 */
+		netdev_for_each_tx_queue(dev, dev_qdisc_reset, NULL);
+		if (dev_ingress_queue(dev))
+			dev_qdisc_reset(dev, dev_ingress_queue(dev), NULL);
+	}
 }
 
 void dev_deactivate(struct net_device *dev)
diff -druNp --no-dereference linux-libre-4.14.27-gnu/net/xfrm/xfrm_policy.c linux-libre-4.14.28-gnu/net/xfrm/xfrm_policy.c
--- linux-libre-4.14.27-gnu/net/xfrm/xfrm_policy.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/net/xfrm/xfrm_policy.c	2018-03-19 03:42:57.000000000 -0400
@@ -1257,7 +1257,7 @@ EXPORT_SYMBOL(xfrm_policy_delete);
 
 int xfrm_sk_policy_insert(struct sock *sk, int dir, struct xfrm_policy *pol)
 {
-	struct net *net = xp_net(pol);
+	struct net *net = sock_net(sk);
 	struct xfrm_policy *old_pol;
 
 #ifdef CONFIG_XFRM_SUB_POLICY
diff -druNp --no-dereference linux-libre-4.14.27-gnu/net/xfrm/xfrm_replay.c linux-libre-4.14.28-gnu/net/xfrm/xfrm_replay.c
--- linux-libre-4.14.27-gnu/net/xfrm/xfrm_replay.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/net/xfrm/xfrm_replay.c	2018-03-19 03:42:57.000000000 -0400
@@ -666,7 +666,7 @@ static int xfrm_replay_overflow_offload_
 		if (unlikely(oseq < replay_esn->oseq)) {
 			XFRM_SKB_CB(skb)->seq.output.hi = ++oseq_hi;
 			xo->seq.hi = oseq_hi;
-
+			replay_esn->oseq_hi = oseq_hi;
 			if (replay_esn->oseq_hi == 0) {
 				replay_esn->oseq--;
 				replay_esn->oseq_hi--;
@@ -678,7 +678,6 @@ static int xfrm_replay_overflow_offload_
 		}
 
 		replay_esn->oseq = oseq;
-		replay_esn->oseq_hi = oseq_hi;
 
 		if (xfrm_aevent_is_on(net))
 			x->repl->notify(x, XFRM_REPLAY_UPDATE);
diff -druNp --no-dereference linux-libre-4.14.27-gnu/net/xfrm/xfrm_state.c linux-libre-4.14.28-gnu/net/xfrm/xfrm_state.c
--- linux-libre-4.14.27-gnu/net/xfrm/xfrm_state.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/net/xfrm/xfrm_state.c	2018-03-19 03:42:57.000000000 -0400
@@ -2050,6 +2050,13 @@ int xfrm_user_policy(struct sock *sk, in
 	struct xfrm_mgr *km;
 	struct xfrm_policy *pol = NULL;
 
+	if (!optval && !optlen) {
+		xfrm_sk_policy_insert(sk, XFRM_POLICY_IN, NULL);
+		xfrm_sk_policy_insert(sk, XFRM_POLICY_OUT, NULL);
+		__sk_dst_reset(sk);
+		return 0;
+	}
+
 	if (optlen <= 0 || optlen > PAGE_SIZE)
 		return -EMSGSIZE;
 
diff -druNp --no-dereference linux-libre-4.14.27-gnu/security/integrity/ima/ima_appraise.c linux-libre-4.14.28-gnu/security/integrity/ima/ima_appraise.c
--- linux-libre-4.14.27-gnu/security/integrity/ima/ima_appraise.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/security/integrity/ima/ima_appraise.c	2018-03-19 03:42:57.000000000 -0400
@@ -223,7 +223,8 @@ int ima_appraise_measurement(enum ima_ho
 		if (opened & FILE_CREATED)
 			iint->flags |= IMA_NEW_FILE;
 		if ((iint->flags & IMA_NEW_FILE) &&
-		    !(iint->flags & IMA_DIGSIG_REQUIRED))
+		    (!(iint->flags & IMA_DIGSIG_REQUIRED) ||
+		     (inode->i_size == 0)))
 			status = INTEGRITY_PASS;
 		goto out;
 	}
diff -druNp --no-dereference linux-libre-4.14.27-gnu/sound/soc/codecs/rt5651.c linux-libre-4.14.28-gnu/sound/soc/codecs/rt5651.c
--- linux-libre-4.14.27-gnu/sound/soc/codecs/rt5651.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/sound/soc/codecs/rt5651.c	2018-03-19 03:42:57.000000000 -0400
@@ -1694,6 +1694,7 @@ static const struct regmap_config rt5651
 	.num_reg_defaults = ARRAY_SIZE(rt5651_reg),
 	.ranges = rt5651_ranges,
 	.num_ranges = ARRAY_SIZE(rt5651_ranges),
+	.use_single_rw = true,
 };
 
 #if defined(CONFIG_OF)
diff -druNp --no-dereference linux-libre-4.14.27-gnu/sound/soc/codecs/sgtl5000.c linux-libre-4.14.28-gnu/sound/soc/codecs/sgtl5000.c
--- linux-libre-4.14.27-gnu/sound/soc/codecs/sgtl5000.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/sound/soc/codecs/sgtl5000.c	2018-03-19 03:42:57.000000000 -0400
@@ -871,15 +871,26 @@ static int sgtl5000_pcm_hw_params(struct
 static int sgtl5000_set_bias_level(struct snd_soc_codec *codec,
 				   enum snd_soc_bias_level level)
 {
+	struct sgtl5000_priv *sgtl = snd_soc_codec_get_drvdata(codec);
+	int ret;
+
 	switch (level) {
 	case SND_SOC_BIAS_ON:
 	case SND_SOC_BIAS_PREPARE:
 	case SND_SOC_BIAS_STANDBY:
+		regcache_cache_only(sgtl->regmap, false);
+		ret = regcache_sync(sgtl->regmap);
+		if (ret) {
+			regcache_cache_only(sgtl->regmap, true);
+			return ret;
+		}
+
 		snd_soc_update_bits(codec, SGTL5000_CHIP_ANA_POWER,
 				    SGTL5000_REFTOP_POWERUP,
 				    SGTL5000_REFTOP_POWERUP);
 		break;
 	case SND_SOC_BIAS_OFF:
+		regcache_cache_only(sgtl->regmap, true);
 		snd_soc_update_bits(codec, SGTL5000_CHIP_ANA_POWER,
 				    SGTL5000_REFTOP_POWERUP, 0);
 		break;
diff -druNp --no-dereference linux-libre-4.14.27-gnu/sound/soc/codecs/wm_adsp.c linux-libre-4.14.28-gnu/sound/soc/codecs/wm_adsp.c
--- linux-libre-4.14.27-gnu/sound/soc/codecs/wm_adsp.c	2018-03-15 08:39:15.000000000 -0400
+++ linux-libre-4.14.28-gnu/sound/soc/codecs/wm_adsp.c	2018-03-19 08:46:52.000000000 -0400
@@ -1204,12 +1204,14 @@ static int wmfw_add_ctl(struct wm_adsp *
 		kcontrol->put = wm_coeff_put_acked;
 		break;
 	default:
-		kcontrol->get = wm_coeff_get;
-		kcontrol->put = wm_coeff_put;
-
-		ctl->bytes_ext.max = ctl->len;
-		ctl->bytes_ext.get = wm_coeff_tlv_get;
-		ctl->bytes_ext.put = wm_coeff_tlv_put;
+		if (kcontrol->access & SNDRV_CTL_ELEM_ACCESS_TLV_CALLBACK) {
+			ctl->bytes_ext.max = ctl->len;
+			ctl->bytes_ext.get = wm_coeff_tlv_get;
+			ctl->bytes_ext.put = wm_coeff_tlv_put;
+		} else {
+			kcontrol->get = wm_coeff_get;
+			kcontrol->put = wm_coeff_put;
+		}
 		break;
 	}
 
diff -druNp --no-dereference linux-libre-4.14.27-gnu/sound/soc/nuc900/nuc900-ac97.c linux-libre-4.14.28-gnu/sound/soc/nuc900/nuc900-ac97.c
--- linux-libre-4.14.27-gnu/sound/soc/nuc900/nuc900-ac97.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/sound/soc/nuc900/nuc900-ac97.c	2018-03-19 03:42:57.000000000 -0400
@@ -67,7 +67,7 @@ static unsigned short nuc900_ac97_read(s
 
 	/* polling the AC_R_FINISH */
 	while (!(AUDIO_READ(nuc900_audio->mmio + ACTL_ACCON) & AC_R_FINISH)
-								&& timeout--)
+								&& --timeout)
 		mdelay(1);
 
 	if (!timeout) {
@@ -121,7 +121,7 @@ static void nuc900_ac97_write(struct snd
 
 	/* polling the AC_W_FINISH */
 	while ((AUDIO_READ(nuc900_audio->mmio + ACTL_ACCON) & AC_W_FINISH)
-								&& timeout--)
+								&& --timeout)
 		mdelay(1);
 
 	if (!timeout)
diff -druNp --no-dereference linux-libre-4.14.27-gnu/sound/soc/sunxi/sun4i-i2s.c linux-libre-4.14.28-gnu/sound/soc/sunxi/sun4i-i2s.c
--- linux-libre-4.14.27-gnu/sound/soc/sunxi/sun4i-i2s.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/sound/soc/sunxi/sun4i-i2s.c	2018-03-19 03:42:57.000000000 -0400
@@ -104,7 +104,7 @@
 
 #define SUN8I_I2S_CHAN_CFG_REG		0x30
 #define SUN8I_I2S_CHAN_CFG_RX_SLOT_NUM_MASK	GENMASK(6, 4)
-#define SUN8I_I2S_CHAN_CFG_RX_SLOT_NUM(chan)	(chan - 1)
+#define SUN8I_I2S_CHAN_CFG_RX_SLOT_NUM(chan)	((chan - 1) << 4)
 #define SUN8I_I2S_CHAN_CFG_TX_SLOT_NUM_MASK	GENMASK(2, 0)
 #define SUN8I_I2S_CHAN_CFG_TX_SLOT_NUM(chan)	(chan - 1)
 
diff -druNp --no-dereference linux-libre-4.14.27-gnu/tools/perf/arch/s390/annotate/instructions.c linux-libre-4.14.28-gnu/tools/perf/arch/s390/annotate/instructions.c
--- linux-libre-4.14.27-gnu/tools/perf/arch/s390/annotate/instructions.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/tools/perf/arch/s390/annotate/instructions.c	2018-03-19 03:42:57.000000000 -0400
@@ -16,7 +16,8 @@ static struct ins_ops *s390__associate_i
 	if (!strcmp(name, "br"))
 		ops = &ret_ops;
 
-	arch__associate_ins_ops(arch, name, ops);
+	if (ops)
+		arch__associate_ins_ops(arch, name, ops);
 	return ops;
 }
 
diff -druNp --no-dereference linux-libre-4.14.27-gnu/tools/perf/util/annotate.c linux-libre-4.14.28-gnu/tools/perf/util/annotate.c
--- linux-libre-4.14.27-gnu/tools/perf/util/annotate.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/tools/perf/util/annotate.c	2018-03-19 03:42:57.000000000 -0400
@@ -323,6 +323,8 @@ static int comment__symbol(char *raw, ch
 		return 0;
 
 	*addrp = strtoull(comment, &endptr, 16);
+	if (endptr == comment)
+		return 0;
 	name = strchr(endptr, '<');
 	if (name == NULL)
 		return -1;
@@ -436,8 +438,8 @@ static int mov__parse(struct arch *arch,
 		return 0;
 
 	comment = ltrim(comment);
-	comment__symbol(ops->source.raw, comment, &ops->source.addr, &ops->source.name);
-	comment__symbol(ops->target.raw, comment, &ops->target.addr, &ops->target.name);
+	comment__symbol(ops->source.raw, comment + 1, &ops->source.addr, &ops->source.name);
+	comment__symbol(ops->target.raw, comment + 1, &ops->target.addr, &ops->target.name);
 
 	return 0;
 
@@ -481,7 +483,7 @@ static int dec__parse(struct arch *arch
 		return 0;
 
 	comment = ltrim(comment);
-	comment__symbol(ops->target.raw, comment, &ops->target.addr, &ops->target.name);
+	comment__symbol(ops->target.raw, comment + 1, &ops->target.addr, &ops->target.name);
 
 	return 0;
 }
diff -druNp --no-dereference linux-libre-4.14.27-gnu/tools/testing/selftests/firmware/fw_filesystem.sh linux-libre-4.14.28-gnu/tools/testing/selftests/firmware/fw_filesystem.sh
--- linux-libre-4.14.27-gnu/tools/testing/selftests/firmware/fw_filesystem.sh	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/tools/testing/selftests/firmware/fw_filesystem.sh	2018-03-19 03:42:57.000000000 -0400
@@ -45,7 +45,10 @@ test_finish()
 	if [ "$HAS_FW_LOADER_USER_HELPER" = "yes" ]; then
 		echo "$OLD_TIMEOUT" >/sys/class/firmware/timeout
 	fi
-	echo -n "$OLD_PATH" >/sys/module/firmware_class/parameters/path
+	if [ "$OLD_FWPATH" = "" ]; then
+		OLD_FWPATH=" "
+	fi
+	echo -n "$OLD_FWPATH" >/sys/module/firmware_class/parameters/path
 	rm -f "$FW"
 	rmdir "$FWPATH"
 }
diff -druNp --no-dereference linux-libre-4.14.27-gnu/tools/testing/selftests/rcutorture/bin/configinit.sh linux-libre-4.14.28-gnu/tools/testing/selftests/rcutorture/bin/configinit.sh
--- linux-libre-4.14.27-gnu/tools/testing/selftests/rcutorture/bin/configinit.sh	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/tools/testing/selftests/rcutorture/bin/configinit.sh	2018-03-19 03:42:57.000000000 -0400
@@ -51,7 +51,7 @@ then
 			mkdir $builddir
 		fi
 	else
-		echo Bad build directory: \"$builddir\"
+		echo Bad build directory: \"$buildloc\"
 		exit 2
 	fi
 fi
diff -druNp --no-dereference linux-libre-4.14.27-gnu/tools/usb/usbip/src/usbipd.c linux-libre-4.14.28-gnu/tools/usb/usbip/src/usbipd.c
--- linux-libre-4.14.27-gnu/tools/usb/usbip/src/usbipd.c	2018-03-15 05:54:38.000000000 -0400
+++ linux-libre-4.14.28-gnu/tools/usb/usbip/src/usbipd.c	2018-03-19 03:42:57.000000000 -0400
@@ -456,7 +456,7 @@ static void set_signal(void)
 	sigaction(SIGTERM, &act, NULL);
 	sigaction(SIGINT, &act, NULL);
 	act.sa_handler = SIG_IGN;
-	sigaction(SIGCLD, &act, NULL);
+	sigaction(SIGCHLD, &act, NULL);
 }
 
 static const char *pid_file;
