commit:     a7ca0939dc7e39edf65eba8207bab7dafe56fa3b
Author:     Mike Pagano <mpagano <AT> gentoo <DOT> org>
AuthorDate: Sun Jan 31 23:48:49 2016 +0000
Commit:     Mike Pagano <mpagano <AT> gentoo <DOT> org>
CommitDate: Sun Jan 31 23:48:49 2016 +0000
URL:        https://gitweb.gentoo.org/proj/linux-patches.git/commit/?id=a7ca0939

Linux patch 3.12.53

 0000_README              |    4 +
 1052_linux-3.12.53.patch | 1128 ++++++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 1132 insertions(+)

diff --git a/0000_README b/0000_README
index 6e9c22c..d9d82c3 100644
--- a/0000_README
+++ b/0000_README
@@ -250,6 +250,10 @@ Patch:  1051_linux-3.12.52.patch
 From:   http://www.kernel.org
 Desc:   Linux 3.12.52
 
+Patch:  1052_linux-3.12.53.patch
+From:   http://www.kernel.org
+Desc:   Linux 3.12.53
+
 Patch:  1500_XATTR_USER_PREFIX.patch
 From:   https://bugs.gentoo.org/show_bug.cgi?id=470644
 Desc:   Support for namespace user.pax.* on tmpfs.

