diff -druNp --no-dereference linux-libre-4.9.114-gnu/arch/arc/configs/axs101_defconfig linux-libre-4.9.115-gnu/arch/arc/configs/axs101_defconfig
--- linux-libre-4.9.114-gnu/arch/arc/configs/axs101_defconfig	2018-07-22 08:27:43.000000000 -0400
+++ linux-libre-4.9.115-gnu/arch/arc/configs/axs101_defconfig	2018-07-25 05:24:03.000000000 -0400
@@ -11,7 +11,6 @@ CONFIG_NAMESPACES=y
 # CONFIG_UTS_NS is not set
 # CONFIG_PID_NS is not set
 CONFIG_BLK_DEV_INITRD=y
-CONFIG_INITRAMFS_SOURCE="../arc_initramfs/"
 CONFIG_EMBEDDED=y
 CONFIG_PERF_EVENTS=y
 # CONFIG_VM_EVENT_COUNTERS is not set
diff -druNp --no-dereference linux-libre-4.9.114-gnu/arch/arc/configs/axs103_defconfig linux-libre-4.9.115-gnu/arch/arc/configs/axs103_defconfig
--- linux-libre-4.9.114-gnu/arch/arc/configs/axs103_defconfig	2018-07-22 08:27:43.000000000 -0400
+++ linux-libre-4.9.115-gnu/arch/arc/configs/axs103_defconfig	2018-07-25 05:24:03.000000000 -0400
@@ -11,7 +11,6 @@ CONFIG_NAMESPACES=y
 # CONFIG_UTS_NS is not set
 # CONFIG_PID_NS is not set
 CONFIG_BLK_DEV_INITRD=y
-CONFIG_INITRAMFS_SOURCE="../../arc_initramfs_hs/"
 CONFIG_EMBEDDED=y
 CONFIG_PERF_EVENTS=y
 # CONFIG_VM_EVENT_COUNTERS is not set
diff -druNp --no-dereference linux-libre-4.9.114-gnu/arch/arc/configs/axs103_smp_defconfig linux-libre-4.9.115-gnu/arch/arc/configs/axs103_smp_defconfig
--- linux-libre-4.9.114-gnu/arch/arc/configs/axs103_smp_defconfig	2018-07-22 08:27:43.000000000 -0400
+++ linux-libre-4.9.115-gnu/arch/arc/configs/axs103_smp_defconfig	2018-07-25 05:24:03.000000000 -0400
@@ -11,7 +11,6 @@ CONFIG_NAMESPACES=y
 # CONFIG_UTS_NS is not set
 # CONFIG_PID_NS is not set
 CONFIG_BLK_DEV_INITRD=y
-CONFIG_INITRAMFS_SOURCE="../../arc_initramfs_hs/"
 CONFIG_EMBEDDED=y
 CONFIG_PERF_EVENTS=y
 # CONFIG_VM_EVENT_COUNTERS is not set
diff -druNp --no-dereference linux-libre-4.9.114-gnu/arch/arc/configs/nsim_700_defconfig linux-libre-4.9.115-gnu/arch/arc/configs/nsim_700_defconfig
--- linux-libre-4.9.114-gnu/arch/arc/configs/nsim_700_defconfig	2018-07-22 08:27:43.000000000 -0400
+++ linux-libre-4.9.115-gnu/arch/arc/configs/nsim_700_defconfig	2018-07-25 05:24:03.000000000 -0400
@@ -11,7 +11,6 @@ CONFIG_NAMESPACES=y
 # CONFIG_UTS_NS is not set
 # CONFIG_PID_NS is not set
 CONFIG_BLK_DEV_INITRD=y
-CONFIG_INITRAMFS_SOURCE="../arc_initramfs/"
 CONFIG_KALLSYMS_ALL=y
 CONFIG_EMBEDDED=y
 CONFIG_PERF_EVENTS=y
diff -druNp --no-dereference linux-libre-4.9.114-gnu/arch/arc/configs/nsim_hs_defconfig linux-libre-4.9.115-gnu/arch/arc/configs/nsim_hs_defconfig
--- linux-libre-4.9.114-gnu/arch/arc/configs/nsim_hs_defconfig	2018-07-22 08:27:43.000000000 -0400
+++ linux-libre-4.9.115-gnu/arch/arc/configs/nsim_hs_defconfig	2018-07-25 05:24:03.000000000 -0400
@@ -11,7 +11,6 @@ CONFIG_NAMESPACES=y
 # CONFIG_UTS_NS is not set
 # CONFIG_PID_NS is not set
 CONFIG_BLK_DEV_INITRD=y
-CONFIG_INITRAMFS_SOURCE="../../arc_initramfs_hs/"
 CONFIG_KALLSYMS_ALL=y
 CONFIG_EMBEDDED=y
 CONFIG_PERF_EVENTS=y
diff -druNp --no-dereference linux-libre-4.9.114-gnu/arch/arc/configs/nsim_hs_smp_defconfig linux-libre-4.9.115-gnu/arch/arc/configs/nsim_hs_smp_defconfig
--- linux-libre-4.9.114-gnu/arch/arc/configs/nsim_hs_smp_defconfig	2018-07-22 08:27:43.000000000 -0400
+++ linux-libre-4.9.115-gnu/arch/arc/configs/nsim_hs_smp_defconfig	2018-07-25 05:24:03.000000000 -0400
@@ -9,7 +9,6 @@ CONFIG_NAMESPACES=y
 # CONFIG_UTS_NS is not set
 # CONFIG_PID_NS is not set
 CONFIG_BLK_DEV_INITRD=y
-CONFIG_INITRAMFS_SOURCE="../arc_initramfs_hs/"
 CONFIG_KALLSYMS_ALL=y
 CONFIG_EMBEDDED=y
 CONFIG_PERF_EVENTS=y
diff -druNp --no-dereference linux-libre-4.9.114-gnu/arch/arc/configs/nsimosci_defconfig linux-libre-4.9.115-gnu/arch/arc/configs/nsimosci_defconfig
--- linux-libre-4.9.114-gnu/arch/arc/configs/nsimosci_defconfig	2018-07-22 08:27:43.000000000 -0400
+++ linux-libre-4.9.115-gnu/arch/arc/configs/nsimosci_defconfig	2018-07-25 05:24:03.000000000 -0400
@@ -11,7 +11,6 @@ CONFIG_NAMESPACES=y
 # CONFIG_UTS_NS is not set
 # CONFIG_PID_NS is not set
 CONFIG_BLK_DEV_INITRD=y
