Skip to contentSkip to conversation

Linux 4.14.157

DISCUSSION Greg KH 1 participant 2 messages Dec 1, 2019 Stable branch

lore
Share & tools
lore

Greg KH

author maintainer
#0 lore raw

I'm announcing the release of the 4.14.157 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

------------

 Documentation/admin-guide/hw-vuln/mds.rst                          |    7 
 Documentation/admin-guide/hw-vuln/tsx_async_abort.rst              |    5 
 Documentation/admin-guide/kernel-parameters.txt                    |   11 +
 Makefile                                                           |    2 
 arch/arc/kernel/perf_event.c                                       |    4 
 arch/arm/mm/mmu.c                                                  |    3 
 arch/arm64/Makefile                                                |    2 
 arch/arm64/include/asm/string.h                                    |   14 -
 arch/arm64/kernel/arm64ksyms.c                                     |    7 
 arch/arm64/kernel/traps.c                                          |    1 
 arch/arm64/lib/memchr.S                                            |    2 
 arch/arm64/lib/memcmp.S                                            |    2 
 arch/arm64/lib/strchr.S                                            |    2 
 arch/arm64/lib/strcmp.S                                            |    2 
 arch/arm64/lib/strlen.S                                            |    2 
 arch/arm64/lib/strncmp.S                                           |    2 
 arch/arm64/lib/strnlen.S                                           |    2 
 arch/arm64/lib/strrchr.S                                           |    2 
 arch/m68k/kernel/uboot.c                                           |    2 
 arch/powerpc/boot/Makefile                                         |    4 
 arch/powerpc/include/asm/asm-prototypes.h                          |    3 
 arch/powerpc/include/asm/security_features.h                       |    3 
 arch/powerpc/kernel/eeh_pe.c                                       |    2 
 arch/powerpc/kernel/entry_64.S                                     |    6 
 arch/powerpc/kernel/process.c                                      |    3 
 arch/powerpc/kernel/security.c                                     |   74 ++++++++
 arch/powerpc/kvm/book3s_hv_rmhandlers.S                            |   27 +++
 arch/powerpc/platforms/ps3/os-area.c                               |    2 
 arch/powerpc/platforms/pseries/hotplug-memory.c                    |    2 
 arch/powerpc/platforms/pseries/lpar.c                              |   54 ++++++
 arch/powerpc/xmon/Makefile                                         |    6 
 arch/s390/kernel/perf_cpum_sf.c                                    |    6 
 arch/sparc/include/asm/cmpxchg_64.h                                |    7 
 arch/sparc/include/asm/parport.h                                   |    2 
 arch/um/drivers/line.c                                             |    2 
 arch/x86/hyperv/hv_init.c                                          |    2 
 arch/x86/include/asm/ptrace.h                                      |   42 ++++-
 arch/x86/kernel/cpu/bugs.c                                         |   30 +++
 arch/x86/kvm/mmu.c                                                 |    8 
 arch/x86/kvm/vmx.c                                                 |   12 -
 arch/x86/tools/gen-insn-attr-x86.awk                               |    4 
 block/blk-merge.c                                                  |   46 ++++-
 drivers/acpi/acpi_memhotplug.c                                     |    2 
 drivers/atm/zatm.c                                                 |   42 ++---
 drivers/base/memory.c                                              |    9 -
 drivers/base/power/domain.c                                        |    6 
 drivers/block/amiflop.c                                            |   84 ++++------
 drivers/block/nbd.c                                                |    6 
 drivers/block/skd_main.c                                           |    4 
 drivers/bluetooth/hci_bcsp.c                                       |    3 
 drivers/cdrom/cdrom.c                                              |   27 +--
 drivers/char/virtio_console.c                                      |   28 +--
 drivers/clk/at91/clk-audio-pll.c                                   |    2 
 drivers/clk/mmp/clk-of-mmp2.c                                      |    4 
 drivers/clk/sunxi-ng/ccu-sun50i-a64.c                              |    7 
 drivers/cpufreq/cpufreq.c                                          |    9 +
 drivers/edac/thunderx_edac.c                                       |    4 
 drivers/firmware/google/gsmi.c                                     |    5 
 drivers/gpio/gpio-max77620.c                                       |    6 
 drivers/gpu/drm/i915/i915_gem_userptr.c                            |   22 ++
 drivers/i2c/busses/i2c-uniphier-f.c                                |   72 ++++++--
 drivers/infiniband/hw/bnxt_re/main.c                               |   13 +
 drivers/isdn/mISDN/tei.c                                           |    7 
 drivers/macintosh/windfarm_smu_sat.c                               |   25 --
 drivers/md/dm-raid.c                                               |    2 
 drivers/md/raid10.c                                                |    2 
 drivers/media/platform/vivid/vivid-kthread-cap.c                   |    8 
 drivers/media/platform/vivid/vivid-kthread-out.c                   |    8 
 drivers/media/platform/vivid/vivid-sdr-cap.c                       |    8 
 drivers/media/platform/vivid/vivid-vid-cap.c                       |    3 
 drivers/media/platform/vivid/vivid-vid-out.c                       |    3 
 drivers/media/rc/imon.c                                            |    3 
 drivers/media/usb/b2c2/flexcop-usb.c                               |    3 
 drivers/media/usb/dvb-usb/cxusb.c                                  |    3 
 drivers/media/usb/usbvision/usbvision-video.c                      |   21 ++
 drivers/media/usb/uvc/uvc_driver.c                                 |   28 +--
 drivers/mfd/arizona-core.c                                         |    8 
 drivers/mfd/intel_soc_pmic_bxtwc.c                                 |   41 +++-
 drivers/mfd/max8997.c                                              |    8 
 drivers/mfd/mc13xxx-core.c                                         |    3 
 drivers/misc/mic/scif/scif_fence.c                                 |    2 
 drivers/mmc/host/mtk-sd.c                                          |    2 
 drivers/net/dsa/bcm_sf2.c                                          |    4 
 drivers/net/dsa/mv88e6xxx/chip.c                                   |    4 
 drivers/net/dsa/mv88e6xxx/port.c                                   |   25 ++
 drivers/net/dsa/mv88e6xxx/port.h                                   |    1 
 drivers/net/ethernet/amazon/Kconfig                                |    2 
 drivers/net/ethernet/broadcom/genet/bcmgenet.c                     |    2 
 drivers/net/ethernet/hisilicon/hns3/hns3pf/hns3_enet.c             |   24 ++
 drivers/net/ethernet/intel/igb/igb_ptp.c                           |    8 
 drivers/net/ethernet/mellanox/mlx4/en_ethtool.c                    |    1 
 drivers/net/ethernet/mellanox/mlx5/core/eswitch.c                  |    2 
 drivers/net/ethernet/mellanox/mlxfw/mlxfw_fsm.c                    |    2 
 drivers/net/ethernet/qlogic/qed/qed.h                              |    2 
 drivers/net/ethernet/qlogic/qed/qed_main.c                         |   22 ++
 drivers/net/ethernet/qlogic/qed/qed_mcp.c                          |   27 +--
 drivers/net/ethernet/qlogic/qed/qed_mcp.h                          |    5 
 drivers/net/ethernet/qlogic/qed/qed_vf.c                           |    2 
 drivers/net/ethernet/qlogic/qlcnic/qlcnic_dcb.c                    |    2 
 drivers/net/ethernet/sfc/ptp.c                                     |    3 
 drivers/net/ethernet/ti/cpsw.c                                     |    1 
 drivers/net/macsec.c                                               |   20 ++
 drivers/net/ntb_netdev.c                                           |    2 
 drivers/net/phy/dp83867.c                                          |   37 ++++
 drivers/net/vrf.c                                                  |   19 +-
 drivers/net/wireless/ath/ath10k/pci.c                              |   23 +-
 drivers/net/wireless/ath/ath10k/usb.c                              |    8 
 drivers/net/wireless/ath/ath9k/ar9003_eeprom.c                     |    2 
 drivers/net/wireless/ath/wil6210/wmi.c                             |    9 -
 drivers/net/wireless/broadcom/brcm80211/brcmsmac/mac80211_if.c     |   30 +++
 drivers/net/wireless/broadcom/brcm80211/brcmsmac/main.h            |    1 
 drivers/net/wireless/cisco/airo.c                                  |    2 
 drivers/net/wireless/marvell/mwifiex/cfg80211.c                    |   13 +
 drivers/net/wireless/marvell/mwifiex/ioctl.h                       |    1 
 drivers/net/wireless/marvell/mwifiex/sta_ioctl.c                   |   11 -
 drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c              |    1 
 drivers/net/wireless/realtek/rtlwifi/rtl8192de/fw.c                |    2 
 drivers/net/wireless/ti/wlcore/vendor_cmd.c                        |    2 
 drivers/nfc/port100.c                                              |    2 
 drivers/ntb/hw/intel/ntb_hw_intel.c                                |    2 
 drivers/nvme/target/fcloop.c                                       |    1 
 drivers/of/unittest.c                                              |   43 ++++-
 drivers/pci/dwc/pci-keystone.c                                     |    3 
 drivers/pci/host/vmd.c                                             |    2 
 drivers/pinctrl/pinctrl-lpc18xx.c                                  |   10 -
 drivers/pinctrl/pinctrl-zynq.c                                     |    9 -
 drivers/pinctrl/qcom/pinctrl-spmi-gpio.c                           |   21 ++
 drivers/pinctrl/sunxi/pinctrl-sunxi.c                              |   11 -
 drivers/platform/x86/asus-nb-wmi.c                                 |   21 ++
 drivers/platform/x86/asus-wmi.c                                    |    2 
 drivers/platform/x86/asus-wmi.h                                    |    1 
 drivers/pwm/pwm-lpss.c                                             |   12 -
 drivers/rtc/rtc-s35390a.c                                          |    2 
 drivers/scsi/dc395x.c                                              |   12 -
 drivers/scsi/ips.c                                                 |    1 
 drivers/scsi/isci/host.c                                           |    8 
 drivers/scsi/isci/host.h                                           |    2 
 drivers/scsi/isci/request.c                                        |    4 
 drivers/scsi/isci/task.c                                           |    4 
 drivers/scsi/iscsi_tcp.c                                           |    3 
 drivers/scsi/lpfc/lpfc_els.c                                       |   28 ++-
 drivers/scsi/lpfc/lpfc_hbadisc.c                                   |   20 ++
 drivers/scsi/lpfc/lpfc_init.c                                      |    2 
 drivers/scsi/lpfc/lpfc_nportdisc.c                                 |    5 
 drivers/scsi/lpfc/lpfc_sli.c                                       |   11 -
 drivers/scsi/lpfc/lpfc_sli4.h                                      |    1 
 drivers/scsi/megaraid/megaraid_sas_base.c                          |    9 -
 drivers/scsi/mpt3sas/mpt3sas_base.c                                |    2 
 drivers/scsi/mpt3sas/mpt3sas_config.c                              |    4 
 drivers/scsi/mpt3sas/mpt3sas_scsih.c                               |   36 ++++
 drivers/spi/spi-omap2-mcspi.c                                      |   26 ---
 drivers/spi/spi-sh-msiof.c                                         |    4 
 drivers/staging/ccree/cc_hw_queue_defs.h                           |    6 
 drivers/staging/comedi/drivers/usbduxfast.c                        |   21 +-
 drivers/thermal/rcar_thermal.c                                     |    4 
 drivers/tty/pty.c                                                  |   14 +
 drivers/tty/synclink_gt.c                                          |   16 -
 drivers/usb/misc/appledisplay.c                                    |   15 +
 drivers/usb/misc/chaoskey.c                                        |   24 ++
 drivers/usb/serial/cp210x.c                                        |    1 
 drivers/usb/serial/mos7720.c                                       |    4 
 drivers/usb/serial/mos7840.c                                       |   16 +
 drivers/usb/serial/option.c                                        |    7 
 drivers/usb/usbip/stub_rx.c                                        |   50 +++--
 drivers/vhost/vsock.c                                              |   66 +++++--
 drivers/virtio/virtio_ring.c                                       |    2 
 drivers/w1/slaves/w1_ds2438.c                                      |   66 ++++++-
 drivers/xen/balloon.c                                              |    3 
 fs/btrfs/ctree.c                                                   |    4 
 fs/btrfs/super.c                                                   |    6 
 fs/ceph/inode.c                                                    |    1 
 fs/dlm/member.c                                                    |    5 
 fs/dlm/user.c                                                      |    2 
 fs/f2fs/data.c                                                     |    8 
 fs/f2fs/dir.c                                                      |    1 
 fs/f2fs/segment.c                                                  |    4 
 fs/gfs2/rgrp.c                                                     |   13 +
 fs/hfs/brec.c                                                      |    1 
 fs/hfs/btree.c                                                     |   41 ++--
 fs/hfs/btree.h                                                     |    1 
 fs/hfs/catalog.c                                                   |   16 +
 fs/hfs/extent.c                                                    |   10 -
 fs/hfs/inode.c                                                     |    2 
 fs/hfsplus/attributes.c                                            |   10 +
 fs/hfsplus/brec.c                                                  |    1 
 fs/hfsplus/btree.c                                                 |   44 +++--
 fs/hfsplus/catalog.c                                               |   24 ++
 fs/hfsplus/extents.c                                               |    8 
 fs/hfsplus/hfsplus_fs.h                                            |    2 
 fs/hfsplus/inode.c                                                 |    1 
 fs/ocfs2/buffer_head_io.c                                          |   77 +++++++--
 fs/ocfs2/dlm/dlmdebug.c                                            |    2 
 fs/ocfs2/dlmglue.c                                                 |    2 
 fs/ocfs2/move_extents.c                                            |   17 ++
 fs/ocfs2/stackglue.c                                               |    6 
 fs/ocfs2/stackglue.h                                               |    3 
 fs/ocfs2/xattr.c                                                   |   56 +++---
 fs/read_write.c                                                    |   33 +++
 fs/xfs/xfs_buf.c                                                   |   38 ++++
 include/linux/bitmap.h                                             |    9 -
 include/linux/kvm_host.h                                           |    1 
 include/linux/memory_hotplug.h                                     |    1 
 include/linux/mfd/intel_soc_pmic.h                                 |    1 
 include/linux/mfd/max8997.h                                        |    1 
 include/linux/mfd/mc13xxx.h                                        |    1 
 kernel/auditsc.c                                                   |    2 
 kernel/bpf/devmap.c                                                |    3 
 kernel/printk/printk.c                                             |    2 
 kernel/sched/fair.c                                                |   13 +
 kernel/sched/topology.c                                            |    2 
 mm/ksm.c                                                           |   14 -
 mm/memory_hotplug.c                                                |   48 +++--
 mm/page-writeback.c                                                |   33 +--
 net/core/dev.c                                                     |    2 
 net/core/rtnetlink.c                                               |   23 ++
 net/ipv6/tcp_ipv6.c                                                |    3 
 net/openvswitch/conntrack.c                                        |    3 
 net/sched/act_pedit.c                                              |    7 
 net/sunrpc/auth_gss/gss_krb5_seal.c                                |    1 
 net/sunrpc/xprtsock.c                                              |   34 ++--
 net/unix/af_unix.c                                                 |    2 
 net/vmw_vsock/virtio_transport_common.c                            |   15 +
 net/wireless/ap.c                                                  |    2 
 net/wireless/core.h                                                |    2 
 net/wireless/sme.c                                                 |    8 
 sound/firewire/isight.c                                            |   10 -
 sound/i2c/cs8427.c                                                 |    2 
 sound/soc/tegra/tegra_sgtl5000.c                                   |   17 +-
 tools/gpio/Build                                                   |    1 
 tools/gpio/Makefile                                                |   10 -
 tools/objtool/arch/x86/tools/gen-insn-attr-x86.awk                 |    4 
 tools/power/acpi/tools/acpidump/apmain.c                           |    2 
 tools/testing/selftests/ftrace/test.d/kprobe/kprobe_args_syntax.tc |    3 
 tools/testing/selftests/powerpc/cache_shape/Makefile               |    9 -
 tools/testing/selftests/powerpc/signal/Makefile                    |   11 -
 tools/testing/selftests/powerpc/switch_endian/Makefile             |    1 
 tools/testing/selftests/watchdog/watchdog-test.c                   |   16 +
 tools/usb/usbip/libsrc/usbip_host_common.c                         |    8 
 virt/kvm/kvm_main.c                                                |   26 ++-
 239 files changed, 1937 insertions(+), 780 deletions(-)

Adrian Bunk (1):
mwifiex: Fix NL80211_TX_POWER_LIMITED

Al Viro (2):
pty: fix compat ioctls
synclink_gt(): fix compat_ioctl()

Alan Stern (1):
media: usbvision: Fix races among open, close, and disconnect

Aleksander Morgado (2):
USB: serial: option: add support for DW5821e with eSIM support
USB: serial: option: add support for Foxconn T77W968 LTE modules

Alexander Kapshuk (1):
x86/insn: Fix awk regexp warnings

Alexander Popov (1):
media: vivid: Fix wrong locking that causes race conditions on streaming stop

Alexandre Belloni (1):
clk: at91: audio-pll: fix audio pmc type

Alexey Brodkin (1):
ARC: perf: Accommodate big-endian CPU

Ali MJ Al-Nasrawy (2):
brcmsmac: AP mode: update beacon when TIM changes
brcmsmac: never log "tid x is not agg'able" by default

Andreas Gruenbacher (1):
gfs2: Fix marking bitmaps non-full

Andrey Ryabinin (2):
mm/ksm.c: don't WARN if page is still mapped in remove_stable_node()
arm64: lib: use C string functions with KASAN enabled

Andy Shevchenko (1):
mfd: intel_soc_pmic_bxtwc: Chain power button IRQs as well

Angelo Dureghello (1):
m68k: fix command-line parsing when passed from u-boot

Anton Ivanov (1):
um: Make line/tty semantics use true write IRQ

Aravinda Prasad (1):
powerpc/pseries: Export raw per-CPU VPA data via debugfs

Arnd Bergmann (2):
openvswitch: fix linking without CONFIG_NF_CONNTRACK_LABELS
btrfs: avoid link error with CONFIG_NO_AUTO_INLINE

Bart Van Assche (1):
nvmet-fcloop: suppress a compiler warning

Benjamin Herrenschmidt (1):
macintosh/windfarm_smu_sat: Fix debug output

Bernd Porr (1):
staging: comedi: usbduxfast: usbduxfast_ai_cmdtest rounding error

Bo Yan (1):
cpufreq: Skip cpufreq resume if it's not suspended

Brian Masney (1):
pinctrl: qcom: spmi-gpio: fix gpio-hog related boot issues

Carl Huang (1):
ath10k: allocate small size dma memory in ath10k_pci_diag_write_mem

Changwei Ge (1):
ocfs2: don't put and assigning null to bh allocated outside

Chao Yu (1):
f2fs: fix to spread clear_cold_data()

Chaotian Jing (1):
mmc: mediatek: fix cannot receive new request when msdc_cmd_is_ready fail

Chester Lin (1):
ARM: 8904/1: skip nomap memblocks while finding the lowmem/highmem boundary

Chris Wilson (1):
drm/i915/userptr: Try to acquire the page lock around set_page_dirty()

Christoph Hellwig (2):
scsi: dc395x: fix dma API usage in srb_done
scsi: dc395x: fix DMA API usage in sg_update_list

Christophe JAILLET (2):
pinctrl: sunxi: Fix a memory leak in 'sunxi_pinctrl_build_state()'
wlcore: Fix the return value in case of error in 'wlcore_vendor_cmd_smart_config_start()'

Christopher M. Riedl (1):
powerpc/64s: support nospectre_v2 cmdline option

Colin Ian King (3):
usbip: tools: fix atoi() on non-null terminated string fs/hfs/extent.c: fix array out of bounds read of array extent
ACPICA: Use %d for signed int print formatting instead of %u

Dan Carpenter (5):
net: rtnetlink: prevent underflows in do_setvfinfo()
powerpc: Fix signedness bug in update_flash_db() EDAC, thunderx: Fix memory leak in thunderx_l2c_threaded_isr()
qlcnic: fix a return in qlcnic_dcb_get_capability()
wireless: airo: potential buffer overflow in sprintf()

Darrick J. Wong (1):
vfs: avoid problematic remapping requests into partial EOF block

Dave Chinner (2):
xfs: fix use-after-free race in xfs_buf_rele mm/page-writeback.c: fix range_cyclic writeback vs writepages deadlock

Dave Jiang (1):
ntb: intel: fix return value for ndev_vec_mask()

David Ahern (1):
ipv6: Fix handling of LLA with VRF and sockets bound to VRF

David Hildenbrand (2):
mm/memory_hotplug: make add_memory() take the device_hotplug_lock mm/memory_hotplug: don't access uninitialized memmaps in shrink_zone_span()

David S. Miller (2):
sparc: Fix parport build warnings.
sparc64: Rework xchg() definition to avoid warnings.

Davide Caratti (1):
net/sched: act_pedit: fix WARN() in the traffic path

Denis Efremov (1):
ath9k_hw: fix uninitialized variable data

