Linux 4.14.218
Greg Kroah-Hartman
maintainerI'm announcing the release of the 4.14.218 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/arm/xen/enlighten.c | 2 arch/sh/drivers/dma/Kconfig | 3 arch/x86/boot/compressed/Makefile | 2 drivers/acpi/scan.c | 2 drivers/gpio/gpio-mvebu.c | 25 -- drivers/gpu/drm/drm_atomic_helper.c | 2 drivers/gpu/drm/nouveau/nvkm/subdev/bios/shadow.c | 2 drivers/gpu/drm/nouveau/nvkm/subdev/i2c/auxgm200.c | 8 drivers/gpu/drm/nouveau/nvkm/subdev/ibus/gf100.c | 10 drivers/gpu/drm/nouveau/nvkm/subdev/ibus/gk104.c | 10 drivers/hwtracing/intel_th/pci.c | 5 drivers/hwtracing/stm/heartbeat.c | 6 drivers/i2c/busses/i2c-octeon-core.c | 2 drivers/i2c/busses/i2c-tegra-bpmp.c | 2 drivers/iio/dac/ad5504.c | 4 drivers/irqchip/irq-mips-cpu.c | 7 drivers/md/dm-table.c | 15 + drivers/mmc/host/sdhci-xenon.c | 7 drivers/net/can/dev.c | 4 drivers/net/can/vxcan.c | 6 drivers/net/dsa/b53/b53_common.c | 2 drivers/net/ethernet/renesas/sh_eth.c | 4 drivers/scsi/ufs/ufshcd.c | 11 - drivers/usb/gadget/udc/bdc/Kconfig | 2 drivers/usb/gadget/udc/core.c | 13 - drivers/usb/host/ehci-hcd.c | 12 + drivers/usb/host/ehci-hub.c | 3 drivers/usb/host/xhci-ring.c | 2 drivers/usb/host/xhci-tegra.c | 7 drivers/xen/events/events_base.c | 10 drivers/xen/platform-pci.c | 1 drivers/xen/xenbus/xenbus.h | 1 drivers/xen/xenbus/xenbus_comms.c | 8 drivers/xen/xenbus/xenbus_probe.c | 81 ++++++- fs/ext4/inode.c | 6 fs/fs-writeback.c | 43 +--- fs/gfs2/super.c | 2 include/linux/compiler-gcc.h | 6 include/linux/fs.h | 4 include/trace/events/writeback.h | 1 include/xen/xenbus.h | 2 kernel/futex.c | 223 +++++++++------------ kernel/locking/rtmutex.c | 3 kernel/locking/rtmutex_common.h | 3 kernel/trace/ring_buffer.c | 4 mm/slub.c | 4 net/core/skbuff.c | 6 net/ipv4/netfilter/ipt_rpfilter.c | 2 net/ipv4/udp.c | 3 net/ipv6/addrconf.c | 1 net/sched/cls_tcindex.c | 8 sound/core/seq/oss/seq_oss_synth.c | 3 sound/pci/hda/patch_via.c | 1 sound/soc/intel/boards/haswell.c | 1 55 files changed, 346 insertions(+), 263 deletions(-)
Alex Leibovich (1):
mmc: sdhci-xenon: fix 1.8v regulator stabilization
Alexander Lobakin (1):
skbuff: back tiny skbs with kmalloc() in __netdev_alloc_skb() too
Alexander Shishkin (1):
intel_th: pci: Add Alder Lake-P support
Arvind Sankar (1):
x86/boot/compressed: Disable relocation relaxation
Baruch Siach (1):
gpio: mvebu: fix pwm .get_state period calculation
Ben Skeggs (3):
drm/nouveau/bios: fix issue shadowing expansion ROMs drm/nouveau/privring: ack interrupts the same way as RM drm/nouveau/i2c/gm200: increase width of aux semaphore owner fields
Can Guo (1):
scsi: ufs: Correct the LUN used in eh_device_reset_handler() callback
Cezary Rojewski (1):
ASoC: Intel: haswell: Add missing pm_ops
Christoph Hellwig (1):
fs: move I_DIRTY_INODE to fs.h
Dan Carpenter (1):
net: dsa: b53: fix an off by one in checking "vlan->vid"
David Woodhouse (1):
xen: Fix event channel callback via INTX/GSI
Eric Biggers (1):
fs: fix lazytime expiration handling in __writeback_single_inode()
Eric Dumazet (1):
net_sched: avoid shift-out-of-bounds in tcindex_set_parms()
Eugene Korenevsky (1):
ehci: fix EHCI host controller initialization sequence
Gaurav Kohli (1):
tracing: Fix race in trace_open and buffer resize call
Geert Uytterhoeven (1):
sh_eth: Fix power down vs. is_opened flag ordering
Greg Kroah-Hartman (1):
Linux 4.14.218
Guillaume Nault (2):
netfilter: rpfilter: mask ecn bits before fib lookup
udp: mask TOS bits in udp_v4_early_demux()
Hannes Reinecke (1):
dm: avoid filesystem lookup in dm_get_dev_t()
Hans de Goede (1):
ACPI: scan: Make acpi_bus_get_device() clear return pointer on error
JC Kuo (1):
xhci: tegra: Delay for disabling LFPS detector
Jan Kara (1):
writeback: Drop I_DIRTY_TIME_EXPIRE
Jiri Slaby (1):
futex: futex_wake_op, fix sign_extend32 sign bits
Lars-Peter Clausen (1):
iio: ad5504: Fix setting power-down state
Longfang Liu (1):
USB: ehci: fix an interrupt calltrace error
Mathias Kresin (1):
irqchip/mips-cpu: Set IPI domain parent chip
Mathias Nyman (1):
xhci: make sure TRB is fully written before giving it to the controller
Matteo Croce (1):
ipv6: create multicast route with RTPROT_KERNEL
Mikko Perttunen (1):
i2c: bpmp-tegra: Ignore unknown I2C_M flags
Necip Fazil Yildiran (1):
sh: dma: fix kconfig dependency for G2_DMA
Pan Bian (1):
drm/atomic: put state on error path
Patrik Jakobsson (1):
usb: bdc: Make bdc pci driver depend on BROKEN
Takashi Iwai (2):
ALSA: seq: oss: Fix missing error check in snd_seq_oss_synth_make_info()
ALSA: hda/via: Add minimum mute flag
Thinh Nguyen (1):
usb: udc: core: Use lock when write to soft_connect
Thomas Gleixner (7):
futex: Ensure the correct return value from futex_lock_pi()
futex: Replace pointless printk in fixup_owner()
futex: Provide and use pi_state_update_owner()
rtmutex: Remove unused argument from rt_mutex_proxy_unlock()
futex: Use pi_state_update_owner() in put_pi_state()
futex: Simplify fixup_pi_state_owner()
futex: Handle faults correctly for PI futexes
Vincent Mailhol (2):
can: dev: can_restart: fix use after free bug
can: vxcan: vxcan_xmit: fix use after free bug
Wang Hai (1):
Revert "mm/slub: fix a memory leak in sysfs_slab_add()"
Wang Hui (1):
stm class: Fix module init return on allocation failure
Will Deacon (1):
compiler.h: Raise minimum version of GCC to 5.1 for arm64
Wolfram Sang (1):
i2c: octeon: check correct size of maximum RECV_LEN packet
Greg Kroah-Hartman
maintainerMakefile +1 -1
@@ -1,7 +1,7 @@ # SPDX-License-Identifier: GPL-2.0 VERSION = 4 PATCHLEVEL = 14 -SUBLEVEL = 217 +SUBLEVEL = 218 EXTRAVERSION = NAME = Petit Gorille
arch/arm/xen/enlighten.c +1 -1
@@ -393,7 +393,7 @@ static int __init xen_guest_init(void) }gnttab_init ();if (!xen_initial_domain ()) -xenbus_probe (NULL ); +xenbus_probe ();/* * Making sure board specific code will not set up ops for
arch/sh/drivers/dma/Kconfig +1 -2
@@ -63,8 +63,7 @@ config PVR2_DMA config G2_DMA tristate "G2 Bus DMA support" - depends on SH_DREAMCAST - select SH_DMA_API + depends on SH_DREAMCAST && SH_DMA_API help This enables support for the DMA controller for the Dreamcast's G2 bus. Drivers that want this will generally enable this on
arch/x86/boot/compressed/Makefile +2 -0
@@ -36,6 +36,8 @@ KBUILD_CFLAGS += -mno-mmx -mno-sse KBUILD_CFLAGS += $(call cc-option,-ffreestanding) KBUILD_CFLAGS += $(call cc-option,-fno-stack-protector) KBUILD_CFLAGS += $(call cc-disable-warning, address-of-packed-member) +# Disable relocation relaxation in case the link is not PIE. +KBUILD_CFLAGS += $(call as-option,-Wa$(comma)-mrelax-relocations=no) KBUILD_AFLAGS := $(KBUILD_CFLAGS) -D__ASSEMBLY__ GCOV_PROFILE := n
drivers/acpi/scan.c +2 -0
@@ -585,6 +585,8 @@ static int acpi_get_device_data(acpi_handle handle, struct acpi_device **device,if (!device)return -EINVAL ; + *device =NULL ; + status =acpi_get_data_full (handle, acpi_scan_drop_device, (void **)device, callback);if (ACPI_FAILURE (status) || !*device) {
drivers/gpio/gpio-mvebu.c +10 -15
@@ -654,9 +654,8 @@ static void mvebu_pwm_get_state(struct pwm_chip *chip,spin_lock_irqsave (&mvpwm->lock, flags); - val = (unsigned long long ) -readl_relaxed (mvebu_pwmreg_blink_on_duration (mvpwm)); - val *=NSEC_PER_SEC ; + u =readl_relaxed (mvebu_pwmreg_blink_on_duration (mvpwm)); + val = (unsigned long long ) u *NSEC_PER_SEC ;do_div (val, mvpwm->clk_rate);if (val >UINT_MAX ) state->duty_cycle =UINT_MAX ;
@@ -665,21 +664,17 @@ static void mvebu_pwm_get_state(struct pwm_chip *chip,else state->duty_cycle =1 ; - val = (unsigned long long ) -readl_relaxed (mvebu_pwmreg_blink_off_duration (mvpwm)); + val = (unsigned long long ) u;/* on duration */ +/* period = on + off duration */ + val +=readl_relaxed (mvebu_pwmreg_blink_off_duration (mvpwm)); val *=NSEC_PER_SEC ;do_div (val, mvpwm->clk_rate); -if (val < state->duty_cycle) { +if (val >UINT_MAX ) + state->period =UINT_MAX ; +else if (val) + state->period = val; +else state->period =1 ; - }else { - val -= state->duty_cycle; -if (val >UINT_MAX ) - state->period =UINT_MAX ; -else if (val) - state->period = val; -else - state->period =1 ; - }regmap_read (mvchip->regs,GPIO_BLINK_EN_OFF + mvchip->offset, &u);if (u)
drivers/gpu/drm/drm_atomic_helper.c +1 -1
@@ -2608,7 +2608,7 @@ int drm_atomic_helper_set_config(struct drm_mode_set *set, ret =handle_conflicting_encoders (state, true);if (ret) -return ret; + goto fail; ret =drm_atomic_commit (state);
drivers/gpu/drm/nouveau/nvkm/subdev/bios/shadow.c +1 -1
@@ -75,7 +75,7 @@ shadow_image(struct nvkm_bios *bios, int idx, u32 offset, struct shadow *mthd)nvkm_debug (subdev,"%08x: type %02x, %d bytes\n" , image.base, image.type, image.size); -if (!shadow_fetch (bios, mthd, image.size)) { +if (!shadow_fetch (bios, mthd, image.base + image.size)) {nvkm_debug (subdev,"%08x: fetch failed\n" , image.base);return 0 ; }
drivers/gpu/drm/nouveau/nvkm/subdev/i2c/auxgm200.c +4 -4
@@ -33,7 +33,7 @@ static void gm200_i2c_aux_fini(struct gm200_i2c_aux *aux) {struct nvkm_device *device = aux->base.pad->i2c->subdev.device; -nvkm_mask (device,0x00d954 + (aux->ch *0x50 ),0x00310000 ,0x00000000 ); +nvkm_mask (device,0x00d954 + (aux->ch *0x50 ),0x00710000 ,0x00000000 ); } static int
@@ -54,10 +54,10 @@ gm200_i2c_aux_init(struct gm200_i2c_aux *aux)AUX_ERR (&aux->base,"begin idle timeout %08x" , ctrl);return -EBUSY ; } - }while (ctrl &0x03010000 ); + }while (ctrl &0x07010000 );/* set some magic, and wait up to 1ms for it to appear */ -nvkm_mask (device,0x00d954 + (aux->ch *0x50 ),0x00300000 , ureq); +nvkm_mask (device,0x00d954 + (aux->ch *0x50 ),0x00700000 , ureq); timeout =1000 ; do { ctrl = nvkm_rd32(device, 0x00d954 + (aux->ch * 0x50));
@@ -67,7 +67,7 @@ gm200_i2c_aux_init(struct gm200_i2c_aux *aux)gm200_i2c_aux_fini (aux);return -EBUSY ; } - }while ((ctrl &0x03000000 ) != urep); + }while ((ctrl &0x07000000 ) != urep);return 0 ; }
drivers/gpu/drm/nouveau/nvkm/subdev/ibus/gf100.c +7 -3
@@ -22,6 +22,7 @@* Authors: Ben Skeggs */ #include "priv.h" +#include <subdev/timer.h> static void gf100_ibus_intr_hub (struct nvkm_subdev *ibus,int i)
@@ -31,7 +32,6 @@ gf100_ibus_intr_hub(struct nvkm_subdev *ibus, int i)u32 data =nvkm_rd32 (device,0x122124 + (i *0x0400 ));u32 stat =nvkm_rd32 (device,0x122128 + (i *0x0400 ));nvkm_debug (ibus,"HUB%d: %06x %08x (%08x)\n" , i, addr, data, stat); -nvkm_mask (device,0x122128 + (i *0x0400 ),0x00000200 ,0x00000000 ); } static void
@@ -42,7 +42,6 @@ gf100_ibus_intr_rop(struct nvkm_subdev *ibus, int i)u32 data =nvkm_rd32 (device,0x124124 + (i *0x0400 ));u32 stat =nvkm_rd32 (device,0x124128 + (i *0x0400 ));nvkm_debug (ibus,"ROP%d: %06x %08x (%08x)\n" , i, addr, data, stat); -nvkm_mask (device,0x124128 + (i *0x0400 ),0x00000200 ,0x00000000 ); } static void
@@ -53,7 +52,6 @@ gf100_ibus_intr_gpc(struct nvkm_subdev *ibus, int i)u32 data =nvkm_rd32 (device,0x128124 + (i *0x0400 ));u32 stat =nvkm_rd32 (device,0x128128 + (i *0x0400 ));nvkm_debug (ibus,"GPC%d: %06x %08x (%08x)\n" , i, addr, data, stat); -nvkm_mask (device,0x128128 + (i *0x0400 ),0x00000200 ,0x00000000 ); }void
@@ -90,6 +88,12 @@ gf100_ibus_intr(struct nvkm_subdev *ibus) intr1 &= ~stat; } } + +nvkm_mask (device,0x121c4c ,0x0000003f ,0x00000002 ); +nvkm_msec (device,2000 , + if (!(nvkm_rd32(device, 0x121c4c) & 0x0000003f)) + break; + ); } static int
drivers/gpu/drm/nouveau/nvkm/subdev/ibus/gk104.c +7 -3
@@ -22,6 +22,7 @@* Authors: Ben Skeggs */ #include "priv.h" +#include <subdev/timer.h> static void gk104_ibus_intr_hub (struct nvkm_subdev *ibus,int i)
@@ -31,7 +32,6 @@ gk104_ibus_intr_hub(struct nvkm_subdev *ibus, int i)u32 data =nvkm_rd32 (device,0x122124 + (i *0x0800 ));u32 stat =nvkm_rd32 (device,0x122128 + (i *0x0800 ));nvkm_debug (ibus,"HUB%d: %06x %08x (%08x)\n" , i, addr, data, stat); -nvkm_mask (device,0x122128 + (i *0x0800 ),0x00000200 ,0x00000000 ); } static void
@@ -42,7 +42,6 @@ gk104_ibus_intr_rop(struct nvkm_subdev *ibus, int i)u32 data =nvkm_rd32 (device,0x124124 + (i *0x0800 ));u32 stat =nvkm_rd32 (device,0x124128 + (i *0x0800 ));nvkm_debug (ibus,"ROP%d: %06x %08x (%08x)\n" , i, addr, data, stat); -nvkm_mask (device,0x124128 + (i *0x0800 ),0x00000200 ,0x00000000 ); } static void
@@ -53,7 +52,6 @@ gk104_ibus_intr_gpc(struct nvkm_subdev *ibus, int i)u32 data =nvkm_rd32 (device,0x128124 + (i *0x0800 ));u32 stat =nvkm_rd32 (device,0x128128 + (i *0x0800 ));nvkm_debug (ibus,"GPC%d: %06x %08x (%08x)\n" , i, addr, data, stat); -nvkm_mask (device,0x128128 + (i *0x0800 ),0x00000200 ,0x00000000 ); }void
@@ -90,6 +88,12 @@ gk104_ibus_intr(struct nvkm_subdev *ibus) intr1 &= ~stat; } } + +nvkm_mask (device,0x12004c ,0x0000003f ,0x00000002 ); +nvkm_msec (device,2000 , + if (!(nvkm_rd32(device, 0x12004c) & 0x0000003f)) + break; + ); } static int
drivers/hwtracing/intel_th/pci.c +5 -0
@@ -238,6 +238,11 @@ static const struct pci_device_id intel_th_pci_id_table[] = { PCI_DEVICE(PCI_VENDOR_ID_INTEL, 0x4b26), .driver_data = (kernel_ulong_t)&intel_th_2x, }, + { +/* Alder Lake-P */ +PCI_DEVICE (PCI_VENDOR_ID_INTEL ,0x51a6 ), + .driver_data = (kernel_ulong_t)&intel_th_2x, + }, {/* Emmitsburg PCH */ PCI_DEVICE(PCI_VENDOR_ID_INTEL, 0x1bcc),
drivers/hwtracing/stm/heartbeat.c +4 -2
@@ -72,7 +72,7 @@ static void stm_heartbeat_unlink(struct stm_source_data *data)static int stm_heartbeat_init (void ) { -int i, ret = -ENOMEM ; +int i, ret;if (nr_devs <0 || nr_devs >STM_HEARTBEAT_MAX )return -EINVAL ;
@@ -80,8 +80,10 @@ static int stm_heartbeat_init(void)for (i =0 ; i < nr_devs; i++) { stm_heartbeat[i].data.name =kasprintf (GFP_KERNEL ,"heartbeat.%d" , i); -if (!stm_heartbeat[i].data.name) +if (!stm_heartbeat[i].data.name) { + ret = -ENOMEM ; goto fail_unregister; + } stm_heartbeat[i].data.nr_chans =1 ; stm_heartbeat[i].data.link = stm_heartbeat_link;
drivers/i2c/busses/i2c-octeon-core.c +1 -1
@@ -346,7 +346,7 @@ static int octeon_i2c_read(struct octeon_i2c *i2c, int target,if (result)return result;if (recv_len && i ==0 ) { -if (data[i] >I2C_SMBUS_BLOCK_MAX +1 ) +if (data[i] >I2C_SMBUS_BLOCK_MAX )return -EPROTO ; length += data[i]; }
drivers/i2c/busses/i2c-tegra-bpmp.c +1 -1
@@ -91,7 +91,7 @@ static int tegra_bpmp_xlate_flags(u16 flags, u16 *out) flags &= ~I2C_M_RECV_LEN ; } -return (flags !=0 ) ? -EINVAL :0 ; +return 0 ; }/**
drivers/iio/dac/ad5504.c +2 -2
@@ -189,9 +189,9 @@ static ssize_t ad5504_write_dac_powerdown(struct iio_dev *indio_dev,return ret;if (pwr_down) - st->pwr_down_mask |= (1 << chan->channel); -else st->pwr_down_mask &= ~(1 << chan->channel); +else + st->pwr_down_mask |= (1 << chan->channel); ret = ad5504_spi_write(st, AD5504_ADDR_CTRL, AD5504_DAC_PWRDWN_MODE(st->pwr_down_mode) |
drivers/irqchip/irq-mips-cpu.c +7 -0
@@ -201,6 +201,13 @@ static int mips_cpu_ipi_alloc(struct irq_domain *domain, unsigned int virq,if (ret)return ret; + ret =irq_domain_set_hwirq_and_chip (domain->parent, virq + i, hwirq, + &mips_mt_cpu_irq_controller, +NULL ); + +if (ret) +return ret; + ret =irq_set_irq_type (virq + i,IRQ_TYPE_LEVEL_HIGH );if (ret)return ret;
drivers/md/dm-table.c +12 -3
@@ -431,14 +431,23 @@ int dm_get_device(struct dm_target *ti, const char *path, fmode_t mode, {int r;dev_t dev; +unsigned int major, minor; +char dummy;struct dm_dev_internal *dd;struct dm_table *t = ti->table;BUG_ON (!t); - dev =dm_get_dev_t (path); -if (!dev) -return -ENODEV ; +if (sscanf (path,"%u:%u%c" , &major, &minor, &dummy) ==2 ) { +/* Extract the major/minor numbers */ + dev =MKDEV (major, minor); +if (MAJOR (dev) != major ||MINOR (dev) != minor) +return -EOVERFLOW ; + }else { + dev =dm_get_dev_t (path); +if (!dev) +return -ENODEV ; + } dd =find_device (&t->devices, dev);if (!dd) {
drivers/mmc/host/sdhci-xenon.c +6 -1
@@ -170,7 +170,12 @@ static void xenon_reset_exit(struct sdhci_host *host,/* Disable tuning request and auto-retuning again */ xenon_retune_setup (host); -xenon_set_acg (host, true); +/* +* The ACG should be turned off at the early init time, in order +* to solve a possible issues with the 1.8V regulator stabilization. +* The feature is enabled in later stage. +*/ +xenon_set_acg (host, false);xenon_set_sdclk_off_idle (host, sdhc_id, false);
drivers/net/can/dev.c +2 -2
@@ -578,11 +578,11 @@ static void can_restart(struct net_device *dev) } cf->can_id |=CAN_ERR_RESTARTED ; -netif_rx_ni (skb); - stats->rx_packets++; stats->rx_bytes += cf->can_dlc; +netif_rx_ni (skb); + restart:netdev_dbg (dev,"restarted\n" ); priv->can_stats.restarts++;
drivers/net/can/vxcan.c +4 -2
@@ -49,6 +49,7 @@ static netdev_tx_t vxcan_xmit(struct sk_buff *skb, struct net_device *dev)struct net_device *peer;struct canfd_frame *cfd = (struct canfd_frame *)skb->data;struct net_device_stats *peerstats, *srcstats = &dev->stats; +u8 len;if (can_dropped_invalid_skb (dev, skb))return NETDEV_TX_OK ;
@@ -71,12 +72,13 @@ static netdev_tx_t vxcan_xmit(struct sk_buff *skb, struct net_device *dev) skb->dev = peer; skb->ip_summed =CHECKSUM_UNNECESSARY ; + len = cfd->len;if (netif_rx_ni (skb) ==NET_RX_SUCCESS ) { srcstats->tx_packets++; - srcstats->tx_bytes += cfd->len; + srcstats->tx_bytes += len; peerstats = &peer->stats; peerstats->rx_packets++; - peerstats->rx_bytes += cfd->len; + peerstats->rx_bytes += len; } out_unlock:
drivers/net/dsa/b53/b53_common.c +1 -1
@@ -970,7 +970,7 @@ int b53_vlan_prepare(struct dsa_switch *ds, int port,if ((is5325 (dev) ||is5365 (dev)) && vlan->vid_begin ==0 )return -EOPNOTSUPP ; -if (vlan->vid_end > dev->num_vlans) +if (vlan->vid_end >= dev->num_vlans)return -ERANGE ;b53_enable_vlan (dev, true);
drivers/net/ethernet/renesas/sh_eth.c +2 -2
@@ -2517,10 +2517,10 @@ static int sh_eth_close(struct net_device *ndev)/* Free all the skbuffs in the Rx queue and the DMA buffer. */ sh_eth_ring_free (ndev); -pm_runtime_put_sync (&mdp->pdev->dev); - mdp->is_opened =0 ; +pm_runtime_put (&mdp->pdev->dev); +return 0 ; }
drivers/scsi/ufs/ufshcd.c +4 -7
@@ -5536,19 +5536,16 @@ static int ufshcd_eh_device_reset_handler(struct scsi_cmnd *cmd) {struct Scsi_Host *host;struct ufs_hba *hba; -unsigned int tag;u32 pos;int err; -u8 resp =0xF ; -struct ufshcd_lrb *lrbp; +u8 resp =0xF , lun;unsigned long flags; host = cmd->device->host; hba =shost_priv (host); - tag = cmd->request->tag; - lrbp = &hba->lrb[tag]; - err =ufshcd_issue_tm_cmd (hba, lrbp->lun,0 ,UFS_LOGICAL_RESET , &resp); + lun =ufshcd_scsi_to_upiu_lun (cmd->device->lun); + err =ufshcd_issue_tm_cmd (hba, lun,0 ,UFS_LOGICAL_RESET , &resp);if (err || resp !=UPIU_TASK_MANAGEMENT_FUNC_COMPL ) {if (!err) err = resp;
@@ -5557,7 +5554,7 @@ static int ufshcd_eh_device_reset_handler(struct scsi_cmnd *cmd)/* clear the commands that were pending for corresponding LUN */ for_each_set_bit (pos, &hba->outstanding_reqs, hba->nutrs) { -if (hba->lrb[pos].lun == lrbp->lun) { +if (hba->lrb[pos].lun == lun) { err =ufshcd_clear_cmd (hba, pos);if (err)break ;
drivers/usb/gadget/udc/bdc/Kconfig +1 -1
@@ -15,7 +15,7 @@ if USB_BDC_UDC comment "Platform Support" config USB_BDC_PCI tristate "BDC support for PCIe based platforms" - depends on USB_PCI + depends on USB_PCI && BROKEN default USB_BDC_UDC help Enable support for platforms which have BDC connected through PCIe, such as Lego3 FPGA platform.
drivers/usb/gadget/udc/core.c +10 -3
@@ -1458,10 +1458,13 @@ static ssize_t usb_udc_softconn_store(struct device *dev, struct device_attribute *attr, const char *buf, size_t n) { struct usb_udc *udc = container_of(dev, struct usb_udc, dev); +ssize_t ret; +mutex_lock (&udc_lock);if (!udc->driver) {dev_err (dev,"soft-connect without a gadget driver\n" ); -return -EOPNOTSUPP ; + ret = -EOPNOTSUPP ; + goto out; }if (sysfs_streq (buf,"connect" )) {
@@ -1473,10 +1476,14 @@ static ssize_t usb_udc_softconn_store(struct device *dev,usb_gadget_udc_stop (udc); }else {dev_err (dev,"unsupported command '%s'\n" , buf); -return -EINVAL ; + ret = -EINVAL ; + goto out; } -return n; + ret = n; +out: +mutex_unlock (&udc_lock); +return ret; } static DEVICE_ATTR(soft_connect, S_IWUSR, NULL, usb_udc_softconn_store);
drivers/usb/host/ehci-hcd.c +12 -0
@@ -587,6 +587,7 @@ static int ehci_run (struct usb_hcd *hcd)struct ehci_hcd *ehci =hcd_to_ehci (hcd);u32 temp;u32 hcc_params; +int rc; hcd->uses_new_polling =1 ;
@@ -642,9 +643,20 @@ static int ehci_run (struct usb_hcd *hcd)down_write (&ehci_cf_port_reset_rwsem); ehci->rh_state =EHCI_RH_RUNNING ;ehci_writel (ehci,FLAG_CF , &ehci->regs->configured_flag); + +/* Wait until HC become operational */ ehci_readl (ehci, &ehci->regs->command);/* unblock posted writes */ msleep (5 ); + rc =ehci_handshake (ehci, &ehci->regs->status,STS_HALT ,0 ,100 *1000 ); +up_write (&ehci_cf_port_reset_rwsem); + +if (rc) { +ehci_err (ehci,"USB %x.%x, controller refused to start: %d\n" , + ((ehci->sbrn &0xf0 )>>4 ), (ehci->sbrn &0x0f ), rc); +return rc; + } + ehci->last_periodic_enable =ktime_get_real (); temp =HC_VERSION (ehci,ehci_readl (ehci, &ehci->caps->hc_capbase));
drivers/usb/host/ehci-hub.c +3 -0
@@ -358,6 +358,9 @@ static int ehci_bus_suspend (struct usb_hcd *hcd)unlink_empty_async_suspended (ehci); +/* Some Synopsys controllers mistakenly leave IAA turned on */ +ehci_writel (ehci,STS_IAA , &ehci->regs->status); +/* Any IAA cycle that started before the suspend is now invalid */ end_iaa_cycle (ehci);ehci_handle_start_intr_unlinks (ehci);
drivers/usb/host/xhci-ring.c +2 -0
@@ -2907,6 +2907,8 @@ static void queue_trb(struct xhci_hcd *xhci, struct xhci_ring *ring, trb->field[0 ] =cpu_to_le32 (field1); trb->field[1 ] =cpu_to_le32 (field2); trb->field[2 ] =cpu_to_le32 (field3); +/* make sure TRB is fully written before giving it to the controller */ +wmb (); trb->field[3 ] =cpu_to_le32 (field4);trace_xhci_queue_trb (ring, trb);
drivers/usb/host/xhci-tegra.c +7 -0
@@ -579,6 +579,13 @@ static void tegra_xusb_mbox_handle(struct tegra_xusb *tegra, enable);if (err <0 )break ; + +/* +* wait 500us for LFPS detector to be disabled before +* sending ACK +*/ +if (!enable) +usleep_range (500 ,1000 ); }if (err <0 ) {
drivers/xen/events/events_base.c +0 -10
@@ -1987,16 +1987,6 @@ static struct irq_chip xen_percpu_chip __read_mostly = { .irq_ack = ack_dynirq, }; -int xen_set_callback_via (uint64_t via) -{ -struct xen_hvm_param a; - a.domid =DOMID_SELF ; - a.index =HVM_PARAM_CALLBACK_IRQ ; - a.value = via; -return HYPERVISOR_hvm_op (HVMOP_set_param, &a); -} -EXPORT_SYMBOL_GPL (xen_set_callback_via); -#ifdef CONFIG_XEN_PVHVM /* Vector callbacks are better than PCI interrupts to receive event * channel notifications because we can receive vector callbacks on any
drivers/xen/platform-pci.c +0 -1
@@ -162,7 +162,6 @@ static int platform_pci_probe(struct pci_dev *pdev, ret =gnttab_init ();if (ret) goto grant_out; -xenbus_probe (NULL );return 0 ; grant_out:gnttab_free_auto_xlat_frames ();
drivers/xen/xenbus/xenbus.h +1 -0
@@ -114,6 +114,7 @@ int xenbus_probe_node(struct xen_bus_type *bus,const char *type, const char *nodename);int xenbus_probe_devices (struct xen_bus_type *bus); +void xenbus_probe (void );void xenbus_dev_changed (const char *node,struct xen_bus_type *bus);
drivers/xen/xenbus/xenbus_comms.c +0 -8
@@ -57,16 +57,8 @@ DEFINE_MUTEX(xs_response_mutex);static int xenbus_irq;static struct task_struct *xenbus_task; -static DECLARE_WORK(probe_work, xenbus_probe); - -static irqreturn_t wake_waiting (int irq,void *unused) { -if (unlikely (xenstored_ready ==0 )) { - xenstored_ready =1 ; -schedule_work (&probe_work); - } -wake_up (&xb_waitq);return IRQ_HANDLED ; }
drivers/xen/xenbus/xenbus_probe.c +67 -14
107 lines not on this page · raw message
fs/ext4/inode.c +3 -3
@@ -5064,16 +5064,16 @@ static int other_inode_match(struct inode * inode, unsigned long ino,if ((inode->i_ino != ino) || (inode->i_state & (I_FREEING |I_WILL_FREE |I_NEW | -I_DIRTY_SYNC |I_DIRTY_DATASYNC )) || +I_DIRTY_INODE )) || ((inode->i_state &I_DIRTY_TIME ) ==0 ))return 0 ;spin_lock (&inode->i_lock);if (((inode->i_state & (I_FREEING |I_WILL_FREE |I_NEW | -I_DIRTY_SYNC |I_DIRTY_DATASYNC )) ==0 ) && +I_DIRTY_INODE )) ==0 ) && (inode->i_state &I_DIRTY_TIME )) {struct ext4_inode_info *ei =EXT4_I (inode); - inode->i_state &= ~(I_DIRTY_TIME |I_DIRTY_TIME_EXPIRED ); + inode->i_state &= ~I_DIRTY_TIME ;spin_unlock (&inode->i_lock);spin_lock (&ei->i_raw_lock);
fs/fs-writeback.c +18 -25
107 lines not on this page · raw message
fs/gfs2/super.c +1 -1
@@ -791,7 +791,7 @@ static void gfs2_dirty_inode(struct inode *inode, int flags)int need_endtrans =0 ;int ret; -if (!(flags & (I_DIRTY_DATASYNC |I_DIRTY_SYNC ))) +if (!(flags &I_DIRTY_INODE ))return ;if (unlikely (test_bit (SDF_SHUTDOWN , &sdp->sd_flags)))return ;
include/linux/compiler-gcc.h +6 -0
@@ -152,6 +152,12 @@#if GCC_VERSION <30200 # error Sorry, your compiler is too old - please upgrade it. +#elif defined(CONFIG_ARM64 ) &&GCC_VERSION <50100 && !defined(__clang__) +/* +* https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63293 +* https://lore.kernel.org/r/[email protected] +*/ +# error Sorry, your version of GCC is too old - please use 5.1 or newer.#endif #if GCC_VERSION <30300
include/linux/fs.h +2 -2
@@ -2010,12 +2010,12 @@ static inline void init_sync_kiocb(struct kiocb *kiocb, struct file *filp)#define I_DIO_WAKEUP (1 << __I_DIO_WAKEUP)#define I_LINKABLE (1 << 10)#define I_DIRTY_TIME (1 << 11) -#define I_DIRTY_TIME_EXPIRED (1 << 12)#define I_WB_SWITCH (1 << 13)#define I_OVL_INUSE (1 << 14)#define I_SYNC_QUEUED (1 << 17) -#define I_DIRTY (I_DIRTY_SYNC | I_DIRTY_DATASYNC | I_DIRTY_PAGES) +#define I_DIRTY_INODE (I_DIRTY_SYNC | I_DIRTY_DATASYNC) +#define I_DIRTY (I_DIRTY_INODE | I_DIRTY_PAGES)#define I_DIRTY_ALL (I_DIRTY | I_DIRTY_TIME)extern void __mark_inode_dirty (struct inode *,int );
include/trace/events/writeback.h +0 -1
@@ -20,7 +20,6 @@ {I_CLEAR, "I_CLEAR"}, \ {I_SYNC, "I_SYNC"}, \ {I_DIRTY_TIME, "I_DIRTY_TIME"}, \ - {I_DIRTY_TIME_EXPIRED, "I_DIRTY_TIME_EXPIRED"}, \ {I_REFERENCED, "I_REFERENCED"} \ )
include/xen/xenbus.h +1 -1
@@ -187,7 +187,7 @@ void xs_suspend_cancel(void);struct work_struct ; -void xenbus_probe (struct work_struct *); +void xenbus_probe (void );#define XENBUS_IS_ERR_READ (str) ({ \ if (!IS_ERR(str) && strlen(str) == 0) { \
kernel/futex.c +98 -125
376 lines not on this page · raw message
kernel/locking/rtmutex.c +1 -2
@@ -1719,8 +1719,7 @@ void rt_mutex_init_proxy_locked(struct rt_mutex *lock,* possible because it belongs to the pi_state which is about to be freed * and it is not longer visible to other tasks. */ -void rt_mutex_proxy_unlock (struct rt_mutex *lock, -struct task_struct *proxy_owner) +void rt_mutex_proxy_unlock (struct rt_mutex *lock) {debug_rt_mutex_proxy_unlock (lock);rt_mutex_set_owner (lock,NULL );
kernel/locking/rtmutex_common.h +1 -2
@@ -132,8 +132,7 @@ enum rtmutex_chainwalk {extern struct task_struct *rt_mutex_next_owner (struct rt_mutex *lock);extern void rt_mutex_init_proxy_locked (struct rt_mutex *lock,struct task_struct *proxy_owner); -extern void rt_mutex_proxy_unlock (struct rt_mutex *lock, -struct task_struct *proxy_owner); +extern void rt_mutex_proxy_unlock (struct rt_mutex *lock);extern void rt_mutex_init_waiter (struct rt_mutex_waiter *waiter); extern int __rt_mutex_start_proxy_lock(struct rt_mutex *lock, struct rt_mutex_waiter *waiter,
kernel/trace/ring_buffer.c +4 -0
@@ -4262,6 +4262,8 @@ void ring_buffer_reset_cpu(struct ring_buffer *buffer, int cpu)if (!cpumask_test_cpu (cpu, buffer->cpumask))return ; +/* prevent another thread from changing buffer sizes */ +mutex_lock (&buffer->mutex);atomic_inc (&buffer->resize_disabled);atomic_inc (&cpu_buffer->record_disabled);
@@ -4285,6 +4287,8 @@ void ring_buffer_reset_cpu(struct ring_buffer *buffer, int cpu)atomic_dec (&cpu_buffer->record_disabled);atomic_dec (&buffer->resize_disabled); + +mutex_unlock (&buffer->mutex); }EXPORT_SYMBOL_GPL (ring_buffer_reset_cpu);
mm/slub.c +1 -3
@@ -5755,10 +5755,8 @@ static int sysfs_slab_add(struct kmem_cache *s) s->kobj.kset = kset; err =kobject_init_and_add (&s->kobj, &slab_ktype,NULL ,"%s" , name); -if (err) { -kobject_put (&s->kobj); +if (err) goto out; - } err =sysfs_create_group (&s->kobj, &slab_attr_group);if (err)
net/core/skbuff.c +5 -1
@@ -398,7 +398,11 @@ struct sk_buff *__netdev_alloc_skb(struct net_device *dev, unsigned int len, len +=NET_SKB_PAD ; -if ((len >SKB_WITH_OVERHEAD (PAGE_SIZE )) || +/* If requested length is either too small or too big, +* we use kmalloc() for skb->head allocation. +*/ +if (len <=SKB_WITH_OVERHEAD (1024 ) || + len >SKB_WITH_OVERHEAD (PAGE_SIZE ) || (gfp_mask & (__GFP_DIRECT_RECLAIM |GFP_DMA ))) { skb =__alloc_skb (len, gfp_mask,SKB_ALLOC_RX ,NUMA_NO_NODE );if (!skb)
net/ipv4/netfilter/ipt_rpfilter.c +1 -1
@@ -94,7 +94,7 @@ static bool rpfilter_mt(const struct sk_buff *skb, struct xt_action_param *par) flow.saddr =rpfilter_get_saddr (iph->daddr); flow.flowi4_oif =0 ; flow.flowi4_mark = info->flags &XT_RPFILTER_VALID_MARK ? skb->mark :0 ; - flow.flowi4_tos =RT_TOS (iph->tos); + flow.flowi4_tos = iph->tos &IPTOS_RT_MASK ; flow.flowi4_scope =RT_SCOPE_UNIVERSE ; flow.flowi4_oif =l3mdev_master_ifindex_rcu (xt_in (par));
net/ipv4/udp.c +2 -1
@@ -2321,7 +2321,8 @@ int udp_v4_early_demux(struct sk_buff *skb)*/ if (!inet_sk (sk)->inet_daddr && in_dev)return ip_mc_validate_source (skb, iph->daddr, - iph->saddr, iph->tos, + iph->saddr, + iph->tos &IPTOS_RT_MASK , skb->dev, in_dev, &itag); }return 0 ;
net/ipv6/addrconf.c +1 -0
@@ -2356,6 +2356,7 @@ static void addrconf_add_mroute(struct net_device *dev) .fc_dst_len = 8, .fc_flags = RTF_UP, .fc_nlinfo.nl_net = dev_net(dev), + .fc_protocol = RTPROT_KERNEL, };ipv6_addr_set (&cfg.fc_dst,htonl (0xFF000000 ),0 ,0 ,0 );
net/sched/cls_tcindex.c +6 -2
@@ -357,9 +357,13 @@ tcindex_set_parms(struct net *net, struct tcf_proto *tp, unsigned long base,if (tb[TCA_TCINDEX_MASK ]) cp->mask =nla_get_u16 (tb[TCA_TCINDEX_MASK ]); -if (tb[TCA_TCINDEX_SHIFT ]) +if (tb[TCA_TCINDEX_SHIFT ]) { cp->shift =nla_get_u32 (tb[TCA_TCINDEX_SHIFT ]); - +if (cp->shift >16 ) { + err = -EINVAL ; + goto errout; + } + }if (!cp->hash) {/* Hash not specified, use perfect hash if the upper limit * of the hashing index is below the threshold.
sound/core/seq/oss/seq_oss_synth.c +2 -1
@@ -624,7 +624,8 @@ snd_seq_oss_synth_make_info(struct seq_oss_devinfo *dp, int dev, struct synth_inif (info->is_midi) {struct midi_info minf; -snd_seq_oss_midi_make_info (dp, info->midi_mapped, &minf); +if (snd_seq_oss_midi_make_info (dp, info->midi_mapped, &minf)) +return -ENXIO ; inf->synth_type =SYNTH_TYPE_MIDI ; inf->synth_subtype =0 ; inf->nr_voices =16 ;
sound/pci/hda/patch_via.c +1 -0
@@ -135,6 +135,7 @@ static struct via_spec *via_new_spec(struct hda_codec *codec) spec->codec_type =VT1708S ; spec->gen.indep_hp =1 ; spec->gen.keep_eapd_on =1 ; + spec->gen.dac_min_mute =1 ; spec->gen.pcm_playback_hook = via_playback_pcm_hook; spec->gen.add_stereo_mix_input =HDA_HINT_STEREO_MIX_AUTO ; codec->power_save_node =1 ;
sound/soc/intel/boards/haswell.c +1 -0
@@ -197,6 +197,7 @@ static struct platform_driver haswell_audio = { .probe = haswell_audio_probe, .driver = { .name = "haswell-audio", + .pm = &snd_soc_pm_ops, }, };