Linux 3.14.40
Greg KH
maintainerI'm announcing the release of the 3.14.40 kernel.
All users of the 3.14 kernel series must upgrade.
The updated 3.14.y git tree can be found at:
git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git linux-3.14.y
and can be browsed at the normal kernel.org git web browser:
http://git.kernel.org/?p=linux/kernel/git/stable/linux-stable.git;a=summary
thanks,
greg k-h
------------
Makefile | 2 arch/alpha/mm/fault.c | 2 arch/arc/mm/fault.c | 2 arch/arm/include/asm/pgtable-3level-hwdef.h | 3 arch/arm/include/asm/pgtable-3level.h | 49 +++++++----- arch/arm/include/asm/pgtable.h | 14 ++- arch/arm/mm/proc-v7-3level.S | 9 +- arch/avr32/mm/fault.c | 2 arch/cris/mm/fault.c | 2 arch/frv/mm/fault.c | 2 arch/ia64/mm/fault.c | 2 arch/m32r/mm/fault.c | 2 arch/m68k/mm/fault.c | 2 arch/metag/mm/fault.c | 2 arch/microblaze/mm/fault.c | 2 arch/mips/mm/fault.c | 2 arch/mn10300/mm/fault.c | 2 arch/openrisc/mm/fault.c | 2 arch/parisc/mm/fault.c | 2 arch/powerpc/mm/fault.c | 2 arch/powerpc/platforms/cell/spu_fault.c | 2 arch/powerpc/platforms/cell/spufs/inode.c | 2 arch/s390/mm/fault.c | 6 + arch/score/mm/fault.c | 2 arch/sh/mm/fault.c | 2 arch/sparc/mm/fault_32.c | 2 arch/sparc/mm/fault_64.c | 2 arch/tile/mm/fault.c | 2 arch/um/kernel/trap.c | 2 arch/x86/kvm/emulate.c | 27 ++---- arch/x86/mm/fault.c | 10 -- arch/xtensa/mm/fault.c | 2 drivers/bluetooth/ath3k.c | 94 ++++++++++++++---------- drivers/bluetooth/btusb.c | 74 ++++++++++++------ drivers/edac/sb_edac.c | 8 +- drivers/net/bonding/bond_3ad.c | 2 drivers/net/bonding/bond_alb.c | 2 drivers/net/bonding/bond_main.c | 10 +- drivers/net/ethernet/broadcom/bnx2.c | 6 - drivers/net/ethernet/broadcom/tg3.c | 14 +-- drivers/net/ethernet/emulex/benet/be_main.c | 2 drivers/net/ethernet/freescale/gianfar.c | 4 - drivers/net/ethernet/intel/ixgb/ixgb_main.c | 6 - drivers/net/ethernet/mellanox/mlx4/en_netdev.c | 15 ++- drivers/net/ethernet/mellanox/mlx4/en_tx.c | 2 drivers/net/ethernet/realtek/8139cp.c | 2 drivers/net/ethernet/realtek/8139too.c | 4 - drivers/net/ethernet/realtek/r8169.c | 6 - drivers/staging/lustre/lustre/llite/dcache.c | 2 drivers/staging/lustre/lustre/llite/llite_lib.c | 2 drivers/staging/lustre/lustre/llite/namei.c | 8 +- drivers/staging/lustre/lustre/llite/vvp_io.c | 2 fs/affs/amigaffs.c | 2 fs/autofs4/expire.c | 12 +-- fs/autofs4/root.c | 2 fs/ceph/dir.c | 8 +- fs/ceph/inode.c | 2 fs/cifs/inode.c | 2 fs/coda/cache.c | 2 fs/dcache.c | 58 +++++++------- fs/debugfs/inode.c | 2 fs/exportfs/expfs.c | 2 fs/libfs.c | 12 +-- fs/ncpfs/dir.c | 2 fs/ncpfs/ncplib_kernel.h | 4 - fs/nfs/getroot.c | 2 fs/notify/fsnotify.c | 4 - fs/ocfs2/dcache.c | 2 fs/proc/task_mmu.c | 67 +++++++++++------ include/linux/dcache.h | 8 +- include/linux/mm.h | 6 + include/linux/netdevice.h | 6 + include/linux/sched.h | 2 include/net/ip.h | 16 ---- include/net/ip6_route.h | 3 include/net/sock.h | 2 kernel/cgroup.c | 2 kernel/trace/trace.c | 4 - kernel/trace/trace_events.c | 2 mm/ksm.c | 2 mm/memory-failure.c | 2 mm/memory.c | 7 + net/core/dev.c | 4 - net/core/sock.c | 19 ++++ net/ipv4/tcp_input.c | 7 + net/ipv4/tcp_ipv4.c | 2 net/ipv4/tcp_output.c | 2 net/ipv6/ip6_output.c | 3 net/ipv6/ndisc.c | 9 ++ net/ipv6/tcp_ipv6.c | 2 net/netfilter/nf_conntrack_proto_generic.c | 26 ++++++ security/selinux/selinuxfs.c | 6 - 92 files changed, 466 insertions(+), 294 deletions(-)
Al Viro (1):
move d_rcu from overlapping d_child to overlapping d_alias
Anantha Krishnan (2):
Bluetooth: Add support for Acer [13D3:3432]
Bluetooth: Add support for Acer [0489:e078]Andy Shevchenko (2):
Bluetooth: sort the list of IDs in the source code
Bluetooth: append new supported device to the list [0b05:17d0]
D.S. Ljungmark (1):
ipv6: Don't reduce hop limit for an interface
Dmitry Tunin (1):
Bluetooth: ath3k: Add support of MCI 13d3:3408 bt device
Eric Dumazet (1):
tcp: tcp_make_synack() should clear skb->tstamp
Eric W. Biederman (10):
8139cp: Call dev_kfree_skby_any instead of kfree_skb. 8139too: Call dev_kfree_skby_any instead of dev_kfree_skb.
r8169: Call dev_kfree_skby_any instead of dev_kfree_skb.
bonding: Call dev_kfree_skby_any instead of kfree_skb.
bnx2: Call dev_kfree_skby_any instead of dev_kfree_skb.
tg3: Call dev_kfree_skby_any instead of dev_kfree_skb.
ixgb: Call dev_kfree_skby_any instead of dev_kfree_skb.
mlx4: Call dev_kfree_skby_any instead of dev_kfree_skb.
benet: Call dev_kfree_skby_any instead of kfree_skb.
gianfar: Carefully free skbs in functions called by netpoll.
Florian Westphal (1):
netfilter: conntrack: disable generic tracking for known protocols
Greg Kroah-Hartman (1):
Linux 3.14.40
Guenter Roeck (1):
arc: mm: Fix build failure
Ido Shamay (1):
net/mlx4_en: Call register_netdevice in the proper location
Janne Heikkinen (1):
Bluetooth: Add USB device 04ca:3010 as Atheros AR3012
Jurgen Kramer (1):
Bluetooth: btusb: Add IMC Networks (Broadcom based)
Konstantin Khlebnikov (1):
proc/pagemap: walk page tables under pte lock
Linus Torvalds (3):
vm: add VM_FAULT_SIGSEGV handling support
vm: make stack guard page errors return VM_FAULT_SIGSEGV rather than SIGBUS
x86: mm: move mmap_sem unlock from mm_fault_error() to caller
Marcel Holtmann (3):
Bluetooth: Add support for Intel bootloader devices
Bluetooth: Ignore isochronous endpoints for Intel USB bootloader
Bluetooth: Add support for Broadcom device of Asus Z97-DELUXE motherboard
Michal Kubeček (1):
tcp: prevent fetching dst twice in early demux code
Nadav Amit (1):
KVM: x86: SYSENTER emulation is broken
Naoya Horiguchi (1):
mm: hwpoison: drop lru_add_drain_all() in __soft_offline_page()
Neal Cardwell (1):
tcp: fix FRTO undo on cumulative ACK of SACKed range
Oliver Neukum (2):
Bluetooth: Enable Atheros 0cf3:311e for firmware upload
Bluetooth: Add firmware update for Atheros 0cf3:311f
Peter Feiner (1):
mm: softdirty: unmapped addresses between VMAs are clean
Richard Guy Briggs (1):
sched: declare pid_alive as inline
Seth Jennings (1):
sb_edac: avoid INTERNAL ERROR message in EDAC with unspecified channel
Steven Capper (2):
ARM: 8108/1: mm: Introduce {pte,pmd}_isset and {pte,pmd}_isclear
ARM: 8109/1: mm: Modify pte_write and pmd_write logic for LPAE
Vincent Zwanenburg (1):
Add a new PID/VID 0227/0930 for AR3012.
[email protected] (1):
ipv6: protect skb->sk accesses from recursive dereference inside the stack
Greg KH
maintainerMakefile +1 -1
@@ -1,6 +1,6 @@ VERSION = 3 PATCHLEVEL = 14 -SUBLEVEL = 39 +SUBLEVEL = 40 EXTRAVERSION = NAME = Remembering Coco
arch/alpha/mm/fault.c +2 -0
@@ -156,6 +156,8 @@ retry:if (unlikely (fault &VM_FAULT_ERROR )) {if (fault &VM_FAULT_OOM ) goto out_of_memory; +else if (fault &VM_FAULT_SIGSEGV ) + goto bad_area;else if (fault &VM_FAULT_SIGBUS ) goto do_sigbus;BUG ();
arch/arc/mm/fault.c +2 -0
@@ -162,6 +162,8 @@ good_area:/* TBD: switch to pagefault_out_of_memory() */ if (fault &VM_FAULT_OOM ) goto out_of_memory; +else if (fault &VM_FAULT_SIGSEGV ) + goto bad_area;else if (fault &VM_FAULT_SIGBUS ) goto do_sigbus;
arch/arm/include/asm/pgtable-3level-hwdef.h +2 -1
@@ -43,7 +43,7 @@#define PMD_SECT_BUFFERABLE (_AT(pmdval_t, 1) << 2)#define PMD_SECT_CACHEABLE (_AT(pmdval_t, 1) << 3)#define PMD_SECT_USER (_AT(pmdval_t, 1) << 6)/* AP[1] */ -#define PMD_SECT_RDONLY (_AT(pmdval_t, 1) << 7)/* AP[2] */ +#define PMD_SECT_AP2 (_AT(pmdval_t, 1) << 7)/* read only */ #define PMD_SECT_S (_AT(pmdval_t, 3) << 8)#define PMD_SECT_AF (_AT(pmdval_t, 1) << 10)#define PMD_SECT_nG (_AT(pmdval_t, 1) << 11)
@@ -72,6 +72,7 @@#define PTE_TABLE_BIT (_AT(pteval_t, 1) << 1)#define PTE_BUFFERABLE (_AT(pteval_t, 1) << 2)/* AttrIndx[0] */ #define PTE_CACHEABLE (_AT(pteval_t, 1) << 3)/* AttrIndx[1] */ +#define PTE_AP2 (_AT(pteval_t, 1) << 7)/* AP[2] */ #define PTE_EXT_SHARED (_AT(pteval_t, 3) << 8)/* SH[1:0], inner shareable */ #define PTE_EXT_AF (_AT(pteval_t, 1) << 10)/* Access Flag */ #define PTE_EXT_NG (_AT(pteval_t, 1) << 11)/* nG */
arch/arm/include/asm/pgtable-3level.h +30 -19
91 lines not on this page · raw message
arch/arm/include/asm/pgtable.h +9 -5
@@ -214,12 +214,16 @@ static inline pte_t *pmd_page_vaddr(pmd_t pmd)#define pte_clear (mm,addr,ptep) set_pte_ext(ptep, __pte(0), 0) +#define pte_isset (pte, val) ((u32)(val) == (val) ? pte_val(pte) & (val) \ + : !!(pte_val(pte) & (val))) +#define pte_isclear (pte, val) (!(pte_val(pte) & (val))) +#define pte_none (pte) (!pte_val(pte)) -#define pte_present (pte) (pte_val(pte) & L_PTE_PRESENT) -#define pte_write (pte) (!(pte_val(pte) & L_PTE_RDONLY)) -#define pte_dirty (pte) (pte_val(pte) & L_PTE_DIRTY) -#define pte_young (pte) (pte_val(pte) & L_PTE_YOUNG) -#define pte_exec (pte) (!(pte_val(pte) & L_PTE_XN)) +#define pte_present (pte) (pte_isset((pte), L_PTE_PRESENT)) +#define pte_write (pte) (pte_isclear((pte), L_PTE_RDONLY)) +#define pte_dirty (pte) (pte_isset((pte), L_PTE_DIRTY)) +#define pte_young (pte) (pte_isset((pte), L_PTE_YOUNG)) +#define pte_exec (pte) (pte_isclear((pte), L_PTE_XN))#define pte_special (pte) (0)#define pte_present_user (pte) (pte_present(pte) && (pte_val(pte) & L_PTE_USER))
arch/arm/mm/proc-v7-3level.S +7 -2
@@ -86,8 +86,13 @@ ENTRY(cpu_v7_set_pte_ext) tst rh, #1 << (57 - 32) @ L_PTE_NONE bicne rl, #L_PTE_VALID bne 1f - tst rh, #1 << (55 - 32) @ L_PTE_DIRTY - orreq rl, #L_PTE_RDONLY + + eor ip, rh, #1 << (55 - 32) @ toggle L_PTE_DIRTY in temp reg to + @ test for !L_PTE_DIRTY || L_PTE_RDONLY + tst ip, #1 << (55 - 32) | 1 << (58 - 32) + orrne rl, #PTE_AP2 + biceq rl, #PTE_AP2 + 1: strd r2, r3, [r0] ALT_SMP(W(nop)) ALT_UP (mcr p15, 0, r0, c7, c10, 1) @ flush_pte
arch/avr32/mm/fault.c +2 -0
@@ -142,6 +142,8 @@ good_area:if (unlikely (fault &VM_FAULT_ERROR )) {if (fault &VM_FAULT_OOM ) goto out_of_memory; +else if (fault &VM_FAULT_SIGSEGV ) + goto bad_area;else if (fault &VM_FAULT_SIGBUS ) goto do_sigbus;BUG ();
arch/cris/mm/fault.c +2 -0
@@ -176,6 +176,8 @@ retry:if (unlikely (fault &VM_FAULT_ERROR )) {if (fault &VM_FAULT_OOM ) goto out_of_memory; +else if (fault &VM_FAULT_SIGSEGV ) + goto bad_area;else if (fault &VM_FAULT_SIGBUS ) goto do_sigbus;BUG ();
arch/frv/mm/fault.c +2 -0
@@ -168,6 +168,8 @@ asmlinkage void do_page_fault(int datammu, unsigned long esr0, unsigned long earif (unlikely (fault &VM_FAULT_ERROR )) {if (fault &VM_FAULT_OOM ) goto out_of_memory; +else if (fault &VM_FAULT_SIGSEGV ) + goto bad_area;else if (fault &VM_FAULT_SIGBUS ) goto do_sigbus;BUG ();
arch/ia64/mm/fault.c +2 -0
@@ -172,6 +172,8 @@ retry:*/ if (fault &VM_FAULT_OOM ) { goto out_of_memory; + }else if (fault &VM_FAULT_SIGSEGV ) { + goto bad_area; }else if (fault &VM_FAULT_SIGBUS ) { signal =SIGBUS ; goto bad_area;
arch/m32r/mm/fault.c +2 -0
@@ -200,6 +200,8 @@ good_area:if (unlikely (fault &VM_FAULT_ERROR )) {if (fault &VM_FAULT_OOM ) goto out_of_memory; +else if (fault &VM_FAULT_SIGSEGV ) + goto bad_area;else if (fault &VM_FAULT_SIGBUS ) goto do_sigbus;BUG ();
arch/m68k/mm/fault.c +2 -0
@@ -145,6 +145,8 @@ good_area:if (unlikely (fault &VM_FAULT_ERROR )) {if (fault &VM_FAULT_OOM ) goto out_of_memory; +else if (fault &VM_FAULT_SIGSEGV ) + goto map_err;else if (fault &VM_FAULT_SIGBUS ) goto bus_err;BUG ();
arch/metag/mm/fault.c +2 -0
@@ -141,6 +141,8 @@ good_area:if (unlikely (fault &VM_FAULT_ERROR )) {if (fault &VM_FAULT_OOM ) goto out_of_memory; +else if (fault &VM_FAULT_SIGSEGV ) + goto bad_area;else if (fault &VM_FAULT_SIGBUS ) goto do_sigbus;BUG ();
arch/microblaze/mm/fault.c +2 -0
@@ -224,6 +224,8 @@ good_area:if (unlikely (fault &VM_FAULT_ERROR )) {if (fault &VM_FAULT_OOM ) goto out_of_memory; +else if (fault &VM_FAULT_SIGSEGV ) + goto bad_area;else if (fault &VM_FAULT_SIGBUS ) goto do_sigbus;BUG ();
arch/mips/mm/fault.c +2 -0
@@ -158,6 +158,8 @@ good_area:if (unlikely (fault &VM_FAULT_ERROR )) {if (fault &VM_FAULT_OOM ) goto out_of_memory; +else if (fault &VM_FAULT_SIGSEGV ) + goto bad_area;else if (fault &VM_FAULT_SIGBUS ) goto do_sigbus;BUG ();
arch/mn10300/mm/fault.c +2 -0
@@ -262,6 +262,8 @@ good_area:if (unlikely (fault &VM_FAULT_ERROR )) {if (fault &VM_FAULT_OOM ) goto out_of_memory; +else if (fault &VM_FAULT_SIGSEGV ) + goto bad_area;else if (fault &VM_FAULT_SIGBUS ) goto do_sigbus;BUG ();
arch/openrisc/mm/fault.c +2 -0
@@ -171,6 +171,8 @@ good_area:if (unlikely (fault &VM_FAULT_ERROR )) {if (fault &VM_FAULT_OOM ) goto out_of_memory; +else if (fault &VM_FAULT_SIGSEGV ) + goto bad_area;else if (fault &VM_FAULT_SIGBUS ) goto do_sigbus;BUG ();
arch/parisc/mm/fault.c +2 -0
@@ -256,6 +256,8 @@ good_area:*/ if (fault &VM_FAULT_OOM ) goto out_of_memory; +else if (fault &VM_FAULT_SIGSEGV ) + goto bad_area;else if (fault &VM_FAULT_SIGBUS ) goto bad_area;BUG ();
arch/powerpc/mm/fault.c +2 -0
@@ -432,6 +432,8 @@ good_area:*/ fault =handle_mm_fault (mm, vma, address, flags);if (unlikely (fault & (VM_FAULT_RETRY |VM_FAULT_ERROR ))) { +if (fault &VM_FAULT_SIGSEGV ) + goto bad_area; rc =mm_fault_error (regs, address, fault);if (rc >=MM_FAULT_RETURN ) goto bail;
arch/powerpc/platforms/cell/spu_fault.c +1 -1
@@ -75,7 +75,7 @@ int spu_handle_mm_fault(struct mm_struct *mm, unsigned long ea,if (*flt &VM_FAULT_OOM ) { ret = -ENOMEM ; goto out_unlock; - }else if (*flt &VM_FAULT_SIGBUS ) { + }else if (*flt & (VM_FAULT_SIGBUS |VM_FAULT_SIGSEGV )) { ret = -EFAULT ; goto out_unlock; }
arch/powerpc/platforms/cell/spufs/inode.c +1 -1
@@ -164,7 +164,7 @@ static void spufs_prune_dir(struct dentry *dir)struct dentry *dentry, *tmp;mutex_lock (&dir->d_inode->i_mutex); -list_for_each_entry_safe (dentry, tmp, &dir->d_subdirs, d_u.d_child) { +list_for_each_entry_safe (dentry, tmp, &dir->d_subdirs, d_child) {spin_lock (&dentry->d_lock);if (!(d_unhashed (dentry)) && dentry->d_inode) {dget_dlock (dentry);
arch/s390/mm/fault.c +6 -0
@@ -239,6 +239,12 @@ static noinline void do_fault_error(struct pt_regs *regs, int fault)do_no_context (regs); elsepagefault_out_of_memory (); + }else if (fault &VM_FAULT_SIGSEGV ) { +/* Kernel mode? Handle exceptions or die */ +if (!user_mode (regs)) +do_no_context (regs); +else +do_sigsegv (regs,SEGV_MAPERR ); }else if (fault &VM_FAULT_SIGBUS ) {/* Kernel mode? Handle exceptions or die */ if (!user_mode (regs))
arch/score/mm/fault.c +2 -0
@@ -114,6 +114,8 @@ good_area:if (unlikely (fault &VM_FAULT_ERROR )) {if (fault &VM_FAULT_OOM ) goto out_of_memory; +else if (fault &VM_FAULT_SIGSEGV ) + goto bad_area;else if (fault &VM_FAULT_SIGBUS ) goto do_sigbus;BUG ();
arch/sh/mm/fault.c +2 -0
@@ -353,6 +353,8 @@ mm_fault_error(struct pt_regs *regs, unsigned long error_code, }else {if (fault &VM_FAULT_SIGBUS )do_sigbus (regs, error_code, address); +else if (fault &VM_FAULT_SIGSEGV ) +bad_area (regs, error_code, address);else BUG (); }
arch/sparc/mm/fault_32.c +2 -0
@@ -252,6 +252,8 @@ good_area:if (unlikely (fault &VM_FAULT_ERROR )) {if (fault &VM_FAULT_OOM ) goto out_of_memory; +else if (fault &VM_FAULT_SIGSEGV ) + goto bad_area;else if (fault &VM_FAULT_SIGBUS ) goto do_sigbus;BUG ();
arch/sparc/mm/fault_64.c +2 -0
@@ -448,6 +448,8 @@ good_area:if (unlikely (fault &VM_FAULT_ERROR )) {if (fault &VM_FAULT_OOM ) goto out_of_memory; +else if (fault &VM_FAULT_SIGSEGV ) + goto bad_area;else if (fault &VM_FAULT_SIGBUS ) goto do_sigbus;BUG ();
arch/tile/mm/fault.c +2 -0
@@ -444,6 +444,8 @@ good_area:if (unlikely (fault &VM_FAULT_ERROR )) {if (fault &VM_FAULT_OOM ) goto out_of_memory; +else if (fault &VM_FAULT_SIGSEGV ) + goto bad_area;else if (fault &VM_FAULT_SIGBUS ) goto do_sigbus;BUG ();
arch/um/kernel/trap.c +2 -0
@@ -80,6 +80,8 @@ good_area:if (unlikely (fault &VM_FAULT_ERROR )) {if (fault &VM_FAULT_OOM ) { goto out_of_memory; + }else if (fault &VM_FAULT_SIGSEGV ) { + goto out; }else if (fault &VM_FAULT_SIGBUS ) { err = -EACCES ; goto out;
arch/x86/kvm/emulate.c +8 -19
@@ -2258,7 +2258,7 @@ static int em_sysenter(struct x86_emulate_ctxt *ctxt)* Not recognized on AMD in compat mode (but is recognized in legacy * mode). */ -if ((ctxt->mode ==X86EMUL_MODE_PROT32 ) && (efer &EFER_LMA ) +if ((ctxt->mode !=X86EMUL_MODE_PROT64 ) && (efer &EFER_LMA ) && !vendor_intel (ctxt))return emulate_ud (ctxt);
@@ -2271,25 +2271,13 @@ static int em_sysenter(struct x86_emulate_ctxt *ctxt)setup_syscalls_segments (ctxt, &cs, &ss); ops->get_msr (ctxt,MSR_IA32_SYSENTER_CS , &msr_data); -switch (ctxt->mode) { -case X86EMUL_MODE_PROT32 : -if ((msr_data &0xfffc ) ==0x0 ) -return emulate_gp (ctxt,0 ); -break ; -case X86EMUL_MODE_PROT64 : -if (msr_data ==0x0 ) -return emulate_gp (ctxt,0 ); -break ; -default : -break ; - } +if ((msr_data &0xfffc ) ==0x0 ) +return emulate_gp (ctxt,0 ); ctxt->eflags &= ~(EFLG_VM |EFLG_IF |EFLG_RF ); - cs_sel = (u16 )msr_data; - cs_sel &= ~SELECTOR_RPL_MASK ; + cs_sel = (u16 )msr_data & ~SELECTOR_RPL_MASK ; ss_sel = cs_sel +8 ; - ss_sel &= ~SELECTOR_RPL_MASK ; -if (ctxt->mode ==X86EMUL_MODE_PROT64 || (efer &EFER_LMA )) { +if (efer &EFER_LMA ) { cs.d =0 ; cs.l =1 ; }
@@ -2298,10 +2286,11 @@ static int em_sysenter(struct x86_emulate_ctxt *ctxt) ops->set_segment (ctxt, ss_sel, &ss,0 ,VCPU_SREG_SS ); ops->get_msr (ctxt,MSR_IA32_SYSENTER_EIP , &msr_data); - ctxt->_eip = msr_data; + ctxt->_eip = (efer &EFER_LMA ) ? msr_data : (u32 )msr_data; ops->get_msr (ctxt,MSR_IA32_SYSENTER_ESP , &msr_data); - *reg_write (ctxt,VCPU_REGS_RSP ) = msr_data; + *reg_write (ctxt,VCPU_REGS_RSP ) = (efer &EFER_LMA ) ? msr_data : + (u32 )msr_data;return X86EMUL_CONTINUE ; }
arch/x86/mm/fault.c +3 -7
@@ -833,11 +833,8 @@ do_sigbus(struct pt_regs *regs, unsigned long error_code, unsigned long address, unsigned int fault) {struct task_struct *tsk = current; -struct mm_struct *mm = tsk->mm;int code =BUS_ADRERR ; -up_read (&mm->mmap_sem); -/* Kernel mode? Handle exceptions or die: */ if (!(error_code &PF_USER )) {no_context (regs, error_code, address,SIGBUS ,BUS_ADRERR );
@@ -868,7 +865,6 @@ mm_fault_error(struct pt_regs *regs, unsigned long error_code, unsigned long address, unsigned int fault) { if (fatal_signal_pending(current) && !(error_code & PF_USER)) { - up_read(¤t->mm->mmap_sem); no_context(regs, error_code, address, 0, 0);return ; }
@@ -876,14 +872,11 @@ mm_fault_error(struct pt_regs *regs, unsigned long error_code,if (fault &VM_FAULT_OOM ) {/* Kernel mode? Handle exceptions or die: */ if (!(error_code &PF_USER )) { -up_read (¤t->mm->mmap_sem);no_context (regs, error_code, address,SIGSEGV ,SEGV_MAPERR );return ; } -up_read (¤t->mm->mmap_sem); -/* * We ran out of memory, call the OOM killer, and return the * userspace (which will retry the fault, or kill us if we got
@@ -894,6 +887,8 @@ mm_fault_error(struct pt_regs *regs, unsigned long error_code,if (fault & (VM_FAULT_SIGBUS |VM_FAULT_HWPOISON |VM_FAULT_HWPOISON_LARGE ))do_sigbus (regs, error_code, address, fault); +else if (fault &VM_FAULT_SIGSEGV ) +bad_area_nosemaphore (regs, error_code, address);else BUG (); }
@@ -1216,6 +1211,7 @@ good_area:return ;if (unlikely (fault &VM_FAULT_ERROR )) { +up_read (&mm->mmap_sem);mm_fault_error (regs, error_code, address, fault);return ; }
arch/xtensa/mm/fault.c +2 -0
@@ -117,6 +117,8 @@ good_area:if (unlikely (fault &VM_FAULT_ERROR )) {if (fault &VM_FAULT_OOM ) goto out_of_memory; +else if (fault &VM_FAULT_SIGSEGV ) + goto bad_area;else if (fault &VM_FAULT_SIGBUS ) goto do_sigbus;BUG ();
drivers/bluetooth/ath3k.c +55 -39
143 lines not on this page · raw message
drivers/bluetooth/btusb.c +48 -26
137 lines not on this page · raw message
drivers/edac/sb_edac.c +6 -2
@@ -285,8 +285,9 @@ static const u32 correrrthrsld[] = {* sbridge structs */ -#define NUM_CHANNELS 4 -#define MAX_DIMMS 3/* Max DIMMS per channel */ +#define NUM_CHANNELS 4 +#define MAX_DIMMS 3/* Max DIMMS per channel */ +#define CHANNEL_UNSPECIFIED 0xf/* Intel IA32 SDM 15-14 */ enum type {SANDY_BRIDGE ,
@@ -1750,6 +1751,9 @@ static void sbridge_mce_output_error(struct mem_ctl_info *mci,/* FIXME: need support for channel mask */ +if (channel ==CHANNEL_UNSPECIFIED ) + channel =-1 ; +/* Call the helper to output message */ edac_mc_handle_error(tp_event, mci, core_err_cnt, m->addr >> PAGE_SHIFT, m->addr & ~PAGE_MASK, 0,
drivers/net/bonding/bond_3ad.c +1 -1
@@ -2479,7 +2479,7 @@ out:return NETDEV_TX_OK ; err_free:/* no suitable interface, frame not sent */ -kfree_skb (skb); +dev_kfree_skb_any (skb); goto out; }
drivers/net/bonding/bond_alb.c +1 -1
@@ -1479,7 +1479,7 @@ int bond_alb_xmit(struct sk_buff *skb, struct net_device *bond_dev) }/* no suitable interface, frame not sent */ -kfree_skb (skb); +dev_kfree_skb_any (skb); out:return NETDEV_TX_OK ; }
drivers/net/bonding/bond_main.c +5 -5
@@ -3568,7 +3568,7 @@ static void bond_xmit_slave_id(struct bonding *bond, struct sk_buff *skb, int sl } }/* no slave that can tx has been found */ -kfree_skb (skb); +dev_kfree_skb_any (skb); }/**
@@ -3650,7 +3650,7 @@ static int bond_xmit_activebackup(struct sk_buff *skb, struct net_device *bond_dif (slave)bond_dev_queue_xmit (bond, skb, slave->dev);else -kfree_skb (skb); +dev_kfree_skb_any (skb);return NETDEV_TX_OK ; }
@@ -3698,7 +3698,7 @@ static int bond_xmit_broadcast(struct sk_buff *skb, struct net_device *bond_dev)if (slave &&IS_UP (slave->dev) && slave->link ==BOND_LINK_UP )bond_dev_queue_xmit (bond, skb, slave->dev);else -kfree_skb (skb); +dev_kfree_skb_any (skb);return NETDEV_TX_OK ; }
@@ -3785,7 +3785,7 @@ static netdev_tx_t __bond_start_xmit(struct sk_buff *skb, struct net_device *devpr_err ("%s: Error: Unknown bonding mode %d\n" , dev->name, bond->params.mode);WARN_ON_ONCE (1 ); -kfree_skb (skb); +dev_kfree_skb_any (skb);return NETDEV_TX_OK ; } }
@@ -3806,7 +3806,7 @@ static netdev_tx_t bond_start_xmit(struct sk_buff *skb, struct net_device *dev)if (bond_has_slaves (bond)) ret =__bond_start_xmit (skb, dev);else -kfree_skb (skb); +dev_kfree_skb_any (skb);rcu_read_unlock ();return ret;
drivers/net/ethernet/broadcom/bnx2.c +3 -3
@@ -2886,7 +2886,7 @@ bnx2_tx_int(struct bnx2 *bp, struct bnx2_napi *bnapi, int budget) sw_cons =BNX2_NEXT_TX_BD (sw_cons); tx_bytes += skb->len; -dev_kfree_skb (skb); +dev_kfree_skb_any (skb); tx_pkt++;if (tx_pkt == budget)break ;
@@ -6640,7 +6640,7 @@ bnx2_start_xmit(struct sk_buff *skb, struct net_device *dev) mapping =dma_map_single (&bp->pdev->dev, skb->data, len,PCI_DMA_TODEVICE );if (dma_mapping_error (&bp->pdev->dev, mapping)) { -dev_kfree_skb (skb); +dev_kfree_skb_any (skb);return NETDEV_TX_OK ; }
@@ -6733,7 +6733,7 @@ dma_error: PCI_DMA_TODEVICE); } -dev_kfree_skb (skb); +dev_kfree_skb_any (skb);return NETDEV_TX_OK ; }
drivers/net/ethernet/broadcom/tg3.c +7 -7
@@ -6593,7 +6593,7 @@ static void tg3_tx(struct tg3_napi *tnapi) pkts_compl++; bytes_compl += skb->len; -dev_kfree_skb (skb); +dev_kfree_skb_any (skb);if (unlikely (tx_bug)) {tg3_tx_recover (tp);
@@ -6925,7 +6925,7 @@ static int tg3_rx(struct tg3_napi *tnapi, int budget)if (len > (tp->dev->mtu +ETH_HLEN ) && skb->protocol !=htons (ETH_P_8021Q ) && skb->protocol !=htons (ETH_P_8021AD )) { -dev_kfree_skb (skb); +dev_kfree_skb_any (skb); goto drop_it_no_recycle; }
@@ -7808,7 +7808,7 @@ static int tigon3_dma_hwbug_workaround(struct tg3_napi *tnapi, PCI_DMA_TODEVICE);/* Make sure the mapping succeeded */ if (pci_dma_mapping_error (tp->pdev, new_addr)) { -dev_kfree_skb (new_skb); +dev_kfree_skb_any (new_skb); ret =-1 ; }else {u32 save_entry = *entry;
@@ -7823,13 +7823,13 @@ static int tigon3_dma_hwbug_workaround(struct tg3_napi *tnapi, new_skb->len, base_flags, mss, vlan)) {tg3_tx_skb_unmap (tnapi, save_entry,-1 ); -dev_kfree_skb (new_skb); +dev_kfree_skb_any (new_skb); ret =-1 ; } } } -dev_kfree_skb (skb); +dev_kfree_skb_any (skb); *pskb = new_skb;return ret; }
@@ -7872,7 +7872,7 @@ static int tg3_tso_bug(struct tg3 *tp, struct sk_buff *skb) }while (segs); tg3_tso_bug_end: -dev_kfree_skb (skb); +dev_kfree_skb_any (skb);return NETDEV_TX_OK ; }
@@ -8110,7 +8110,7 @@ dma_error:tg3_tx_skb_unmap (tnapi, tnapi->tx_prod, --i); tnapi->tx_buffers[tnapi->tx_prod].skb =NULL ; drop: -dev_kfree_skb (skb); +dev_kfree_skb_any (skb); drop_nofree: tp->tx_dropped++;return NETDEV_TX_OK ;
drivers/net/ethernet/emulex/benet/be_main.c +1 -1
@@ -1883,7 +1883,7 @@ static u16 be_tx_compl_process(struct be_adapter *adapter,queue_tail_inc (txq); }while (cur_index != last_index); -kfree_skb (sent_skb); +dev_kfree_skb_any (sent_skb);return num_wrbs; }
drivers/net/ethernet/freescale/gianfar.c +2 -2
@@ -2152,13 +2152,13 @@ static int gfar_start_xmit(struct sk_buff *skb, struct net_device *dev) skb_new =skb_realloc_headroom (skb, fcb_len);if (!skb_new) { dev->stats.tx_errors++; -kfree_skb (skb); +dev_kfree_skb_any (skb);return NETDEV_TX_OK ; }if (skb->sk)skb_set_owner_w (skb_new, skb->sk); -consume_skb (skb); +dev_consume_skb_any (skb); skb = skb_new; }
drivers/net/ethernet/intel/ixgb/ixgb_main.c +3 -3
@@ -1521,12 +1521,12 @@ ixgb_xmit_frame(struct sk_buff *skb, struct net_device *netdev)int tso;if (test_bit (__IXGB_DOWN, &adapter->flags)) { -dev_kfree_skb (skb); +dev_kfree_skb_any (skb);return NETDEV_TX_OK ; }if (skb->len <=0 ) { -dev_kfree_skb (skb); +dev_kfree_skb_any (skb);return NETDEV_TX_OK ; }
@@ -1543,7 +1543,7 @@ ixgb_xmit_frame(struct sk_buff *skb, struct net_device *netdev) tso =ixgb_tso (adapter, skb);if (tso <0 ) { -dev_kfree_skb (skb); +dev_kfree_skb_any (skb);return NETDEV_TX_OK ; }
drivers/net/ethernet/mellanox/mlx4/en_netdev.c +8 -7
@@ -2497,13 +2497,6 @@ int mlx4_en_init_netdev(struct mlx4_en_dev *mdev, int port,netif_carrier_off (dev);mlx4_en_set_default_moderation (priv); - err =register_netdev (dev); -if (err) { -en_err (priv,"Netdev registration failed for port %d\n" , port); - goto out; - } - priv->registered =1 ; -en_warn (priv,"Using %d TX rings\n" , prof->tx_ring_num);en_warn (priv,"Using %d RX rings\n" , prof->rx_ring_num);
@@ -2543,6 +2536,14 @@ int mlx4_en_init_netdev(struct mlx4_en_dev *mdev, int port,queue_delayed_work (mdev->workqueue, &priv->service_task,SERVICE_TASK_DELAY ); + err =register_netdev (dev); +if (err) { +en_err (priv,"Netdev registration failed for port %d\n" , port); + goto out; + } + + priv->registered =1 ; +return 0 ; out:
drivers/net/ethernet/mellanox/mlx4/en_tx.c +1 -1
@@ -325,7 +325,7 @@ static u32 mlx4_en_free_tx_desc(struct mlx4_en_priv *priv, } } } -dev_kfree_skb (skb); +dev_kfree_skb_any (skb);return tx_info->nr_txbb; }
drivers/net/ethernet/realtek/8139cp.c +1 -1
@@ -899,7 +899,7 @@ out_unlock:return NETDEV_TX_OK ; out_dma_error: -kfree_skb (skb); +dev_kfree_skb_any (skb); cp->dev->stats.tx_dropped++; goto out_unlock; }
drivers/net/ethernet/realtek/8139too.c +2 -2
@@ -1717,9 +1717,9 @@ static netdev_tx_t rtl8139_start_xmit (struct sk_buff *skb,if (len <ETH_ZLEN )memset (tp->tx_buf[entry],0 ,ETH_ZLEN );skb_copy_and_csum_dev (skb, tp->tx_buf[entry]); -dev_kfree_skb (skb); +dev_kfree_skb_any (skb); }else { -dev_kfree_skb (skb); +dev_kfree_skb_any (skb); dev->stats.tx_dropped++;return NETDEV_TX_OK ; }
drivers/net/ethernet/realtek/r8169.c +3 -3
@@ -5834,7 +5834,7 @@ static void rtl8169_tx_clear_range(struct rtl8169_private *tp, u32 start, tp->TxDescArray + entry);if (skb) { tp->dev->stats.tx_dropped++; -dev_kfree_skb (skb); +dev_kfree_skb_any (skb); tx_skb->skb =NULL ; } }
@@ -6059,7 +6059,7 @@ static netdev_tx_t rtl8169_start_xmit(struct sk_buff *skb, err_dma_1:rtl8169_unmap_tx_skb (d, tp->tx_skb + entry, txd); err_dma_0: -dev_kfree_skb (skb); +dev_kfree_skb_any (skb); err_update_stats: dev->stats.tx_dropped++;return NETDEV_TX_OK ;
@@ -6142,7 +6142,7 @@ static void rtl_tx(struct net_device *dev, struct rtl8169_private *tp) tp->tx_stats.packets++; tp->tx_stats.bytes += tx_skb->skb->len;u64_stats_update_end (&tp->tx_stats.syncp); -dev_kfree_skb (tx_skb->skb); +dev_kfree_skb_any (tx_skb->skb); tx_skb->skb =NULL ; } dirty_tx++;
drivers/staging/lustre/lustre/llite/dcache.c +1 -1
@@ -278,7 +278,7 @@ void ll_invalidate_aliases(struct inode *inode) inode->i_ino, inode->i_generation, inode);ll_lock_dcache (inode); -ll_d_hlist_for_each_entry (dentry, p, &inode->i_dentry, d_alias) { +ll_d_hlist_for_each_entry (dentry, p, &inode->i_dentry, d_u.d_alias) { CDEBUG(D_DENTRY, "dentry in drop %.*s (%p) parent %p " "inode %p flags %d\n", dentry->d_name.len, dentry->d_name.name, dentry, dentry->d_parent,
drivers/staging/lustre/lustre/llite/llite_lib.c +1 -1
@@ -678,7 +678,7 @@ void lustre_dump_dentry(struct dentry *dentry, int recur)return ;list_for_each (tmp, &dentry->d_subdirs) { - struct dentry *d = list_entry(tmp, struct dentry, d_u.d_child); + struct dentry *d = list_entry(tmp, struct dentry, d_child);lustre_dump_dentry (d, recur -1 ); } }
drivers/staging/lustre/lustre/llite/namei.c +4 -4
@@ -175,14 +175,14 @@ static void ll_invalidate_negative_children(struct inode *dir)struct ll_d_hlist_node *p;ll_lock_dcache (dir); -ll_d_hlist_for_each_entry (dentry, p, &dir->i_dentry, d_alias) { +ll_d_hlist_for_each_entry (dentry, p, &dir->i_dentry, d_u.d_alias) {spin_lock (&dentry->d_lock);if (!list_empty (&dentry->d_subdirs)) {struct dentry *child;list_for_each_entry_safe (child, tmp_subdir, &dentry->d_subdirs, - d_u.d_child) { + d_child) {if (child->d_inode ==NULL )d_lustre_invalidate (child,1 ); }
@@ -364,7 +364,7 @@ static struct dentry *ll_find_alias(struct inode *inode, struct dentry *dentry) discon_alias = invalid_alias =NULL ;ll_lock_dcache (inode); -ll_d_hlist_for_each_entry (alias, p, &inode->i_dentry, d_alias) { +ll_d_hlist_for_each_entry (alias, p, &inode->i_dentry, d_u.d_alias) {LASSERT (alias != dentry);spin_lock (&alias->d_lock);
@@ -953,7 +953,7 @@ static void ll_get_child_fid(struct inode * dir, struct qstr *name, {struct dentry *parent, *child; - parent = ll_d_hlist_entry(dir->i_dentry, struct dentry, d_alias); + parent = ll_d_hlist_entry(dir->i_dentry, struct dentry, d_u.d_alias); child =d_lookup (parent, name);if (child) {if (child->d_inode)
drivers/staging/lustre/lustre/llite/vvp_io.c +1 -1
@@ -642,7 +642,7 @@ static int vvp_io_kernel_fault(struct vvp_fault_io *cfio)return 0 ; } -if (cfio->fault.ft_flags &VM_FAULT_SIGBUS ) { +if (cfio->fault.ft_flags & (VM_FAULT_SIGBUS |VM_FAULT_SIGSEGV )) {CDEBUG (D_PAGE ,"got addr %p - SIGBUS\n" , vmf->virtual_address);return -EFAULT ; }
fs/affs/amigaffs.c +1 -1
@@ -126,7 +126,7 @@ affs_fix_dcache(struct inode *inode, u32 entry_ino) {struct dentry *dentry;spin_lock (&inode->i_lock); -hlist_for_each_entry (dentry, &inode->i_dentry, d_alias) { +hlist_for_each_entry (dentry, &inode->i_dentry, d_u.d_alias) {if (entry_ino == (u32 )(long )dentry->d_fsdata) { dentry->d_fsdata = (void *)inode->i_ino;break ;
fs/autofs4/expire.c +6 -6
@@ -91,7 +91,7 @@ static struct dentry *get_next_positive_subdir(struct dentry *prev,spin_lock (&root->d_lock);if (prev) - next = prev->d_u.d_child.next; + next = prev->d_child.next;else { prev =dget_dlock (root); next = prev->d_subdirs.next;
@@ -105,13 +105,13 @@ cont:return NULL ; } - q = list_entry(next, struct dentry, d_u.d_child); + q = list_entry(next, struct dentry, d_child);spin_lock_nested (&q->d_lock,DENTRY_D_LOCK_NESTED );/* Already gone or negative dentry (under construction) - try next */ if (!d_count (q) || !simple_positive (q)) {spin_unlock (&q->d_lock); - next = q->d_u.d_child.next; + next = q->d_child.next; goto cont; }dget_dlock (q);
@@ -161,13 +161,13 @@ again: goto relock; }spin_unlock (&p->d_lock); - next = p->d_u.d_child.next; + next = p->d_child.next; p = parent;if (next != &parent->d_subdirs)break ; } } - ret = list_entry(next, struct dentry, d_u.d_child); + ret = list_entry(next, struct dentry, d_child);spin_lock_nested (&ret->d_lock,DENTRY_D_LOCK_NESTED );/* Negative dentry - try next */
@@ -461,7 +461,7 @@ found:spin_lock (&sbi->lookup_lock);spin_lock (&expired->d_parent->d_lock);spin_lock_nested (&expired->d_lock,DENTRY_D_LOCK_NESTED ); -list_move (&expired->d_parent->d_subdirs, &expired->d_u.d_child); +list_move (&expired->d_parent->d_subdirs, &expired->d_child);spin_unlock (&expired->d_lock);spin_unlock (&expired->d_parent->d_lock);spin_unlock (&sbi->lookup_lock);
fs/autofs4/root.c +1 -1
@@ -655,7 +655,7 @@ static void autofs_clear_leaf_automount_flags(struct dentry *dentry)/* only consider parents below dentrys in the root */ if (IS_ROOT (parent->d_parent))return ; - d_child = &dentry->d_u.d_child; + d_child = &dentry->d_child;/* Set parent managed if it's becoming empty */ if (d_child->next == &parent->d_subdirs && d_child->prev == &parent->d_subdirs)
fs/ceph/dir.c +4 -4
@@ -111,7 +111,7 @@ static int fpos_cmp(loff_t l, loff_t r)/* * When possible, we try to satisfy a readdir by peeking at the * dcache. We make this work by carefully ordering dentries on -* d_u.d_child when we initially get results back from the MDS, and +* d_child when we initially get results back from the MDS, and * falling back to a "normal" sync readdir if any dentries in the dir * are dropped. *
@@ -146,11 +146,11 @@ static int __dcache_readdir(struct file *file, struct dir_context *ctx) p = parent->d_subdirs.prev;dout (" initial p %p/%p\n" , p->prev, p->next); }else { - p = last->d_u.d_child.prev; + p = last->d_child.prev; } more: - dentry = list_entry(p, struct dentry, d_u.d_child); + dentry = list_entry(p, struct dentry, d_child); di =ceph_dentry (dentry);while (1 ) { dout(" p %p/%p %s d_subdirs %p/%p\n", p->prev, p->next,
@@ -172,7 +172,7 @@ more: !dentry->d_inode ? " null" : "");spin_unlock (&dentry->d_lock); p = p->prev; - dentry = list_entry(p, struct dentry, d_u.d_child); + dentry = list_entry(p, struct dentry, d_child); di =ceph_dentry (dentry); }
fs/ceph/inode.c +1 -1
@@ -1289,7 +1289,7 @@ retry_lookup:/* reorder parent's d_subdirs */ spin_lock (&parent->d_lock);spin_lock_nested (&dn->d_lock,DENTRY_D_LOCK_NESTED ); -list_move (&dn->d_u.d_child, &parent->d_subdirs); +list_move (&dn->d_child, &parent->d_subdirs);spin_unlock (&dn->d_lock);spin_unlock (&parent->d_lock); }
fs/cifs/inode.c +1 -1
@@ -883,7 +883,7 @@ inode_has_hashed_dentries(struct inode *inode)struct dentry *dentry;spin_lock (&inode->i_lock); -hlist_for_each_entry (dentry, &inode->i_dentry, d_alias) { +hlist_for_each_entry (dentry, &inode->i_dentry, d_u.d_alias) {if (!d_unhashed (dentry) ||IS_ROOT (dentry)) {spin_unlock (&inode->i_lock);return true;
fs/coda/cache.c +1 -1
@@ -92,7 +92,7 @@ static void coda_flag_children(struct dentry *parent, int flag)struct dentry *de;spin_lock (&parent->d_lock); -list_for_each_entry (de, &parent->d_subdirs, d_u.d_child) { +list_for_each_entry (de, &parent->d_subdirs, d_child) {/* don't know what to do with negative dentries */ if (de->d_inode )coda_flag_inode (de->d_inode, flag);
fs/dcache.c +29 -29
215 lines not on this page · raw message
fs/debugfs/inode.c +1 -1
@@ -552,7 +552,7 @@ void debugfs_remove_recursive(struct dentry *dentry)* use the d_u.d_child as the rcu head and corrupt this list. */ spin_lock (&parent->d_lock); -list_for_each_entry (child, &parent->d_subdirs, d_u.d_child) { +list_for_each_entry (child, &parent->d_subdirs, d_child) {if (!debugfs_positive (child))continue ;
fs/exportfs/expfs.c +1 -1
@@ -50,7 +50,7 @@ find_acceptable_alias(struct dentry *result, inode = result->d_inode;spin_lock (&inode->i_lock); -hlist_for_each_entry (dentry, &inode->i_dentry, d_alias) { +hlist_for_each_entry (dentry, &inode->i_dentry, d_u.d_alias) {dget (dentry);spin_unlock (&inode->i_lock);if (toput)
fs/libfs.c +6 -6
@@ -113,18 +113,18 @@ loff_t dcache_dir_lseek(struct file *file, loff_t offset, int whence)spin_lock (&dentry->d_lock);/* d_lock not required for cursor */ -list_del (&cursor->d_u.d_child); +list_del (&cursor->d_child); p = dentry->d_subdirs.next;while (n && p != &dentry->d_subdirs) {struct dentry *next; - next = list_entry(p, struct dentry, d_u.d_child); + next = list_entry(p, struct dentry, d_child);spin_lock_nested (&next->d_lock,DENTRY_D_LOCK_NESTED );if (simple_positive (next)) n--;spin_unlock (&next->d_lock); p = p->next; } -list_add_tail (&cursor->d_u.d_child, p); +list_add_tail (&cursor->d_child, p);spin_unlock (&dentry->d_lock); } }
@@ -149,7 +149,7 @@ int dcache_readdir(struct file *file, struct dir_context *ctx) {struct dentry *dentry = file->f_path.dentry;struct dentry *cursor = file->private_data; -struct list_head *p, *q = &cursor->d_u.d_child; +struct list_head *p, *q = &cursor->d_child;if (!dir_emit_dots (file, ctx))return 0 ;
@@ -158,7 +158,7 @@ int dcache_readdir(struct file *file, struct dir_context *ctx)list_move (q, &dentry->d_subdirs);for (p = q->next; p != &dentry->d_subdirs; p = p->next) { - struct dentry *next = list_entry(p, struct dentry, d_u.d_child); + struct dentry *next = list_entry(p, struct dentry, d_child);spin_lock_nested (&next->d_lock,DENTRY_D_LOCK_NESTED );if (!simple_positive (next)) {spin_unlock (&next->d_lock);
@@ -286,7 +286,7 @@ int simple_empty(struct dentry *dentry)int ret =0 ;spin_lock (&dentry->d_lock); -list_for_each_entry (child, &dentry->d_subdirs, d_u.d_child) { +list_for_each_entry (child, &dentry->d_subdirs, d_child) {spin_lock_nested (&child->d_lock,DENTRY_D_LOCK_NESTED );if (simple_positive (child)) {spin_unlock (&child->d_lock);
fs/ncpfs/dir.c +1 -1
@@ -406,7 +406,7 @@ ncp_dget_fpos(struct dentry *dentry, struct dentry *parent, unsigned long fpos)spin_lock (&parent->d_lock); next = parent->d_subdirs.next;while (next != &parent->d_subdirs) { - dent = list_entry(next, struct dentry, d_u.d_child); + dent = list_entry(next, struct dentry, d_child);if ((unsigned long )dent->d_fsdata == fpos) {if (dent->d_inode)dget (dent);
fs/ncpfs/ncplib_kernel.h +2 -2
@@ -194,7 +194,7 @@ ncp_renew_dentries(struct dentry *parent)spin_lock (&parent->d_lock); next = parent->d_subdirs.next;while (next != &parent->d_subdirs) { - dentry = list_entry(next, struct dentry, d_u.d_child); + dentry = list_entry(next, struct dentry, d_child);if (dentry->d_fsdata ==NULL )ncp_age_dentry (server, dentry);
@@ -216,7 +216,7 @@ ncp_invalidate_dircache_entries(struct dentry *parent)spin_lock (&parent->d_lock); next = parent->d_subdirs.next;while (next != &parent->d_subdirs) { - dentry = list_entry(next, struct dentry, d_u.d_child); + dentry = list_entry(next, struct dentry, d_child); dentry->d_fsdata =NULL ;ncp_age_dentry (server, dentry); next = next->next;
fs/nfs/getroot.c +1 -1
@@ -58,7 +58,7 @@ static int nfs_superblock_set_dummy_root(struct super_block *sb, struct inode *i*/ spin_lock (&sb->s_root->d_inode->i_lock);spin_lock (&sb->s_root->d_lock); -hlist_del_init (&sb->s_root->d_alias); +hlist_del_init (&sb->s_root->d_u.d_alias);spin_unlock (&sb->s_root->d_lock);spin_unlock (&sb->s_root->d_inode->i_lock); }
fs/notify/fsnotify.c +2 -2
@@ -63,14 +63,14 @@ void __fsnotify_update_child_dentry_flags(struct inode *inode)spin_lock (&inode->i_lock);/* run all of the dentries associated with this inode. Since this is a * directory, there damn well better only be one item on this list */ -hlist_for_each_entry (alias, &inode->i_dentry, d_alias) { +hlist_for_each_entry (alias, &inode->i_dentry, d_u.d_alias) {struct dentry *child;/* run all of the children of the original inode and fix their * d_flags to indicate parental interest (their parent is the * original inode) */ spin_lock (&alias->d_lock); -list_for_each_entry (child, &alias->d_subdirs, d_u.d_child) { +list_for_each_entry (child, &alias->d_subdirs, d_child) {if (!child->d_inode)continue ;
fs/ocfs2/dcache.c +1 -1
@@ -173,7 +173,7 @@ struct dentry *ocfs2_find_local_alias(struct inode *inode,struct dentry *dentry;spin_lock (&inode->i_lock); -hlist_for_each_entry (dentry, &inode->i_dentry, d_alias) { +hlist_for_each_entry (dentry, &inode->i_dentry, d_u.d_alias) {spin_lock (&dentry->d_lock);if (ocfs2_match_dentry (dentry, parent_blkno, skip_unhashed)) { trace_ocfs2_find_local_alias(dentry->d_name.len,
fs/proc/task_mmu.c +45 -22
92 lines not on this page · raw message
include/linux/dcache.h +4 -4
@@ -124,15 +124,15 @@ struct dentry {void *d_fsdata;/* fs-specific data */ struct list_head d_lru;/* LRU list */ +struct list_head d_child;/* child of parent list */ +struct list_head d_subdirs;/* our children */ /* -* d_child and d_rcu can share memory +* d_alias and d_rcu can share memory */ union { -struct list_head d_child;/* child of parent list */ +struct hlist_node d_alias;/* inode alias list */ struct rcu_head d_rcu; } d_u; -struct list_head d_subdirs;/* our children */ -struct hlist_node d_alias;/* inode alias list */ };/*
include/linux/mm.h +4 -2
@@ -1009,6 +1009,7 @@ static inline int page_mapped(struct page *page)#define VM_FAULT_WRITE 0x0008/* Special case for get_user_pages */ #define VM_FAULT_HWPOISON 0x0010/* Hit poisoned small page */ #define VM_FAULT_HWPOISON_LARGE 0x0020/* Hit poisoned large page. Index encoded in upper bits */ +#define VM_FAULT_SIGSEGV 0x0040#define VM_FAULT_NOPAGE 0x0100/* ->fault installed the pte, not return page */ #define VM_FAULT_LOCKED 0x0200/* ->fault locked the returned page */
@@ -1017,8 +1018,9 @@ static inline int page_mapped(struct page *page)#define VM_FAULT_HWPOISON_LARGE_MASK 0xf000/* encodes hpage index for large hwpoison */ -#define VM_FAULT_ERROR (VM_FAULT_OOM | VM_FAULT_SIGBUS | VM_FAULT_HWPOISON | \ - VM_FAULT_FALLBACK | VM_FAULT_HWPOISON_LARGE) +#define VM_FAULT_ERROR (VM_FAULT_OOM | VM_FAULT_SIGBUS | VM_FAULT_SIGSEGV | \ + VM_FAULT_HWPOISON | VM_FAULT_HWPOISON_LARGE | \ + VM_FAULT_FALLBACK)/* Encode hstate index for a hwpoisoned large page */ #define VM_FAULT_SET_HINDEX (x) ((x) << 12)
include/linux/netdevice.h +6 -0
@@ -1880,6 +1880,12 @@ void netdev_freemem(struct net_device *dev);void synchronize_net (void );int init_dummy_netdev (struct net_device *dev); +DECLARE_PER_CPU (int, xmit_recursion); +static inline int dev_recursion_level (void ) +{ +return this_cpu_read (xmit_recursion); +} +struct net_device *dev_get_by_index (struct net *net,int ifindex);struct net_device *__dev_get_by_index (struct net *net,int ifindex);struct net_device *dev_get_by_index_rcu (struct net *net,int ifindex);
include/linux/sched.h +1 -1
@@ -1695,7 +1695,7 @@ static inline pid_t task_tgid_vnr(struct task_struct *tsk) } -static int pid_alive (const struct task_struct *p); +static inline int pid_alive (const struct task_struct *p);static inline pid_t task_ppid_nr_ns (const struct task_struct *tsk,struct pid_namespace *ns) {pid_t pid =0 ;
include/net/ip.h +0 -16
@@ -407,22 +407,6 @@ static __inline__ void inet_reset_saddr(struct sock *sk)#endif -static inline int sk_mc_loop (struct sock *sk) -{ -if (!sk) -return 1 ; -switch (sk->sk_family) { -case AF_INET : -return inet_sk (sk)->mc_loop; -#if IS_ENABLED (CONFIG_IPV6 ) -case AF_INET6 : -return inet6_sk (sk)->mc_loop; -#endif - } -WARN_ON (1 ); -return 1 ; -} -bool ip_call_ra_chain (struct sk_buff *skb);/*
include/net/ip6_route.h +2 -1
@@ -168,7 +168,8 @@ int ip6_fragment(struct sk_buff *skb, int (*output)(struct sk_buff *));static inline int ip6_skb_dst_mtu (struct sk_buff *skb) { -struct ipv6_pinfo *np = skb->sk ?inet6_sk (skb->sk) :NULL ; +struct ipv6_pinfo *np = skb->sk && !dev_recursion_level () ? +inet6_sk (skb->sk) :NULL ;return (np && np->pmtudisc >=IPV6_PMTUDISC_PROBE ) ?skb_dst (skb)->dev->mtu :dst_mtu (skb_dst (skb));
include/net/sock.h +2 -0
@@ -1815,6 +1815,8 @@ struct dst_entry *__sk_dst_check(struct sock *sk, u32 cookie);struct dst_entry *sk_dst_check (struct sock *sk,u32 cookie); +bool sk_mc_loop (struct sock *sk); +static inline bool sk_can_gso (const struct sock *sk) {return net_gso_ok (sk->sk_route_caps, sk->sk_gso_type);
kernel/cgroup.c +1 -1
@@ -971,7 +971,7 @@ static void cgroup_d_remove_dir(struct dentry *dentry) parent = dentry->d_parent;spin_lock (&parent->d_lock);spin_lock_nested (&dentry->d_lock,DENTRY_D_LOCK_NESTED ); -list_del_init (&dentry->d_u.d_child); +list_del_init (&dentry->d_child);spin_unlock (&dentry->d_lock);spin_unlock (&parent->d_lock);remove_dir (dentry);
kernel/trace/trace.c +2 -2
@@ -6158,7 +6158,7 @@ static int instance_mkdir (struct inode *inode, struct dentry *dentry, umode_t mint ret;/* Paranoid: Make sure the parent is the "instances" directory */ - parent = hlist_entry(inode->i_dentry.first, struct dentry, d_alias); + parent = hlist_entry(inode->i_dentry.first, struct dentry, d_u.d_alias);if (WARN_ON_ONCE (parent != trace_instance_dir))return -ENOENT ;
@@ -6185,7 +6185,7 @@ static int instance_rmdir(struct inode *inode, struct dentry *dentry)int ret;/* Paranoid: Make sure the parent is the "instances" directory */ - parent = hlist_entry(inode->i_dentry.first, struct dentry, d_alias); + parent = hlist_entry(inode->i_dentry.first, struct dentry, d_u.d_alias);if (WARN_ON_ONCE (parent != trace_instance_dir))return -ENOENT ;
kernel/trace/trace_events.c +1 -1
@@ -428,7 +428,7 @@ static void remove_event_file_dir(struct ftrace_event_file *file)if (dir) {spin_lock (&dir->d_lock);/* probably unneeded */ -list_for_each_entry (child, &dir->d_subdirs, d_u.d_child) { +list_for_each_entry (child, &dir->d_subdirs, d_child) {if (child->d_inode)/* probably unneeded */ child->d_inode->i_private =NULL ; }
mm/ksm.c +1 -1
@@ -376,7 +376,7 @@ static int break_ksm(struct vm_area_struct *vma, unsigned long addr)else ret =VM_FAULT_WRITE ;put_page (page); - }while (!(ret & (VM_FAULT_WRITE |VM_FAULT_SIGBUS |VM_FAULT_OOM ))); + }while (!(ret & (VM_FAULT_WRITE |VM_FAULT_SIGBUS |VM_FAULT_SIGSEGV |VM_FAULT_OOM )));/* * We must loop because handle_mm_fault() may back out if there's * any difficulty e.g. if pte accessed bit gets updated concurrently.
mm/memory-failure.c +0 -2
@@ -1645,8 +1645,6 @@ static int __soft_offline_page(struct page *page, int flags)* setting PG_hwpoison. */ if (!is_free_buddy_page (page)) -lru_add_drain_all (); -if (!is_free_buddy_page (page))drain_all_pages ();SetPageHWPoison (page);if (!is_free_buddy_page (page))
mm/memory.c +4 -3
@@ -1836,7 +1836,8 @@ long __get_user_pages(struct task_struct *tsk, struct mm_struct *mm,else return -EFAULT ; } -if (ret &VM_FAULT_SIGBUS ) +if (ret & (VM_FAULT_SIGBUS | +VM_FAULT_SIGSEGV ))return i ? i : -EFAULT ;BUG (); }
@@ -1946,7 +1947,7 @@ int fixup_user_fault(struct task_struct *tsk, struct mm_struct *mm,return -ENOMEM ;if (ret & (VM_FAULT_HWPOISON |VM_FAULT_HWPOISON_LARGE ))return -EHWPOISON ; -if (ret &VM_FAULT_SIGBUS ) +if (ret & (VM_FAULT_SIGBUS |VM_FAULT_SIGSEGV ))return -EFAULT ;BUG (); }
@@ -3235,7 +3236,7 @@ static int do_anonymous_page(struct mm_struct *mm, struct vm_area_struct *vma,/* Check if we need to add a guard page to the stack */ if (check_stack_guard_page (vma, address) <0 ) -return VM_FAULT_SIGBUS ; +return VM_FAULT_SIGSEGV ;/* Use the zero-page for reads */ if (!(flags &FAULT_FLAG_WRITE )) {
net/core/dev.c +3 -1
@@ -2775,7 +2775,9 @@ static void skb_update_prio(struct sk_buff *skb)#define skb_update_prio (skb)#endif -static DEFINE_PER_CPU(int, xmit_recursion); +DEFINE_PER_CPU (int, xmit_recursion); +EXPORT_SYMBOL (xmit_recursion); +#define RECURSION_LIMIT 10/**
net/core/sock.c +19 -0
@@ -659,6 +659,25 @@ static inline void sock_valbool_flag(struct sock *sk, int bit, int valbool)sock_reset_flag (sk, bit); } +bool sk_mc_loop (struct sock *sk) +{ +if (dev_recursion_level ()) +return false; +if (!sk) +return true; +switch (sk->sk_family) { +case AF_INET : +return inet_sk (sk)->mc_loop; +#if IS_ENABLED (CONFIG_IPV6 ) +case AF_INET6 : +return inet6_sk (sk)->mc_loop; +#endif + } +WARN_ON (1 ); +return true; +} +EXPORT_SYMBOL (sk_mc_loop); +/* * This is meant for all protocols to use and covers goings on * at the socket level. Everything here is generic.
net/ipv4/tcp_input.c +4 -3
@@ -3064,10 +3064,11 @@ static int tcp_clean_rtx_queue(struct sock *sk, int prior_fackets,if (seq_rtt <0 ) { seq_rtt = ca_seq_rtt; } -if (!(sacked &TCPCB_SACKED_ACKED )) +if (!(sacked &TCPCB_SACKED_ACKED )) { reord =min (pkts_acked, reord); -if (!after (scb->end_seq, tp->high_seq)) - flag |=FLAG_ORIG_SACK_ACKED ; +if (!after (scb->end_seq, tp->high_seq)) + flag |=FLAG_ORIG_SACK_ACKED ; + } }if (sacked &TCPCB_SACKED_ACKED )
net/ipv4/tcp_ipv4.c +1 -1
@@ -1875,7 +1875,7 @@ void tcp_v4_early_demux(struct sk_buff *skb) skb->sk = sk; skb->destructor = sock_edemux;if (sk->sk_state !=TCP_TIME_WAIT ) { -struct dst_entry *dst = sk->sk_rx_dst; +struct dst_entry *dst =ACCESS_ONCE (sk->sk_rx_dst);if (dst) dst =dst_check (dst,0 );
net/ipv4/tcp_output.c +2 -0
@@ -2796,6 +2796,8 @@ struct sk_buff *tcp_make_synack(struct sock *sk, struct dst_entry *dst, }#endif +/* Do not fool tcpdump (if any), clean our debris */ + skb->tstamp.tv64 =0 ;return skb; }EXPORT_SYMBOL (tcp_make_synack);
net/ipv6/ip6_output.c +2 -1
@@ -555,7 +555,8 @@ int ip6_fragment(struct sk_buff *skb, int (*output)(struct sk_buff *)) {struct sk_buff *frag;struct rt6_info *rt = (struct rt6_info *)skb_dst (skb); -struct ipv6_pinfo *np = skb->sk ?inet6_sk (skb->sk) :NULL ; +struct ipv6_pinfo *np = skb->sk && !dev_recursion_level () ? +inet6_sk (skb->sk) :NULL ;struct ipv6hdr *tmp_hdr;struct frag_hdr *fh;unsigned int mtu, hlen, left, len;
net/ipv6/ndisc.c +8 -1
@@ -1193,7 +1193,14 @@ static void ndisc_router_discovery(struct sk_buff *skb)if (rt)rt6_set_expires (rt, jiffies + (HZ * lifetime));if (ra_msg->icmph.icmp6_hop_limit) { - in6_dev->cnf.hop_limit = ra_msg->icmph.icmp6_hop_limit; +/* Only set hop_limit on the interface if it is higher than +* the current hop_limit. +*/ +if (in6_dev->cnf.hop_limit < ra_msg->icmph.icmp6_hop_limit) { + in6_dev->cnf.hop_limit = ra_msg->icmph.icmp6_hop_limit; + }else { +ND_PRINTK (2 , warn,"RA: Got route advertisement with lower hop_limit than current\n" ); + }if (rt)dst_metric_set (&rt->dst,RTAX_HOPLIMIT , ra_msg->icmph.icmp6_hop_limit);
net/ipv6/tcp_ipv6.c +1 -1
@@ -1633,7 +1633,7 @@ static void tcp_v6_early_demux(struct sk_buff *skb) skb->sk = sk; skb->destructor = sock_edemux;if (sk->sk_state !=TCP_TIME_WAIT ) { -struct dst_entry *dst = sk->sk_rx_dst; +struct dst_entry *dst =ACCESS_ONCE (sk->sk_rx_dst);if (dst) dst =dst_check (dst,inet6_sk (sk)->rx_dst_cookie);
net/netfilter/nf_conntrack_proto_generic.c +25 -1
@@ -14,6 +14,30 @@static unsigned int nf_ct_generic_timeout__read_mostly =600 *HZ ; +static bool nf_generic_should_process (u8 proto) +{ +switch (proto) { +#ifdef CONFIG_NF_CT_PROTO_SCTP_MODULE +case IPPROTO_SCTP : +return false; +#endif +#ifdef CONFIG_NF_CT_PROTO_DCCP_MODULE +case IPPROTO_DCCP : +return false; +#endif +#ifdef CONFIG_NF_CT_PROTO_GRE_MODULE +case IPPROTO_GRE : +return false; +#endif +#ifdef CONFIG_NF_CT_PROTO_UDPLITE_MODULE +case IPPROTO_UDPLITE : +return false; +#endif +default : +return true; + } +} +static inline struct nf_generic_net *generic_pernet (struct net *net) {return &net->ct.nf_ct_proto.generic;
@@ -67,7 +91,7 @@ static int generic_packet(struct nf_conn *ct,static bool generic_new (struct nf_conn *ct,const struct sk_buff *skb,unsigned int dataoff,unsigned int *timeouts) { -return true; +return nf_generic_should_process (nf_ct_protonum (ct)); }#if IS_ENABLED (CONFIG_NF_CT_NETLINK_TIMEOUT )
security/selinux/selinuxfs.c +3 -3
@@ -1200,7 +1200,7 @@ static void sel_remove_entries(struct dentry *de)spin_lock (&de->d_lock); node = de->d_subdirs.next;while (node != &de->d_subdirs) { - struct dentry *d = list_entry(node, struct dentry, d_u.d_child); + struct dentry *d = list_entry(node, struct dentry, d_child);spin_lock_nested (&d->d_lock,DENTRY_D_LOCK_NESTED );list_del_init (node);
@@ -1674,12 +1674,12 @@ static void sel_remove_classes(void)list_for_each (class_node, &class_dir->d_subdirs) {struct dentry *class_subdir =list_entry (class_node, - struct dentry, d_u.d_child); + struct dentry, d_child);struct list_head *class_subdir_node;list_for_each (class_subdir_node, &class_subdir->d_subdirs) {struct dentry *d =list_entry (class_subdir_node, - struct dentry, d_u.d_child); + struct dentry, d_child);if (d->d_inode)if (d->d_inode->i_mode &S_IFDIR )