Linux 4.14.221
Greg Kroah-Hartman
maintainerI'm announcing the release of the 4.14.221 kernel.
All users of the 4.14 kernel series must upgrade.
The updated 4.14.y git tree can be found at:
git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git linux-4.14.y
and can be browsed at the normal kernel.org git web browser:
https://git.kernel.org/?p=linux/kernel/git/stable/linux-stable.git;a=summary
thanks,
greg k-h
------------
Makefile | 8 ----- arch/arm/mach-footbridge/dc21285.c | 12 +++---- arch/arm64/boot/dts/freescale/fsl-ls1046a.dtsi | 2 - arch/x86/Makefile | 3 + arch/x86/include/asm/apic.h | 10 ------ arch/x86/include/asm/barrier.h | 18 +++++++++++ arch/x86/kernel/apic/apic.c | 4 ++ arch/x86/kernel/apic/x2apic_cluster.c | 6 ++- arch/x86/kernel/apic/x2apic_phys.c | 6 ++- drivers/input/joystick/xpad.c | 17 ++++++++++- drivers/input/serio/i8042-x86ia64io.h | 2 + drivers/iommu/intel-iommu.c | 6 +++ drivers/mmc/core/sdio_cis.c | 6 +++ drivers/net/dsa/mv88e6xxx/chip.c | 6 +++ drivers/nvme/host/pci.c | 2 + drivers/usb/class/usblp.c | 19 +++++++----- drivers/usb/dwc2/gadget.c | 8 ----- drivers/usb/gadget/legacy/ether.c | 4 +- drivers/usb/host/xhci-ring.c | 31 +++++++++++++------- drivers/usb/serial/cp210x.c | 2 + drivers/usb/serial/option.c | 6 +++ fs/cifs/dir.c | 22 +++++++++++++- fs/cifs/smb2pdu.h | 2 - fs/hugetlbfs/inode.c | 3 + fs/overlayfs/dir.c | 2 - include/linux/elfcore.h | 22 ++++++++++++++ include/linux/hugetlb.h | 3 + kernel/Makefile | 1 kernel/elfcore.c | 26 ----------------- kernel/kprobes.c | 4 ++ mm/huge_memory.c | 37 +++++++++++++++--------- mm/hugetlb.c | 9 ++--- net/ipv4/route.c | 38 ++++++++++++------------- net/lapb/lapb_out.c | 3 + net/mac80211/driver-ops.c | 5 ++- net/mac80211/rate.c | 3 + tools/objtool/orc_gen.c | 33 +++++++++++++++++---- 37 files changed, 254 insertions(+), 137 deletions(-)
Alexey Dobriyan (1):
Input: i8042 - unbreak Pegatron C15B
Arnd Bergmann (1):
elfcore: fix building with clang
Aurelien Aptel (1):
cifs: report error instead of invalid when revalidating a dentry fails
Benjamin Valentin (1):
Input: xpad - sync supported devices with fork on GitHub
Chenxin Jin (1):
USB: serial: cp210x: add new VID/PID for supporting Teraoka AD2000
Christoph Schemmel (1):
USB: serial: option: Adding support for Cinterion MV31
DENG Qingfang (1):
net: dsa: mv88e6xxx: override existent unicast portvec in port_fdb_add
Dan Carpenter (1):
USB: gadget: legacy: fix an error code in eth_bind()
Dave Hansen (1):
x86/apic: Add extra serialization for non-serializing MSRs
Felix Fietkau (1):
mac80211: fix station rate table updates on assoc
Fengnan Chang (1):
mmc: core: Limit retries when analyse of SDIO tuples fails
Greg Kroah-Hartman (1):
Linux 4.14.221
Gustavo A. R. Silva (1):
smb3: Fix out-of-bounds bug in SMB2_negotiate()
Heiko Stuebner (1):
usb: dwc2: Fix endpoint direction check in ep_from_windex
Hugh Dickins (1):
mm: thp: fix MADV_REMOVE deadlock on shmem THP
Jeremy Figgins (1):
USB: usblp: don't call usb_set_interface if there's a single alt
Josh Poimboeuf (2):
objtool: Support Clang non-section symbols in ORC generation x86/build: Disable CET instrumentation in the kernel
Liangyan (1):
ovl: fix dentry leak in ovl_get_redirect
Mathias Nyman (1):
xhci: fix bounce buffer usage for non-sg list case
Muchun Song (3):
mm: hugetlbfs: fix cannot migrate the fallocated HugeTLB page
mm: hugetlb: fix a race between isolating and freeing page
mm: hugetlb: remove VM_BUG_ON_PAGE from page_huge_active
Nadav Amit (1):
iommu/vt-d: Do not use flush-queue when caching-mode is on
Pho Tran (1):
USB: serial: cp210x: add pid/vid for WSDA-200-USB
Russell King (1):
ARM: footbridge: fix dc21285 PCI configuration accessors
Thorsten Leemhuis (1):
nvme-pci: avoid the deepest sleep state on Kingston A2000 SSDs
Wang ShaoBo (1):
kretprobe: Avoid re-registration of the same kretprobe earlier
Wei Wang (1):
ipv4: fix race condition between route lookup and invalidation
Xie He (1):
net: lapb: Copy the skb before sending a packet
Zyta Szpak (1):
arm64: dts: ls1046a: fix dcfg address range
Greg Kroah-Hartman
maintainerMakefile +1 -7
@@ -1,7 +1,7 @@ # SPDX-License-Identifier: GPL-2.0 VERSION = 4 PATCHLEVEL = 14 -SUBLEVEL = 220 +SUBLEVEL = 221 EXTRAVERSION = NAME = Petit Gorille
@@ -844,12 +844,6 @@ KBUILD_CFLAGS += $(call cc-option,-Werror=designated-init) # change __FILE__ to the relative path from the srctree KBUILD_CFLAGS += $(call cc-option,-fmacro-prefix-map=$(srctree)/=) -# ensure -fcf-protection is disabled when using retpoline as it is -# incompatible with -mindirect-branch=thunk-extern -ifdef CONFIG_RETPOLINE -KBUILD_CFLAGS += $(call cc-option,-fcf-protection=none) -endif - # use the deterministic mode of AR if available KBUILD_ARFLAGS := $(call ar-option,D)
arch/arm/mach-footbridge/dc21285.c +6 -6
@@ -69,15 +69,15 @@ dc21285_read_config(struct pci_bus *bus, unsigned int devfn, int where,if (addr)switch (size) {case 1 : - asm("ldrb %0, [%1, %2]" + asmvolatile ("ldrb %0, [%1, %2]" :"=r" (v) :"r" (addr),"r" (where) :"cc" );break ;case 2 : - asm("ldrh %0, [%1, %2]" + asmvolatile ("ldrh %0, [%1, %2]" :"=r" (v) :"r" (addr),"r" (where) :"cc" );break ;case 4 : - asm("ldr %0, [%1, %2]" + asmvolatile ("ldr %0, [%1, %2]" :"=r" (v) :"r" (addr),"r" (where) :"cc" );break ; }
@@ -103,17 +103,17 @@ dc21285_write_config(struct pci_bus *bus, unsigned int devfn, int where,if (addr)switch (size) {case 1 : - asm("strb %0, [%1, %2]" + asmvolatile ("strb %0, [%1, %2]" : :"r" (value),"r" (addr),"r" (where) :"cc" );break ;case 2 : - asm("strh %0, [%1, %2]" + asmvolatile ("strh %0, [%1, %2]" : :"r" (value),"r" (addr),"r" (where) :"cc" );break ;case 4 : - asm("str %0, [%1, %2]" + asmvolatile ("str %0, [%1, %2]" : :"r" (value),"r" (addr),"r" (where) :"cc" );break ;
arch/arm64/boot/dts/freescale/fsl-ls1046a.dtsi +1 -1
@@ -304,7 +304,7 @@ dcfg: dcfg@1ee0000 { compatible = "fsl,ls1046a-dcfg", "syscon"; - reg = <0x0 0x1ee0000 0x0 0x10000>; + reg = <0x0 0x1ee0000 0x0 0x1000>; big-endian; };
arch/x86/Makefile +3 -0
@@ -138,6 +138,9 @@ else KBUILD_CFLAGS += -mno-red-zone KBUILD_CFLAGS += -mcmodel=kernel + # Intel CET isn't enabled in the kernel + KBUILD_CFLAGS += $(call cc-option,-fcf-protection=none) + # -funit-at-a-time shrinks the kernel .text considerably # unfortunately it makes reading oopses harder. KBUILD_CFLAGS += $(call cc-option,-funit-at-a-time)
arch/x86/include/asm/apic.h +0 -10
@@ -174,16 +174,6 @@ static inline void lapic_update_tsc_freq(void) { }#endif /* !CONFIG_X86_LOCAL_APIC */ #ifdef CONFIG_X86_X2APIC -/* -* Make previous memory operations globally visible before -* sending the IPI through x2apic wrmsr. We need a serializing instruction or -* mfence for this. -*/ -static inline void x2apic_wrmsr_fence (void ) -{ - asmvolatile ("mfence" : : :"memory" ); -} -static inline void native_apic_msr_write (u32 reg,u32 v) { if (reg == APIC_DFR || reg == APIC_ID || reg == APIC_LDR ||
arch/x86/include/asm/barrier.h +18 -0
@@ -111,4 +111,22 @@ do { \#include <asm-generic/barrier.h> +/* +* Make previous memory operations globally visible before +* a WRMSR. +* +* MFENCE makes writes visible, but only affects load/store +* instructions. WRMSR is unfortunately not a load/store +* instruction and is unaffected by MFENCE. The LFENCE ensures +* that the WRMSR is not reordered. +* +* Most WRMSRs are full serializing instructions themselves and +* do not require this barrier. This is only required for the +* IA32_TSC_DEADLINE and X2APIC MSRs. +*/ +static inline void weak_wrmsr_fence (void ) +{ + asmvolatile ("mfence; lfence" : : :"memory" ); +} +#endif /* _ASM_X86_BARRIER_H */
arch/x86/kernel/apic/apic.c +4 -0
@@ -42,6 +42,7 @@#include <asm/x86_init.h> #include <asm/pgalloc.h> #include <linux/atomic.h> +#include <asm/barrier.h> #include <asm/mpspec.h> #include <asm/i8259.h> #include <asm/proto.h>
@@ -473,6 +474,9 @@ static int lapic_next_deadline(unsigned long delta, {u64 tsc; +/* This MSR is special and need a special fence: */ +weak_wrmsr_fence (); + tsc =rdtsc ();wrmsrl (MSR_IA32_TSC_DEADLINE , tsc + (((u64 ) delta) *TSC_DIVISOR ));return 0 ;
arch/x86/kernel/apic/x2apic_cluster.c +4 -2
@@ -29,7 +29,8 @@ static void x2apic_send_IPI(int cpu, int vector) {u32 dest =per_cpu (x86_cpu_to_logical_apicid, cpu); -x2apic_wrmsr_fence (); +/* x2apic MSRs are special and need a special fence: */ +weak_wrmsr_fence ();__x2apic_send_IPI_dest (dest, vector,APIC_DEST_LOGICAL ); }
@@ -42,7 +43,8 @@ __x2apic_send_IPI_mask(const struct cpumask *mask, int vector, int apic_dest)unsigned long flags;u32 dest; -x2apic_wrmsr_fence (); +/* x2apic MSRs are special and need a special fence: */ +weak_wrmsr_fence ();local_irq_save (flags);
arch/x86/kernel/apic/x2apic_phys.c +4 -2
@@ -41,7 +41,8 @@ static void x2apic_send_IPI(int cpu, int vector) {u32 dest =per_cpu (x86_cpu_to_apicid, cpu); -x2apic_wrmsr_fence (); +/* x2apic MSRs are special and need a special fence: */ +weak_wrmsr_fence ();__x2apic_send_IPI_dest (dest, vector,APIC_DEST_PHYSICAL ); }
@@ -52,7 +53,8 @@ __x2apic_send_IPI_mask(const struct cpumask *mask, int vector, int apic_dest)unsigned long this_cpu;unsigned long flags; -x2apic_wrmsr_fence (); +/* x2apic MSRs are special and need a special fence: */ +weak_wrmsr_fence ();local_irq_save (flags);
drivers/input/joystick/xpad.c +16 -1
@@ -232,9 +232,17 @@ static const struct xpad_device { { 0x0e6f, 0x0213, "Afterglow Gamepad for Xbox 360", 0, XTYPE_XBOX360 }, { 0x0e6f, 0x021f, "Rock Candy Gamepad for Xbox 360", 0, XTYPE_XBOX360 }, { 0x0e6f, 0x0246, "Rock Candy Gamepad for Xbox One 2015", 0, XTYPE_XBOXONE }, - { 0x0e6f, 0x02ab, "PDP Controller for Xbox One", 0, XTYPE_XBOXONE }, + { 0x0e6f, 0x02a0, "PDP Xbox One Controller", 0, XTYPE_XBOXONE }, + { 0x0e6f, 0x02a1, "PDP Xbox One Controller", 0, XTYPE_XBOXONE }, + { 0x0e6f, 0x02a2, "PDP Wired Controller for Xbox One - Crimson Red", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x02a4, "PDP Wired Controller for Xbox One - Stealth Series", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x02a6, "PDP Wired Controller for Xbox One - Camo Series", 0, XTYPE_XBOXONE }, + { 0x0e6f, 0x02a7, "PDP Xbox One Controller", 0, XTYPE_XBOXONE }, + { 0x0e6f, 0x02a8, "PDP Xbox One Controller", 0, XTYPE_XBOXONE }, + { 0x0e6f, 0x02ab, "PDP Controller for Xbox One", 0, XTYPE_XBOXONE }, + { 0x0e6f, 0x02ad, "PDP Wired Controller for Xbox One - Stealth Series", 0, XTYPE_XBOXONE }, + { 0x0e6f, 0x02b3, "Afterglow Prismatic Wired Controller", 0, XTYPE_XBOXONE }, + { 0x0e6f, 0x02b8, "Afterglow Prismatic Wired Controller", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x0301, "Logic3 Controller", 0, XTYPE_XBOX360 }, { 0x0e6f, 0x0346, "Rock Candy Gamepad for Xbox One 2016", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x0401, "Logic3 Controller", 0, XTYPE_XBOX360 },
@@ -313,6 +321,9 @@ static const struct xpad_device { { 0x1bad, 0xfa01, "MadCatz GamePad", 0, XTYPE_XBOX360 }, { 0x1bad, 0xfd00, "Razer Onza TE", 0, XTYPE_XBOX360 }, { 0x1bad, 0xfd01, "Razer Onza", 0, XTYPE_XBOX360 }, + { 0x20d6, 0x2001, "BDA Xbox Series X Wired Controller", 0, XTYPE_XBOXONE }, + { 0x20d6, 0x281f, "PowerA Wired Controller For Xbox 360", 0, XTYPE_XBOX360 }, + { 0x2e24, 0x0652, "Hyperkin Duke X-Box One pad", 0, XTYPE_XBOXONE }, { 0x24c6, 0x5000, "Razer Atrox Arcade Stick", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x24c6, 0x5300, "PowerA MINI PROEX Controller", 0, XTYPE_XBOX360 }, { 0x24c6, 0x5303, "Xbox Airflo wired controller", 0, XTYPE_XBOX360 },
@@ -446,8 +457,12 @@ static const struct usb_device_id xpad_table[] = {XPAD_XBOX360_VENDOR (0x162e ),/* Joytech X-Box 360 controllers */ XPAD_XBOX360_VENDOR (0x1689 ),/* Razer Onza */ XPAD_XBOX360_VENDOR (0x1bad ),/* Harminix Rock Band Guitar and Drums */ +XPAD_XBOX360_VENDOR (0x20d6 ),/* PowerA Controllers */ +XPAD_XBOXONE_VENDOR (0x20d6 ),/* PowerA Controllers */ XPAD_XBOX360_VENDOR (0x24c6 ),/* PowerA Controllers */ XPAD_XBOXONE_VENDOR (0x24c6 ),/* PowerA Controllers */ +XPAD_XBOXONE_VENDOR (0x2e24 ),/* Hyperkin Duke X-Box One pad */ + XPAD_XBOX360_VENDOR(0x2f24), /* GameSir Controllers */ { } };
drivers/input/serio/i8042-x86ia64io.h +2 -0
@@ -223,6 +223,8 @@ static const struct dmi_system_id __initconst i8042_dmi_noloop_table[] = {DMI_MATCH (DMI_SYS_VENDOR ,"PEGATRON CORPORATION" ), DMI_MATCH(DMI_PRODUCT_NAME, "C15B"), }, + }, + { .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"ByteSpeed LLC" ), DMI_MATCH(DMI_PRODUCT_NAME, "ByteSpeed Laptop C15B"),
drivers/iommu/intel-iommu.c +6 -0
@@ -3338,6 +3338,12 @@ static int __init init_dmars(void)if (!ecap_pass_through (iommu->ecap)) hw_pass_through =0 ; + +if (!intel_iommu_strict &&cap_caching_mode (iommu->cap)) { +pr_info ("Disable batched IOTLB flush due to virtualization" ); + intel_iommu_strict =1 ; + } +#ifdef CONFIG_INTEL_IOMMU_SVM if (pasid_enabled (iommu))intel_svm_alloc_pasid_tables (iommu);
drivers/mmc/core/sdio_cis.c +6 -0
@@ -24,6 +24,8 @@#include "sdio_cis.h" #include "sdio_ops.h" +#define SDIO_READ_CIS_TIMEOUT_MS (10 * 1000)/* 10s */ +static int cistpl_vers_1 (struct mmc_card *card,struct sdio_func *func,const unsigned char *buf,unsigned size) {
@@ -270,6 +272,8 @@ static int sdio_read_cis(struct mmc_card *card, struct sdio_func *func) do { unsigned char tpl_code, tpl_link; + unsigned long timeout = jiffies + + msecs_to_jiffies(SDIO_READ_CIS_TIMEOUT_MS); ret = mmc_io_rw_direct(card, 0, 0, ptr++, 0, &tpl_code); if (ret)
@@ -322,6 +326,8 @@ static int sdio_read_cis(struct mmc_card *card, struct sdio_func *func) prev = &this->next;if (ret == -ENOENT ) { +if (time_after (jiffies, timeout)) +break ;/* warn about unknown tuples */ pr_warn_ratelimited("%s: queuing unknown" " CIS tuple 0x%02x (%u bytes)\n",
drivers/net/dsa/mv88e6xxx/chip.c +5 -1
@@ -1364,7 +1364,11 @@ static int mv88e6xxx_port_db_load_purge(struct mv88e6xxx_chip *chip, int port,if (!entry.portvec) entry.state =MV88E6XXX_G1_ATU_DATA_STATE_UNUSED ; }else { - entry.portvec |=BIT (port); +if (state ==MV88E6XXX_G1_ATU_DATA_STATE_UC_STATIC ) + entry.portvec =BIT (port); +else + entry.portvec |=BIT (port); + entry.state = state; }
drivers/nvme/host/pci.c +2 -0
@@ -2588,6 +2588,8 @@ static const struct pci_device_id nvme_id_table[] = { { PCI_DEVICE(0x1d1d, 0x2601), /* CNEX Granby */ .driver_data = NVME_QUIRK_LIGHTNVM, }, { PCI_DEVICE_CLASS(PCI_CLASS_STORAGE_EXPRESS, 0xffffff) }, + { PCI_DEVICE(0x2646, 0x2263), /* KINGSTON A2000 NVMe SSD */ + .driver_data = NVME_QUIRK_NO_DEEPEST_PS, }, { PCI_DEVICE(PCI_VENDOR_ID_APPLE, 0x2001) }, { PCI_DEVICE(PCI_VENDOR_ID_APPLE, 0x2003) }, { 0, }
drivers/usb/class/usblp.c +11 -8
@@ -1340,14 +1340,17 @@ static int usblp_set_protocol(struct usblp *usblp, int protocol)if (protocol <USBLP_FIRST_PROTOCOL || protocol >USBLP_LAST_PROTOCOL )return -EINVAL ; - alts = usblp->protocol[protocol].alt_setting; -if (alts <0 ) -return -EINVAL ; - r =usb_set_interface (usblp->dev, usblp->ifnum, alts); -if (r <0 ) { -printk (KERN_ERR "usblp: can't set desired altsetting %d on interface %d\n" , - alts, usblp->ifnum); -return r; +/* Don't unnecessarily set the interface if there's a single alt. */ +if (usblp->intf->num_altsetting >1 ) { + alts = usblp->protocol[protocol].alt_setting; +if (alts <0 ) +return -EINVAL ; + r =usb_set_interface (usblp->dev, usblp->ifnum, alts); +if (r <0 ) { +printk (KERN_ERR "usblp: can't set desired altsetting %d on interface %d\n" , + alts, usblp->ifnum); +return r; + } } usblp->bidir = (usblp->protocol[protocol].epread !=NULL );
drivers/usb/dwc2/gadget.c +1 -7
@@ -1470,7 +1470,6 @@ static void dwc2_hsotg_complete_oursetup(struct usb_ep *ep,static struct dwc2_hsotg_ep *ep_from_windex (struct dwc2_hsotg *hsotg,u32 windex) { -struct dwc2_hsotg_ep *ep;int dir = (windex &USB_DIR_IN ) ?1 :0 ;int idx = windex &0x7F ;
@@ -1480,12 +1479,7 @@ static struct dwc2_hsotg_ep *ep_from_windex(struct dwc2_hsotg *hsotg,if (idx > hsotg->num_of_eps)return NULL ; - ep =index_to_ep (hsotg, idx, dir); - -if (idx && ep->dir_in != dir) -return NULL ; - -return ep; +return index_to_ep (hsotg, idx, dir); }/**
drivers/usb/gadget/legacy/ether.c +3 -1
@@ -407,8 +407,10 @@ static int eth_bind(struct usb_composite_dev *cdev)struct usb_descriptor_header *usb_desc; usb_desc =usb_otg_descriptor_alloc (gadget); -if (!usb_desc) +if (!usb_desc) { + status = -ENOMEM ; goto fail1; + }usb_otg_descriptor_init (gadget, usb_desc); otg_desc[0 ] = usb_desc; otg_desc[1 ] =NULL ;
drivers/usb/host/xhci-ring.c +20 -11
@@ -681,11 +681,16 @@ static void xhci_unmap_td_bounce_buffer(struct xhci_hcd *xhci,dma_unmap_single (dev, seg->bounce_dma, ring->bounce_buf_len,DMA_FROM_DEVICE );/* for in tranfers we need to copy the data from bounce to sg */ - len =sg_pcopy_from_buffer (urb->sg, urb->num_sgs, seg->bounce_buf, - seg->bounce_len, seg->bounce_offs); -if (len != seg->bounce_len) -xhci_warn (xhci,"WARN Wrong bounce buffer read length: %zu != %d\n" , - len, seg->bounce_len); +if (urb->num_sgs) { + len =sg_pcopy_from_buffer (urb->sg, urb->num_sgs, seg->bounce_buf, + seg->bounce_len, seg->bounce_offs); +if (len != seg->bounce_len) +xhci_warn (xhci,"WARN Wrong bounce buffer read length: %zu != %d\n" , + len, seg->bounce_len); + }else { +memcpy (urb->transfer_buffer + seg->bounce_offs, seg->bounce_buf, + seg->bounce_len); + } seg->bounce_len =0 ; seg->bounce_offs =0 ; }
@@ -3252,12 +3257,16 @@ static int xhci_align_td(struct xhci_hcd *xhci, struct urb *urb, u32 enqd_len,/* create a max max_pkt sized bounce buffer pointed to by last trb */ if (usb_urb_dir_out (urb)) { - len =sg_pcopy_to_buffer (urb->sg, urb->num_sgs, - seg->bounce_buf, new_buff_len, enqd_len); -if (len != new_buff_len) -xhci_warn (xhci, -"WARN Wrong bounce buffer write length: %zu != %d\n" , - len, new_buff_len); +if (urb->num_sgs) { + len =sg_pcopy_to_buffer (urb->sg, urb->num_sgs, + seg->bounce_buf, new_buff_len, enqd_len); +if (len != new_buff_len) +xhci_warn (xhci,"WARN Wrong bounce buffer write length: %zu != %d\n" , + len, new_buff_len); + }else { +memcpy (seg->bounce_buf, urb->transfer_buffer + enqd_len, new_buff_len); + } + seg->bounce_dma =dma_map_single (dev, seg->bounce_buf, max_pkt,DMA_TO_DEVICE ); }else {
drivers/usb/serial/cp210x.c +2 -0
@@ -64,6 +64,7 @@ static const struct usb_device_id id_table[] = { { USB_DEVICE(0x08e6, 0x5501) }, /* Gemalto Prox-PU/CU contactless smartcard reader */ { USB_DEVICE(0x08FD, 0x000A) }, /* Digianswer A/S , ZigBee/802.15.4 MAC Device */ { USB_DEVICE(0x0908, 0x01FF) }, /* Siemens RUGGEDCOM USB Serial Console */ + { USB_DEVICE(0x0988, 0x0578) }, /* Teraoka AD2000 */ { USB_DEVICE(0x0B00, 0x3070) }, /* Ingenico 3070 */ { USB_DEVICE(0x0BED, 0x1100) }, /* MEI (TM) Cashflow-SC Bill/Voucher Acceptor */ { USB_DEVICE(0x0BED, 0x1101) }, /* MEI series 2000 Combo Acceptor */
@@ -204,6 +205,7 @@ static const struct usb_device_id id_table[] = { { USB_DEVICE(0x1901, 0x0194) }, /* GE Healthcare Remote Alarm Box */ { USB_DEVICE(0x1901, 0x0195) }, /* GE B850/B650/B450 CP2104 DP UART interface */ { USB_DEVICE(0x1901, 0x0196) }, /* GE B850 CP2105 DP UART interface */ + { USB_DEVICE(0x199B, 0xBA30) }, /* LORD WSDA-200-USB */ { USB_DEVICE(0x19CF, 0x3000) }, /* Parrot NMEA GPS Flight Recorder */ { USB_DEVICE(0x1ADB, 0x0001) }, /* Schweitzer Engineering C662 Cable */ { USB_DEVICE(0x1B1C, 0x1C00) }, /* Corsair USB Dongle */
drivers/usb/serial/option.c +6 -0
@@ -428,6 +428,8 @@ static void option_instat_callback(struct urb *urb);#define CINTERION_PRODUCT_AHXX_2RMNET 0x0084#define CINTERION_PRODUCT_AHXX_AUDIO 0x0085#define CINTERION_PRODUCT_CLS8 0x00b0 +#define CINTERION_PRODUCT_MV31_MBIM 0x00b3 +#define CINTERION_PRODUCT_MV31_RMNET 0x00b7/* Olivetti products */ #define OLIVETTI_VENDOR_ID 0x0b3c
@@ -1917,6 +1919,10 @@ static const struct usb_device_id option_ids[] = { { USB_DEVICE(SIEMENS_VENDOR_ID, CINTERION_PRODUCT_HC25_MDMNET) }, { USB_DEVICE(SIEMENS_VENDOR_ID, CINTERION_PRODUCT_HC28_MDM) }, /* HC28 enumerates with Siemens or Cinterion VID depending on FW revision */ { USB_DEVICE(SIEMENS_VENDOR_ID, CINTERION_PRODUCT_HC28_MDMNET) }, + { USB_DEVICE_INTERFACE_CLASS(CINTERION_VENDOR_ID, CINTERION_PRODUCT_MV31_MBIM, 0xff), + .driver_info = RSVD(3)}, + { USB_DEVICE_INTERFACE_CLASS(CINTERION_VENDOR_ID, CINTERION_PRODUCT_MV31_RMNET, 0xff), + .driver_info = RSVD(0)}, { USB_DEVICE(OLIVETTI_VENDOR_ID, OLIVETTI_PRODUCT_OLICARD100), .driver_info = RSVD(4) }, { USB_DEVICE(OLIVETTI_VENDOR_ID, OLIVETTI_PRODUCT_OLICARD120),
fs/cifs/dir.c +20 -2
@@ -841,6 +841,7 @@ static int cifs_d_revalidate(struct dentry *direntry, unsigned int flags) {struct inode *inode; +int rc;if (flags &LOOKUP_RCU )return -ECHILD ;
@@ -850,8 +851,25 @@ cifs_d_revalidate(struct dentry *direntry, unsigned int flags)if ((flags &LOOKUP_REVAL ) && !CIFS_CACHE_READ (CIFS_I (inode)))CIFS_I (inode)->time =0 ;/* force reval */ -if (cifs_revalidate_dentry (direntry)) -return 0 ; + rc =cifs_revalidate_dentry (direntry); +if (rc) { +cifs_dbg (FYI ,"cifs_revalidate_dentry failed with rc=%d" , rc); +switch (rc) { +case -ENOENT : +case -ESTALE : +/* +* Those errors mean the dentry is invalid +* (file was deleted or recreated) +*/ +return 0 ; +default : +/* +* Otherwise some unexpected error happened +* report it as-is to VFS layer +*/ +return rc; + } + }else {/* * If the inode wasn't known to be a dfs entry when
fs/cifs/smb2pdu.h +1 -1
@@ -206,7 +206,7 @@ struct smb2_negotiate_req {__le32 NegotiateContextOffset;/* SMB3.1.1 only. MBZ earlier */ __le16 NegotiateContextCount;/* SMB3.1.1 only. MBZ earlier */ __le16 Reserved2; -__le16 Dialects[1 ];/* One dialect (vers=) at a time for now */ +__le16 Dialects[4 ];/* BB expand this if autonegotiate > 4 dialects */ } __packed;/* Dialects */
fs/hugetlbfs/inode.c +2 -1
@@ -649,8 +649,9 @@ static long hugetlbfs_fallocate(struct file *file, int mode, loff_t offset,mutex_unlock (&hugetlb_fault_mutex_table[hash]); +set_page_huge_active (page);/* -* page_put due to reference from alloc_huge_page() +* put_page() due to reference from alloc_huge_page() * unlock_page because locked by add_to_page_cache() */ put_page (page);
fs/overlayfs/dir.c +1 -1
@@ -850,8 +850,8 @@ static char *ovl_get_redirect(struct dentry *dentry, bool samedir) buflen -= thislen;memcpy (&buf[buflen], name, thislen); - tmp =dget_dlock (d->d_parent);spin_unlock (&d->d_lock); + tmp =dget_parent (d);dput (d); d = tmp;
include/linux/elfcore.h +22 -0
@@ -58,6 +58,7 @@ static inline int elf_core_copy_task_xfpregs(struct task_struct *t, elf_fpxregse }#endif +#if defined(CONFIG_UM ) || defined(CONFIG_IA64 )/* * These functions parameterize elf_core_dump in fs/binfmt_elf.c to write out * extra segments containing the gate DSO contents. Dumping its
@@ -72,5 +73,26 @@ elf_core_write_extra_phdrs(struct coredump_params *cprm, loff_t offset);extern int elf_core_write_extra_data (struct coredump_params *cprm);extern size_t elf_core_extra_data_size (void ); +#else +static inline Elf_Half elf_core_extra_phdrs (void ) +{ +return 0 ; +} + +static inline int elf_core_write_extra_phdrs (struct coredump_params *cprm,loff_t offset) +{ +return 1 ; +} + +static inline int elf_core_write_extra_data (struct coredump_params *cprm) +{ +return 1 ; +} + +static inline size_t elf_core_extra_data_size (void ) +{ +return 0 ; +} +#endif #endif /* _LINUX_ELFCORE_H */
include/linux/hugetlb.h +3 -0
@@ -531,6 +531,9 @@ static inline void set_huge_swap_pte_at(struct mm_struct *mm, unsigned long addr set_huge_pte_at(mm, addr, ptep, pte); }#endif + +void set_page_huge_active (struct page *page); +#else /* CONFIG_HUGETLB_PAGE */ struct hstate {};#define alloc_huge_page (v, a, r) NULL
kernel/Makefile +0 -1
@@ -90,7 +90,6 @@ obj-$(CONFIG_TASK_DELAY_ACCT) += delayacct.o obj-$(CONFIG_TASKSTATS) += taskstats.o tsacct.o obj-$(CONFIG_TRACEPOINTS) += tracepoint.o obj-$(CONFIG_LATENCYTOP) += latencytop.o -obj-$(CONFIG_ELFCORE) += elfcore.o obj-$(CONFIG_FUNCTION_TRACER) += trace/ obj-$(CONFIG_TRACING) += trace/ obj-$(CONFIG_TRACE_CLOCK) += trace/
kernel/elfcore.c deleted +0 -26
@@ -1,26 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0 -#include <linux/elf.h> -#include <linux/fs.h> -#include <linux/mm.h> -#include <linux/binfmts.h> -#include <linux/elfcore.h> - -Elf_Half __weak elf_core_extra_phdrs (void ) -{ -return 0 ; -} - -int __weak elf_core_write_extra_phdrs (struct coredump_params *cprm,loff_t offset) -{ -return 1 ; -} - -int __weak elf_core_write_extra_data (struct coredump_params *cprm) -{ -return 1 ; -} - -size_t __weak elf_core_extra_data_size (void ) -{ -return 0 ; -}
kernel/kprobes.c +4 -0
@@ -1989,6 +1989,10 @@ int register_kretprobe(struct kretprobe *rp)if (!kprobe_on_func_entry (rp->kp.addr, rp->kp.symbol_name, rp->kp.offset))return -EINVAL ; +/* If only rp->kp.addr is specified, check reregistering kprobes */ +if (rp->kp.addr &&check_kprobe_rereg (&rp->kp)) +return -EINVAL ; +if (kretprobe_blacklist_size) { addr =kprobe_addr (&rp->kp);if (IS_ERR (addr))
mm/huge_memory.c +23 -14
@@ -2198,7 +2198,7 @@ void __split_huge_pmd(struct vm_area_struct *vma, pmd_t *pmd,spinlock_t *ptl;struct mm_struct *mm = vma->vm_mm;unsigned long haddr = address &HPAGE_PMD_MASK ; -bool was_locked = false; +bool do_unlock_page = false;pmd_t _pmd;mmu_notifier_invalidate_range_start (mm, haddr, haddr +HPAGE_PMD_SIZE );
@@ -2211,7 +2211,6 @@ void __split_huge_pmd(struct vm_area_struct *vma, pmd_t *pmd,VM_BUG_ON (freeze && !page);if (page) {VM_WARN_ON_ONCE (!PageLocked (page)); - was_locked = true;if (page !=pmd_page (*pmd)) goto out; }
@@ -2220,19 +2219,29 @@ void __split_huge_pmd(struct vm_area_struct *vma, pmd_t *pmd,if (pmd_trans_huge (*pmd)) {if (!page) { page =pmd_page (*pmd); -if (unlikely (!trylock_page (page))) { -get_page (page); - _pmd = *pmd; -spin_unlock (ptl); -lock_page (page); -spin_lock (ptl); -if (unlikely (!pmd_same (*pmd, _pmd))) { -unlock_page (page); +/* +* An anonymous page must be locked, to ensure that a +* concurrent reuse_swap_page() sees stable mapcount; +* but reuse_swap_page() is not used on shmem or file, +* and page lock must not be taken when zap_pmd_range() +* calls __split_huge_pmd() while i_mmap_lock is held. +*/ +if (PageAnon (page)) { +if (unlikely (!trylock_page (page))) { +get_page (page); + _pmd = *pmd; +spin_unlock (ptl); +lock_page (page); +spin_lock (ptl); +if (unlikely (!pmd_same (*pmd, _pmd))) { +unlock_page (page); +put_page (page); + page =NULL ; + goto repeat; + }put_page (page); - page =NULL ; - goto repeat; } -put_page (page); + do_unlock_page = true; } }if (PageMlocked (page))
@@ -2242,7 +2251,7 @@ void __split_huge_pmd(struct vm_area_struct *vma, pmd_t *pmd,__split_huge_pmd_locked (vma, pmd, haddr, freeze); out:spin_unlock (ptl); -if (!was_locked && page) +if (do_unlock_page)unlock_page (page);mmu_notifier_invalidate_range_end (mm, haddr, haddr +HPAGE_PMD_SIZE ); }
mm/hugetlb.c +4 -5
@@ -1233,12 +1233,11 @@ struct hstate *size_to_hstate(unsigned long size)*/ bool page_huge_active (struct page *page) { -VM_BUG_ON_PAGE (!PageHuge (page), page); -return PageHead (page) &&PagePrivate (&page[1 ]); +return PageHeadHuge (page) &&PagePrivate (&page[1 ]); }/* never called for tail page */ -static void set_page_huge_active (struct page *page) +void set_page_huge_active (struct page *page) {VM_BUG_ON_PAGE (!PageHeadHuge (page), page);SetPagePrivate (&page[1 ]);
@@ -4865,9 +4864,9 @@ bool isolate_huge_page(struct page *page, struct list_head *list) {bool ret = true; -VM_BUG_ON_PAGE (!PageHead (page), page);spin_lock (&hugetlb_lock); -if (!page_huge_active (page) || !get_page_unless_zero (page)) { +if (!PageHeadHuge (page) || !page_huge_active (page) || + !get_page_unless_zero (page)) { ret = false; goto unlock; }
net/ipv4/route.c +19 -19
@@ -1437,6 +1437,24 @@ static bool rt_bind_exception(struct rtable *rt, struct fib_nh_exception *fnhe,return ret; } +struct uncached_list { +spinlock_t lock; +struct list_head head; +}; + +static DEFINE_PER_CPU_ALIGNED(struct uncached_list, rt_uncached_list); + +static void rt_add_uncached_list (struct rtable *rt) +{ +struct uncached_list *ul =raw_cpu_ptr (&rt_uncached_list); + + rt->rt_uncached_list = ul; + +spin_lock_bh (&ul->lock); +list_add_tail (&rt->rt_uncached, &ul->head); +spin_unlock_bh (&ul->lock); +} +static bool rt_cache_route (struct fib_nh *nh,struct rtable *rt) {struct rtable *orig, *prev, **p;
@@ -1456,7 +1474,7 @@ static bool rt_cache_route(struct fib_nh *nh, struct rtable *rt) prev =cmpxchg (p, orig, rt);if (prev == orig) {if (orig) { -dst_dev_put (&orig->dst); +rt_add_uncached_list (orig);dst_release (&orig->dst); } }else {
@@ -1467,24 +1485,6 @@ static bool rt_cache_route(struct fib_nh *nh, struct rtable *rt)return ret; } -struct uncached_list { -spinlock_t lock; -struct list_head head; -}; - -static DEFINE_PER_CPU_ALIGNED(struct uncached_list, rt_uncached_list); - -static void rt_add_uncached_list (struct rtable *rt) -{ -struct uncached_list *ul =raw_cpu_ptr (&rt_uncached_list); - - rt->rt_uncached_list = ul; - -spin_lock_bh (&ul->lock); -list_add_tail (&rt->rt_uncached, &ul->head); -spin_unlock_bh (&ul->lock); -} -static void ipv4_dst_destroy (struct dst_entry *dst) {struct dst_metrics *p = (struct dst_metrics *)DST_METRICS_PTR (dst);
net/lapb/lapb_out.c +2 -1
@@ -87,7 +87,8 @@ void lapb_kick(struct lapb_cb *lapb) skb =skb_dequeue (&lapb->write_queue); do { - if ((skbn = skb_clone(skb, GFP_ATOMIC)) == NULL) { + skbn = skb_copy(skb, GFP_ATOMIC); + if (!skbn) { skb_queue_head(&lapb->write_queue, skb); break; }
net/mac80211/driver-ops.c +4 -1
@@ -128,8 +128,11 @@ int drv_sta_state(struct ieee80211_local *local, }else if (old_state ==IEEE80211_STA_AUTH && new_state ==IEEE80211_STA_ASSOC ) { ret =drv_sta_add (local, sdata, &sta->sta); -if (ret ==0 ) +if (ret ==0 ) { sta->uploaded = true; +if (rcu_access_pointer (sta->sta.rates)) +drv_sta_rate_tbl_update (local, sdata, &sta->sta); + } }else if (old_state ==IEEE80211_STA_ASSOC && new_state ==IEEE80211_STA_AUTH ) {drv_sta_remove (local, sdata, &sta->sta);
net/mac80211/rate.c +2 -1
@@ -941,7 +941,8 @@ int rate_control_set_rates(struct ieee80211_hw *hw,if (old)kfree_rcu (old, rcu_head); -drv_sta_rate_tbl_update (hw_to_local (hw), sta->sdata, pubsta); +if (sta->uploaded) +drv_sta_rate_tbl_update (hw_to_local (hw), sta->sdata, pubsta);ieee80211_sta_set_expected_throughput (pubsta,sta_get_expected_throughput (sta));
tools/objtool/orc_gen.c +26 -7
@@ -98,11 +98,6 @@ static int create_orc_entry(struct section *u_sec, struct section *ip_relasec,struct orc_entry *orc;struct rela *rela; -if (!insn_sec->sym) { -WARN ("missing symbol for section %s" , insn_sec->name); -return -1 ; - } -/* populate ORC data */ orc = (struct orc_entry *)u_sec->data->d_buf + idx;memcpy (orc, o,sizeof (*orc));
@@ -115,8 +110,32 @@ static int create_orc_entry(struct section *u_sec, struct section *ip_relasec, }memset (rela,0 ,sizeof (*rela)); - rela->sym = insn_sec->sym; - rela->addend = insn_off; +if (insn_sec->sym) { + rela->sym = insn_sec->sym; + rela->addend = insn_off; + }else { +/* +* The Clang assembler doesn't produce section symbols, so we +* have to reference the function symbol instead: +*/ + rela->sym =find_symbol_containing (insn_sec, insn_off); +if (!rela->sym) { +/* +* Hack alert. This happens when we need to reference +* the NOP pad insn immediately after the function. +*/ + rela->sym =find_symbol_containing (insn_sec, + insn_off -1 ); + } +if (!rela->sym) { +WARN ("missing symbol for insn at offset 0x%lx\n" , + insn_off); +return -1 ; + } + + rela->addend = insn_off - rela->sym->offset; + } + rela->type =R_X86_64_PC32 ; rela->offset = idx *sizeof (int );