diff --git a/1052_linux-3.12.53.patch b/1052_linux-3.12.53.patch
new file mode 100644
index 0000000..3eefc18
--- /dev/null
+++ b/1052_linux-3.12.53.patch
@@ -0,0 +1,1128 @@
+diff --git a/MAINTAINERS b/MAINTAINERS
+index ffcaf975bed7..44881abcfb06 100644
+--- a/MAINTAINERS
++++ b/MAINTAINERS
+@@ -8151,6 +8151,7 @@ F:       include/linux/swiotlb.h
+ 
+ SYNOPSYS ARC ARCHITECTURE
+ M:    Vineet Gupta <[email protected]>
++L:    [email protected]
+ S:    Supported
+ F:    arch/arc/
+ F:    Documentation/devicetree/bindings/arc/
+diff --git a/Makefile b/Makefile
+index 0314ac5a52ca..3a572ff5b8e3 100644
+--- a/Makefile
++++ b/Makefile
+@@ -1,6 +1,6 @@
+ VERSION = 3
+ PATCHLEVEL = 12
+-SUBLEVEL = 52
++SUBLEVEL = 53
+ EXTRAVERSION =
+ NAME = One Giant Leap for Frogkind
+ 
+diff --git a/arch/blackfin/mach-common/pm.c b/arch/blackfin/mach-common/pm.c
+index 87bfe549ad3f..92273fa6804a 100644
+--- a/arch/blackfin/mach-common/pm.c
++++ b/arch/blackfin/mach-common/pm.c
+@@ -144,7 +144,7 @@ int bfin_pm_suspend_mem_enter(void)
+ 
+       unsigned char *memptr = kmalloc(L1_CODE_LENGTH + L1_DATA_A_LENGTH
+                                        + L1_DATA_B_LENGTH + L1_SCRATCH_LENGTH,
+-                                        GFP_KERNEL);
++                                        GFP_ATOMIC);
+ 
+       if (memptr == NULL) {
+               panic("bf53x_suspend_l1_mem malloc failed");
+diff --git a/arch/m32r/include/asm/pgalloc.h b/arch/m32r/include/asm/pgalloc.h
+index 0fc736198979..ac4208bcc5ad 100644
+--- a/arch/m32r/include/asm/pgalloc.h
++++ b/arch/m32r/include/asm/pgalloc.h
+@@ -43,6 +43,8 @@ static __inline__ pgtable_t pte_alloc_one(struct mm_struct 
*mm,
+ {
+       struct page *pte = alloc_page(GFP_KERNEL|__GFP_ZERO);
+ 
++      if (!pte)
++              return NULL;
+       pgtable_page_ctor(pte);
+       return pte;
+ }
+diff --git a/arch/m68k/kernel/head.S b/arch/m68k/kernel/head.S
+index ac85f16534af..4180f8b20374 100644
+--- a/arch/m68k/kernel/head.S
++++ b/arch/m68k/kernel/head.S
+@@ -2909,7 +2909,9 @@ func_start       serial_init,%d0/%d1/%a0/%a1
+ 
+ #if defined(MAC_USE_SCC_A) || defined(MAC_USE_SCC_B)
+       movel   %pc@(L(mac_sccbase)),%a0
+-      /* Reset SCC device */
++      /* Reset SCC register pointer */
++      moveb   %a0@(mac_scc_cha_a_ctrl_offset),%d0
++      /* Reset SCC device: write register pointer then register value */
+       moveb   #9,%a0@(mac_scc_cha_a_ctrl_offset)
+       moveb   #0xc0,%a0@(mac_scc_cha_a_ctrl_offset)
+       /* Wait for 5 PCLK cycles, which is about 68 CPU cycles */
+diff --git a/arch/m68k/mm/fault.c b/arch/m68k/mm/fault.c
+index f0eef0491f77..97136b5e47e0 100644
+--- a/arch/m68k/mm/fault.c
++++ b/arch/m68k/mm/fault.c
+@@ -77,8 +77,7 @@ int do_page_fault(struct pt_regs *regs, unsigned long 
address,
+ 
+ #ifdef DEBUG
+       printk ("do page fault:\nregs->sr=%#x, regs->pc=%#lx, address=%#lx, 
%ld, %p\n",
+-              regs->sr, regs->pc, address, error_code,
+-              current->mm->pgd);
++              regs->sr, regs->pc, address, error_code, mm ? mm->pgd : NULL);
+ #endif
+ 
+       /*
+diff --git a/arch/powerpc/kvm/book3s_hv.c b/arch/powerpc/kvm/book3s_hv.c
+index 211974a386d6..ed6e0be80b3b 100644
+--- a/arch/powerpc/kvm/book3s_hv.c
++++ b/arch/powerpc/kvm/book3s_hv.c
+@@ -160,6 +160,12 @@ void kvmppc_core_vcpu_put(struct kvm_vcpu *vcpu)
+ 
+ void kvmppc_set_msr(struct kvm_vcpu *vcpu, u64 msr)
+ {
++      /*
++       * Check for illegal transactional state bit combination
++       * and if we find it, force the TS field to a safe state.
++       */
++      if ((msr & MSR_TS_MASK) == MSR_TS_MASK)
++              msr &= ~MSR_TS_MASK;
+       vcpu->arch.shregs.msr = msr;
+       kvmppc_end_cede(vcpu);
+ }
+diff --git a/arch/x86/include/asm/boot.h b/arch/x86/include/asm/boot.h
+index 4fa687a47a62..6b8d6e8cd449 100644
+--- a/arch/x86/include/asm/boot.h
++++ b/arch/x86/include/asm/boot.h
+@@ -27,7 +27,7 @@
+ #define BOOT_HEAP_SIZE             0x400000
+ #else /* !CONFIG_KERNEL_BZIP2 */
+ 
+-#define BOOT_HEAP_SIZE        0x8000
++#define BOOT_HEAP_SIZE        0x10000
+ 
+ #endif /* !CONFIG_KERNEL_BZIP2 */
+ 
+diff --git a/arch/x86/kernel/reboot.c b/arch/x86/kernel/reboot.c
+index cb74a04c56c8..8134735f98e4 100644
+--- a/arch/x86/kernel/reboot.c
++++ b/arch/x86/kernel/reboot.c
+@@ -180,6 +180,14 @@ static struct dmi_system_id __initdata reboot_dmi_table[] 
= {
+                       DMI_MATCH(DMI_PRODUCT_NAME, "iMac9,1"),
+               },
+       },
++      {       /* Handle problems with rebooting on the iMac10,1. */
++              .callback = set_pci_reboot,
++              .ident = "Apple iMac10,1",
++              .matches = {
++                  DMI_MATCH(DMI_SYS_VENDOR, "Apple Inc."),
++                  DMI_MATCH(DMI_PRODUCT_NAME, "iMac10,1"),
++              },
++      },
+ 
+       /* ASRock */
+       {       /* Handle problems with rebooting on ASRock Q1900DC-ITX */
+diff --git a/arch/x86/kernel/signal.c b/arch/x86/kernel/signal.c
+index b88fc86309bc..5d3e60156683 100644
+--- a/arch/x86/kernel/signal.c
++++ b/arch/x86/kernel/signal.c
+@@ -682,12 +682,15 @@ handle_signal(struct ksignal *ksig, struct pt_regs *regs)
+       signal_setup_done(failed, ksig, test_thread_flag(TIF_SINGLESTEP));
+ }
+ 
+-#ifdef CONFIG_X86_32
+-#define NR_restart_syscall    __NR_restart_syscall
+-#else /* !CONFIG_X86_32 */
+-#define NR_restart_syscall    \
+-      test_thread_flag(TIF_IA32) ? __NR_ia32_restart_syscall : 
__NR_restart_syscall
+-#endif /* CONFIG_X86_32 */
++static inline unsigned long get_nr_restart_syscall(const struct pt_regs *regs)
++{
++#if defined(CONFIG_X86_32) || !defined(CONFIG_X86_64)
++      return __NR_restart_syscall;
++#else /* !CONFIG_X86_32 && CONFIG_X86_64 */
++      return test_thread_flag(TIF_IA32) ? __NR_ia32_restart_syscall :
++              __NR_restart_syscall | (regs->orig_ax & __X32_SYSCALL_BIT);
++#endif /* CONFIG_X86_32 || !CONFIG_X86_64 */
++}
+ 
+ /*
+  * Note that 'init' is a special process: it doesn't get signals it doesn't
+@@ -716,7 +719,7 @@ static void do_signal(struct pt_regs *regs)
+                       break;
+ 
+               case -ERESTART_RESTARTBLOCK:
+-                      regs->ax = NR_restart_syscall;
++                      regs->ax = get_nr_restart_syscall(regs);
+                       regs->ip -= 2;
+                       break;
+               }
+diff --git a/arch/x86/platform/efi/efi.c b/arch/x86/platform/efi/efi.c
+index f19284d87dfe..9167de031e47 100644
+--- a/arch/x86/platform/efi/efi.c
++++ b/arch/x86/platform/efi/efi.c
+@@ -250,12 +250,19 @@ static efi_status_t __init 
phys_efi_set_virtual_address_map(
+       efi_memory_desc_t *virtual_map)
+ {
+       efi_status_t status;
++      unsigned long flags;
+ 
+       efi_call_phys_prelog();
++
++      /* Disable interrupts around EFI calls: */
++      local_irq_save(flags);
+       status = efi_call_phys4(efi_phys.set_virtual_address_map,
+                               memory_map_size, descriptor_size,
+                               descriptor_version, virtual_map);
++      local_irq_restore(flags);
++
+       efi_call_phys_epilog();
++
+       return status;
+ }
+ 
+diff --git a/arch/x86/platform/efi/efi_32.c b/arch/x86/platform/efi/efi_32.c
+index 40e446941dd7..bebbee05e331 100644
+--- a/arch/x86/platform/efi/efi_32.c
++++ b/arch/x86/platform/efi/efi_32.c
+@@ -33,19 +33,16 @@
+ 
+ /*
+  * To make EFI call EFI runtime service in physical addressing mode we need
+- * prelog/epilog before/after the invocation to disable interrupt, to
+- * claim EFI runtime service handler exclusively and to duplicate a memory in
+- * low memory space say 0 - 3G.
++ * prolog/epilog before/after the invocation to claim the EFI runtime service
++ * handler exclusively and to duplicate a memory mapping in low memory space,
++ * say 0 - 3G.
+  */
+ 
+-static unsigned long efi_rt_eflags;
+ 
+ void efi_call_phys_prelog(void)
+ {
+       struct desc_ptr gdt_descr;
+ 
+-      local_irq_save(efi_rt_eflags);
+-
+       load_cr3(initial_page_table);
+       __flush_tlb_all();
+ 
+@@ -64,6 +61,4 @@ void efi_call_phys_epilog(void)
+ 
+       load_cr3(swapper_pg_dir);
+       __flush_tlb_all();
+-
+-      local_irq_restore(efi_rt_eflags);
+ }
+diff --git a/arch/x86/platform/efi/efi_64.c b/arch/x86/platform/efi/efi_64.c
+index 39a0e7f1f0a3..2f6c1a9734c8 100644
+--- a/arch/x86/platform/efi/efi_64.c
++++ b/arch/x86/platform/efi/efi_64.c
+@@ -40,7 +40,6 @@
+ #include <asm/fixmap.h>
+ 
+ static pgd_t *save_pgd __initdata;
+-static unsigned long efi_flags __initdata;
+ 
+ static void __init early_code_mapping_set_exec(int executable)
+ {
+@@ -66,7 +65,6 @@ void __init efi_call_phys_prelog(void)
+       int n_pgds;
+ 
+       early_code_mapping_set_exec(1);
+-      local_irq_save(efi_flags);
+ 
+       n_pgds = DIV_ROUND_UP((max_pfn << PAGE_SHIFT), PGDIR_SIZE);
+       save_pgd = kmalloc(n_pgds * sizeof(pgd_t), GFP_KERNEL);
+@@ -90,7 +88,6 @@ void __init efi_call_phys_epilog(void)
+               set_pgd(pgd_offset_k(pgd * PGDIR_SIZE), save_pgd[pgd]);
+       kfree(save_pgd);
+       __flush_tlb_all();
+-      local_irq_restore(efi_flags);
+       early_code_mapping_set_exec(0);
+ }
+ 
+diff --git a/arch/x86/xen/suspend.c b/arch/x86/xen/suspend.c
+index 45329c8c226e..39e12c10b931 100644
+--- a/arch/x86/xen/suspend.c
++++ b/arch/x86/xen/suspend.c
+@@ -30,7 +30,8 @@ void xen_arch_hvm_post_suspend(int suspend_cancelled)
+ {
+ #ifdef CONFIG_XEN_PVHVM
+       int cpu;
+-      xen_hvm_init_shared_info();
++      if (!suspend_cancelled)
++          xen_hvm_init_shared_info();
+       xen_callback_vector();
+       xen_unplug_emulated_devices();
+       if (xen_feature(XENFEAT_hvm_safe_pvclock)) {
+diff --git a/block/blk-core.c b/block/blk-core.c
+index bf214ae98937..de352508333f 100644
+--- a/block/blk-core.c
++++ b/block/blk-core.c
+@@ -1893,7 +1893,8 @@ void submit_bio(int rw, struct bio *bio)
+ EXPORT_SYMBOL(submit_bio);
+ 
+ /**
+- * blk_rq_check_limits - Helper function to check a request for the queue 
limit
++ * blk_cloned_rq_check_limits - Helper function to check a cloned request
++ *                              for new the queue limits
+  * @q:  the queue
+  * @rq: the request being checked
+  *
+@@ -1904,20 +1905,13 @@ EXPORT_SYMBOL(submit_bio);
+  *    after it is inserted to @q, it should be checked against @q before
+  *    the insertion using this generic function.
+  *
+- *    This function should also be useful for request stacking drivers
+- *    in some cases below, so export this function.
+  *    Request stacking drivers like request-based dm may change the queue
+- *    limits while requests are in the queue (e.g. dm's table swapping).
+- *    Such request stacking drivers should check those requests agaist
+- *    the new queue limits again when they dispatch those requests,
+- *    although such checkings are also done against the old queue limits
+- *    when submitting requests.
++ *    limits when retrying requests on other queues. Those requests need
++ *    to be checked against the new queue limits again during dispatch.
+  */
+-int blk_rq_check_limits(struct request_queue *q, struct request *rq)
++static int blk_cloned_rq_check_limits(struct request_queue *q,
++                                    struct request *rq)
+ {
+-      if (!rq_mergeable(rq))
+-              return 0;
+-
+       if (blk_rq_sectors(rq) > blk_queue_get_max_sectors(q, rq->cmd_flags)) {
+               printk(KERN_ERR "%s: over max size limit.\n", __func__);
+               return -EIO;
+@@ -1937,7 +1931,6 @@ int blk_rq_check_limits(struct request_queue *q, struct 
request *rq)
+ 
+       return 0;
+ }
+-EXPORT_SYMBOL_GPL(blk_rq_check_limits);
+ 
+ /**
+  * blk_insert_cloned_request - Helper for stacking drivers to submit a request
+@@ -1949,7 +1942,7 @@ int blk_insert_cloned_request(struct request_queue *q, 
struct request *rq)
+       unsigned long flags;
+       int where = ELEVATOR_INSERT_BACK;
+ 
+-      if (blk_rq_check_limits(q, rq))
++      if (blk_cloned_rq_check_limits(q, rq))
+               return -EIO;
+ 
+       if (rq->rq_disk &&
+diff --git a/drivers/char/ipmi/ipmi_si_intf.c 
b/drivers/char/ipmi/ipmi_si_intf.c
+index 25ed69ffd8dd..c16fd35bd640 100644
+--- a/drivers/char/ipmi/ipmi_si_intf.c
++++ b/drivers/char/ipmi/ipmi_si_intf.c
+@@ -1152,14 +1152,14 @@ static int smi_start_processing(void       *send_info,
+ 
+       new_smi->intf = intf;
+ 
+-      /* Try to claim any interrupts. */
+-      if (new_smi->irq_setup)
+-              new_smi->irq_setup(new_smi);
+-
+       /* Set up the timer that drives the interface. */
+       setup_timer(&new_smi->si_timer, smi_timeout, (long)new_smi);
+       smi_mod_timer(new_smi, jiffies + SI_TIMEOUT_JIFFIES);
+ 
++      /* Try to claim any interrupts. */
++      if (new_smi->irq_setup)
++              new_smi->irq_setup(new_smi);
++
+       /*
+        * Check if the user forcefully enabled the daemon.
+        */
+diff --git a/drivers/gpu/drm/i915/intel_ringbuffer.c 
b/drivers/gpu/drm/i915/intel_ringbuffer.c
+index 4e51ce2bbb85..83780190cdd7 100644
+--- a/drivers/gpu/drm/i915/intel_ringbuffer.c
++++ b/drivers/gpu/drm/i915/intel_ringbuffer.c
+@@ -1125,7 +1125,7 @@ i830_dispatch_execbuffer(struct intel_ring_buffer *ring,
+                */
+               intel_ring_emit(ring, SRC_COPY_BLT_CMD | BLT_WRITE_RGBA);
+               intel_ring_emit(ring, BLT_DEPTH_32 | BLT_ROP_SRC_COPY | 4096);
+-              intel_ring_emit(ring, DIV_ROUND_UP(len, 4096) << 16 | 1024);
++              intel_ring_emit(ring, DIV_ROUND_UP(len, 4096) << 16 | 4096);
+               intel_ring_emit(ring, cs_offset);
+               intel_ring_emit(ring, 4096);
+               intel_ring_emit(ring, offset);
+diff --git a/drivers/input/tablet/aiptek.c b/drivers/input/tablet/aiptek.c
+index ee83c3904ee8..fcf9aa1eb167 100644
+--- a/drivers/input/tablet/aiptek.c
++++ b/drivers/input/tablet/aiptek.c
+@@ -1820,6 +1820,14 @@ aiptek_probe(struct usb_interface *intf, const struct 
usb_device_id *id)
+       input_set_abs_params(inputdev, ABS_TILT_Y, AIPTEK_TILT_MIN, 
AIPTEK_TILT_MAX, 0, 0);
+       input_set_abs_params(inputdev, ABS_WHEEL, AIPTEK_WHEEL_MIN, 
AIPTEK_WHEEL_MAX - 1, 0, 0);
+ 
++      /* Verify that a device really has an endpoint */
++      if (intf->altsetting[0].desc.bNumEndpoints < 1) {
++              dev_err(&intf->dev,
++                      "interface has %d endpoints, but must have minimum 1\n",
++                      intf->altsetting[0].desc.bNumEndpoints);
++              err = -EINVAL;
++              goto fail3;
++      }
+       endpoint = &intf->altsetting[0].endpoint[0].desc;
+ 
+       /* Go set up our URB, which is called when the tablet receives
+@@ -1862,6 +1870,7 @@ aiptek_probe(struct usb_interface *intf, const struct 
usb_device_id *id)
+       if (i == ARRAY_SIZE(speeds)) {
+               dev_info(&intf->dev,
+                        "Aiptek tried all speeds, no sane response\n");
++              err = -EINVAL;
+               goto fail3;
+       }
+ 
+diff --git a/drivers/isdn/i4l/isdn_ppp.c b/drivers/isdn/i4l/isdn_ppp.c
+index 38ceac5053a0..0ed6731396ef 100644
+--- a/drivers/isdn/i4l/isdn_ppp.c
++++ b/drivers/isdn/i4l/isdn_ppp.c
+@@ -301,6 +301,8 @@ isdn_ppp_open(int min, struct file *file)
+       is->compflags = 0;
+ 
+       is->reset = isdn_ppp_ccp_reset_alloc(is);
++      if (!is->reset)
++              return -ENOMEM;
+ 
+       is->lp = NULL;
+       is->mp_seqno = 0;       /* MP sequence number */
+@@ -320,6 +322,10 @@ isdn_ppp_open(int min, struct file *file)
+        * VJ header compression init
+        */
+       is->slcomp = slhc_init(16, 16); /* not necessary for 2. link in bundle 
*/
++      if (IS_ERR(is->slcomp)) {
++              isdn_ppp_ccp_reset_free(is);
++              return PTR_ERR(is->slcomp);
++      }
+ #endif
+ #ifdef CONFIG_IPPP_FILTER
+       is->pass_filter = NULL;
+@@ -568,10 +574,8 @@ isdn_ppp_ioctl(int min, struct file *file, unsigned int 
cmd, unsigned long arg)
+                       is->maxcid = val;
+ #ifdef CONFIG_ISDN_PPP_VJ
+                       sltmp = slhc_init(16, val);
+-                      if (!sltmp) {
+-                              printk(KERN_ERR "ippp, can't realloc slhc 
struct\n");
+-                              return -ENOMEM;
+-                      }
++                      if (IS_ERR(sltmp))
++                              return PTR_ERR(sltmp);
+                       if (is->slcomp)
+                               slhc_free(is->slcomp);
+                       is->slcomp = sltmp;
+diff --git a/drivers/net/ppp/ppp_generic.c b/drivers/net/ppp/ppp_generic.c
+index 5a1897d86e94..a2d7d5f066f1 100644
+--- a/drivers/net/ppp/ppp_generic.c
++++ b/drivers/net/ppp/ppp_generic.c
+@@ -716,10 +716,8 @@ static long ppp_ioctl(struct file *file, unsigned int 
cmd, unsigned long arg)
+                       val &= 0xffff;
+               }
+               vj = slhc_init(val2+1, val+1);
+-              if (!vj) {
+-                      netdev_err(ppp->dev,
+-                                 "PPP: no memory (VJ compressor)\n");
+-                      err = -ENOMEM;
++              if (IS_ERR(vj)) {
++                      err = PTR_ERR(vj);
+                       break;
+               }
+               ppp_lock(ppp);
+diff --git a/drivers/net/slip/slhc.c b/drivers/net/slip/slhc.c
+index 1252d9c726a7..b52eabc168a0 100644
+--- a/drivers/net/slip/slhc.c
++++ b/drivers/net/slip/slhc.c
+@@ -84,8 +84,9 @@ static long decode(unsigned char **cpp);
+ static unsigned char * put16(unsigned char *cp, unsigned short x);
+ static unsigned short pull16(unsigned char **cpp);
+ 
+-/* Initialize compression data structure
++/* Allocate compression data structure
+  *    slots must be in range 0 to 255 (zero meaning no compression)
++ * Returns pointer to structure or ERR_PTR() on error.
+  */
+ struct slcompress *
+ slhc_init(int rslots, int tslots)
+@@ -94,11 +95,14 @@ slhc_init(int rslots, int tslots)
+       register struct cstate *ts;
+       struct slcompress *comp;
+ 
++      if (rslots < 0 || rslots > 255 || tslots < 0 || tslots > 255)
++              return ERR_PTR(-EINVAL);
++
+       comp = kzalloc(sizeof(struct slcompress), GFP_KERNEL);
+       if (! comp)
+               goto out_fail;
+ 
+-      if ( rslots > 0  &&  rslots < 256 ) {
++      if (rslots > 0) {
+               size_t rsize = rslots * sizeof(struct cstate);
+               comp->rstate = kzalloc(rsize, GFP_KERNEL);
+               if (! comp->rstate)
+@@ -106,7 +110,7 @@ slhc_init(int rslots, int tslots)
+               comp->rslot_limit = rslots - 1;
+       }
+ 
+-      if ( tslots > 0  &&  tslots < 256 ) {
++      if (tslots > 0) {
+               size_t tsize = tslots * sizeof(struct cstate);
+               comp->tstate = kzalloc(tsize, GFP_KERNEL);
+               if (! comp->tstate)
+@@ -141,7 +145,7 @@ out_free2:
+ out_free:
+       kfree(comp);
+ out_fail:
+-      return NULL;
++      return ERR_PTR(-ENOMEM);
+ }
+ 
+ 
+diff --git a/drivers/net/slip/slip.c b/drivers/net/slip/slip.c
+index 87526443841f..0641fccdc954 100644
+--- a/drivers/net/slip/slip.c
++++ b/drivers/net/slip/slip.c
+@@ -164,7 +164,7 @@ static int sl_alloc_bufs(struct slip *sl, int mtu)
+       if (cbuff == NULL)
+               goto err_exit;
+       slcomp = slhc_init(16, 16);
+-      if (slcomp == NULL)
++      if (IS_ERR(slcomp))
+               goto err_exit;
+ #endif
+       spin_lock_bh(&sl->lock);
+diff --git a/drivers/pci/pci.c b/drivers/pci/pci.c
+index 2d163544fa51..1e480a898d28 100644
+--- a/drivers/pci/pci.c
++++ b/drivers/pci/pci.c
+@@ -2871,7 +2871,7 @@ void __weak pcibios_set_master(struct pci_dev *dev)
+               lat = pcibios_max_latency;
+       else
+               return;
+-      dev_printk(KERN_DEBUG, &dev->dev, "setting latency timer to %d\n", lat);
++
+       pci_write_config_byte(dev, PCI_LATENCY_TIMER, lat);
+ }
+ 
+diff --git a/drivers/scsi/lpfc/lpfc_scsi.c b/drivers/scsi/lpfc/lpfc_scsi.c
+index ed7759980c47..1d01ed6f8dd2 100644
+--- a/drivers/scsi/lpfc/lpfc_scsi.c
++++ b/drivers/scsi/lpfc/lpfc_scsi.c
+@@ -5264,7 +5264,15 @@ lpfc_target_reset_handler(struct scsi_cmnd *cmnd)
+       if (status == FAILED) {
+               lpfc_printf_vlog(vport, KERN_ERR, LOG_FCP,
+                       "0722 Target Reset rport failure: rdata x%p\n", rdata);
+-              return FAILED;
++              if (pnode) {
++                      spin_lock_irq(shost->host_lock);
++                      pnode->nlp_flag &= ~NLP_NPR_ADISC;
++                      pnode->nlp_fcp_info &= ~NLP_FCP_2_DEVICE;
++                      spin_unlock_irq(shost->host_lock);
++              }
++              lpfc_reset_flush_io_context(vport, tgt_id, lun_id,
++                                          LPFC_CTX_TGT);
++              return FAST_IO_FAIL;
+       }
+ 
+       scsi_event.event_type = FC_REG_SCSI_EVENT;
+diff --git a/drivers/scsi/qla2xxx/qla_init.c b/drivers/scsi/qla2xxx/qla_init.c
+index 03f715e7591e..df67a0649410 100644
+--- a/drivers/scsi/qla2xxx/qla_init.c
++++ b/drivers/scsi/qla2xxx/qla_init.c
+@@ -2725,6 +2725,7 @@ qla2x00_rport_del(void *data)
+       struct fc_rport *rport;
+       scsi_qla_host_t *vha = fcport->vha;
+       unsigned long flags;
++      unsigned long vha_flags;
+ 
+       spin_lock_irqsave(fcport->vha->host->host_lock, flags);
+       rport = fcport->drport ? fcport->drport: fcport->rport;
+@@ -2736,7 +2737,9 @@ qla2x00_rport_del(void *data)
+                * Release the target mode FC NEXUS in qla_target.c code
+                * if target mod is enabled.
+                */
++              spin_lock_irqsave(&vha->hw->hardware_lock, vha_flags);
+               qlt_fc_port_deleted(vha, fcport);
++              spin_unlock_irqrestore(&vha->hw->hardware_lock, vha_flags);
+       }
+ }
+ 
+@@ -3106,6 +3109,7 @@ qla2x00_reg_remote_port(scsi_qla_host_t *vha, fc_port_t 
*fcport)
+        * Create target mode FC NEXUS in qla_target.c if target mode is
+        * enabled..
+        */
++
+       qlt_fc_port_added(vha, fcport);
+ 
+       spin_lock_irqsave(fcport->vha->host->host_lock, flags);
+diff --git a/drivers/scsi/qla2xxx/qla_target.c 
b/drivers/scsi/qla2xxx/qla_target.c
+index 30788321ac2b..16a4cf8654a8 100644
+--- a/drivers/scsi/qla2xxx/qla_target.c
++++ b/drivers/scsi/qla2xxx/qla_target.c
+@@ -741,7 +741,6 @@ void qlt_fc_port_deleted(struct scsi_qla_host *vha, 
fc_port_t *fcport)
+       struct qla_hw_data *ha = vha->hw;
+       struct qla_tgt *tgt = ha->tgt.qla_tgt;
+       struct qla_tgt_sess *sess;
+-      unsigned long flags;
+ 
+       if (!vha->hw->tgt.tgt_ops)
+               return;
+@@ -749,14 +748,11 @@ void qlt_fc_port_deleted(struct scsi_qla_host *vha, 
fc_port_t *fcport)
+       if (!tgt || (fcport->port_type != FCT_INITIATOR))
+               return;
+ 
+-      spin_lock_irqsave(&ha->hardware_lock, flags);
+       if (tgt->tgt_stop) {
+-              spin_unlock_irqrestore(&ha->hardware_lock, flags);
+               return;
+       }
+       sess = qlt_find_sess_by_port_name(tgt, fcport->port_name);
+       if (!sess) {
+-              spin_unlock_irqrestore(&ha->hardware_lock, flags);
+               return;
+       }
+ 
+@@ -764,7 +760,6 @@ void qlt_fc_port_deleted(struct scsi_qla_host *vha, 
fc_port_t *fcport)
+ 
+       sess->local = 1;
+       qlt_schedule_sess_for_deletion(sess, false);
+-      spin_unlock_irqrestore(&ha->hardware_lock, flags);
+ }
+ 
+ static inline int test_tgt_sess_count(struct qla_tgt *tgt)
+diff --git a/drivers/staging/dgnc/dgnc_mgmt.c 
b/drivers/staging/dgnc/dgnc_mgmt.c
+index c4629d7c80b2..d885bbb7de60 100644
+--- a/drivers/staging/dgnc/dgnc_mgmt.c
++++ b/drivers/staging/dgnc/dgnc_mgmt.c
+@@ -145,6 +145,7 @@ long dgnc_mgmt_ioctl(struct file *file, unsigned int cmd, 
unsigned long arg)
+ 
+               DGNC_LOCK(dgnc_global_lock, lock_flags);
+ 
++              memset(&ddi, 0, sizeof(ddi));
+               ddi.dinfo_nboards = dgnc_NumBoards;
+               sprintf(ddi.dinfo_version, "%s", DG_PART);
+ 
+diff --git a/drivers/usb/core/quirks.c b/drivers/usb/core/quirks.c
+index a6956cd27334..9596d4f3e71a 100644
+--- a/drivers/usb/core/quirks.c
++++ b/drivers/usb/core/quirks.c
+@@ -125,6 +125,9 @@ static const struct usb_device_id usb_quirk_list[] = {
+       { USB_DEVICE(0x04f3, 0x016f), .driver_info =
+                       USB_QUIRK_DEVICE_QUALIFIER },
+ 
++      { USB_DEVICE(0x04f3, 0x21b8), .driver_info =
++                      USB_QUIRK_DEVICE_QUALIFIER },
++
+       /* Roland SC-8820 */
+       { USB_DEVICE(0x0582, 0x0007), .driver_info = USB_QUIRK_RESET_RESUME },
+ 
+diff --git a/drivers/xen/gntdev.c b/drivers/xen/gntdev.c
+index 0b5806995718..27accc4cc999 100644
+--- a/drivers/xen/gntdev.c
++++ b/drivers/xen/gntdev.c
+@@ -763,7 +763,7 @@ static int gntdev_mmap(struct file *flip, struct 
vm_area_struct *vma)
+ 
+       vma->vm_ops = &gntdev_vmops;
+ 
+-      vma->vm_flags |= VM_DONTEXPAND | VM_DONTDUMP;
++      vma->vm_flags |= VM_DONTEXPAND | VM_DONTDUMP | VM_IO;
+ 
+       if (use_ptemod)
+               vma->vm_flags |= VM_DONTCOPY;
+diff --git a/fs/dlm/plock.c b/fs/dlm/plock.c
+index f704458ea5f5..a6d999418de4 100644
+--- a/fs/dlm/plock.c
++++ b/fs/dlm/plock.c
+@@ -145,7 +145,7 @@ int dlm_posix_lock(dlm_lockspace_t *lockspace, u64 number, 
struct file *file,
+       send_op(op);
+ 
+       if (xop->callback == NULL) {
+-              rv = wait_event_killable(recv_wq, (op->done != 0));
++              rv = wait_event_interruptible(recv_wq, (op->done != 0));
+               if (rv == -ERESTARTSYS) {
+                       log_debug(ls, "dlm_posix_lock: wait killed %llx",
+                                 (unsigned long long)number);
+diff --git a/include/linux/blkdev.h b/include/linux/blkdev.h
+index b1056783c105..e66eba43d702 100644
+--- a/include/linux/blkdev.h
++++ b/include/linux/blkdev.h
+@@ -740,7 +740,6 @@ extern struct request *blk_make_request(struct 
request_queue *, struct bio *,
+ extern void blk_requeue_request(struct request_queue *, struct request *);
+ extern void blk_add_request_payload(struct request *rq, struct page *page,
+               unsigned int len);
+-extern int blk_rq_check_limits(struct request_queue *q, struct request *rq);
+ extern int blk_lld_busy(struct request_queue *q);
+ extern int blk_rq_prep_clone(struct request *rq, struct request *rq_src,
+                            struct bio_set *bs, gfp_t gfp_mask,
+diff --git a/include/linux/isapnp.h b/include/linux/isapnp.h
+index e2d28b026a8c..3c77bf9b1efd 100644
+--- a/include/linux/isapnp.h
++++ b/include/linux/isapnp.h
+@@ -56,10 +56,6 @@
+ #define ISAPNP_DEVICE_ID(_va, _vb, _vc, _function) \
+               { .vendor = ISAPNP_VENDOR(_va, _vb, _vc), .function = 
ISAPNP_FUNCTION(_function) }
+ 
+-/* export used IDs outside module */
+-#define ISAPNP_CARD_TABLE(name) \
+-              MODULE_GENERIC_TABLE(isapnp_card, name)
+-
+ struct isapnp_card_id {
+       unsigned long driver_data;      /* data private to the driver */
+       unsigned short card_vendor, card_device;
+diff --git a/include/linux/module.h b/include/linux/module.h
+index 54aef1b38463..73c8c06c25bf 100644
+--- a/include/linux/module.h
++++ b/include/linux/module.h
+@@ -83,15 +83,6 @@ void sort_extable(struct exception_table_entry *start,
+ void sort_main_extable(void);
+ void trim_init_extable(struct module *m);
+ 
+-#ifdef MODULE
+-#define MODULE_GENERIC_TABLE(gtype,name)                      \
+-extern const struct gtype##_id __mod_##gtype##_table          \
+-  __attribute__ ((unused, alias(__stringify(name))))
+-
+-#else  /* !MODULE */
+-#define MODULE_GENERIC_TABLE(gtype,name)
+-#endif
+-
+ /* Generic info of form tag = "info" */
+ #define MODULE_INFO(tag, info) __MODULE_INFO(tag, tag, info)
+ 
+@@ -142,8 +133,14 @@ extern const struct gtype##_id __mod_##gtype##_table      
        \
+ /* What your module does. */
+ #define MODULE_DESCRIPTION(_description) MODULE_INFO(description, 
_description)
+ 
+-#define MODULE_DEVICE_TABLE(type,name)                \
+-  MODULE_GENERIC_TABLE(type##__##name##_device, name)
++#ifdef MODULE
++/* Creates an alias so file2alias.c can find device table. */
++#define MODULE_DEVICE_TABLE(type, name)                                       
\
++  extern const struct type##_device_id __mod_##type##__##name##_device_table \
++  __attribute__ ((unused, alias(__stringify(name))))
++#else  /* !MODULE */
++#define MODULE_DEVICE_TABLE(type, name)
++#endif
+ 
+ /* Version of form [<epoch>:]<version>[-<extra-version>].
+    Or for CVS/RCS ID version, everything but the number is stripped.
+diff --git a/include/trace/events/sunrpc.h b/include/trace/events/sunrpc.h
+index d51d16c7afd8..3646fa31ade9 100644
+--- a/include/trace/events/sunrpc.h
++++ b/include/trace/events/sunrpc.h
+@@ -83,7 +83,7 @@ DECLARE_EVENT_CLASS(rpc_task_running,
+               ),
+ 
+       TP_fast_assign(
+-              __entry->client_id = clnt->cl_clid;
++              __entry->client_id = clnt ? clnt->cl_clid : -1;
+               __entry->task_id = task->tk_pid;
+               __entry->action = action;
+               __entry->runstate = task->tk_runstate;
+@@ -91,7 +91,7 @@ DECLARE_EVENT_CLASS(rpc_task_running,
+               __entry->flags = task->tk_flags;
+               ),
+ 
+-      TP_printk("task:%u@%u flags=%4.4x state=%4.4lx status=%d action=%pf",
++      TP_printk("task:%u@%d flags=%4.4x state=%4.4lx status=%d action=%pf",
+               __entry->task_id, __entry->client_id,
+               __entry->flags,
+               __entry->runstate,
+diff --git a/kernel/trace/ring_buffer.c b/kernel/trace/ring_buffer.c
+index 469af802d14e..d6b35d3a232c 100644
+--- a/kernel/trace/ring_buffer.c
++++ b/kernel/trace/ring_buffer.c
+@@ -1700,22 +1700,14 @@ int ring_buffer_resize(struct ring_buffer *buffer, 
unsigned long size,
+                       if (!cpu_buffer->nr_pages_to_update)
+                               continue;
+ 
+-                      /* The update must run on the CPU that is being 
updated. */
+-                      preempt_disable();
+-                      if (cpu == smp_processor_id() || !cpu_online(cpu)) {
++                      /* Can't run something on an offline CPU. */
++                      if (!cpu_online(cpu)) {
+                               rb_update_pages(cpu_buffer);
+                               cpu_buffer->nr_pages_to_update = 0;
+                       } else {
+-                              /*
+-                               * Can not disable preemption for 
schedule_work_on()
+-                               * on PREEMPT_RT.
+-                               */
+-                              preempt_enable();
+                               schedule_work_on(cpu,
+                                               &cpu_buffer->update_pages_work);
+-                              preempt_disable();
+                       }
+-                      preempt_enable();
+               }
+ 
+               /* wait for all the updates to complete */
+@@ -1753,22 +1745,14 @@ int ring_buffer_resize(struct ring_buffer *buffer, 
unsigned long size,
+ 
+               get_online_cpus();
+ 
+-              preempt_disable();
+-              /* The update must run on the CPU that is being updated. */
+-              if (cpu_id == smp_processor_id() || !cpu_online(cpu_id))
++              /* Can't run something on an offline CPU. */
++              if (!cpu_online(cpu_id))
+                       rb_update_pages(cpu_buffer);
+               else {
+-                      /*
+-                       * Can not disable preemption for schedule_work_on()
+-                       * on PREEMPT_RT.
+-                       */
+-                      preempt_enable();
+                       schedule_work_on(cpu_id,
+                                        &cpu_buffer->update_pages_work);
+                       wait_for_completion(&cpu_buffer->update_done);
+-                      preempt_disable();
+               }
+-              preempt_enable();
+ 
+               cpu_buffer->nr_pages_to_update = 0;
+               put_online_cpus();
+diff --git a/net/ipv4/route.c b/net/ipv4/route.c
+index bd5f3461d1ce..54874e4767de 100644
+--- a/net/ipv4/route.c
++++ b/net/ipv4/route.c
+@@ -985,7 +985,7 @@ static void __ip_rt_update_pmtu(struct rtable *rt, struct 
flowi4 *fl4, u32 mtu)
+       if (dst_metric_locked(dst, RTAX_MTU))
+               return;
+ 
+-      if (dst->dev->mtu < mtu)
++      if (ipv4_mtu(dst) < mtu)
+               return;
+ 
+       if (mtu < ip_rt_min_pmtu)
+diff --git a/net/ipv4/udp.c b/net/ipv4/udp.c
+index 4908eaa1cdec..f8e304667108 100644
+--- a/net/ipv4/udp.c
++++ b/net/ipv4/udp.c
+@@ -1210,6 +1210,7 @@ int udp_recvmsg(struct kiocb *iocb, struct sock *sk, 
struct msghdr *msg,
+       int peeked, off = 0;
+       int err;
+       int is_udplite = IS_UDPLITE(sk);
++      bool checksum_valid = false;
+       bool slow;
+ 
+       if (flags & MSG_ERRQUEUE)
+@@ -1235,11 +1236,12 @@ try_again:
+        */
+ 
+       if (copied < ulen || UDP_SKB_CB(skb)->partial_cov) {
+-              if (udp_lib_checksum_complete(skb))
++              checksum_valid = !udp_lib_checksum_complete(skb);
++              if (!checksum_valid)
+                       goto csum_copy_err;
+       }
+ 
+-      if (skb_csum_unnecessary(skb))
++      if (checksum_valid || skb_csum_unnecessary(skb))
+               err = skb_copy_datagram_iovec(skb, sizeof(struct udphdr),
+                                             msg->msg_iov, copied);
+       else {
+diff --git a/net/ipv6/udp.c b/net/ipv6/udp.c
+index a6c5ef5225ef..94ca4172b38e 100644
+--- a/net/ipv6/udp.c
++++ b/net/ipv6/udp.c
+@@ -371,6 +371,7 @@ int udpv6_recvmsg(struct kiocb *iocb, struct sock *sk,
+       int peeked, off = 0;
+       int err;
+       int is_udplite = IS_UDPLITE(sk);
++      bool checksum_valid = false;
+       int is_udp4;
+       bool slow;
+ 
+@@ -402,11 +403,12 @@ try_again:
+        */
+ 
+       if (copied < ulen || UDP_SKB_CB(skb)->partial_cov) {
+-              if (udp_lib_checksum_complete(skb))
++              checksum_valid = !udp_lib_checksum_complete(skb);
++              if (!checksum_valid)
+                       goto csum_copy_err;
+       }
+ 
+-      if (skb_csum_unnecessary(skb))
++      if (checksum_valid || skb_csum_unnecessary(skb))
+               err = skb_copy_datagram_iovec(skb, sizeof(struct udphdr),
+                                             msg->msg_iov, copied);
+       else {
+diff --git a/net/sctp/sm_sideeffect.c b/net/sctp/sm_sideeffect.c
+index 1a6eef39ab2f..ae66c9fe7c55 100644
+--- a/net/sctp/sm_sideeffect.c
++++ b/net/sctp/sm_sideeffect.c
+@@ -245,12 +245,13 @@ void sctp_generate_t3_rtx_event(unsigned long peer)
+       int error;
+       struct sctp_transport *transport = (struct sctp_transport *) peer;
+       struct sctp_association *asoc = transport->asoc;
+-      struct net *net = sock_net(asoc->base.sk);
++      struct sock *sk = asoc->base.sk;
++      struct net *net = sock_net(sk);
+ 
+       /* Check whether a task is in the sock.  */
+ 
+-      sctp_bh_lock_sock(asoc->base.sk);
+-      if (sock_owned_by_user(asoc->base.sk)) {
++      sctp_bh_lock_sock(sk);
++      if (sock_owned_by_user(sk)) {
+               pr_debug("%s: sock is busy\n", __func__);
+ 
+               /* Try again later.  */
+@@ -273,10 +274,10 @@ void sctp_generate_t3_rtx_event(unsigned long peer)
+                          transport, GFP_ATOMIC);
+ 
+       if (error)
+-              asoc->base.sk->sk_err = -error;
++              sk->sk_err = -error;
+ 
+ out_unlock:
+-      sctp_bh_unlock_sock(asoc->base.sk);
++      sctp_bh_unlock_sock(sk);
+       sctp_transport_put(transport);
+ }
+ 
+@@ -286,11 +287,12 @@ out_unlock:
+ static void sctp_generate_timeout_event(struct sctp_association *asoc,
+                                       sctp_event_timeout_t timeout_type)
+ {
+-      struct net *net = sock_net(asoc->base.sk);
++      struct sock *sk = asoc->base.sk;
++      struct net *net = sock_net(sk);
+       int error = 0;
+ 
+-      sctp_bh_lock_sock(asoc->base.sk);
+-      if (sock_owned_by_user(asoc->base.sk)) {
++      sctp_bh_lock_sock(sk);
++      if (sock_owned_by_user(sk)) {
+               pr_debug("%s: sock is busy: timer %d\n", __func__,
+                        timeout_type);
+ 
+@@ -313,10 +315,10 @@ static void sctp_generate_timeout_event(struct 
sctp_association *asoc,
+                          (void *)timeout_type, GFP_ATOMIC);
+ 
+       if (error)
+-              asoc->base.sk->sk_err = -error;
++              sk->sk_err = -error;
+ 
+ out_unlock:
+-      sctp_bh_unlock_sock(asoc->base.sk);
++      sctp_bh_unlock_sock(sk);
+       sctp_association_put(asoc);
+ }
+ 
+@@ -366,10 +368,11 @@ void sctp_generate_heartbeat_event(unsigned long data)
+       int error = 0;
+       struct sctp_transport *transport = (struct sctp_transport *) data;
+       struct sctp_association *asoc = transport->asoc;
+-      struct net *net = sock_net(asoc->base.sk);
++      struct sock *sk = asoc->base.sk;
++      struct net *net = sock_net(sk);
+ 
+-      sctp_bh_lock_sock(asoc->base.sk);
+-      if (sock_owned_by_user(asoc->base.sk)) {
++      sctp_bh_lock_sock(sk);
++      if (sock_owned_by_user(sk)) {
+               pr_debug("%s: sock is busy\n", __func__);
+ 
+               /* Try again later.  */
+@@ -390,10 +393,10 @@ void sctp_generate_heartbeat_event(unsigned long data)
+                          transport, GFP_ATOMIC);
+ 
+        if (error)
+-               asoc->base.sk->sk_err = -error;
++               sk->sk_err = -error;
+ 
+ out_unlock:
+-      sctp_bh_unlock_sock(asoc->base.sk);
++      sctp_bh_unlock_sock(sk);
+       sctp_transport_put(transport);
+ }
+ 
+@@ -404,10 +407,11 @@ void sctp_generate_proto_unreach_event(unsigned long 
data)
+ {
+       struct sctp_transport *transport = (struct sctp_transport *) data;
+       struct sctp_association *asoc = transport->asoc;
+-      struct net *net = sock_net(asoc->base.sk);
++      struct sock *sk = asoc->base.sk;
++      struct net *net = sock_net(sk);
+       
+-      sctp_bh_lock_sock(asoc->base.sk);
+-      if (sock_owned_by_user(asoc->base.sk)) {
++      sctp_bh_lock_sock(sk);
++      if (sock_owned_by_user(sk)) {
+               pr_debug("%s: sock is busy\n", __func__);
+ 
+               /* Try again later.  */
+@@ -428,7 +432,7 @@ void sctp_generate_proto_unreach_event(unsigned long data)
+                  asoc->state, asoc->ep, asoc, transport, GFP_ATOMIC);
+ 
+ out_unlock:
+-      sctp_bh_unlock_sock(asoc->base.sk);
++      sctp_bh_unlock_sock(sk);
+       sctp_association_put(asoc);
+ }
+ 
+diff --git a/security/keys/keyctl.c b/security/keys/keyctl.c
+index 33cfd27b4de2..3242195bfa95 100644
+--- a/security/keys/keyctl.c
++++ b/security/keys/keyctl.c
+@@ -744,16 +744,16 @@ long keyctl_read_key(key_serial_t keyid, char __user 
*buffer, size_t buflen)
+ 
+       /* the key is probably readable - now try to read it */
+ can_read_key:
+-      ret = key_validate(key);
+-      if (ret == 0) {
+-              ret = -EOPNOTSUPP;
+-              if (key->type->read) {
+-                      /* read the data with the semaphore held (since we
+-                       * might sleep) */
+-                      down_read(&key->sem);
++      ret = -EOPNOTSUPP;
++      if (key->type->read) {
++              /* Read the data with the semaphore held (since we might sleep)
++               * to protect against the key being updated or revoked.
++               */
++              down_read(&key->sem);
++              ret = key_validate(key);
++              if (ret == 0)
+                       ret = key->type->read(key, buffer, buflen);
+-                      up_read(&key->sem);
+-              }
++              up_read(&key->sem);
+       }
+ 
+ error2:
+diff --git a/security/keys/process_keys.c b/security/keys/process_keys.c
+index 42defae1e161..cd871dc8b7c0 100644
+--- a/security/keys/process_keys.c
++++ b/security/keys/process_keys.c
+@@ -792,6 +792,7 @@ long join_session_keyring(const char *name)
+               ret = PTR_ERR(keyring);
+               goto error2;
+       } else if (keyring == new->session_keyring) {
++              key_put(keyring);
+               ret = 0;
+               goto error2;
+       }
+diff --git a/sound/pci/hda/hda_intel.c b/sound/pci/hda/hda_intel.c
+index a7315298ee10..baf12f1a2820 100644
+--- a/sound/pci/hda/hda_intel.c
++++ b/sound/pci/hda/hda_intel.c
+@@ -4082,6 +4082,11 @@ static DEFINE_PCI_DEVICE_TABLE(azx_ids) = {
+         .driver_data = AZX_DRIVER_PCH | AZX_DCAPS_INTEL_PCH },
+       { PCI_DEVICE(0x8086, 0x8d21),
+         .driver_data = AZX_DRIVER_PCH | AZX_DCAPS_INTEL_PCH },
++      /* Lewisburg */
++      { PCI_DEVICE(0x8086, 0xa1f0),
++        .driver_data = AZX_DRIVER_PCH | AZX_DCAPS_INTEL_PCH },
++      { PCI_DEVICE(0x8086, 0xa270),
++        .driver_data = AZX_DRIVER_PCH | AZX_DCAPS_INTEL_PCH },
+       /* Lynx Point-LP */
+       { PCI_DEVICE(0x8086, 0x9c20),
+         .driver_data = AZX_DRIVER_PCH | AZX_DCAPS_INTEL_PCH },
+diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c
+index 73d342c8403c..1ec93efc8253 100644
+--- a/sound/pci/hda/patch_realtek.c
++++ b/sound/pci/hda/patch_realtek.c
+@@ -3637,6 +3637,18 @@ static void alc283_fixup_chromebook(struct hda_codec 
*codec,
+       }
+ }
+ 
++/* additional fixup for Thinkpad T440s noise problem */
++static void alc_fixup_tpt440(struct hda_codec *codec,
++                           const struct hda_fixup *fix, int action)
++{
++      struct alc_spec *spec = codec->spec;
++
++      if (action == HDA_FIXUP_ACT_PRE_PROBE) {
++              spec->shutup = alc_no_shutup; /* reduce click noise */
++              spec->gen.mixer_nid = 0; /* reduce background noise */
++      }
++}
++
+ /* mute tablet speaker pin (0x14) via dock plugging in addition */
+ static void asus_tx300_automute(struct hda_codec *codec)
+ {
+@@ -3746,6 +3758,7 @@ enum {
+       ALC283_FIXUP_INT_MIC,
+       ALC290_FIXUP_MONO_SPEAKERS,
+       ALC292_FIXUP_TPT440_DOCK,
++      ALC292_FIXUP_TPT440,
+ };
+ 
+ static const struct hda_fixup alc269_fixups[] = {
+@@ -4090,6 +4103,12 @@ static const struct hda_fixup alc269_fixups[] = {
+               .chained = true,
+               .chain_id = ALC269_FIXUP_LIMIT_INT_MIC_BOOST
+       },
++      [ALC292_FIXUP_TPT440] = {
++              .type = HDA_FIXUP_FUNC,
++              .v.func = alc_fixup_tpt440,
++              .chained = true,
++              .chain_id = ALC292_FIXUP_TPT440_DOCK,
++      },
+ };
+ 
+ static const struct snd_pci_quirk alc269_fixup_tbl[] = {
+@@ -4185,7 +4204,7 @@ static const struct snd_pci_quirk alc269_fixup_tbl[] = {
+       SND_PCI_QUIRK(0x17aa, 0x21fb, "Thinkpad T430s", 
ALC269_FIXUP_LENOVO_DOCK),
+       SND_PCI_QUIRK(0x17aa, 0x2203, "Thinkpad X230 Tablet", 
ALC269_FIXUP_LENOVO_DOCK),
+       SND_PCI_QUIRK(0x17aa, 0x2208, "Thinkpad T431s", 
ALC269_FIXUP_LENOVO_DOCK),
+-      SND_PCI_QUIRK(0x17aa, 0x220c, "Thinkpad T440s", 
ALC292_FIXUP_TPT440_DOCK),
++      SND_PCI_QUIRK(0x17aa, 0x220c, "Thinkpad T440s", ALC292_FIXUP_TPT440),
+       SND_PCI_QUIRK(0x17aa, 0x220e, "Thinkpad T440p", 
ALC292_FIXUP_TPT440_DOCK),
+       SND_PCI_QUIRK(0x17aa, 0x2212, "Thinkpad", 
ALC269_FIXUP_LIMIT_INT_MIC_BOOST),
+       SND_PCI_QUIRK(0x17aa, 0x2214, "Thinkpad", 
ALC269_FIXUP_LIMIT_INT_MIC_BOOST),
+@@ -4263,6 +4282,7 @@ static const struct hda_model_fixup 
alc269_fixup_models[] = {
+       {.id = ALC269_FIXUP_DELL1_MIC_NO_PRESENCE, .name = 
"dell-headset-multi"},
+       {.id = ALC269_FIXUP_DELL2_MIC_NO_PRESENCE, .name = "dell-headset-dock"},
+       {.id = ALC292_FIXUP_TPT440_DOCK, .name = "tpt440-dock"},
++      {.id = ALC292_FIXUP_TPT440, .name = "tpt440"},
+       {}
+ };
+ 
+diff --git a/sound/pci/hda/patch_sigmatel.c b/sound/pci/hda/patch_sigmatel.c
+index 984b75ef1190..d68f6af1da2b 100644
+--- a/sound/pci/hda/patch_sigmatel.c
++++ b/sound/pci/hda/patch_sigmatel.c
+@@ -712,6 +712,7 @@ static bool hp_bnb2011_with_dock(struct hda_codec *codec)
+ static bool hp_blike_system(u32 subsystem_id)
+ {
+       switch (subsystem_id) {
++      case 0x103c1473: /* HP ProBook 6550b */
+       case 0x103c1520:
+       case 0x103c1521:
+       case 0x103c1523:
+diff --git a/tools/Makefile b/tools/Makefile
+index 41067f304215..b82a15b92b1c 100644
+--- a/tools/Makefile
++++ b/tools/Makefile
+@@ -22,6 +22,10 @@ help:
+       @echo '  from the kernel command line to build and install one of'
+       @echo '  the tools above'
+       @echo ''
++      @echo '  $$ make tools/all'
++      @echo ''
++      @echo '  builds all tools.'
++      @echo ''
+       @echo '  $$ make tools/install'
+       @echo ''
+       @echo '  installs all tools.'
+@@ -50,6 +54,10 @@ selftests: FORCE
+ turbostat x86_energy_perf_policy: FORCE
+       $(call descend,power/x86/$@)
+ 
++all: cgroup cpupower firewire lguest \
++              perf selftests turbostat usb \
++              virtio vm net x86_energy_perf_policy
++
+ cpupower_install:
+       $(call descend,power/$(@:_install=),install)
+ 

Reply via email to