diff options
-rw-r--r-- | mk/kernel-ver.mk | 4 | ||||
-rw-r--r-- | target/config/Config.in.kernelversion | 2 | ||||
-rw-r--r-- | target/linux/patches/4.9.77/alpha-remove-coff.patch (renamed from target/linux/patches/4.9.71/alpha-remove-coff.patch) | 0 | ||||
-rw-r--r-- | target/linux/patches/4.9.77/crisv32_ethernet_driver.patch (renamed from target/linux/patches/4.9.71/crisv32_ethernet_driver.patch) | 0 | ||||
-rw-r--r-- | target/linux/patches/4.9.77/h8300.patch (renamed from target/linux/patches/4.9.71/h8300.patch) | 0 | ||||
-rw-r--r-- | target/linux/patches/4.9.77/initramfs-nosizelimit.patch (renamed from target/linux/patches/4.9.71/initramfs-nosizelimit.patch) | 0 | ||||
-rw-r--r-- | target/linux/patches/4.9.77/ld-or1k.patch (renamed from target/linux/patches/4.9.71/ld-or1k.patch) | 0 | ||||
-rw-r--r-- | target/linux/patches/4.9.77/macsonic.patch (renamed from target/linux/patches/4.9.71/macsonic.patch) | 0 | ||||
-rw-r--r-- | target/linux/patches/4.9.77/microblaze-sigaltstack.patch (renamed from target/linux/patches/4.9.71/microblaze-sigaltstack.patch) | 0 | ||||
-rw-r--r-- | target/linux/patches/4.9.77/mips64r6-multi3.patch (renamed from target/linux/patches/4.9.71/mips64r6-multi3.patch) | 0 | ||||
-rw-r--r-- | target/linux/patches/4.9.77/or1k-more-ram.patch (renamed from target/linux/patches/4.9.71/or1k-more-ram.patch) | 0 | ||||
-rw-r--r-- | target/linux/patches/4.9.77/patch-realtime (renamed from target/linux/patches/4.9.71/patch-realtime) | 3302 | ||||
-rw-r--r-- | target/linux/patches/4.9.77/sh2.patch (renamed from target/linux/patches/4.9.71/sh2.patch) | 0 | ||||
-rw-r--r-- | target/linux/patches/4.9.77/startup.patch (renamed from target/linux/patches/4.9.71/startup.patch) | 0 | ||||
-rw-r--r-- | target/linux/patches/4.9.77/vdso2.patch (renamed from target/linux/patches/4.9.71/vdso2.patch) | 0 |
15 files changed, 2020 insertions, 1288 deletions
diff --git a/mk/kernel-ver.mk b/mk/kernel-ver.mk index 011f0baf3..42d5c0490 100644 --- a/mk/kernel-ver.mk +++ b/mk/kernel-ver.mk @@ -22,10 +22,10 @@ KERNEL_VERSION:= $(KERNEL_FILE_VER)-$(KERNEL_RELEASE) KERNEL_HASH:= 6ebcc57ba31d714af872347184d1de32f4ab0b7096ef4e062d1ca6b3234d9333 endif ifeq ($(ADK_TARGET_KERNEL_VERSION_4_9),y) -KERNEL_FILE_VER:= 4.9.71 +KERNEL_FILE_VER:= 4.9.77 KERNEL_RELEASE:= 1 KERNEL_VERSION:= $(KERNEL_FILE_VER)-$(KERNEL_RELEASE) -KERNEL_HASH:= f1fd9740fb4ec31180113e99a2329214ae441533ee226075a40d4e0675db769c +KERNEL_HASH:= 7c29bc3fb96f1e23d98f664e786dddd53a1599f56431b9b7fdfba402a4b3705c endif ifeq ($(ADK_TARGET_KERNEL_VERSION_4_4),y) KERNEL_FILE_VER:= 4.4.107 diff --git a/target/config/Config.in.kernelversion b/target/config/Config.in.kernelversion index ec2757683..85620f5e0 100644 --- a/target/config/Config.in.kernelversion +++ b/target/config/Config.in.kernelversion @@ -46,7 +46,7 @@ config ADK_TARGET_KERNEL_VERSION_4_14 depends on !ADK_TARGET_SYSTEM_QEMU_ARM_REALVIEW_EB_MPCORE config ADK_TARGET_KERNEL_VERSION_4_9 - bool "4.9.71" + bool "4.9.77" depends on !ADK_TARGET_ARCH_CRIS depends on !ADK_TARGET_ARCH_CSKY depends on !ADK_TARGET_ARCH_METAG diff --git a/target/linux/patches/4.9.71/alpha-remove-coff.patch b/target/linux/patches/4.9.77/alpha-remove-coff.patch index 176db3c88..176db3c88 100644 --- a/target/linux/patches/4.9.71/alpha-remove-coff.patch +++ b/target/linux/patches/4.9.77/alpha-remove-coff.patch diff --git a/target/linux/patches/4.9.71/crisv32_ethernet_driver.patch b/target/linux/patches/4.9.77/crisv32_ethernet_driver.patch index 0cef202fc..0cef202fc 100644 --- a/target/linux/patches/4.9.71/crisv32_ethernet_driver.patch +++ b/target/linux/patches/4.9.77/crisv32_ethernet_driver.patch diff --git a/target/linux/patches/4.9.71/h8300.patch b/target/linux/patches/4.9.77/h8300.patch index c71194f0a..c71194f0a 100644 --- a/target/linux/patches/4.9.71/h8300.patch +++ b/target/linux/patches/4.9.77/h8300.patch diff --git a/target/linux/patches/4.9.71/initramfs-nosizelimit.patch b/target/linux/patches/4.9.77/initramfs-nosizelimit.patch index 40d2f6bd8..40d2f6bd8 100644 --- a/target/linux/patches/4.9.71/initramfs-nosizelimit.patch +++ b/target/linux/patches/4.9.77/initramfs-nosizelimit.patch diff --git a/target/linux/patches/4.9.71/ld-or1k.patch b/target/linux/patches/4.9.77/ld-or1k.patch index 264f9166f..264f9166f 100644 --- a/target/linux/patches/4.9.71/ld-or1k.patch +++ b/target/linux/patches/4.9.77/ld-or1k.patch diff --git a/target/linux/patches/4.9.71/macsonic.patch b/target/linux/patches/4.9.77/macsonic.patch index 75a6fcad2..75a6fcad2 100644 --- a/target/linux/patches/4.9.71/macsonic.patch +++ b/target/linux/patches/4.9.77/macsonic.patch diff --git a/target/linux/patches/4.9.71/microblaze-sigaltstack.patch b/target/linux/patches/4.9.77/microblaze-sigaltstack.patch index c4064e8b9..c4064e8b9 100644 --- a/target/linux/patches/4.9.71/microblaze-sigaltstack.patch +++ b/target/linux/patches/4.9.77/microblaze-sigaltstack.patch diff --git a/target/linux/patches/4.9.71/mips64r6-multi3.patch b/target/linux/patches/4.9.77/mips64r6-multi3.patch index 771febe29..771febe29 100644 --- a/target/linux/patches/4.9.71/mips64r6-multi3.patch +++ b/target/linux/patches/4.9.77/mips64r6-multi3.patch diff --git a/target/linux/patches/4.9.71/or1k-more-ram.patch b/target/linux/patches/4.9.77/or1k-more-ram.patch index de848c838..de848c838 100644 --- a/target/linux/patches/4.9.71/or1k-more-ram.patch +++ b/target/linux/patches/4.9.77/or1k-more-ram.patch diff --git a/target/linux/patches/4.9.71/patch-realtime b/target/linux/patches/4.9.77/patch-realtime index 7abba16fe..7bb72e14d 100644 --- a/target/linux/patches/4.9.71/patch-realtime +++ b/target/linux/patches/4.9.77/patch-realtime @@ -378,7 +378,7 @@ diff --git a/arch/arm/kernel/entry-armv.S b/arch/arm/kernel/entry-armv.S index 9f157e7c51e7..468e224d76aa 100644 --- a/arch/arm/kernel/entry-armv.S +++ b/arch/arm/kernel/entry-armv.S -@@ -220,11 +220,18 @@ ENDPROC(__dabt_svc) +@@ -220,11 +220,18 @@ __irq_svc: #ifdef CONFIG_PREEMPT ldr r8, [tsk, #TI_PREEMPT] @ get preempt count @@ -399,7 +399,7 @@ index 9f157e7c51e7..468e224d76aa 100644 #endif svc_exit r5, irq = 1 @ return from exception -@@ -239,8 +246,14 @@ ENDPROC(__irq_svc) +@@ -239,8 +246,14 @@ svc_preempt: 1: bl preempt_schedule_irq @ irq en/disable is done inside ldr r0, [tsk, #TI_FLAGS] @ get new tasks TI_FLAGS tst r0, #_TIF_NEED_RESCHED @@ -419,7 +419,7 @@ diff --git a/arch/arm/kernel/entry-common.S b/arch/arm/kernel/entry-common.S index 10c3283d6c19..8872937862cc 100644 --- a/arch/arm/kernel/entry-common.S +++ b/arch/arm/kernel/entry-common.S -@@ -36,7 +36,9 @@ +@@ -36,7 +36,9 @@ ret_fast_syscall: UNWIND(.cantunwind ) disable_irq_notrace @ disable interrupts ldr r1, [tsk, #TI_FLAGS] @ re-check for syscall tracing @@ -430,7 +430,7 @@ index 10c3283d6c19..8872937862cc 100644 bne fast_work_pending /* perform architecture specific actions before user return */ -@@ -62,8 +64,11 @@ ENDPROC(ret_fast_syscall) +@@ -62,8 +64,11 @@ ret_fast_syscall: str r0, [sp, #S_R0 + S_OFF]! @ save returned r0 disable_irq_notrace @ disable interrupts ldr r1, [tsk, #TI_FLAGS] @ re-check for syscall tracing @@ -983,10 +983,10 @@ index ea5a2277ee46..b988e081ac79 100644 return pen_release != -1 ? -ENOSYS : 0; } diff --git a/arch/arm/mm/fault.c b/arch/arm/mm/fault.c -index 0122ad1a6027..926b1be48043 100644 +index f7861dc83182..ce47dfe25fb0 100644 --- a/arch/arm/mm/fault.c +++ b/arch/arm/mm/fault.c -@@ -430,6 +430,9 @@ do_translation_fault(unsigned long addr, unsigned int fsr, +@@ -433,6 +433,9 @@ do_translation_fault(unsigned long addr, unsigned int fsr, if (addr < TASK_SIZE) return do_page_fault(addr, fsr, regs); @@ -996,7 +996,7 @@ index 0122ad1a6027..926b1be48043 100644 if (user_mode(regs)) goto bad_area; -@@ -497,6 +500,9 @@ do_translation_fault(unsigned long addr, unsigned int fsr, +@@ -500,6 +503,9 @@ do_translation_fault(unsigned long addr, unsigned int fsr, static int do_sect_fault(unsigned long addr, unsigned int fsr, struct pt_regs *regs) { @@ -1255,10 +1255,10 @@ index c58ddf8c4062..a8f2f7c1fe12 100644 DEFINE(TI_TASK, offsetof(struct thread_info, task)); DEFINE(TI_CPU, offsetof(struct thread_info, cpu)); diff --git a/arch/arm64/kernel/entry.S b/arch/arm64/kernel/entry.S -index 79b0fe24d5b7..f3c959ade308 100644 +index b4c7db434654..433d846f4f51 100644 --- a/arch/arm64/kernel/entry.S +++ b/arch/arm64/kernel/entry.S -@@ -428,11 +428,16 @@ ENDPROC(el1_sync) +@@ -430,11 +430,16 @@ el1_irq: #ifdef CONFIG_PREEMPT ldr w24, [tsk, #TI_PREEMPT] // get preempt count @@ -1278,7 +1278,7 @@ index 79b0fe24d5b7..f3c959ade308 100644 #endif #ifdef CONFIG_TRACE_IRQFLAGS bl trace_hardirqs_on -@@ -446,6 +451,7 @@ ENDPROC(el1_irq) +@@ -448,6 +453,7 @@ el1_preempt: 1: bl preempt_schedule_irq // irq en/disable is done inside ldr x0, [tsk, #TI_FLAGS] // get new tasks TI_FLAGS tbnz x0, #TIF_NEED_RESCHED, 1b // needs rescheduling? @@ -1313,7 +1313,7 @@ index 5e844f68e847..dc613cc10f54 100644 config CPU_SUPPORTS_HIGHMEM bool diff --git a/arch/powerpc/Kconfig b/arch/powerpc/Kconfig -index 8f01f21e78f1..619485b777d2 100644 +index 6eda5abbd719..601e27701a4a 100644 --- a/arch/powerpc/Kconfig +++ b/arch/powerpc/Kconfig @@ -52,10 +52,11 @@ config LOCKDEP_SUPPORT @@ -1412,7 +1412,7 @@ diff --git a/arch/powerpc/kernel/entry_32.S b/arch/powerpc/kernel/entry_32.S index 3841d749a430..6dbaeff192b9 100644 --- a/arch/powerpc/kernel/entry_32.S +++ b/arch/powerpc/kernel/entry_32.S -@@ -835,7 +835,14 @@ user_exc_return: /* r10 contains MSR_KERNEL here */ +@@ -835,7 +835,14 @@ resume_kernel: cmpwi 0,r0,0 /* if non-zero, just restore regs and return */ bne restore andi. r8,r8,_TIF_NEED_RESCHED @@ -1427,7 +1427,7 @@ index 3841d749a430..6dbaeff192b9 100644 lwz r3,_MSR(r1) andi. r0,r3,MSR_EE /* interrupts off? */ beq restore /* don't schedule if so */ -@@ -846,11 +853,11 @@ user_exc_return: /* r10 contains MSR_KERNEL here */ +@@ -846,11 +853,11 @@ resume_kernel: */ bl trace_hardirqs_off #endif @@ -1442,7 +1442,7 @@ index 3841d749a430..6dbaeff192b9 100644 #ifdef CONFIG_TRACE_IRQFLAGS /* And now, to properly rebalance the above, we tell lockdep they * are being turned back on, which will happen when we return -@@ -1171,7 +1178,7 @@ END_FTR_SECTION_IFSET(CPU_FTR_NEED_PAIRED_STWCX) +@@ -1171,7 +1178,7 @@ global_dbcr0: #endif /* !(CONFIG_4xx || CONFIG_BOOKE) */ do_work: /* r10 contains MSR_KERNEL here */ @@ -1451,7 +1451,7 @@ index 3841d749a430..6dbaeff192b9 100644 beq do_user_signal do_resched: /* r10 contains MSR_KERNEL here */ -@@ -1192,7 +1199,7 @@ do_resched: /* r10 contains MSR_KERNEL here */ +@@ -1192,7 +1199,7 @@ recheck: MTMSRD(r10) /* disable interrupts */ CURRENT_THREAD_INFO(r9, r1) lwz r9,TI_FLAGS(r9) @@ -1461,7 +1461,7 @@ index 3841d749a430..6dbaeff192b9 100644 andi. r0,r9,_TIF_USER_WORK_MASK beq restore_user diff --git a/arch/powerpc/kernel/entry_64.S b/arch/powerpc/kernel/entry_64.S -index 767ef6d68c9e..2cb4d5552319 100644 +index caa659671599..891080c4a41e 100644 --- a/arch/powerpc/kernel/entry_64.S +++ b/arch/powerpc/kernel/entry_64.S @@ -656,7 +656,7 @@ _GLOBAL(ret_from_except_lite) @@ -1473,29 +1473,27 @@ index 767ef6d68c9e..2cb4d5552319 100644 beq 2f bl restore_interrupts SCHEDULE_USER -@@ -718,10 +718,18 @@ _GLOBAL(ret_from_except_lite) +@@ -718,10 +718,18 @@ resume_kernel: #ifdef CONFIG_PREEMPT /* Check if we need to preempt */ -- andi. r0,r4,_TIF_NEED_RESCHED -- beq+ restore -- /* Check that preempt_count() == 0 and interrupts are enabled */ - lwz r8,TI_PREEMPT(r9) ++ lwz r8,TI_PREEMPT(r9) + cmpwi 0,r8,0 /* if non-zero, just restore regs and return */ + bne restore -+ andi. r0,r4,_TIF_NEED_RESCHED + andi. r0,r4,_TIF_NEED_RESCHED + bne+ check_count + + andi. r0,r4,_TIF_NEED_RESCHED_LAZY -+ beq+ restore + beq+ restore + lwz r8,TI_PREEMPT_LAZY(r9) + -+ /* Check that preempt_count() == 0 and interrupts are enabled */ + /* Check that preempt_count() == 0 and interrupts are enabled */ +- lwz r8,TI_PREEMPT(r9) +check_count: cmpwi cr1,r8,0 ld r0,SOFTE(r1) cmpdi r0,0 -@@ -738,7 +746,7 @@ _GLOBAL(ret_from_except_lite) +@@ -738,7 +746,7 @@ resume_kernel: /* Re-test flags and eventually loop */ CURRENT_THREAD_INFO(r9, r1) ld r4,TI_FLAGS(r9) @@ -1505,10 +1503,10 @@ index 767ef6d68c9e..2cb4d5552319 100644 /* diff --git a/arch/powerpc/kernel/irq.c b/arch/powerpc/kernel/irq.c -index 3c05c311e35e..f83f6ac1274d 100644 +index 028a22bfa90c..a75e2dd3e71f 100644 --- a/arch/powerpc/kernel/irq.c +++ b/arch/powerpc/kernel/irq.c -@@ -638,6 +638,7 @@ void irq_ctx_init(void) +@@ -651,6 +651,7 @@ void irq_ctx_init(void) } } @@ -1516,7 +1514,7 @@ index 3c05c311e35e..f83f6ac1274d 100644 void do_softirq_own_stack(void) { struct thread_info *curtp, *irqtp; -@@ -655,6 +656,7 @@ void do_softirq_own_stack(void) +@@ -668,6 +669,7 @@ void do_softirq_own_stack(void) if (irqtp->flags) set_bits(irqtp->flags, &curtp->flags); } @@ -1610,7 +1608,7 @@ index 6c0378c0b8b5..abd58b4dff97 100644 static inline void handle_one_irq(unsigned int irq) { diff --git a/arch/sparc/Kconfig b/arch/sparc/Kconfig -index 165ecdd24d22..b68a464a22be 100644 +index 8b4152f3a764..c5cca159692a 100644 --- a/arch/sparc/Kconfig +++ b/arch/sparc/Kconfig @@ -194,12 +194,10 @@ config NR_CPUS @@ -1629,7 +1627,7 @@ index 165ecdd24d22..b68a464a22be 100644 config GENERIC_HWEIGHT bool diff --git a/arch/sparc/kernel/irq_64.c b/arch/sparc/kernel/irq_64.c -index 34a7930b76ef..773740521008 100644 +index 5cbf03c14981..6067d9379e5b 100644 --- a/arch/sparc/kernel/irq_64.c +++ b/arch/sparc/kernel/irq_64.c @@ -854,6 +854,7 @@ void __irq_entry handler_irq(int pil, struct pt_regs *regs) @@ -1649,7 +1647,7 @@ index 34a7930b76ef..773740521008 100644 #ifdef CONFIG_HOTPLUG_CPU void fixup_irqs(void) diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig -index bada636d1065..f8a995c90c01 100644 +index da8156fd3d58..d8cd3bc807fc 100644 --- a/arch/x86/Kconfig +++ b/arch/x86/Kconfig @@ -17,6 +17,7 @@ config X86_64 @@ -2042,10 +2040,10 @@ index edba8606b99a..4a3389535fc6 100644 jz restore_all call preempt_schedule_irq diff --git a/arch/x86/entry/entry_64.S b/arch/x86/entry/entry_64.S -index ef766a358b37..28401f826ab1 100644 +index af4e58132d91..22803e2f7495 100644 --- a/arch/x86/entry/entry_64.S +++ b/arch/x86/entry/entry_64.S -@@ -546,7 +546,23 @@ GLOBAL(retint_user) +@@ -575,7 +575,23 @@ retint_kernel: bt $9, EFLAGS(%rsp) /* were interrupts off? */ jnc 1f 0: cmpl $0, PER_CPU_VAR(__preempt_count) @@ -2069,7 +2067,7 @@ index ef766a358b37..28401f826ab1 100644 call preempt_schedule_irq jmp 0b 1: -@@ -894,6 +910,7 @@ EXPORT_SYMBOL(native_load_gs_index) +@@ -925,6 +941,7 @@ bad_gs: jmp 2b .previous @@ -2077,7 +2075,7 @@ index ef766a358b37..28401f826ab1 100644 /* Call softirq on interrupt stack. Interrupts are off. */ ENTRY(do_softirq_own_stack) pushq %rbp -@@ -906,6 +923,7 @@ ENTRY(do_softirq_own_stack) +@@ -937,6 +954,7 @@ ENTRY(do_softirq_own_stack) decl PER_CPU_VAR(irq_count) ret END(do_softirq_own_stack) @@ -2283,7 +2281,7 @@ index 57ab86d94d64..35d25e27180f 100644 } diff --git a/arch/x86/kernel/acpi/boot.c b/arch/x86/kernel/acpi/boot.c -index 931ced8ca345..167975ac8af7 100644 +index 11cc600f4df0..8cbfc51ce339 100644 --- a/arch/x86/kernel/acpi/boot.c +++ b/arch/x86/kernel/acpi/boot.c @@ -87,7 +87,9 @@ static u64 acpi_lapic_addr __initdata = APIC_DEFAULT_PHYS_BASE; @@ -2297,7 +2295,7 @@ index 931ced8ca345..167975ac8af7 100644 /* -------------------------------------------------------------------------- Boot-time Configuration diff --git a/arch/x86/kernel/apic/io_apic.c b/arch/x86/kernel/apic/io_apic.c -index 7249f1500bcb..a79d5c224004 100644 +index cf89928dbd46..18b5ec2a71df 100644 --- a/arch/x86/kernel/apic/io_apic.c +++ b/arch/x86/kernel/apic/io_apic.c @@ -1712,7 +1712,8 @@ static bool io_apic_level_ack_pending(struct mp_chip_data *data) @@ -2329,7 +2327,7 @@ index c62e015b126c..0cc71257fca6 100644 + DEFINE(_PREEMPT_ENABLED, PREEMPT_ENABLED); } diff --git a/arch/x86/kernel/cpu/mcheck/mce.c b/arch/x86/kernel/cpu/mcheck/mce.c -index 22cda29d654e..57c85e3af092 100644 +index 8ca5f8ad008e..edcbd18b3189 100644 --- a/arch/x86/kernel/cpu/mcheck/mce.c +++ b/arch/x86/kernel/cpu/mcheck/mce.c @@ -41,6 +41,8 @@ @@ -2341,7 +2339,7 @@ index 22cda29d654e..57c85e3af092 100644 #include <linux/jump_label.h> #include <asm/processor.h> -@@ -1307,7 +1309,7 @@ void mce_log_therm_throt_event(__u64 status) +@@ -1306,7 +1308,7 @@ void mce_log_therm_throt_event(__u64 status) static unsigned long check_interval = INITIAL_CHECK_INTERVAL; static DEFINE_PER_CPU(unsigned long, mce_next_interval); /* in jiffies */ @@ -2350,7 +2348,7 @@ index 22cda29d654e..57c85e3af092 100644 static unsigned long mce_adjust_timer_default(unsigned long interval) { -@@ -1316,32 +1318,18 @@ static unsigned long mce_adjust_timer_default(unsigned long interval) +@@ -1315,32 +1317,18 @@ static unsigned long mce_adjust_timer_default(unsigned long interval) static unsigned long (*mce_adjust_timer)(unsigned long interval) = mce_adjust_timer_default; @@ -2389,7 +2387,7 @@ index 22cda29d654e..57c85e3af092 100644 iv = __this_cpu_read(mce_next_interval); if (mce_available(this_cpu_ptr(&cpu_info))) { -@@ -1364,7 +1352,7 @@ static void mce_timer_fn(unsigned long data) +@@ -1363,7 +1351,7 @@ static void mce_timer_fn(unsigned long data) done: __this_cpu_write(mce_next_interval, iv); @@ -2398,7 +2396,7 @@ index 22cda29d654e..57c85e3af092 100644 } /* -@@ -1372,7 +1360,7 @@ static void mce_timer_fn(unsigned long data) +@@ -1371,7 +1359,7 @@ static void mce_timer_fn(unsigned long data) */ void mce_timer_kick(unsigned long interval) { @@ -2407,7 +2405,7 @@ index 22cda29d654e..57c85e3af092 100644 unsigned long iv = __this_cpu_read(mce_next_interval); __restart_timer(t, interval); -@@ -1387,7 +1375,7 @@ static void mce_timer_delete_all(void) +@@ -1386,7 +1374,7 @@ static void mce_timer_delete_all(void) int cpu; for_each_online_cpu(cpu) @@ -2416,7 +2414,7 @@ index 22cda29d654e..57c85e3af092 100644 } static void mce_do_trigger(struct work_struct *work) -@@ -1397,6 +1385,56 @@ static void mce_do_trigger(struct work_struct *work) +@@ -1396,6 +1384,56 @@ static void mce_do_trigger(struct work_struct *work) static DECLARE_WORK(mce_trigger_work, mce_do_trigger); @@ -2473,7 +2471,7 @@ index 22cda29d654e..57c85e3af092 100644 /* * Notify the user(s) about new machine check events. * Can be called from interrupt context, but not from machine check/NMI -@@ -1404,19 +1442,8 @@ static DECLARE_WORK(mce_trigger_work, mce_do_trigger); +@@ -1403,19 +1441,8 @@ static DECLARE_WORK(mce_trigger_work, mce_do_trigger); */ int mce_notify_irq(void) { @@ -2494,7 +2492,7 @@ index 22cda29d654e..57c85e3af092 100644 return 1; } return 0; -@@ -1722,7 +1749,7 @@ static void __mcheck_cpu_clear_vendor(struct cpuinfo_x86 *c) +@@ -1721,7 +1748,7 @@ static void __mcheck_cpu_clear_vendor(struct cpuinfo_x86 *c) } } @@ -2503,7 +2501,7 @@ index 22cda29d654e..57c85e3af092 100644 { unsigned long iv = check_interval * HZ; -@@ -1731,16 +1758,17 @@ static void mce_start_timer(unsigned int cpu, struct timer_list *t) +@@ -1730,16 +1757,17 @@ static void mce_start_timer(unsigned int cpu, struct timer_list *t) per_cpu(mce_next_interval, cpu) = iv; @@ -2525,7 +2523,7 @@ index 22cda29d654e..57c85e3af092 100644 mce_start_timer(cpu, t); } -@@ -2465,6 +2493,8 @@ static void mce_disable_cpu(void *h) +@@ -2464,6 +2492,8 @@ static void mce_disable_cpu(void *h) if (!mce_available(raw_cpu_ptr(&cpu_info))) return; @@ -2534,7 +2532,7 @@ index 22cda29d654e..57c85e3af092 100644 if (!(action & CPU_TASKS_FROZEN)) cmci_clear(); -@@ -2487,6 +2517,7 @@ static void mce_reenable_cpu(void *h) +@@ -2486,6 +2516,7 @@ static void mce_reenable_cpu(void *h) if (b->init) wrmsrl(msr_ops.ctl(i), b->ctl); } @@ -2542,7 +2540,7 @@ index 22cda29d654e..57c85e3af092 100644 } /* Get notified when a cpu comes on/off. Be hotplug friendly. */ -@@ -2494,7 +2525,6 @@ static int +@@ -2493,7 +2524,6 @@ static int mce_cpu_callback(struct notifier_block *nfb, unsigned long action, void *hcpu) { unsigned int cpu = (unsigned long)hcpu; @@ -2550,7 +2548,7 @@ index 22cda29d654e..57c85e3af092 100644 switch (action & ~CPU_TASKS_FROZEN) { case CPU_ONLINE: -@@ -2514,11 +2544,9 @@ mce_cpu_callback(struct notifier_block *nfb, unsigned long action, void *hcpu) +@@ -2513,11 +2543,9 @@ mce_cpu_callback(struct notifier_block *nfb, unsigned long action, void *hcpu) break; case CPU_DOWN_PREPARE: smp_call_function_single(cpu, mce_disable_cpu, &action, 1); @@ -2562,7 +2560,7 @@ index 22cda29d654e..57c85e3af092 100644 break; } -@@ -2557,6 +2585,10 @@ static __init int mcheck_init_device(void) +@@ -2556,6 +2584,10 @@ static __init int mcheck_init_device(void) goto err_out; } @@ -2651,10 +2649,10 @@ index bd7be8efdc4c..b3b0a7f7b1ca 100644 * Leave lazy mode, flushing any hypercalls made here. * This must be done before restoring TLS segments so diff --git a/arch/x86/kvm/lapic.c b/arch/x86/kvm/lapic.c -index 3f05c044720b..fe68afd37162 100644 +index b24b3c6d686e..02a062b0de5d 100644 --- a/arch/x86/kvm/lapic.c +++ b/arch/x86/kvm/lapic.c -@@ -1939,6 +1939,7 @@ int kvm_create_lapic(struct kvm_vcpu *vcpu) +@@ -1944,6 +1944,7 @@ int kvm_create_lapic(struct kvm_vcpu *vcpu) hrtimer_init(&apic->lapic_timer.timer, CLOCK_MONOTONIC, HRTIMER_MODE_ABS_PINNED); apic->lapic_timer.timer.function = apic_timer_fn; @@ -2663,10 +2661,10 @@ index 3f05c044720b..fe68afd37162 100644 /* * APIC is created enabled. This will prevent kvm_lapic_set_base from diff --git a/arch/x86/kvm/x86.c b/arch/x86/kvm/x86.c -index 81bba3c2137d..fcb84512e85d 100644 +index 73304b1a03cc..2a0fae2ef089 100644 --- a/arch/x86/kvm/x86.c +++ b/arch/x86/kvm/x86.c -@@ -5958,6 +5958,13 @@ int kvm_arch_init(void *opaque) +@@ -5967,6 +5967,13 @@ int kvm_arch_init(void *opaque) goto out; } @@ -2765,10 +2763,10 @@ index ada98b39b8ad..585f6829653b 100644 kmap_atomic_idx_pop(); } diff --git a/arch/x86/mm/pageattr.c b/arch/x86/mm/pageattr.c -index e3353c97d086..01664968555c 100644 +index 73dcb0e18c1b..c1085c7ee212 100644 --- a/arch/x86/mm/pageattr.c +++ b/arch/x86/mm/pageattr.c -@@ -214,7 +214,15 @@ static void cpa_flush_array(unsigned long *start, int numpages, int cache, +@@ -215,7 +215,15 @@ static void cpa_flush_array(unsigned long *start, int numpages, int cache, int in_flags, struct page **pages) { unsigned int i, level; @@ -2785,7 +2783,7 @@ index e3353c97d086..01664968555c 100644 BUG_ON(irqs_disabled()); diff --git a/arch/x86/platform/uv/tlb_uv.c b/arch/x86/platform/uv/tlb_uv.c -index 9e42842e924a..5398f97172f9 100644 +index 0f0175186f1b..39b5d5b2627d 100644 --- a/arch/x86/platform/uv/tlb_uv.c +++ b/arch/x86/platform/uv/tlb_uv.c @@ -748,9 +748,9 @@ static void destination_plugged(struct bau_desc *bau_desc, @@ -2861,7 +2859,7 @@ index 9e42842e924a..5398f97172f9 100644 return -1; } -@@ -1940,9 +1940,9 @@ static void __init init_per_cpu_tunables(void) +@@ -1939,9 +1939,9 @@ static void __init init_per_cpu_tunables(void) bcp->cong_reps = congested_reps; bcp->disabled_period = sec_2_cycles(disabled_period); bcp->giveup_limit = giveup_limit; @@ -2959,7 +2957,7 @@ index b333fc45f9ec..8b85916e6986 100644 /* diff --git a/block/blk-core.c b/block/blk-core.c -index d1f2801ce836..6f945bb0fa1a 100644 +index 23daf40be371..e8341f78f119 100644 --- a/block/blk-core.c +++ b/block/blk-core.c @@ -125,6 +125,9 @@ void blk_rq_init(struct request_queue *q, struct request *rq) @@ -2976,12 +2974,12 @@ index d1f2801ce836..6f945bb0fa1a 100644 **/ void blk_start_queue(struct request_queue *q) { -- WARN_ON(!irqs_disabled()); -+ WARN_ON_NONRT(!irqs_disabled()); +- WARN_ON(!in_interrupt() && !irqs_disabled()); ++ WARN_ON_NONRT(!in_interrupt() && !irqs_disabled()); queue_flag_clear(QUEUE_FLAG_STOPPED, q); __blk_run_queue(q); -@@ -659,7 +662,7 @@ int blk_queue_enter(struct request_queue *q, bool nowait) +@@ -660,7 +663,7 @@ int blk_queue_enter(struct request_queue *q, bool nowait) if (nowait) return -EBUSY; @@ -2990,7 +2988,7 @@ index d1f2801ce836..6f945bb0fa1a 100644 !atomic_read(&q->mq_freeze_depth) || blk_queue_dying(q)); if (blk_queue_dying(q)) -@@ -679,7 +682,7 @@ static void blk_queue_usage_counter_release(struct percpu_ref *ref) +@@ -680,7 +683,7 @@ static void blk_queue_usage_counter_release(struct percpu_ref *ref) struct request_queue *q = container_of(ref, struct request_queue, q_usage_counter); @@ -2999,7 +2997,7 @@ index d1f2801ce836..6f945bb0fa1a 100644 } static void blk_rq_timed_out_timer(unsigned long data) -@@ -748,7 +751,7 @@ struct request_queue *blk_alloc_queue_node(gfp_t gfp_mask, int node_id) +@@ -750,7 +753,7 @@ struct request_queue *blk_alloc_queue_node(gfp_t gfp_mask, int node_id) q->bypass_depth = 1; __set_bit(QUEUE_FLAG_BYPASS, &q->queue_flags); @@ -3008,7 +3006,7 @@ index d1f2801ce836..6f945bb0fa1a 100644 /* * Init percpu_ref in atomic mode so that it's faster to shutdown. -@@ -3200,7 +3203,7 @@ static void queue_unplugged(struct request_queue *q, unsigned int depth, +@@ -3202,7 +3205,7 @@ static void queue_unplugged(struct request_queue *q, unsigned int depth, blk_run_queue_async(q); else __blk_run_queue(q); @@ -3017,7 +3015,7 @@ index d1f2801ce836..6f945bb0fa1a 100644 } static void flush_plug_callbacks(struct blk_plug *plug, bool from_schedule) -@@ -3248,7 +3251,6 @@ EXPORT_SYMBOL(blk_check_plugged); +@@ -3250,7 +3253,6 @@ EXPORT_SYMBOL(blk_check_plugged); void blk_flush_plug_list(struct blk_plug *plug, bool from_schedule) { struct request_queue *q; @@ -3025,7 +3023,7 @@ index d1f2801ce836..6f945bb0fa1a 100644 struct request *rq; LIST_HEAD(list); unsigned int depth; -@@ -3268,11 +3270,6 @@ void blk_flush_plug_list(struct blk_plug *plug, bool from_schedule) +@@ -3270,11 +3272,6 @@ void blk_flush_plug_list(struct blk_plug *plug, bool from_schedule) q = NULL; depth = 0; @@ -3037,7 +3035,7 @@ index d1f2801ce836..6f945bb0fa1a 100644 while (!list_empty(&list)) { rq = list_entry_rq(list.next); list_del_init(&rq->queuelist); -@@ -3285,7 +3282,7 @@ void blk_flush_plug_list(struct blk_plug *plug, bool from_schedule) +@@ -3287,7 +3284,7 @@ void blk_flush_plug_list(struct blk_plug *plug, bool from_schedule) queue_unplugged(q, depth, from_schedule); q = rq->q; depth = 0; @@ -3046,7 +3044,7 @@ index d1f2801ce836..6f945bb0fa1a 100644 } /* -@@ -3312,8 +3309,6 @@ void blk_flush_plug_list(struct blk_plug *plug, bool from_schedule) +@@ -3314,8 +3311,6 @@ void blk_flush_plug_list(struct blk_plug *plug, bool from_schedule) */ if (q) queue_unplugged(q, depth, from_schedule); @@ -3086,7 +3084,7 @@ index 381cb50a673c..dc8785233d94 100644 } } diff --git a/block/blk-mq.c b/block/blk-mq.c -index 7b597ec4e9c5..48c9652a701c 100644 +index 10f8f94b7f20..82500641f37b 100644 --- a/block/blk-mq.c +++ b/block/blk-mq.c @@ -72,7 +72,7 @@ EXPORT_SYMBOL_GPL(blk_mq_freeze_queue_start); @@ -3198,10 +3196,10 @@ index 7b597ec4e9c5..48c9652a701c 100644 kblockd_schedule_work_on(blk_mq_hctx_next_cpu(hctx), &hctx->run_work); diff --git a/block/blk-mq.h b/block/blk-mq.h -index e5d25249028c..1e846b842eab 100644 +index c55bcf67b956..c26a84d44cc4 100644 --- a/block/blk-mq.h +++ b/block/blk-mq.h -@@ -72,12 +72,12 @@ static inline struct blk_mq_ctx *__blk_mq_get_ctx(struct request_queue *q, +@@ -73,12 +73,12 @@ static inline struct blk_mq_ctx *__blk_mq_get_ctx(struct request_queue *q, */ static inline struct blk_mq_ctx *blk_mq_get_ctx(struct request_queue *q) { @@ -3409,7 +3407,7 @@ index 15073375bd00..357e7ca5a587 100644 /* Delete the reader/writer lock */ diff --git a/drivers/ata/libata-sff.c b/drivers/ata/libata-sff.c -index 051b6158d1b7..7ad293bef6ed 100644 +index 8d22acdf90f0..64fbad747da9 100644 --- a/drivers/ata/libata-sff.c +++ b/drivers/ata/libata-sff.c @@ -678,9 +678,9 @@ unsigned int ata_sff_data_xfer_noirq(struct ata_device *dev, unsigned char *buf, @@ -3461,17 +3459,17 @@ index 051b6158d1b7..7ad293bef6ed 100644 buf = page_address(page); consumed = ap->ops->sff_data_xfer(dev, buf + offset, diff --git a/drivers/block/zram/zcomp.c b/drivers/block/zram/zcomp.c -index 4b5cd3a7b2b6..fa8329ad79fd 100644 +index 4b5cd3a7b2b6..8c93ee150ee8 100644 --- a/drivers/block/zram/zcomp.c +++ b/drivers/block/zram/zcomp.c -@@ -118,12 +118,19 @@ ssize_t zcomp_available_show(const char *comp, char *buf) +@@ -118,12 +118,20 @@ ssize_t zcomp_available_show(const char *comp, char *buf) struct zcomp_strm *zcomp_stream_get(struct zcomp *comp) { - return *get_cpu_ptr(comp->stream); + struct zcomp_strm *zstrm; + -+ zstrm = *this_cpu_ptr(comp->stream); ++ zstrm = *get_local_ptr(comp->stream); + spin_lock(&zstrm->zcomp_lock); + return zstrm; } @@ -3483,10 +3481,11 @@ index 4b5cd3a7b2b6..fa8329ad79fd 100644 + + zstrm = *this_cpu_ptr(comp->stream); + spin_unlock(&zstrm->zcomp_lock); ++ put_local_ptr(zstrm); } int zcomp_compress(struct zcomp_strm *zstrm, -@@ -174,6 +181,7 @@ static int __zcomp_cpu_notifier(struct zcomp *comp, +@@ -174,6 +182,7 @@ static int __zcomp_cpu_notifier(struct zcomp *comp, pr_err("Can't allocate a compression stream\n"); return NOTIFY_BAD; } @@ -3507,7 +3506,7 @@ index 478cac2ed465..f7a6efdc3285 100644 /* dynamic per-device compression frontend */ diff --git a/drivers/block/zram/zram_drv.c b/drivers/block/zram/zram_drv.c -index c9914d653968..2038d138f286 100644 +index b7c0b69a02f5..47d033b8a966 100644 --- a/drivers/block/zram/zram_drv.c +++ b/drivers/block/zram/zram_drv.c @@ -528,6 +528,8 @@ static struct zram_meta *zram_meta_alloc(char *pool_name, u64 disksize) @@ -3793,6 +3792,60 @@ index 08d1dd58c0d2..25ee319dc8e3 100644 return ret; } #endif +diff --git a/drivers/char/tpm/tpm_tis.c b/drivers/char/tpm/tpm_tis.c +index 8022bea27fed..247330efd310 100644 +--- a/drivers/char/tpm/tpm_tis.c ++++ b/drivers/char/tpm/tpm_tis.c +@@ -50,6 +50,31 @@ static inline struct tpm_tis_tcg_phy *to_tpm_tis_tcg_phy(struct tpm_tis_data *da + return container_of(data, struct tpm_tis_tcg_phy, priv); + } + ++#ifdef CONFIG_PREEMPT_RT_FULL ++/* ++ * Flushes previous write operations to chip so that a subsequent ++ * ioread*()s won't stall a cpu. ++ */ ++static inline void tpm_tis_flush(void __iomem *iobase) ++{ ++ ioread8(iobase + TPM_ACCESS(0)); ++} ++#else ++#define tpm_tis_flush(iobase) do { } while (0) ++#endif ++ ++static inline void tpm_tis_iowrite8(u8 b, void __iomem *iobase, u32 addr) ++{ ++ iowrite8(b, iobase + addr); ++ tpm_tis_flush(iobase); ++} ++ ++static inline void tpm_tis_iowrite32(u32 b, void __iomem *iobase, u32 addr) ++{ ++ iowrite32(b, iobase + addr); ++ tpm_tis_flush(iobase); ++} ++ + static bool interrupts = true; + module_param(interrupts, bool, 0444); + MODULE_PARM_DESC(interrupts, "Enable interrupts"); +@@ -103,7 +128,7 @@ static int tpm_tcg_write_bytes(struct tpm_tis_data *data, u32 addr, u16 len, + struct tpm_tis_tcg_phy *phy = to_tpm_tis_tcg_phy(data); + + while (len--) +- iowrite8(*value++, phy->iobase + addr); ++ tpm_tis_iowrite8(*value++, phy->iobase, addr); + return 0; + } + +@@ -127,7 +152,7 @@ static int tpm_tcg_write32(struct tpm_tis_data *data, u32 addr, u32 value) + { + struct tpm_tis_tcg_phy *phy = to_tpm_tis_tcg_phy(data); + +- iowrite32(value, phy->iobase + addr); ++ tpm_tis_iowrite32(value, phy->iobase, addr); + return 0; + } + diff --git a/drivers/clocksource/tcb_clksrc.c b/drivers/clocksource/tcb_clksrc.c index 4da2af9694a2..5b6f57f500b8 100644 --- a/drivers/clocksource/tcb_clksrc.c @@ -4191,10 +4244,10 @@ index 02908e37c228..05c0480576e1 100644 spin_unlock_irqrestore(&dev_priv->uncore.lock, irqflags); diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c -index 5dc6082639db..c32458fb3be2 100644 +index ce32303b3013..c0a53bf2e952 100644 --- a/drivers/gpu/drm/i915/intel_display.c +++ b/drivers/gpu/drm/i915/intel_display.c -@@ -12131,7 +12131,7 @@ void intel_check_page_flip(struct drm_i915_private *dev_priv, int pipe) +@@ -12138,7 +12138,7 @@ void intel_check_page_flip(struct drm_i915_private *dev_priv, int pipe) struct intel_crtc *intel_crtc = to_intel_crtc(crtc); struct intel_flip_work *work; @@ -4204,7 +4257,7 @@ index 5dc6082639db..c32458fb3be2 100644 if (crtc == NULL) return; diff --git a/drivers/gpu/drm/i915/intel_sprite.c b/drivers/gpu/drm/i915/intel_sprite.c -index dbed12c484c9..5c540b78e8b5 100644 +index 64f4e2e18594..aebf1e9eabcb 100644 --- a/drivers/gpu/drm/i915/intel_sprite.c +++ b/drivers/gpu/drm/i915/intel_sprite.c @@ -35,6 +35,7 @@ @@ -4224,7 +4277,7 @@ index dbed12c484c9..5c540b78e8b5 100644 /** * intel_pipe_update_start() - start update of a set of display registers * @crtc: the crtc of which the registers are going to be updated -@@ -95,7 +98,7 @@ void intel_pipe_update_start(struct intel_crtc *crtc) +@@ -98,7 +101,7 @@ void intel_pipe_update_start(struct intel_crtc *crtc) min = vblank_start - intel_usecs_to_scanlines(adjusted_mode, 100); max = vblank_start - 1; @@ -4233,7 +4286,7 @@ index dbed12c484c9..5c540b78e8b5 100644 if (min <= 0 || max <= 0) return; -@@ -125,11 +128,11 @@ void intel_pipe_update_start(struct intel_crtc *crtc) +@@ -128,11 +131,11 @@ void intel_pipe_update_start(struct intel_crtc *crtc) break; } @@ -4247,7 +4300,7 @@ index dbed12c484c9..5c540b78e8b5 100644 } finish_wait(wq, &wait); -@@ -181,7 +184,7 @@ void intel_pipe_update_end(struct intel_crtc *crtc, struct intel_flip_work *work +@@ -202,7 +205,7 @@ void intel_pipe_update_end(struct intel_crtc *crtc, struct intel_flip_work *work crtc->base.state->event = NULL; } @@ -4547,7 +4600,7 @@ index 4a2a9e370be7..e970d9afd179 100644 if (t2 - t1 < tx) tx = t2 - t1; } diff --git a/drivers/iommu/amd_iommu.c b/drivers/iommu/amd_iommu.c -index 11a13b5be73a..baaed0ac274b 100644 +index 0c910a863581..3408e5dd1b93 100644 --- a/drivers/iommu/amd_iommu.c +++ b/drivers/iommu/amd_iommu.c @@ -1923,10 +1923,10 @@ static int __attach_device(struct iommu_dev_data *dev_data, @@ -4578,8 +4631,26 @@ index 11a13b5be73a..baaed0ac274b 100644 if (WARN_ON(!dev_data->domain)) return; +@@ -2283,7 +2283,7 @@ static void queue_add(struct dma_ops_domain *dma_dom, + pages = __roundup_pow_of_two(pages); + address >>= |