Linux 4.14.205
Greg Kroah-Hartman
maintainerI'm announcing the release of the 4.14.205 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 | 2 - arch/arc/kernel/entry.S | 16 +++++--- arch/arc/kernel/stacktrace.c | 7 +++ arch/arm/boot/dts/sun4i-a10.dtsi | 2 - arch/arm64/boot/dts/marvell/armada-3720-espressobin.dts | 4 ++ arch/x86/kernel/kexec-bzimage64.c | 3 - block/blk-cgroup.c | 15 ++++++- drivers/acpi/nfit/core.c | 2 - drivers/base/dd.c | 7 ++- drivers/gpu/drm/i915/i915_gpu_error.c | 3 + drivers/gpu/drm/vc4/vc4_drv.c | 1 drivers/net/ethernet/freescale/gianfar.c | 14 +------ drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 32 +++++++++++++--- drivers/net/phy/sfp.c | 3 + drivers/net/usb/qmi_wwan.c | 1 drivers/of/of_reserved_mem.c | 13 +++++- drivers/scsi/scsi_scan.c | 7 ++- drivers/tty/serial/8250/8250_mtk.c | 2 - drivers/tty/serial/serial_txx9.c | 3 + drivers/tty/vt/vt.c | 24 +----------- drivers/usb/core/quirks.c | 3 + drivers/usb/mtu3/mtu3_gadget.c | 1 drivers/usb/serial/cyberjack.c | 7 +++ drivers/usb/serial/option.c | 10 +++++ drivers/xen/events/events_base.c | 29 ++++++++++---- fs/gfs2/glock.c | 3 + include/asm-generic/pgtable.h | 4 -- include/linux/mm.h | 9 ++++ kernel/fork.c | 10 ++--- kernel/futex.c | 16 +++++++- kernel/kthread.c | 3 + kernel/trace/blktrace.c | 24 +++++++----- kernel/trace/trace.c | 2 - kernel/trace/trace.h | 26 +++++++++++-- kernel/trace/trace_selftest.c | 9 +++- lib/crc32test.c | 4 -- lib/fonts/font_10x18.c | 2 - lib/fonts/font_6x10.c | 2 - lib/fonts/font_6x11.c | 2 - lib/fonts/font_7x14.c | 2 - lib/fonts/font_8x16.c | 2 - lib/fonts/font_8x8.c | 2 - lib/fonts/font_acorn_8x8.c | 2 - lib/fonts/font_mini_4x6.c | 2 - lib/fonts/font_pearl_8x8.c | 2 - lib/fonts/font_sun12x22.c | 2 - lib/fonts/font_sun8x16.c | 2 - net/sctp/sm_sideeffect.c | 4 +- net/tipc/core.c | 5 ++ net/vmw_vsock/af_vsock.c | 2 - sound/usb/pcm.c | 1 51 files changed, 239 insertions(+), 116 deletions(-)
Alan Stern (1):
USB: Add NO_LPM quirk for Kingston flash drive
Alexander Aring (1):
gfs2: Wake up when sd_glock_disposal becomes zero
Chris Wilson (1):
drm/i915: Break up error capture compression loops with cond_resched()
Christophe JAILLET (1):
i40e: Fix a potential NULL pointer dereference
Claire Chang (1):
serial: 8250_mtk: Fix uart_get_baud_rate warning
Claudiu Manoil (2):
gianfar: Replace skb_realloc_headroom with skb_cow_head for PTP
gianfar: Account for Tx PTP timestamp in the skb headroom
Clément Péron (1):
ARM: dts: sun4i-a10: fix cpu_alert temperature
Daniel Vetter (1):
vt: Disable KD_FONT_OP_COPY
Daniele Palmas (3):
net: usb: qmi_wwan: add Telit LE910Cx 0x1230 composition
USB: serial: option: add LE910Cx compositions 0x1203, 0x1230, 0x1231
USB: serial: option: add Telit FN980 composition 0x1055Eddy Wu (1):
fork: fix copy_process(CLONE_PARENT) race with the exiting ->real_parent
Gabriel Krisman Bertazi (2):
blk-cgroup: Fix memleak on error path
blk-cgroup: Pre-allocate tree node on blkg_conf_prep
Geoffrey D. Bennett (1):
ALSA: usb-audio: Add implicit feedback quirk for Qu-16
Greg Kroah-Hartman (1):
Linux 4.14.205
Grzegorz Siwik (1):
i40e: Wrong truncation from u16 to u8
Hoang Huu Le (1):
tipc: fix use-after-free in tipc_bcast_get_mode
Hoegeun Kwon (1):
drm/vc4: drv: Add error handding for bind
Jason Gunthorpe (1):
mm: always have io_remap_pfn_range() set pgprot_decrypted()
Jeff Vander Stoep (1):
vsock: use ns_capable_noaudit() on socket create
Johan Hovold (1):
USB: serial: cyberjack: fix write-URB completion race
Juergen Gross (1):
xen/events: don't use chip_data for legacy IRQs
Kairui Song (1):
x86/kexec: Use up-to-dated screen_info copy to fill boot params
Lee Jones (1):
Fonts: Replace discarded const qualifier
Liu Bo (1):
Blktrace: bail out early if block debugfs is not configured
Luis Chamberlain (1):
blktrace: fix debugfs use after free
Macpaul Lin (1):
usb: mtu3: fix panic in mtu3_gadget_stop()
Martyna Szapar (2):
i40e: Fix of memory leak and integer truncation in i40e_virtchnl.c
i40e: Memory leak in i40e_config_iwarp_qvlist
Mike Galbraith (1):
futex: Handle transient "ownerless" rtmutex state correctly
Ming Lei (1):
scsi: core: Don't start concurrent async scan on same host
Petr Malat (1):
sctp: Fix COMM_LOST/CANT_STR_ASSOC err reporting on big-endian platforms
Qinglang Miao (1):
serial: txx9: add missing platform_driver_unregister() on error in serial_txx9_init
Qiujun Huang (1):
tracing: Fix out of bounds write in get_trace_buf
Rafael J. Wysocki (1):
PM: runtime: Resume the device earlier in __device_release_driver()
Sergey Nemov (1):
i40e: add num_vectors checker in iwarp handler
Steven Rostedt (VMware) (2):
ftrace: Fix recursion check for NMI test
ftrace: Handle tracing when switching between context
Tomasz Maciej Nowak (1):
arm64: dts: marvell: espressobin: add ethernet alias
Vasily Gorbik (1):
lib/crc32test: remove extra local_irq_disable/enable
Vincent Whitchurch (1):
of: Fix reserved-memory overlap detection
Vineet Gupta (2):
ARC: stack unwinding: avoid indefinite looping
Revert "ARC: entry: fix potential EFA clobber when TIF_SYSCALL_TRACE"
YueHaibing (1):
sfp: Fix error handing in sfp_probe()
Zhang Qilong (1):
ACPI: NFIT: Fix comparison to '-ENXIO'
Ziyi Cao (1):
USB: serial: option: add Quectel EC200T module support
Zqiang (1):
kthread_worker: prevent queuing delayed work from timer_fn when it is being canceled
Greg Kroah-Hartman
maintainerMakefile +1 -1
@@ -1,7 +1,7 @@ # SPDX-License-Identifier: GPL-2.0 VERSION = 4 PATCHLEVEL = 14 -SUBLEVEL = 204 +SUBLEVEL = 205 EXTRAVERSION = NAME = Petit Gorille
arch/arc/kernel/entry.S +11 -5
@@ -156,6 +156,7 @@ END(EV_Extension) tracesys: ; save EFA in case tracer wants the PC of traced task ; using ERET won't work since next-PC has already committed + lr r12, [efa] GET_CURR_TASK_FIELD_PTR TASK_THREAD, r11 st r12, [r11, THREAD_FAULT_ADDR] ; thread.fault_address
@@ -198,9 +199,15 @@ tracesys_exit: ; Breakpoint TRAP ; --------------------------------------------- trap_with_param: - mov r0, r12 ; EFA in case ptracer/gdb wants stop_pc + + ; stop_pc info by gdb needs this info + lr r0, [efa] mov r1, sp + ; Now that we have read EFA, it is safe to do "fake" rtie + ; and get out of CPU exception mode + FAKE_RET_FROM_EXCPN + ; Save callee regs in case gdb wants to have a look ; SP will grow up by size of CALLEE Reg-File ; NOTE: clobbers r12
@@ -227,10 +234,6 @@ ENTRY(EV_Trap) EXCEPTION_PROLOGUE - lr r12, [efa] - - FAKE_RET_FROM_EXCPN - ;============ TRAP 1 :breakpoints ; Check ECR for trap with arg (PROLOGUE ensures r9 has ECR) bmsk.f 0, r9, 7
@@ -238,6 +241,9 @@ ENTRY(EV_Trap) ;============ TRAP (no param): syscall top level + ; First return from Exception to pure K mode (Exception/IRQs renabled) + FAKE_RET_FROM_EXCPN + ; If syscall tracing ongoing, invoke pre-post-hooks GET_CURR_THR_INFO_FLAGS r10 btst r10, TIF_SYSCALL_TRACE
arch/arc/kernel/stacktrace.c +6 -1
@@ -115,7 +115,7 @@ arc_unwind_core(struct task_struct *tsk, struct pt_regs *regs, int (*consumer_fn) (unsigned int, void *), void *arg) { #ifdef CONFIG_ARC_DW2_UNWIND - int ret = 0; + int ret = 0, cnt = 0;unsigned int address;struct unwind_frame_info frame_info;
@@ -135,6 +135,11 @@ arc_unwind_core(struct task_struct *tsk, struct pt_regs *regs,break ; frame_info.regs.r63 = frame_info.regs.r31; + +if (cnt++ >128 ) { +printk ("unwinder looping too long, aborting !\n" ); +return 0 ; + } }return address;/* return the last address it saw */
arch/arm/boot/dts/sun4i-a10.dtsi +1 -1
@@ -143,7 +143,7 @@ trips { cpu_alert0: cpu_alert0 { /* milliCelsius */ - temperature = <850000>; + temperature = <85000>; hysteresis = <2000>; type = "passive"; };
arch/arm64/boot/dts/marvell/armada-3720-espressobin.dts +4 -0
@@ -52,6 +52,10 @@ model = "Globalscale Marvell ESPRESSOBin Board"; compatible = "globalscale,espressobin", "marvell,armada3720", "marvell,armada3710"; + aliases { + ethernet0 = ð0; + }; + chosen { stdout-path = "serial0:115200n8"; };
arch/x86/kernel/kexec-bzimage64.c +1 -2
@@ -211,8 +211,7 @@ setup_boot_parameters(struct kimage *image, struct boot_params *params, params->hdr.hardware_subarch = boot_params.hdr.hardware_subarch;/* Copying screen_info will do? */ -memcpy (¶ms->screen_info, &boot_params.screen_info, -sizeof (struct screen_info )); +memcpy (¶ms->screen_info, &screen_info,sizeof (struct screen_info ));/* Fill in memsize later */ params->screen_info.ext_mem_k =0 ;
block/blk-cgroup.c +13 -2
@@ -872,13 +872,20 @@ int blkg_conf_prep(struct blkcg *blkcg, const struct blkcg_policy *pol, goto fail; } +if (radix_tree_preload (GFP_KERNEL )) { +blkg_free (new_blkg); + ret = -ENOMEM ; + goto fail; + } +rcu_read_lock ();spin_lock_irq (q->queue_lock); blkg =blkg_lookup_check (pos, pol, q);if (IS_ERR (blkg)) { ret =PTR_ERR (blkg); - goto fail_unlock; +blkg_free (new_blkg); + goto fail_preloaded; }if (blkg) {
@@ -887,10 +894,12 @@ int blkg_conf_prep(struct blkcg *blkcg, const struct blkcg_policy *pol, blkg =blkg_create (pos, q, new_blkg);if (unlikely (IS_ERR (blkg))) { ret =PTR_ERR (blkg); - goto fail_unlock; + goto fail_preloaded; } } +radix_tree_preload_end (); +if (pos == blkcg) goto success; }
@@ -900,6 +909,8 @@ int blkg_conf_prep(struct blkcg *blkcg, const struct blkcg_policy *pol, ctx->body = body;return 0 ; +fail_preloaded: +radix_tree_preload_end (); fail_unlock:spin_unlock_irq (q->queue_lock);rcu_read_unlock ();
drivers/acpi/nfit/core.c +1 -1
@@ -1273,7 +1273,7 @@ static ssize_t format1_show(struct device *dev, le16_to_cpu(nfit_dcr->dcr->code));break ; } -if (rc !=ENXIO ) +if (rc != -ENXIO )break ; }mutex_unlock (&acpi_desc->init_mutex);
drivers/base/dd.c +5 -2
@@ -816,6 +816,8 @@ static void __device_release_driver(struct device *dev, struct device *parent) drv = dev->driver;if (drv) { +pm_runtime_get_sync (dev); +while (device_links_busy (dev)) {device_unlock (dev);if (parent)
@@ -831,11 +833,12 @@ static void __device_release_driver(struct device *dev, struct device *parent)* have released the driver successfully while this one * was waiting, so check for that. */ -if (dev->driver != drv) +if (dev->driver != drv) { +pm_runtime_put (dev);return ; + } } -pm_runtime_get_sync (dev);pm_runtime_clean_up_links (dev);driver_sysfs_remove (dev);
drivers/gpu/drm/i915/i915_gpu_error.c +3 -0
@@ -231,6 +231,8 @@ static int compress_page(struct compress *c,if (zlib_deflate (zstream,Z_SYNC_FLUSH ) !=Z_OK )return -EIO ; + +cond_resched (); }while (zstream->avail_in);/* Fallback to uncompressed if we increase size? */
@@ -287,6 +289,7 @@ static int compress_page(struct compress *c,if (!i915_memcpy_from_wc (ptr, src,PAGE_SIZE ))memcpy (ptr, src,PAGE_SIZE ); dst->pages[dst->page_count++] = ptr; +cond_resched ();return 0 ; }
drivers/gpu/drm/vc4/vc4_drv.c +1 -0
@@ -283,6 +283,7 @@ static int vc4_drm_bind(struct device *dev)component_unbind_all (dev, drm); gem_destroy:vc4_gem_destroy (drm); +drm_mode_config_cleanup (drm);vc4_bo_cache_destroy (drm); dev_unref:drm_dev_unref (drm);
drivers/net/ethernet/freescale/gianfar.c +3 -11
@@ -1388,7 +1388,7 @@ static int gfar_probe(struct platform_device *ofdev)if (dev->features &NETIF_F_IP_CSUM || priv->device_flags &FSL_GIANFAR_DEV_HAS_TIMER ) - dev->needed_headroom =GMAC_FCB_LEN ; + dev->needed_headroom =GMAC_FCB_LEN +GMAC_TXPAL_LEN ;/* Initializing some of the rx/tx queue level parameters */ for (i =0 ; i < priv->num_tx_queues; i++) {
@@ -2370,20 +2370,12 @@ static netdev_tx_t gfar_start_xmit(struct sk_buff *skb, struct net_device *dev) fcb_len =GMAC_FCB_LEN +GMAC_TXPAL_LEN ;/* make space for additional header when fcb is needed */ -if (fcb_len &&unlikely (skb_headroom (skb) < fcb_len)) { -struct sk_buff *skb_new; - - skb_new =skb_realloc_headroom (skb, fcb_len); -if (!skb_new) { +if (fcb_len) { +if (unlikely (skb_cow_head (skb, fcb_len))) { dev->stats.tx_errors++;dev_kfree_skb_any (skb);return NETDEV_TX_OK ; } - -if (skb->sk) -skb_set_owner_w (skb_new, skb->sk); -dev_consume_skb_any (skb); - skb = skb_new; }/* total number of fragments in the SKB */
drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c +26 -6
@@ -189,7 +189,7 @@ static inline bool i40e_vc_isvalid_vsi_id(struct i40e_vf *vf, u16 vsi_id)* check for the valid queue id **/ static inline bool i40e_vc_isvalid_queue_id (struct i40e_vf *vf,u16 vsi_id, -u8 qid) +u16 qid) {struct i40e_pf *pf = vf->pf;struct i40e_vsi *vsi =i40e_find_vsi_from_id (pf, vsi_id);
@@ -204,7 +204,7 @@ static inline bool i40e_vc_isvalid_queue_id(struct i40e_vf *vf, u16 vsi_id,* * check for the valid vector id **/ -static inline bool i40e_vc_isvalid_vector_id (struct i40e_vf *vf,u8 vector_id) +static inline bool i40e_vc_isvalid_vector_id (struct i40e_vf *vf,u32 vector_id) {struct i40e_pf *pf = vf->pf;
@@ -418,11 +418,28 @@ static int i40e_config_iwarp_qvlist(struct i40e_vf *vf,u32 v_idx, i, reg_idx, reg;u32 next_q_idx, next_q_type;u32 msix_vf, size; +int ret =0 ; + + msix_vf = pf->hw.func_caps.num_msix_vectors_vf; + +if (qvlist_info->num_vectors > msix_vf) { +dev_warn (&pf->pdev->dev, +"Incorrect number of iwarp vectors %u. Maximum %u allowed.\n" , + qvlist_info->num_vectors, + msix_vf); + ret = -EINVAL ; + goto err_out; + } size =sizeof (struct virtchnl_iwarp_qvlist_info ) + (sizeof (struct virtchnl_iwarp_qv_info ) * (qvlist_info->num_vectors -1 )); +kfree (vf->qvlist_info); vf->qvlist_info =kzalloc (size,GFP_KERNEL ); +if (!vf->qvlist_info) { + ret = -ENOMEM ; + goto err_out; + } vf->qvlist_info->num_vectors = qvlist_info->num_vectors; msix_vf = pf->hw.func_caps.num_msix_vectors_vf;
@@ -433,8 +450,10 @@ static int i40e_config_iwarp_qvlist(struct i40e_vf *vf, v_idx = qv_info->v_idx;/* Validate vector id belongs to this vf */ -if (!i40e_vc_isvalid_vector_id (vf, v_idx)) - goto err; +if (!i40e_vc_isvalid_vector_id (vf, v_idx)) { + ret = -EINVAL ; + goto err_free; + } vf->qvlist_info->qv_info[i] = *qv_info;
@@ -476,10 +495,11 @@ static int i40e_config_iwarp_qvlist(struct i40e_vf *vf, }return 0 ; -err: +err_free:kfree (vf->qvlist_info); vf->qvlist_info =NULL ; -return -EINVAL ; +err_out: +return ret; }/**
drivers/net/phy/sfp.c +2 -1
@@ -881,7 +881,8 @@ static int sfp_probe(struct platform_device *pdev)continue ; irq =gpiod_to_irq (sfp->gpio[i]); -if (!irq) { +if (irq <0 ) { + irq =0 ; poll = true;continue ; }
drivers/net/usb/qmi_wwan.c +1 -0
@@ -1257,6 +1257,7 @@ static const struct usb_device_id products[] = { {QMI_FIXED_INTF(0x1bc7, 0x1101, 3)}, /* Telit ME910 dual modem */ {QMI_FIXED_INTF(0x1bc7, 0x1200, 5)}, /* Telit LE920 */ {QMI_QUIRK_SET_DTR(0x1bc7, 0x1201, 2)}, /* Telit LE920, LE920A4 */ + {QMI_QUIRK_SET_DTR(0x1bc7, 0x1230, 2)}, /* Telit LE910Cx */ {QMI_QUIRK_SET_DTR(0x1bc7, 0x1260, 2)}, /* Telit LE910Cx */ {QMI_QUIRK_SET_DTR(0x1bc7, 0x1261, 2)}, /* Telit LE910Cx */ {QMI_QUIRK_SET_DTR(0x1bc7, 0x1900, 1)}, /* Telit LN940 series */
drivers/of/of_reserved_mem.c +11 -2
@@ -222,6 +222,16 @@ static int __init __rmem_cmp(const void *a, const void *b)if (ra->base > rb->base)return 1 ; +/* +* Put the dynamic allocations (address == 0, size == 0) before static +* allocations at address 0x0 so that overlap detection works +* correctly. +*/ +if (ra->size < rb->size) +return -1 ; +if (ra->size > rb->size) +return 1 ; +return 0 ; }
@@ -239,8 +249,7 @@ static void __init __rmem_check_for_overlap(void) this = &reserved_mem[i]; next = &reserved_mem[i +1 ]; -if (!(this->base && next->base)) -continue ; +if (this->base + this->size > next->base) {phys_addr_t this_end, next_end;
drivers/scsi/scsi_scan.c +4 -3
@@ -1720,15 +1720,16 @@ static void scsi_sysfs_add_devices(struct Scsi_Host *shost)*/ static struct async_scan_data *scsi_prep_async_scan (struct Scsi_Host *shost) { -struct async_scan_data *data; +struct async_scan_data *data =NULL ;unsigned long flags;if (strncmp (scsi_scan_type,"sync" ,4 ) ==0 )return NULL ; +mutex_lock (&shost->scan_mutex);if (shost->async_scan) {shost_printk (KERN_DEBUG , shost,"%s called twice\n" , __func__); -return NULL ; + goto err; } data =kmalloc (sizeof (*data),GFP_KERNEL );
@@ -1739,7 +1740,6 @@ static struct async_scan_data *scsi_prep_async_scan(struct Scsi_Host *shost) goto err;init_completion (&data->prev_finished); -mutex_lock (&shost->scan_mutex);spin_lock_irqsave (shost->host_lock, flags); shost->async_scan =1 ;spin_unlock_irqrestore (shost->host_lock, flags);
@@ -1754,6 +1754,7 @@ static struct async_scan_data *scsi_prep_async_scan(struct Scsi_Host *shost)return data; err: +mutex_unlock (&shost->scan_mutex);kfree (data);return NULL ; }
drivers/tty/serial/8250/8250_mtk.c +1 -1
@@ -56,7 +56,7 @@ mtk8250_set_termios(struct uart_port *port, struct ktermios *termios,*/ baud =tty_termios_baud_rate (termios); -serial8250_do_set_termios (port, termios, old); +serial8250_do_set_termios (port, termios,NULL );tty_termios_encode_baud_rate (termios, baud, baud);
drivers/tty/serial/serial_txx9.c +3 -0
@@ -1287,6 +1287,9 @@ static int __init serial_txx9_init(void)#ifdef ENABLE_SERIAL_TXX9_PCI ret =pci_register_driver (&serial_txx9_pci_driver); +if (ret) { +platform_driver_unregister (&serial_txx9_plat_driver); + }#endif if (ret ==0 ) goto out;
drivers/tty/vt/vt.c +2 -22
@@ -4227,27 +4227,6 @@ static int con_font_default(struct vc_data *vc, struct console_font_op *op)return rc; } -static int con_font_copy (struct vc_data *vc,struct console_font_op *op) -{ -int con = op->height; -int rc; - - -console_lock (); -if (vc->vc_mode !=KD_TEXT ) - rc = -EINVAL ; -else if (!vc->vc_sw->con_font_copy) - rc = -ENOSYS ; -else if (con <0 || !vc_cons_allocated (con)) - rc = -ENOTTY ; -else if (con == vc->vc_num)/* nothing to do */ - rc =0 ; -else - rc = vc->vc_sw->con_font_copy (vc, con); -console_unlock (); -return rc; -} -int con_font_op (struct vc_data *vc,struct console_font_op *op) {switch (op->op) {
@@ -4258,7 +4237,8 @@ int con_font_op(struct vc_data *vc, struct console_font_op *op)case KD_FONT_OP_SET_DEFAULT :return con_font_default (vc, op);case KD_FONT_OP_COPY : -return con_font_copy (vc, op); +/* was buggy and never really used */ +return -EINVAL ; }return -ENOSYS ; }
drivers/usb/core/quirks.c +3 -0
@@ -217,6 +217,9 @@ static const struct usb_device_id usb_quirk_list[] = { { USB_DEVICE(0x0926, 0x3333), .driver_info = USB_QUIRK_CONFIG_INTF_STRINGS }, + /* Kingston DataTraveler 3.0 */ + { USB_DEVICE(0x0951, 0x1666), .driver_info = USB_QUIRK_NO_LPM }, + /* X-Rite/Gretag-Macbeth Eye-One Pro display colorimeter */ { USB_DEVICE(0x0971, 0x2000), .driver_info = USB_QUIRK_NO_SET_INTF },
drivers/usb/mtu3/mtu3_gadget.c +1 -0
@@ -581,6 +581,7 @@ static int mtu3_gadget_stop(struct usb_gadget *g)spin_unlock_irqrestore (&mtu->lock, flags); +synchronize_irq (mtu->irq);return 0 ; }
drivers/usb/serial/cyberjack.c +6 -1
@@ -358,11 +358,12 @@ static void cyberjack_write_bulk_callback(struct urb *urb)struct cyberjack_private *priv =usb_get_serial_port_data (port);struct device *dev = &port->dev;int status = urb->status; +bool resubmitted = false; -set_bit (0 , &port->write_urbs_free);if (status) {dev_dbg (dev,"%s - nonzero write bulk status received: %d\n" , __func__, status); +set_bit (0 , &port->write_urbs_free);return ; }
@@ -395,6 +396,8 @@ static void cyberjack_write_bulk_callback(struct urb *urb) goto exit; } + resubmitted = true; +dev_dbg (dev,"%s - priv->wrsent=%d\n" , __func__, priv->wrsent);dev_dbg (dev,"%s - priv->wrfilled=%d\n" , __func__, priv->wrfilled);
@@ -411,6 +414,8 @@ static void cyberjack_write_bulk_callback(struct urb *urb) exit:spin_unlock (&priv->lock); +if (!resubmitted) +set_bit (0 , &port->write_urbs_free);usb_serial_port_softint (port); }
drivers/usb/serial/option.c +10 -0
@@ -253,6 +253,7 @@ static void option_instat_callback(struct urb *urb);#define QUECTEL_PRODUCT_EP06 0x0306#define QUECTEL_PRODUCT_EM12 0x0512#define QUECTEL_PRODUCT_RM500Q 0x0800 +#define QUECTEL_PRODUCT_EC200T 0x6026#define CMOTECH_VENDOR_ID 0x16d8#define CMOTECH_PRODUCT_6001 0x6001
@@ -1120,6 +1121,7 @@ static const struct usb_device_id option_ids[] = { { USB_DEVICE_AND_INTERFACE_INFO(QUECTEL_VENDOR_ID, QUECTEL_PRODUCT_RM500Q, 0xff, 0, 0) }, { USB_DEVICE_AND_INTERFACE_INFO(QUECTEL_VENDOR_ID, QUECTEL_PRODUCT_RM500Q, 0xff, 0xff, 0x10), .driver_info = ZLP }, + { USB_DEVICE_AND_INTERFACE_INFO(QUECTEL_VENDOR_ID, QUECTEL_PRODUCT_EC200T, 0xff, 0, 0) }, { USB_DEVICE(CMOTECH_VENDOR_ID, CMOTECH_PRODUCT_6001) }, { USB_DEVICE(CMOTECH_VENDOR_ID, CMOTECH_PRODUCT_CMU_300) },
@@ -1192,6 +1194,8 @@ static const struct usb_device_id option_ids[] = { .driver_info = NCTRL(0) | RSVD(1) }, { USB_DEVICE_INTERFACE_CLASS(TELIT_VENDOR_ID, 0x1054, 0xff), /* Telit FT980-KS */ .driver_info = NCTRL(2) | RSVD(3) }, + { USB_DEVICE_INTERFACE_CLASS(TELIT_VENDOR_ID, 0x1055, 0xff), /* Telit FN980 (PCIe) */ + .driver_info = NCTRL(0) | RSVD(1) }, { USB_DEVICE(TELIT_VENDOR_ID, TELIT_PRODUCT_ME910), .driver_info = NCTRL(0) | RSVD(1) | RSVD(3) }, { USB_DEVICE(TELIT_VENDOR_ID, TELIT_PRODUCT_ME910_DUAL_MODEM),
@@ -1204,6 +1208,8 @@ static const struct usb_device_id option_ids[] = { .driver_info = NCTRL(0) }, { USB_DEVICE(TELIT_VENDOR_ID, TELIT_PRODUCT_LE910), .driver_info = NCTRL(0) | RSVD(1) | RSVD(2) }, + { USB_DEVICE_INTERFACE_CLASS(TELIT_VENDOR_ID, 0x1203, 0xff), /* Telit LE910Cx (RNDIS) */ + .driver_info = NCTRL(2) | RSVD(3) }, { USB_DEVICE(TELIT_VENDOR_ID, TELIT_PRODUCT_LE910_USBCFG4), .driver_info = NCTRL(0) | RSVD(1) | RSVD(2) | RSVD(3) }, { USB_DEVICE(TELIT_VENDOR_ID, TELIT_PRODUCT_LE920),
@@ -1218,6 +1224,10 @@ static const struct usb_device_id option_ids[] = { { USB_DEVICE_INTERFACE_CLASS(TELIT_VENDOR_ID, TELIT_PRODUCT_LE920A4_1213, 0xff) }, { USB_DEVICE(TELIT_VENDOR_ID, TELIT_PRODUCT_LE920A4_1214), .driver_info = NCTRL(0) | RSVD(1) | RSVD(2) | RSVD(3) }, + { USB_DEVICE_INTERFACE_CLASS(TELIT_VENDOR_ID, 0x1230, 0xff), /* Telit LE910Cx (rmnet) */ + .driver_info = NCTRL(0) | RSVD(1) | RSVD(2) }, + { USB_DEVICE_INTERFACE_CLASS(TELIT_VENDOR_ID, 0x1231, 0xff), /* Telit LE910Cx (RNDIS) */ + .driver_info = NCTRL(2) | RSVD(3) }, { USB_DEVICE(TELIT_VENDOR_ID, 0x1260), .driver_info = NCTRL(0) | RSVD(1) | RSVD(2) }, { USB_DEVICE(TELIT_VENDOR_ID, 0x1261),
drivers/xen/events/events_base.c +21 -8
@@ -90,6 +90,8 @@ static bool (*pirq_needs_eoi)(unsigned irq);/* Xen will never allocate port zero for any purpose. */ #define VALID_EVTCHN (chn) ((chn) != 0) +static struct irq_info *legacy_info_ptrs[NR_IRQS_LEGACY ]; +static struct irq_chip xen_dynamic_chip;static struct irq_chip xen_percpu_chip;static struct irq_chip xen_pirq_chip;
@@ -154,7 +156,18 @@ int get_evtchn_to_irq(unsigned evtchn)/* Get info for IRQ */ struct irq_info *info_for_irq (unsigned irq) { -return irq_get_chip_data (irq); +if (irq <nr_legacy_irqs ()) +return legacy_info_ptrs[irq]; +else +return irq_get_chip_data (irq); +} + +static void set_info_for_irq (unsigned int irq,struct irq_info *info) +{ +if (irq <nr_legacy_irqs ()) + legacy_info_ptrs[irq] = info; +else +irq_set_chip_data (irq, info); }/* Constructors for packed IRQ information. */
@@ -375,7 +388,7 @@ static void xen_irq_init(unsigned irq) info->type =IRQT_UNBOUND ; info->refcnt =-1 ; -irq_set_chip_data (irq, info); +set_info_for_irq (irq, info);list_add_tail (&info->list, &xen_irq_list_head); }
@@ -424,14 +437,14 @@ static int __must_check xen_allocate_irq_gsi(unsigned gsi)static void xen_free_irq (unsigned irq) { -struct irq_info *info =irq_get_chip_data (irq); +struct irq_info *info =info_for_irq (irq);if (WARN_ON (!info))return ;list_del (&info->list); -irq_set_chip_data (irq,NULL ); +set_info_for_irq (irq,NULL );WARN_ON (info->refcnt >0 );
@@ -601,7 +614,7 @@ EXPORT_SYMBOL_GPL(xen_irq_from_gsi);static void __unbind_from_irq (unsigned int irq) {int evtchn =evtchn_from_irq (irq); -struct irq_info *info =irq_get_chip_data (irq); +struct irq_info *info =info_for_irq (irq);if (info->refcnt >0 ) { info->refcnt--;
@@ -1105,7 +1118,7 @@ int bind_ipi_to_irqhandler(enum ipi_vector ipi,void unbind_from_irqhandler (unsigned int irq,void *dev_id) { -struct irq_info *info =irq_get_chip_data (irq); +struct irq_info *info =info_for_irq (irq);if (WARN_ON (!info))return ;
@@ -1139,7 +1152,7 @@ int evtchn_make_refcounted(unsigned int evtchn)if (irq ==-1 )return -ENOENT ; - info =irq_get_chip_data (irq); + info =info_for_irq (irq);if (!info)return -ENOENT ;
@@ -1167,7 +1180,7 @@ int evtchn_get(unsigned int evtchn)if (irq ==-1 ) goto done; - info =irq_get_chip_data (irq); + info =info_for_irq (irq);if (!info) goto done;
fs/gfs2/glock.c +2 -1
@@ -870,7 +870,8 @@ int gfs2_glock_get(struct gfs2_sbd *sdp, u64 number, out_free:kfree (gl->gl_lksb.sb_lvbptr);kmem_cache_free (cachep, gl); -atomic_dec (&sdp->sd_glock_disposal); +if (atomic_dec_and_test (&sdp->sd_glock_disposal)) +wake_up (&sdp->sd_glock_wait); out:return ret;
include/asm-generic/pgtable.h +0 -4
@@ -1069,10 +1069,6 @@ static inline bool arch_has_pfn_modify_check(void)#endif /* !__ASSEMBLY__ */ -#ifndef io_remap_pfn_range -#define io_remap_pfn_range remap_pfn_range -#endif -#ifndef has_transparent_hugepage#ifdef CONFIG_TRANSPARENT_HUGEPAGE #define has_transparent_hugepage () 1
include/linux/mm.h +9 -0
@@ -2422,6 +2422,15 @@ static inline int vm_fault_to_errno(int vm_fault, int foll_flags)return 0 ; } +#ifndef io_remap_pfn_range +static inline int io_remap_pfn_range (struct vm_area_struct *vma, +unsigned long addr,unsigned long pfn, +unsigned long size,pgprot_t prot) +{ +return remap_pfn_range (vma, addr, pfn, size,pgprot_decrypted (prot)); +} +#endif +typedef int (*pte_fn_t )(pte_t *pte,pgtable_t token,unsigned long addr,void *data); extern int apply_to_page_range(struct mm_struct *mm, unsigned long address,
kernel/fork.c +5 -5
@@ -1833,14 +1833,9 @@ static __latent_entropy struct task_struct *copy_process(/* ok, now we should be set up.. */ p->pid =pid_nr (pid);if (clone_flags &CLONE_THREAD ) { - p->exit_signal =-1 ; p->group_leader = current->group_leader; p->tgid = current->tgid; }else { -if (clone_flags &CLONE_PARENT ) - p->exit_signal = current->group_leader->exit_signal; -else - p->exit_signal = (clone_flags &CSIGNAL ); p->group_leader = p; p->tgid = p->pid; }
@@ -1885,9 +1880,14 @@ static __latent_entropy struct task_struct *copy_process(if (clone_flags & (CLONE_PARENT |CLONE_THREAD )) { p->real_parent = current->real_parent; p->parent_exec_id = current->parent_exec_id; +if (clone_flags &CLONE_THREAD ) + p->exit_signal =-1 ; +else + p->exit_signal = current->group_leader->exit_signal; }else { p->real_parent = current; p->parent_exec_id = current->self_exec_id; + p->exit_signal = (clone_flags &CSIGNAL ); }klp_copy_process (p);
kernel/futex.c +14 -2
@@ -2512,10 +2512,22 @@ static int fixup_pi_state_owner(u32 __user *uaddr, struct futex_q *q, }/* -* Since we just failed the trylock; there must be an owner. +* The trylock just failed, so either there is an owner or +* there is a higher priority waiter than this one. */ newowner =rt_mutex_owner (&pi_state->pi_mutex); -BUG_ON (!newowner); +/* +* If the higher priority waiter has not yet taken over the +* rtmutex then newowner is NULL. We can't return here with +* that state because it's inconsistent vs. the user space +* state. So drop the locks and try again. It's a valid +* situation and not any different from the other retry +* conditions. +*/ +if (unlikely (!newowner)) { + err = -EAGAIN ; + goto handle_err; + } }else {WARN_ON_ONCE (argowner != current);if (oldowner == current) {
kernel/kthread.c +2 -1
@@ -831,7 +831,8 @@ void kthread_delayed_work_timer_fn(unsigned long __data)/* Move the work from worker->delayed_work_list. */ WARN_ON_ONCE (list_empty (&work->node));list_del_init (&work->node); -kthread_insert_work (worker, work, &worker->work_list); +if (!work->canceling) +kthread_insert_work (worker, work, &worker->work_list);spin_unlock (&worker->lock); }
kernel/trace/blktrace.c +15 -9
@@ -498,6 +498,9 @@ static int do_blk_trace_setup(struct request_queue *q, char *name, dev_t dev,if (!buts->buf_size || !buts->buf_nr)return -EINVAL ; +if (!blk_debugfs_root) +return -ENOENT ; +strncpy (buts->name, name,BLKTRACE_BDEV_SIZE ); buts->name[BLKTRACE_BDEV_SIZE -1 ] ='\0' ;
@@ -530,13 +533,18 @@ static int do_blk_trace_setup(struct request_queue *q, char *name, dev_t dev,if (!bt->msg_data) goto err; - ret = -ENOENT ; - -if (!blk_debugfs_root) - goto err; - - dir =debugfs_lookup (buts->name, blk_debugfs_root); -if (!dir) +#ifdef CONFIG_BLK_DEBUG_FS +/* +* When tracing whole make_request drivers (multiqueue) block devices, +* reuse the existing debugfs directory created by the block layer on +* init. For request-based block devices, all partitions block devices, +* and scsi-generic block devices we create a temporary new debugfs +* directory that will be removed once the trace ends. +*/ +if (q->mq_ops && bdev && bdev == bdev->bd_contains) + dir = q->debugfs_dir; + else +#endif bt->dir = dir =debugfs_create_dir (buts->name, blk_debugfs_root);if (!dir) goto err;
@@ -595,8 +603,6 @@ static int do_blk_trace_setup(struct request_queue *q, char *name, dev_t dev, ret =0 ; err: -if (dir && !bt->dir) -dput (dir);if (ret)blk_trace_free (bt);return ret;
kernel/trace/trace.c +1 -1
@@ -2817,7 +2817,7 @@ static char *get_trace_buf(void)/* Interrupts must see nesting incremented before we use the buffer */ barrier (); -return &buffer->buffer[buffer->nesting][0 ]; +return &buffer->buffer[buffer->nesting -1 ][0 ]; }static void put_trace_buf (void )
kernel/trace/trace.h +23 -3
@@ -526,6 +526,12 @@ enum {TRACE_GRAPH_DEPTH_START_BIT ,TRACE_GRAPH_DEPTH_END_BIT , + +/* +* When transitioning between context, the preempt_count() may +* not be correct. Allow for a single recursion to cover this case. +*/ + TRACE_TRANSITION_BIT, };#define trace_recursion_set (bit) do { (current)->trace_recursion |= (1<<(bit)); } while (0)
@@ -580,14 +586,27 @@ static __always_inline int trace_test_and_set_recursion(int start, int max)return 0 ; bit =trace_get_context_bit () + start; -if (unlikely (val & (1 << bit))) -return -1 ; +if (unlikely (val & (1 << bit))) { +/* +* It could be that preempt_count has not been updated during +* a switch between contexts. Allow for a single recursion. +*/ + bit =TRACE_TRANSITION_BIT ; +if (trace_recursion_test (bit)) +return -1 ; +trace_recursion_set (bit); +barrier (); +return bit +1 ; + } + +/* Normal check passed, clear the transition to allow it again */ +trace_recursion_clear (TRACE_TRANSITION_BIT ); val |=1 << bit; current->trace_recursion = val;barrier (); -return bit; +return bit +1 ; } static __always_inline void trace_clear_recursion(int bit)
@@ -597,6 +616,7 @@ static __always_inline void trace_clear_recursion(int bit)if (!bit)return ; + bit--; bit =1 << bit; val &= ~bit;
kernel/trace/trace_selftest.c +7 -2
@@ -492,8 +492,13 @@ trace_selftest_function_recursion(void)unregister_ftrace_function (&test_rec_probe); ret =-1 ; -if (trace_selftest_recursion_cnt !=1 ) { -pr_cont ("*callback not called once (%d)* " , +/* +* Recursion allows for transitions between context, +* and may call the callback twice. +*/ +if (trace_selftest_recursion_cnt !=1 && + trace_selftest_recursion_cnt !=2 ) { +pr_cont ("*callback not called once (or twice) (%d)* " , trace_selftest_recursion_cnt); goto out; }
lib/crc32test.c +0 -4
@@ -683,7 +683,6 @@ static int __init crc32c_test(void)/* reduce OS noise */ local_irq_save (flags); -local_irq_disable (); nsec =ktime_get_ns ();for (i =0 ; i <100 ; i++) {
@@ -694,7 +693,6 @@ static int __init crc32c_test(void) nsec =ktime_get_ns () - nsec;local_irq_restore (flags); -local_irq_enable ();pr_info ("crc32c: CRC_LE_BITS = %d\n" ,CRC_LE_BITS );
@@ -768,7 +766,6 @@ static int __init crc32_test(void)/* reduce OS noise */ local_irq_save (flags); -local_irq_disable (); nsec =ktime_get_ns ();for (i =0 ; i <100 ; i++) {
@@ -783,7 +780,6 @@ static int __init crc32_test(void) nsec =ktime_get_ns () - nsec;local_irq_restore (flags); -local_irq_enable ();pr_info ("crc32: CRC_LE_BITS = %d, CRC_BE BITS = %d\n" ,CRC_LE_BITS ,CRC_BE_BITS );
lib/fonts/font_10x18.c +1 -1
@@ -8,7 +8,7 @@#define FONTDATAMAX 9216 -static struct font_data fontdata_10x18 = { +static const struct font_data fontdata_10x18 = { {0 ,0 ,FONTDATAMAX ,0 }, {/* 0 0x00 '^@' */ 0x00 ,0x00 ,/* 0000000000 */
lib/fonts/font_6x10.c +1 -1
@@ -3,7 +3,7 @@#define FONTDATAMAX 2560 -static struct font_data fontdata_6x10 = { +static const struct font_data fontdata_6x10 = { {0 ,0 ,FONTDATAMAX ,0 }, {/* 0 0x00 '^@' */ 0x00 ,/* 00000000 */
lib/fonts/font_6x11.c +1 -1
@@ -9,7 +9,7 @@#define FONTDATAMAX (11*256) -static struct font_data fontdata_6x11 = { +static const struct font_data fontdata_6x11 = { {0 ,0 ,FONTDATAMAX ,0 }, {/* 0 0x00 '^@' */ 0x00 ,/* 00000000 */
lib/fonts/font_7x14.c +1 -1
@@ -8,7 +8,7 @@#define FONTDATAMAX 3584 -static struct font_data fontdata_7x14 = { +static const struct font_data fontdata_7x14 = { {0 ,0 ,FONTDATAMAX ,0 }, {/* 0 0x00 '^@' */ 0x00 ,/* 0000000 */
lib/fonts/font_8x16.c +1 -1
@@ -10,7 +10,7 @@#define FONTDATAMAX 4096 -static struct font_data fontdata_8x16 = { +static const struct font_data fontdata_8x16 = { {0 ,0 ,FONTDATAMAX ,0 }, {/* 0 0x00 '^@' */ 0x00 ,/* 00000000 */
lib/fonts/font_8x8.c +1 -1
@@ -9,7 +9,7 @@#define FONTDATAMAX 2048 -static struct font_data fontdata_8x8 = { +static const struct font_data fontdata_8x8 = { {0 ,0 ,FONTDATAMAX ,0 }, {/* 0 0x00 '^@' */ 0x00 ,/* 00000000 */
lib/fonts/font_acorn_8x8.c +1 -1
@@ -5,7 +5,7 @@#define FONTDATAMAX 2048 -static struct font_data acorndata_8x8 = { +static const struct font_data acorndata_8x8 = { {0 ,0 ,FONTDATAMAX ,0 }, {/* 00 */ 0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,/* ^@ */ /* 01 */ 0x7e ,0x81 ,0xa5 ,0x81 ,0xbd ,0x99 ,0x81 ,0x7e ,/* ^A */
lib/fonts/font_mini_4x6.c +1 -1
@@ -43,7 +43,7 @@ __END__;#define FONTDATAMAX 1536 -static struct font_data fontdata_mini_4x6 = { +static const struct font_data fontdata_mini_4x6 = { {0 ,0 ,FONTDATAMAX ,0 }, {/*{*/ /* Char 0: ' ' */
lib/fonts/font_pearl_8x8.c +1 -1
@@ -14,7 +14,7 @@#define FONTDATAMAX 2048 -static struct font_data fontdata_pearl8x8 = { +static const struct font_data fontdata_pearl8x8 = { {0 ,0 ,FONTDATAMAX ,0 }, {/* 0 0x00 '^@' */ 0x00 ,/* 00000000 */
lib/fonts/font_sun12x22.c +1 -1
@@ -3,7 +3,7 @@#define FONTDATAMAX 11264 -static struct font_data fontdata_sun12x22 = { +static const struct font_data fontdata_sun12x22 = { {0 ,0 ,FONTDATAMAX ,0 }, {/* 0 0x00 '^@' */ 0x00 ,0x00 ,/* 000000000000 */
lib/fonts/font_sun8x16.c +1 -1
@@ -3,7 +3,7 @@#define FONTDATAMAX 4096 -static struct font_data fontdata_sun8x16 = { +static const struct font_data fontdata_sun8x16 = { {0 ,0 ,FONTDATAMAX ,0 }, {/* */ 0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,0x00 ,/* */ 0x00 ,0x00 ,0x7e ,0x81 ,0xa5 ,0x81 ,0x81 ,0xbd ,0x99 ,0x81 ,0x81 ,0x7e ,0x00 ,0x00 ,0x00 ,0x00 ,
net/sctp/sm_sideeffect.c +2 -2
@@ -1591,12 +1591,12 @@ static int sctp_cmd_interpreter(enum sctp_event event_type,break ;case SCTP_CMD_INIT_FAILED : -sctp_cmd_init_failed (commands, asoc, cmd->obj.u32); +sctp_cmd_init_failed (commands, asoc, cmd->obj.u16);break ;case SCTP_CMD_ASSOC_FAILED :sctp_cmd_assoc_failed (commands, asoc, event_type, - subtype, chunk, cmd->obj.u32); + subtype, chunk, cmd->obj.u16);break ;case SCTP_CMD_INIT_COUNTER_INC :
net/tipc/core.c +5 -0
@@ -89,6 +89,11 @@ static int __net_init tipc_init_net(struct net *net) static void __net_exit tipc_exit_net(struct net *net) {tipc_net_stop (net); + +/* Make sure the tipc_net_finalize_work stopped +* before releasing the resources. +*/ +flush_scheduled_work ();tipc_bcast_stop (net);tipc_nametbl_stop (net);tipc_sk_rht_destroy (net);
net/vmw_vsock/af_vsock.c +1 -1
@@ -636,7 +636,7 @@ struct sock *__vsock_create(struct net *net, vsk->owner =get_cred (psk->owner); vsk->connect_timeout = psk->connect_timeout; }else { - vsk->trusted =capable (CAP_NET_ADMIN ); + vsk->trusted =ns_capable_noaudit (&init_user_ns,CAP_NET_ADMIN ); vsk->owner =get_current_cred (); vsk->connect_timeout =VSOCK_DEFAULT_CONNECT_TIMEOUT ; }
sound/usb/pcm.c +1 -0
@@ -332,6 +332,7 @@ static int set_sync_ep_implicit_fb_quirk(struct snd_usb_substream *subs,switch (subs->stream->chip->usb_id) {case USB_ID (0x0763 ,0x2030 ):/* M-Audio Fast Track C400 */ case USB_ID (0x0763 ,0x2031 ):/* M-Audio Fast Track C600 */ +case USB_ID (0x22f0 ,0x0006 ):/* Allen&Heath Qu-16 */ ep =0x81 ; iface =usb_ifnum_to_if (dev,3 );