Linux 4.14.99
Greg KH
maintainerI'm announcing the release of the 4.14.99 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:
http://git.kernel.org/?p=linux/kernel/git/stable/linux-stable.git;a=summary
thanks,
greg k-h
------------
Makefile | 2 arch/arm/boot/dts/gemini-dlink-dir-685.dts | 16 -- arch/arm/boot/dts/mmp2.dtsi | 9 - arch/arm/boot/dts/omap4-sdp.dts | 1 arch/arm/kernel/smp.c | 15 ++ arch/arm/mach-omap2/omap_hwmod.c | 6 arch/arm/mach-pxa/cm-x300.c | 2 arch/arm/mach-pxa/littleton.c | 2 arch/arm/mach-pxa/zeus.c | 2 arch/arm64/include/asm/io.h | 32 +++- arch/arm64/kernel/entry-ftrace.S | 1 arch/mips/boot/dts/img/boston.dts | 6 arch/mips/include/uapi/asm/inst.h | 2 arch/mips/ralink/Kconfig | 1 arch/powerpc/include/asm/fadump.h | 2 arch/powerpc/include/asm/uaccess.h | 2 arch/powerpc/kernel/fadump.c | 10 + arch/powerpc/kvm/powerpc.c | 5 arch/powerpc/mm/fault.c | 4 arch/powerpc/perf/isa207-common.c | 7 - arch/powerpc/platforms/pseries/dlpar.c | 2 arch/powerpc/platforms/pseries/hotplug-memory.c | 7 - arch/s390/include/uapi/asm/zcrypt.h | 4 arch/um/include/asm/pgtable.h | 9 + arch/x86/events/intel/core.c | 10 + arch/x86/events/intel/uncore_snbep.c | 4 arch/x86/include/asm/fpu/internal.h | 3 arch/x86/kernel/cpu/bugs.c | 2 arch/x86/kernel/cpu/mcheck/mce.c | 1 arch/x86/kvm/svm.c | 7 + arch/x86/kvm/vmx.c | 4 arch/x86/kvm/x86.c | 7 + arch/x86/pci/broadcom_bus.c | 4 crypto/Kconfig | 3 crypto/aes_ti.c | 18 ++ drivers/acpi/apei/ghes.c | 2 drivers/acpi/spcr.c | 11 + drivers/ata/sata_rcar.c | 4 drivers/base/bus.c | 12 + drivers/base/core.c | 8 + drivers/base/dd.c | 6 drivers/base/power/opp/core.c | 11 + drivers/block/drbd/drbd_nl.c | 15 +- drivers/block/drbd/drbd_receiver.c | 13 + drivers/block/sunvdc.c | 5 drivers/block/swim3.c | 6 drivers/cdrom/gdrom.c | 1 drivers/clk/imgtec/clk-boston.c | 11 + drivers/clk/imx/clk-imx6sl.c | 6 drivers/clk/sunxi-ng/ccu-sun8i-a33.c | 6 drivers/cpuidle/cpuidle-big_little.c | 7 - drivers/crypto/ux500/cryp/cryp_core.c | 4 drivers/crypto/ux500/hash/hash_core.c | 2 drivers/dma/bcm2835-dma.c | 70 +++------- drivers/dma/imx-dma.c | 8 - drivers/dma/xilinx/zynqmp_dma.c | 2 drivers/firmware/efi/vars.c | 99 +++++++++++---- drivers/fpga/altera-cvp.c | 9 + drivers/gpu/drm/drm_atomic_helper.c | 8 - drivers/gpu/drm/drm_bufs.c | 3 drivers/gpu/drm/rockchip/cdn-dp-reg.c | 2 drivers/gpu/drm/vc4/vc4_plane.c | 12 + drivers/gpu/drm/vgem/vgem_drv.c | 16 +- drivers/gpu/ipu-v3/ipu-image-convert.c | 10 + drivers/hid/hid-lenovo.c | 10 + drivers/hwmon/lm80.c | 26 ++- drivers/i2c/busses/i2c-axxia.c | 32 ++-- drivers/i2c/busses/i2c-sh_mobile.c | 1 drivers/iio/accel/kxcjk-1013.c | 1 drivers/iio/adc/meson_saradc.c | 14 +- drivers/infiniband/hw/hfi1/rc.c | 2 drivers/infiniband/hw/hfi1/ruc.c | 7 - drivers/infiniband/hw/qib/qib_ruc.c | 7 - drivers/iommu/amd_iommu.c | 9 + drivers/iommu/arm-smmu-v3.c | 8 + drivers/iommu/arm-smmu.c | 3 drivers/irqchip/irq-gic-v3-its.c | 32 ++++ drivers/isdn/hisax/hfc_pci.c | 2 drivers/md/raid10.c | 4 drivers/media/i2c/ad9389b.c | 2 drivers/media/i2c/adv7511.c | 2 drivers/media/i2c/adv7604.c | 4 drivers/media/i2c/adv7842.c | 4 drivers/media/i2c/tc358743.c | 2 drivers/media/i2c/ths8200.c | 2 drivers/media/platform/coda/coda-bit.c | 19 +- drivers/media/platform/coda/coda-common.c | 15 +- drivers/media/platform/coda/coda.h | 6 drivers/media/platform/coda/coda_regs.h | 2 drivers/media/platform/davinci/vpbe.c | 7 - drivers/media/platform/mtk-vcodec/mtk_vcodec_enc_pm.c | 10 - drivers/memstick/core/memstick.c | 3 drivers/mmc/host/bcm2835.c | 12 + drivers/mmc/host/sdhci-of-esdhc.c | 16 +- drivers/mmc/host/sdhci-xenon-phy.c | 10 + drivers/mmc/host/sdhci-xenon.c | 10 + drivers/net/ethernet/broadcom/bcmsysport.c | 25 +-- drivers/net/ethernet/broadcom/bcmsysport.h | 2 drivers/net/ethernet/cisco/enic/enic_main.c | 3 drivers/net/ethernet/freescale/fman/fman_memac.c | 2 drivers/net/ethernet/freescale/fman/fman_tgec.c | 2 drivers/net/ethernet/intel/i40e/i40e_main.c | 3 drivers/net/ethernet/intel/igb/igb_main.c | 8 - drivers/net/ethernet/marvell/skge.c | 6 drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 2 drivers/net/ethernet/mellanox/mlx5/core/en_rx.c | 14 ++ drivers/net/ethernet/mellanox/mlx5/core/main.c | 14 +- drivers/net/ethernet/mellanox/mlxsw/spectrum.c | 23 +++ drivers/net/ethernet/mellanox/mlxsw/spectrum_switchdev.c | 27 ---- drivers/net/ethernet/sun/niu.c | 10 + drivers/net/phy/dp83640.c | 13 + drivers/net/usb/smsc95xx.c | 1 drivers/net/wireless/ath/ath9k/ath9k.h | 2 drivers/net/wireless/ath/ath9k/dynack.c | 35 +++-- drivers/net/wireless/ath/ath9k/dynack.h | 6 drivers/net/wireless/ath/ath9k/xmit.c | 5 drivers/net/wireless/st/cw1200/scan.c | 13 - drivers/pci/switch/switchtec.c | 3 drivers/phy/allwinner/phy-sun4i-usb.c | 7 + drivers/pinctrl/bcm/pinctrl-bcm2835.c | 16 +- drivers/pinctrl/meson/pinctrl-meson8.c | 3 drivers/pinctrl/meson/pinctrl-meson8b.c | 13 + drivers/pinctrl/pinctrl-sx150x.c | 11 + drivers/platform/chrome/cros_ec_proto.c | 18 ++ drivers/ptp/ptp_chardev.c | 5 drivers/ptp/ptp_clock.c | 5 drivers/s390/crypto/zcrypt_error.h | 2 drivers/scsi/aic94xx/aic94xx_init.c | 8 - drivers/scsi/cxlflash/main.c | 2 drivers/scsi/lpfc/lpfc_els.c | 52 +++---- drivers/scsi/lpfc/lpfc_nportdisc.c | 5 drivers/scsi/mpt3sas/mpt3sas_scsih.c | 2 drivers/scsi/mpt3sas/mpt3sas_transport.c | 7 - drivers/scsi/smartpqi/smartpqi_init.c | 6 drivers/scsi/smartpqi/smartpqi_sis.c | 2 drivers/soc/bcm/brcmstb/common.c | 6 drivers/soc/tegra/common.c | 6 drivers/staging/iio/adc/ad7280a.c | 17 +- drivers/staging/iio/adc/ad7780.c | 6 drivers/staging/iio/resolver/ad2s90.c | 7 - drivers/staging/pi433/pi433_if.c | 4 drivers/staging/speakup/spk_ttyio.c | 6 drivers/thermal/broadcom/bcm2835_thermal.c | 11 + drivers/thermal/thermal-generic-adc.c | 12 + drivers/thermal/thermal_core.c | 12 + drivers/thermal/thermal_hwmon.h | 4 drivers/tty/serial/8250/8250_pci.c | 9 - drivers/tty/serial/fsl_lpuart.c | 4 drivers/tty/serial/samsung.c | 3 drivers/tty/serial/serial_core.c | 6 drivers/usb/core/hub.c | 10 + drivers/usb/dwc3/gadget.c | 16 +- drivers/usb/dwc3/trace.h | 2 drivers/usb/gadget/udc/net2272.c | 2 drivers/usb/mtu3/mtu3_core.c | 4 drivers/usb/mtu3/mtu3_gadget_ep0.c | 8 - drivers/usb/musb/musb_dsps.c | 9 + drivers/usb/musb/musb_gadget.c | 13 - drivers/usb/musb/musbhsdma.c | 21 +-- drivers/usb/phy/phy-am335x.c | 5 drivers/video/fbdev/clps711x-fb.c | 5 drivers/video/fbdev/core/fbcon.c | 2 drivers/video/fbdev/core/fbmem.c | 8 - drivers/watchdog/renesas_wdt.c | 9 + fs/binfmt_script.c | 10 + fs/cifs/readdir.c | 9 + fs/dlm/ast.c | 10 + fs/eventpoll.c | 2 fs/f2fs/acl.c | 14 +- fs/f2fs/data.c | 12 + fs/f2fs/f2fs.h | 11 + fs/f2fs/file.c | 3 fs/f2fs/shrinker.c | 2 fs/fuse/dev.c | 4 fs/fuse/file.c | 2 fs/nfs/super.c | 3 fs/nfsd/nfs4state.c | 57 +++++++- fs/nfsd/nfsctl.c | 2 fs/nfsd/state.h | 2 fs/nfsd/xdr4.h | 13 + fs/ocfs2/Makefile | 2 fs/ocfs2/buffer_head_io.c | 2 fs/ocfs2/dlm/Makefile | 2 fs/ocfs2/dlmfs/Makefile | 2 fs/udf/inode.c | 6 include/linux/cpu.h | 2 include/linux/genl_magic_struct.h | 5 include/linux/kvm_host.h | 3 include/linux/mlx5/driver.h | 2 include/sound/compress_driver.h | 6 kernel/cgroup/cgroup.c | 2 kernel/cpu.c | 33 ----- kernel/debug/debug_core.c | 4 kernel/debug/kdb/kdb_bt.c | 11 + kernel/debug/kdb/kdb_debugger.c | 7 - kernel/events/ring_buffer.c | 3 kernel/futex.c | 28 ++-- kernel/hung_task.c | 20 +-- kernel/locking/rtmutex.c | 37 ++++- kernel/module.c | 6 kernel/sched/fair.c | 1 kernel/smp.c | 2 kernel/sysctl.c | 2 kernel/time/timekeeping.c | 4 lib/seq_buf.c | 6 mm/percpu-km.c | 5 net/bluetooth/hci_event.c | 6 net/dccp/ccid.h | 4 net/dsa/slave.c | 12 + net/ipv6/xfrm6_tunnel.c | 3 net/mac80211/rx.c | 5 net/rds/bind.c | 6 net/rxrpc/recvmsg.c | 3 scripts/decode_stacktrace.sh | 2 scripts/gdb/linux/proc.py | 2 scripts/mod/modpost.c | 50 +++---- security/smack/smack_lsm.c | 12 + sound/pci/hda/hda_bind.c | 3 sound/pci/hda/hda_codec.h | 1 sound/pci/hda/hda_intel.c | 2 sound/soc/fsl/Kconfig | 2 sound/soc/intel/atom/sst/sst_loader.c | 8 - tools/hv/hv_kvp_daemon.c | 15 +- tools/perf/arch/x86/util/kvm-stat.c | 2 tools/perf/tests/attr.py | 2 tools/perf/tests/evsel-tp-sched.c | 2 tools/perf/util/header.c | 2 tools/perf/util/probe-file.c | 2 tools/testing/selftests/bpf/test_progs.c | 8 - virt/kvm/arm/mmio.c | 11 - virt/kvm/kvm_main.c | 6 231 files changed, 1359 insertions(+), 646 deletions(-)
Adamski, Krzysztof (Nokia - PL/Wroclaw) (1):
i2c-axxia: check for error conditions first
Aditya Pakki (1):
HID: lenovo: Add checks to fix of_led_classdev_register
Adrian Hunter (3):
mmc: sdhci-of-esdhc: Fix timeout checks
mmc: sdhci-xenon: Fix timeout checks
perf test: Fix perf_event_attr test failure
Alexander Duyck (1):
driver core: Move async_synchronize_full call
Alexey Khoroshilov (3):
media: mtk-vcodec: Release device nodes in mtk_vcodec_init_enc_pm()
media: DaVinci-VPBE: fix error handling in vpbe_initialize()
video: clps711x-fb: release disp device node in probe()
Andreas Puhm (1):
fpga: altera-cvp: Fix registration for CvP incapable devices
Andy Duan (1):
serial: fsl_lpuart: clear parity enable bit when disable parity
Andy Shevchenko (3):
ACPI: SPCR: Consider baud rate 0 as preconfigured state
usb: dwc3: trace: add missing break statement to make compiler happy
serial: 8250_pci: Make PCI class test non fatal
Anson Huang (1):
clk: imx6sl: ensure MMDC CH0 handshake is bypassed
Anton Ivanov (1):
um: Avoid marking pages with "changed protection"
Anurag Kumar Vulisha (1):
usb: dwc3: Correct the logic for checking TRB full in __dwc3_prepare_one_trb()
Arend van Spriel (1):
firmware/efi: Add NULL pointer checks in efivars API functions
Arnaldo Carvalho de Melo (2):
perf header: Fix unchecked usage of strncpy() perf probe: Fix unchecked usage of strncpy()
Arnd Bergmann (2):
ASoC: Intel: mrfld: fix uninitialized variable access
ARM: pxa: avoid section mismatch warning
Bart Van Assche (1):
timekeeping: Use proper seqcount initializer
Ben Dooks (1):
usbnet: smsc95xx: fix rx packet alignment
Beomho Seo (1):
tty: serial: samsung: Properly set flags in autoCTS mode
Bin Liu (2):
usb: musb: dsps: fix otg state machine
usb: phy: am335x: fix race condition in _probe
Bjorn Andersson (1):
thermal: generic-adc: Fix adc to temp interpolation
Bob Peterson (1):
dlm: Don't swamp the CPU with callbacks queued during recovery
Boris Brezillon (1):
drm/vc4: ->x_scaling[1] should never be set to VC4_SCALING_NONE
Brian Norris (1):
platform/chrome: don't report EC_MKBP_EVENT_SENSOR_FIFO as wakeup
Charles Keepax (1):
ALSA: compress: Fix stop handling on compressed capture streams
Chen-Yu Tsai (1):
clk: sunxi-ng: a33: Set CLK_SET_RATE_PARENT for all audio module clocks
Cheng Lin (1):
proc/sysctl: fix return error for proc_doulongvec_minmax()
Chris Perl (1):
NFS: nfs_compare_mount_options always compare auth flavors.
Christophe Leroy (2):
powerpc/uaccess: fix warning/error with access_ok() powerpc/mm: Fix reporting of kernel execute faults on the 8xx
Chunfeng Yun (1):
usb: mtu3: fix the issue about SetFeature(U1/U2_Enable)
Colin Ian King (1):
x86/PCI: Fix Broadcom CNB20LE unintended sign extension (redux)
Cong Wang (1):
net/mlx5e: Force CHECKSUM_UNNECESSARY for short ethernet frames
Damian Kos (1):
drm/rockchip: fix for mailbox read size
Dan Carpenter (1):
skge: potential memory corruption in skge_get_regs()
Dave Carroll (1):
scsi: smartpqi: correct volume status
Davidlohr Bueso (1):
fs/epoll: drop ovflist branch prediction
Deepak Sharma (1):
drm/vgem: Fix vgem_init to get drm device available.
Dennis Zhou (1):
percpu: convert spin_lock_irq to spin_lock_irqsave.
Dexuan Cui (1):
Tools: hv: kvp: Fix a warning of buffer overflow with gcc 8.0.1
Douglas Anderson (1):
kdb: Don't back trace on a cpu that didn't round up
Du Changbin (1):
scripts/gdb: fix lx-version string output
Eduardo Valentin (1):
thermal: hwmon: inline helpers when CONFIG_THERMAL_HWMON is not set
Eric Biggers (1):
crypto: aes_ti - disable interrupts while accessing S-box
Eric Dumazet (3):
dccp: fool proof ccid_hc_[rt]x_parse_options()
rxrpc: bad unlock balance in rxrpc_recvmsg
rds: fix refcount bug in rds_sock_addref
Fabio Estevam (1):
ASoC: fsl: Fix SND_SOC_EUKREA_TLV320 build error on i.MX8M
Finn Thain (1):
block/swim3: Fix -EBUSY error when re-opening device after unmount
Florian Fainelli (1):
net: systemport: Fix WoL with password after deep sleep
Frank Rowand (1):
powerpc/pseries: add of_node_put() in dlpar_detach_node()
Govindarajulu Varadarajan (1):
enic: fix checksum validation for IPv6
Greg Kroah-Hartman (2):
serial: fix race between flush_to_ldisc and tty_open Linux 4.14.99
Guoqing Jiang (1):
md: fix raid10 hang issue caused by barrier
Gustavo A. R. Silva (3):
drm/bufs: Fix Spectre v1 vulnerability
usb: gadget: udc: net2272: Fix bitwise and boolean operations perf tests evsel-tp-sched: Fix bitwise operator
Hans Verkuil (1):
media: adv*/tc358743/ths8200: fill in min width/height/pixelclock
Hans de Goede (1):
iio: accel: kxcjk1013: Add KIOX010A ACPI Hardware-ID
Harald Freudenberger (1):
s390/zcrypt: improve special ap message cmd handling
Icenowy Zheng (1):
phy: sun4i-usb: add support for missing USB PHY index
Ido Schimmel (1):
mlxsw: spectrum: Properly cleanup LAG uppers when removing port from LAG
J. Bruce Fields (3):
nfsd4: fix crash on writing v4_end_grace before nfsd startup
nfsd4: fix cached replies to solo SEQUENCE compounds
nfsd4: catch some false session retries
James Bottomley (1):
scsi: aic94xx: fix module loading
James Smart (2):
scsi: lpfc: Correct LCB RJT handling
scsi: lpfc: Fix LOGO/PLOGI handling when triggerd by ABTS Timeout event
Jan Kara (1):
udf: Fix BUG on corrupted inode
Jann Horn (2):
fuse: call pipe_buf_release() under pipe lock
kvm: fix kvm_ioctl_create_device() reference counting (CVE-2019-6974)
Jia-Ju Bai (2):
cw1200: Fix concurrency use-after-free bugs in cw1200_hw_scan()
isdn: hisax: hfc_pci: Fix a possible concurrency use-after-free bug in HFCPCI_l1hw()
Jim Mattson (1):
kvm: Change offset in kvm_write_guest_offset_cached to unsigned
Jiong Wang (1):
mips: bpf: fix encoding bug for mm_srlv32_op
Joey Zhang (1):
switchtec: Fix SWITCHTEC_IOCTL_EVENT_IDX_ALL flags overwrite
Johan Hedberg (1):
Bluetooth: Fix unnecessary error message for HCI request completion
Johan Hovold (1):
staging: speakup: fix tty-operation NULL derefs
Johannes Berg (1):
mac80211: fix radiotap vendor presence bitmap handling
Josh Poimboeuf (1):
cpu/hotplug: Fix "SMT disabled by BIOS" detection for KVM
Junxiao Bi (1):
ocfs2: don't clear bh uptodate for block read
Kai-Heng Feng (2):
memstick: Prevent memstick host from getting runtime suspended during card detection
igb: Fix an issue that PME is not enabled during runtime suspend
Kaike Wan (1):
IB/hfi1: Unreserve a reserved request when it is completed
Kan Liang (1):
perf/x86/intel/uncore: Add Node ID mask
Kangjie Lu (3):
hwmon: (lm80) fix a missing check of the status of SMBus read
hwmon: (lm80) fix a missing check of bus read in lm80 probe
niu: fix missing checks of niu_pci_eeprom_read
Konstantin Khorenko (1):
i40e: define proper net_device::neigh_priv_len
Larry Chen (1):
ocfs2: improve ocfs2 Makefile
Lars Ellenberg (2):
drbd: disconnect, if the wrong UUIDs are attached on a connected peer
drbd: skip spurious timeout (ping-timeo) when failing promote
Lenny Szubowicz (1):
ACPI/APEI: Clear GHES block_status before panic()
Leonid Iziumtsev (1):
dmaengine: imx-dma: fix wrong callback invoke
Linus Walleij (1):
ARM: dts: Fix up the D-Link DIR-685 MTD partition info
Liu, Chuansheng (1):
kernel/hung_task.c: force console verbose before panic
Lorenzo Bianconi (3):
ath9k: dynack: use authentication messages for 'late' ack
ath9k: dynack: make ewma estimation faster
ath9k: dynack: check da->enabled first in sampling routines
Lubomir Rintel (1):
ARM: dts: mmp2: fix TWSI2
Lukas Wunner (3):
pinctrl: bcm2835: Use raw spinlock for RT compatibility
dmaengine: bcm2835: Fix interrupt race on RT
dmaengine: bcm2835: Fix abort of transactions
Madhavan Srinivasan (1):
powerpc/perf: Fix thresholding counter data for unknown type
Mahesh Rajashekhara (2):
scsi: smartpqi: correct host serial num for ssa
scsi: smartpqi: increase fw status register read timeout
Mahesh Salgaonkar (1):
powerpc/fadump: Do not allow hot-remove memory from fadump reserved area.
Marc Zyngier (2):
scripts/decode_stacktrace: only strip base path when a prefix of the path irqchip/gic-v3-its: Plug allocation race for devices sharing a DevID
Mark Rutland (3):
arm64: ftrace: don't adjust the LR value
arm64: KVM: Skip MMIO insn after emulation perf/core: Don't WARN() for impossible ring-buffer sizes
Martin Blumenstingl (3):
iio: adc: meson-saradc: fix internal clock names
pinctrl: meson: meson8: fix the GPIO function for the GPIOAO pins
pinctrl: meson: meson8b: fix the GPIO function for the GPIOAO pins
Matheus Tavares (1):
staging:iio:ad2s90: Make probe handle spi_setup failure
Mathias Nyman (1):
usb: hub: delay hub autosuspend if USB3 port is still link training
Matthias Brugger (1):
thermal: bcm2835: enable hwmon explicitly
Michael Ellerman (1):
seq_buf: Make seq_buf_puts() null-terminate the buffer
Michael Straube (1):
staging: pi433: fix potential null dereference
Michal Suchanek (1):
mmc: bcm2835: reset host on timeout
Mike Marciniszyn (1):
IB/hfi1: Add limit test for RC/UC send via loopback
Miklos Szeredi (2):
fuse: decrement NR_WRITEBACK_TEMP on the right page
fuse: handle zero sized retrieve correctly
Miroslav Lichvar (1):
ptp: check gettime64 return code in PTP_SYS_OFFSET ioctl
Nathan Chancellor (5):
ARM: OMAP2+: hwmod: Fix some section annotations
dmaengine: xilinx_dma: Remove __aligned attribute on zynqmp_dma_desc_ll
drbd: Avoid Clang warning about pointless switch statment
crypto: ux500 - Use proper enum in cryp_set_dma_transfer
crypto: ux500 - Use proper enum in hash_set_dma_transfer
Nicholas Mc Guire (2):
iio: adc: meson-saradc: check for devm_kasprintf failure
pinctrl: sx150x: handle failure case of devm_kstrdup
Noralf Trønnes (1):
fbdev: fbcon: Fix unregister crash when more than one framebuffer
Oleg Nesterov (1):
exec: load_script: don't blindly truncate shebang string
Ondrej Mosnacek (1):
cgroup: fix parsing empty mount option string
Paolo Bonzini (1):
KVM: x86: work around leak of uninitialized stack contents (CVE-2019-7222)
Paul Burton (1):
MIPS: Boston: Disable EG20T prefetch
Paul Elder (1):
usb: gadget: musb: fix short isoc packets with inventra dma
Peter Rajnoha (1):
kobject: return error code if writing /sys/.../uevent fails
Peter Rosin (1):
fbdev: fbmem: behave better with small rotated displays and many CPUs
Peter Shier (1):
KVM: nVMX: unconditionally cancel preemption timer in free_nested (CVE-2019-7221)
Peter Zijlstra (1):
perf/x86/intel: Delay memory deallocation until x86_pmu_dead_cpu()
Phil Elwell (1):
mmc: bcm2835: Recover from MMC_SEND_EXT_CSD
Philipp Zabel (1):
media: coda: fix H.264 deblocking filter controls
Pu Wen (1):
perf tools: Add Hygon Dhyana support
Renato Lui Geh (1):
staging: iio: ad7780: update voltage on read
Roland Kammerer (1):
drbd: narrow rcu_read_lock in drbd_sync_handshake
Ronnie Sahlberg (1):
cifs: check ntwrk_buf_start for NULL before dereferencing it
Rundong Ge (1):
net: dsa: slave: Don't propagate flag changes on down slave interfaces
Russell King - ARM Linux (1):
ARM: dts: Fix OMAP4430 SDP Ethernet startup
Saeed Mahameed (1):
net/mlx5: EQ, Use the right place to store/read IRQ affinity hint
Sahitya Tummala (1):
f2fs: fix sbi->extent_list corruption issue
Sami Tolvanen (1):
modpost: validate symbol names also in find_elf_symbol
Scott Wood (1):
fsl/fman: Use GFP_ATOMIC in {memac,tgec}_add_hash_mac_address()
Sean Paul (1):
drm: Clear state->acquire_ctx before leaving drm_atomic_helper_commit_duplicated_state()
Sebastian Andrzej Siewior (2):
x86/fpu: Add might_fault() to user_insn()
net: dp83640: expire old TX-skb
Sergei Shtylyov (1):
sata_rcar: fix deferred probing
Sheng Yong (1):
f2fs: fix race between write_checkpoint and write_begin
Simon Horman (1):
i2c: sh_mobile: add support for r8a77990 (R-Car E3)
Slawomir Stepien (1):
staging: iio: adc: ad7280a: handle error from __ad7280_read32()
Stanislav Fomichev (1):
selftests/bpf: use __bpf_constant_htons in test_prog.c
Stefan Roese (1):
MIPS: ralink: Select CONFIG_CPU_MIPSR2_IRQ_VI on MT7620/8
Steve Longerbeam (1):
gpu: ipu-v3: image-convert: Prevent race between run and unprepare
Suganath Prabu (1):
scsi: mpt3sas: Call sas_remove_host before removing the target devices
Suraj Jitindar Singh (1):
KVM: PPC: Book3S: Only report KVM_CAP_SPAPR_TCE_VFIO on powernv machines
Takashi Iwai (1):
ALSA: hda - Serialize codec registrations
Tejas Joglekar (2):
usb: dwc3: gadget: Disable CSP for stream OUT ep
usb: dwc3: gadget: Handle 0 xfer length for OUT EP
Tetsuo Handa (1):
kernel/hung_task.c: break RCU locks based on jiffies
Thomas Gleixner (1):
futex: Handle early deadlock return correctly
Tiezhu Yang (1):
f2fs: fix wrong return value of f2fs_acl_create
Tony Luck (1):
x86/MCE: Initialize mce.bank in the case of a fatal error in mce_no_way_out()
Vaibhav Jain (1):
scsi: cxlflash: Prevent deadlock when adapter probe fails
Viresh Kumar (1):
OPP: Use opp_table->regulators to verify no regulator case
Vitaly Kuznetsov (1):
KVM: x86: svm: report MSR_IA32_MCG_EXT_CTL as unsupported
Vivek Gautam (1):
iommu/arm-smmu: Add support for qcom,smmu-v2 variant
Wei Wang (1):
Thermal: do not clear passive state during system sleep
Wenwen Wang (1):
gdrom: fix a memory leak bug
Will Deacon (3):
arm64: io: Ensure calls to delay routines are ordered against prior readX()
arm64: io: Ensure value passed to __iormb() is held in a 64-bit register iommu/arm-smmu-v3: Use explicit mb() when moving cons pointer
Wolfram Sang (1):
watchdog: renesas_wdt: don't set divider while watchdog is running
Yangtao Li (3):
soc/tegra: Don't leak device tree node reference
soc: bcm: brcmstb: Don't leak device tree node reference
cpuidle: big.LITTLE: fix refcount leak
Yi Wang (1):
clk: boston: fix possible memory leak in clk_boston_setup()
Young Xiao (1):
sunvdc: Do not spin in an infinite loop when vio_ldc_send() returns EAGAIN
Yu Zhao (1):
iommu/amd: Fix amd_iommu=force_isolation
YueHaibing (2):
ptp: Fix pass zero to ERR_PTR() in ptp_clock_register
xfrm6_tunnel: Fix spi check in __xfrm6_tunnel_alloc_spi
Yufen Wang (1):
ARM: 8808/1: kexec:offline panic_smp_self_stop CPU
Yunlei He (1):
f2fs: move dir data flush to write checkpoint process
Zoran Markovic (1):
smack: fix access permissions for keyring
Greg KH
maintainerMakefile +1 -1
@@ -1,7 +1,7 @@ # SPDX-License-Identifier: GPL-2.0 VERSION = 4 PATCHLEVEL = 14 -SUBLEVEL = 98 +SUBLEVEL = 99 EXTRAVERSION = NAME = Petit Gorille
arch/arm/boot/dts/gemini-dlink-dir-685.dts +6 -10
@@ -128,20 +128,16 @@ read-only; }; /* - * Between the boot loader and the rootfs is the kernel - * in a custom Storlink format flashed from the boot - * menu. The rootfs is in squashfs format. + * This firmware image contains the kernel catenated + * with the squashfs root filesystem. For some reason + * this is called "upgrade" on the vendor system. */ - partition@1800c0 { - label = "rootfs"; - reg = <0x001800c0 0x01dbff40>; - read-only; - }; - partition@1f40000 { + partition@40000 { label = "upgrade"; - reg = <0x01f40000 0x00040000>; + reg = <0x00040000 0x01f40000>; read-only; }; + /* RGDB, Residental Gateway Database? */ partition@1f80000 { label = "rgdb"; reg = <0x01f80000 0x00040000>;
arch/arm/boot/dts/mmp2.dtsi +6 -3
@@ -220,12 +220,15 @@ status = "disabled"; }; - twsi2: i2c@d4025000 { + twsi2: i2c@d4031000 { compatible = "mrvl,mmp-twsi"; - reg = <0xd4025000 0x1000>; - interrupts = <58>; + reg = <0xd4031000 0x1000>; + interrupt-parent = <&intcmux17>; + interrupts = <0>; clocks = <&soc_clocks MMP2_CLK_TWSI1>; resets = <&soc_clocks MMP2_CLK_TWSI1>; + #address-cells = <1>; + #size-cells = <0>; status = "disabled"; };
arch/arm/boot/dts/omap4-sdp.dts +1 -0
@@ -33,6 +33,7 @@ gpio = <&gpio2 16 GPIO_ACTIVE_HIGH>; /* gpio line 48 */ enable-active-high; regulator-boot-on; + startup-delay-us = <25000>; }; vbat: fixedregulator-vbat {
arch/arm/kernel/smp.c +15 -0
@@ -691,6 +691,21 @@ void smp_send_stop(void)pr_warn ("SMP: failed to stop secondary CPUs\n" ); } +/* In case panic() and panic() called at the same time on CPU1 and CPU2, +* and CPU 1 calls panic_smp_self_stop() before crash_smp_send_stop() +* CPU1 can't receive the ipi irqs from CPU2, CPU1 will be always online, +* kdump fails. So split out the panic_smp_self_stop() and add +* set_cpu_online(smp_processor_id(), false). +*/ +void panic_smp_self_stop (void ) +{ +pr_debug ("CPU %u will stop doing anything useful since another CPU has paniced\n" , +smp_processor_id ()); +set_cpu_online (smp_processor_id (), false); +while (1 ) +cpu_relax (); +} +/* * not supported here */
arch/arm/mach-omap2/omap_hwmod.c +3 -3
@@ -2497,7 +2497,7 @@ static int __init _init(struct omap_hwmod *oh, void *data)* a stub; implementing this properly requires iclk autoidle usecounting in * the clock code. No return value. */ -static void __init _setup_iclk_autoidle (struct omap_hwmod *oh) +static void _setup_iclk_autoidle (struct omap_hwmod *oh) {struct omap_hwmod_ocp_if *os;
@@ -2528,7 +2528,7 @@ static void __init _setup_iclk_autoidle(struct omap_hwmod *oh)* reset. Returns 0 upon success or a negative error code upon * failure. */ -static int __init _setup_reset (struct omap_hwmod *oh) +static int _setup_reset (struct omap_hwmod *oh) {int r;
@@ -2589,7 +2589,7 @@ static int __init _setup_reset(struct omap_hwmod *oh)* * No return value. */ -static void __init _setup_postsetup (struct omap_hwmod *oh) +static void _setup_postsetup (struct omap_hwmod *oh) {u8 postsetup_state;
arch/arm/mach-pxa/cm-x300.c +1 -1
@@ -547,7 +547,7 @@ static struct pxa3xx_u2d_platform_data cm_x300_u2d_platform_data = { .exit = cm_x300_u2d_exit, }; -static void cm_x300_init_u2d (void ) +static void __init cm_x300_init_u2d (void ) {pxa3xx_set_u2d_info (&cm_x300_u2d_platform_data); }
arch/arm/mach-pxa/littleton.c +1 -1
@@ -183,7 +183,7 @@ static struct pxafb_mach_info littleton_lcd_info = { .lcd_conn = LCD_COLOR_TFT_16BPP, }; -static void littleton_init_lcd (void ) +static void __init littleton_init_lcd (void ) {pxa_set_fb_info (NULL , &littleton_lcd_info); }
arch/arm/mach-pxa/zeus.c +1 -1
@@ -558,7 +558,7 @@ static struct pxaohci_platform_data zeus_ohci_platform_data = { .flags = ENABLE_PORT_ALL | POWER_SENSE_LOW, }; -static void zeus_register_ohci (void ) +static void __init zeus_register_ohci (void ) {/* Port 2 is shared between host and client interface. */ UP2OCR =UP2OCR_HXOE |UP2OCR_HXS |UP2OCR_DMPDE |UP2OCR_DPPDE ;
arch/arm64/include/asm/io.h +24 -8
@@ -106,7 +106,23 @@ static inline u64 __raw_readq(const volatile void __iomem *addr) }/* IO barriers */ -#define __iormb () rmb() +#define __iormb (v) \ +({ \ + unsigned long tmp; \ + \ + rmb(); \ + \ +/* \ +* Create a dummy control dependency from the IO read to any \ +* later instructions. This ensures that a subsequent call to \ +* udelay() will be ordered due to the ISB in get_cycles(). \ +*/ \ + asmvolatile ("eor %0, %1, %1\n" \ +"cbnz %0, ." \ + :"=r" (tmp) :"r" ((unsigned long )(v)) \ + :"memory" ); \ +}) +#define __iowmb () wmb()#define mmiowb () do { } while (0)
@@ -131,10 +147,10 @@ static inline u64 __raw_readq(const volatile void __iomem *addr)* following Normal memory access. Writes are ordered relative to any prior * Normal memory access. */ -#define readb (c) ({ u8 __v = readb_relaxed(c); __iormb(); __v; }) -#define readw (c) ({ u16 __v = readw_relaxed(c); __iormb(); __v; }) -#define readl (c) ({ u32 __v = readl_relaxed(c); __iormb(); __v; }) -#define readq (c) ({ u64 __v = readq_relaxed(c); __iormb(); __v; }) +#define readb (c) ({ u8 __v = readb_relaxed(c); __iormb(__v); __v; }) +#define readw (c) ({ u16 __v = readw_relaxed(c); __iormb(__v); __v; }) +#define readl (c) ({ u32 __v = readl_relaxed(c); __iormb(__v); __v; }) +#define readq (c) ({ u64 __v = readq_relaxed(c); __iormb(__v); __v; })#define writeb (v,c) ({ __iowmb(); writeb_relaxed((v),(c)); })#define writew (v,c) ({ __iowmb(); writew_relaxed((v),(c)); })
@@ -185,9 +201,9 @@ extern void __iomem *ioremap_cache(phys_addr_t phys_addr, size_t size);/* * io{read,write}{16,32,64}be() macros */ -#define ioread16be (p) ({ __u16 __v = be16_to_cpu((__force __be16)__raw_readw(p)); __iormb(); __v; }) -#define ioread32be (p) ({ __u32 __v = be32_to_cpu((__force __be32)__raw_readl(p)); __iormb(); __v; }) -#define ioread64be (p) ({ __u64 __v = be64_to_cpu((__force __be64)__raw_readq(p)); __iormb(); __v; }) +#define ioread16be (p) ({ __u16 __v = be16_to_cpu((__force __be16)__raw_readw(p)); __iormb(__v); __v; }) +#define ioread32be (p) ({ __u32 __v = be32_to_cpu((__force __be32)__raw_readl(p)); __iormb(__v); __v; }) +#define ioread64be (p) ({ __u64 __v = be64_to_cpu((__force __be64)__raw_readq(p)); __iormb(__v); __v; })#define iowrite16be (v,p) ({ __iowmb(); __raw_writew((__force __u16)cpu_to_be16(v), p); })#define iowrite32be (v,p) ({ __iowmb(); __raw_writel((__force __u32)cpu_to_be32(v), p); })
arch/arm64/kernel/entry-ftrace.S +0 -1
@@ -79,7 +79,6 @@ .macro mcount_get_lr reg ldr \reg, [x29] ldr \reg, [\reg, #8] - mcount_adjust_addr \reg, \reg .endm .macro mcount_get_lr_addr reg
arch/mips/boot/dts/img/boston.dts +6 -0
@@ -141,6 +141,12 @@ #size-cells = <2>; #interrupt-cells = <1>; + eg20t_phub@2,0,0 { + compatible = "pci8086,8801"; + reg = <0x00020000 0 0 0 0>; + intel,eg20t-prefetch = <0>; + }; + eg20t_mac@2,0,1 { compatible = "pci8086,8802"; reg = <0x00020100 0 0 0 0>;
arch/mips/include/uapi/asm/inst.h +1 -1
@@ -369,8 +369,8 @@ enum mm_32a_minor_op { mm_ext_op =0x02c , mm_pool32axf_op =0x03c , mm_srl32_op =0x040 , + mm_srlv32_op =0x050 , mm_sra_op =0x080 , - mm_srlv32_op =0x090 , mm_rotr_op =0x0c0 , mm_lwxs_op =0x118 , mm_addu32_op = 0x150,
arch/mips/ralink/Kconfig +1 -0
@@ -39,6 +39,7 @@ choice config SOC_MT7620 bool "MT7620/8" + select CPU_MIPSR2_IRQ_VI select HW_HAS_PCI config SOC_MT7621
arch/powerpc/include/asm/fadump.h +1 -1
@@ -200,7 +200,7 @@ struct fad_crash_memory_ranges {unsigned long long size; }; -extern int is_fadump_boot_memory_area (u64 addr,ulong size); +extern int is_fadump_memory_area (u64 addr,ulong size);extern int early_init_dt_scan_fw_dump (unsigned long node,const char *uname,int depth,void *data);extern int fadump_reserve_mem (void );
arch/powerpc/include/asm/uaccess.h +1 -1
@@ -54,7 +54,7 @@#endif #define access_ok (type, addr, size) \ - (__chk_user_ptr(addr), \ + (__chk_user_ptr(addr), (void)(type), \ __access_ok((__force unsigned long)(addr), (size), get_fs()))/*
arch/powerpc/kernel/fadump.c +8 -2
@@ -117,13 +117,19 @@ int __init early_init_dt_scan_fw_dump(unsigned long node,/* * If fadump is registered, check if the memory provided -* falls within boot memory area. +* falls within boot memory area and reserved memory area. */ -int is_fadump_boot_memory_area (u64 addr,ulong size) +int is_fadump_memory_area (u64 addr,ulong size) { +u64 d_start = fw_dump.reserve_dump_area_start; +u64 d_end = d_start + fw_dump.reserve_dump_area_size; +if (!fw_dump.dump_registered)return 0 ; +if (((addr + size) > d_start) && (addr <= d_end)) +return 1 ; +return (addr + size) >RMA_START && addr <= fw_dump.boot_memory_size; }
arch/powerpc/kvm/powerpc.c +4 -1
@@ -540,8 +540,11 @@ int kvm_vm_ioctl_check_extension(struct kvm *kvm, long ext)#ifdef CONFIG_PPC_BOOK3S_64 case KVM_CAP_SPAPR_TCE :case KVM_CAP_SPAPR_TCE_64 : -/* fallthrough */ + r =1 ; +break ;case KVM_CAP_SPAPR_TCE_VFIO : + r = !!cpu_has_feature (CPU_FTR_HVMODE ); +break ;case KVM_CAP_PPC_RTAS :case KVM_CAP_PPC_FIXUP_HCALL :case KVM_CAP_PPC_ENABLE_HCALL :
arch/powerpc/mm/fault.c +3 -1
@@ -215,7 +215,9 @@ static int mm_fault_error(struct pt_regs *regs, unsigned long addr, int fault)static bool bad_kernel_fault (bool is_exec,unsigned long error_code,unsigned long address) { -if (is_exec && (error_code & (DSISR_NOEXEC_OR_G |DSISR_KEYFAULT ))) { +/* NX faults set DSISR_PROTFAULT on the 8xx, DSISR_NOEXEC_OR_G on others */ +if (is_exec && (error_code & (DSISR_NOEXEC_OR_G |DSISR_KEYFAULT | +DSISR_PROTFAULT ))) { printk_ratelimited(KERN_CRIT "kernel tried to execute" " exec-protected page (%lx) -" "exploit attempt? (uid: %d)\n",
arch/powerpc/perf/isa207-common.c +6 -1
@@ -228,8 +228,13 @@ void isa207_get_mem_weight(u64 *weight)u64 mmcra =mfspr (SPRN_MMCRA );u64 exp =MMCRA_THR_CTR_EXP (mmcra);u64 mantissa =MMCRA_THR_CTR_MANT (mmcra); +u64 sier =mfspr (SPRN_SIER ); +u64 val = (sier &ISA207_SIER_TYPE_MASK ) >>ISA207_SIER_TYPE_SHIFT ; - *weight = mantissa << (2 * exp); +if (val ==0 || val ==7 ) + *weight =0 ; +else + *weight = mantissa << (2 * exp); }int isa207_get_constraint (u64 event,unsigned long *maskp,unsigned long *valp)
arch/powerpc/platforms/pseries/dlpar.c +2 -0
@@ -284,6 +284,8 @@ int dlpar_detach_node(struct device_node *dn)if (rc)return rc; +of_node_put (dn); +return 0 ; }
arch/powerpc/platforms/pseries/hotplug-memory.c +5 -2
@@ -441,8 +441,11 @@ static bool lmb_is_removable(struct of_drconf_cell *lmb) phys_addr = lmb->base_addr;#ifdef CONFIG_FA_DUMP -/* Don't hot-remove memory that falls in fadump boot memory area */ -if (is_fadump_boot_memory_area (phys_addr, block_sz)) +/* +* Don't hot-remove memory that falls in fadump boot memory area +* and memory that is reserved for capturing old kernel memory. +*/ +if (is_fadump_memory_area (phys_addr, block_sz))return false;#endif
arch/s390/include/uapi/asm/zcrypt.h +2 -2
@@ -161,8 +161,8 @@ struct ica_xcRB {* @cprb_len: CPRB header length [0x0020] * @cprb_ver_id: CPRB version id. [0x04] * @pad_000: Alignment pad bytes -* @flags: Admin cmd [0x80] or functional cmd [0x00] -* @func_id: Function id / subtype [0x5434] +* @flags: Admin bit [0x80], Special bit [0x20] +* @func_id: Function id / subtype [0x5434] "T4" * @source_id: Source id [originator id] * @target_id: Target id [usage/ctrl domain id] * @ret_code: Return code
arch/um/include/asm/pgtable.h +8 -1
@@ -197,12 +197,17 @@ static inline pte_t pte_mkold(pte_t pte)static inline pte_t pte_wrprotect (pte_t pte) { -pte_clear_bits (pte, _PAGE_RW); +if (likely (pte_get_bits (pte, _PAGE_RW))) +pte_clear_bits (pte, _PAGE_RW); +else +return pte;return (pte_mknewprot (pte)); }static inline pte_t pte_mkread (pte_t pte) { +if (unlikely (pte_get_bits (pte, _PAGE_USER))) +return pte;pte_set_bits (pte, _PAGE_USER);return (pte_mknewprot (pte)); }
@@ -221,6 +226,8 @@ static inline pte_t pte_mkyoung(pte_t pte)static inline pte_t pte_mkwrite (pte_t pte) { +if (unlikely (pte_get_bits (pte, _PAGE_RW))) +return pte;pte_set_bits (pte, _PAGE_RW);return (pte_mknewprot (pte)); }
arch/x86/events/intel/core.c +8 -2
@@ -3419,6 +3419,11 @@ static void free_excl_cntrs(int cpu) }static void intel_pmu_cpu_dying (int cpu) +{ +fini_debug_store_on_cpu (cpu); +} + +static void intel_pmu_cpu_dead (int cpu) {struct cpu_hw_events *cpuc = &per_cpu (cpu_hw_events, cpu);struct intel_shared_regs *pc;
@@ -3431,8 +3436,6 @@ static void intel_pmu_cpu_dying(int cpu) }free_excl_cntrs (cpu); - -fini_debug_store_on_cpu (cpu); } static void intel_pmu_sched_task(struct perf_event_context *ctx,
@@ -3521,6 +3524,7 @@ static __initconst const struct x86_pmu core_pmu = { .cpu_prepare = intel_pmu_cpu_prepare, .cpu_starting = intel_pmu_cpu_starting, .cpu_dying = intel_pmu_cpu_dying, + .cpu_dead = intel_pmu_cpu_dead, };static struct attribute *intel_pmu_attrs[];
@@ -3560,6 +3564,8 @@ static __initconst const struct x86_pmu intel_pmu = { .cpu_prepare = intel_pmu_cpu_prepare, .cpu_starting = intel_pmu_cpu_starting, .cpu_dying = intel_pmu_cpu_dying, + .cpu_dead = intel_pmu_cpu_dead, + .guest_get_msrs = intel_guest_get_msrs, .sched_task = intel_pmu_sched_task, };
arch/x86/events/intel/uncore_snbep.c +3 -1
@@ -1221,6 +1221,8 @@ static struct pci_driver snbep_uncore_pci_driver = { .id_table = snbep_uncore_pci_ids, }; +#define NODE_ID_MASK 0x7 +/* * build pci bus to socket mapping */
@@ -1242,7 +1244,7 @@ static int snbep_pci2phy_map_init(int devid, int nodeid_loc, int idmap_loc, bool err =pci_read_config_dword (ubox_dev, nodeid_loc, &config);if (err)break ; - nodeid = config; + nodeid = config &NODE_ID_MASK ;/* get the Node ID mapping */ err =pci_read_config_dword (ubox_dev, idmap_loc, &config);if (err)
arch/x86/include/asm/fpu/internal.h +3 -0
@@ -106,6 +106,9 @@ extern void fpstate_sanitize_xstate(struct fpu *fpu); #define user_insn(insn, output, input...) \ ({ \ int err; \ + \ + might_fault(); \ + \ asm volatile(ASM_STAC "\n" \ "1:" #insn "\n\t" \ "2: " ASM_CLAC "\n" \
arch/x86/kernel/cpu/bugs.c +1 -1
@@ -68,7 +68,7 @@ void __init check_bugs(void)* identify_boot_cpu() initialized SMT support information, let the * core code know. */ -cpu_smt_check_topology_early (); +cpu_smt_check_topology ();if (!IS_ENABLED (CONFIG_SMP )) {pr_info ("CPU: " );
arch/x86/kernel/cpu/mcheck/mce.c +1 -0
@@ -773,6 +773,7 @@ static int mce_no_way_out(struct mce *m, char **msg, unsigned long *validp,quirk_no_way_out (i, m, regs);if (mce_severity (m, mca_cfg.tolerant, &tmp, true) >=MCE_PANIC_SEVERITY ) { + m->bank = i;mce_read_aux (m, i); *msg = tmp;return 1 ;
arch/x86/kvm/svm.c +7 -0
@@ -5319,6 +5319,13 @@ static bool svm_cpu_has_accelerated_tpr(void)static bool svm_has_emulated_msr (int index) { +switch (index) { +case MSR_IA32_MCG_EXT_CTL : +return false; +default : +break ; + } +return true; }
arch/x86/kvm/vmx.c +3 -1
@@ -27,6 +27,7 @@#include <linux/mm.h> #include <linux/highmem.h> #include <linux/sched.h> +#include <linux/sched/smt.h> #include <linux/moduleparam.h> #include <linux/mod_devicetable.h> #include <linux/trace_events.h>
@@ -7708,6 +7709,7 @@ static void free_nested(struct vcpu_vmx *vmx)if (!vmx->nested.vmxon)return ; +hrtimer_cancel (&vmx->nested.preemption_timer); vmx->nested.vmxon = false;free_vpid (vmx->nested.vpid02); vmx->nested.posted_intr_nv =-1 ;
@@ -10119,7 +10121,7 @@ static int vmx_vm_init(struct kvm *kvm)* Warn upon starting the first VM in a potentially * insecure environment. */ -if (cpu_smt_control ==CPU_SMT_ENABLED ) +if (sched_smt_active ())pr_warn_once (L1TF_MSG_SMT );if (l1tf_vmx_mitigation ==VMENTER_L1D_FLUSH_NEVER )pr_warn_once (L1TF_MSG_L1D );
arch/x86/kvm/x86.c +7 -0
@@ -4611,6 +4611,13 @@ int kvm_read_guest_virt(struct kvm_vcpu *vcpu, {u32 access = (kvm_x86_ops->get_cpl (vcpu) ==3 ) ?PFERR_USER_MASK :0 ; +/* +* FIXME: this should call handle_emulation_failure if X86EMUL_IO_NEEDED +* is returned, but our callers are not ready for that and they blindly +* call kvm_inject_page_fault. Ensure that they at least do not leak +* uninitialized kernel stack memory into cr2 and error code. +*/ +memset (exception,0 ,sizeof (*exception));return kvm_read_guest_virt_helper (addr, val, bytes, vcpu, access, exception); }
arch/x86/pci/broadcom_bus.c +2 -2
@@ -50,8 +50,8 @@ static void __init cnb20le_res(u8 bus, u8 slot, u8 func) word1 =read_pci_config_16 (bus, slot, func,0xc0 ); word2 =read_pci_config_16 (bus, slot, func,0xc2 );if (word1 != word2) { - res.start = (word1 <<16 ) |0x0000 ; - res.end = (word2 <<16 ) |0xffff ; + res.start = ((resource_size_t ) word1 <<16 ) |0x0000 ; + res.end = ((resource_size_t ) word2 <<16 ) |0xffff ; res.flags =IORESOURCE_MEM ;update_res (info, res.start, res.end, res.flags,0 ); }
crypto/Kconfig +2 -1
@@ -930,7 +930,8 @@ config CRYPTO_AES_TI 8 for decryption), this implementation only uses just two S-boxes of 256 bytes each, and attempts to eliminate data dependent latencies by prefetching the entire table into the cache at the start of each - block. + block. Interrupts are also disabled to avoid races where cachelines + are evicted when the CPU is interrupted to do something else. config CRYPTO_AES_586 tristate "AES cipher algorithms (i586)"
crypto/aes_ti.c +18 -0
@@ -269,6 +269,7 @@ static void aesti_encrypt(struct crypto_tfm *tfm, u8 *out, const u8 *in)const u32 *rkp = ctx->key_enc +4 ;int rounds =6 + ctx->key_length /4 ;u32 st0[4 ], st1[4 ]; +unsigned long flags;int round; st0[0 ] = ctx->key_enc[0 ] ^get_unaligned_le32 (in);
@@ -276,6 +277,12 @@ static void aesti_encrypt(struct crypto_tfm *tfm, u8 *out, const u8 *in) st0[2 ] = ctx->key_enc[2 ] ^get_unaligned_le32 (in +8 ); st0[3 ] = ctx->key_enc[3 ] ^get_unaligned_le32 (in +12 ); +/* +* Temporarily disable interrupts to avoid races where cachelines are +* evicted when the CPU is interrupted to do something else. +*/ +local_irq_save (flags); + st0[0 ] ^= __aesti_sbox[0 ] ^ __aesti_sbox[128 ]; st0[1 ] ^= __aesti_sbox[32 ] ^ __aesti_sbox[160 ]; st0[2 ] ^= __aesti_sbox[64 ] ^ __aesti_sbox[192 ];
@@ -300,6 +307,8 @@ static void aesti_encrypt(struct crypto_tfm *tfm, u8 *out, const u8 *in)put_unaligned_le32 (subshift (st1,1 ) ^ rkp[5 ], out +4 );put_unaligned_le32 (subshift (st1,2 ) ^ rkp[6 ], out +8 );put_unaligned_le32 (subshift (st1,3 ) ^ rkp[7 ], out +12 ); + +local_irq_restore (flags); }static void aesti_decrypt (struct crypto_tfm *tfm,u8 *out,const u8 *in)
@@ -308,6 +317,7 @@ static void aesti_decrypt(struct crypto_tfm *tfm, u8 *out, const u8 *in)const u32 *rkp = ctx->key_dec +4 ;int rounds =6 + ctx->key_length /4 ;u32 st0[4 ], st1[4 ]; +unsigned long flags;int round; st0[0 ] = ctx->key_dec[0 ] ^get_unaligned_le32 (in);
@@ -315,6 +325,12 @@ static void aesti_decrypt(struct crypto_tfm *tfm, u8 *out, const u8 *in) st0[2 ] = ctx->key_dec[2 ] ^get_unaligned_le32 (in +8 ); st0[3 ] = ctx->key_dec[3 ] ^get_unaligned_le32 (in +12 ); +/* +* Temporarily disable interrupts to avoid races where cachelines are +* evicted when the CPU is interrupted to do something else. +*/ +local_irq_save (flags); + st0[0 ] ^= __aesti_inv_sbox[0 ] ^ __aesti_inv_sbox[128 ]; st0[1 ] ^= __aesti_inv_sbox[32 ] ^ __aesti_inv_sbox[160 ]; st0[2 ] ^= __aesti_inv_sbox[64 ] ^ __aesti_inv_sbox[192 ];
@@ -339,6 +355,8 @@ static void aesti_decrypt(struct crypto_tfm *tfm, u8 *out, const u8 *in)put_unaligned_le32 (inv_subshift (st1,1 ) ^ rkp[5 ], out +4 );put_unaligned_le32 (inv_subshift (st1,2 ) ^ rkp[6 ], out +8 );put_unaligned_le32 (inv_subshift (st1,3 ) ^ rkp[7 ], out +12 ); + +local_irq_restore (flags); }static struct crypto_alg aes_alg = {
drivers/acpi/apei/ghes.c +2 -0
@@ -675,6 +675,8 @@ static void __ghes_panic(struct ghes *ghes) {__ghes_print_estatus (KERN_EMERG , ghes->generic, ghes->estatus); +ghes_clear_estatus (ghes); +/* reboot to log the error! */ if (!panic_timeout) panic_timeout = ghes_panic_timeout;
drivers/acpi/spcr.c +11 -0
@@ -148,6 +148,13 @@ int __init parse_spcr(bool earlycon) }switch (table->baud_rate) { +case 0 : +/* +* SPCR 1.04 defines 0 as a preconfigured state of UART. +* Assume firmware or bootloader configures console correctly. +*/ + baud_rate =0 ; +break ;case 3 : baud_rate =9600 ;break ;
@@ -196,6 +203,10 @@ int __init parse_spcr(bool earlycon)* UART so don't attempt to change to the baud rate state * in the table because driver cannot calculate the dividers */ + baud_rate =0 ; + } + +if (!baud_rate) {snprintf (opts,sizeof (opts),"%s,%s,0x%llx" , uart, iotype, table->serial_port.address); }else {
drivers/ata/sata_rcar.c +3 -1
@@ -880,7 +880,9 @@ static int sata_rcar_probe(struct platform_device *pdev)int ret =0 ; irq =platform_get_irq (pdev,0 ); -if (irq <=0 ) +if (irq <0 ) +return irq; +if (!irq)return -EINVAL ; priv = devm_kzalloc(&pdev->dev, sizeof(struct sata_rcar_priv),
drivers/base/bus.c +8 -4
@@ -616,8 +616,10 @@ static void remove_probe_files(struct bus_type *bus)static ssize_t uevent_store (struct device_driver *drv,const char *buf,size_t count) { -kobject_synth_uevent (&drv->p->kobj, buf, count); -return count; +int rc; + + rc =kobject_synth_uevent (&drv->p->kobj, buf, count); +return rc ? rc : count; }static DRIVER_ATTR_WO (uevent);
@@ -833,8 +835,10 @@ static void klist_devices_put(struct klist_node *n)static ssize_t bus_uevent_store (struct bus_type *bus,const char *buf,size_t count) { -kobject_synth_uevent (&bus->p->subsys.kobj, buf, count); -return count; +int rc; + + rc =kobject_synth_uevent (&bus->p->subsys.kobj, buf, count); +return rc ? rc : count; } static BUS_ATTR(uevent, S_IWUSR, NULL, bus_uevent_store);
drivers/base/core.c +7 -1
@@ -991,8 +991,14 @@ static ssize_t uevent_show(struct device *dev, struct device_attribute *attr,static ssize_t uevent_store (struct device *dev,struct device_attribute *attr,const char *buf,size_t count) { -if (kobject_synth_uevent (&dev->kobj, buf, count)) +int rc; + + rc =kobject_synth_uevent (&dev->kobj, buf, count); + +if (rc) {dev_err (dev,"uevent: failed to send synthetic uevent\n" ); +return rc; + }return count; }
drivers/base/dd.c +3 -3
@@ -813,9 +813,6 @@ static void __device_release_driver(struct device *dev, struct device *parent) drv = dev->driver;if (drv) { -if (driver_allows_async_probing (drv)) -async_synchronize_full (); -while (device_links_busy (dev)) {device_unlock (dev);if (parent)
@@ -920,6 +917,9 @@ void driver_detach(struct device_driver *drv)struct device_private *dev_prv;struct device *dev; +if (driver_allows_async_probing (drv)) +async_synchronize_full (); +for (;;) {spin_lock (&drv->p->klist_devices.k_lock);if (list_empty (&drv->p->klist_devices.k_list)) {
drivers/base/power/opp/core.c +7 -4
@@ -192,12 +192,12 @@ unsigned long dev_pm_opp_get_max_volt_latency(struct device *dev)if (IS_ERR (opp_table))return 0 ; - count = opp_table->regulator_count; -/* Regulator may not be required for the device */ -if (!count) +if (!opp_table->regulators) goto put_opp_table; + count = opp_table->regulator_count; + uV =kmalloc_array (count,sizeof (*uV),GFP_KERNEL );if (!uV) goto put_opp_table;
@@ -921,6 +921,9 @@ static bool _opp_supported_by_regulators(struct dev_pm_opp *opp,struct regulator *reg;int i; +if (!opp_table->regulators) +return true; +for (i =0 ; i < opp_table->regulator_count; i++) { reg = opp_table->regulators[i];
@@ -1226,7 +1229,7 @@ static int _allocate_set_opp_data(struct opp_table *opp_table)struct dev_pm_set_opp_data *data;int len, count = opp_table->regulator_count; -if (WARN_ON (!count)) +if (WARN_ON (!opp_table->regulators))return -EINVAL ;/* space for set_opp_data */
drivers/block/drbd/drbd_nl.c +8 -7
@@ -668,14 +668,15 @@ drbd_set_role(struct drbd_device *const device, enum drbd_role new_role, int forif (rv ==SS_TWO_PRIMARIES ) {/* Maybe the peer is detected as dead very soon... retry at most once more in this case. */ -int timeo; -rcu_read_lock (); - nc =rcu_dereference (connection->net_conf); - timeo = nc ? (nc->ping_timeo +1 ) *HZ /10 :1 ; -rcu_read_unlock (); -schedule_timeout_interruptible (timeo); -if (try < max_tries) +if (try < max_tries) { +int timeo; try = max_tries -1 ; +rcu_read_lock (); + nc =rcu_dereference (connection->net_conf); + timeo = nc ? (nc->ping_timeo +1 ) *HZ /10 :1 ; +rcu_read_unlock (); +schedule_timeout_interruptible (timeo); + }continue ; }if (rv <SS_SUCCESS ) {
drivers/block/drbd/drbd_receiver.c +7 -6
@@ -3361,7 +3361,7 @@ static enum drbd_conns drbd_sync_handshake(struct drbd_peer_device *peer_device,enum drbd_conns rv =C_MASK ;enum drbd_disk_state mydisk;struct net_conf *nc; -int hg, rule_nr, rr_conflict, tentative; +int hg, rule_nr, rr_conflict, tentative, always_asbp; mydisk = device->state.disk;if (mydisk ==D_NEGOTIATING )
@@ -3412,8 +3412,12 @@ static enum drbd_conns drbd_sync_handshake(struct drbd_peer_device *peer_device,rcu_read_lock (); nc =rcu_dereference (peer_device->connection->net_conf); + always_asbp = nc->always_asbp; + rr_conflict = nc->rr_conflict; + tentative = nc->tentative; +rcu_read_unlock (); -if (hg ==100 || (hg ==-100 && nc->always_asbp)) { +if (hg ==100 || (hg ==-100 && always_asbp)) {int pcount = (device->state.role ==R_PRIMARY ) + (peer_role ==R_PRIMARY );int forced = (hg ==-100 );
@@ -3452,9 +3456,6 @@ static enum drbd_conns drbd_sync_handshake(struct drbd_peer_device *peer_device,"Sync from %s node\n" , (hg < 0) ? "peer" : "this"); } - rr_conflict = nc->rr_conflict; - tentative = nc->tentative; -rcu_read_unlock ();if (hg ==-100 ) {/* FIXME this log message is not correct if we end up here
@@ -4138,7 +4139,7 @@ static int receive_uuids(struct drbd_connection *connection, struct packet_infokfree (device->p_uuid); device->p_uuid = p_uuid; -if (device->state.conn <C_CONNECTED && +if ((device->state.conn <C_CONNECTED || device->state.pdsk ==D_DISKLESS ) && device->state.disk <D_INCONSISTENT && device->state.role ==R_PRIMARY && (device->ed_uuid & ~((u64 )1 )) != (p_uuid[UI_CURRENT ] & ~((u64 )1 ))) {
drivers/block/sunvdc.c +5 -0
@@ -41,6 +41,8 @@ MODULE_VERSION(DRV_MODULE_VERSION);#define WAITING_FOR_GEN_CMD 0x04#define WAITING_FOR_ANY -1 +#define VDC_MAX_RETRIES 10 +static struct workqueue_struct *sunvdc_wq;struct vdc_req_entry {
@@ -427,6 +429,7 @@ static int __vdc_tx_trigger(struct vdc_port *port) .end_idx = dr->prod, };int err, delay; +int retries =0 ; hdr.seq = dr->snd_nxt; delay =1 ;
@@ -439,6 +442,8 @@ static int __vdc_tx_trigger(struct vdc_port *port)udelay (delay);if ((delay <<=1 ) >128 ) delay =128 ; +if (retries++ >VDC_MAX_RETRIES ) +break ; }while (err == -EAGAIN );if (err == -ENOTCONN )
drivers/block/swim3.c +5 -1
@@ -1027,7 +1027,11 @@ static void floppy_release(struct gendisk *disk, fmode_t mode)struct swim3 __iomem *sw = fs->swim3;mutex_lock (&swim3_mutex); -if (fs->ref_count >0 && --fs->ref_count ==0 ) { +if (fs->ref_count >0 ) + --fs->ref_count; +else if (fs->ref_count ==-1 ) + fs->ref_count =0 ; +if (fs->ref_count ==0 ) {swim3_action (fs,MOTOR_OFF );out_8 (&sw->control_bic,0xff );swim3_select (fs,RELAX );
drivers/cdrom/gdrom.c +1 -0
@@ -889,6 +889,7 @@ static void __exit exit_gdrom(void)platform_device_unregister (pd);platform_driver_unregister (&gdrom_driver);kfree (gd.toc); +kfree (gd.cd_info); }module_init (init_gdrom);
drivers/clk/imgtec/clk-boston.c +8 -3
@@ -73,27 +73,32 @@ static void __init clk_boston_setup(struct device_node *np) hw =clk_hw_register_fixed_rate (NULL ,"input" ,NULL ,0 , in_freq);if (IS_ERR (hw)) {pr_err ("failed to register input clock: %ld\n" ,PTR_ERR (hw)); -return ; + goto error; } onecell->hws[BOSTON_CLK_INPUT ] = hw; hw =clk_hw_register_fixed_rate (NULL ,"sys" ,"input" ,0 , sys_freq);if (IS_ERR (hw)) {pr_err ("failed to register sys clock: %ld\n" ,PTR_ERR (hw)); -return ; + goto error; } onecell->hws[BOSTON_CLK_SYS ] = hw; hw =clk_hw_register_fixed_rate (NULL ,"cpu" ,"input" ,0 , cpu_freq);if (IS_ERR (hw)) {pr_err ("failed to register cpu clock: %ld\n" ,PTR_ERR (hw)); -return ; + goto error; } onecell->hws[BOSTON_CLK_CPU ] = hw; err =of_clk_add_hw_provider (np, of_clk_hw_onecell_get, onecell);if (err)pr_err ("failed to add DT provider: %d\n" , err); + +return ; + +error: +kfree (onecell); }/*
drivers/clk/imx/clk-imx6sl.c +6 -0
@@ -17,6 +17,8 @@#include "clk.h" +#define CCDR 0x4 +#define BM_CCM_CCDR_MMDC_CH0_MASK (1 << 17)#define CCSR 0xc#define BM_CCSR_PLL1_SW_CLK_SEL (1 << 2)#define CACRR 0x10
@@ -414,6 +416,10 @@ static void __init imx6sl_clocks_init(struct device_node *ccm_node) clks[IMX6SL_CLK_USDHC3 ] =imx_clk_gate2 ("usdhc3" ,"usdhc3_podf" , base +0x80 ,6 ); clks[IMX6SL_CLK_USDHC4 ] =imx_clk_gate2 ("usdhc4" ,"usdhc4_podf" , base +0x80 ,8 ); +/* Ensure the MMDC CH0 handshake is bypassed */ +writel_relaxed (readl_relaxed (base +CCDR ) | +BM_CCM_CCDR_MMDC_CH0_MASK , base +CCDR ); +imx_check_clocks (clks,ARRAY_SIZE (clks)); clk_data.clks = clks;
drivers/clk/sunxi-ng/ccu-sun8i-a33.c +3 -3
@@ -366,10 +366,10 @@ static SUNXI_CCU_MP_WITH_MUX_GATE(spi1_clk, "spi1", mod0_default_parents, 0x0a4,static const char *const i2s_parents[] = {"pll-audio-8x" ,"pll-audio-4x" ,"pll-audio-2x" ,"pll-audio" }; static SUNXI_CCU_MUX_WITH_GATE(i2s0_clk, "i2s0", i2s_parents, - 0x0b0, 16, 2, BIT(31), 0); + 0x0b0, 16, 2, BIT(31), CLK_SET_RATE_PARENT); static SUNXI_CCU_MUX_WITH_GATE(i2s1_clk, "i2s1", i2s_parents, - 0x0b4, 16, 2, BIT(31), 0); + 0x0b4, 16, 2, BIT(31), CLK_SET_RATE_PARENT);/* TODO: the parent for most of the USB clocks is not known */ static SUNXI_CCU_GATE(usb_phy0_clk, "usb-phy0", "osc24M",
@@ -446,7 +446,7 @@ static SUNXI_CCU_M_WITH_GATE(ve_clk, "ve", "pll-ve", static SUNXI_CCU_GATE(ac_dig_clk, "ac-dig", "pll-audio", 0x140, BIT(31), CLK_SET_RATE_PARENT); static SUNXI_CCU_GATE(ac_dig_4x_clk, "ac-dig-4x", "pll-audio-4x", - 0x140, BIT(30), 0); + 0x140, BIT(30), CLK_SET_RATE_PARENT); static SUNXI_CCU_GATE(avs_clk, "avs", "osc24M", 0x144, BIT(31), 0);
drivers/cpuidle/cpuidle-big_little.c +6 -1
@@ -167,6 +167,7 @@ static int __init bl_idle_init(void) {int ret;struct device_node *root =of_find_node_by_path ("/" ); +const struct of_device_id *match_id;if (!root)return -ENODEV ;
@@ -174,7 +175,11 @@ static int __init bl_idle_init(void)/* * Initialize the driver just for a compliant set of machines */ -if (!of_match_node (compatible_machine_match, root)) + match_id =of_match_node (compatible_machine_match, root); + +of_node_put (root); + +if (!match_id)return -ENODEV ;if (!mcpm_is_available ())
drivers/crypto/ux500/cryp/cryp_core.c +2 -2
@@ -555,7 +555,7 @@ static int cryp_set_dma_transfer(struct cryp_ctx *ctx, desc =dmaengine_prep_slave_sg (channel, ctx->device->dma.sg_src, ctx->device->dma.sg_src_len, - direction,DMA_CTRL_ACK ); +DMA_MEM_TO_DEV ,DMA_CTRL_ACK );break ;case DMA_FROM_DEVICE :
@@ -579,7 +579,7 @@ static int cryp_set_dma_transfer(struct cryp_ctx *ctx, desc =dmaengine_prep_slave_sg (channel, ctx->device->dma.sg_dst, ctx->device->dma.sg_dst_len, - direction, +DMA_DEV_TO_MEM ,DMA_CTRL_ACK |DMA_PREP_INTERRUPT );
drivers/crypto/ux500/hash/hash_core.c +1 -1
@@ -165,7 +165,7 @@ static int hash_set_dma_transfer(struct hash_ctx *ctx, struct scatterlist *sg, __func__); desc =dmaengine_prep_slave_sg (channel, ctx->device->dma.sg, ctx->device->dma.sg_len, - direction,DMA_CTRL_ACK |DMA_PREP_INTERRUPT ); +DMA_MEM_TO_DEV ,DMA_CTRL_ACK |DMA_PREP_INTERRUPT );if (!desc) {dev_err (ctx->device->dev,"%s: dmaengine_prep_slave_sg() failed!\n" , __func__);
drivers/dma/bcm2835-dma.c +25 -45
116 lines not on this page · raw message
drivers/dma/imx-dma.c +4 -4
@@ -623,7 +623,7 @@ static void imxdma_tasklet(unsigned long data) {struct imxdma_channel *imxdmac = (void *)data;struct imxdma_engine *imxdma = imxdmac->imxdma; -struct imxdma_desc *desc; +struct imxdma_desc *desc, *next_desc;unsigned long flags;spin_lock_irqsave (&imxdma->lock, flags);
@@ -653,10 +653,10 @@ static void imxdma_tasklet(unsigned long data)list_move_tail (imxdmac->ld_active.next, &imxdmac->ld_free);if (!list_empty (&imxdmac->ld_queue)) { - desc = list_first_entry(&imxdmac->ld_queue, struct imxdma_desc, - node); + next_desc =list_first_entry (&imxdmac->ld_queue, + struct imxdma_desc, node);list_move_tail (imxdmac->ld_queue.next, &imxdmac->ld_active); -if (imxdma_xfer_desc (desc) <0 ) +if (imxdma_xfer_desc (next_desc) <0 )dev_warn (imxdma->dev,"%s: channel: %d couldn't xfer desc\n" , __func__, imxdmac->channel); }
drivers/dma/xilinx/zynqmp_dma.c +1 -1
@@ -159,7 +159,7 @@ struct zynqmp_dma_desc_ll {u32 ctrl;u64 nxtdscraddr;u64 rsvd; -};__aligned(64) +};/** * struct zynqmp_dma_desc_sw - Per Transaction structure
drivers/firmware/efi/vars.c +78 -21
227 lines not on this page · raw message
drivers/fpga/altera-cvp.c +9 -0
@@ -404,6 +404,7 @@ static int altera_cvp_probe(struct pci_dev *pdev, {struct altera_cvp_conf *conf;u16 cmd, val; +u32 regval;int ret;/*
@@ -417,6 +418,14 @@ static int altera_cvp_probe(struct pci_dev *pdev,return -ENODEV ; } +pci_read_config_dword (pdev,VSE_CVP_STATUS , ®val); +if (!(regval &VSE_CVP_STATUS_CVP_EN )) { +dev_err (&pdev->dev, +"CVP is disabled for this device: CVP_STATUS Reg 0x%x\n" , + regval); +return -ENODEV ; + } + conf =devm_kzalloc (&pdev->dev,sizeof (*conf),GFP_KERNEL );if (!conf)return -ENOMEM ;
drivers/gpu/drm/drm_atomic_helper.c +6 -2
@@ -2899,7 +2899,7 @@ EXPORT_SYMBOL(drm_atomic_helper_suspend);int drm_atomic_helper_commit_duplicated_state (struct drm_atomic_state *state,struct drm_modeset_acquire_ctx *ctx) { -int i; +int i, ret;struct drm_plane *plane;struct drm_plane_state *new_plane_state;struct drm_connector *connector;
@@ -2918,7 +2918,11 @@ int drm_atomic_helper_commit_duplicated_state(struct drm_atomic_state *state,for_each_new_connector_in_state (state, connector, new_conn_state, i) state->connectors[i].old_state = connector->state; -return drm_atomic_commit (state); + ret =drm_atomic_commit (state); + + state->acquire_ctx =NULL ; + +return ret; }EXPORT_SYMBOL (drm_atomic_helper_commit_duplicated_state);
drivers/gpu/drm/drm_bufs.c +3 -0
@@ -36,6 +36,8 @@#include <drm/drmP.h> #include "drm_legacy.h" +#include <linux/nospec.h> +static struct drm_map_list *drm_find_matching_map (struct drm_device *dev,struct drm_local_map *map) {
@@ -1417,6 +1419,7 @@ int drm_legacy_freebufs(struct drm_device *dev, void *data, idx, dma->buf_count - 1);return -EINVAL ; } + idx =array_index_nospec (idx, dma->buf_count); buf = dma->buflist[idx];if (buf->file_priv != file_priv) { DRM_ERROR("Process %d freeing buffer not owned\n",
drivers/gpu/drm/rockchip/cdn-dp-reg.c +1 -1
@@ -147,7 +147,7 @@ static int cdn_dp_mailbox_validate_receive(struct cdn_dp_device *dp, }static int cdn_dp_mailbox_read_receive (struct cdn_dp_device *dp, -u8 *buff,u8 buff_size) +u8 *buff,u16 buff_size) {u32 i;int ret;
drivers/gpu/drm/vc4/vc4_plane.c +7 -5
@@ -347,12 +347,14 @@ static int vc4_plane_setup_clipping_and_scaling(struct drm_plane_state *state)vc4_get_scaling_mode (vc4_state->src_h[1 ], vc4_state->crtc_h); -/* YUV conversion requires that horizontal scaling be enabled, -* even on a plane that's otherwise 1:1. Looks like only PPF -* works in that case, so let's pick that one. +/* YUV conversion requires that horizontal scaling be enabled +* on the UV plane even if vc4_get_scaling_mode() returned +* VC4_SCALING_NONE (which can happen when the down-scaling +* ratio is 0.5). Let's force it to VC4_SCALING_PPF in this +* case. */ -if (vc4_state->is_unity) - vc4_state->x_scaling[0 ] =VC4_SCALING_PPF ; +if (vc4_state->x_scaling[1 ] ==VC4_SCALING_NONE ) + vc4_state->x_scaling[1 ] =VC4_SCALING_PPF ; }else { vc4_state->is_yuv = false; vc4_state->x_scaling[1 ] =VC4_SCALING_NONE ;
drivers/gpu/drm/vgem/vgem_drv.c +8 -8
@@ -472,31 +472,31 @@ static int __init vgem_init(void)if (!vgem_device)return -ENOMEM ; - ret =drm_dev_init (&vgem_device->drm, &vgem_driver,NULL ); -if (ret) - goto out_free; - vgem_device->platform =platform_device_register_simple ("vgem" ,-1 ,NULL ,0 );if (IS_ERR (vgem_device->platform)) { ret =PTR_ERR (vgem_device->platform); - goto out_fini; + goto out_free; }dma_coerce_mask_and_coherent (&vgem_device->platform->dev,DMA_BIT_MASK (64 )); + ret =drm_dev_init (&vgem_device->drm, &vgem_driver, + &vgem_device->platform->dev); +if (ret) + goto out_unregister;/* Final step: expose the device/driver to userspace */ ret =drm_dev_register (&vgem_device->drm,0 );if (ret) - goto out_unregister; + goto out_fini;return 0 ; -out_unregister: -platform_device_unregister (vgem_device->platform); out_fini:drm_dev_fini (&vgem_device->drm); +out_unregister: +platform_device_unregister (vgem_device->platform); out_free:kfree (vgem_device);return ret;
drivers/gpu/ipu-v3/ipu-image-convert.c +7 -3
@@ -1518,7 +1518,7 @@ int ipu_image_convert_queue(struct ipu_image_convert_run *run)EXPORT_SYMBOL_GPL (ipu_image_convert_queue);/* Abort any active or pending conversions for this context */ -void ipu_image_convert_abort (struct ipu_image_convert_ctx *ctx) +static void __ipu_image_convert_abort (struct ipu_image_convert_ctx *ctx) {struct ipu_image_convert_chan *chan = ctx->chan;struct ipu_image_convert_priv *priv = chan->priv;
@@ -1545,7 +1545,7 @@ void ipu_image_convert_abort(struct ipu_image_convert_ctx *ctx) need_abort = (run_count || active_run); - ctx->aborting = need_abort; + ctx->aborting = true;spin_unlock_irqrestore (&chan->irqlock, flags);
@@ -1566,7 +1566,11 @@ void ipu_image_convert_abort(struct ipu_image_convert_ctx *ctx)dev_warn (priv->ipu->dev,"%s: timeout\n" , __func__);force_abort (ctx); } +} +void ipu_image_convert_abort (struct ipu_image_convert_ctx *ctx) +{ +__ipu_image_convert_abort (ctx); ctx->aborting = false; }EXPORT_SYMBOL_GPL (ipu_image_convert_abort);
@@ -1580,7 +1584,7 @@ void ipu_image_convert_unprepare(struct ipu_image_convert_ctx *ctx)bool put_res;/* make sure no runs are hanging around */ -ipu_image_convert_abort (ctx); +__ipu_image_convert_abort (ctx);dev_dbg (priv->ipu->dev,"%s: task %u: removing ctx %p\n" , __func__, chan->ic_task, ctx);
drivers/hid/hid-lenovo.c +8 -2
@@ -743,7 +743,9 @@ static int lenovo_probe_tpkbd(struct hid_device *hdev) data_pointer->led_mute.brightness_get = lenovo_led_brightness_get_tpkbd; data_pointer->led_mute.brightness_set = lenovo_led_brightness_set_tpkbd; data_pointer->led_mute.dev = dev; -led_classdev_register (dev, &data_pointer->led_mute); + ret =led_classdev_register (dev, &data_pointer->led_mute); +if (ret <0 ) + goto err; data_pointer->led_micmute.name = name_micmute; data_pointer->led_micmute.brightness_get =
@@ -751,7 +753,11 @@ static int lenovo_probe_tpkbd(struct hid_device *hdev) data_pointer->led_micmute.brightness_set = lenovo_led_brightness_set_tpkbd; data_pointer->led_micmute.dev = dev; -led_classdev_register (dev, &data_pointer->led_micmute); + ret =led_classdev_register (dev, &data_pointer->led_micmute); +if (ret <0 ) { +led_classdev_unregister (&data_pointer->led_mute); + goto err; + }lenovo_features_set_tpkbd (hdev);
drivers/hwmon/lm80.c +19 -7
@@ -360,9 +360,11 @@ static ssize_t set_fan_div(struct device *dev, struct device_attribute *attr,struct i2c_client *client = data->client;unsigned long min, val;u8 reg; -int err =kstrtoul (buf,10 , &val); -if (err <0 ) -return err; +int rv; + + rv =kstrtoul (buf,10 , &val); +if (rv <0 ) +return rv;/* Save fan_min */ mutex_lock (&data->update_lock);
@@ -390,8 +392,11 @@ static ssize_t set_fan_div(struct device *dev, struct device_attribute *attr,return -EINVAL ; } - reg = (lm80_read_value (client,LM80_REG_FANDIV ) & - ~(3 << (2 * (nr +1 )))) | (data->fan_div[nr] << (2 * (nr +1 ))); + rv =lm80_read_value (client,LM80_REG_FANDIV ); +if (rv <0 ) +return rv; + reg = (rv & ~(3 << (2 * (nr +1 )))) + | (data->fan_div[nr] << (2 * (nr +1 )));lm80_write_value (client,LM80_REG_FANDIV , reg);/* Restore fan_min */
@@ -623,6 +628,7 @@ static int lm80_probe(struct i2c_client *client,struct device *dev = &client->dev;struct device *hwmon_dev;struct lm80_data *data; +int rv; data =devm_kzalloc (dev,sizeof (struct lm80_data ),GFP_KERNEL );if (!data)
@@ -635,8 +641,14 @@ static int lm80_probe(struct i2c_client *client,lm80_init_client (client);/* A few vars need to be filled upon startup */ - data->fan[f_min][0 ] =lm80_read_value (client,LM80_REG_FAN_MIN (1 )); - data->fan[f_min][1 ] =lm80_read_value (client,LM80_REG_FAN_MIN (2 )); + rv =lm80_read_value (client,LM80_REG_FAN_MIN (1 )); +if (rv <0 ) +return rv; + data->fan[f_min][0 ] = rv; + rv =lm80_read_value (client,LM80_REG_FAN_MIN (2 )); +if (rv <0 ) +return rv; + data->fan[f_min][1 ] = rv; hwmon_dev =devm_hwmon_device_register_with_groups (dev, client->name, data, lm80_groups);
drivers/i2c/busses/i2c-axxia.c +16 -16
@@ -296,22 +296,7 @@ static irqreturn_t axxia_i2c_isr(int irq, void *_dev)i2c_int_disable (idev,MST_STATUS_TFL ); } -if (status &MST_STATUS_SCC ) { -/* Stop completed */ -i2c_int_disable (idev, ~MST_STATUS_TSS ); -complete (&idev->msg_complete); - }else if (status &MST_STATUS_SNS ) { -/* Transfer done */ -i2c_int_disable (idev, ~MST_STATUS_TSS ); -if (i2c_m_rd (idev->msg) && idev->msg_xfrd < idev->msg->len) -axxia_i2c_empty_rx_fifo (idev); -complete (&idev->msg_complete); - }else if (status &MST_STATUS_TSS ) { -/* Transfer timeout */ - idev->msg_err = -ETIMEDOUT ; -i2c_int_disable (idev, ~MST_STATUS_TSS ); -complete (&idev->msg_complete); - }else if (unlikely (status &MST_STATUS_ERR )) { +if (unlikely (status &MST_STATUS_ERR )) {/* Transfer error */ i2c_int_disable (idev, ~0 );if (status &MST_STATUS_AL )
@@ -328,6 +313,21 @@ static irqreturn_t axxia_i2c_isr(int irq, void *_dev)readl (idev->base +MST_TX_BYTES_XFRD ), readl(idev->base + MST_TX_XFER));complete (&idev->msg_complete); + }else if (status &MST_STATUS_SCC ) { +/* Stop completed */ +i2c_int_disable (idev, ~MST_STATUS_TSS ); +complete (&idev->msg_complete); + }else if (status &MST_STATUS_SNS ) { +/* Transfer done */ +i2c_int_disable (idev, ~MST_STATUS_TSS ); +if (i2c_m_rd (idev->msg) && idev->msg_xfrd < idev->msg->len) +axxia_i2c_empty_rx_fifo (idev); +complete (&idev->msg_complete); + }else if (status &MST_STATUS_TSS ) { +/* Transfer timeout */ + idev->msg_err = -ETIMEDOUT ; +i2c_int_disable (idev, ~MST_STATUS_TSS ); +complete (&idev->msg_complete); } out:
drivers/i2c/busses/i2c-sh_mobile.c +1 -0
@@ -836,6 +836,7 @@ static const struct of_device_id sh_mobile_i2c_dt_ids[] = { { .compatible = "renesas,rcar-gen2-iic", .data = &fast_clock_dt_config }, { .compatible = "renesas,iic-r8a7795", .data = &fast_clock_dt_config }, { .compatible = "renesas,rcar-gen3-iic", .data = &fast_clock_dt_config }, + { .compatible = "renesas,iic-r8a77990", .data = &fast_clock_dt_config }, { .compatible = "renesas,iic-sh73a0", .data = &fast_clock_dt_config }, { .compatible = "renesas,rmobile-iic", .data = &default_dt_config }, {},
drivers/iio/accel/kxcjk-1013.c +1 -0
@@ -1393,6 +1393,7 @@ static const struct acpi_device_id kx_acpi_match[] = { {"KXCJ1008", KXCJ91008}, {"KXCJ9000", KXCJ91008}, {"KIOX000A", KXCJ91008}, + {"KIOX010A", KXCJ91008}, /* KXCJ91008 inside the display of a 2-in-1 */ {"KXTJ1009", KXTJ21009}, {"SMO8500", KXCJ91008}, { },
drivers/iio/adc/meson_saradc.c +10 -4
@@ -583,8 +583,11 @@ static int meson_sar_adc_clk_init(struct iio_dev *indio_dev,struct clk_init_data init;const char *clk_parents[1 ]; - init.name =devm_kasprintf (&indio_dev->dev,GFP_KERNEL ,"%pOF#adc_div" , - indio_dev->dev.of_node); + init.name =devm_kasprintf (&indio_dev->dev,GFP_KERNEL ,"%s#adc_div" , +dev_name (indio_dev->dev.parent)); +if (!init.name) +return -ENOMEM ; + init.flags =0 ; init.ops = &clk_divider_ops; clk_parents[0 ] =__clk_get_name (priv->clkin);
@@ -602,8 +605,11 @@ static int meson_sar_adc_clk_init(struct iio_dev *indio_dev,if (WARN_ON (IS_ERR (priv->adc_div_clk)))return PTR_ERR (priv->adc_div_clk); - init.name =devm_kasprintf (&indio_dev->dev,GFP_KERNEL ,"%pOF#adc_en" , - indio_dev->dev.of_node); + init.name =devm_kasprintf (&indio_dev->dev,GFP_KERNEL ,"%s#adc_en" , +dev_name (indio_dev->dev.parent)); +if (!init.name) +return -ENOMEM ; + init.flags =CLK_SET_RATE_PARENT ; init.ops = &clk_gate_ops; clk_parents[0 ] =__clk_get_name (priv->adc_div_clk);
drivers/infiniband/hw/hfi1/rc.c +2 -0
@@ -1162,6 +1162,7 @@ void hfi1_rc_send_complete(struct rvt_qp *qp, struct hfi1_opa_header *opah)if (cmp_psn (wqe->lpsn, qp->s_sending_psn) >=0 &&cmp_psn (qp->s_sending_psn, qp->s_sending_hpsn) <=0 )break ; +rvt_qp_wqe_unreserve (qp, wqe); s_last = qp->s_last;trace_hfi1_qp_send_completion (qp, wqe, s_last);if (++s_last >= qp->s_size)
@@ -1214,6 +1215,7 @@ static struct rvt_swqe *do_rc_completion(struct rvt_qp *qp,u32 s_last;rvt_put_swqe (wqe); +rvt_qp_wqe_unreserve (qp, wqe); s_last = qp->s_last;trace_hfi1_qp_send_completion (qp, wqe, s_last);if (++s_last >= qp->s_size)
drivers/infiniband/hw/hfi1/ruc.c +6 -1
@@ -440,6 +440,8 @@ static void ruc_loopback(struct rvt_qp *sqp) goto op_err;if (!ret) goto rnr_nak; +if (wqe->length > qp->r_len) + goto inv_err;break ;case IB_WR_RDMA_WRITE_WITH_IMM :
@@ -607,7 +609,10 @@ static void ruc_loopback(struct rvt_qp *sqp) goto err; inv_err: - send_status =IB_WC_REM_INV_REQ_ERR ; + send_status = + sqp->ibqp.qp_type ==IB_QPT_RC ? +IB_WC_REM_INV_REQ_ERR : +IB_WC_SUCCESS ; wc.status =IB_WC_LOC_QP_OP_ERR ; goto err;
drivers/infiniband/hw/qib/qib_ruc.c +6 -1
@@ -425,6 +425,8 @@ static void qib_ruc_loopback(struct rvt_qp *sqp) goto op_err;if (!ret) goto rnr_nak; +if (wqe->length > qp->r_len) + goto inv_err;break ;case IB_WR_RDMA_WRITE_WITH_IMM :
@@ -585,7 +587,10 @@ static void qib_ruc_loopback(struct rvt_qp *sqp) goto err; inv_err: - send_status =IB_WC_REM_INV_REQ_ERR ; + send_status = + sqp->ibqp.qp_type ==IB_QPT_RC ? +IB_WC_REM_INV_REQ_ERR : +IB_WC_SUCCESS ; wc.status =IB_WC_LOC_QP_OP_ERR ; goto err;
drivers/iommu/amd_iommu.c +8 -1
@@ -442,7 +442,14 @@ static int iommu_init_device(struct device *dev) dev_data->alias =get_alias (dev); -if (dev_is_pci (dev) &&pci_iommuv2_capable (to_pci_dev (dev))) { +/* +* By default we use passthrough mode for IOMMUv2 capable device. +* But if amd_iommu=force_isolation is set (e.g. to debug DMA to +* invalid address), we ignore the capability for the device so +* it'll be forced to go into translation mode. +*/ +if ((iommu_pass_through || !amd_iommu_force_isolation) && +dev_is_pci (dev) &&pci_iommuv2_capable (to_pci_dev (dev))) {struct amd_iommu *iommu; iommu = amd_iommu_rlookup_table[dev_data->devid];
drivers/iommu/arm-smmu-v3.c +7 -1
@@ -730,7 +730,13 @@ static void queue_inc_cons(struct arm_smmu_queue *q)u32 cons = (Q_WRP (q, q->cons) |Q_IDX (q, q->cons)) +1 ; q->cons =Q_OVF (q, q->cons) |Q_WRP (q, cons) |Q_IDX (q, cons); -writel (q->cons, q->cons_reg); + +/* +* Ensure that all CPU accesses (reads and writes) to the queue +* are complete before we update the cons pointer. +*/ +mb (); +writel_relaxed (q->cons, q->cons_reg); }static int queue_sync_prod (struct arm_smmu_queue *q)
drivers/iommu/arm-smmu.c +3 -0
@@ -117,6 +117,7 @@ enum arm_smmu_implementation {GENERIC_SMMU ,ARM_MMU500 ,CAVIUM_SMMUV2 , + QCOM_SMMUV2, };/* Until ACPICA headers cover IORT rev. C */
@@ -1910,6 +1911,7 @@ ARM_SMMU_MATCH_DATA(smmu_generic_v2, ARM_SMMU_V2, GENERIC_SMMU);ARM_SMMU_MATCH_DATA (arm_mmu401,ARM_SMMU_V1_64K ,GENERIC_SMMU );ARM_SMMU_MATCH_DATA (arm_mmu500,ARM_SMMU_V2 ,ARM_MMU500 );ARM_SMMU_MATCH_DATA (cavium_smmuv2,ARM_SMMU_V2 ,CAVIUM_SMMUV2 ); +ARM_SMMU_MATCH_DATA (qcom_smmuv2,ARM_SMMU_V2 ,QCOM_SMMUV2 );static const struct of_device_id arm_smmu_of_match[] = { { .compatible ="arm,smmu-v1" , .data = &smmu_generic_v1 },
@@ -1918,6 +1920,7 @@ static const struct of_device_id arm_smmu_of_match[] = { { .compatible = "arm,mmu-401", .data = &arm_mmu401 }, { .compatible = "arm,mmu-500", .data = &arm_mmu500 }, { .compatible = "cavium,smmu-v2", .data = &cavium_smmuv2 }, + { .compatible = "qcom,smmu-v2", .data = &qcom_smmuv2 }, { }, };MODULE_DEVICE_TABLE (of, arm_smmu_of_match);
drivers/irqchip/irq-gic-v3-its.c +27 -5
@@ -87,9 +87,14 @@ struct its_baser {* The ITS structure - contains most of the infrastructure, with the * top-level MSI domain, the command queue, the collections, and the * list of devices writing to it. +* +* dev_alloc_lock has to be taken for device allocations, while the +* spinlock must be taken to parse data structures such as the device +* list. */ struct its_node {raw_spinlock_t lock; +struct mutex dev_alloc_lock;struct list_head entry;void __iomem *base;phys_addr_t phys_base;
@@ -138,6 +143,7 @@ struct its_device {void *itt;u32 nr_ites;u32 device_id; +bool shared; }; static struct {
@@ -2109,6 +2115,7 @@ static int its_msi_prepare(struct irq_domain *domain, struct device *dev,struct its_device *its_dev;struct msi_domain_info *msi_info;u32 dev_id; +int err =0 ;/* * We ignore "dev" entierely, and rely on the dev_id that has
@@ -2131,6 +2138,7 @@ static int its_msi_prepare(struct irq_domain *domain, struct device *dev,return -EINVAL ; } +mutex_lock (&its->dev_alloc_lock); its_dev =its_find_device (its, dev_id);if (its_dev) {/*
@@ -2138,18 +2146,22 @@ static int its_msi_prepare(struct irq_domain *domain, struct device *dev,* another alias (PCI bridge of some sort). No need to * create the device. */ + its_dev->shared = true;pr_debug ("Reusing ITT for devID %x\n" , dev_id); goto out; } its_dev =its_create_device (its, dev_id, nvec, true); -if (!its_dev) -return -ENOMEM ; +if (!its_dev) { + err = -ENOMEM ; + goto out; + }pr_debug ("ITT %d entries, %d bits\n" , nvec,ilog2 (nvec)); out: +mutex_unlock (&its->dev_alloc_lock); info->scratchpad[0 ].ptr = its_dev; -return 0 ; +return err; }static struct msi_domain_ops its_msi_domain_ops = {
@@ -2252,6 +2264,7 @@ static void its_irq_domain_free(struct irq_domain *domain, unsigned int virq, {struct irq_data *d =irq_domain_get_irq_data (domain, virq);struct its_device *its_dev =irq_data_get_irq_chip_data (d); +struct its_node *its = its_dev->its;int i;for (i =0 ; i < nr_irqs; i++) {
@@ -2266,8 +2279,14 @@ static void its_irq_domain_free(struct irq_domain *domain, unsigned int virq,irq_domain_reset_irq_data (data); } -/* If all interrupts have been freed, start mopping the floor */ -if (bitmap_empty (its_dev->event_map.lpi_map, +mutex_lock (&its->dev_alloc_lock); + +/* +* If all interrupts have been freed, start mopping the +* floor. This is conditionned on the device not being shared. +*/ +if (!its_dev->shared && +bitmap_empty (its_dev->event_map.lpi_map, its_dev->event_map.nr_lpis)) { its_lpi_free_chunks(its_dev->event_map.lpi_map, its_dev->event_map.lpi_base,
@@ -2279,6 +2298,8 @@ static void its_irq_domain_free(struct irq_domain *domain, unsigned int virq,its_free_device (its_dev); } +mutex_unlock (&its->dev_alloc_lock); +irq_domain_free_irqs_parent (domain, virq, nr_irqs); }
@@ -2966,6 +2987,7 @@ static int __init its_probe_one(struct resource *res, }raw_spin_lock_init (&its->lock); +mutex_init (&its->dev_alloc_lock);INIT_LIST_HEAD (&its->entry);INIT_LIST_HEAD (&its->its_device_list); typer =gic_read_typer (its_base +GITS_TYPER );
drivers/isdn/hisax/hfc_pci.c +2 -0
@@ -1169,11 +1169,13 @@ HFCPCI_l1hw(struct PStack *st, int pr, void *arg)if (cs->debug &L1_DEB_LAPD )debugl1 (cs,"-> PH_REQUEST_PULL" );#endif +spin_lock_irqsave (&cs->lock, flags);if (!cs->tx_skb) {test_and_clear_bit (FLG_L1_PULL_REQ , &st->l1.Flags); st->l1.l1l2 (st,PH_PULL |CONFIRM ,NULL ); }else test_and_set_bit (FLG_L1_PULL_REQ , &st->l1.Flags); +spin_unlock_irqrestore (&cs->lock, flags);break ;case (HW_RESET |REQUEST ):spin_lock_irqsave (&cs->lock, flags);
drivers/md/raid10.c +4 -0
@@ -1190,7 +1190,9 @@ static void raid10_read_request(struct mddev *mddev, struct bio *bio,struct bio *split =bio_split (bio, max_sectors, gfp, conf->bio_split);bio_chain (split, bio); +allow_barrier (conf);generic_make_request (bio); +wait_barrier (conf); bio = split; r10_bio->master_bio = bio; r10_bio->sectors = max_sectors;
@@ -1479,7 +1481,9 @@ static void raid10_write_request(struct mddev *mddev, struct bio *bio,struct bio *split =bio_split (bio, r10_bio->sectors,GFP_NOIO , conf->bio_split);bio_chain (split, bio); +allow_barrier (conf);generic_make_request (bio); +wait_barrier (conf); bio = split; r10_bio->master_bio = bio; }
drivers/media/i2c/ad9389b.c +1 -1
@@ -590,7 +590,7 @@ static const struct v4l2_dv_timings_cap ad9389b_timings_cap = { .type = V4L2_DV_BT_656_1120, /* keep this initialization for compatibility with GCC < 4.4.6 */ .reserved = { 0 }, - V4L2_INIT_BT_TIMINGS(0, 1920, 0, 1200, 25000000, 170000000, + V4L2_INIT_BT_TIMINGS(640, 1920, 350, 1200, 25000000, 170000000, V4L2_DV_BT_STD_CEA861 | V4L2_DV_BT_STD_DMT | V4L2_DV_BT_STD_GTF | V4L2_DV_BT_STD_CVT, V4L2_DV_BT_CAP_PROGRESSIVE | V4L2_DV_BT_CAP_REDUCED_BLANKING |
drivers/media/i2c/adv7511.c +1 -1
@@ -142,7 +142,7 @@ static const struct v4l2_dv_timings_cap adv7511_timings_cap = { .type = V4L2_DV_BT_656_1120, /* keep this initialization for compatibility with GCC < 4.4.6 */ .reserved = { 0 }, - V4L2_INIT_BT_TIMINGS(0, ADV7511_MAX_WIDTH, 0, ADV7511_MAX_HEIGHT, + V4L2_INIT_BT_TIMINGS(640, ADV7511_MAX_WIDTH, 350, ADV7511_MAX_HEIGHT, ADV7511_MIN_PIXELCLOCK, ADV7511_MAX_PIXELCLOCK, V4L2_DV_BT_STD_CEA861 | V4L2_DV_BT_STD_DMT | V4L2_DV_BT_STD_GTF | V4L2_DV_BT_STD_CVT,
drivers/media/i2c/adv7604.c +2 -2
@@ -778,7 +778,7 @@ static const struct v4l2_dv_timings_cap adv7604_timings_cap_analog = { .type = V4L2_DV_BT_656_1120, /* keep this initialization for compatibility with GCC < 4.4.6 */ .reserved = { 0 }, - V4L2_INIT_BT_TIMINGS(0, 1920, 0, 1200, 25000000, 170000000, + V4L2_INIT_BT_TIMINGS(640, 1920, 350, 1200, 25000000, 170000000, V4L2_DV_BT_STD_CEA861 | V4L2_DV_BT_STD_DMT | V4L2_DV_BT_STD_GTF | V4L2_DV_BT_STD_CVT, V4L2_DV_BT_CAP_PROGRESSIVE | V4L2_DV_BT_CAP_REDUCED_BLANKING |
@@ -789,7 +789,7 @@ static const struct v4l2_dv_timings_cap adv76xx_timings_cap_digital = { .type = V4L2_DV_BT_656_1120, /* keep this initialization for compatibility with GCC < 4.4.6 */ .reserved = { 0 }, - V4L2_INIT_BT_TIMINGS(0, 1920, 0, 1200, 25000000, 225000000, + V4L2_INIT_BT_TIMINGS(640, 1920, 350, 1200, 25000000, 225000000, V4L2_DV_BT_STD_CEA861 | V4L2_DV_BT_STD_DMT | V4L2_DV_BT_STD_GTF | V4L2_DV_BT_STD_CVT, V4L2_DV_BT_CAP_PROGRESSIVE | V4L2_DV_BT_CAP_REDUCED_BLANKING |
drivers/media/i2c/adv7842.c +2 -2
@@ -676,7 +676,7 @@ static const struct v4l2_dv_timings_cap adv7842_timings_cap_analog = { .type = V4L2_DV_BT_656_1120, /* keep this initialization for compatibility with GCC < 4.4.6 */ .reserved = { 0 }, - V4L2_INIT_BT_TIMINGS(0, 1920, 0, 1200, 25000000, 170000000, + V4L2_INIT_BT_TIMINGS(640, 1920, 350, 1200, 25000000, 170000000, V4L2_DV_BT_STD_CEA861 | V4L2_DV_BT_STD_DMT | V4L2_DV_BT_STD_GTF | V4L2_DV_BT_STD_CVT, V4L2_DV_BT_CAP_PROGRESSIVE | V4L2_DV_BT_CAP_REDUCED_BLANKING |
@@ -687,7 +687,7 @@ static const struct v4l2_dv_timings_cap adv7842_timings_cap_digital = { .type = V4L2_DV_BT_656_1120, /* keep this initialization for compatibility with GCC < 4.4.6 */ .reserved = { 0 }, - V4L2_INIT_BT_TIMINGS(0, 1920, 0, 1200, 25000000, 225000000, + V4L2_INIT_BT_TIMINGS(640, 1920, 350, 1200, 25000000, 225000000, V4L2_DV_BT_STD_CEA861 | V4L2_DV_BT_STD_DMT | V4L2_DV_BT_STD_GTF | V4L2_DV_BT_STD_CVT, V4L2_DV_BT_CAP_PROGRESSIVE | V4L2_DV_BT_CAP_REDUCED_BLANKING |
drivers/media/i2c/tc358743.c +1 -1
@@ -70,7 +70,7 @@ static const struct v4l2_dv_timings_cap tc358743_timings_cap = {/* keep this initialization for compatibility with GCC < 4.4.6 */ .reserved = { 0 },/* Pixel clock from REF_01 p. 20. Min/max height/width are unknown */ - V4L2_INIT_BT_TIMINGS(1, 10000, 1, 10000, 0, 165000000, + V4L2_INIT_BT_TIMINGS(640, 1920, 350, 1200, 13000000, 165000000, V4L2_DV_BT_STD_CEA861 | V4L2_DV_BT_STD_DMT | V4L2_DV_BT_STD_GTF | V4L2_DV_BT_STD_CVT, V4L2_DV_BT_CAP_PROGRESSIVE |
drivers/media/i2c/ths8200.c +1 -1
@@ -49,7 +49,7 @@ static const struct v4l2_dv_timings_cap ths8200_timings_cap = { .type = V4L2_DV_BT_656_1120, /* keep this initialization for compatibility with GCC < 4.4.6 */ .reserved = { 0 }, -V4L2_INIT_BT_TIMINGS (0 ,1920 ,0 ,1080 ,25000000 ,148500000 , +V4L2_INIT_BT_TIMINGS (640 ,1920 ,350 ,1080 ,25000000 ,148500000 , V4L2_DV_BT_STD_CEA861, V4L2_DV_BT_CAP_PROGRESSIVE) };
drivers/media/platform/coda/coda-bit.c +9 -10
@@ -953,16 +953,15 @@ static int coda_start_encoding(struct coda_ctx *ctx)else coda_write (dev,CODA_STD_H264 ,CODA_CMD_ENC_SEQ_COD_STD ); -if (ctx->params.h264_deblk_enabled) { - value = ((ctx->params.h264_deblk_alpha & -CODA_264PARAM_DEBLKFILTEROFFSETALPHA_MASK ) << -CODA_264PARAM_DEBLKFILTEROFFSETALPHA_OFFSET ) | - ((ctx->params.h264_deblk_beta & -CODA_264PARAM_DEBLKFILTEROFFSETBETA_MASK ) << -CODA_264PARAM_DEBLKFILTEROFFSETBETA_OFFSET ); - }else { - value =1 <<CODA_264PARAM_DISABLEDEBLK_OFFSET ; - } + value = ((ctx->params.h264_disable_deblocking_filter_idc & +CODA_264PARAM_DISABLEDEBLK_MASK ) << +CODA_264PARAM_DISABLEDEBLK_OFFSET ) | + ((ctx->params.h264_slice_alpha_c0_offset_div2 & +CODA_264PARAM_DEBLKFILTEROFFSETALPHA_MASK ) << +CODA_264PARAM_DEBLKFILTEROFFSETALPHA_OFFSET ) | + ((ctx->params.h264_slice_beta_offset_div2 & +CODA_264PARAM_DEBLKFILTEROFFSETBETA_MASK ) << +CODA_264PARAM_DEBLKFILTEROFFSETBETA_OFFSET );coda_write (dev, value,CODA_CMD_ENC_SEQ_264_PARA );break ;case V4L2_PIX_FMT_JPEG :
drivers/media/platform/coda/coda-common.c +7 -8
@@ -1675,14 +1675,13 @@ static int coda_s_ctrl(struct v4l2_ctrl *ctrl) ctx->params.h264_max_qp = ctrl->val;break ;case V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_ALPHA : - ctx->params.h264_deblk_alpha = ctrl->val; + ctx->params.h264_slice_alpha_c0_offset_div2 = ctrl->val;break ;case V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_BETA : - ctx->params.h264_deblk_beta = ctrl->val; + ctx->params.h264_slice_beta_offset_div2 = ctrl->val;break ;case V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_MODE : - ctx->params.h264_deblk_enabled = (ctrl->val == -V4L2_MPEG_VIDEO_H264_LOOP_FILTER_MODE_ENABLED ); + ctx->params.h264_disable_deblocking_filter_idc = ctrl->val;break ;case V4L2_CID_MPEG_VIDEO_H264_PROFILE :/* TODO: switch between baseline and constrained baseline */
@@ -1764,13 +1763,13 @@ static void coda_encode_ctrls(struct coda_ctx *ctx)v4l2_ctrl_new_std (&ctx->ctrls, &coda_ctrl_ops,V4L2_CID_MPEG_VIDEO_H264_MAX_QP ,0 ,51 ,1 ,51 );v4l2_ctrl_new_std (&ctx->ctrls, &coda_ctrl_ops, -V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_ALPHA ,0 ,15 ,1 ,0 ); +V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_ALPHA ,-6 ,6 ,1 ,0 );v4l2_ctrl_new_std (&ctx->ctrls, &coda_ctrl_ops, -V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_BETA ,0 ,15 ,1 ,0 ); +V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_BETA ,-6 ,6 ,1 ,0 );v4l2_ctrl_new_std_menu (&ctx->ctrls, &coda_ctrl_ops,V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_MODE , -V4L2_MPEG_VIDEO_H264_LOOP_FILTER_MODE_DISABLED ,0x0 , -V4L2_MPEG_VIDEO_H264_LOOP_FILTER_MODE_ENABLED ); +V4L2_MPEG_VIDEO_H264_LOOP_FILTER_MODE_DISABLED_AT_SLICE_BOUNDARY , +0x0 ,V4L2_MPEG_VIDEO_H264_LOOP_FILTER_MODE_ENABLED ); v4l2_ctrl_new_std_menu(&ctx->ctrls, &coda_ctrl_ops, V4L2_CID_MPEG_VIDEO_H264_PROFILE, V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE, 0x0,
drivers/media/platform/coda/coda.h +3 -3
@@ -114,9 +114,9 @@ struct coda_params {u8 h264_inter_qp;u8 h264_min_qp;u8 h264_max_qp; -u8 h264_deblk_enabled; -u8 h264_deblk_alpha; -u8 h264_deblk_beta; +u8 h264_disable_deblocking_filter_idc; +s8 h264_slice_alpha_c0_offset_div2; +s8 h264_slice_beta_offset_div2;u8 h264_profile_idc;u8 h264_level_idc;u8 mpeg4_intra_qp;
drivers/media/platform/coda/coda_regs.h +1 -1
@@ -292,7 +292,7 @@#define CODA_264PARAM_DEBLKFILTEROFFSETALPHA_OFFSET 8#define CODA_264PARAM_DEBLKFILTEROFFSETALPHA_MASK 0x0f#define CODA_264PARAM_DISABLEDEBLK_OFFSET 6 -#define CODA_264PARAM_DISABLEDEBLK_MASK 0x01 +#define CODA_264PARAM_DISABLEDEBLK_MASK 0x03#define CODA_264PARAM_CONSTRAINEDINTRAPREDFLAG_OFFSET 5#define CODA_264PARAM_CONSTRAINEDINTRAPREDFLAG_MASK 0x01#define CODA_264PARAM_CHROMAQPOFFSET_OFFSET 0
drivers/media/platform/davinci/vpbe.c +5 -2
@@ -739,7 +739,7 @@ static int vpbe_initialize(struct device *dev, struct vpbe_device *vpbe_dev)if (ret) {v4l2_err (&vpbe_dev->v4l2_dev,"Failed to set default output %s" , def_output); -return ret; + goto fail_kfree_amp; }printk (KERN_NOTICE "Setting default mode to %s\n" , def_mode);
@@ -747,12 +747,15 @@ static int vpbe_initialize(struct device *dev, struct vpbe_device *vpbe_dev)if (ret) {v4l2_err (&vpbe_dev->v4l2_dev,"Failed to set default mode %s" , def_mode); -return ret; + goto fail_kfree_amp; } vpbe_dev->initialized =1 ;/* TBD handling of bootargs for default output and mode */ return 0 ; +fail_kfree_amp: +mutex_lock (&vpbe_dev->lock); +kfree (vpbe_dev->amp); fail_kfree_encoders:kfree (vpbe_dev->encoders); fail_dev_unregister:
drivers/media/platform/mtk-vcodec/mtk_vcodec_enc_pm.c +6 -4
@@ -41,25 +41,27 @@ int mtk_vcodec_init_enc_pm(struct mtk_vcodec_dev *mtkdev) node =of_parse_phandle (dev->of_node,"mediatek,larb" ,0 );if (!node) {mtk_v4l2_err ("no mediatek,larb found" ); -return -1 ; +return -ENODEV ; } pdev =of_find_device_by_node (node); +of_node_put (node);if (!pdev) {mtk_v4l2_err ("no mediatek,larb device found" ); -return -1 ; +return -ENODEV ; } pm->larbvenc = &pdev->dev; node =of_parse_phandle (dev->of_node,"mediatek,larb" ,1 );if (!node) {mtk_v4l2_err ("no mediatek,larb found" ); -return -1 ; +return -ENODEV ; } pdev =of_find_device_by_node (node); +of_node_put (node);if (!pdev) {mtk_v4l2_err ("no mediatek,larb device found" ); -return -1 ; +return -ENODEV ; } pm->larbvenclt = &pdev->dev;
drivers/memstick/core/memstick.c +3 -0
@@ -18,6 +18,7 @@#include <linux/delay.h> #include <linux/slab.h> #include <linux/module.h> +#include <linux/pm_runtime.h> #define DRIVER_NAME "memstick"
@@ -436,6 +437,7 @@ static void memstick_check(struct work_struct *work)struct memstick_dev *card;dev_dbg (&host->dev,"memstick_check started\n" ); +pm_runtime_get_noresume (host->dev.parent);mutex_lock (&host->lock);if (!host->card) {if (memstick_power_on (host))
@@ -479,6 +481,7 @@ static void memstick_check(struct work_struct *work) host->set_param (host,MEMSTICK_POWER ,MEMSTICK_POWER_OFF );mutex_unlock (&host->lock); +pm_runtime_put (host->dev.parent);dev_dbg (&host->dev,"memstick_check finished\n" ); }
drivers/mmc/host/bcm2835.c +12 -0
@@ -286,6 +286,7 @@ static void bcm2835_reset(struct mmc_host *mmc)if (host->dma_chan)dmaengine_terminate_sync (host->dma_chan); + host->dma_chan =NULL ;bcm2835_reset_internal (host); }
@@ -772,6 +773,8 @@ static void bcm2835_finish_command(struct bcm2835_host *host)if (!(sdhsts &SDHSTS_CRC7_ERROR ) || (host->cmd->opcode !=MMC_SEND_OP_COND )) { +u32 edm, fsm; +if (sdhsts &SDHSTS_CMD_TIME_OUT ) { host->cmd->error = -ETIMEDOUT ; }else {
@@ -780,6 +783,13 @@ static void bcm2835_finish_command(struct bcm2835_host *host)bcm2835_dumpregs (host); host->cmd->error = -EILSEQ ; } + edm =readl (host->ioaddr +SDEDM ); + fsm = edm &SDEDM_FSM_MASK ; +if (fsm ==SDEDM_FSM_READWAIT || + fsm ==SDEDM_FSM_WRITESTART1 ) +/* Kick the FSM out of its wait */ +writel (edm |SDEDM_FORCE_DATA_MODE , + host->ioaddr +SDEDM );bcm2835_finish_request (host);return ; }
@@ -837,6 +847,8 @@ static void bcm2835_timeout(struct work_struct *work)dev_err (dev,"timeout waiting for hardware interrupt.\n" );bcm2835_dumpregs (host); +bcm2835_reset (host->mmc); +if (host->data) { host->data->error = -ETIMEDOUT ;bcm2835_finish_data (host);
drivers/mmc/host/sdhci-of-esdhc.c +12 -4
@@ -481,8 +481,12 @@ static void esdhc_clock_enable(struct sdhci_host *host, bool enable)/* Wait max 20 ms */ timeout =ktime_add_ms (ktime_get (),20 ); val =ESDHC_CLOCK_STABLE ; -while (!(sdhci_readl (host,ESDHC_PRSSTAT ) & val)) { -if (ktime_after (ktime_get (), timeout)) { +while (1 ) { +bool timedout =ktime_after (ktime_get (), timeout); + +if (sdhci_readl (host,ESDHC_PRSSTAT ) & val) +break ; +if (timedout) {pr_err ("%s: Internal clock never stabilised.\n" ,mmc_hostname (host->mmc));break ;
@@ -558,8 +562,12 @@ static void esdhc_of_set_clock(struct sdhci_host *host, unsigned int clock)/* Wait max 20 ms */ timeout =ktime_add_ms (ktime_get (),20 ); -while (!(sdhci_readl (host,ESDHC_PRSSTAT ) &ESDHC_CLOCK_STABLE )) { -if (ktime_after (ktime_get (), timeout)) { +while (1 ) { +bool timedout =ktime_after (ktime_get (), timeout); + +if (sdhci_readl (host,ESDHC_PRSSTAT ) &ESDHC_CLOCK_STABLE ) +break ; +if (timedout) {pr_err ("%s: Internal clock never stabilised.\n" ,mmc_hostname (host->mmc));return ;
drivers/mmc/host/sdhci-xenon-phy.c +7 -3
@@ -357,9 +357,13 @@ static int xenon_emmc_phy_enable_dll(struct sdhci_host *host)/* Wait max 32 ms */ timeout =ktime_add_ms (ktime_get (),32 ); -while (!(sdhci_readw (host,XENON_SLOT_EXT_PRESENT_STATE ) & -XENON_DLL_LOCK_STATE )) { -if (ktime_after (ktime_get (), timeout)) { +while (1 ) { +bool timedout =ktime_after (ktime_get (), timeout); + +if (sdhci_readw (host,XENON_SLOT_EXT_PRESENT_STATE ) & +XENON_DLL_LOCK_STATE ) +break ; +if (timedout) {dev_err (mmc_dev (host->mmc),"Wait for DLL Lock time-out\n" );return -ETIMEDOUT ; }
drivers/mmc/host/sdhci-xenon.c +7 -3
@@ -34,9 +34,13 @@ static int xenon_enable_internal_clk(struct sdhci_host *host)sdhci_writel (host, reg,SDHCI_CLOCK_CONTROL );/* Wait max 20 ms */ timeout =ktime_add_ms (ktime_get (),20 ); -while (!((reg =sdhci_readw (host,SDHCI_CLOCK_CONTROL )) - &SDHCI_CLOCK_INT_STABLE )) { -if (ktime_after (ktime_get (), timeout)) { +while (1 ) { +bool timedout =ktime_after (ktime_get (), timeout); + + reg =sdhci_readw (host,SDHCI_CLOCK_CONTROL ); +if (reg &SDHCI_CLOCK_INT_STABLE ) +break ; +if (timedout) {dev_err (mmc_dev (host->mmc),"Internal clock never stabilised.\n" );return -ETIMEDOUT ; }
drivers/net/ethernet/broadcom/bcmsysport.c +10 -15
@@ -519,7 +519,6 @@ static void bcm_sysport_get_wol(struct net_device *dev, struct ethtool_wolinfo *wol) {struct bcm_sysport_priv *priv =netdev_priv (dev); -u32 reg; wol->supported =WAKE_MAGIC |WAKE_MAGICSECURE ; wol->wolopts = priv->wolopts;
@@ -527,11 +526,7 @@ static void bcm_sysport_get_wol(struct net_device *dev,if (!(priv->wolopts &WAKE_MAGICSECURE ))return ; -/* Return the programmed SecureOn password */ - reg =umac_readl (priv,UMAC_PSW_MS ); -put_unaligned_be16 (reg, &wol->sopass[0 ]); - reg =umac_readl (priv,UMAC_PSW_LS ); -put_unaligned_be32 (reg, &wol->sopass[2 ]); +memcpy (wol->sopass, priv->sopass,sizeof (priv->sopass)); } static int bcm_sysport_set_wol(struct net_device *dev,
@@ -547,13 +542,8 @@ static int bcm_sysport_set_wol(struct net_device *dev,if (wol->wolopts & ~supported)return -EINVAL ; -/* Program the SecureOn password */ -if (wol->wolopts &WAKE_MAGICSECURE ) { -umac_writel (priv,get_unaligned_be16 (&wol->sopass[0 ]), -UMAC_PSW_MS ); -umac_writel (priv,get_unaligned_be32 (&wol->sopass[2 ]), -UMAC_PSW_LS ); - } +if (wol->wolopts &WAKE_MAGICSECURE ) +memcpy (priv->sopass, wol->sopass,sizeof (priv->sopass));/* Flag the device and relevant IRQ as wakeup capable */ if (wol->wolopts) {
@@ -2221,12 +2211,17 @@ static int bcm_sysport_suspend_to_wol(struct bcm_sysport_priv *priv)unsigned int timeout =1000 ;u32 reg; -/* Password has already been programmed */ reg =umac_readl (priv,UMAC_MPD_CTRL ); reg |=MPD_EN ; reg &= ~PSW_EN ; -if (priv->wolopts &WAKE_MAGICSECURE ) +if (priv->wolopts &WAKE_MAGICSECURE ) { +/* Program the SecureOn password */ +umac_writel (priv,get_unaligned_be16 (&priv->sopass[0 ]), +UMAC_PSW_MS ); +umac_writel (priv,get_unaligned_be32 (&priv->sopass[2 ]), +UMAC_PSW_LS ); reg |=PSW_EN ; + }umac_writel (priv, reg,UMAC_MPD_CTRL );/* Make sure RBUF entered WoL mode as result */
drivers/net/ethernet/broadcom/bcmsysport.h +2 -0
@@ -11,6 +11,7 @@#ifndef __BCM_SYSPORT_H#define __BCM_SYSPORT_H +#include <linux/ethtool.h> #include <linux/if_vlan.h> /* Receive/transmit descriptor format */
@@ -754,6 +755,7 @@ struct bcm_sysport_priv { unsigned int crc_fwd:1;u16 rev;u32 wolopts; +u8 sopass[SOPASS_MAX ]; unsigned int wol_irq_disabled:1;/* MIB related fields */
drivers/net/ethernet/cisco/enic/enic_main.c +2 -1
@@ -1393,7 +1393,8 @@ static void enic_rq_indicate_buf(struct vnic_rq *rq,* csum is correct or is zero. */ if ((netdev->features &NETIF_F_RXCSUM ) && !csum_not_calc && - tcp_udp_csum_ok && ipv4_csum_ok && outer_csum_ok) { + tcp_udp_csum_ok && outer_csum_ok && + (ipv4_csum_ok || ipv6)) { skb->ip_summed =CHECKSUM_UNNECESSARY ; skb->csum_level = encap; }
drivers/net/ethernet/freescale/fman/fman_memac.c +1 -1
@@ -927,7 +927,7 @@ int memac_add_hash_mac_address(struct fman_mac *memac, enet_addr_t *eth_addr) hash =get_mac_addr_hash_code (addr) &HASH_CTRL_ADDR_MASK ;/* Create element to be added to the driver hash table */ - hash_entry =kmalloc (sizeof (*hash_entry),GFP_KERNEL ); + hash_entry =kmalloc (sizeof (*hash_entry),GFP_ATOMIC );if (!hash_entry)return -ENOMEM ; hash_entry->addr = addr;
drivers/net/ethernet/freescale/fman/fman_tgec.c +1 -1
@@ -551,7 +551,7 @@ int tgec_add_hash_mac_address(struct fman_mac *tgec, enet_addr_t *eth_addr) hash = (crc >>TGEC_HASH_MCAST_SHIFT ) &TGEC_HASH_ADR_MSK ;/* Create element to be added to the driver hash table */ - hash_entry =kmalloc (sizeof (*hash_entry),GFP_KERNEL ); + hash_entry =kmalloc (sizeof (*hash_entry),GFP_ATOMIC );if (!hash_entry)return -ENOMEM ; hash_entry->addr = addr;
drivers/net/ethernet/intel/i40e/i40e_main.c +3 -0
@@ -9772,6 +9772,9 @@ static int i40e_config_netdev(struct i40e_vsi *vsi)ether_addr_copy (netdev->dev_addr, mac_addr);ether_addr_copy (netdev->perm_addr, mac_addr); +/* i40iw_net_event() reads 16 bytes from neigh->primary_key */ + netdev->neigh_priv_len =sizeof (u32) *4 ; + netdev->priv_flags |=IFF_UNICAST_FLT ; netdev->priv_flags |=IFF_SUPP_NOFCS ;/* Setup netdev TC information */
drivers/net/ethernet/intel/igb/igb_main.c +5 -3
@@ -7950,9 +7950,11 @@ static int __igb_shutdown(struct pci_dev *pdev, bool *enable_wake,rtnl_unlock ();#ifdef CONFIG_PM - retval =pci_save_state (pdev); -if (retval) -return retval; +if (!runtime) { + retval =pci_save_state (pdev); +if (retval) +return retval; + }#endif status =rd32 (E1000_STATUS );
drivers/net/ethernet/marvell/skge.c +4 -2
@@ -152,8 +152,10 @@ static void skge_get_regs(struct net_device *dev, struct ethtool_regs *regs,memset (p,0 , regs->len);memcpy_fromio (p, io,B3_RAM_ADDR ); -memcpy_fromio (p +B3_RI_WTO_R1 , io +B3_RI_WTO_R1 , - regs->len -B3_RI_WTO_R1 ); +if (regs->len >B3_RI_WTO_R1 ) { +memcpy_fromio (p +B3_RI_WTO_R1 , io +B3_RI_WTO_R1 , + regs->len -B3_RI_WTO_R1 ); + } }/* Wake on Lan only supported on Yukon chips with rev 1 or above */
drivers/net/ethernet/mellanox/mlx5/core/en_main.c +1 -1
@@ -1605,7 +1605,7 @@ static void mlx5e_close_cq(struct mlx5e_cq *cq)static int mlx5e_get_cpu (struct mlx5e_priv *priv,int ix) { -return cpumask_first (priv->mdev->priv.irq_info[ix].mask); +return cpumask_first (priv->mdev->priv.irq_info[ix +MLX5_EQ_VEC_COMP_BASE ].mask); } static int mlx5e_open_tx_cqs(struct mlx5e_channel *c,
drivers/net/ethernet/mellanox/mlx5/core/en_rx.c +14 -0
@@ -646,6 +646,8 @@ static u32 mlx5e_get_fcs(const struct sk_buff *skb)return __get_unaligned_cpu32 (fcs_bytes); } +#define short_frame (size) ((size) <= ETH_ZLEN + ETH_FCS_LEN) + static inline void mlx5e_handle_csum(struct net_device *netdev, struct mlx5_cqe64 *cqe, struct mlx5e_rq *rq,
@@ -661,6 +663,17 @@ static inline void mlx5e_handle_csum(struct net_device *netdev,return ; } +/* CQE csum doesn't cover padding octets in short ethernet +* frames. And the pad field is appended prior to calculating +* and appending the FCS field. +* +* Detecting these padded frames requires to verify and parse +* IP headers, so we simply force all those small frames to be +* CHECKSUM_UNNECESSARY even if they are not padded. +*/ +if (short_frame (skb->len)) + goto csum_unnecessary; +if (is_first_ethertype_ip (skb)) { skb->ip_summed =CHECKSUM_COMPLETE ; skb->csum =csum_unfold ((__force __sum16 )cqe->check_sum);
@@ -672,6 +685,7 @@ static inline void mlx5e_handle_csum(struct net_device *netdev,return ; } +csum_unnecessary:if (likely ((cqe->hds_ip_ext &CQE_L3_OK ) && (cqe->hds_ip_ext &CQE_L4_OK ))) { skb->ip_summed =CHECKSUM_UNNECESSARY ;
drivers/net/ethernet/mellanox/mlx5/core/main.c +8 -6
@@ -619,18 +619,19 @@ u64 mlx5_read_internal_timer(struct mlx5_core_dev *dev)static int mlx5_irq_set_affinity_hint (struct mlx5_core_dev *mdev,int i) {struct mlx5_priv *priv = &mdev->priv; -int irq =pci_irq_vector (mdev->pdev,MLX5_EQ_VEC_COMP_BASE + i); +int vecidx =MLX5_EQ_VEC_COMP_BASE + i; +int irq =pci_irq_vector (mdev->pdev, vecidx); -if (!zalloc_cpumask_var (&priv->irq_info[i].mask,GFP_KERNEL )) { +if (!zalloc_cpumask_var (&priv->irq_info[vecidx].mask,GFP_KERNEL )) {mlx5_core_warn (mdev,"zalloc_cpumask_var failed" );return -ENOMEM ; }cpumask_set_cpu (cpumask_local_spread (i, priv->numa_node), - priv->irq_info[i].mask); + priv->irq_info[vecidx].mask);if (IS_ENABLED (CONFIG_SMP ) && -irq_set_affinity_hint (irq, priv->irq_info[i].mask)) +irq_set_affinity_hint (irq, priv->irq_info[vecidx].mask))mlx5_core_warn (mdev,"irq_set_affinity_hint failed, irq 0x%.4x" , irq);return 0 ;
@@ -638,11 +639,12 @@ static int mlx5_irq_set_affinity_hint(struct mlx5_core_dev *mdev, int i)static void mlx5_irq_clear_affinity_hint (struct mlx5_core_dev *mdev,int i) { +int vecidx =MLX5_EQ_VEC_COMP_BASE + i;struct mlx5_priv *priv = &mdev->priv; -int irq =pci_irq_vector (mdev->pdev,MLX5_EQ_VEC_COMP_BASE + i); +int irq =pci_irq_vector (mdev->pdev, vecidx);irq_set_affinity_hint (irq,NULL ); -free_cpumask_var (priv->irq_info[i].mask); +free_cpumask_var (priv->irq_info[vecidx].mask); }static int mlx5_irq_set_affinity_hints (struct mlx5_core_dev *mdev)
drivers/net/ethernet/mellanox/mlxsw/spectrum.c +23 -0
@@ -3907,6 +3907,25 @@ void mlxsw_sp_port_dev_put(struct mlxsw_sp_port *mlxsw_sp_port)dev_put (mlxsw_sp_port->dev); } +static void +mlxsw_sp_port_lag_uppers_cleanup (struct mlxsw_sp_port *mlxsw_sp_port, +struct net_device *lag_dev) +{ +struct net_device *br_dev =netdev_master_upper_dev_get (lag_dev); +struct net_device *upper_dev; +struct list_head *iter; + +if (netif_is_bridge_port (lag_dev)) +mlxsw_sp_port_bridge_leave (mlxsw_sp_port, lag_dev, br_dev); + +netdev_for_each_upper_dev_rcu (lag_dev, upper_dev, iter) { +if (!netif_is_bridge_port (upper_dev)) +continue ; + br_dev =netdev_master_upper_dev_get (upper_dev); +mlxsw_sp_port_bridge_leave (mlxsw_sp_port, upper_dev, br_dev); + } +} +static int mlxsw_sp_lag_create (struct mlxsw_sp *mlxsw_sp,u16 lag_id) {char sldr_pl[MLXSW_REG_SLDR_LEN ];
@@ -4094,6 +4113,10 @@ static void mlxsw_sp_port_lag_leave(struct mlxsw_sp_port *mlxsw_sp_port,/* Any VLANs configured on the port are no longer valid */ mlxsw_sp_port_vlan_flush (mlxsw_sp_port); +/* Make the LAG and its directly linked uppers leave bridges they +* are memeber in +*/ +mlxsw_sp_port_lag_uppers_cleanup (mlxsw_sp_port, lag_dev);if (lag->ref_count ==1 )mlxsw_sp_lag_destroy (mlxsw_sp, lag_id);
drivers/net/ethernet/mellanox/mlxsw/spectrum_switchdev.c +1 -26
@@ -291,30 +291,6 @@ mlxsw_sp_bridge_port_destroy(struct mlxsw_sp_bridge_port *bridge_port)kfree (bridge_port); } -static bool -mlxsw_sp_bridge_port_should_destroy (const struct mlxsw_sp_bridge_port * - bridge_port) -{ -struct net_device *dev = bridge_port->dev; -struct mlxsw_sp *mlxsw_sp; - -if (is_vlan_dev (dev)) - mlxsw_sp =mlxsw_sp_lower_get (vlan_dev_real_dev (dev)); -else - mlxsw_sp =mlxsw_sp_lower_get (dev); - -/* In case ports were pulled from out of a bridged LAG, then -* it's possible the reference count isn't zero, yet the bridge -* port should be destroyed, as it's no longer an upper of ours. -*/ -if (!mlxsw_sp &&list_empty (&bridge_port->vlans_list)) -return true; -else if (bridge_port->ref_count ==0 ) -return true; -else -return false; -} -static struct mlxsw_sp_bridge_port *mlxsw_sp_bridge_port_get (struct mlxsw_sp_bridge *bridge,struct net_device *brport_dev)
@@ -352,8 +328,7 @@ static void mlxsw_sp_bridge_port_put(struct mlxsw_sp_bridge *bridge, {struct mlxsw_sp_bridge_device *bridge_device; - bridge_port->ref_count--; -if (!mlxsw_sp_bridge_port_should_destroy (bridge_port)) +if (--bridge_port->ref_count !=0 )return ; bridge_device = bridge_port->bridge_device;mlxsw_sp_bridge_port_destroy (bridge_port);
drivers/net/ethernet/sun/niu.c +8 -2
@@ -8119,6 +8119,8 @@ static int niu_pci_vpd_scan_props(struct niu *np, u32 start, u32 end) start +=3 ; prop_len =niu_pci_eeprom_read (np, start +4 ); +if (prop_len <0 ) +return prop_len; err =niu_pci_vpd_get_propname (np, start +5 , namebuf,64 );if (err <0 )return err;
@@ -8163,8 +8165,12 @@ static int niu_pci_vpd_scan_props(struct niu *np, u32 start, u32 end)netif_printk (np, probe,KERN_DEBUG , np->dev,"VPD_SCAN: Reading in property [%s] len[%d]\n" , namebuf, prop_len); -for (i =0 ; i < prop_len; i++) - *prop_buf++ =niu_pci_eeprom_read (np, off + i); +for (i =0 ; i < prop_len; i++) { + err =niu_pci_eeprom_read (np, off + i); +if (err >=0 ) + *prop_buf = err; + ++prop_buf; + } } start += len;
drivers/net/phy/dp83640.c +10 -3
@@ -893,14 +893,14 @@ static void decode_txts(struct dp83640_private *dp83640, struct phy_txts *phy_txts) {struct skb_shared_hwtstamps shhwtstamps; +struct dp83640_skb_info *skb_info;struct sk_buff *skb; -u64 ns;u8 overflow; +u64 ns;/* We must already have the skb that triggered this. */ - +again: skb =skb_dequeue (&dp83640->tx_queue); -if (!skb) {pr_debug ("have timestamp but tx_queue empty\n" );return ;
@@ -915,6 +915,11 @@ static void decode_txts(struct dp83640_private *dp83640, }return ; } + skb_info = (struct dp83640_skb_info *)skb->cb; +if (time_after (jiffies, skb_info->tmo)) { +kfree_skb (skb); + goto again; + } ns =phy2txts (phy_txts);memset (&shhwtstamps,0 ,sizeof (shhwtstamps));
@@ -1466,6 +1471,7 @@ static bool dp83640_rxtstamp(struct phy_device *phydev,static void dp83640_txtstamp (struct phy_device *phydev,struct sk_buff *skb,int type) { +struct dp83640_skb_info *skb_info = (struct dp83640_skb_info *)skb->cb;struct dp83640_private *dp83640 = phydev->priv;switch (dp83640->hwts_tx_en) {
@@ -1478,6 +1484,7 @@ static void dp83640_txtstamp(struct phy_device *phydev,/* fall through */ case HWTSTAMP_TX_ON :skb_shinfo (skb)->tx_flags |=SKBTX_IN_PROGRESS ; + skb_info->tmo = jiffies +SKB_TIMESTAMP_TIMEOUT ;skb_queue_tail (&dp83640->tx_queue, skb);break ;
drivers/net/usb/smsc95xx.c +1 -0
@@ -1295,6 +1295,7 @@ static int smsc95xx_bind(struct usbnet *dev, struct usb_interface *intf) dev->net->features |=NETIF_F_RXCSUM ; dev->net->hw_features =NETIF_F_IP_CSUM |NETIF_F_RXCSUM ; +set_bit (EVENT_NO_IP_ALIGN , &dev->flags);smsc95xx_init_mac_address (dev);
drivers/net/wireless/ath/ath9k/ath9k.h +1 -1
@@ -272,7 +272,7 @@ struct ath_node {#endif u8 key_idx[4 ]; -u32 ackto; +int ackto;struct list_head list; };
drivers/net/wireless/ath/ath9k/dynack.c +25 -10
@@ -29,9 +29,13 @@* ath_dynack_ewma - EWMA (Exponentially Weighted Moving Average) calculation * */ -static inline u32 ath_dynack_ewma (u32 old,u32 new) +static inline int ath_dynack_ewma (int old,int new) { -return (new * (EWMA_DIV -EWMA_LEVEL ) + old *EWMA_LEVEL ) /EWMA_DIV ; +if (old >0 ) +return (new * (EWMA_DIV -EWMA_LEVEL ) + + old *EWMA_LEVEL ) /EWMA_DIV ; +else +return new; }/**
@@ -82,10 +86,10 @@ static inline bool ath_dynack_bssidmask(struct ath_hw *ah, const u8 *mac)*/ static void ath_dynack_compute_ackto (struct ath_hw *ah) { -struct ath_node *an; -u32 to =0 ; -struct ath_dynack *da = &ah->dynack;struct ath_common *common =ath9k_hw_common (ah); +struct ath_dynack *da = &ah->dynack; +struct ath_node *an; +int to =0 ;list_for_each_entry (an, &da->nodes, list)if (an->ackto > to)
@@ -144,7 +148,8 @@ static void ath_dynack_compute_to(struct ath_hw *ah) an->ackto =ath_dynack_ewma (an->ackto, ackto);ath_dbg (ath9k_hw_common (ah),DYNACK , -"%pM to %u\n" , dst, an->ackto); +"%pM to %d [%u]\n" , dst, + an->ackto, ackto);if (time_is_before_jiffies (da->lto)) {ath_dynack_compute_ackto (ah); da->lto = jiffies +COMPUTE_TO ;
@@ -166,10 +171,12 @@ static void ath_dynack_compute_to(struct ath_hw *ah)* @ah: ath hw * @skb: socket buffer * @ts: tx status info +* @sta: station pointer * */ void ath_dynack_sample_tx_ts (struct ath_hw *ah,struct sk_buff *skb, -struct ath_tx_status *ts) +struct ath_tx_status *ts, +struct ieee80211_sta *sta) {u8 ridx;struct ieee80211_hdr *hdr;
@@ -177,7 +184,7 @@ void ath_dynack_sample_tx_ts(struct ath_hw *ah, struct sk_buff *skb,struct ath_common *common =ath9k_hw_common (ah);struct ieee80211_tx_info *info =IEEE80211_SKB_CB (skb); -if ((info->flags &IEEE80211_TX_CTL_NO_ACK ) || !da->enabled) +if (!da->enabled || (info->flags &IEEE80211_TX_CTL_NO_ACK ))return ;spin_lock_bh (&da->qlock);
@@ -187,11 +194,19 @@ void ath_dynack_sample_tx_ts(struct ath_hw *ah, struct sk_buff *skb,/* late ACK */ if (ts->ts_status &ATH9K_TXERR_XRETRY ) {if (ieee80211_is_assoc_req (hdr->frame_control) || -ieee80211_is_assoc_resp (hdr->frame_control)) { +ieee80211_is_assoc_resp (hdr->frame_control) || +ieee80211_is_auth (hdr->frame_control)) {ath_dbg (common,DYNACK ,"late ack\n" ); +ath9k_hw_setslottime (ah, (LATEACK_TO -3 ) /2 );ath9k_hw_set_ack_timeout (ah,LATEACK_TO );ath9k_hw_set_cts_timeout (ah,LATEACK_TO ); +if (sta) { +struct ath_node *an; + + an = (struct ath_node *)sta->drv_priv; + an->ackto =-1 ; + } da->lto = jiffies +LATEACK_DELAY ; }
@@ -251,7 +266,7 @@ void ath_dynack_sample_ack_ts(struct ath_hw *ah, struct sk_buff *skb,struct ath_common *common =ath9k_hw_common (ah);struct ieee80211_hdr *hdr = (struct ieee80211_hdr *)skb->data; -if (!ath_dynack_bssidmask (ah, hdr->addr1) || !da->enabled) +if (!da->enabled || !ath_dynack_bssidmask (ah, hdr->addr1))return ;spin_lock_bh (&da->qlock);
drivers/net/wireless/ath/ath9k/dynack.h +4 -2
@@ -86,7 +86,8 @@ void ath_dynack_node_deinit(struct ath_hw *ah, struct ath_node *an);void ath_dynack_init (struct ath_hw *ah);void ath_dynack_sample_ack_ts (struct ath_hw *ah,struct sk_buff *skb,u32 ts);void ath_dynack_sample_tx_ts (struct ath_hw *ah,struct sk_buff *skb, -struct ath_tx_status *ts); +struct ath_tx_status *ts, +struct ieee80211_sta *sta);#else static inline void ath_dynack_init (struct ath_hw *ah) {} static inline void ath_dynack_node_init(struct ath_hw *ah,
@@ -97,7 +98,8 @@ static inline void ath_dynack_sample_ack_ts(struct ath_hw *ah, struct sk_buff *skb, u32 ts) {}static inline void ath_dynack_sample_tx_ts (struct ath_hw *ah,struct sk_buff *skb, -struct ath_tx_status *ts) {} +struct ath_tx_status *ts, +struct ieee80211_sta *sta) {}#endif #endif /* DYNACK_H */
drivers/net/wireless/ath/ath9k/xmit.c +3 -2
@@ -621,7 +621,7 @@ static void ath_tx_complete_aggr(struct ath_softc *sc, struct ath_txq *txq,if (bf == bf->bf_lastbf)ath_dynack_sample_tx_ts (sc->sc_ah, bf->bf_mpdu, - ts); + ts, sta); } ath_tx_complete_buf(sc, bf, txq, &bf_head, sta, ts,
@@ -765,7 +765,8 @@ static void ath_tx_process_buffer(struct ath_softc *sc, struct ath_txq *txq,memcpy (info->control.rates, bf->rates,sizeof (info->control.rates));ath_tx_rc_status (sc, bf, ts,1 , txok ?0 :1 , txok); -ath_dynack_sample_tx_ts (sc->sc_ah, bf->bf_mpdu, ts); +ath_dynack_sample_tx_ts (sc->sc_ah, bf->bf_mpdu, ts, + sta); }ath_tx_complete_buf (sc, bf, txq, bf_head, sta, ts, txok); }else
drivers/net/wireless/st/cw1200/scan.c +6 -7
@@ -78,6 +78,10 @@ int cw1200_hw_scan(struct ieee80211_hw *hw,if (req->n_ssids >WSM_SCAN_MAX_NUM_OF_SSIDS )return -EINVAL ; +/* will be unlocked in cw1200_scan_work() */ +down (&priv->scan.lock); +mutex_lock (&priv->conf_mutex); + frame.skb =ieee80211_probereq_get (hw, priv->vif->addr,NULL ,0 , req->ie_len);if (!frame.skb)
@@ -86,19 +90,15 @@ int cw1200_hw_scan(struct ieee80211_hw *hw,if (req->ie_len)skb_put_data (frame.skb, req->ie, req->ie_len); -/* will be unlocked in cw1200_scan_work() */ -down (&priv->scan.lock); -mutex_lock (&priv->conf_mutex); - ret =wsm_set_template_frame (priv, &frame);if (!ret) {/* Host want to be the probe responder. */ ret =wsm_set_probe_responder (priv, true); }if (ret) { +dev_kfree_skb (frame.skb);mutex_unlock (&priv->conf_mutex);up (&priv->scan.lock); -dev_kfree_skb (frame.skb);return ret; }
@@ -120,10 +120,9 @@ int cw1200_hw_scan(struct ieee80211_hw *hw, ++priv->scan.n_ssids; } -mutex_unlock (&priv->conf_mutex); -if (frame.skb)dev_kfree_skb (frame.skb); +mutex_unlock (&priv->conf_mutex);queue_work (priv->workqueue, &priv->scan.work);return 0 ; }
drivers/pci/switch/switchtec.c +3 -0
@@ -1064,6 +1064,7 @@ static int ioctl_event_ctl(struct switchtec_dev *stdev, {int ret;int nr_idxs; +unsigned int event_flags;struct switchtec_ioctl_event_ctl ctl;if (copy_from_user (&ctl, uctl,sizeof (ctl)))
@@ -1085,7 +1086,9 @@ static int ioctl_event_ctl(struct switchtec_dev *stdev,else return -EINVAL ; + event_flags = ctl.flags;for (ctl.index =0 ; ctl.index < nr_idxs; ctl.index++) { + ctl.flags = event_flags; ret =event_ctl (stdev, &ctl);if (ret <0 )return ret;
drivers/phy/allwinner/phy-sun4i-usb.c +7 -0
@@ -125,6 +125,7 @@ struct sun4i_usb_phy_cfg {bool dedicated_clocks;bool enable_pmu_unk1;bool phy0_dual_route; +int missing_phys; };struct sun4i_usb_phy_data {
@@ -645,6 +646,9 @@ static struct phy *sun4i_usb_phy_xlate(struct device *dev,if (args->args[0 ] >= data->cfg->num_phys)return ERR_PTR (-ENODEV ); +if (data->cfg->missing_phys &BIT (args->args[0 ])) +return ERR_PTR (-ENODEV ); +return data->phys[args->args[0 ]].phy; }
@@ -740,6 +744,9 @@ static int sun4i_usb_phy_probe(struct platform_device *pdev)struct sun4i_usb_phy *phy = data->phys + i;char name[16 ]; +if (data->cfg->missing_phys &BIT (i)) +continue ; +snprintf (name,sizeof (name),"usb%d_vbus" , i); phy->vbus =devm_regulator_get_optional (dev, name);if (IS_ERR (phy->vbus)) {
drivers/pinctrl/bcm/pinctrl-bcm2835.c +8 -8
@@ -92,7 +92,7 @@ struct bcm2835_pinctrl {struct gpio_chip gpio_chip;struct pinctrl_gpio_range gpio_range; -spinlock_t irq_lock[BCM2835_NUM_BANKS ]; +raw_spinlock_t irq_lock[BCM2835_NUM_BANKS ]; };/* pins are just named GPIO0..GPIO53 */
@@ -471,10 +471,10 @@ static void bcm2835_gpio_irq_enable(struct irq_data *data)unsigned bank =GPIO_REG_OFFSET (gpio);unsigned long flags; -spin_lock_irqsave (&pc->irq_lock[bank], flags); +raw_spin_lock_irqsave (&pc->irq_lock[bank], flags);set_bit (offset, &pc->enabled_irq_map[bank]);bcm2835_gpio_irq_config (pc, gpio, true); -spin_unlock_irqrestore (&pc->irq_lock[bank], flags); +raw_spin_unlock_irqrestore (&pc->irq_lock[bank], flags); }static void bcm2835_gpio_irq_disable (struct irq_data *data)
@@ -486,12 +486,12 @@ static void bcm2835_gpio_irq_disable(struct irq_data *data)unsigned bank =GPIO_REG_OFFSET (gpio);unsigned long flags; -spin_lock_irqsave (&pc->irq_lock[bank], flags); +raw_spin_lock_irqsave (&pc->irq_lock[bank], flags);bcm2835_gpio_irq_config (pc, gpio, false);/* Clear events that were latched prior to clearing event sources */ bcm2835_gpio_set_bit (pc,GPEDS0 , gpio);clear_bit (offset, &pc->enabled_irq_map[bank]); -spin_unlock_irqrestore (&pc->irq_lock[bank], flags); +raw_spin_unlock_irqrestore (&pc->irq_lock[bank], flags); } static int __bcm2835_gpio_irq_set_type_disabled(struct bcm2835_pinctrl *pc,
@@ -594,7 +594,7 @@ static int bcm2835_gpio_irq_set_type(struct irq_data *data, unsigned int type)unsigned long flags;int ret; -spin_lock_irqsave (&pc->irq_lock[bank], flags); +raw_spin_lock_irqsave (&pc->irq_lock[bank], flags);if (test_bit (offset, &pc->enabled_irq_map[bank])) ret =__bcm2835_gpio_irq_set_type_enabled (pc, gpio, type);
@@ -606,7 +606,7 @@ static int bcm2835_gpio_irq_set_type(struct irq_data *data, unsigned int type)else irq_set_handler_locked (data, handle_level_irq); -spin_unlock_irqrestore (&pc->irq_lock[bank], flags); +raw_spin_unlock_irqrestore (&pc->irq_lock[bank], flags);return ret; }
@@ -1021,7 +1021,7 @@ static int bcm2835_pinctrl_probe(struct platform_device *pdev)for_each_set_bit (offset, &events,32 )bcm2835_gpio_wr (pc,GPEDS0 + i *4 ,BIT (offset)); -spin_lock_init (&pc->irq_lock[i]); +raw_spin_lock_init (&pc->irq_lock[i]); } err =gpiochip_add_data (&pc->gpio_chip, pc);
drivers/pinctrl/meson/pinctrl-meson8.c +3 -0
@@ -808,7 +808,9 @@ static const char * const gpio_groups[] = {"BOOT_5" ,"BOOT_6" ,"BOOT_7" ,"BOOT_8" ,"BOOT_9" ,"BOOT_10" ,"BOOT_11" ,"BOOT_12" ,"BOOT_13" ,"BOOT_14" , "BOOT_15", "BOOT_16", "BOOT_17", "BOOT_18", +}; +static const char *const gpio_aobus_groups[] = {"GPIOAO_0" ,"GPIOAO_1" ,"GPIOAO_2" ,"GPIOAO_3" ,"GPIOAO_4" ,"GPIOAO_5" ,"GPIOAO_6" ,"GPIOAO_7" , "GPIOAO_8", "GPIOAO_9", "GPIOAO_10", "GPIOAO_11",
@@ -1030,6 +1032,7 @@ static struct meson_pmx_func meson8_cbus_functions[] = { };static struct meson_pmx_func meson8_aobus_functions[] = { +FUNCTION (gpio_aobus),FUNCTION (uart_ao),FUNCTION (remote),FUNCTION (i2c_slave_ao),
drivers/pinctrl/meson/pinctrl-meson8b.c +8 -5
@@ -649,16 +649,18 @@ static const char * const gpio_groups[] = {"BOOT_10" ,"BOOT_11" ,"BOOT_12" ,"BOOT_13" ,"BOOT_14" ,"BOOT_15" ,"BOOT_16" ,"BOOT_17" ,"BOOT_18" , -"GPIOAO_0" ,"GPIOAO_1" ,"GPIOAO_2" ,"GPIOAO_3" , -"GPIOAO_4" ,"GPIOAO_5" ,"GPIOAO_6" ,"GPIOAO_7" , -"GPIOAO_8" ,"GPIOAO_9" ,"GPIOAO_10" ,"GPIOAO_11" , -"GPIOAO_12" ,"GPIOAO_13" ,"GPIO_BSD_EN" ,"GPIO_TEST_N" , -"DIF_0_P" ,"DIF_0_N" ,"DIF_1_P" ,"DIF_1_N" ,"DIF_2_P" ,"DIF_2_N" ,"DIF_3_P" ,"DIF_3_N" ,"DIF_4_P" ,"DIF_4_N" }; +static const char *const gpio_aobus_groups[] = { +"GPIOAO_0" ,"GPIOAO_1" ,"GPIOAO_2" ,"GPIOAO_3" , +"GPIOAO_4" ,"GPIOAO_5" ,"GPIOAO_6" ,"GPIOAO_7" , +"GPIOAO_8" ,"GPIOAO_9" ,"GPIOAO_10" ,"GPIOAO_11" , +"GPIOAO_12" ,"GPIOAO_13" ,"GPIO_BSD_EN" ,"GPIO_TEST_N" +}; +static const char *const sd_a_groups[] = {"sd_d0_a" ,"sd_d1_a" ,"sd_d2_a" ,"sd_d3_a" ,"sd_clk_a" , "sd_cmd_a"
@@ -874,6 +876,7 @@ static struct meson_pmx_func meson8b_cbus_functions[] = { };static struct meson_pmx_func meson8b_aobus_functions[] = { +FUNCTION (gpio_aobus),FUNCTION (uart_ao),FUNCTION (uart_ao_b),FUNCTION (i2c_slave_ao),
drivers/pinctrl/pinctrl-sx150x.c +8 -3
@@ -1166,7 +1166,6 @@ static int sx150x_probe(struct i2c_client *client, }/* Register GPIO controller */ - pctl->gpio.label =devm_kstrdup (dev, client->name,GFP_KERNEL ); pctl->gpio.base =-1 ; pctl->gpio.ngpio = pctl->data->npins; pctl->gpio.get_direction = sx150x_gpio_get_direction;
@@ -1180,6 +1179,10 @@ static int sx150x_probe(struct i2c_client *client, pctl->gpio.of_node = dev->of_node;#endif pctl->gpio.can_sleep = true; + pctl->gpio.label =devm_kstrdup (dev, client->name,GFP_KERNEL ); +if (!pctl->gpio.label) +return -ENOMEM ; +/* * Setting multiple pins is not safe when all pins are not * handled by the same regmap register. The oscio pin (present
@@ -1200,13 +1203,15 @@ static int sx150x_probe(struct i2c_client *client,/* Add Interrupt support if an irq is specified */ if (client->irq >0 ) { - pctl->irq_chip.name =devm_kstrdup (dev, client->name, -GFP_KERNEL ); pctl->irq_chip.irq_mask = sx150x_irq_mask; pctl->irq_chip.irq_unmask = sx150x_irq_unmask; pctl->irq_chip.irq_set_type = sx150x_irq_set_type; pctl->irq_chip.irq_bus_lock = sx150x_irq_bus_lock; pctl->irq_chip.irq_bus_sync_unlock = sx150x_irq_bus_sync_unlock; + pctl->irq_chip.name =devm_kstrdup (dev, client->name, +GFP_KERNEL ); +if (!pctl->irq_chip.name) +return -ENOMEM ; pctl->irq.masked = ~0 ; pctl->irq.sense =0 ;
drivers/platform/chrome/cros_ec_proto.c +15 -3
@@ -551,6 +551,7 @@ static int get_keyboard_state_event(struct cros_ec_device *ec_dev)int cros_ec_get_next_event (struct cros_ec_device *ec_dev,bool *wake_event) { +u8 event_type;u32 host_event;int ret;
@@ -570,11 +571,22 @@ int cros_ec_get_next_event(struct cros_ec_device *ec_dev, bool *wake_event)return ret;if (wake_event) { + event_type = ec_dev->event_data.event_type; host_event =cros_ec_get_host_event (ec_dev); -/* Consider non-host_event as wake event */ - *wake_event = !host_event || - !!(host_event & ec_dev->host_event_wake_mask); +/* +* Sensor events need to be parsed by the sensor sub-device. +* Defer them, and don't report the wakeup here. +*/ +if (event_type ==EC_MKBP_EVENT_SENSOR_FIFO ) + *wake_event = false; +/* Masked host-events should not count as wake events. */ +else if (host_event && + !(host_event & ec_dev->host_event_wake_mask)) + *wake_event = false; +/* Consider all other events as wake events. */ +else + *wake_event = true; }return ret;
drivers/ptp/ptp_chardev.c +4 -1
@@ -228,7 +228,9 @@ long ptp_ioctl(struct posix_clock *pc, unsigned int cmd, unsigned long arg) pct->sec = ts.tv_sec; pct->nsec = ts.tv_nsec; pct++; - ptp->info->gettime64 (ptp->info, &ts); + err = ptp->info->gettime64 (ptp->info, &ts); +if (err) + goto out; pct->sec = ts.tv_sec; pct->nsec = ts.tv_nsec; pct++;
@@ -281,6 +283,7 @@ long ptp_ioctl(struct posix_clock *pc, unsigned int cmd, unsigned long arg)break ; } +out:kfree (sysoff);return err; }
drivers/ptp/ptp_clock.c +4 -1
@@ -253,8 +253,10 @@ struct ptp_clock *ptp_clock_register(struct ptp_clock_info *info, ptp->dev =device_create_with_groups (ptp_class, parent, ptp->devid, ptp, ptp->pin_attr_groups,"ptp%d" , ptp->index); -if (IS_ERR (ptp->dev)) +if (IS_ERR (ptp->dev)) { + err =PTR_ERR (ptp->dev); goto no_device; + }/* Register a new PPS source. */ if (info->pps) {
@@ -265,6 +267,7 @@ struct ptp_clock *ptp_clock_register(struct ptp_clock_info *info, pps.owner = info->owner; ptp->pps_source =pps_register_source (&pps,PTP_PPS_DEFAULTS );if (!ptp->pps_source) { + err = -EINVAL ;pr_err ("failed to register pps source\n" ); goto no_pps; }
drivers/s390/crypto/zcrypt_error.h +2 -0
@@ -65,6 +65,7 @@ struct error_hdr {#define REP82_ERROR_FORMAT_FIELD 0x29#define REP82_ERROR_INVALID_COMMAND 0x30#define REP82_ERROR_MALFORMED_MSG 0x40 +#define REP82_ERROR_INVALID_SPECIAL_CMD 0x41#define REP82_ERROR_INVALID_DOMAIN_PRECHECK 0x42#define REP82_ERROR_RESERVED_FIELDO 0x50/* old value */ #define REP82_ERROR_WORD_ALIGNMENT 0x60
@@ -103,6 +104,7 @@ static inline int convert_error(struct zcrypt_queue *zq,case REP88_ERROR_MESSAGE_MALFORMD :case REP82_ERROR_INVALID_DOMAIN_PRECHECK :case REP82_ERROR_INVALID_DOMAIN_PENDING : +case REP82_ERROR_INVALID_SPECIAL_CMD :// REP88_ERROR_INVALID_KEY // '82' CEX2A // REP88_ERROR_OPERAND // '84' CEX2A // REP88_ERROR_OPERAND_EVEN_MOD // '85' CEX2A
drivers/scsi/aic94xx/aic94xx_init.c +4 -4
@@ -281,7 +281,7 @@ static ssize_t asd_show_dev_rev(struct device *dev,return snprintf (buf,PAGE_SIZE ,"%s\n" , asd_dev_rev[asd_ha->revision_id]); } -static DEVICE_ATTR(revision, S_IRUGO, asd_show_dev_rev, NULL); +static DEVICE_ATTR(aic_revision, S_IRUGO, asd_show_dev_rev, NULL);static ssize_t asd_show_dev_bios_build (struct device *dev,struct device_attribute *attr,char *buf)
@@ -478,7 +478,7 @@ static int asd_create_dev_attrs(struct asd_ha_struct *asd_ha) {int err; - err =device_create_file (&asd_ha->pcidev->dev, &dev_attr_revision); + err =device_create_file (&asd_ha->pcidev->dev, &dev_attr_aic_revision);if (err)return err;
@@ -500,13 +500,13 @@ static int asd_create_dev_attrs(struct asd_ha_struct *asd_ha) err_biosb:device_remove_file (&asd_ha->pcidev->dev, &dev_attr_bios_build); err_rev: -device_remove_file (&asd_ha->pcidev->dev, &dev_attr_revision); +device_remove_file (&asd_ha->pcidev->dev, &dev_attr_aic_revision);return err; }static void asd_remove_dev_attrs (struct asd_ha_struct *asd_ha) { -device_remove_file (&asd_ha->pcidev->dev, &dev_attr_revision); +device_remove_file (&asd_ha->pcidev->dev, &dev_attr_aic_revision);device_remove_file (&asd_ha->pcidev->dev, &dev_attr_bios_build);device_remove_file (&asd_ha->pcidev->dev, &dev_attr_pcba_sn);device_remove_file (&asd_ha->pcidev->dev, &dev_attr_update_bios);
drivers/scsi/cxlflash/main.c +2 -0
@@ -3659,6 +3659,7 @@ static int cxlflash_probe(struct pci_dev *pdev, host->max_cmd_len =CXLFLASH_MAX_CDB_LEN ; cfg =shost_priv (host); + cfg->state =STATE_PROBING ; cfg->host = host; rc =alloc_mem (cfg);if (rc) {
@@ -3741,6 +3742,7 @@ static int cxlflash_probe(struct pci_dev *pdev,return rc; out_remove: + cfg->state =STATE_PROBED ;cxlflash_remove (pdev); goto out; }
drivers/scsi/lpfc/lpfc_els.c +24 -28
59 lines not on this page · raw message
drivers/scsi/mpt3sas/mpt3sas_transport.c +5 -2
Lines of this file are not shown. View the raw message.
drivers/thermal/broadcom/bcm2835_thermal.c +11 -0
Lines of this file are not shown. View the raw message.
fs/nfsd/nfs4state.c +51 -6
57 lines not on this page · raw message
scripts/mod/modpost.c +26 -24
50 lines not on this page · raw message
tools/testing/selftests/bpf/test_progs.c +4 -4
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.