From 521ed14531468388aa979bc6f8ab97829f9be3f9 Mon Sep 17 00:00:00 2001 From: Ben Hutchings Date: Fri, 11 Jul 2014 16:44:49 +0000 Subject: [PATCH] Update to 3.14.12 Drop x86 ptrace patch which is included in it. Ignore or work around various ABI changes. svn path=/dists/sid/linux/; revision=21525 --- debian/changelog | 80 ++++++++++++++++++- debian/config/amd64/defines | 4 + debian/config/i386/defines | 4 + ...-force-IRET-path-after-a-ptrace_stop.patch | 74 ----------------- .../blkcg-avoid-abi-change-in-3.14.12.patch | 33 ++++++++ ...-syscall-avoid-abi-change-in-3.14.11.patch | 18 +++++ debian/patches/series | 3 +- 7 files changed, 140 insertions(+), 76 deletions(-) delete mode 100644 debian/patches/bugfix/all/ptrace-x86-force-IRET-path-after-a-ptrace_stop.patch create mode 100644 debian/patches/debian/blkcg-avoid-abi-change-in-3.14.12.patch create mode 100644 debian/patches/debian/trace-syscall-avoid-abi-change-in-3.14.11.patch diff --git a/debian/changelog b/debian/changelog index 5687eb186..60f3c5eb6 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,5 +1,83 @@ -linux (3.14.10-2) UNRELEASED; urgency=medium +linux (3.14.12-1) UNRELEASED; urgency=medium + * New upstream stable update: + https://www.kernel.org/pub/linux/kernel/v3.x/ChangeLog-3.14.11 + - iscsi-target: Avoid rejecting incorrect ITT for Data-Out + - iscsi-target: Explicily clear login response PDU in exception path + (regression in 3.10) + - iscsi-target: fix iscsit_del_np deadlock on unload (regression in 3.13) + - Input: synaptics - fix resolution for manually provided min/max + (regression in 3.14) + - [mips] MSC: Prevent out-of-bounds writes to MIPS SC ioremap'd region + - UBIFS: fix an mmap and fsync race condition + - UBIFS: Remove incorrect assertion in shrink_tnc() + - IB/ipath: Translate legacy diagpkt into newer extended diagpkt + - IB/srp: Fix a sporadic crash triggered by cable pulling + - IB/umad: Fix error handling + - IB/umad: Fix use-after-free on close + - nfsd4: fix FREE_STATEID lockowner leak (regression in 3.14.6) + - nfsd: getattr for FATTR4_WORD0_FILES_AVAIL needs the statfs buffer + - NFS: Don't declare inode uptodate unless all attributes were checked + - nfs: Fix cache_validity check in nfs_write_pageuptodate() + - [powerpc] mm: Check paca psize is up to date for huge mappings + - [powerpc] perf: Ensure all EBB register state is cleared on fork() + - xfs: xfs_readsb needs to check for magic numbers (regression in 3.14) + - reiserfs: call truncate_setsize under tailpack mutex + - ipvs: Fix panic due to non-linear skb + - tracing: Fix syscall_*regfunc() vs copy_process() race + - ALSA: usb-audio: Fix races at disconnection and PCM closing + https://www.kernel.org/pub/linux/kernel/v3.x/ChangeLog-3.14.12 + - [powerpc] ibmvscsi: Abort init sequence during error recovery + - [powerpc] ibmvscsi: Add memory barriers for send / receive + - virtio-scsi: avoid cancelling uninitialized work items + - scsi_error: fix invalid setting of host byte + - virtio-scsi: fix various bad behavior on aborted requests + - xhci: Use correct SLOT ID when handling a reset device command + (regression in 3.13) + - usb: chipidea: udc: delete td from req's td list at ep_dequeue + - mtd: eLBC NAND: fix subpage write support (regression in 3.10) + - mtd: nand: omap: fix BCHx ecc.correct to return detected bit-flips in + erased-page + - [x86] drm/i915: Avoid div-by-zero when pixel_multiplier is zero + (regression in 3.13) + - [x86] drm/i915: set backlight duty cycle after backlight enable for gen4 + (regression in 3.14) + - Bluetooth: Fix SSP acceptor just-works confirmation without MITM + - Bluetooth: Fix check for connection encryption + - rbd: use reference counts for image requests + - rbd: handle parent_overlap on writes correctly + - mac80211: fix a memory leak on sta rate selection table + (regression in 3.10) + - hugetlb: fix copy_hugetlb_page_range() to handle migration/hwpoisoned + entry + - [arm64] mm: Make icache synchronisation logic huge page aware + - [arm64] Bug fix in stack alignment exception + - fs/cifs: fix regression in cifs_create_mf_symlink() (regression in 3.14) + - blkcg: fix use-after-free in __blkg_release_rcu() by making + blkcg_gq refcnt an atomic_t + - ext4: Fix buffer double free in ext4_alloc_branch() + - ext4: Fix hole punching for files with indirect blocks + - [x86] KVM: preserve the high 32-bits of the PAT register + - [x86] kvm: fix wrong address when writing Hyper-V tsc page + - nfsd: fix rare symlink decoding bug + - tracing: Remove ftrace_stop/start() from reading the trace file + - md: flush writes before starting a recovery. + - mlx4_core: Fix incorrect FLAGS1 bitmap test in mlx4_QUERY_FUNC_CAP + (regression in 3.14) + - netfilter: nf_nat: fix oops on netns removal + - brcmfmac: Fix brcmf_chip_ai_coredisable not applying reset bits to + BCMA_IOCTL (regression in 3.14) + - mmc: rtsx: add R1-no-CRC mmc command type handle (regression in 3.13) + - aio: block io_destroy() until all context requests are completed + (regression in 3.11) + - audit: remove superfluous new- prefix in AUDIT_LOGIN messages + (regression in 3.14) + - mm/numa: Remove BUG_ON() in __handle_mm_fault() (regression in 3.13) + - slab: fix oops when reading /proc/slab_allocators + - sym53c8xx_2: Set DID_REQUEUE return code when aborting squeue + - mm: fix crashes from mbind() merging vmas + + [ Ben Hutchings ] * [rt] Update to 3.14.10-rt7: - random: Do not add randomness from threaded interrupts - rtmutex: Resolve conflicts with changes in 3.14.10 diff --git a/debian/config/amd64/defines b/debian/config/amd64/defines index 01c752096..ffb24dfdd 100644 --- a/debian/config/amd64/defines +++ b/debian/config/amd64/defines @@ -1,3 +1,7 @@ +[abi] +ignore-changes: + module:arch/x86/kvm/* + [base] featuresets: none diff --git a/debian/config/i386/defines b/debian/config/i386/defines index 1c14fd869..a0ea566e7 100644 --- a/debian/config/i386/defines +++ b/debian/config/i386/defines @@ -1,3 +1,7 @@ +[abi] +ignore-changes: + module:arch/x86/kvm/* + [base] featuresets: none diff --git a/debian/patches/bugfix/all/ptrace-x86-force-IRET-path-after-a-ptrace_stop.patch b/debian/patches/bugfix/all/ptrace-x86-force-IRET-path-after-a-ptrace_stop.patch deleted file mode 100644 index 323f4b592..000000000 --- a/debian/patches/bugfix/all/ptrace-x86-force-IRET-path-after-a-ptrace_stop.patch +++ /dev/null @@ -1,74 +0,0 @@ -From: Tejun Heo -Date: Thu, 3 Jul 2014 15:43:15 -0400 -Subject: ptrace,x86: force IRET path after a ptrace_stop() -Origin: https://git.kernel.org/linus/b9cd18de4db3c9ffa7e17b0dc0ca99ed5aa4d43a - -The 'sysret' fastpath does not correctly restore even all regular -registers, much less any segment registers or reflags values. That is -very much part of why it's faster than 'iret'. - -Normally that isn't a problem, because the normal ptrace() interface -catches the process using the signal handler infrastructure, which -always returns with an iret. - -However, some paths can get caught using ptrace_event() instead of the -signal path, and for those we need to make sure that we aren't going to -return to user space using 'sysret'. Otherwise the modifications that -may have been done to the register set by the tracer wouldn't -necessarily take effect. - -Fix it by forcing IRET path by setting TIF_NOTIFY_RESUME from -arch_ptrace_stop_needed() which is invoked from ptrace_stop(). - -Signed-off-by: Tejun Heo -Reported-by: Andy Lutomirski -Acked-by: Oleg Nesterov -Suggested-by: Linus Torvalds -Cc: stable@vger.kernel.org -Signed-off-by: Linus Torvalds ---- - arch/x86/include/asm/ptrace.h | 16 ++++++++++++++++ - include/linux/ptrace.h | 3 +++ - 2 files changed, 19 insertions(+) - -diff --git a/arch/x86/include/asm/ptrace.h b/arch/x86/include/asm/ptrace.h -index 14fd6fd..6205f0c 100644 ---- a/arch/x86/include/asm/ptrace.h -+++ b/arch/x86/include/asm/ptrace.h -@@ -231,6 +231,22 @@ static inline unsigned long regs_get_kernel_stack_nth(struct pt_regs *regs, - - #define ARCH_HAS_USER_SINGLE_STEP_INFO - -+/* -+ * When hitting ptrace_stop(), we cannot return using SYSRET because -+ * that does not restore the full CPU state, only a minimal set. The -+ * ptracer can change arbitrary register values, which is usually okay -+ * because the usual ptrace stops run off the signal delivery path which -+ * forces IRET; however, ptrace_event() stops happen in arbitrary places -+ * in the kernel and don't force IRET path. -+ * -+ * So force IRET path after a ptrace stop. -+ */ -+#define arch_ptrace_stop_needed(code, info) \ -+({ \ -+ set_thread_flag(TIF_NOTIFY_RESUME); \ -+ false; \ -+}) -+ - struct user_desc; - extern int do_get_thread_area(struct task_struct *p, int idx, - struct user_desc __user *info); -diff --git a/include/linux/ptrace.h b/include/linux/ptrace.h -index 077904c..cc79eff 100644 ---- a/include/linux/ptrace.h -+++ b/include/linux/ptrace.h -@@ -334,6 +334,9 @@ static inline void user_single_step_siginfo(struct task_struct *tsk, - * calling arch_ptrace_stop() when it would be superfluous. For example, - * if the thread has not been back to user mode since the last stop, the - * thread state might indicate that nothing needs to be done. -+ * -+ * This is guaranteed to be invoked once before a task stops for ptrace and -+ * may include arch-specific operations necessary prior to a ptrace stop. - */ - #define arch_ptrace_stop_needed(code, info) (0) - #endif diff --git a/debian/patches/debian/blkcg-avoid-abi-change-in-3.14.12.patch b/debian/patches/debian/blkcg-avoid-abi-change-in-3.14.12.patch new file mode 100644 index 000000000..050c77fbc --- /dev/null +++ b/debian/patches/debian/blkcg-avoid-abi-change-in-3.14.12.patch @@ -0,0 +1,33 @@ +From: Ben Hutchings +Date: Fri, 11 Jul 2014 17:41:42 +0100 +Subject: blkcg: Avoid ABI change in 3.14.12 + +The type of blkcg_gq::refcnt was changed from int to atomic_t, +and reference counting now requires atomic operations. None +of the in-tree users are modular and this structure isn't exposed +OOT, so we can hide this change. + +--- a/block/blk-cgroup.h ++++ b/block/blk-cgroup.h +@@ -18,7 +18,9 @@ + #include + #include + #include ++#ifndef __GENKSYMS__ + #include ++#endif + + /* Max limits for throttle policy */ + #define THROTL_IOPS_MAX UINT_MAX +@@ -105,7 +107,11 @@ struct blkcg_gq { + struct request_list rl; + + /* reference count */ ++#ifndef __GENKSYMS__ + atomic_t refcnt; ++#else ++ int refcnt; ++#endif + + /* is this blkg online? protected by both blkcg and q locks */ + bool online; diff --git a/debian/patches/debian/trace-syscall-avoid-abi-change-in-3.14.11.patch b/debian/patches/debian/trace-syscall-avoid-abi-change-in-3.14.11.patch new file mode 100644 index 000000000..cf156dd9e --- /dev/null +++ b/debian/patches/debian/trace-syscall-avoid-abi-change-in-3.14.11.patch @@ -0,0 +1,18 @@ +From: Ben Hutchings +Date: Fri, 11 Jul 2014 09:07:00 +0100 +Subject: trace/syscall: Avoid ABI change in 3.14.11 + +Hide the added #include from genksyms. + +--- a/include/trace/syscall.h ++++ b/include/trace/syscall.h +@@ -4,7 +4,9 @@ + #include + #include + #include ++#ifndef __GENKSYMS__ + #include ++#endif + + #include + diff --git a/debian/patches/series b/debian/patches/series index dd621771e..04dfec425 100644 --- a/debian/patches/series +++ b/debian/patches/series @@ -91,7 +91,8 @@ debian/drivers-base-platform-avoid-abi-change-in-3.14.6.patch debian/dma-avoid-abi-change-in-3.14.6.patch debian/vfs-avoid-abi-change-for-cve-2014-4014.patch debian/alsa-avoid-abi-change-for-cve-2014-4652-fix.patch -bugfix/all/ptrace-x86-force-IRET-path-after-a-ptrace_stop.patch bugfix/all/shmem-fix-faulting-into-a-hole-while-it-s-punched.patch debian/irq-avoid-abi-change-in-3.14.10.patch debian/ptrace-avoid-abi-change-in-3.14.10.patch +debian/trace-syscall-avoid-abi-change-in-3.14.11.patch +debian/blkcg-avoid-abi-change-in-3.14.12.patch