Devesh Sharma (1):
RDMA/bnxt_re: Fix qp async event reporting

Duncan Laurie (1):
gsmi: Fix bug in append_to_eventlog sysfs handler

Eran Ben Elisha (1):
net/mlxfw: Verify FSM error code translation doesn't exceed array size

Eric Dumazet (1):
net: do not abort bulk send on BQL status

Ernesto A. Fernández (8):
hfsplus: fix BUG on bnode parent update
hfs: fix BUG on bnode parent update
hfsplus: prevent btree data loss on ENOSPC
hfs: prevent btree data loss on ENOSPC
hfsplus: fix return value of hfsplus_get_block()
hfs: fix return value of hfs_get_block()
hfsplus: update timestamps on truncate()
hfs: update timestamp on truncate()

Fabio Estevam (1):
mfd: mc13xxx-core: Fix PMIC shutdown when reading ADC values

Felipe Rechia (1):
powerpc/process: Fix flush_all_to_thread for SPE

Florian Fainelli (1):
net: dsa: bcm_sf2: Turn on PHY to allow successful registration

Frank Rowand (1):
of: unittest: allow base devicetree to have symbol metadata

Gang He (1):
ocfs2: remove ocfs2_is_o2cb_active()

Geert Uytterhoeven (1):
thermal: rcar_thermal: Prevent hardware access during system suspend

Greg Kroah-Hartman (2):
usb-serial: cp201x: support Mark-10 digital force gauge Linux 4.14.157

Gustavo A. R. Silva (2):
scsi: ips: fix missing break in switch
rtl8xxxu: Fix missing break in switch

Halil Pasic (1):
virtio_ring: fix return code on DMA mapping fails

Hans de Goede (2):
platform/x86: asus-wmi: Only Tell EC the OS will handle display hotkeys from asus_nb_wmi
pwm: lpss: Only set update bit if we are actually changing the settings

Hari Vyas (1):
arm64: fix for bad_mode() handler to always result in panic

Heinz Mauelshagen (1):
dm raid: avoid bitmap with raid4/5/6 journal device

Hewenliang (1):
usbip: tools: fix fd leakage in the function of read_attr_usbip_status

Huazhong Tan (1):
net: hns3: bugfix for buffer not free problem during resetting

Hui Peng (1):
ath10k: Fix a NULL-ptr-deref bug in ath10k_usb_alloc_urb_from_pipe

Icenowy Zheng (1):
clk: sunxi-ng: enable so-said LDOs for A64 SoC's pll-mipi clock

Ivan Khoronzhuk (1):
net: ethernet: ti: cpsw: unsync mcast entries while switch promisc mode

J. Bruce Fields (1):
sunrpc: safely reallow resvport min/max inversion

James Smart (2):
scsi: lpfc: fcoe: Fix link down issue after 1000+ link bounces
scsi: lpfc: Correct loss of fc4 type on remote port address change

Jens Axboe (2):
skd: fixup usage of legacy IO API
cdrom: don't attempt to fiddle with cdo->capability

Jerry Hoemann (1):
selftests: watchdog: Fix error message.

Jia-Ju Bai (1):
fs/ocfs2/dlm/dlmdebug.c: fix a sleep-in-atomic-context bug in dlm_print_one_mle()

Jianchao Wang (1):
block: fix the DISCARD request merge

Joel Stanley (3):
powerpc/boot: Disable vector instructions powerpc/xmon: Relax frame size for clang selftests/powerpc/signal: Fix out-of-tree build

Johan Hovold (2):
USB: serial: mos7720: fix remote wakeup
USB: serial: mos7840: fix remote wakeup

Johannes Berg (1):
cfg80211: call disconnect_wk when AP stops

John Pittman (1):
md/raid10: prevent access of uninitialized resync_pages offset

Jon Derrick (1):
PCI: vmd: Detach resources after stopping root bus

Jon Mason (1):
ntb_netdev: fix sleep time mismatch

Joseph Qi (1):
Revert "fs: ocfs2: fix possible null-pointer dereferences in ocfs2_xa_prepare_entry()"

Julien Folly (1):
w1: IAD Register is yet readable trough iad sys file. Fix snprintf (%u for unsigned, count for max size).

Kai Shen (1):
cpufreq: Add NULL checks to show() and store() methods of cpufreq

Kiernan Hager (1):
platform/x86: asus-nb-wmi: Support ALS on the Zenbook UX430UQ

Kishon Vijay Abraham I (1):
PCI: keystone: Use quirk to limit MRRS for K2G

Kyeongdon Kim (1):
net: fix warning in af_unix

Larry Chen (1):
ocfs2: fix clusters leak in ocfs2_defrag_extent()

Laura Abbott (1):
tools: gpio: Correctly add make dependencies for gpio_utils

Laurent Pinchart (1):
media: uvcvideo: Fix error path in control parsing failure

Laurent Vivier (1):
virtio_console: allocate inbufs in add_port() only if it is needed

Lior David (1):
wil6210: fix locking in wmi_call

Lubomir Rintel (1):
clk: mmp2: fix the clock id for sdh2_clk and sdh3_clk

Luigi Rizzo (1):
net/mlx4_en: fix mlx4 ethtool -N insertion

Marcel Ziswiler (1):
ASoC: tegra_sgtl5000: fix device_node refcounting

Marek Behún (1):

      net: dsa: mv88e6xxx: Fix 88E6141/6341 2500mbps SERDES speed

Marek Szyprowski (1):
mfd: max8997: Enale irq-wakeup unconditionally

Martin Habets (1):
sfc: Only cancel the PPS workqueue if it exists

Masahiro Yamada (4):
i2c: uniphier-f: make driver robust against concurrency
i2c: uniphier-f: fix occasional timeout error
i2c: uniphier-f: fix race condition when IRQ is cleared
i2c: uniphier-f: fix timeout error after reading 8 bytes

Masami Hiramatsu (1):
selftests/ftrace: Fix to test kprobe $comm arg only if available

Mattias Jacobsson (1):
USB: misc: appledisplay: fix backlight update_status return code

Max Uvarov (2):
net: phy: dp83867: fix speed 10 in sgmii mode
net: phy: dp83867: increase SGMII autoneg timer duration

Michael Ellerman (4):
selftests/powerpc/switch_endian: Fix out-of-tree build selftests/powerpc/cache_shape: Fix out-of-tree build powerpc/book3s64: Fix link stack flush on context switch
KVM: PPC: Book3S HV: Flush link stack on guest exit to host kernel

Mike Manning (1):
vrf: mark skb for multicast or link-local as enslaved to VRF

Miroslav Lichvar (1):
igb: shorten maximum PHC timecounter update interval

Nathan Chancellor (9):
scsi: isci: Use proper enumerated type in atapi_d2h_reg_frame_handler
scsi: isci: Change sci_controller_start_task's return type to sci_status
scsi: iscsi_tcp: Explicitly cast param in iscsi_sw_tcp_host_get_param
crypto: ccree - avoid implicit enum conversion
atm: zatm: Fix empty body Clang warnings
rtc: s35390a: Change buf's type to u8 in s35390a_init
mISDN: Fix type of switch control variable in ctrl_teimanager
pinctrl: lpc18xx: Use define directive for PIN_CONFIG_GPIO_PIN_INT
pinctrl: zynq: Use define directive for PIN_CONFIG_IO_STANDARD

Navid Emamdoost (1):
nbd: prevent memory leak

Netanel Belgazal (1):
net: ena: Fix Kconfig dependency on X86

Nikolay Borisov (1):
btrfs: handle error of get_old_root

Oliver Neukum (4):
nfc: port100: handle command failure cleanly
media: b2c2-flexcop-usb: add sanity checking
USB: chaoskey: fix error case of a timeout
appledisplay: fix error handling in the scheduled work

Omar Sandoval (1):
amiflop: clean up on errors during setup

Pavel Löbl (1):
USB: serial: mos7840: add USB ID to support Moxa UPort 2210

Peter Zijlstra (1):
sched/topology: Fix off by one bug

Philipp Klocke (1):
ALSA: i2c/cs8427: Fix int to char conversion

Rahul Verma (1):
qed: Align local and global PTT to propagate through the APIs.

Rasmus Villemoes (2):
linux/bitmap.h: handle constant zero-size bitmaps correctly linux/bitmap.h: fix type of nbits in bitmap_shift_right()

Richard Guy Briggs (1):
audit: print empty EXECVE args

Roi Dayan (1):
net/mlx5e: Fix set vf link state error flow

Sabrina Dubroca (2):
macsec: update operstate when lower device changes
macsec: let the administrator set UP state even if lowerdev is down

Sam Bobroff (1):
powerpc/eeh: Fix use of EEH_PE_KEEP on wrong field

Sapthagiri Baratam (1):
mfd: arizona: Correct calling of runtime_put_sync

Sasha Levin (1):
x86/hyperv: mark hyperv_init as __init function

Sean Christopherson (2):
KVM: nVMX: reset cache/shadows when switching loaded VMCS
KVM: MMU: Do not treat ZONE_DEVICE pages as being reserved

Sean Young (1):
media: imon: invalid dereference in imon_touch_event

Sergei Shtylyov (1):
spi: sh-msiof: fix deferred probing

Sergey Senozhatsky (1):
printk: fix integer overflow in setup_log_buf()

Shaokun Zhang (1):
rtlwifi: rtl8192de: Fix misleading REG_MCUFWDL information

Shivasharan S (2):
scsi: megaraid_sas: Fix msleep granularity
scsi: megaraid_sas: Fix goto labels in error handling

Shuah Khan (Samsung OSG) (1):
selftests: watchdog: fix message when /dev/watchdog open fails

Sriram R (1):
cfg80211: Prevent regulatory restore during STA disconnect in concurrent interfaces

Stefano Garzarella (1):
vhost/vsock: split packets to send using multiple buffers

Steven Rostedt (VMware) (1):
kprobes, x86/ptrace.h: Make regs_get_kernel_stack_nth() not fault on bad stack

Suganath Prabu (3):
scsi: mpt3sas: Fix Sync cache command failure during driver unload
scsi: mpt3sas: Don't modify EEDPTagMode field setting on SAS3.5 HBA devices
scsi: mpt3sas: Fix driver modifying persistent data in Manufacturing page11

Sun Ke (1):
nbd:fix memory leak in nbd_get_socket()

Suwan Kim (1):
usbip: Fix uninitialized symbol 'nents' in stub_recv_cmd_submit()

Taehee Yoo (1):
bpf: devmap: fix wrong interface selection in notifier_call

Takashi Sakamoto (1):
ALSA: isight: fix leak of reference to firewire unit in error path of .probe callback

Thierry Reding (1):
gpio: max77620: Fixup debounce delays

Thomas Richter (1):
s390/perf: Return error when debug_register fails

Tomas Bortoli (1):
Bluetooth: Fix invalid-free in bcsp_close()

Trond Myklebust (1):
SUNRPC: Fix a compile warning for cmpxchg64()

Tycho Andersen (2):
dlm: fix invalid free
dlm: don't leak kernel pointer to userspace

Ulf Hansson (1):
PM / Domains: Deal with multiple states but no governor in genpd

Uros Bizjak (1):
KVM/x86: Fix invvpid and invept register operand size in 64-bit mode

Valentin Schneider (1):

      sched/fair: Don't increase sd->balance_interval on newidle balance

Vandana BN (1):
media: vivid: Set vid_cap_streaming and vid_out_streaming to true

Victor Kamensky (1):
arm64: makefile fix build of .i file in external module case

Vignesh R (2):
spi: omap2-mcspi: Set FIFO DMA trigger level to word length
spi: omap2-mcspi: Fix DMA and FIFO event trigger size mismatch

Vito Caputo (1):
media: cxusb: detect cxusb_ctrl_msg error in query

Waiman Long (2):
x86/speculation: Fix incorrect MDS/TAA mitigation status x86/speculation: Fix redundant MDS mitigation message

Wenwen Wang (1):
misc: mic: fix a DMA pool free failure

Yan, Zheng (1):
ceph: fix dentry leak in ceph_readdir_prepopulate

YueHaibing (1):
net: bcmgenet: return correct value 'ret' from bcmgenet_power_down

zhong jiang (1):
mm/memory_hotplug: Do not unlock when fails to take the device_hotplug_lock

author maintainer
#1 lore raw
Documentation/admin-guide/hw-vuln/mds.rst +5 -2
index e3a796c0d3a2..2d19c9f4c1fe 100644
@@ -265,8 +265,11 @@ time with the option "mds=". The valid arguments for this option are:
 
   ============  =============================================================
 
-Not specifying this option is equivalent to "mds=full".
-
+Not specifying this option is equivalent to "mds=full". For processors
+that are affected by both TAA (TSX Asynchronous Abort) and MDS,
+specifying just "mds=off" without an accompanying "tsx_async_abort=off"
+will have no effect as the same mitigation is used for both
+vulnerabilities.
 
 Mitigation selection guide
 --------------------------
Documentation/admin-guide/hw-vuln/tsx_async_abort.rst +4 -1
index fddbd7579c53..af6865b822d2 100644
@@ -174,7 +174,10 @@ the option "tsx_async_abort=". The valid arguments for this option are:
                 CPU is not vulnerable to cross-thread TAA attacks.
   ============  =============================================================
 
-Not specifying this option is equivalent to "tsx_async_abort=full".
+Not specifying this option is equivalent to "tsx_async_abort=full". For
+processors that are affected by both TAA and MDS, specifying just
+"tsx_async_abort=off" without an accompanying "mds=off" will have no
+effect as the same mitigation is used for both vulnerabilities.
 
 The kernel command line also allows to control the TSX feature using the
 parameter "tsx=" on CPUs which support TSX control. MSR_IA32_TSX_CTRL is used
Documentation/admin-guide/kernel-parameters.txt +11 -0
index 05596e05bc71..b0da6050a254 100644
@@ -2254,6 +2254,12 @@
 				     SMT on vulnerable CPUs
 			off        - Unconditionally disable MDS mitigation
 
+			On TAA-affected machines, mds=off can be prevented by
+			an active TAA mitigation as both vulnerabilities are
+			mitigated with the same mechanism so in order to disable
+			this mitigation, you need to specify tsx_async_abort=off
+			too.
+
 			Not specifying this option is equivalent to
 			mds=full.
 
@@ -4588,6 +4594,11 @@
 				     vulnerable to cross-thread TAA attacks.
 			off        - Unconditionally disable TAA mitigation
 
+			On MDS-affected machines, tsx_async_abort=off can be
+			prevented by an active MDS mitigation as both vulnerabilities
+			are mitigated with the same mechanism so in order to disable
+			this mitigation, you need to specify mds=off too.
+
 			Not specifying this option is equivalent to
 			tsx_async_abort=full.  On CPUs which are MDS affected
 			and deploy MDS mitigation, TAA mitigation is not
Makefile +1 -1
index b1db48ad832e..dad90f53faeb 100644
@@ -1,7 +1,7 @@
 # SPDX-License-Identifier: GPL-2.0
 VERSION = 4
 PATCHLEVEL = 14
-SUBLEVEL = 156
+SUBLEVEL = 157
 EXTRAVERSION =
 NAME = Petit Gorille
 
arch/arc/kernel/perf_event.c +2 -2
index 2ce24e74f879..a509b77ef80d 100644
@@ -488,8 +488,8 @@ static int arc_pmu_device_probe(struct platform_device *pdev)
 	/* loop thru all available h/w condition indexes */
 	for (j = 0; j < cc_bcr.c; j++) {
 		write_aux_reg(ARC_REG_CC_INDEX, j);
-		cc_name.indiv.word0 = read_aux_reg(ARC_REG_CC_NAME0);
-		cc_name.indiv.word1 = read_aux_reg(ARC_REG_CC_NAME1);
+		cc_name.indiv.word0 = le32_to_cpu(read_aux_reg(ARC_REG_CC_NAME0));
+		cc_name.indiv.word1 = le32_to_cpu(read_aux_reg(ARC_REG_CC_NAME1));
 
 		/* See if it has been mapped to a perf event_id */
 		for (i = 0; i < ARRAY_SIZE(arc_pmu_ev_hw_map); i++) {
arch/arm/mm/mmu.c +3 -0
index 70e560cf8ca0..d8cbe772f690 100644
@@ -1195,6 +1195,9 @@ void __init adjust_lowmem_bounds(void)
 		phys_addr_t block_start = reg->base;
 		phys_addr_t block_end = reg->base + reg->size;
 
+		if (memblock_is_nomap(reg))
+			continue;
+
 		if (reg->base < vmalloc_limit) {
 			if (block_end > lowmem_limit)
 				/*
arch/arm64/Makefile +2 -0
index 0c5f70e6d5cf..8c4bc5a2c61f 100644
@@ -149,6 +149,7 @@ archclean:
 	$(Q)$(MAKE) $(clean)=$(boot)
 	$(Q)$(MAKE) $(clean)=$(boot)/dts
 
+ifeq ($(KBUILD_EXTMOD),)
 # We need to generate vdso-offsets.h before compiling certain files in kernel/.
 # In order to do that, we should use the archprepare target, but we can't since
 # asm-offsets.h is included in some files used to generate vdso-offsets.h, and
@@ -158,6 +159,7 @@ archclean:
 prepare: vdso_prepare
 vdso_prepare: prepare0
 	$(Q)$(MAKE) $(build)=arch/arm64/kernel/vdso include/generated/vdso-offsets.h
+endif
 
 define archhelp
   echo  '* Image.gz      - Compressed kernel image (arch/$(ARCH)/boot/Image.gz)'
arch/arm64/include/asm/string.h +8 -6
index dd95d33a5bd5..03a6c256b7ec 100644
@@ -16,6 +16,7 @@
 #ifndef __ASM_STRING_H
 #define __ASM_STRING_H
 
+#ifndef CONFIG_KASAN
 #define __HAVE_ARCH_STRRCHR
 extern char *strrchr(const char *, int c);
 
@@ -34,6 +35,13 @@ extern __kernel_size_t strlen(const char *);
 #define __HAVE_ARCH_STRNLEN
 extern __kernel_size_t strnlen(const char *, __kernel_size_t);
 
+#define __HAVE_ARCH_MEMCMP
+extern int memcmp(const void *, const void *, size_t);
+
+#define __HAVE_ARCH_MEMCHR
+extern void *memchr(const void *, int, __kernel_size_t);
+#endif
+
 #define __HAVE_ARCH_MEMCPY
 extern void *memcpy(void *, const void *, __kernel_size_t);
 extern void *__memcpy(void *, const void *, __kernel_size_t);
@@ -42,16 +50,10 @@ extern void *__memcpy(void *, const void *, __kernel_size_t);
 extern void *memmove(void *, const void *, __kernel_size_t);
 extern void *__memmove(void *, const void *, __kernel_size_t);
 
-#define __HAVE_ARCH_MEMCHR
-extern void *memchr(const void *, int, __kernel_size_t);
-
 #define __HAVE_ARCH_MEMSET
 extern void *memset(void *, int, __kernel_size_t);
 extern void *__memset(void *, int, __kernel_size_t);
 
-#define __HAVE_ARCH_MEMCMP
-extern int memcmp(const void *, const void *, size_t);
-
 #ifdef CONFIG_ARCH_HAS_UACCESS_FLUSHCACHE
 #define __HAVE_ARCH_MEMCPY_FLUSHCACHE
 void memcpy_flushcache(void *dst, const void *src, size_t cnt);
arch/arm64/kernel/arm64ksyms.c +5 -2
index 66be504edb6c..9eedf839e739 100644
@@ -44,20 +44,23 @@ EXPORT_SYMBOL(__arch_copy_in_user);
 EXPORT_SYMBOL(memstart_addr);
 
 	/* string / mem functions */
+#ifndef CONFIG_KASAN
 EXPORT_SYMBOL(strchr);
 EXPORT_SYMBOL(strrchr);
 EXPORT_SYMBOL(strcmp);
 EXPORT_SYMBOL(strncmp);
 EXPORT_SYMBOL(strlen);
 EXPORT_SYMBOL(strnlen);
+EXPORT_SYMBOL(memcmp);
+EXPORT_SYMBOL(memchr);
+#endif
+
 EXPORT_SYMBOL(memset);
 EXPORT_SYMBOL(memcpy);
 EXPORT_SYMBOL(memmove);
 EXPORT_SYMBOL(__memset);
 EXPORT_SYMBOL(__memcpy);
 EXPORT_SYMBOL(__memmove);
-EXPORT_SYMBOL(memchr);
-EXPORT_SYMBOL(memcmp);
 
 	/* atomic bitops */
 EXPORT_SYMBOL(set_bit);
arch/arm64/kernel/traps.c +0 -1
index a4e49e947684..5ae9c86c30d1 100644
@@ -648,7 +648,6 @@ asmlinkage void bad_mode(struct pt_regs *regs, int reason, unsigned int esr)
 		handler[reason], smp_processor_id(), esr,
 		esr_get_class_string(esr));
 
-	die("Oops - bad mode", regs, 0);
 	local_irq_disable();
 	panic("bad mode");
 }
arch/arm64/lib/memchr.S +1 -1
index 4444c1d25f4b..0f164a4baf52 100644
@@ -30,7 +30,7 @@
  * Returns:
  *	x0 - address of first occurrence of 'c' or 0
  */
-ENTRY(memchr)
+WEAK(memchr)
 	and	w1, w1, #0xff
 1:	subs	x2, x2, #1
 	b.mi	2f
arch/arm64/lib/memcmp.S +1 -1
index 2a4e239bd17a..fb295f52e9f8 100644
@@ -58,7 +58,7 @@ pos		.req	x11
 limit_wd	.req	x12
 mask		.req	x13
 
-ENTRY(memcmp)
+WEAK(memcmp)
 	cbz	limit, .Lret0
 	eor	tmp1, src1, src2
 	tst	tmp1, #7
arch/arm64/lib/strchr.S +1 -1
index dae0cf5591f9..7c83091d1bcd 100644
@@ -29,7 +29,7 @@
  * Returns:
  *	x0 - address of first occurrence of 'c' or 0
  */
-ENTRY(strchr)
+WEAK(strchr)
 	and	w1, w1, #0xff
 1:	ldrb	w2, [x0], #1
 	cmp	w2, w1
arch/arm64/lib/strcmp.S +1 -1
index 471fe61760ef..7d5d15398bfb 100644
@@ -60,7 +60,7 @@ tmp3		.req	x9
 zeroones	.req	x10
 pos		.req	x11
 
-ENTRY(strcmp)
+WEAK(strcmp)
 	eor	tmp1, src1, src2
 	mov	zeroones, #REP8_01
 	tst	tmp1, #7
arch/arm64/lib/strlen.S +1 -1
index 55ccc8e24c08..8e0b14205dcb 100644
@@ -56,7 +56,7 @@ pos		.req	x12
 #define REP8_7f 0x7f7f7f7f7f7f7f7f
 #define REP8_80 0x8080808080808080
 
-ENTRY(strlen)
+WEAK(strlen)
 	mov	zeroones, #REP8_01
 	bic	src, srcin, #15
 	ands	tmp1, srcin, #15
arch/arm64/lib/strncmp.S +1 -1
index e267044761c6..66bd145935d9 100644
@@ -64,7 +64,7 @@ limit_wd	.req	x13
 mask		.req	x14
 endloop		.req	x15
 
-ENTRY(strncmp)
+WEAK(strncmp)
 	cbz	limit, .Lret0
 	eor	tmp1, src1, src2
 	mov	zeroones, #REP8_01
arch/arm64/lib/strnlen.S +1 -1
index eae38da6e0bb..355be04441fe 100644
@@ -59,7 +59,7 @@ limit_wd	.req	x14
 #define REP8_7f 0x7f7f7f7f7f7f7f7f
 #define REP8_80 0x8080808080808080
 
-ENTRY(strnlen)
+WEAK(strnlen)
 	cbz	limit, .Lhit_limit
 	mov	zeroones, #REP8_01
 	bic	src, srcin, #15
arch/arm64/lib/strrchr.S +1 -1
index 61eabd9a289a..f3b9f8e2917c 100644
@@ -29,7 +29,7 @@
  * Returns:
  *	x0 - address of last occurrence of 'c' or 0
  */
-ENTRY(strrchr)
+WEAK(strrchr)
 	mov	x3, #0
 	and	w1, w1, #0xff
 1:	ldrb	w2, [x0], #1
arch/m68k/kernel/uboot.c +1 -1
index b29c3b241e1b..107082877064 100644
@@ -102,5 +102,5 @@ __init void process_uboot_commandline(char *commandp, int size)
 	}
 
 	parse_uboot_commandline(commandp, len);