-CONFIG_INITRAMFS_SOURCE="../arc_initramfs/"
 CONFIG_KALLSYMS_ALL=y
 CONFIG_EMBEDDED=y
 CONFIG_PERF_EVENTS=y
diff -druNp --no-dereference linux-libre-4.9.114-gnu/arch/arc/configs/nsimosci_hs_defconfig linux-libre-4.9.115-gnu/arch/arc/configs/nsimosci_hs_defconfig
--- linux-libre-4.9.114-gnu/arch/arc/configs/nsimosci_hs_defconfig	2018-07-22 08:27:43.000000000 -0400
+++ linux-libre-4.9.115-gnu/arch/arc/configs/nsimosci_hs_defconfig	2018-07-25 05:24:03.000000000 -0400
@@ -11,7 +11,6 @@ CONFIG_NAMESPACES=y
 # CONFIG_UTS_NS is not set
 # CONFIG_PID_NS is not set
 CONFIG_BLK_DEV_INITRD=y
-CONFIG_INITRAMFS_SOURCE="../arc_initramfs_hs/"
 CONFIG_KALLSYMS_ALL=y
 CONFIG_EMBEDDED=y
 CONFIG_PERF_EVENTS=y
diff -druNp --no-dereference linux-libre-4.9.114-gnu/arch/arc/configs/nsimosci_hs_smp_defconfig linux-libre-4.9.115-gnu/arch/arc/configs/nsimosci_hs_smp_defconfig
--- linux-libre-4.9.114-gnu/arch/arc/configs/nsimosci_hs_smp_defconfig	2018-07-22 08:27:43.000000000 -0400
+++ linux-libre-4.9.115-gnu/arch/arc/configs/nsimosci_hs_smp_defconfig	2018-07-25 05:24:03.000000000 -0400
@@ -9,7 +9,6 @@ CONFIG_IKCONFIG_PROC=y
 # CONFIG_UTS_NS is not set
 # CONFIG_PID_NS is not set
 CONFIG_BLK_DEV_INITRD=y
-CONFIG_INITRAMFS_SOURCE="../arc_initramfs_hs/"
 CONFIG_PERF_EVENTS=y
 # CONFIG_COMPAT_BRK is not set
 CONFIG_KPROBES=y
diff -druNp --no-dereference linux-libre-4.9.114-gnu/arch/arc/include/asm/page.h linux-libre-4.9.115-gnu/arch/arc/include/asm/page.h
--- linux-libre-4.9.114-gnu/arch/arc/include/asm/page.h	2018-07-22 08:27:43.000000000 -0400
+++ linux-libre-4.9.115-gnu/arch/arc/include/asm/page.h	2018-07-25 05:24:03.000000000 -0400
@@ -105,7 +105,7 @@ typedef pte_t * pgtable_t;
 #define virt_addr_valid(kaddr)  pfn_valid(virt_to_pfn(kaddr))
 
 /* Default Permissions for stack/heaps pages (Non Executable) */
-#define VM_DATA_DEFAULT_FLAGS   (VM_READ | VM_WRITE | VM_MAYREAD | VM_MAYWRITE)
+#define VM_DATA_DEFAULT_FLAGS   (VM_READ | VM_WRITE | VM_MAYREAD | VM_MAYWRITE | VM_MAYEXEC)
 
 #define WANT_PAGE_VIRTUAL   1
 