-	commandp[size - 1] = 0;
+	commandp[len - 1] = 0;
 }
arch/powerpc/boot/Makefile +2 -2
index e2a5a932c24a..5807c9d8e56d 100644
@@ -24,8 +24,8 @@ compress-$(CONFIG_KERNEL_GZIP) := CONFIG_KERNEL_GZIP
 compress-$(CONFIG_KERNEL_XZ)   := CONFIG_KERNEL_XZ
 
 BOOTCFLAGS    := -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs \
-		 -fno-strict-aliasing -Os -msoft-float -pipe \
-		 -fomit-frame-pointer -fno-builtin -fPIC -nostdinc \
+		 -fno-strict-aliasing -Os -msoft-float -mno-altivec -mno-vsx \
+		 -pipe -fomit-frame-pointer -fno-builtin -fPIC -nostdinc \
 		 -D$(compress-y)
 
 BOOTCC := $(CC)
arch/powerpc/include/asm/asm-prototypes.h +3 -0
index ba4c75062d49..2d4444981c2c 100644
@@ -129,7 +129,10 @@ unsigned long prepare_ftrace_return(unsigned long parent, unsigned long ip);
 /* Patch sites */
 extern s32 patch__call_flush_count_cache;
 extern s32 patch__flush_count_cache_return;
+extern s32 patch__flush_link_stack_return;
+extern s32 patch__call_kvm_flush_link_stack;
 
 extern long flush_count_cache;
+extern long kvm_flush_link_stack;
 
 #endif /* _ASM_POWERPC_ASM_PROTOTYPES_H */
arch/powerpc/include/asm/security_features.h +3 -0
index 759597bf0fd8..ccf44c135389 100644
@@ -81,6 +81,9 @@ static inline bool security_ftr_enabled(unsigned long feature)
 // Software required to flush count cache on context switch
 #define SEC_FTR_FLUSH_COUNT_CACHE	0x0000000000000400ull
 
+// Software required to flush link stack on context switch
+#define SEC_FTR_FLUSH_LINK_STACK	0x0000000000001000ull
+
 
 // Features enabled by default
 #define SEC_FTR_DEFAULT \
arch/powerpc/kernel/eeh_pe.c +1 -1
index 8545a9523b9b..7339ca4fdc19 100644
@@ -381,7 +381,7 @@ int eeh_add_to_parent_pe(struct eeh_dev *edev)
 		while (parent) {
 			if (!(parent->type & EEH_PE_INVALID))
 				break;
-			parent->type &= ~(EEH_PE_INVALID | EEH_PE_KEEP);
+			parent->type &= ~EEH_PE_INVALID;
 			parent = parent->parent;
 		}
 
arch/powerpc/kernel/entry_64.S +6 -0
index 12395895b9aa..02a0bf52aec0 100644
@@ -524,6 +524,7 @@ flush_count_cache:
 	/* Save LR into r9 */
 	mflr	r9
 
+	// Flush the link stack
 	.rept 64
 	bl	.+4
 	.endr
@@ -533,6 +534,11 @@ flush_count_cache:
 	.balign 32
 	/* Restore LR */
 1:	mtlr	r9
+
+	// If we're just flushing the link stack, return here
+3:	nop
+	patch_site 3b patch__flush_link_stack_return
+
 	li	r9,0x7fff
 	mtctr	r9
 
arch/powerpc/kernel/process.c +1 -2
index 5e5da2073fdf..ba0d4f9a99ba 100644
@@ -567,12 +567,11 @@ void flush_all_to_thread(struct task_struct *tsk)
 	if (tsk->thread.regs) {
 		preempt_disable();
 		BUG_ON(tsk != current);
-		save_all(tsk);
-
 #ifdef CONFIG_SPE
 		if (tsk->thread.regs->msr & MSR_SPE)
 			tsk->thread.spefscr = mfspr(SPRN_SPEFSCR);
 #endif
+		save_all(tsk);
 
 		preempt_enable();
 	}
arch/powerpc/kernel/security.c +68 -6

128 lines not on this page · raw message

arch/powerpc/kvm/book3s_hv_rmhandlers.S +27 -0
index 663a398449b7..46ea42f40334 100644
@@ -18,6 +18,7 @@
  */
 
 #include <asm/ppc_asm.h>
+#include <asm/code-patching-asm.h>
 #include <asm/kvm_asm.h>
 #include <asm/reg.h>
 #include <asm/mmu.h>
@@ -1445,6 +1446,10 @@ mc_cont:
 1:
 #endif /* CONFIG_KVM_XICS */
 
+	/* Possibly flush the link stack here. */
+1:	nop
+	patch_site 1b patch__call_kvm_flush_link_stack
+
 	stw	r12, STACK_SLOT_TRAP(r1)
 	mr 	r3, r12
 	/* Increment exit count, poke other threads to exit */
@@ -1957,6 +1962,28 @@ END_MMU_FTR_SECTION_IFSET(MMU_FTR_TYPE_RADIX)
 	mtlr	r0
 	blr
 
+.balign 32
+.global kvm_flush_link_stack
+kvm_flush_link_stack:
+	/* Save LR into r0 */
+	mflr	r0
+
+	/* Flush the link stack. On Power8 it's up to 32 entries in size. */
+	.rept 32
+	bl	.+4
+	.endr
+
+	/* And on Power9 it's up to 64. */
+BEGIN_FTR_SECTION
+	.rept 32
+	bl	.+4
+	.endr
+END_FTR_SECTION_IFSET(CPU_FTR_ARCH_300)
+
+	/* Restore LR */
+	mtlr	r0
+	blr
+
 /*
  * Check whether an HDSI is an HPTE not found fault or something else.
  * If it is an HPTE not found fault that is due to the guest accessing
arch/powerpc/platforms/ps3/os-area.c +1 -1
index 3db53e8aff92..9b2ef76578f0 100644
@@ -664,7 +664,7 @@ static int update_flash_db(void)
 	db_set_64(db, &os_area_db_id_rtc_diff, saved_params.rtc_diff);
 
 	count = os_area_flash_write(db, sizeof(struct os_area_db), pos);
-	if (count < sizeof(struct os_area_db)) {
+	if (count < 0 || count < sizeof(struct os_area_db)) {
 		pr_debug("%s: os_area_flash_write failed %zd\n", __func__,
 			 count);
 		error = count < 0 ? count : -EIO;
arch/powerpc/platforms/pseries/hotplug-memory.c +1 -1
index 93e09f108ca1..99a3cf51c5ba 100644
@@ -787,7 +787,7 @@ static int dlpar_add_lmb(struct of_drconf_cell *lmb)
 	nid = memory_add_physaddr_to_nid(lmb->base_addr);
 
 	/* Add the memory */
-	rc = add_memory(nid, lmb->base_addr, block_sz);
+	rc = __add_memory(nid, lmb->base_addr, block_sz);
 	if (rc) {
 		dlpar_remove_device_tree_lmb(lmb);
 		return rc;
arch/powerpc/platforms/pseries/lpar.c +54 -0

63 lines not on this page · raw message

arch/powerpc/xmon/Makefile +6 -0
index 549e99e71112..ac5ee067aa51 100644
@@ -13,6 +13,12 @@ UBSAN_SANITIZE := n
 ORIG_CFLAGS := $(KBUILD_CFLAGS)
 KBUILD_CFLAGS = $(subst -mno-sched-epilog,,$(subst $(CC_FLAGS_FTRACE),,$(ORIG_CFLAGS)))
 
+ifdef CONFIG_CC_IS_CLANG
+# clang stores addresses on the stack causing the frame size to blow
+# out. See https://github.com/ClangBuiltLinux/linux/issues/252
+KBUILD_CFLAGS += -Wframe-larger-than=4096
+endif
+
 ccflags-$(CONFIG_PPC64) := $(NO_MINIMAL_TOC)
 
 obj-y			+= xmon.o nonstdio.o spr_access.o
arch/s390/kernel/perf_cpum_sf.c +5 -1
index d99155793c26..2e2fd9535f86 100644
@@ -1610,14 +1610,17 @@ static int __init init_cpum_sampling_pmu(void)
 	}
 
 	sfdbg = debug_register(KMSG_COMPONENT, 2, 1, 80);
-	if (!sfdbg)
+	if (!sfdbg) {
 		pr_err("Registering for s390dbf failed\n");
+		return -ENOMEM;
+	}
 	debug_register_view(sfdbg, &debug_sprintf_view);
 
 	err = register_external_irq(EXT_IRQ_MEASURE_ALERT,
 				    cpumf_measurement_alert);
 	if (err) {
 		pr_cpumsf_err(RS_INIT_FAILURE_ALRT);
+		debug_unregister(sfdbg);
 		goto out;
 	}
 
@@ -1626,6 +1629,7 @@ static int __init init_cpum_sampling_pmu(void)
 		pr_cpumsf_err(RS_INIT_FAILURE_PERF);
 		unregister_external_irq(EXT_IRQ_MEASURE_ALERT,
 					cpumf_measurement_alert);
+		debug_unregister(sfdbg);
 		goto out;
 	}
 
arch/sparc/include/asm/cmpxchg_64.h +6 -1
index f71ef3729888..316faa0130ba 100644
@@ -52,7 +52,12 @@ static inline unsigned long xchg64(__volatile__ unsigned long *m, unsigned long
 	return val;
 }
 
-#define xchg(ptr,x) ((__typeof__(*(ptr)))__xchg((unsigned long)(x),(ptr),sizeof(*(ptr))))
+#define xchg(ptr,x)							\
+({	__typeof__(*(ptr)) __ret;					\
+	__ret = (__typeof__(*(ptr)))					\
+		__xchg((unsigned long)(x), (ptr), sizeof(*(ptr)));	\
+	__ret;								\
+})
 
 void __xchg_called_with_bad_pointer(void);
 
arch/sparc/include/asm/parport.h +2 -0
index 05df5f043053..3c5a1c620f0f 100644
@@ -21,6 +21,7 @@
  */
 #define HAS_DMA
 
+#ifdef CONFIG_PARPORT_PC_FIFO
 static DEFINE_SPINLOCK(dma_spin_lock);
 
 #define claim_dma_lock() \
@@ -31,6 +32,7 @@ static DEFINE_SPINLOCK(dma_spin_lock);
 
 #define release_dma_lock(__flags) \
 	spin_unlock_irqrestore(&dma_spin_lock, __flags);
+#endif
 
 static struct sparc_ebus_info {
 	struct ebus_dma_info info;
arch/um/drivers/line.c +1 -1
index 366e57f5e8d6..7e524efed584 100644
@@ -261,7 +261,7 @@ static irqreturn_t line_write_interrupt(int irq, void *data)
 	if (err == 0) {
 		spin_unlock(&line->lock);
 		return IRQ_NONE;
-	} else if (err < 0) {
+	} else if ((err < 0) && (err != -EAGAIN)) {
 		line->head = line->buffer;
 		line->tail = line->buffer;
 	}
arch/x86/hyperv/hv_init.c +1 -1
index 2653b7b25d17..924fa9c07368 100644
@@ -125,7 +125,7 @@ static int __init hv_pci_init(void)
  * 1. Setup the hypercall page.
  * 2. Register Hyper-V specific clocksource.
  */
-void hyperv_init(void)
+void __init hyperv_init(void)
 {
 	u64 guest_id, required_msrs;
 	union hv_x64_msr_hypercall_contents hypercall_msr;
arch/x86/include/asm/ptrace.h +35 -7

59 lines not on this page · raw message

arch/x86/kernel/cpu/bugs.c +28 -2
index 8596811843cc..7896a34f53b5 100644
@@ -39,6 +39,7 @@ static void __init spectre_v2_select_mitigation(void);
 static void __init ssb_select_mitigation(void);
 static void __init l1tf_select_mitigation(void);
 static void __init mds_select_mitigation(void);
+static void __init mds_print_mitigation(void);
 static void __init taa_select_mitigation(void);
 
 /* The base value of the SPEC_CTRL MSR that always has to be preserved. */
@@ -108,6 +109,12 @@ void __init check_bugs(void)
 	mds_select_mitigation();
 	taa_select_mitigation();
 
+	/*
+	 * As MDS and TAA mitigations are inter-related, print MDS
+	 * mitigation until after TAA mitigation selection is done.
+	 */
+	mds_print_mitigation();
+
 	arch_smt_update();
 
 #ifdef CONFIG_X86_32
@@ -245,6 +252,12 @@ static void __init mds_select_mitigation(void)
 		    (mds_nosmt || cpu_mitigations_auto_nosmt()))
 			cpu_smt_disable(false);
 	}
+}
+
+static void __init mds_print_mitigation(void)
+{
+	if (!boot_cpu_has_bug(X86_BUG_MDS) || cpu_mitigations_off())
+		return;
 
 	pr_info("%s\n", mds_strings[mds_mitigation]);
 }
@@ -304,8 +317,12 @@ static void __init taa_select_mitigation(void)
 		return;
 	}
 
-	/* TAA mitigation is turned off on the cmdline (tsx_async_abort=off) */
-	if (taa_mitigation == TAA_MITIGATION_OFF)
+	/*
+	 * TAA mitigation via VERW is turned off if both
+	 * tsx_async_abort=off and mds=off are specified.
+	 */
+	if (taa_mitigation == TAA_MITIGATION_OFF &&
+	    mds_mitigation == MDS_MITIGATION_OFF)
 		goto out;
 
 	if (boot_cpu_has(X86_FEATURE_MD_CLEAR))
@@ -339,6 +356,15 @@ static void __init taa_select_mitigation(void)
 	if (taa_nosmt || cpu_mitigations_auto_nosmt())
 		cpu_smt_disable(false);
 
+	/*
+	 * Update MDS mitigation, if necessary, as the mds_user_clear is
+	 * now enabled for TAA mitigation.
+	 */
+	if (mds_mitigation == MDS_MITIGATION_OFF &&
+	    boot_cpu_has_bug(X86_BUG_MDS)) {
+		mds_mitigation = MDS_MITIGATION_FULL;
+		mds_select_mitigation();
+	}
 out:
 	pr_info("%s\n", taa_strings[taa_mitigation]);
 }
arch/x86/kvm/mmu.c +4 -4
index 8cd26e50d41c..c0b0135ef07f 100644
@@ -3177,7 +3177,7 @@ static void transparent_hugepage_adjust(struct kvm_vcpu *vcpu,
 	 * here.
 	 */
 	if (!is_error_noslot_pfn(pfn) && !kvm_is_reserved_pfn(pfn) &&
-	    level == PT_PAGE_TABLE_LEVEL &&
+	    !kvm_is_zone_device_pfn(pfn) && level == PT_PAGE_TABLE_LEVEL &&
 	    PageTransCompoundMap(pfn_to_page(pfn)) &&
 	    !mmu_gfn_lpage_is_disallowed(vcpu, gfn, PT_DIRECTORY_LEVEL)) {
 		unsigned long mask;
@@ -5344,9 +5344,9 @@ static bool kvm_mmu_zap_collapsible_spte(struct kvm *kvm,
 		 * the guest, and the guest page table is using 4K page size
 		 * mapping if the indirect sp has level = 1.
 		 */
-		if (sp->role.direct &&
-			!kvm_is_reserved_pfn(pfn) &&
-			PageTransCompoundMap(pfn_to_page(pfn))) {
+		if (sp->role.direct && !kvm_is_reserved_pfn(pfn) &&
+		    !kvm_is_zone_device_pfn(pfn) &&
+		    PageTransCompoundMap(pfn_to_page(pfn))) {
 			drop_spte(kvm, sptep);
 			need_tlb_flush = 1;
 			goto restart;
arch/x86/kvm/vmx.c +6 -6
index ab6384efc791..f67fc0f359ff 100644
@@ -1602,7 +1602,7 @@ static int __find_msr_index(struct vcpu_vmx *vmx, u32 msr)
 	return -1;
 }
 
-static inline void __invvpid(int ext, u16 vpid, gva_t gva)
+static inline void __invvpid(unsigned long ext, u16 vpid, gva_t gva)
 {
     struct {
 	u64 vpid : 16;
@@ -1616,7 +1616,7 @@ static inline void __invvpid(int ext, u16 vpid, gva_t gva)
 		  : : "a"(&operand), "c"(ext) : "cc", "memory");
 }
 
-static inline void __invept(int ext, u64 eptp, gpa_t gpa)
+static inline void __invept(unsigned long ext, u64 eptp, gpa_t gpa)
 {
 	struct {
 		u64 eptp, gpa;
@@ -10000,6 +10000,10 @@ static void vmx_switch_vmcs(struct kvm_vcpu *vcpu, struct loaded_vmcs *vmcs)
 	vmx_vcpu_load(vcpu, cpu);
 	vcpu->cpu = cpu;
 	put_cpu();
+
+	vm_entry_controls_reset_shadow(vmx);
+	vm_exit_controls_reset_shadow(vmx);
+	vmx_segment_cache_clear(vmx);
 }
 
 /*
@@ -11428,7 +11432,6 @@ static int enter_vmx_non_root_mode(struct kvm_vcpu *vcpu, bool from_vmentry)
 		vmx->nested.vmcs01_debugctl = vmcs_read64(GUEST_IA32_DEBUGCTL);
 
 	vmx_switch_vmcs(vcpu, &vmx->nested.vmcs02);
-	vmx_segment_cache_clear(vmx);
 
 	if (prepare_vmcs02(vcpu, vmcs12, from_vmentry, &exit_qual)) {
 		leave_guest_mode(vcpu);
@@ -12172,9 +12175,6 @@ static void nested_vmx_vmexit(struct kvm_vcpu *vcpu, u32 exit_reason,
 	}
 
 	vmx_switch_vmcs(vcpu, &vmx->vmcs01);
-	vm_entry_controls_reset_shadow(vmx);
-	vm_exit_controls_reset_shadow(vmx);
-	vmx_segment_cache_clear(vmx);
 
 	/* Update any VMCS fields that might have changed while L2 ran */
 	vmcs_write32(VM_EXIT_MSR_LOAD_COUNT, vmx->msr_autoload.host.nr);
arch/x86/tools/gen-insn-attr-x86.awk +2 -2
index b02a36b2c14f..a42015b305f4 100644
@@ -69,7 +69,7 @@ BEGIN {
 
 	lprefix1_expr = "\\((66|!F3)\\)"
 	lprefix2_expr = "\\(F3\\)"
-	lprefix3_expr = "\\((F2|!F3|66\\&F2)\\)"
+	lprefix3_expr = "\\((F2|!F3|66&F2)\\)"
 	lprefix_expr = "\\((66|F2|F3)\\)"
 	max_lprefix = 4
 
@@ -257,7 +257,7 @@ function convert_operands(count,opnd,       i,j,imm,mod)
 	return add_flags(imm, mod)
 }
 
-/^[0-9a-f]+\:/ {
+/^[0-9a-f]+:/ {
 	if (NR == 1)
 		next
 	# get index
block/blk-merge.c +36 -10

73 lines not on this page · raw message

drivers/acpi/acpi_memhotplug.c +1 -1
index 6b0d3ef7309c..2ccfbb61ca89 100644
@@ -228,7 +228,7 @@ static int acpi_memory_enable_device(struct acpi_memory_device *mem_device)
 		if (node < 0)
 			node = memory_add_physaddr_to_nid(info->start_addr);
 
-		result = add_memory(node, info->start_addr, info->length);
+		result = __add_memory(node, info->start_addr, info->length);
 
 		/*
 		 * If the memory block has been used by the kernel, add_memory()
drivers/atm/zatm.c +21 -21

127 lines not on this page · raw message

drivers/base/memory.c +7 -2
index c617e00f4361..fe1557aa9b10 100644
@@ -517,15 +517,20 @@ memory_probe_store(struct device *dev, struct device_attribute *attr,
 	if (phys_addr & ((pages_per_block << PAGE_SHIFT) - 1))
 		return -EINVAL;
 
+	ret = lock_device_hotplug_sysfs();
+	if (ret)
+		return ret;
+
 	nid = memory_add_physaddr_to_nid(phys_addr);
-	ret = add_memory(nid, phys_addr,
-			 MIN_MEMORY_BLOCK_SIZE * sections_per_block);
+	ret = __add_memory(nid, phys_addr,
+			   MIN_MEMORY_BLOCK_SIZE * sections_per_block);
 
 	if (ret)
 		goto out;
 
 	ret = count;
 out:
+	unlock_device_hotplug();
 	return ret;
 }
 
drivers/base/power/domain.c +6 -0
index c276ba1c0a19..e811f2414889 100644
@@ -369,6 +369,10 @@ static int genpd_power_off(struct generic_pm_domain *genpd, bool one_dev_on,
 			return -EAGAIN;
 	}
 
+	/* Default to shallowest state. */
+	if (!genpd->gov)
+		genpd->state_idx = 0;
+
 	if (genpd->power_off) {
 		int ret;
 
@@ -1598,6 +1602,8 @@ int pm_genpd_init(struct generic_pm_domain *genpd,
 		ret = genpd_set_default_power_state(genpd);
 		if (ret)
 			return ret;
+	} else if (!gov) {
+		pr_warn("%s : no governor for states\n", genpd->name);
 	}
 
 	mutex_lock(&gpd_list_lock);
drivers/block/amiflop.c +40 -44

119 lines not on this page · raw message

drivers/block/nbd.c +4 -2
index 34dfadd4dcd4..929bd255a290 100644
@@ -931,6 +931,7 @@ static struct socket *nbd_get_socket(struct nbd_device *nbd, unsigned long fd,
 	if (sock->ops->shutdown == sock_no_shutdown) {
 		dev_err(disk_to_dev(nbd->disk), "Unsupported socket: shutdown callout must be supported.\n");
 		*err = -EINVAL;
+		sockfd_put(sock);
 		return NULL;
 	}
 
@@ -969,14 +970,15 @@ static int nbd_add_socket(struct nbd_device *nbd, unsigned long arg,
 		sockfd_put(sock);
 		return -ENOMEM;
 	}
+
+	config->socks = socks;
+
 	nsock = kzalloc(sizeof(struct nbd_sock), GFP_KERNEL);
 	if (!nsock) {
 		sockfd_put(sock);
 		return -ENOMEM;
 	}
 
-	config->socks = socks;
-
 	nsock->fallback_index = -1;
 	nsock->dead = false;
 	mutex_init(&nsock->tx_lock);
drivers/block/skd_main.c +2 -2
index 64d0fc17c174..95649025cde7 100644
@@ -1417,7 +1417,7 @@ static void skd_resolve_req_exception(struct skd_device *skdev,
 
 	case SKD_CHECK_STATUS_BUSY_IMMINENT:
 		skd_log_skreq(skdev, skreq, "retry(busy)");
-		blk_requeue_request(skdev->queue, req);
+		blk_mq_requeue_request(req, true);
 		dev_info(&skdev->pdev->dev, "drive BUSY imminent\n");
 		skdev->state = SKD_DRVR_STATE_BUSY_IMMINENT;
 		skdev->timer_countdown = SKD_TIMER_MINUTES(20);
@@ -1427,7 +1427,7 @@ static void skd_resolve_req_exception(struct skd_device *skdev,
 	case SKD_CHECK_STATUS_REQUEUE_REQUEST:
 		if ((unsigned long) ++req->special < SKD_MAX_RETRIES) {
 			skd_log_skreq(skdev, skreq, "retry");
-			blk_requeue_request(skdev->queue, req);
+			blk_mq_requeue_request(req, true);
 			break;
 		}
 		/* fall through */
drivers/bluetooth/hci_bcsp.c +3 -0
index 57a7f4255ac0..ee6c403de6af 100644
@@ -605,6 +605,7 @@ static int bcsp_recv(struct hci_uart *hu, const void *data, int count)
 			if (*ptr == 0xc0) {
 				BT_ERR("Short BCSP packet");
 				kfree_skb(bcsp->rx_skb);
+				bcsp->rx_skb = NULL;
 				bcsp->rx_state = BCSP_W4_PKT_START;
 				bcsp->rx_count = 0;
 			} else
@@ -620,6 +621,7 @@ static int bcsp_recv(struct hci_uart *hu, const void *data, int count)
 			    bcsp->rx_skb->data[2])) != bcsp->rx_skb->data[3]) {
 				BT_ERR("Error in BCSP hdr checksum");
 				kfree_skb(bcsp->rx_skb);
+				bcsp->rx_skb = NULL;
 				bcsp->rx_state = BCSP_W4_PKT_DELIMITER;
 				bcsp->rx_count = 0;
 				continue;
@@ -644,6 +646,7 @@ static int bcsp_recv(struct hci_uart *hu, const void *data, int count)
 				       bscp_get_crc(bcsp));
 
 				kfree_skb(bcsp->rx_skb);
+				bcsp->rx_skb = NULL;
 				bcsp->rx_state = BCSP_W4_PKT_DELIMITER;
 				bcsp->rx_count = 0;
 				continue;
drivers/cdrom/cdrom.c +13 -14
index ea6558d4864c..90dd8e7291da 100644
@@ -410,10 +410,10 @@ static int cdrom_get_disc_info(struct cdrom_device_info *cdi,
  * hack to have the capability flags defined const, while we can still
  * change it here without gcc complaining at every line.
  */
-#define ENSURE(call, bits)			\
-do {						\
-	if (cdo->call == NULL)			\
-		*change_capability &= ~(bits);	\
+#define ENSURE(cdo, call, bits)					\
+do {								\
+	if (cdo->call == NULL)					\
+		WARN_ON_ONCE((cdo)->capability & (bits));	\
 } while (0)
 
 /*
@@ -589,7 +589,6 @@ int register_cdrom(struct cdrom_device_info *cdi)
 {
 	static char banner_printed;
 	const struct cdrom_device_ops *cdo = cdi->ops;
-	int *change_capability = (int *)&cdo->capability; /* hack */
 
 	cd_dbg(CD_OPEN, "entering register_cdrom\n");
 
@@ -601,16 +600,16 @@ int register_cdrom(struct cdrom_device_info *cdi)
 		cdrom_sysctl_register();
 	}
 
-	ENSURE(drive_status, CDC_DRIVE_STATUS);
+	ENSURE(cdo, drive_status, CDC_DRIVE_STATUS);
 	if (cdo->check_events == NULL && cdo->media_changed == NULL)
-		*change_capability = ~(CDC_MEDIA_CHANGED | CDC_SELECT_DISC);
-	ENSURE(tray_move, CDC_CLOSE_TRAY | CDC_OPEN_TRAY);
-	ENSURE(lock_door, CDC_LOCK);
-	ENSURE(select_speed, CDC_SELECT_SPEED);
-	ENSURE(get_last_session, CDC_MULTI_SESSION);
-	ENSURE(get_mcn, CDC_MCN);
-	ENSURE(reset, CDC_RESET);
-	ENSURE(generic_packet, CDC_GENERIC_PACKET);
+		WARN_ON_ONCE(cdo->capability & (CDC_MEDIA_CHANGED | CDC_SELECT_DISC));
+	ENSURE(cdo, tray_move, CDC_CLOSE_TRAY | CDC_OPEN_TRAY);
+	ENSURE(cdo, lock_door, CDC_LOCK);
+	ENSURE(cdo, select_speed, CDC_SELECT_SPEED);
+	ENSURE(cdo, get_last_session, CDC_MULTI_SESSION);
+	ENSURE(cdo, get_mcn, CDC_MCN);
+	ENSURE(cdo, reset, CDC_RESET);
+	ENSURE(cdo, generic_packet, CDC_GENERIC_PACKET);
 	cdi->mc_flags = 0;
 	cdi->options = CDO_USE_FFLAGS;
 
drivers/char/virtio_console.c +13 -15
index 65454acd4b97..5200772ab0bd 100644
@@ -1366,24 +1366,24 @@ static void set_console_size(struct port *port, u16 rows, u16 cols)
 	port->cons.ws.ws_col = cols;
 }
 
-static unsigned int fill_queue(struct virtqueue *vq, spinlock_t *lock)
+static int fill_queue(struct virtqueue *vq, spinlock_t *lock)
 {
 	struct port_buffer *buf;
-	unsigned int nr_added_bufs;
+	int nr_added_bufs;
 	int ret;
 
 	nr_added_bufs = 0;
 	do {
 		buf = alloc_buf(vq->vdev, PAGE_SIZE, 0);
 		if (!buf)
-			break;
+			return -ENOMEM;
 
 		spin_lock_irq(lock);
 		ret = add_inbuf(vq, buf);
 		if (ret < 0) {
 			spin_unlock_irq(lock);
 			free_buf(buf, true);
-			break;
+			return ret;
 		}
 		nr_added_bufs++;
 		spin_unlock_irq(lock);
@@ -1403,7 +1403,6 @@ static int add_port(struct ports_device *portdev, u32 id)
 	char debugfs_name[16];
 	struct port *port;
 	dev_t devt;
-	unsigned int nr_added_bufs;
 	int err;
 
 	port = kmalloc(sizeof(*port), GFP_KERNEL);
@@ -1462,11 +1461,13 @@ static int add_port(struct ports_device *portdev, u32 id)
 	spin_lock_init(&port->outvq_lock);
 	init_waitqueue_head(&port->waitqueue);
 
-	/* Fill the in_vq with buffers so the host can send us data. */
-	nr_added_bufs = fill_queue(port->in_vq, &port->inbuf_lock);
-	if (!nr_added_bufs) {
+	/* We can safely ignore ENOSPC because it means
+	 * the queue already has buffers. Buffers are removed
+	 * only by virtcons_remove(), not by unplug_port()
+	 */
+	err = fill_queue(port->in_vq, &port->inbuf_lock);
+	if (err < 0 && err != -ENOSPC) {
 		dev_err(port->dev, "Error allocating inbufs\n");
-		err = -ENOMEM;
 		goto free_device;
 	}
 
@@ -2099,14 +2100,11 @@ static int virtcons_probe(struct virtio_device *vdev)
 	INIT_WORK(&portdev->control_work, &control_work_handler);
 
 	if (multiport) {
-		unsigned int nr_added_bufs;
-
 		spin_lock_init(&portdev->c_ivq_lock);
 		spin_lock_init(&portdev->c_ovq_lock);
 
-		nr_added_bufs = fill_queue(portdev->c_ivq,
-					   &portdev->c_ivq_lock);
-		if (!nr_added_bufs) {
+		err = fill_queue(portdev->c_ivq, &portdev->c_ivq_lock);
+		if (err < 0) {
 			dev_err(&vdev->dev,
 				"Error allocating buffers for control queue\n");
 			/*
@@ -2117,7 +2115,7 @@ static int virtcons_probe(struct virtio_device *vdev)
 					   VIRTIO_CONSOLE_DEVICE_READY, 0);
 			/* Device was functional: we need full cleanup. */
 			virtcons_remove(vdev);
-			return -ENOMEM;
+			return err;
 		}
 	} else {
 		/*
drivers/clk/at91/clk-audio-pll.c +1 -1
index da7bafcfbe70..b3eaf654fac9 100644
@@ -509,7 +509,7 @@ static void __init of_sama5d2_clk_audio_pll_pad_setup(struct device_node *np)
 
 static void __init of_sama5d2_clk_audio_pll_pmc_setup(struct device_node *np)
 {
-	struct clk_audio_pad *apmc_ck;
+	struct clk_audio_pmc *apmc_ck;
 	struct clk_init_data init = {};
 
 	apmc_ck = kzalloc(sizeof(*apmc_ck), GFP_KERNEL);
drivers/clk/mmp/clk-of-mmp2.c +2 -2
index 0fc75c395957..d083b860f083 100644
@@ -227,8 +227,8 @@ static struct mmp_param_gate_clk apmu_gate_clks[] = {
 	/* The gate clocks has mux parent. */
 	{MMP2_CLK_SDH0, "sdh0_clk", "sdh_mix_clk", CLK_SET_RATE_PARENT, APMU_SDH0, 0x1b, 0x1b, 0x0, 0, &sdh_lock},
 	{MMP2_CLK_SDH1, "sdh1_clk", "sdh_mix_clk", CLK_SET_RATE_PARENT, APMU_SDH1, 0x1b, 0x1b, 0x0, 0, &sdh_lock},
-	{MMP2_CLK_SDH1, "sdh2_clk", "sdh_mix_clk", CLK_SET_RATE_PARENT, APMU_SDH2, 0x1b, 0x1b, 0x0, 0, &sdh_lock},
-	{MMP2_CLK_SDH1, "sdh3_clk", "sdh_mix_clk", CLK_SET_RATE_PARENT, APMU_SDH3, 0x1b, 0x1b, 0x0, 0, &sdh_lock},
+	{MMP2_CLK_SDH2, "sdh2_clk", "sdh_mix_clk", CLK_SET_RATE_PARENT, APMU_SDH2, 0x1b, 0x1b, 0x0, 0, &sdh_lock},
+	{MMP2_CLK_SDH3, "sdh3_clk", "sdh_mix_clk", CLK_SET_RATE_PARENT, APMU_SDH3, 0x1b, 0x1b, 0x0, 0, &sdh_lock},
 	{MMP2_CLK_DISP0, "disp0_clk", "disp0_div", CLK_SET_RATE_PARENT, APMU_DISP0, 0x1b, 0x1b, 0x0, 0, &disp0_lock},
 	{MMP2_CLK_DISP0_SPHY, "disp0_sphy_clk", "disp0_sphy_div", CLK_SET_RATE_PARENT, APMU_DISP0, 0x1024, 0x1024, 0x0, 0, &disp0_lock},
 	{MMP2_CLK_DISP1, "disp1_clk", "disp1_div", CLK_SET_RATE_PARENT, APMU_DISP1, 0x1b, 0x1b, 0x0, 0, &disp1_lock},
drivers/clk/sunxi-ng/ccu-sun50i-a64.c +6 -1
index 2bb4cabf802f..36a30a3cfad7 100644
@@ -158,7 +158,12 @@ static SUNXI_CCU_NM_WITH_FRAC_GATE_LOCK(pll_gpu_clk, "pll-gpu",
 #define SUN50I_A64_PLL_MIPI_REG		0x040
 
 static struct ccu_nkm pll_mipi_clk = {
-	.enable		= BIT(31),
+	/*
+	 * The bit 23 and 22 are called "LDO{1,2}_EN" on the SoC's
+	 * user manual, and by experiments the PLL doesn't work without
+	 * these bits toggled.
+	 */
+	.enable		= BIT(31) | BIT(23) | BIT(22),
 	.lock		= BIT(28),
 	.n		= _SUNXI_CCU_MULT(8, 4),
 	.k		= _SUNXI_CCU_MULT_MIN(4, 2, 2),
drivers/cpufreq/cpufreq.c +9 -0
index 4aa3c5331666..480e8c13567c 100644
@@ -911,6 +911,9 @@ static ssize_t show(struct kobject *kobj, struct attribute *attr, char *buf)
 	struct freq_attr *fattr = to_attr(attr);
 	ssize_t ret;
 
+	if (!fattr->show)
+		return -EIO;
+
 	down_read(&policy->rwsem);
 	ret = fattr->show(policy, buf);
 	up_read(&policy->rwsem);
@@ -925,6 +928,9 @@ static ssize_t store(struct kobject *kobj, struct attribute *attr,
 	struct freq_attr *fattr = to_attr(attr);
 	ssize_t ret = -EINVAL;
 
+	if (!fattr->store)
+		return -EIO;
+
 	cpus_read_lock();
 
 	if (cpu_online(policy->cpu)) {
@@ -1673,6 +1679,9 @@ void cpufreq_resume(void)
 	if (!cpufreq_driver)
 		return;
 
+	if (unlikely(!cpufreq_suspended))
+		return;
+
 	cpufreq_suspended = false;
 
 	if (!has_target() && !cpufreq_driver->resume)
drivers/edac/thunderx_edac.c +2 -2
index f35d87519a3e..dfefa39e9351 100644
@@ -1905,7 +1905,7 @@ static irqreturn_t thunderx_l2c_threaded_isr(int irq, void *irq_id)
 	default:
 		dev_err(&l2c->pdev->dev, "Unsupported device: %04x\n",
 			l2c->pdev->device);
-		return IRQ_NONE;
+		goto err_free;
 	}
 
 	while (CIRC_CNT(l2c->ring_head, l2c->ring_tail,
@@ -1927,7 +1927,7 @@ static irqreturn_t thunderx_l2c_threaded_isr(int irq, void *irq_id)
 		l2c->ring_tail++;
 	}
 
-	return IRQ_HANDLED;
+	ret = IRQ_HANDLED;
 
 err_free:
 	kfree(other);
drivers/firmware/google/gsmi.c +2 -3
index c8f169bf2e27..62337be07afc 100644
@@ -480,11 +480,10 @@ static ssize_t eventlog_write(struct file *filp, struct kobject *kobj,
 	if (count < sizeof(u32))
 		return -EINVAL;
 	param.type = *(u32 *)buf;
-	count -= sizeof(u32);
 	buf += sizeof(u32);
 
 	/* The remaining buffer is the data payload */
-	if (count > gsmi_dev.data_buf->length)
+	if ((count - sizeof(u32)) > gsmi_dev.data_buf->length)
 		return -EINVAL;
 	param.data_len = count - sizeof(u32);
 
@@ -504,7 +503,7 @@ static ssize_t eventlog_write(struct file *filp, struct kobject *kobj,
 
 	spin_unlock_irqrestore(&gsmi_dev.lock, flags);
 
-	return rc;
+	return (rc == 0) ? count : rc;
 
 }
 
drivers/gpio/gpio-max77620.c +3 -3
index ac6c1c0548b6..78254ed93206 100644
@@ -163,13 +163,13 @@ static int max77620_gpio_set_debounce(struct max77620_gpio *mgpio,
 	case 0:
 		val = MAX77620_CNFG_GPIO_DBNC_None;
 		break;
-	case 1000 ... 8000:
+	case 1 ... 8000:
 		val = MAX77620_CNFG_GPIO_DBNC_8ms;
 		break;
-	case 9000 ... 16000:
+	case 8001 ... 16000:
 		val = MAX77620_CNFG_GPIO_DBNC_16ms;
 		break;
-	case 17000 ... 32000:
+	case 16001 ... 32000:
 		val = MAX77620_CNFG_GPIO_DBNC_32ms;
 		break;
 	default:
drivers/gpu/drm/i915/i915_gem_userptr.c +21 -1
index 05ae8c4a8a1b..480d20758324 100644
@@ -690,8 +690,28 @@ i915_gem_userptr_put_pages(struct drm_i915_gem_object *obj,
 	i915_gem_gtt_finish_pages(obj, pages);
 
 	for_each_sgt_page(page, sgt_iter, pages) {
-		if (obj->mm.dirty)
+		if (obj->mm.dirty && trylock_page(page)) {
+			/*
+			 * As this may not be anonymous memory (e.g. shmem)
+			 * but exist on a real mapping, we have to lock
+			 * the page in order to dirty it -- holding
+			 * the page reference is not sufficient to
+			 * prevent the inode from being truncated.
+			 * Play safe and take the lock.
+			 *
+			 * However...!
+			 *
+			 * The mmu-notifier can be invalidated for a
+			 * migrate_page, that is alreadying holding the lock
+			 * on the page. Such a try_to_unmap() will result
+			 * in us calling put_pages() and so recursively try
+			 * to lock the page. We avoid that deadlock with
+			 * a trylock_page() and in exchange we risk missing
+			 * some page dirtying.
+			 */
 			set_page_dirty(page);
+			unlock_page(page);
+		}
 
 		mark_page_accessed(page);
 		put_page(page);
drivers/i2c/busses/i2c-uniphier-f.c +58 -14

169 lines not on this page · raw message

drivers/infiniband/hw/bnxt_re/main.c +9 -4
index bf811b23bc95..7d00b6a53ed8 100644
@@ -782,12 +782,17 @@ static void bnxt_re_dispatch_event(struct ib_device *ibdev, struct ib_qp *qp,
 	struct ib_event ib_event;
 
 	ib_event.device = ibdev;
-	if (qp)
+	if (qp) {
 		ib_event.element.qp = qp;
-	else
+		ib_event.event = event;
+		if (qp->event_handler)
+			qp->event_handler(&ib_event, qp->qp_context);
+
+	} else {
 		ib_event.element.port_num = port_num;
-	ib_event.event = event;
-	ib_dispatch_event(&ib_event);
+		ib_event.event = event;
+		ib_dispatch_event(&ib_event);
+	}
 }
 
 #define HWRM_QUEUE_PRI2COS_QCFG_INPUT_FLAGS_IVLAN      0x02
drivers/isdn/mISDN/tei.c +3 -4
index 12d9e5f4beb1..58635b5f296f 100644
@@ -1180,8 +1180,7 @@ static int
 ctrl_teimanager(struct manager *mgr, void *arg)
 {
 	/* currently we only have one option */
-	int	*val = (int *)arg;
-	int	ret = 0;
+	unsigned int *val = (unsigned int *)arg;
 
 	switch (val[0]) {
 	case IMCLEAR_L2:
@@ -1197,9 +1196,9 @@ ctrl_teimanager(struct manager *mgr, void *arg)
 			test_and_clear_bit(OPTION_L1_HOLD, &mgr->options);
 		break;
 	default:
-		ret = -EINVAL;
+		return -EINVAL;
 	}
-	return ret;
+	return 0;
 }
 
 /* This function does create a L2 for fixed TEI in NT Mode */
drivers/macintosh/windfarm_smu_sat.c +7 -18
index da7f4fc1a51d..a0f61eb853c5 100644
@@ -22,14 +22,6 @@
 
 #define VERSION "1.0"
 
-#define DEBUG
-
-#ifdef DEBUG
-#define DBG(args...)	printk(args)
-#else
-#define DBG(args...)	do { } while(0)
-#endif
-
 /* If the cache is older than 800ms we'll refetch it */
 #define MAX_AGE		msecs_to_jiffies(800)
 
@@ -106,13 +98,10 @@ struct smu_sdbp_header *smu_sat_get_sdb_partition(unsigned int sat_id, int id,
 		buf[i+2] = data[3];
 		buf[i+3] = data[2];
 	}
-#ifdef DEBUG
-	DBG(KERN_DEBUG "sat %d partition %x:", sat_id, id);
-	for (i = 0; i < len; ++i)
-		DBG(" %x", buf[i]);
-	DBG("\n");
-#endif
 
+	printk(KERN_DEBUG "sat %d partition %x:", sat_id, id);
+	print_hex_dump(KERN_DEBUG, "  ", DUMP_PREFIX_OFFSET,
+		       16, 1, buf, len, false);
 	if (size)
 		*size = len;
 	return (struct smu_sdbp_header *) buf;
@@ -132,13 +121,13 @@ static int wf_sat_read_cache(struct wf_sat *sat)
 	if (err < 0)
 		return err;
 	sat->last_read = jiffies;
+
 #ifdef LOTSA_DEBUG
 	{
 		int i;
-		DBG(KERN_DEBUG "wf_sat_get: data is");
-		for (i = 0; i < 16; ++i)
-			DBG(" %.2x", sat->cache[i]);
-		DBG("\n");
+		printk(KERN_DEBUG "wf_sat_get: data is");
+		print_hex_dump(KERN_DEBUG, "  ", DUMP_PREFIX_OFFSET,
+			       16, 1, sat->cache, 16, false);
 	}
 #endif
 	return 0;
drivers/md/dm-raid.c +1 -1
index 151211b4cb1b..2c5912e75514 100644
@@ -2441,7 +2441,7 @@ static int super_validate(struct raid_set *rs, struct md_rdev *rdev)
 	}
 
 	/* Enable bitmap creation for RAID levels != 0 */
-	mddev->bitmap_info.offset = rt_is_raid0(rs->raid_type) ? 0 : to_sector(4096);
+	mddev->bitmap_info.offset = (rt_is_raid0(rs->raid_type) || rs->journal_dev.dev) ? 0 : to_sector(4096);
 	mddev->bitmap_info.default_offset = mddev->bitmap_info.offset;
 
 	if (!test_and_clear_bit(FirstUse, &rdev->flags)) {
drivers/md/raid10.c +1 -1
index 433e78f453da..d08d77b9674f 100644
@@ -226,7 +226,7 @@ static void * r10buf_pool_alloc(gfp_t gfp_flags, void *data)
 
 out_free_pages:
 	while (--j >= 0)
-		resync_free_pages(&rps[j * 2]);
+		resync_free_pages(&rps[j]);
 
 	j = 0;
 out_free_bio:
drivers/media/platform/vivid/vivid-kthread-cap.c +5 -3
index d300e5e7eadc..2ca9c928ed2f 100644
@@ -777,7 +777,11 @@ static int vivid_thread_vid_cap(void *data)
 		if (kthread_should_stop())
 			break;
 
-		mutex_lock(&dev->mutex);
+		if (!mutex_trylock(&dev->mutex)) {
+			schedule_timeout_uninterruptible(1);
+			continue;
+		}
+
 		cur_jiffies = jiffies;
 		if (dev->cap_seq_resync) {
 			dev->jiffies_vid_cap = cur_jiffies;
@@ -930,8 +934,6 @@ void vivid_stop_generating_vid_cap(struct vivid_dev *dev, bool *pstreaming)
 
 	/* shutdown control thread */
 	vivid_grab_controls(dev, false);
-	mutex_unlock(&dev->mutex);
 	kthread_stop(dev->kthread_vid_cap);
 	dev->kthread_vid_cap = NULL;
-	mutex_lock(&dev->mutex);
 }
drivers/media/platform/vivid/vivid-kthread-out.c +5 -3
index 7c8d75852816..ed5d8fb854b4 100644
@@ -147,7 +147,11 @@ static int vivid_thread_vid_out(void *data)
 		if (kthread_should_stop())
 			break;
 
-		mutex_lock(&dev->mutex);
+		if (!mutex_trylock(&dev->mutex)) {
+			schedule_timeout_uninterruptible(1);
+			continue;
+		}
+
 		cur_jiffies = jiffies;
 		if (dev->out_seq_resync) {
 			dev->jiffies_vid_out = cur_jiffies;
@@ -301,8 +305,6 @@ void vivid_stop_generating_vid_out(struct vivid_dev *dev, bool *pstreaming)
 
 	/* shutdown control thread */
 	vivid_grab_controls(dev, false);
-	mutex_unlock(&dev->mutex);
 	kthread_stop(dev->kthread_vid_out);
 	dev->kthread_vid_out = NULL;
-	mutex_lock(&dev->mutex);
 }
drivers/media/platform/vivid/vivid-sdr-cap.c +5 -3
index ebd7b9c4dd83..4f49c9a47d49 100644
@@ -149,7 +149,11 @@ static int vivid_thread_sdr_cap(void *data)
 		if (kthread_should_stop())
 			break;
 
-		mutex_lock(&dev->mutex);
+		if (!mutex_trylock(&dev->mutex)) {
+			schedule_timeout_uninterruptible(1);
+			continue;
+		}
+
 		cur_jiffies = jiffies;
 		if (dev->sdr_cap_seq_resync) {
 			dev->jiffies_sdr_cap = cur_jiffies;
@@ -309,10 +313,8 @@ static void sdr_cap_stop_streaming(struct vb2_queue *vq)
 	}
 
 	/* shutdown control thread */
-	mutex_unlock(&dev->mutex);
 	kthread_stop(dev->kthread_sdr_cap);
 	dev->kthread_sdr_cap = NULL;
-	mutex_lock(&dev->mutex);
 }
 
 const struct vb2_ops vivid_sdr_cap_qops = {
drivers/media/platform/vivid/vivid-vid-cap.c +0 -3
index 4ca3d600aa84..c66568e8f388 100644
@@ -239,9 +239,6 @@ static int vid_cap_start_streaming(struct vb2_queue *vq, unsigned count)
 	if (vb2_is_streaming(&dev->vb_vid_out_q))
 		dev->can_loop_video = vivid_vid_can_loop(dev);
 
-	if (dev->kthread_vid_cap)
-		return 0;
-
 	dev->vid_cap_seq_count = 0;
 	dprintk(dev, 1, "%s\n", __func__);
 	for (i = 0; i < VIDEO_MAX_FRAME; i++)
drivers/media/platform/vivid/vivid-vid-out.c +0 -3
index 0b1b6218ede8..3e7a26d15074 100644
@@ -158,9 +158,6 @@ static int vid_out_start_streaming(struct vb2_queue *vq, unsigned count)
 	if (vb2_is_streaming(&dev->vb_vid_cap_q))
 		dev->can_loop_video = vivid_vid_can_loop(dev);
 
-	if (dev->kthread_vid_out)
-		return 0;
-
 	dev->vid_out_seq_count = 0;
 	dprintk(dev, 1, "%s\n", __func__);
 	if (dev->start_streaming_error) {
drivers/media/rc/imon.c +1 -2
index a7547c88e4c3..edf8a7a76e86 100644
@@ -1737,8 +1737,7 @@ static void imon_incoming_scancode(struct imon_context *ictx,
 	spin_unlock_irqrestore(&ictx->kc_lock, flags);
 
 	/* send touchscreen events through input subsystem if touchpad data */
-	if (ictx->display_type == IMON_DISPLAY_TYPE_VGA && len == 8 &&
-	    buf[7] == 0x86) {
+	if (ictx->touch && len == 8 && buf[7] == 0x86) {
 		imon_touch_event(ictx, buf);
 		return;
 
drivers/media/usb/b2c2/flexcop-usb.c +3 -0
index a8f3169e30b3..ac4fddfd0a43 100644
@@ -537,6 +537,9 @@ static int flexcop_usb_probe(struct usb_interface *intf,
 	struct flexcop_device *fc = NULL;
 	int ret;
 
+	if (intf->cur_altsetting->desc.bNumEndpoints < 1)
+		return -ENODEV;
+
 	if ((fc = flexcop_device_kmalloc(sizeof(struct flexcop_usb))) == NULL) {
 		err("out of memory\n");
 		return -ENOMEM;
drivers/media/usb/dvb-usb/cxusb.c +2 -1
index cfe86b4864b3..47a9a791ee7d 100644
@@ -455,7 +455,8 @@ static int cxusb_rc_query(struct dvb_usb_device *d)
 {
 	u8 ircode[4];
 
-	cxusb_ctrl_msg(d, CMD_GET_IR_CODE, NULL, 0, ircode, 4);
+	if (cxusb_ctrl_msg(d, CMD_GET_IR_CODE, NULL, 0, ircode, 4) < 0)
+		return 0;
 
 	if (ircode[2] || ircode[3])
 		rc_keydown(d->rc_dev, RC_PROTO_NEC,
drivers/media/usb/usbvision/usbvision-video.c +18 -3
index 960272d3c924..4c39c502d616 100644
@@ -328,6 +328,10 @@ static int usbvision_v4l2_open(struct file *file)
 	if (mutex_lock_interruptible(&usbvision->v4l2_lock))
 		return -ERESTARTSYS;
 
+	if (usbvision->remove_pending) {
+		err_code = -ENODEV;
+		goto unlock;
+	}
 	if (usbvision->user) {
 		err_code = -EBUSY;
 	} else {
@@ -391,6 +395,7 @@ static int usbvision_v4l2_open(struct file *file)
 static int usbvision_v4l2_close(struct file *file)
 {
 	struct usb_usbvision *usbvision = video_drvdata(file);
+	int r;
 
 	PDEBUG(DBG_IO, "close");
 
@@ -405,9 +410,10 @@ static int usbvision_v4l2_close(struct file *file)
 	usbvision_scratch_free(usbvision);
 
 	usbvision->user--;
+	r = usbvision->remove_pending;
 	mutex_unlock(&usbvision->v4l2_lock);
 
-	if (usbvision->remove_pending) {
+	if (r) {
 		printk(KERN_INFO "%s: Final disconnect\n", __func__);
 		usbvision_release(usbvision);
 		return 0;
@@ -1091,6 +1097,11 @@ static int usbvision_radio_open(struct file *file)
 
 	if (mutex_lock_interruptible(&usbvision->v4l2_lock))
 		return -ERESTARTSYS;
+
+	if (usbvision->remove_pending) {
+		err_code = -ENODEV;
+		goto out;
+	}
 	err_code = v4l2_fh_open(file);
 	if (err_code)
 		goto out;
@@ -1123,6 +1134,7 @@ static int usbvision_radio_open(struct file *file)
 static int usbvision_radio_close(struct file *file)
 {
 	struct usb_usbvision *usbvision = video_drvdata(file);
+	int r;
 
 	PDEBUG(DBG_IO, "");
 
@@ -1135,9 +1147,10 @@ static int usbvision_radio_close(struct file *file)
 	usbvision_audio_off(usbvision);
 	usbvision->radio = 0;
 	usbvision->user--;
+	r = usbvision->remove_pending;
 	mutex_unlock(&usbvision->v4l2_lock);
 
-	if (usbvision->remove_pending) {
+	if (r) {
 		printk(KERN_INFO "%s: Final disconnect\n", __func__);
 		v4l2_fh_release(file);
 		usbvision_release(usbvision);
@@ -1562,6 +1575,7 @@ static int usbvision_probe(struct usb_interface *intf,
 static void usbvision_disconnect(struct usb_interface *intf)
 {
 	struct usb_usbvision *usbvision = to_usbvision(usb_get_intfdata(intf));
+	int u;
 
 	PDEBUG(DBG_PROBE, "");
 
@@ -1578,13 +1592,14 @@ static void usbvision_disconnect(struct usb_interface *intf)
 	v4l2_device_disconnect(&usbvision->v4l2_dev);
 	usbvision_i2c_unregister(usbvision);
 	usbvision->remove_pending = 1;	/* Now all ISO data will be ignored */
+	u = usbvision->user;
 
 	usb_put_dev(usbvision->dev);
 	usbvision->dev = NULL;	/* USB device is no more */
 
 	mutex_unlock(&usbvision->v4l2_lock);
 
-	if (usbvision->user) {
+	if (u) {
 		printk(KERN_INFO "%s: In use, disconnect pending\n",
 		       __func__);
 		wake_up_interruptible(&usbvision->wait_frame);
drivers/media/usb/uvc/uvc_driver.c +15 -13
index c2939d080997..6445b638f207 100644
@@ -2059,6 +2059,20 @@ static int uvc_probe(struct usb_interface *intf,
 			   sizeof(dev->name) - len);
 	}
 
+	/* Initialize the media device. */
+#ifdef CONFIG_MEDIA_CONTROLLER
+	dev->mdev.dev = &intf->dev;
+	strscpy(dev->mdev.model, dev->name, sizeof(dev->mdev.model));
+	if (udev->serial)
+		strscpy(dev->mdev.serial, udev->serial,
+			sizeof(dev->mdev.serial));
+	usb_make_path(udev, dev->mdev.bus_info, sizeof(dev->mdev.bus_info));
+	dev->mdev.hw_revision = le16_to_cpu(udev->descriptor.bcdDevice);
+	media_device_init(&dev->mdev);
+
+	dev->vdev.mdev = &dev->mdev;
+#endif
+
 	/* Parse the Video Class control descriptor. */
 	if (uvc_parse_control(dev) < 0) {
 		uvc_trace(UVC_TRACE_PROBE, "Unable to parse UVC "
@@ -2079,19 +2093,7 @@ static int uvc_probe(struct usb_interface *intf,
 			"linux-uvc-devel mailing list.\n");
 	}
 
-	/* Initialize the media device and register the V4L2 device. */
-#ifdef CONFIG_MEDIA_CONTROLLER
-	dev->mdev.dev = &intf->dev;
-	strlcpy(dev->mdev.model, dev->name, sizeof(dev->mdev.model));
-	if (udev->serial)
-		strlcpy(dev->mdev.serial, udev->serial,
-			sizeof(dev->mdev.serial));
-	strcpy(dev->mdev.bus_info, udev->devpath);
-	dev->mdev.hw_revision = le16_to_cpu(udev->descriptor.bcdDevice);
-	media_device_init(&dev->mdev);
-
-	dev->vdev.mdev = &dev->mdev;
-#endif
+	/* Register the V4L2 device. */
 	if (v4l2_device_register(&intf->dev, &dev->vdev) < 0)
 		goto error;
 
drivers/mfd/arizona-core.c +4 -4
index d8e3184bd27c..ad8a5296c50b 100644
@@ -52,8 +52,10 @@ int arizona_clk32k_enable(struct arizona *arizona)
 			if (ret != 0)
 				goto err_ref;
 			ret = clk_prepare_enable(arizona->mclk[ARIZONA_MCLK1]);
-			if (ret != 0)
-				goto err_pm;
+			if (ret != 0) {
+				pm_runtime_put_sync(arizona->dev);
+				goto err_ref;
+			}
 			break;
 		case ARIZONA_32KZ_MCLK2:
 			ret = clk_prepare_enable(arizona->mclk[ARIZONA_MCLK2]);
@@ -67,8 +69,6 @@ int arizona_clk32k_enable(struct arizona *arizona)
 					 ARIZONA_CLK_32K_ENA);
 	}
 
-err_pm:
-	pm_runtime_put_sync(arizona->dev);
 err_ref:
 	if (ret != 0)
 		arizona->clk32k_ref--;
drivers/mfd/intel_soc_pmic_bxtwc.c +31 -10

94 lines not on this page · raw message

drivers/mfd/max8997.c +1 -7
index 2d6e2c392786..4a2fc59d5901 100644
@@ -155,12 +155,6 @@ static struct max8997_platform_data *max8997_i2c_parse_dt_pdata(
 
 	pd->ono = irq_of_parse_and_map(dev->of_node, 1);
 
-	/*
-	 * ToDo: the 'wakeup' member in the platform data is more of a linux
-	 * specfic information. Hence, there is no binding for that yet and
-	 * not parsed here.
-	 */
-
 	return pd;
 }
 
@@ -248,7 +242,7 @@ static int max8997_i2c_probe(struct i2c_client *i2c,
 	 */
 
 	/* MAX8997 has a power button input. */
-	device_init_wakeup(max8997->dev, pdata->wakeup);
+	device_init_wakeup(max8997->dev, true);
 
 	return ret;
 
drivers/mfd/mc13xxx-core.c +2 -1
index 6c16f170529f..75d52034f89d 100644
@@ -278,7 +278,8 @@ int mc13xxx_adc_do_conversion(struct mc13xxx *mc13xxx, unsigned int mode,
 	if (ret)
 		goto out;
 
-	adc0 = MC13XXX_ADC0_ADINC1 | MC13XXX_ADC0_ADINC2;
+	adc0 = MC13XXX_ADC0_ADINC1 | MC13XXX_ADC0_ADINC2 |
+	       MC13XXX_ADC0_CHRGRAWDIV;
 	adc1 = MC13XXX_ADC1_ADEN | MC13XXX_ADC1_ADTRIGIGN | MC13XXX_ADC1_ASC;
 
 	if (channel > 7)
drivers/misc/mic/scif/scif_fence.c +1 -1
index cac3bcc308a7..7bb929f05d85 100644
@@ -272,7 +272,7 @@ static int _scif_prog_signal(scif_epd_t epd, dma_addr_t dst, u64 val)
 dma_fail:
 	if (!x100)
 		dma_pool_free(ep->remote_dev->signal_pool, status,
-			      status->src_dma_addr);
+			      src - offsetof(struct scif_status, val));
 alloc_fail:
 	return err;
 }
drivers/mmc/host/mtk-sd.c +1 -1
index 267f7ab08420..a2ac9938d945 100644
@@ -885,6 +885,7 @@ static void msdc_start_command(struct msdc_host *host,
 	WARN_ON(host->cmd);
 	host->cmd = cmd;
 
+	mod_delayed_work(system_wq, &host->req_timeout, DAT_TIMEOUT);
 	if (!msdc_cmd_is_ready(host, mrq, cmd))
 		return;
 
@@ -896,7 +897,6 @@ static void msdc_start_command(struct msdc_host *host,
 
 	cmd->error = 0;
 	rawcmd = msdc_cmd_prepare_raw_cmd(host, mrq, cmd);
-	mod_delayed_work(system_wq, &host->req_timeout, DAT_TIMEOUT);
 
 	sdr_set_bits(host->base + MSDC_INTEN, cmd_ints_mask);
 	writel(cmd->arg, host->base + SDC_ARG);
drivers/net/dsa/bcm_sf2.c +4 -0
index 604c5abc08eb..af666951a959 100644
@@ -1196,12 +1196,16 @@ static int bcm_sf2_sw_probe(struct platform_device *pdev)
 		return ret;
 	}
 
+	bcm_sf2_gphy_enable_set(priv->dev->ds, true);
+
 	ret = bcm_sf2_mdio_register(ds);
 	if (ret) {
 		pr_err("failed to register MDIO bus\n");
 		return ret;
 	}
 
+	bcm_sf2_gphy_enable_set(priv->dev->ds, false);
+
 	ret = bcm_sf2_cfp_rst(priv);
 	if (ret) {
 		pr_err("failed to reset CFP\n");
drivers/net/dsa/mv88e6xxx/chip.c +2 -2
index 0fff1502267a..be17194487c6 100644
@@ -2527,7 +2527,7 @@ static const struct mv88e6xxx_ops mv88e6141_ops = {
 	.port_set_link = mv88e6xxx_port_set_link,
 	.port_set_duplex = mv88e6xxx_port_set_duplex,
 	.port_set_rgmii_delay = mv88e6390_port_set_rgmii_delay,
-	.port_set_speed = mv88e6390_port_set_speed,
+	.port_set_speed = mv88e6341_port_set_speed,
 	.port_tag_remap = mv88e6095_port_tag_remap,
 	.port_set_frame_mode = mv88e6351_port_set_frame_mode,
 	.port_set_egress_floods = mv88e6352_port_set_egress_floods,
@@ -3029,7 +3029,7 @@ static const struct mv88e6xxx_ops mv88e6341_ops = {
 	.port_set_link = mv88e6xxx_port_set_link,
 	.port_set_duplex = mv88e6xxx_port_set_duplex,
 	.port_set_rgmii_delay = mv88e6390_port_set_rgmii_delay,
-	.port_set_speed = mv88e6390_port_set_speed,
+	.port_set_speed = mv88e6341_port_set_speed,
 	.port_tag_remap = mv88e6095_port_tag_remap,
 	.port_set_frame_mode = mv88e6351_port_set_frame_mode,
 	.port_set_egress_floods = mv88e6352_port_set_egress_floods,
drivers/net/dsa/mv88e6xxx/port.c +23 -2
index 2cffecfe86e3..fd0a88c56031 100644
@@ -203,8 +203,11 @@ static int mv88e6xxx_port_set_speed(struct mv88e6xxx_chip *chip, int port,
 		ctrl = MV88E6XXX_PORT_MAC_CTL_SPEED_1000;
 		break;
 	case 2500:
-		ctrl = MV88E6390_PORT_MAC_CTL_SPEED_10000 |
-			MV88E6390_PORT_MAC_CTL_ALTSPEED;
+		if (alt_bit)
+			ctrl = MV88E6390_PORT_MAC_CTL_SPEED_10000 |
+				MV88E6390_PORT_MAC_CTL_ALTSPEED;
+		else
+			ctrl = MV88E6390_PORT_MAC_CTL_SPEED_10000;
 		break;
 	case 10000:
 		/* all bits set, fall through... */
@@ -266,6 +269,24 @@ int mv88e6185_port_set_speed(struct mv88e6xxx_chip *chip, int port, int speed)
 	return mv88e6xxx_port_set_speed(chip, port, speed, false, false);
 }
 
+/* Support 10, 100, 200, 1000, 2500 Mbps (e.g. 88E6341) */
+int mv88e6341_port_set_speed(struct mv88e6xxx_chip *chip, int port, int speed)
+{
+	if (speed == SPEED_MAX)
+		speed = port < 5 ? 1000 : 2500;
+
+	if (speed > 2500)
+		return -EOPNOTSUPP;
+
+	if (speed == 200 && port != 0)
+		return -EOPNOTSUPP;
+
+	if (speed == 2500 && port < 5)
+		return -EOPNOTSUPP;
+
+	return mv88e6xxx_port_set_speed(chip, port, speed, !port, true);
+}
+
 /* Support 10, 100, 200, 1000 Mbps (e.g. 88E6352 family) */
 int mv88e6352_port_set_speed(struct mv88e6xxx_chip *chip, int port, int speed)
 {
drivers/net/dsa/mv88e6xxx/port.h +1 -0
index ccdc67fe9079..8a645683cf6b 100644
@@ -262,6 +262,7 @@ int mv88e6xxx_port_set_duplex(struct mv88e6xxx_chip *chip, int port, int dup);
 
 int mv88e6065_port_set_speed(struct mv88e6xxx_chip *chip, int port, int speed);
 int mv88e6185_port_set_speed(struct mv88e6xxx_chip *chip, int port, int speed);
+int mv88e6341_port_set_speed(struct mv88e6xxx_chip *chip, int port, int speed);
 int mv88e6352_port_set_speed(struct mv88e6xxx_chip *chip, int port, int speed);
 int mv88e6390_port_set_speed(struct mv88e6xxx_chip *chip, int port, int speed);
 int mv88e6390x_port_set_speed(struct mv88e6xxx_chip *chip, int port, int speed);
drivers/net/ethernet/amazon/Kconfig +1 -1
index 99b30353541a..9e87d7b8360f 100644
@@ -17,7 +17,7 @@ if NET_VENDOR_AMAZON
 
 config ENA_ETHERNET
 	tristate "Elastic Network Adapter (ENA) support"
-	depends on (PCI_MSI && X86)
+	depends on PCI_MSI && !CPU_BIG_ENDIAN
 	---help---
 	  This driver supports Elastic Network Adapter (ENA)"
 
drivers/net/ethernet/broadcom/genet/bcmgenet.c +1 -1
index 1cc4fb27c13b..b6af286fa5c7 100644
@@ -1138,7 +1138,7 @@ static int bcmgenet_power_down(struct bcmgenet_priv *priv,
 		break;
 	}
 
-	return 0;
+	return ret;
 }
 
 static void bcmgenet_power_up(struct bcmgenet_priv *priv,
drivers/net/ethernet/hisilicon/hns3/hns3pf/hns3_enet.c +21 -3
index 5483cb23c08a..e9cff8ed5e07 100644
@@ -2300,7 +2300,7 @@ static int hns3_get_vector_ring_chain(struct hns3_enet_tqp_vector *tqp_vector,
 			chain = devm_kzalloc(&pdev->dev, sizeof(*chain),
 					     GFP_KERNEL);
 			if (!chain)
-				return -ENOMEM;
+				goto err_free_chain;
 
 			cur_chain->next = chain;
 			chain->tqp_index = tx_ring->tqp->tqp_index;
@@ -2324,7 +2324,7 @@ static int hns3_get_vector_ring_chain(struct hns3_enet_tqp_vector *tqp_vector,
 	while (rx_ring) {
 		chain = devm_kzalloc(&pdev->dev, sizeof(*chain), GFP_KERNEL);
 		if (!chain)
-			return -ENOMEM;
+			goto err_free_chain;
 
 		cur_chain->next = chain;
 		chain->tqp_index = rx_ring->tqp->tqp_index;
@@ -2336,6 +2336,16 @@ static int hns3_get_vector_ring_chain(struct hns3_enet_tqp_vector *tqp_vector,
 	}
 
 	return 0;
+
+err_free_chain:
+	cur_chain = head->next;
+	while (cur_chain) {
+		chain = cur_chain->next;
+		devm_kfree(&pdev->dev, chain);
+		cur_chain = chain;
+	}
+
+	return -ENOMEM;
 }
 
 static void hns3_free_vector_ring_chain(struct hns3_enet_tqp_vector *tqp_vector,
@@ -2530,8 +2540,10 @@ static int hns3_queue_to_ring(struct hnae3_queue *tqp,
 		return ret;
 
 	ret = hns3_ring_get_cfg(tqp, priv, HNAE3_RING_TYPE_RX);
-	if (ret)
+	if (ret) {
+		devm_kfree(priv->dev, priv->ring_data[tqp->tqp_index].ring);
 		return ret;
+	}
 
 	return 0;
 }
@@ -2556,6 +2568,12 @@ static int hns3_get_ring_config(struct hns3_nic_priv *priv)
 
 	return 0;
 err:
+	while (i--) {
+		devm_kfree(priv->dev, priv->ring_data[i].ring);
+		devm_kfree(priv->dev,
+			   priv->ring_data[i + h->kinfo.num_tqps].ring);
+	}
+
 	devm_kfree(&pdev->dev, priv->ring_data);
 	return ret;
 }
drivers/net/ethernet/intel/igb/igb_ptp.c +7 -1
index 0746b19ec6d3..295d27f33104 100644
@@ -65,9 +65,15 @@
  *
  * The 40 bit 82580 SYSTIM overflows every
  *   2^40 * 10^-9 /  60  = 18.3 minutes.
+ *
+ * SYSTIM is converted to real time using a timecounter. As
+ * timecounter_cyc2time() allows old timestamps, the timecounter
+ * needs to be updated at least once per half of the SYSTIM interval.
+ * Scheduling of delayed work is not very accurate, so we aim for 8
+ * minutes to be sure the actual interval is shorter than 9.16 minutes.
  */
 
-#define IGB_SYSTIM_OVERFLOW_PERIOD	(HZ * 60 * 9)
+#define IGB_SYSTIM_OVERFLOW_PERIOD	(HZ * 60 * 8)
 #define IGB_PTP_TX_TIMEOUT		(HZ * 15)
 #define INCPERIOD_82576			BIT(E1000_TIMINCA_16NS_SHIFT)
 #define INCVALUE_82576_MASK		GENMASK(E1000_TIMINCA_16NS_SHIFT - 1, 0)
drivers/net/ethernet/mellanox/mlx4/en_ethtool.c +1 -0
index d631cd94ee63..25a15bdc125e 100644
@@ -1722,6 +1722,7 @@ static int mlx4_en_get_rxnfc(struct net_device *dev, struct ethtool_rxnfc *cmd,
 		err = mlx4_en_get_flow(dev, cmd, cmd->fs.location);
 		break;
 	case ETHTOOL_GRXCLSRLALL:
+		cmd->data = MAX_NUM_OF_FS_RULES;
 		while ((!err || err == -ENOENT) && priority < cmd->rule_cnt) {
 			err = mlx4_en_get_flow(dev, cmd, i);
 			if (!err)
drivers/net/ethernet/mellanox/mlx5/core/eswitch.c +1 -1
index 090d54275a7d..387758fc6be4 100644
@@ -1783,7 +1783,7 @@ int mlx5_eswitch_set_vport_state(struct mlx5_eswitch *esw,
 
 unlock:
 	mutex_unlock(&esw->state_lock);
-	return 0;
+	return err;
 }
 
 int mlx5_eswitch_get_vport_config(struct mlx5_eswitch *esw,
drivers/net/ethernet/mellanox/mlxfw/mlxfw_fsm.c +2 -0
index 2cf89126fb23..d765e7a69d6b 100644
@@ -86,6 +86,8 @@ static int mlxfw_fsm_state_wait(struct mlxfw_dev *mlxfw_dev, u32 fwhandle,
 		return err;
 
 	if (fsm_state_err != MLXFW_FSM_STATE_ERR_OK) {
+		fsm_state_err = min_t(enum mlxfw_fsm_state_err,
+				      fsm_state_err, MLXFW_FSM_STATE_ERR_MAX);
 		pr_err("Firmware flash failed: %s\n",
 		       mlxfw_fsm_state_err_str[fsm_state_err]);
 		return -EINVAL;
drivers/net/ethernet/qlogic/qed/qed.h +1 -1
index 91003bc6f00b..6c4714a8b54c 100644
@@ -829,7 +829,7 @@ u16 qed_get_cm_pq_idx_vf(struct qed_hwfn *p_hwfn, u16 vf);
 /* Prototypes */
 int qed_fill_dev_info(struct qed_dev *cdev,
 		      struct qed_dev_info *dev_info);
-void qed_link_update(struct qed_hwfn *hwfn);
+void qed_link_update(struct qed_hwfn *hwfn, struct qed_ptt *ptt);
 u32 qed_unzip_data(struct qed_hwfn *p_hwfn,
 		   u32 input_len, u8 *input_buf,
 		   u32 max_size, u8 *unzip_buf);
drivers/net/ethernet/qlogic/qed/qed_main.c +18 -4
index 557332f1f886..52e747fd9c83 100644
@@ -1389,6 +1389,7 @@ static int qed_get_link_data(struct qed_hwfn *hwfn,
 }
 
 static void qed_fill_link(struct qed_hwfn *hwfn,
+			  struct qed_ptt *ptt,
 			  struct qed_link_output *if_link)
 {
 	struct qed_mcp_link_params params;
@@ -1469,7 +1470,7 @@ static void qed_fill_link(struct qed_hwfn *hwfn,
 
 	/* TODO - fill duplex properly */
 	if_link->duplex = DUPLEX_FULL;
-	qed_mcp_get_media_type(hwfn->cdev, &media_type);
+	qed_mcp_get_media_type(hwfn, ptt, &media_type);
 	if_link->port = qed_get_port_type(media_type);
 
 	if_link->autoneg = params.speed.autoneg;
@@ -1525,21 +1526,34 @@ static void qed_fill_link(struct qed_hwfn *hwfn,
 static void qed_get_current_link(struct qed_dev *cdev,
 				 struct qed_link_output *if_link)
 {
+	struct qed_hwfn *hwfn;
+	struct qed_ptt *ptt;
 	int i;
 
-	qed_fill_link(&cdev->hwfns[0], if_link);
+	hwfn = &cdev->hwfns[0];
+	if (IS_PF(cdev)) {
+		ptt = qed_ptt_acquire(hwfn);
+		if (ptt) {
+			qed_fill_link(hwfn, ptt, if_link);
+			qed_ptt_release(hwfn, ptt);
+		} else {
+			DP_NOTICE(hwfn, "Failed to fill link; No PTT\n");
+		}
+	} else {
+		qed_fill_link(hwfn, NULL, if_link);
+	}
 
 	for_each_hwfn(cdev, i)
 		qed_inform_vf_link_state(&cdev->hwfns[i]);
 }
 
-void qed_link_update(struct qed_hwfn *hwfn)
+void qed_link_update(struct qed_hwfn *hwfn, struct qed_ptt *ptt)
 {
 	void *cookie = hwfn->cdev->ops_cookie;
 	struct qed_common_cb_ops *op = hwfn->cdev->protocol_ops.common;
 	struct qed_link_output if_link;
 
-	qed_fill_link(hwfn, &if_link);
+	qed_fill_link(hwfn, ptt, &if_link);
 	qed_inform_vf_link_state(hwfn);
 
 	if (IS_LEAD_HWFN(hwfn) && cookie)
drivers/net/ethernet/qlogic/qed/qed_mcp.c +12 -15
index 7938abe9a301..ef17ca09d303 100644
@@ -1352,7 +1352,7 @@ static void qed_mcp_handle_link_change(struct qed_hwfn *p_hwfn,
 	if (p_hwfn->mcp_info->capabilities & FW_MB_PARAM_FEATURE_SUPPORT_EEE)
 		qed_mcp_read_eee_config(p_hwfn, p_ptt, p_link);
 
-	qed_link_update(p_hwfn);
+	qed_link_update(p_hwfn, p_ptt);
 out:
 	spin_unlock_bh(&p_hwfn->mcp_info->link_lock);
 }
@@ -1722,12 +1722,10 @@ int qed_mcp_get_mbi_ver(struct qed_hwfn *p_hwfn,
 	return 0;
 }
 
-int qed_mcp_get_media_type(struct qed_dev *cdev, u32 *p_media_type)
+int qed_mcp_get_media_type(struct qed_hwfn *p_hwfn,
+			   struct qed_ptt *p_ptt, u32 *p_media_type)
 {
-	struct qed_hwfn *p_hwfn = &cdev->hwfns[0];
-	struct qed_ptt  *p_ptt;
-
-	if (IS_VF(cdev))
+	if (IS_VF(p_hwfn->cdev))
 		return -EINVAL;
 
 	if (!qed_mcp_is_init(p_hwfn)) {
@@ -1735,16 +1733,15 @@ int qed_mcp_get_media_type(struct qed_dev *cdev, u32 *p_media_type)
 		return -EBUSY;
 	}
 
-	*p_media_type = MEDIA_UNSPECIFIED;
-
-	p_ptt = qed_ptt_acquire(p_hwfn);
-	if (!p_ptt)
-		return -EBUSY;
-
-	*p_media_type = qed_rd(p_hwfn, p_ptt, p_hwfn->mcp_info->port_addr +
-			       offsetof(struct public_port, media_type));
+	if (!p_ptt) {
+		*p_media_type = MEDIA_UNSPECIFIED;
+		return -EINVAL;
+	}
 
-	qed_ptt_release(p_hwfn, p_ptt);
+	*p_media_type = qed_rd(p_hwfn, p_ptt,
+			       p_hwfn->mcp_info->port_addr +
+			       offsetof(struct public_port,
+					media_type));
 
 	return 0;
 }
drivers/net/ethernet/qlogic/qed/qed_mcp.h +3 -2
index f1fe5e3427ea..8fcdb2c3e5db 100644
@@ -284,14 +284,15 @@ int qed_mcp_get_mbi_ver(struct qed_hwfn *p_hwfn,
  * @brief Get media type value of the port.
  *
  * @param cdev      - qed dev pointer
+ * @param p_ptt
  * @param mfw_ver    - media type value
  *
  * @return int -
  *      0 - Operation was successul.
  *      -EBUSY - Operation failed
  */
-int qed_mcp_get_media_type(struct qed_dev      *cdev,
-			   u32                  *media_type);
+int qed_mcp_get_media_type(struct qed_hwfn *p_hwfn,
+			   struct qed_ptt *p_ptt, u32 *media_type);
 
 /**
  * @brief General function for sending commands to the MCP
drivers/net/ethernet/qlogic/qed/qed_vf.c +1 -1
index 3220086f99de..a2a9921b467b 100644
@@ -1669,7 +1669,7 @@ static void qed_handle_bulletin_change(struct qed_hwfn *hwfn)
 	ops->ports_update(cookie, vxlan_port, geneve_port);
 
 	/* Always update link configuration according to bulletin */
-	qed_link_update(hwfn);
+	qed_link_update(hwfn, NULL);
 }
 
 void qed_iov_vf_task(struct work_struct *work)
drivers/net/ethernet/qlogic/qlcnic/qlcnic_dcb.c +1 -1
index 4b76c69fe86d..834208e55f7b 100644
@@ -883,7 +883,7 @@ static u8 qlcnic_dcb_get_capability(struct net_device *netdev, int capid,
 	struct qlcnic_adapter *adapter = netdev_priv(netdev);
 
 	if (!test_bit(QLCNIC_DCB_STATE, &adapter->dcb->state))
-		return 0;
+		return 1;
 
 	switch (capid) {
 	case DCB_CAP_ATTR_PG:
drivers/net/ethernet/sfc/ptp.c +2 -1
index 60cdb97f58e2..f22690792697 100644
@@ -1320,7 +1320,8 @@ void efx_ptp_remove(struct efx_nic *efx)
 	(void)efx_ptp_disable(efx);
 
 	cancel_work_sync(&efx->ptp_data->work);
-	cancel_work_sync(&efx->ptp_data->pps_work);
+	if (efx->ptp_data->pps_workwq)
+		cancel_work_sync(&efx->ptp_data->pps_work);
 
 	skb_queue_purge(&efx->ptp_data->rxq);
 	skb_queue_purge(&efx->ptp_data->txq);
drivers/net/ethernet/ti/cpsw.c +1 -0
index 8cb44eabc283..a44838aac97d 100644
@@ -601,6 +601,7 @@ static void cpsw_set_promiscious(struct net_device *ndev, bool enable)
 
 			/* Clear all mcast from ALE */
 			cpsw_ale_flush_multicast(ale, ALE_ALL_PORTS, -1);
+			__dev_mc_unsync(ndev, NULL);
 
 			/* Flood All Unicast Packets to Host port */
 			cpsw_ale_control_set(ale, 0, ALE_P0_UNI_FLOOD, 1);
drivers/net/macsec.c +17 -3
index 9bcb7c3e879f..9bb65e0af7dd 100644
@@ -2798,9 +2798,6 @@ static int macsec_dev_open(struct net_device *dev)
 	struct net_device *real_dev = macsec->real_dev;
 	int err;
 
-	if (!(real_dev->flags & IFF_UP))
-		return -ENETDOWN;
-
 	err = dev_uc_add(real_dev, dev->dev_addr);
 	if (err < 0)
 		return err;
@@ -3273,6 +3270,9 @@ static int macsec_newlink(struct net *net, struct net_device *dev,
 	if (err < 0)
 		goto del_dev;
 
+	netif_stacked_transfer_operstate(real_dev, dev);
+	linkwatch_fire_event(dev);
+
 	macsec_generation++;
 
 	return 0;
@@ -3444,6 +3444,20 @@ static int macsec_notify(struct notifier_block *this, unsigned long event,
 		return NOTIFY_DONE;
 
 	switch (event) {
+	case NETDEV_DOWN:
+	case NETDEV_UP:
+	case NETDEV_CHANGE: {
+		struct macsec_dev *m, *n;
+		struct macsec_rxh_data *rxd;
+
+		rxd = macsec_data_rtnl(real_dev);
+		list_for_each_entry_safe(m, n, &rxd->secys, secys) {
+			struct net_device *dev = m->secy.netdev;
+
+			netif_stacked_transfer_operstate(real_dev, dev);
+		}
+		break;
+	}
 	case NETDEV_UNREGISTER: {
 		struct macsec_dev *m, *n;
 		struct macsec_rxh_data *rxd;
drivers/net/ntb_netdev.c +1 -1
index 0250aa9ae2cb..97bf49ad81a6 100644
@@ -236,7 +236,7 @@ static void ntb_netdev_tx_timer(unsigned long data)
 	struct ntb_netdev *dev = netdev_priv(ndev);
 
 	if (ntb_transport_tx_free_entry(dev->qp) < tx_stop) {
-		mod_timer(&dev->tx_timer, jiffies + msecs_to_jiffies(tx_time));
+		mod_timer(&dev->tx_timer, jiffies + usecs_to_jiffies(tx_time));
 	} else {
 		/* Make sure anybody stopping the queue after this sees the new
 		 * value of ntb_transport_tx_free_entry()
drivers/net/phy/dp83867.c +37 -0
index 12b09e6e03ba..e03e91d5f1b1 100644
@@ -33,10 +33,18 @@
 
 /* Extended Registers */
 #define DP83867_CFG4            0x0031
+#define DP83867_CFG4_SGMII_ANEG_MASK (BIT(5) | BIT(6))
+#define DP83867_CFG4_SGMII_ANEG_TIMER_11MS   (3 << 5)
+#define DP83867_CFG4_SGMII_ANEG_TIMER_800US  (2 << 5)
+#define DP83867_CFG4_SGMII_ANEG_TIMER_2US    (1 << 5)
+#define DP83867_CFG4_SGMII_ANEG_TIMER_16MS   (0 << 5)
+
 #define DP83867_RGMIICTL	0x0032
 #define DP83867_STRAP_STS1	0x006E
 #define DP83867_RGMIIDCTL	0x0086
 #define DP83867_IO_MUX_CFG	0x0170
+#define DP83867_10M_SGMII_CFG   0x016F
+#define DP83867_10M_SGMII_RATE_ADAPT_MASK BIT(7)
 
 #define DP83867_SW_RESET	BIT(15)
 #define DP83867_SW_RESTART	BIT(14)
@@ -283,6 +291,35 @@ static int dp83867_config_init(struct phy_device *phydev)
 		}
 	}
 
+	if (phydev->interface == PHY_INTERFACE_MODE_SGMII) {
+		/* For support SPEED_10 in SGMII mode
+		 * DP83867_10M_SGMII_RATE_ADAPT bit
+		 * has to be cleared by software. That
+		 * does not affect SPEED_100 and
+		 * SPEED_1000.
+		 */
+		val = phy_read_mmd(phydev, DP83867_DEVADDR,
+				   DP83867_10M_SGMII_CFG);
+		val &= ~DP83867_10M_SGMII_RATE_ADAPT_MASK;
+		ret = phy_write_mmd(phydev, DP83867_DEVADDR,
+				    DP83867_10M_SGMII_CFG, val);
+
+		if (ret)
+			return ret;
+
+		/* After reset SGMII Autoneg timer is set to 2us (bits 6 and 5
+		 * are 01). That is not enough to finalize autoneg on some
+		 * devices. Increase this timer duration to maximum 16ms.
+		 */
+		val = phy_read_mmd(phydev, DP83867_DEVADDR, DP83867_CFG4);
+		val &= ~DP83867_CFG4_SGMII_ANEG_MASK;
+		val |= DP83867_CFG4_SGMII_ANEG_TIMER_16MS;
+		ret = phy_write_mmd(phydev, DP83867_DEVADDR, DP83867_CFG4, val);
+
+		if (ret)
+			return ret;
+	}
+
 	/* Enable Interrupt output INT_OE in CFG3 register */
 	if (phy_interrupt_is_valid(phydev)) {
 		val = phy_read(phydev, DP83867_CFG3);
drivers/net/vrf.c +9 -10
index 03e4fcdfeab7..e0cea5c05f0e 100644
@@ -996,24 +996,23 @@ static struct sk_buff *vrf_ip6_rcv(struct net_device *vrf_dev,
 				   struct sk_buff *skb)
 {
 	int orig_iif = skb->skb_iif;
-	bool need_strict;
+	bool need_strict = rt6_need_strict(&ipv6_hdr(skb)->daddr);
+	bool is_ndisc = ipv6_ndisc_frame(skb);
 
-	/* loopback traffic; do not push through packet taps again.
-	 * Reset pkt_type for upper layers to process skb
+	/* loopback, multicast & non-ND link-local traffic; do not push through
+	 * packet taps again. Reset pkt_type for upper layers to process skb
 	 */
-	if (skb->pkt_type == PACKET_LOOPBACK) {
+	if (skb->pkt_type == PACKET_LOOPBACK || (need_strict && !is_ndisc)) {
 		skb->dev = vrf_dev;
 		skb->skb_iif = vrf_dev->ifindex;
 		IP6CB(skb)->flags |= IP6SKB_L3SLAVE;
-		skb->pkt_type = PACKET_HOST;
+		if (skb->pkt_type == PACKET_LOOPBACK)
+			skb->pkt_type = PACKET_HOST;
 		goto out;
 	}
 
-	/* if packet is NDISC or addressed to multicast or link-local
-	 * then keep the ingress interface
-	 */
-	need_strict = rt6_need_strict(&ipv6_hdr(skb)->daddr);
-	if (!ipv6_ndisc_frame(skb) && !need_strict) {
+	/* if packet is NDISC then keep the ingress interface */
+	if (!is_ndisc) {
 		vrf_rx_stats(vrf_dev, skb->len);
 		skb->dev = vrf_dev;
 		skb->skb_iif = vrf_dev->ifindex;
drivers/net/wireless/ath/ath10k/pci.c +11 -12
index 27ab3eb47534..0298ddc1ff06 100644
@@ -1039,10 +1039,9 @@ int ath10k_pci_diag_write_mem(struct ath10k *ar, u32 address,
 	struct ath10k_ce *ce = ath10k_ce_priv(ar);
 	int ret = 0;
 	u32 *buf;
-	unsigned int completed_nbytes, orig_nbytes, remaining_bytes;
+	unsigned int completed_nbytes, alloc_nbytes, remaining_bytes;
 	struct ath10k_ce_pipe *ce_diag;
 	void *data_buf = NULL;
-	u32 ce_data;	/* Host buffer address in CE space */
 	dma_addr_t ce_data_base = 0;
 	int i;
 
@@ -1056,9 +1055,10 @@ int ath10k_pci_diag_write_mem(struct ath10k *ar, u32 address,
 	 *   1) 4-byte alignment
 	 *   2) Buffer in DMA-able space
 	 */
-	orig_nbytes = nbytes;
+	alloc_nbytes = min_t(unsigned int, nbytes, DIAG_TRANSFER_LIMIT);
+
 	data_buf = (unsigned char *)dma_alloc_coherent(ar->dev,
-						       orig_nbytes,
+						       alloc_nbytes,
 						       &ce_data_base,
 						       GFP_ATOMIC);
 	if (!data_buf) {
@@ -1066,9 +1066,6 @@ int ath10k_pci_diag_write_mem(struct ath10k *ar, u32 address,
 		goto done;
 	}
 
-	/* Copy caller's data to allocated DMA buf */
-	memcpy(data_buf, data, orig_nbytes);
-
 	/*
 	 * The address supplied by the caller is in the
 	 * Target CPU virtual address space.
@@ -1081,12 +1078,14 @@ int ath10k_pci_diag_write_mem(struct ath10k *ar, u32 address,
 	 */
 	address = ath10k_pci_targ_cpu_to_ce_addr(ar, address);
 
-	remaining_bytes = orig_nbytes;
-	ce_data = ce_data_base;
+	remaining_bytes = nbytes;
 	while (remaining_bytes) {
 		/* FIXME: check cast */
 		nbytes = min_t(int, remaining_bytes, DIAG_TRANSFER_LIMIT);
 
+		/* Copy caller's data to allocated DMA buf */
+		memcpy(data_buf, data, nbytes);
+
 		/* Set up to receive directly into Target(!) address */
 		ret = __ath10k_ce_rx_post_buf(ce_diag, &address, address);
 		if (ret != 0)
@@ -1096,7 +1095,7 @@ int ath10k_pci_diag_write_mem(struct ath10k *ar, u32 address,
 		 * Request CE to send caller-supplied data that
 		 * was copied to bounce buffer to Target(!) address.
 		 */
-		ret = ath10k_ce_send_nolock(ce_diag, NULL, (u32)ce_data,
+		ret = ath10k_ce_send_nolock(ce_diag, NULL, ce_data_base,
 					    nbytes, 0, 0);
 		if (ret != 0)
 			goto done;
@@ -1137,12 +1136,12 @@ int ath10k_pci_diag_write_mem(struct ath10k *ar, u32 address,
 
 		remaining_bytes -= nbytes;
 		address += nbytes;
-		ce_data += nbytes;
+		data += nbytes;
 	}
 
 done:
 	if (data_buf) {
-		dma_free_coherent(ar->dev, orig_nbytes, data_buf,
+		dma_free_coherent(ar->dev, alloc_nbytes, data_buf,
 				  ce_data_base);
 	}
 
drivers/net/wireless/ath/ath10k/usb.c +8 -0
index f09a4ad2e9de..f9c79e21ab22 100644
@@ -49,6 +49,10 @@ ath10k_usb_alloc_urb_from_pipe(struct ath10k_usb_pipe *pipe)
 	struct ath10k_urb_context *urb_context = NULL;
 	unsigned long flags;
 
+	/* bail if this pipe is not initialized */
+	if (!pipe->ar_usb)
+		return NULL;
+
 	spin_lock_irqsave(&pipe->ar_usb->cs_lock, flags);
 	if (!list_empty(&pipe->urb_list_head)) {
 		urb_context = list_first_entry(&pipe->urb_list_head,
@@ -66,6 +70,10 @@ static void ath10k_usb_free_urb_to_pipe(struct ath10k_usb_pipe *pipe,
 {
 	unsigned long flags;
 
+	/* bail if this pipe is not initialized */
+	if (!pipe->ar_usb)
+		return;
+
 	spin_lock_irqsave(&pipe->ar_usb->cs_lock, flags);
 
 	pipe->urb_cnt++;
drivers/net/wireless/ath/ath9k/ar9003_eeprom.c +1 -1
index 3dbfd86ebe36..76385834a7de 100644
@@ -4116,7 +4116,7 @@ static void ar9003_hw_thermometer_apply(struct ath_hw *ah)
 
 static void ar9003_hw_thermo_cal_apply(struct ath_hw *ah)
 {
-	u32 data, ko, kg;
+	u32 data = 0, ko, kg;
 
 	if (!AR_SREV_9462_20_OR_LATER(ah))
 		return;
drivers/net/wireless/ath/wil6210/wmi.c +5 -4
index d63d7c326801..798516f42f2f 100644
@@ -1002,15 +1002,16 @@ int wmi_call(struct wil6210_priv *wil, u16 cmdid, void *buf, u16 len,
 {
 	int rc;
 	unsigned long remain;
+	ulong flags;
 
 	mutex_lock(&wil->wmi_mutex);
 
-	spin_lock(&wil->wmi_ev_lock);
+	spin_lock_irqsave(&wil->wmi_ev_lock, flags);
 	wil->reply_id = reply_id;
 	wil->reply_buf = reply;
 	wil->reply_size = reply_size;
 	reinit_completion(&wil->wmi_call);
-	spin_unlock(&wil->wmi_ev_lock);
+	spin_unlock_irqrestore(&wil->wmi_ev_lock, flags);
 
 	rc = __wmi_send(wil, cmdid, buf, len);
 	if (rc)
@@ -1030,11 +1031,11 @@ int wmi_call(struct wil6210_priv *wil, u16 cmdid, void *buf, u16 len,
 	}
 
 out:
-	spin_lock(&wil->wmi_ev_lock);
+	spin_lock_irqsave(&wil->wmi_ev_lock, flags);
 	wil->reply_id = 0;
 	wil->reply_buf = NULL;
 	wil->reply_size = 0;
-	spin_unlock(&wil->wmi_ev_lock);
+	spin_unlock_irqrestore(&wil->wmi_ev_lock, flags);
 
 	mutex_unlock(&wil->wmi_mutex);
 
drivers/net/wireless/broadcom/brcm80211/brcmsmac/mac80211_if.c +28 -2
index ddfdfe177e24..66f1f41b1380 100644
@@ -502,6 +502,7 @@ brcms_ops_add_interface(struct ieee80211_hw *hw, struct ieee80211_vif *vif)
 	}
 
 	spin_lock_bh(&wl->lock);
+	wl->wlc->vif = vif;
 	wl->mute_tx = false;
 	brcms_c_mute(wl->wlc, false);
 	if (vif->type == NL80211_IFTYPE_STATION)
@@ -519,6 +520,11 @@ brcms_ops_add_interface(struct ieee80211_hw *hw, struct ieee80211_vif *vif)
 static void
 brcms_ops_remove_interface(struct ieee80211_hw *hw, struct ieee80211_vif *vif)
 {
+	struct brcms_info *wl = hw->priv;
+
+	spin_lock_bh(&wl->lock);
+	wl->wlc->vif = NULL;
+	spin_unlock_bh(&wl->lock);
 }
 
 static int brcms_ops_config(struct ieee80211_hw *hw, u32 changed)
@@ -840,8 +846,8 @@ brcms_ops_ampdu_action(struct ieee80211_hw *hw,
 		status = brcms_c_aggregatable(wl->wlc, tid);
 		spin_unlock_bh(&wl->lock);
 		if (!status) {
-			brcms_err(wl->wlc->hw->d11core,
-				  "START: tid %d is not agg\'able\n", tid);
+			brcms_dbg_ht(wl->wlc->hw->d11core,
+				     "START: tid %d is not agg\'able\n", tid);
 			return -EINVAL;
 		}
 		ieee80211_start_tx_ba_cb_irqsafe(vif, sta->addr, tid);
@@ -937,6 +943,25 @@ static void brcms_ops_set_tsf(struct ieee80211_hw *hw,
 	spin_unlock_bh(&wl->lock);
 }
 
+static int brcms_ops_beacon_set_tim(struct ieee80211_hw *hw,
+				 struct ieee80211_sta *sta, bool set)
+{
+	struct brcms_info *wl = hw->priv;
+	struct sk_buff *beacon = NULL;
+	u16 tim_offset = 0;
+
+	spin_lock_bh(&wl->lock);
+	if (wl->wlc->vif)
+		beacon = ieee80211_beacon_get_tim(hw, wl->wlc->vif,
+						  &tim_offset, NULL);
+	if (beacon)
+		brcms_c_set_new_beacon(wl->wlc, beacon, tim_offset,
+				       wl->wlc->vif->bss_conf.dtim_period);
+	spin_unlock_bh(&wl->lock);
+
+	return 0;
+}
+
 static const struct ieee80211_ops brcms_ops = {
 	.tx = brcms_ops_tx,
 	.start = brcms_ops_start,
@@ -955,6 +980,7 @@ static const struct ieee80211_ops brcms_ops = {
 	.flush = brcms_ops_flush,
 	.get_tsf = brcms_ops_get_tsf,
 	.set_tsf = brcms_ops_set_tsf,
+	.set_tim = brcms_ops_beacon_set_tim,
 };
 
 void brcms_dpc(unsigned long data)
drivers/net/wireless/broadcom/brcm80211/brcmsmac/main.h +1 -0
index c4d135cff04a..9f76b880814e 100644
@@ -563,6 +563,7 @@ struct brcms_c_info {
 
 	struct wiphy *wiphy;
 	struct scb pri_scb;
+	struct ieee80211_vif *vif;
 
 	struct sk_buff *beacon;
 	u16 beacon_tim_offset;
drivers/net/wireless/cisco/airo.c +1 -1
index 54201c02fdb8..fc49255bab00 100644
@@ -5464,7 +5464,7 @@ static int proc_BSSList_open( struct inode *inode, struct file *file ) {
            we have to add a spin lock... */
 	rc = readBSSListRid(ai, doLoseSync, &BSSList_rid);
 	while(rc == 0 && BSSList_rid.index != cpu_to_le16(0xffff)) {
-		ptr += sprintf(ptr, "%pM %*s rssi = %d",
+		ptr += sprintf(ptr, "%pM %.*s rssi = %d",
 			       BSSList_rid.bssid,
 				(int)BSSList_rid.ssidLen,
 				BSSList_rid.ssid,
drivers/net/wireless/marvell/mwifiex/cfg80211.c +11 -2
index dde47c548818..5e8e34a08b2d 100644
@@ -362,11 +362,20 @@ mwifiex_cfg80211_set_tx_power(struct wiphy *wiphy,
 	struct mwifiex_power_cfg power_cfg;
 	int dbm = MBM_TO_DBM(mbm);
 
-	if (type == NL80211_TX_POWER_FIXED) {
+	switch (type) {
+	case NL80211_TX_POWER_FIXED:
 		power_cfg.is_power_auto = 0;
+		power_cfg.is_power_fixed = 1;
 		power_cfg.power_level = dbm;
-	} else {
+		break;
+	case NL80211_TX_POWER_LIMITED:
+		power_cfg.is_power_auto = 0;
+		power_cfg.is_power_fixed = 0;
+		power_cfg.power_level = dbm;
+		break;
+	case NL80211_TX_POWER_AUTOMATIC:
 		power_cfg.is_power_auto = 1;
+		break;
 	}
 
 	priv = mwifiex_get_priv(adapter, MWIFIEX_BSS_ROLE_ANY);
drivers/net/wireless/marvell/mwifiex/ioctl.h +1 -0
index 48e154e1865d..0dd592ea6e83 100644
@@ -267,6 +267,7 @@ struct mwifiex_ds_encrypt_key {
 
 struct mwifiex_power_cfg {
 	u32 is_power_auto;
+	u32 is_power_fixed;
 	u32 power_level;
 };
 
drivers/net/wireless/marvell/mwifiex/sta_ioctl.c +7 -4
index 82828a207963..a8043d76152a 100644
@@ -728,6 +728,9 @@ int mwifiex_set_tx_power(struct mwifiex_private *priv,
 	txp_cfg = (struct host_cmd_ds_txpwr_cfg *) buf;
 	txp_cfg->action = cpu_to_le16(HostCmd_ACT_GEN_SET);
 	if (!power_cfg->is_power_auto) {
+		u16 dbm_min = power_cfg->is_power_fixed ?
+			      dbm : priv->min_tx_power_level;
+
 		txp_cfg->mode = cpu_to_le32(1);
 		pg_tlv = (struct mwifiex_types_power_group *)
 			 (buf + sizeof(struct host_cmd_ds_txpwr_cfg));
@@ -742,7 +745,7 @@ int mwifiex_set_tx_power(struct mwifiex_private *priv,
 		pg->last_rate_code = 0x03;
 		pg->modulation_class = MOD_CLASS_HR_DSSS;
 		pg->power_step = 0;
-		pg->power_min = (s8) dbm;
+		pg->power_min = (s8) dbm_min;
 		pg->power_max = (s8) dbm;
 		pg++;
 		/* Power group for modulation class OFDM */
@@ -750,7 +753,7 @@ int mwifiex_set_tx_power(struct mwifiex_private *priv,
 		pg->last_rate_code = 0x07;
 		pg->modulation_class = MOD_CLASS_OFDM;
 		pg->power_step = 0;
-		pg->power_min = (s8) dbm;
+		pg->power_min = (s8) dbm_min;
 		pg->power_max = (s8) dbm;
 		pg++;
 		/* Power group for modulation class HTBW20 */
@@ -758,7 +761,7 @@ int mwifiex_set_tx_power(struct mwifiex_private *priv,
 		pg->last_rate_code = 0x20;
 		pg->modulation_class = MOD_CLASS_HT;
 		pg->power_step = 0;
-		pg->power_min = (s8) dbm;
+		pg->power_min = (s8) dbm_min;
 		pg->power_max = (s8) dbm;
 		pg->ht_bandwidth = HT_BW_20;
 		pg++;
@@ -767,7 +770,7 @@ int mwifiex_set_tx_power(struct mwifiex_private *priv,
 		pg->last_rate_code = 0x20;
 		pg->modulation_class = MOD_CLASS_HT;
 		pg->power_step = 0;
-		pg->power_min = (s8) dbm;
+		pg->power_min = (s8) dbm_min;
 		pg->power_max = (s8) dbm;
 		pg->ht_bandwidth = HT_BW_40;
 	}
drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c +1 -0
index 7806a4d2b1fc..91b01ca32e75 100644
@@ -5691,6 +5691,7 @@ static int rtl8xxxu_set_key(struct ieee80211_hw *hw, enum set_key_cmd cmd,
 		break;
 	case WLAN_CIPHER_SUITE_TKIP:
 		key->flags |= IEEE80211_KEY_FLAG_GENERATE_MMIC;
+		break;
 	default:
 		return -EOPNOTSUPP;
 	}
drivers/net/wireless/realtek/rtlwifi/rtl8192de/fw.c +1 -1
index f4129cf96e7c..bad70a4206fb 100644
@@ -173,7 +173,7 @@ static int _rtl92d_fw_init(struct ieee80211_hw *hw)
 			 rtl_read_byte(rtlpriv, FW_MAC1_READY));
 	}
 	RT_TRACE(rtlpriv, COMP_FW, DBG_DMESG,
-		 "Polling FW ready fail!! REG_MCUFWDL:0x%08ul\n",
+		 "Polling FW ready fail!! REG_MCUFWDL:0x%08x\n",
 		 rtl_read_dword(rtlpriv, REG_MCUFWDL));
 	return -1;
 }
drivers/net/wireless/ti/wlcore/vendor_cmd.c +1 -1
index 5c0bcb1fe1a1..e75c3cee0252 100644
@@ -66,7 +66,7 @@ wlcore_vendor_cmd_smart_config_start(struct wiphy *wiphy,
 out:
 	mutex_unlock(&wl->mutex);
 
-	return 0;
+	return ret;
 }
 
 static int
drivers/nfc/port100.c +1 -1
index bb43cebda9dc..60ae382f50da 100644
@@ -792,7 +792,7 @@ static int port100_send_frame_async(struct port100 *dev, struct sk_buff *out,
 
 	rc = port100_submit_urb_for_ack(dev, GFP_KERNEL);
 	if (rc)
-		usb_unlink_urb(dev->out_urb);
+		usb_kill_urb(dev->out_urb);
 
 exit:
 	mutex_unlock(&dev->out_urb_lock);
drivers/ntb/hw/intel/ntb_hw_intel.c +1 -1
index 2557e2c05b90..58068f1447bb 100644
@@ -348,7 +348,7 @@ static inline int ndev_db_clear_mask(struct intel_ntb_dev *ndev, u64 db_bits,
 	return 0;
 }
 
-static inline int ndev_vec_mask(struct intel_ntb_dev *ndev, int db_vector)
+static inline u64 ndev_vec_mask(struct intel_ntb_dev *ndev, int db_vector)
 {
 	u64 shift, mask;
 
drivers/nvme/target/fcloop.c +1 -0
index 0b0a4825b3eb..096523d8dd42 100644
@@ -535,6 +535,7 @@ fcloop_fcp_op(struct nvmet_fc_target_port *tgtport,
 			break;
 
 		/* Fall-Thru to RSP handling */
+		/* FALLTHRU */
 
 	case NVMET_FCOP_RSP:
 		if (fcpreq) {
drivers/of/unittest.c +35 -8

30 lines not on this page · raw message

drivers/pci/dwc/pci-keystone.c +3 -0
index 9bc52e4cf52a..3ea8288c1605 100644

Lines of this file are not shown. View the raw message.

drivers/pci/host/vmd.c +1 -1
index 2537b022f42d..af6d5da10ea5 100644

Lines of this file are not shown. View the raw message.

drivers/pinctrl/pinctrl-lpc18xx.c +2 -8
index d090f37ca4a1..8b4e3582af6e 100644

Lines of this file are not shown. View the raw message.

drivers/pinctrl/pinctrl-zynq.c +3 -6
index a0daf27042bd..90fd37e8207b 100644

Lines of this file are not shown. View the raw message.

drivers/pinctrl/qcom/pinctrl-spmi-gpio.c +17 -4
index 22aaf4375fac..0f0049dfaa3a 100644

Lines of this file are not shown. View the raw message.

drivers/pinctrl/sunxi/pinctrl-sunxi.c +7 -4
index 52edf3b5988d..cc8b86a16da0 100644

Lines of this file are not shown. View the raw message.

drivers/platform/x86/asus-nb-wmi.c +19 -2
index 9c4b0d7f15c3..59f3a37a44d7 100644

Lines of this file are not shown. View the raw message.

drivers/platform/x86/asus-wmi.c +1 -1
index 3f662cd774d7..1c1999600717 100644

Lines of this file are not shown. View the raw message.

drivers/platform/x86/asus-wmi.h +1 -0
index 6c1311f4b04d..57a79bddb286 100644

Lines of this file are not shown. View the raw message.

drivers/pwm/pwm-lpss.c +7 -5
index 4721a264bac2..1e69c1c9ec09 100644

Lines of this file are not shown. View the raw message.

drivers/rtc/rtc-s35390a.c +1 -1
index 7067bca5c20d..6bfff0a6d655 100644

Lines of this file are not shown. View the raw message.

drivers/scsi/dc395x.c +7 -5
index 5ee7f44cf869..830b2d2dcf20 100644

Lines of this file are not shown. View the raw message.

drivers/scsi/ips.c +1 -0
index 67621308eb9c..ea652f1e2071 100644

Lines of this file are not shown. View the raw message.

drivers/scsi/isci/host.c +4 -4
index 609dafd661d1..da4583a2fa23 100644

Lines of this file are not shown. View the raw message.

drivers/scsi/isci/host.h +1 -1
index b3539928073c..6bc3f022630a 100644

Lines of this file are not shown. View the raw message.

drivers/scsi/isci/request.c +2 -2
index ed197bc8e801..2f151708b59a 100644

Lines of this file are not shown. View the raw message.

drivers/scsi/isci/task.c +2 -2
index 6dcaed0c1fc8..fb6eba331ac6 100644

Lines of this file are not shown. View the raw message.

drivers/scsi/iscsi_tcp.c +2 -1
index e11eff6b0e97..045207b5560e 100644

Lines of this file are not shown. View the raw message.

drivers/scsi/lpfc/lpfc_els.c +25 -3
index ddd29752d96d..e5db20e8979d 100644

Lines of this file are not shown. View the raw message.

drivers/scsi/lpfc/lpfc_hbadisc.c +20 -0
index b970933a218d..d850077c5e22 100644

Lines of this file are not shown. View the raw message.

drivers/scsi/lpfc/lpfc_init.c +1 -1
index 25612ccf6ff2..15bcd00dd7a2 100644

Lines of this file are not shown. View the raw message.

drivers/scsi/lpfc/lpfc_nportdisc.c +3 -2
index a0658d158228..043bca6449cd 100644

Lines of this file are not shown. View the raw message.

drivers/scsi/lpfc/lpfc_sli.c +2 -9
index 6c2b098b7609..ebf7d3cda367 100644

Lines of this file are not shown. View the raw message.

drivers/scsi/lpfc/lpfc_sli4.h +1 -0
index 60200385fe00..a132a83ef233 100644

Lines of this file are not shown. View the raw message.

drivers/scsi/megaraid/megaraid_sas_base.c +4 -5
index 8595d83229b7..577513649afb 100644

Lines of this file are not shown. View the raw message.

drivers/scsi/mpt3sas/mpt3sas_base.c +1 -1
index 7bfe53f48d1d..817a7963a038 100644

Lines of this file are not shown. View the raw message.

drivers/scsi/mpt3sas/mpt3sas_config.c +0 -4
index dd6270125614..58acbff40abc 100644

Lines of this file are not shown. View the raw message.

drivers/scsi/mpt3sas/mpt3sas_scsih.c +35 -1
index b28efddab7b1..9ef0c6265cd2 100644

Lines of this file are not shown. View the raw message.

drivers/spi/spi-omap2-mcspi.c +7 -19
index 9bf64e6eca9b..1db4d3c1d2bf 100644

Lines of this file are not shown. View the raw message.

drivers/spi/spi-sh-msiof.c +2 -2
index db2a529accae..a7bd3c92356b 100644

Lines of this file are not shown. View the raw message.

drivers/staging/ccree/cc_hw_queue_defs.h +2 -4
index 2ae0f655e7a0..b86f47712e30 100644

Lines of this file are not shown. View the raw message.

drivers/staging/comedi/drivers/usbduxfast.c +14 -7
index 608403c7586b..f0572d6a5f63 100644

Lines of this file are not shown. View the raw message.

drivers/thermal/rcar_thermal.c +2 -2
index 73e5fee6cf1d..83126e2dce36 100644

Lines of this file are not shown. View the raw message.

drivers/tty/pty.c +12 -2
index 9e26c530d2dd..b3208b1b1028 100644

Lines of this file are not shown. View the raw message.

drivers/tty/synclink_gt.c +4 -12
index 636b8ae29b46..344e8c427c7e 100644

Lines of this file are not shown. View the raw message.

drivers/usb/misc/appledisplay.c +12 -3
index 03be7c75c5be..aad7963e40e7 100644

Lines of this file are not shown. View the raw message.

drivers/usb/misc/chaoskey.c +21 -3
index eb0795c5ff7a..3a701c1e9e75 100644

Lines of this file are not shown. View the raw message.

drivers/usb/serial/cp210x.c +1 -0
index 98e466c3cfca..8dd9852f399d 100644

Lines of this file are not shown. View the raw message.

drivers/usb/serial/mos7720.c +0 -4
index 393a91ab56ed..37967f4d93fd 100644

Lines of this file are not shown. View the raw message.

drivers/usb/serial/mos7840.c +11 -5
index 5e490177cf75..285527f115dd 100644

Lines of this file are not shown. View the raw message.

drivers/usb/serial/option.c +7 -0
index b9fad046828d..8d349f2e5656 100644

Lines of this file are not shown. View the raw message.

drivers/usb/usbip/stub_rx.c +32 -18

50 lines not on this page · raw message

drivers/vhost/vsock.c +48 -18

66 lines not on this page · raw message

drivers/virtio/virtio_ring.c +1 -1
index cc9d421c0929..b82bb0b08161 100644

Lines of this file are not shown. View the raw message.

drivers/w1/slaves/w1_ds2438.c +52 -14

66 lines not on this page · raw message

drivers/xen/balloon.c +3 -0
index 7d521babc020..71a6deeb4e71 100644

Lines of this file are not shown. View the raw message.

fs/btrfs/ctree.c +4 -0
index 27983fd657ab..d2263caff307 100644

Lines of this file are not shown. View the raw message.

fs/btrfs/super.c +3 -3
index 49a02bf091ae..204d585e012a 100644

Lines of this file are not shown. View the raw message.

fs/ceph/inode.c +0 -1
index 3818027c12f5..5999d806de78 100644

Lines of this file are not shown. View the raw message.

fs/dlm/member.c +3 -2
index 3fda3832cf6a..cad6d85911a8 100644

Lines of this file are not shown. View the raw message.

fs/dlm/user.c +1 -1
index d18e7a539f11..1f0c071d4a86 100644

Lines of this file are not shown. View the raw message.

fs/f2fs/data.c +7 -1
index cc5729445194..ac3fa4bbed2d 100644

Lines of this file are not shown. View the raw message.

fs/f2fs/dir.c +1 -0
index c0c933ad43c8..4abefd841b6c 100644

Lines of this file are not shown. View the raw message.

fs/f2fs/segment.c +3 -1
index 9e5fca35e47d..2cd0d126ef8f 100644

Lines of this file are not shown. View the raw message.

fs/gfs2/rgrp.c +11 -2
index 0d72baae5150..7cb0672294df 100644

Lines of this file are not shown. View the raw message.

fs/hfs/brec.c +1 -0
index da25c49203cc..896396554bcc 100644

Lines of this file are not shown. View the raw message.

fs/hfs/btree.c +25 -16

41 lines not on this page · raw message

fs/hfs/btree.h +1 -0
index c8b252dbb26c..dcc2aab1b2c4 100644

Lines of this file are not shown. View the raw message.

fs/hfs/catalog.c +16 -0
index 8a66405b0f8b..d365bf0b8c77 100644

Lines of this file are not shown. View the raw message.

fs/hfs/extent.c +8 -2
index 5d0182654580..263d5028d9d1 100644

Lines of this file are not shown. View the raw message.

fs/hfs/inode.c +2 -0
index 2538b49cc349..350afd67bd69 100644

Lines of this file are not shown. View the raw message.

fs/hfsplus/attributes.c +10 -0
index 2bab6b3cdba4..e6d554476db4 100644

Lines of this file are not shown. View the raw message.

fs/hfsplus/brec.c +1 -0
index d3f36982f685..0f53a486d2c1 100644

Lines of this file are not shown. View the raw message.

fs/hfsplus/btree.c +28 -16

44 lines not on this page · raw message

fs/hfsplus/catalog.c +24 -0
index a196369ba779..35472cba750e 100644

Lines of this file are not shown. View the raw message.

fs/hfsplus/extents.c +7 -1
index e8770935ce6d..58f296bfd438 100644

Lines of this file are not shown. View the raw message.

fs/hfsplus/hfsplus_fs.h +2 -0
index a015044daa05..dbb55d823385 100644

Lines of this file are not shown. View the raw message.

fs/hfsplus/inode.c +1 -0
index 190c60efbc99..5b31f4730ee9 100644

Lines of this file are not shown. View the raw message.

fs/ocfs2/buffer_head_io.c +59 -18

77 lines not on this page · raw message

fs/ocfs2/dlm/dlmdebug.c +1 -1
index 9b984cae4c4e..1d6dc8422899 100644

Lines of this file are not shown. View the raw message.

fs/ocfs2/dlmglue.c +1 -1
index 5193218f5889..e961015fb484 100644

Lines of this file are not shown. View the raw message.

fs/ocfs2/move_extents.c +17 -0
index f55f82ca3425..1565dd8e8856 100644

Lines of this file are not shown. View the raw message.

fs/ocfs2/stackglue.c +0 -6
index d6c350ba25b9..c4b029c43464 100644

Lines of this file are not shown. View the raw message.

fs/ocfs2/stackglue.h +0 -3
index e3036e1790e8..f2dce10fae54 100644

Lines of this file are not shown. View the raw message.

fs/ocfs2/xattr.c +33 -23

56 lines not on this page · raw message

fs/read_write.c +33 -0
index 38a8bcccf0dd..e8136a72c13f 100644

Lines of this file are not shown. View the raw message.

fs/xfs/xfs_buf.c +37 -1
index e4a623956df5..e5970ecdfd58 100644

Lines of this file are not shown. View the raw message.

include/linux/bitmap.h +7 -2
index 835c2271196a..aec255fb62aa 100644

Lines of this file are not shown. View the raw message.

include/linux/kvm_host.h +1 -0
index bb4758ffd403..7668c68ddb5b 100644

Lines of this file are not shown. View the raw message.

include/linux/memory_hotplug.h +1 -0
index 58e110aee7ab..d36a02935391 100644

Lines of this file are not shown. View the raw message.

include/linux/mfd/intel_soc_pmic.h +1 -0
index 5aacdb017a9f..806a4f095312 100644

Lines of this file are not shown. View the raw message.

include/linux/mfd/max8997.h +0 -1
index cf815577bd68..3ae1fe743bc3 100644

Lines of this file are not shown. View the raw message.

include/linux/mfd/mc13xxx.h +1 -0
index 638222e43e48..93011c61aafd 100644

Lines of this file are not shown. View the raw message.

kernel/auditsc.c +1 -1
index 76d789d6cea0..ffa8d64f6fef 100644

Lines of this file are not shown. View the raw message.

kernel/bpf/devmap.c +1 -2
index 482bf42e21a4..1060eee6c8d5 100644

Lines of this file are not shown. View the raw message.

kernel/printk/printk.c +1 -1
index 5b33c14ab8b2..4e50beb162c0 100644

Lines of this file are not shown. View the raw message.

kernel/sched/fair.c +11 -2
index feeb52880d35..67433fbdcb5a 100644

Lines of this file are not shown. View the raw message.

kernel/sched/topology.c +1 -1
index 9dcd80ed9d4c..867d173dab48 100644

Lines of this file are not shown. View the raw message.

mm/ksm.c +7 -7
index f50cc573815f..764486ffcd16 100644

Lines of this file are not shown. View the raw message.

mm/memory_hotplug.c +32 -16

48 lines not on this page · raw message

mm/page-writeback.c +15 -18
index e001de5ac50c..a40c075fd8f1 100644

Lines of this file are not shown. View the raw message.

net/core/dev.c +1 -1
index 9d6beb9de924..3ce68484ed5a 100644

Lines of this file are not shown. View the raw message.

net/core/rtnetlink.c +22 -1
index 925af6b43017..b598e9909fec 100644

Lines of this file are not shown. View the raw message.

net/ipv6/tcp_ipv6.c +2 -1
index 7b4ce3f9e2f4..5ec73cf386df 100644

Lines of this file are not shown. View the raw message.

net/openvswitch/conntrack.c +2 -1
index 0171b27a2b81..48d81857961c 100644

Lines of this file are not shown. View the raw message.

net/sched/act_pedit.c +4 -3
index b6f6bfad8b2a..fb0caa500ac8 100644

Lines of this file are not shown. View the raw message.

net/sunrpc/auth_gss/gss_krb5_seal.c +1 -0
index 1d74d653e6c0..ad0dcb69395d 100644

Lines of this file are not shown. View the raw message.

net/sunrpc/xprtsock.c +18 -16
index a42871a59f3b..f75b5b7c1fc2 100644

Lines of this file are not shown. View the raw message.

net/unix/af_unix.c +2 -0
index 4de9dfd14d09..99f581a61cfa 100644

Lines of this file are not shown. View the raw message.

net/vmw_vsock/virtio_transport_common.c +12 -3
index a8eb0657c1e8..d20f43057323 100644

Lines of this file are not shown. View the raw message.

net/wireless/ap.c +2 -0
index 63682176c96c..c4bd3ecef508 100644

Lines of this file are not shown. View the raw message.

net/wireless/core.h +2 -0
index 90f90c7d8bf9..507ec6446eb6 100644

Lines of this file are not shown. View the raw message.

net/wireless/sme.c +6 -2
index d014aea07160..8344153800e2 100644

Lines of this file are not shown. View the raw message.

sound/firewire/isight.c +5 -5
index 5826aa8362f1..9edb26ab16e9 100644

Lines of this file are not shown. View the raw message.

sound/i2c/cs8427.c +1 -1
index 7e21621e492a..7fd1b4000883 100644

Lines of this file are not shown. View the raw message.

sound/soc/tegra/tegra_sgtl5000.c +15 -2
index 45a4aa9d2a47..901457da25ec 100644

Lines of this file are not shown. View the raw message.

tools/gpio/Build +1 -0
index 620c1937d957..4141f35837db 100644

Lines of this file are not shown. View the raw message.

tools/gpio/Makefile +7 -3
index f8bc8656a544..6a73c06e069c 100644

Lines of this file are not shown. View the raw message.

tools/objtool/arch/x86/tools/gen-insn-attr-x86.awk +2 -2
index b02a36b2c14f..a42015b305f4 100644

Lines of this file are not shown. View the raw message.

tools/power/acpi/tools/acpidump/apmain.c +1 -1
index 943b6b614683..bed0794e3295 100644

Lines of this file are not shown. View the raw message.

tools/testing/selftests/ftrace/test.d/kprobe/kprobe_args_syntax.tc +3 -0
index 231bcd2c4eb5..1e7ac6f3362f 100644

Lines of this file are not shown. View the raw message.

tools/testing/selftests/powerpc/cache_shape/Makefile +2 -7
index 1be547434a49..7e0c175b8297 100644

Lines of this file are not shown. View the raw message.

tools/testing/selftests/powerpc/signal/Makefile +3 -8
index a7cbd5082e27..4213978f3ee2 100644

Lines of this file are not shown. View the raw message.

tools/testing/selftests/powerpc/switch_endian/Makefile +1 -0
index 30b8ff8fb82e..e4cedfe9753d 100644

Lines of this file are not shown. View the raw message.

tools/testing/selftests/watchdog/watchdog-test.c +11 -5
index 6e290874b70e..f1c6e025cbe5 100644

Lines of this file are not shown. View the raw message.

tools/usb/usbip/libsrc/usbip_host_common.c +4 -4
index 6ff7b601f854..4bb905925b0e 100644

Lines of this file are not shown. View the raw message.

virt/kvm/kvm_main.c +23 -3
index ea61162b2b53..cdaacdf7bc87 100644

Lines of this file are not shown. View the raw message.

The rest of this diff is not shown. View the raw message.

Part of the diff is not shown here. View the raw message.