diff -druNp --no-dereference linux-libre-4.9.114-gnu/arch/arc/include/asm/pgtable.h linux-libre-4.9.115-gnu/arch/arc/include/asm/pgtable.h
--- linux-libre-4.9.114-gnu/arch/arc/include/asm/pgtable.h	2018-07-22 08:27:43.000000000 -0400
+++ linux-libre-4.9.115-gnu/arch/arc/include/asm/pgtable.h	2018-07-25 05:24:03.000000000 -0400
@@ -378,7 +378,7 @@ void update_mmu_cache(struct vm_area_str
 
 /* Decode a PTE containing swap "identifier "into constituents */
 #define __swp_type(pte_lookalike)	(((pte_lookalike).val) & 0x1f)
-#define __swp_offset(pte_lookalike)	((pte_lookalike).val << 13)
+#define __swp_offset(pte_lookalike)	((pte_lookalike).val >> 13)
 
 /* NOPs, to keep generic kernel happy */
 #define __pte_to_swp_entry(pte)	((swp_entry_t) { pte_val(pte) })
diff -druNp --no-dereference linux-libre-4.9.114-gnu/arch/x86/include/asm/apm.h linux-libre-4.9.115-gnu/arch/x86/include/asm/apm.h
--- linux-libre-4.9.114-gnu/arch/x86/include/asm/apm.h	2018-07-22 08:27:43.000000000 -0400
+++ linux-libre-4.9.115-gnu/arch/x86/include/asm/apm.h	2018-07-25 05:24:03.000000000 -0400
@@ -6,8 +6,6 @@
 #ifndef _ASM_X86_MACH_DEFAULT_APM_H
 #define _ASM_X86_MACH_DEFAULT_APM_H
 
-#include <asm/nospec-branch.h>
-
 #ifdef APM_ZERO_SEGS
 #	define APM_DO_ZERO_SEGS \
 		"pushl %%ds\n\t" \
@@ -33,7 +31,6 @@ static inline void apm_bios_call_asm(u32
 	 * N.B. We do NOT need a cld after the BIOS call
 	 * because we always save and restore the flags.
 	 */
-	firmware_restrict_branch_speculation_start();
 	__asm__ __volatile__(APM_DO_ZERO_SEGS
 		"pushl %%edi\n\t"
 		"pushl %%ebp\n\t"
@@ -46,7 +43,6 @@ static inline void apm_bios_call_asm(u32
 		  "=S" (*esi)
 		: "a" (func), "b" (ebx_in), "c" (ecx_in)
 		: "memory", "cc");
-	firmware_restrict_branch_speculation_end();
 }
 
 static inline bool apm_bios_call_simple_asm(u32 func, u32 ebx_in,
@@ -59,7 +55,6 @@ static inline bool apm_bios_call_simple_
 	 * N.B. We do NOT need a cld after the BIOS call
 	 * because we always save and restore the flags.
 	 */
-	firmware_restrict_branch_speculation_start();
 	__asm__ __volatile__(APM_DO_ZERO_SEGS
 		"pushl %%edi\n\t"
 		"pushl %%ebp\n\t"
@@ -72,7 +67,6 @@ static inline bool apm_bios_call_simple_
 		  "=S" (si)
 		: "a" (func), "b" (ebx_in), "c" (ecx_in)
 		: "memory", "cc");
-	firmware_restrict_branch_speculation_end();
 	return error;
 }
 
diff -druNp --no-dereference linux-libre-4.9.114-gnu/arch/x86/kernel/apm_32.c linux-libre-4.9.115-gnu/arch/x86/kernel/apm_32.c
--- linux-libre-4.9.114-gnu/arch/x86/kernel/apm_32.c	2018-07-22 08:27:43.000000000 -0400
+++ linux-libre-4.9.115-gnu/arch/x86/kernel/apm_32.c	2018-07-25 05:24:03.000000000 -0400
@@ -239,6 +239,7 @@
 #include <asm/olpc.h>
 #include <asm/paravirt.h>
 #include <asm/reboot.h>
+#include <asm/nospec-branch.h>
 
 #if defined(CONFIG_APM_DISPLAY_BLANK) && defined(CONFIG_VT)
 extern int (*console_blank_hook)(int);
@@ -613,11 +614,13 @@ static long __apm_bios_call(void *_call)
 	gdt[0x40 / 8] = bad_bios_desc;
 
 	apm_irq_save(flags);
+	firmware_restrict_branch_speculation_start();
 	APM_DO_SAVE_SEGS;
 	apm_bios_call_asm(call->func, call->ebx, call->ecx,
 			  &call->eax, &call->ebx, &call->ecx, &call->edx,
 			  &call->esi);
 	APM_DO_RESTORE_SEGS;
+	firmware_restrict_branch_speculation_end();
 	apm_irq_restore(flags);
 	gdt[0x40 / 8] = save_desc_40;
 	put_cpu();
@@ -689,10 +692,12 @@ static long __apm_bios_call_simple(void
 	gdt[0x40 / 8] = bad_bios_desc;
 
 	apm_irq_save(flags);
+	firmware_restrict_branch_speculation_start();
 	APM_DO_SAVE_SEGS;
 	error = apm_bios_call_simple_asm(call->func, call->ebx, call->ecx,
 					 &call->eax);
 	APM_DO_RESTORE_SEGS;
+	firmware_restrict_branch_speculation_end();
 	apm_irq_restore(flags);
 	gdt[0x40 / 8] = save_desc_40;
 	put_cpu();
diff -druNp --no-dereference linux-libre-4.9.114-gnu/arch/x86/kernel/cpu/mcheck/mce.c linux-libre-4.9.115-gnu/arch/x86/kernel/cpu/mcheck/mce.c
--- linux-libre-4.9.114-gnu/arch/x86/kernel/cpu/mcheck/mce.c	2018-07-22 08:27:43.000000000 -0400
+++ linux-libre-4.9.115-gnu/arch/x86/kernel/cpu/mcheck/mce.c	2018-07-25 05:24:03.000000000 -0400
@@ -2397,9 +2397,6 @@ static ssize_t store_int_with_restart(st
 	if (check_interval == old_check_interval)
 		return ret;
 
-	if (check_interval < 1)
-		check_interval = 1;
-
 	mutex_lock(&mce_sysfs_mutex);
 	mce_restart();
 	mutex_unlock(&mce_sysfs_mutex);
diff -druNp --no-dereference linux-libre-4.9.114-gnu/block/blk-core.c linux-libre-4.9.115-gnu/block/blk-core.c
--- linux-libre-4.9.114-gnu/block/blk-core.c	2018-07-22 08:27:43.000000000 -0400
+++ linux-libre-4.9.115-gnu/block/blk-core.c	2018-07-25 05:24:03.000000000 -0400
@@ -652,7 +652,6 @@ EXPORT_SYMBOL(blk_alloc_queue);
 int blk_queue_enter(struct request_queue *q, bool nowait)
 {
 	while (true) {
-		int ret;
 
 		if (percpu_ref_tryget_live(&q->q_usage_counter))
 			return 0;
@@ -660,13 +659,11 @@ int blk_queue_enter(struct request_queue
 		if (nowait)
 			return -EBUSY;
 
-		ret = wait_event_interruptible(q->mq_freeze_wq,
-				!atomic_read(&q->mq_freeze_depth) ||
-				blk_queue_dying(q));
+		wait_event(q->mq_freeze_wq,
+			   !atomic_read(&q->mq_freeze_depth) ||
+			   blk_queue_dying(q));
 		if (blk_queue_dying(q))
 			return -ENODEV;
-		if (ret)
-			return ret;
 	}
 }
 
diff -druNp --no-dereference linux-libre-4.9.114-gnu/drivers/gpu/drm/i915/i915_irq.c linux-libre-4.9.115-gnu/drivers/gpu/drm/i915/i915_irq.c
--- linux-libre-4.9.114-gnu/drivers/gpu/drm/i915/i915_irq.c	2018-07-22 08:27:43.000000000 -0400
+++ linux-libre-4.9.115-gnu/drivers/gpu/drm/i915/i915_irq.c	2018-07-25 05:24:03.000000000 -0400
@@ -1684,10 +1684,38 @@ static void valleyview_pipestat_irq_hand
 
 static u32 i9xx_hpd_irq_ack(struct drm_i915_private *dev_priv)
 {
-	u32 hotplug_status = I915_READ(PORT_HOTPLUG_STAT);
+	u32 hotplug_status = 0, hotplug_status_mask;
+	int i;
 
-	if (hotplug_status)
+	if (IS_G4X(dev_priv) ||
+	    IS_VALLEYVIEW(dev_priv) || IS_CHERRYVIEW(dev_priv))
+		hotplug_status_mask = HOTPLUG_INT_STATUS_G4X |
+			DP_AUX_CHANNEL_MASK_INT_STATUS_G4X;
+	else
+		hotplug_status_mask = HOTPLUG_INT_STATUS_I915;
+
+	/*
+	 * We absolutely have to clear all the pending interrupt
+	 * bits in PORT_HOTPLUG_STAT. Otherwise the ISR port
+	 * interrupt bit won't have an edge, and the i965/g4x
+	 * edge triggered IIR will not notice that an interrupt
+	 * is still pending. We can't use PORT_HOTPLUG_EN to
+	 * guarantee the edge as the act of toggling the enable
+	 * bits can itself generate a new hotplug interrupt :(
+	 */
+	for (i = 0; i < 10; i++) {
+		u32 tmp = I915_READ(PORT_HOTPLUG_STAT) & hotplug_status_mask;
+
+		if (tmp == 0)
+			return hotplug_status;
+
+		hotplug_status |= tmp;
 		I915_WRITE(PORT_HOTPLUG_STAT, hotplug_status);
+	}
+
+	WARN_ONCE(1,
+		  "PORT_HOTPLUG_STAT did not clear (0x%08x)\n",
+		  I915_READ(PORT_HOTPLUG_STAT));
 
 	return hotplug_status;
 }
diff -druNp --no-dereference linux-libre-4.9.114-gnu/drivers/net/ethernet/broadcom/tg3.c linux-libre-4.9.115-gnu/drivers/net/ethernet/broadcom/tg3.c
--- linux-libre-4.9.114-gnu/drivers/net/ethernet/broadcom/tg3.c	2018-07-22 11:37:15.000000000 -0400
+++ linux-libre-4.9.115-gnu/drivers/net/ethernet/broadcom/tg3.c	2018-07-25 10:13:20.000000000 -0400
@@ -9267,6 +9267,15 @@ static int tg3_chip_reset(struct tg3 *tp
 
 	tg3_restore_clk(tp);
 
+	/* Increase the core clock speed to fix tx timeout issue for 5762
+	 * with 100Mbps link speed.
+	 */
+	if (tg3_asic_rev(tp) == ASIC_REV_5762) {
+		val = tr32(TG3_CPMU_CLCK_ORIDE_ENABLE);
+		tw32(TG3_CPMU_CLCK_ORIDE_ENABLE, val |
+		     TG3_CPMU_MAC_ORIDE_ENABLE);
+	}
+
 	/* Reprobe ASF enable state.  */
 	tg3_flag_clear(tp, ENABLE_ASF);
 	tp->phy_flags &= ~(TG3_PHYFLG_1G_ON_VAUX_OK |
diff -druNp --no-dereference linux-libre-4.9.114-gnu/drivers/net/phy/phy_device.c linux-libre-4.9.115-gnu/drivers/net/phy/phy_device.c
--- linux-libre-4.9.114-gnu/drivers/net/phy/phy_device.c	2018-07-22 08:27:43.000000000 -0400
+++ linux-libre-4.9.115-gnu/drivers/net/phy/phy_device.c	2018-07-25 05:24:03.000000000 -0400
@@ -1579,11 +1579,8 @@ static int gen10g_resume(struct phy_devi
 
 static int __set_phy_supported(struct phy_device *phydev, u32 max_speed)
 {
-	/* The default values for phydev->supported are provided by the PHY
-	 * driver "features" member, we want to reset to sane defaults first
-	 * before supporting higher speeds.
-	 */
-	phydev->supported &= PHY_DEFAULT_FEATURES;
+	phydev->supported &= ~(PHY_1000BT_FEATURES | PHY_100BT_FEATURES |
+			       PHY_10BT_FEATURES);
 
 	switch (max_speed) {
 	default:
diff -druNp --no-dereference linux-libre-4.9.114-gnu/drivers/net/usb/asix_devices.c linux-libre-4.9.115-gnu/drivers/net/usb/asix_devices.c
--- linux-libre-4.9.114-gnu/drivers/net/usb/asix_devices.c	2018-07-22 08:27:43.000000000 -0400
+++ linux-libre-4.9.115-gnu/drivers/net/usb/asix_devices.c	2018-07-25 05:24:03.000000000 -0400
@@ -640,10 +640,12 @@ static void ax88772_restore_phy(struct u
 				     priv->presvd_phy_advertise);
 
 		/* Restore BMCR */
+		if (priv->presvd_phy_bmcr & BMCR_ANENABLE)
+			priv->presvd_phy_bmcr |= BMCR_ANRESTART;
+
 		asix_mdio_write_nopm(dev->net, dev->mii.phy_id, MII_BMCR,
 				     priv->presvd_phy_bmcr);
 
-		mii_nway_restart(&dev->mii);
 		priv->presvd_phy_advertise = 0;
 		priv->presvd_phy_bmcr = 0;
 	}
diff -druNp --no-dereference linux-libre-4.9.114-gnu/drivers/net/usb/qmi_wwan.c linux-libre-4.9.115-gnu/drivers/net/usb/qmi_wwan.c
--- linux-libre-4.9.114-gnu/drivers/net/usb/qmi_wwan.c	2018-07-22 08:27:43.000000000 -0400
+++ linux-libre-4.9.115-gnu/drivers/net/usb/qmi_wwan.c	2018-07-25 05:24:03.000000000 -0400
@@ -953,6 +953,7 @@ static const struct usb_device_id produc
 	{QMI_FIXED_INTF(0x1e0e, 0x9001, 5)},	/* SIMCom 7230E */
 	{QMI_QUIRK_SET_DTR(0x2c7c, 0x0125, 4)},	/* Quectel EC25, EC20 R2.0  Mini PCIe */
 	{QMI_QUIRK_SET_DTR(0x2c7c, 0x0121, 4)},	/* Quectel EC21 Mini PCIe */
+	{QMI_QUIRK_SET_DTR(0x2c7c, 0x0191, 4)},	/* Quectel EG91 */
 	{QMI_FIXED_INTF(0x2c7c, 0x0296, 4)},	/* Quectel BG96 */
 	{QMI_QUIRK_SET_DTR(0x2c7c, 0x0306, 4)},	/* Quectel EP06 Mini PCIe */
 
diff -druNp --no-dereference linux-libre-4.9.114-gnu/drivers/ptp/ptp_chardev.c linux-libre-4.9.115-gnu/drivers/ptp/ptp_chardev.c
--- linux-libre-4.9.114-gnu/drivers/ptp/ptp_chardev.c	2018-07-22 08:27:43.000000000 -0400
+++ linux-libre-4.9.115-gnu/drivers/ptp/ptp_chardev.c	2018-07-25 05:24:03.000000000 -0400
@@ -89,6 +89,7 @@ int ptp_set_pinfunc(struct ptp_clock *pt
 	case PTP_PF_PHYSYNC:
 		if (chan != 0)
 			return -EINVAL;
+		break;
 	default:
 		return -EINVAL;
 	}
diff -druNp --no-dereference linux-libre-4.9.114-gnu/drivers/usb/host/xhci.c linux-libre-4.9.115-gnu/drivers/usb/host/xhci.c
--- linux-libre-4.9.114-gnu/drivers/usb/host/xhci.c	2018-07-22 08:27:43.000000000 -0400
+++ linux-libre-4.9.115-gnu/drivers/usb/host/xhci.c	2018-07-25 05:24:03.000000000 -0400
@@ -891,6 +891,41 @@ static void xhci_disable_port_wake_on_bi
 	spin_unlock_irqrestore(&xhci->lock, flags);
 }
 
+static bool xhci_pending_portevent(struct xhci_hcd *xhci)
+{
+	__le32 __iomem		**port_array;
+	int			port_index;
+	u32			status;
+	u32			portsc;
+
+	status = readl(&xhci->op_regs->status);
+	if (status & STS_EINT)
+		return true;
+	/*
+	 * Checking STS_EINT is not enough as there is a lag between a change
+	 * bit being set and the Port Status Change Event that it generated
+	 * being written to the Event Ring. See note in xhci 1.1 section 4.19.2.
+	 */
+
+	port_index = xhci->num_usb2_ports;
+	port_array = xhci->usb2_ports;
+	while (port_index--) {
+		portsc = readl(port_array[port_index]);
+		if (portsc & PORT_CHANGE_MASK ||
+		    (portsc & PORT_PLS_MASK) == XDEV_RESUME)
+			return true;
+	}
+	port_index = xhci->num_usb3_ports;
+	port_array = xhci->usb3_ports;
+	while (port_index--) {
+		portsc = readl(port_array[port_index]);
+		if (portsc & PORT_CHANGE_MASK ||
+		    (portsc & PORT_PLS_MASK) == XDEV_RESUME)
+			return true;
+	}
+	return false;
+}
+
 /*
  * Stop HC (not bus-specific)
  *
@@ -987,7 +1022,7 @@ EXPORT_SYMBOL_GPL(xhci_suspend);
  */
 int xhci_resume(struct xhci_hcd *xhci, bool hibernated)
 {
-	u32			command, temp = 0, status;
+	u32			command, temp = 0;
 	struct usb_hcd		*hcd = xhci_to_hcd(xhci);
 	struct usb_hcd		*secondary_hcd;
 	int			retval = 0;
@@ -1109,8 +1144,7 @@ int xhci_resume(struct xhci_hcd *xhci, b
  done:
 	if (retval == 0) {
 		/* Resume root hubs only when have pending events. */
-		status = readl(&xhci->op_regs->status);
-		if (status & STS_EINT) {
+		if (xhci_pending_portevent(xhci)) {
 			usb_hcd_resume_root_hub(xhci->shared_hcd);
 			usb_hcd_resume_root_hub(hcd);
 		}
diff -druNp --no-dereference linux-libre-4.9.114-gnu/drivers/usb/host/xhci.h linux-libre-4.9.115-gnu/drivers/usb/host/xhci.h
--- linux-libre-4.9.114-gnu/drivers/usb/host/xhci.h	2018-07-22 08:27:43.000000000 -0400
+++ linux-libre-4.9.115-gnu/drivers/usb/host/xhci.h	2018-07-25 05:24:03.000000000 -0400
@@ -385,6 +385,10 @@ struct xhci_op_regs {
 #define PORT_PLC	(1 << 22)
 /* port configure error change - port failed to configure its link partner */
 #define PORT_CEC	(1 << 23)
+#define PORT_CHANGE_MASK	(PORT_CSC | PORT_PEC | PORT_WRC | PORT_OCC | \
+				 PORT_RC | PORT_PLC | PORT_CEC)
+
+
 /* Cold Attach Status - xHC can set this bit to report device attached during
  * Sx state. Warm port reset should be perfomed to clear this bit and move port
  * to connected state.
diff -druNp --no-dereference linux-libre-4.9.114-gnu/drivers/vfio/pci/vfio_pci.c linux-libre-4.9.115-gnu/drivers/vfio/pci/vfio_pci.c
--- linux-libre-4.9.114-gnu/drivers/vfio/pci/vfio_pci.c	2018-07-22 08:27:43.000000000 -0400
+++ linux-libre-4.9.115-gnu/drivers/vfio/pci/vfio_pci.c	2018-07-25 05:24:03.000000000 -0400
@@ -28,6 +28,7 @@
 #include <linux/uaccess.h>
 #include <linux/vfio.h>
 #include <linux/vgaarb.h>
+#include <linux/nospec.h>
 
 #include "vfio_pci_private.h"
 
@@ -755,6 +756,9 @@ static long vfio_pci_ioctl(void *device_
 			if (info.index >=
 			    VFIO_PCI_NUM_REGIONS + vdev->num_regions)
 				return -EINVAL;
+			info.index = array_index_nospec(info.index,
+							VFIO_PCI_NUM_REGIONS +
+							vdev->num_regions);
 
 			i = info.index - VFIO_PCI_NUM_REGIONS;
 
diff -druNp --no-dereference linux-libre-4.9.114-gnu/fs/fat/inode.c linux-libre-4.9.115-gnu/fs/fat/inode.c
--- linux-libre-4.9.114-gnu/fs/fat/inode.c	2018-07-22 08:27:43.000000000 -0400
+++ linux-libre-4.9.115-gnu/fs/fat/inode.c	2018-07-25 05:24:03.000000000 -0400
@@ -696,13 +696,21 @@ static void fat_set_state(struct super_b
 	brelse(bh);
 }
 
+static void fat_reset_iocharset(struct fat_mount_options *opts)
+{
+	if (opts->iocharset != fat_default_iocharset) {
+		/* Note: opts->iocharset can be NULL here */
+		kfree(opts->iocharset);
+		opts->iocharset = fat_default_iocharset;
+	}
+}
+
 static void delayed_free(struct rcu_head *p)
 {
 	struct msdos_sb_info *sbi = container_of(p, struct msdos_sb_info, rcu);
 	unload_nls(sbi->nls_disk);
 	unload_nls(sbi->nls_io);
-	if (sbi->options.iocharset != fat_default_iocharset)
-		kfree(sbi->options.iocharset);
+	fat_reset_iocharset(&sbi->options);
 	kfree(sbi);
 }
 
@@ -1117,7 +1125,7 @@ static int parse_options(struct super_bl
 	opts->fs_fmask = opts->fs_dmask = current_umask();
 	opts->allow_utime = -1;
 	opts->codepage = fat_default_codepage;
-	opts->iocharset = fat_default_iocharset;
+	fat_reset_iocharset(opts);
 	if (is_vfat) {
 		opts->shortname = VFAT_SFN_DISPLAY_WINNT|VFAT_SFN_CREATE_WIN95;
 		opts->rodir = 0;
@@ -1274,8 +1282,7 @@ static int parse_options(struct super_bl
 
 		/* vfat specific */
 		case Opt_charset:
-			if (opts->iocharset != fat_default_iocharset)
-				kfree(opts->iocharset);
+			fat_reset_iocharset(opts);
 			iocharset = match_strdup(&args[0]);
 			if (!iocharset)
 				return -ENOMEM;
@@ -1866,8 +1873,7 @@ out_fail:
 		iput(fat_inode);
 	unload_nls(sbi->nls_io);
 	unload_nls(sbi->nls_disk);
-	if (sbi->options.iocharset != fat_default_iocharset)
-		kfree(sbi->options.iocharset);
+	fat_reset_iocharset(&sbi->options);
 	sb->s_fs_info = NULL;
 	kfree(sbi);
 	return error;
diff -druNp --no-dereference linux-libre-4.9.114-gnu/include/linux/skbuff.h linux-libre-4.9.115-gnu/include/linux/skbuff.h
--- linux-libre-4.9.114-gnu/include/linux/skbuff.h	2018-07-22 08:27:43.000000000 -0400
+++ linux-libre-4.9.115-gnu/include/linux/skbuff.h	2018-07-25 05:24:03.000000000 -0400
@@ -602,6 +602,7 @@ static inline bool skb_mstamp_after(cons
  *	@hash: the packet hash
  *	@queue_mapping: Queue mapping for multiqueue devices
  *	@xmit_more: More SKBs are pending for this queue
+ *	@pfmemalloc: skbuff was allocated from PFMEMALLOC reserves
  *	@ndisc_nodetype: router type (from link layer)
  *	@ooo_okay: allow the mapping of a socket to a queue to be changed
  *	@l4_hash: indicate hash is a canonical 4-tuple hash over transport
@@ -692,7 +693,7 @@ struct sk_buff {
 				peeked:1,
 				head_frag:1,
 				xmit_more:1,
-				__unused:1; /* one bit hole */
+				pfmemalloc:1;
 	kmemcheck_bitfield_end(flags1);
 
 	/* fields enclosed in headers_start/headers_end are copied
@@ -712,19 +713,18 @@ struct sk_buff {
 
 	__u8			__pkt_type_offset[0];
 	__u8			pkt_type:3;
-	__u8			pfmemalloc:1;
 	__u8			ignore_df:1;
 	__u8			nfctinfo:3;
-
 	__u8			nf_trace:1;
+
 	__u8			ip_summed:2;
 	__u8			ooo_okay:1;
 	__u8			l4_hash:1;
 	__u8			sw_hash:1;
 	__u8			wifi_acked_valid:1;
 	__u8			wifi_acked:1;
-
 	__u8			no_fcs:1;
+
 	/* Indicates the inner headers are valid in the skbuff. */
 	__u8			encapsulation:1;
 	__u8			encap_hdr_csum:1;
@@ -732,11 +732,11 @@ struct sk_buff {
 	__u8			csum_complete_sw:1;
 	__u8			csum_level:2;
 	__u8			csum_bad:1;
-
 #ifdef CONFIG_IPV6_NDISC_NODETYPE
 	__u8			ndisc_nodetype:2;
 #endif
 	__u8			ipvs_property:1;
+
 	__u8			inner_protocol_type:1;
 	__u8			remcsum_offload:1;
 #ifdef CONFIG_NET_SWITCHDEV
diff -druNp --no-dereference linux-libre-4.9.114-gnu/include/net/ipv6.h linux-libre-4.9.115-gnu/include/net/ipv6.h
--- linux-libre-4.9.114-gnu/include/net/ipv6.h	2018-07-22 08:27:43.000000000 -0400
+++ linux-libre-4.9.115-gnu/include/net/ipv6.h	2018-07-25 05:24:03.000000000 -0400
@@ -794,7 +794,7 @@ static inline __be32 ip6_make_flowlabel(
 	 * to minimize possbility that any useful information to an
 	 * attacker is leaked. Only lower 20 bits are relevant.
 	 */
-	rol32(hash, 16);
+	hash = rol32(hash, 16);
 
 	flowlabel = (__force __be32)hash & IPV6_FLOWLABEL_MASK;
 
diff -druNp --no-dereference linux-libre-4.9.114-gnu/lib/rhashtable.c linux-libre-4.9.115-gnu/lib/rhashtable.c
--- linux-libre-4.9.114-gnu/lib/rhashtable.c	2018-07-22 08:27:43.000000000 -0400
+++ linux-libre-4.9.115-gnu/lib/rhashtable.c	2018-07-25 05:24:03.000000000 -0400
@@ -783,8 +783,16 @@ EXPORT_SYMBOL_GPL(rhashtable_walk_stop);
 
 static size_t rounded_hashtable_size(const struct rhashtable_params *params)
 {
-	return max(roundup_pow_of_two(params->nelem_hint * 4 / 3),
-		   (unsigned long)params->min_size);
+	size_t retsize;
+
+	if (params->nelem_hint)
+		retsize = max(roundup_pow_of_two(params->nelem_hint * 4 / 3),
+			      (unsigned long)params->min_size);
+	else
+		retsize = max(HASH_DEFAULT_SIZE,
+			      (unsigned long)params->min_size);
+
+	return retsize;
 }
 
 static u32 rhashtable_jhash2(const void *key, u32 length, u32 seed)
@@ -841,8 +849,6 @@ int rhashtable_init(struct rhashtable *h
 	struct bucket_table *tbl;
 	size_t size;
 
-	size = HASH_DEFAULT_SIZE;
-
 	if ((!params->key_len && !params->obj_hashfn) ||
 	    (params->obj_hashfn && !params->obj_cmpfn))
 		return -EINVAL;
@@ -869,8 +875,7 @@ int rhashtable_init(struct rhashtable *h
 
 	ht->p.min_size = max(ht->p.min_size, HASH_MIN_SIZE);
 
-	if (params->nelem_hint)
-		size = rounded_hashtable_size(&ht->p);
+	size = rounded_hashtable_size(&ht->p);
 
 	/* The maximum (not average) chain length grows with the
 	 * size of the hash table, at a rate of (log N)/(log log N).
diff -druNp --no-dereference linux-libre-4.9.114-gnu/Makefile linux-libre-4.9.115-gnu/Makefile
--- linux-libre-4.9.114-gnu/Makefile	2018-07-22 11:23:19.000000000 -0400
+++ linux-libre-4.9.115-gnu/Makefile	2018-07-25 09:58:08.000000000 -0400
@@ -1,6 +1,6 @@
 VERSION = 4
 PATCHLEVEL = 9
-SUBLEVEL = 114
+SUBLEVEL = 115
 EXTRAVERSION = -gnu
 NAME = Roaring Lionus
 
diff -druNp --no-dereference linux-libre-4.9.114-gnu/mm/huge_memory.c linux-libre-4.9.115-gnu/mm/huge_memory.c
--- linux-libre-4.9.114-gnu/mm/huge_memory.c	2018-07-22 08:27:43.000000000 -0400
+++ linux-libre-4.9.115-gnu/mm/huge_memory.c	2018-07-25 05:24:03.000000000 -0400
@@ -1642,6 +1642,8 @@ static void __split_huge_pmd_locked(stru
 		if (vma_is_dax(vma))
 			return;
 		page = pmd_page(_pmd);
+		if (!PageDirty(page) && pmd_dirty(_pmd))
+			set_page_dirty(page);
 		if (!PageReferenced(page) && pmd_young(_pmd))
 			SetPageReferenced(page);
 		page_remove_rmap(page, true);
diff -druNp --no-dereference linux-libre-4.9.114-gnu/mm/memcontrol.c linux-libre-4.9.115-gnu/mm/memcontrol.c
--- linux-libre-4.9.114-gnu/mm/memcontrol.c	2018-07-22 08:27:43.000000000 -0400
+++ linux-libre-4.9.115-gnu/mm/memcontrol.c	2018-07-25 05:24:03.000000000 -0400
@@ -895,7 +895,7 @@ static void invalidate_reclaim_iterators
 	int nid;
 	int i;
 
-	while ((memcg = parent_mem_cgroup(memcg))) {
+	for (; memcg; memcg = parent_mem_cgroup(memcg)) {
 		for_each_node(nid) {
 			mz = mem_cgroup_nodeinfo(memcg, nid);
 			for (i = 0; i <= DEF_PRIORITY; i++) {
diff -druNp --no-dereference linux-libre-4.9.114-gnu/net/core/gen_stats.c linux-libre-4.9.115-gnu/net/core/gen_stats.c
--- linux-libre-4.9.114-gnu/net/core/gen_stats.c	2018-07-22 08:27:43.000000000 -0400
+++ linux-libre-4.9.115-gnu/net/core/gen_stats.c	2018-07-25 05:24:03.000000000 -0400
@@ -77,8 +77,20 @@ gnet_stats_start_copy_compat(struct sk_b
 		d->lock = lock;
 		spin_lock_bh(lock);
 	}
-	if (d->tail)
-		return gnet_stats_copy(d, type, NULL, 0, padattr);
+	if (d->tail) {
+		int ret = gnet_stats_copy(d, type, NULL, 0, padattr);
+
+		/* The initial attribute added in gnet_stats_copy() may be
+		 * preceded by a padding attribute, in which case d->tail will
+		 * end up pointing at the padding instead of the real attribute.
+		 * Fix this so gnet_stats_finish_copy() adjusts the length of
+		 * the right attribute.
+		 */
+		if (ret == 0 && d->tail->nla_type == padattr)
+			d->tail = (struct nlattr *)((char *)d->tail +
+						    NLA_ALIGN(d->tail->nla_len));
+		return ret;
+	}
 
 	return 0;
 }
diff -druNp --no-dereference linux-libre-4.9.114-gnu/net/core/skbuff.c linux-libre-4.9.115-gnu/net/core/skbuff.c
--- linux-libre-4.9.114-gnu/net/core/skbuff.c	2018-07-22 08:27:43.000000000 -0400
+++ linux-libre-4.9.115-gnu/net/core/skbuff.c	2018-07-25 05:24:03.000000000 -0400
@@ -904,6 +904,7 @@ static struct sk_buff *__skb_clone(struc
 	n->cloned = 1;
 	n->nohdr = 0;
 	n->peeked = 0;
+	C(pfmemalloc);
 	n->destructor = NULL;
 	C(tail);
 	C(end);
diff -druNp --no-dereference linux-libre-4.9.114-gnu/net/ipv4/fib_frontend.c linux-libre-4.9.115-gnu/net/ipv4/fib_frontend.c
--- linux-libre-4.9.114-gnu/net/ipv4/fib_frontend.c	2018-07-22 08:27:43.000000000 -0400
+++ linux-libre-4.9.115-gnu/net/ipv4/fib_frontend.c	2018-07-25 05:24:03.000000000 -0400
@@ -290,6 +290,7 @@ __be32 fib_compute_spec_dst(struct sk_bu
 	if (!ipv4_is_zeronet(ip_hdr(skb)->saddr)) {
 		struct flowi4 fl4 = {
 			.flowi4_iif = LOOPBACK_IFINDEX,
+			.flowi4_oif = l3mdev_master_ifindex_rcu(dev),
 			.daddr = ip_hdr(skb)->saddr,
 			.flowi4_tos = RT_TOS(ip_hdr(skb)->tos),
 			.flowi4_scope = scope,
diff -druNp --no-dereference linux-libre-4.9.114-gnu/net/ipv4/sysctl_net_ipv4.c linux-libre-4.9.115-gnu/net/ipv4/sysctl_net_ipv4.c
--- linux-libre-4.9.114-gnu/net/ipv4/sysctl_net_ipv4.c	2018-07-22 08:27:43.000000000 -0400
+++ linux-libre-4.9.115-gnu/net/ipv4/sysctl_net_ipv4.c	2018-07-25 05:24:03.000000000 -0400
@@ -140,8 +140,9 @@ static int ipv4_ping_group_range(struct
 	if (write && ret == 0) {
 		low = make_kgid(user_ns, urange[0]);
 		high = make_kgid(user_ns, urange[1]);
-		if (!gid_valid(low) || !gid_valid(high) ||
-		    (urange[1] < urange[0]) || gid_lt(high, low)) {
+		if (!gid_valid(low) || !gid_valid(high))
+			return -EINVAL;
+		if (urange[1] < urange[0] || gid_lt(high, low)) {
 			low = make_kgid(&init_user_ns, 1);
 			high = make_kgid(&init_user_ns, 0);
 		}
diff -druNp --no-dereference linux-libre-4.9.114-gnu/net/ipv4/tcp.c linux-libre-4.9.115-gnu/net/ipv4/tcp.c
--- linux-libre-4.9.114-gnu/net/ipv4/tcp.c	2018-07-22 08:27:43.000000000 -0400
+++ linux-libre-4.9.115-gnu/net/ipv4/tcp.c	2018-07-25 05:24:03.000000000 -0400
@@ -3238,8 +3238,7 @@ int tcp_abort(struct sock *sk, int err)
 			struct request_sock *req = inet_reqsk(sk);
 
 			local_bh_disable();
-			inet_csk_reqsk_queue_drop_and_put(req->rsk_listener,
-							  req);
+			inet_csk_reqsk_queue_drop(req->rsk_listener, req);
 			local_bh_enable();
 			return 0;
 		}
diff -druNp --no-dereference linux-libre-4.9.114-gnu/net/sunrpc/xprtrdma/rpc_rdma.c linux-libre-4.9.115-gnu/net/sunrpc/xprtrdma/rpc_rdma.c
--- linux-libre-4.9.114-gnu/net/sunrpc/xprtrdma/rpc_rdma.c	2018-07-22 08:27:43.000000000 -0400
+++ linux-libre-4.9.115-gnu/net/sunrpc/xprtrdma/rpc_rdma.c	2018-07-25 05:24:03.000000000 -0400
@@ -229,7 +229,7 @@ rpcrdma_convert_iovs(struct rpcrdma_xprt
 			/* alloc the pagelist for receiving buffer */
 			ppages[p] = alloc_page(GFP_ATOMIC);
 			if (!ppages[p])
-				return -EAGAIN;
+				return -ENOBUFS;
 		}
 		seg[n].mr_page = ppages[p];
 		seg[n].mr_offset = (void *)(unsigned long) page_base;
diff -druNp --no-dereference linux-libre-4.9.114-gnu/sound/core/rawmidi.c linux-libre-4.9.115-gnu/sound/core/rawmidi.c
--- linux-libre-4.9.114-gnu/sound/core/rawmidi.c	2018-07-22 08:27:43.000000000 -0400
+++ linux-libre-4.9.115-gnu/sound/core/rawmidi.c	2018-07-25 05:24:03.000000000 -0400
@@ -635,7 +635,7 @@ static int snd_rawmidi_info_select_user(
 int snd_rawmidi_output_params(struct snd_rawmidi_substream *substream,
 			      struct snd_rawmidi_params * params)
 {
-	char *newbuf;
+	char *newbuf, *oldbuf;
 	struct snd_rawmidi_runtime *runtime = substream->runtime;
 	
 	if (substream->append && substream->use_count > 1)
@@ -648,13 +648,17 @@ int snd_rawmidi_output_params(struct snd
 		return -EINVAL;
 	}
 	if (params->buffer_size != runtime->buffer_size) {
-		newbuf = krealloc(runtime->buffer, params->buffer_size,
-				  GFP_KERNEL);
+		newbuf = kmalloc(params->buffer_size, GFP_KERNEL);
 		if (!newbuf)
 			return -ENOMEM;
+		spin_lock_irq(&runtime->lock);
+		oldbuf = runtime->buffer;
 		runtime->buffer = newbuf;
 		runtime->buffer_size = params->buffer_size;
 		runtime->avail = runtime->buffer_size;
+		runtime->appl_ptr = runtime->hw_ptr = 0;
+		spin_unlock_irq(&runtime->lock);
+		kfree(oldbuf);
 	}
 	runtime->avail_min = params->avail_min;
 	substream->active_sensing = !params->no_active_sensing;
@@ -665,7 +669,7 @@ EXPORT_SYMBOL(snd_rawmidi_output_params)
 int snd_rawmidi_input_params(struct snd_rawmidi_substream *substream,
 			     struct snd_rawmidi_params * params)
 {
-	char *newbuf;
+	char *newbuf, *oldbuf;
 	struct snd_rawmidi_runtime *runtime = substream->runtime;
 
 	snd_rawmidi_drain_input(substream);
@@ -676,12 +680,16 @@ int snd_rawmidi_input_params(struct snd_
 		return -EINVAL;
 	}
 	if (params->buffer_size != runtime->buffer_size) {
-		newbuf = krealloc(runtime->buffer, params->buffer_size,
-				  GFP_KERNEL);
+		newbuf = kmalloc(params->buffer_size, GFP_KERNEL);
 		if (!newbuf)
 			return -ENOMEM;
+		spin_lock_irq(&runtime->lock);
+		oldbuf = runtime->buffer;
 		runtime->buffer = newbuf;
 		runtime->buffer_size = params->buffer_size;
+		runtime->appl_ptr = runtime->hw_ptr = 0;
+		spin_unlock_irq(&runtime->lock);
+		kfree(oldbuf);
 	}
 	runtime->avail_min = params->avail_min;
 	return 0;
diff -druNp --no-dereference linux-libre-4.9.114-gnu/virt/kvm/eventfd.c linux-libre-4.9.115-gnu/virt/kvm/eventfd.c
--- linux-libre-4.9.114-gnu/virt/kvm/eventfd.c	2018-07-22 08:27:43.000000000 -0400
+++ linux-libre-4.9.115-gnu/virt/kvm/eventfd.c	2018-07-25 05:24:03.000000000 -0400
@@ -119,8 +119,12 @@ irqfd_shutdown(struct work_struct *work)
 {
 	struct kvm_kernel_irqfd *irqfd =
 		container_of(work, struct kvm_kernel_irqfd, shutdown);
+	struct kvm *kvm = irqfd->kvm;
 	u64 cnt;
 
+	/* Make sure irqfd has been initalized in assign path. */
+	synchronize_srcu(&kvm->irq_srcu);
+
 	/*
 	 * Synchronize with the wait-queue and unhook ourselves to prevent
 	 * further events.
@@ -387,7 +391,6 @@ kvm_irqfd_assign(struct kvm *kvm, struct
 
 	idx = srcu_read_lock(&kvm->irq_srcu);
 	irqfd_update(kvm, irqfd);
-	srcu_read_unlock(&kvm->irq_srcu, idx);
 
 	list_add_tail(&irqfd->list, &kvm->irqfds.items);
 
@@ -421,6 +424,7 @@ kvm_irqfd_assign(struct kvm *kvm, struct
 	}
 #endif
 
+	srcu_read_unlock(&kvm->irq_srcu, idx);
 	return 0;
 
 fail:
