Linux 5.15.80
Greg Kroah-Hartman
maintainerI'm announcing the release of the 5.15.80 kernel.
All users of the 5.15 kernel series must upgrade.
The updated 5.15.y git tree can be found at:
git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git linux-5.15.y
and can be browsed at the normal kernel.org git web browser:
https://git.kernel.org/?p=linux/kernel/git/stable/linux-stable.git;a=summary
thanks,
greg k-h
------------
Documentation/process/code-of-conduct-interpretation.rst | 2 Makefile | 2 arch/arm/boot/dts/imx7s.dtsi | 4 arch/arm/boot/dts/sama7g5-pinfunc.h | 2 arch/arm/mach-at91/pm_suspend.S | 7 arch/arm64/boot/dts/freescale/imx8mm.dtsi | 4 arch/arm64/boot/dts/freescale/imx8mn.dtsi | 2 arch/arm64/boot/dts/qcom/sa8155p-adp.dts | 13 + arch/arm64/boot/dts/qcom/sm8150-sony-xperia-kumano.dtsi | 6 arch/arm64/boot/dts/qcom/sm8250-sony-xperia-edo.dtsi | 6 arch/arm64/boot/dts/qcom/sm8350-hdk.dts | 12 + arch/arm64/include/asm/cputype.h | 2 arch/mips/kernel/relocate_kernel.S | 15 -- arch/mips/loongson64/reset.c | 10 + arch/x86/events/intel/pt.c | 9 + arch/x86/include/asm/intel-family.h | 11 + arch/x86/kvm/x86.c | 14 - block/sed-opal.c | 32 +++- drivers/accessibility/speakup/main.c | 2 drivers/acpi/scan.c | 1 drivers/acpi/x86/utils.c | 6 drivers/ata/libata-transport.c | 19 ++ drivers/block/drbd/drbd_main.c | 4 drivers/firmware/arm_scmi/bus.c | 11 + drivers/firmware/arm_scmi/common.h | 1 drivers/firmware/arm_scmi/driver.c | 31 ++-- drivers/firmware/google/coreboot_table.c | 37 +++-- drivers/gpu/drm/amd/display/dc/dcn20/dcn20_hwseq.c | 2 drivers/gpu/drm/amd/display/dc/dcn31/dcn31_hubp.c | 1 drivers/gpu/drm/drm_drv.c | 2 drivers/gpu/drm/drm_internal.h | 3 drivers/gpu/drm/imx/imx-tve.c | 5 drivers/gpu/drm/panel/panel-simple.c | 2 drivers/gpu/drm/vc4/vc4_kms.c | 8 - drivers/i2c/busses/i2c-i801.c | 1 drivers/i2c/busses/i2c-tegra.c | 16 +- drivers/iio/adc/at91_adc.c | 4 drivers/iio/adc/mp2629_adc.c | 5 drivers/iio/pressure/ms5611_spi.c | 2 drivers/iio/trigger/iio-trig-sysfs.c | 6 drivers/infiniband/hw/efa/efa_main.c | 4 drivers/input/joystick/iforce/iforce-main.c | 8 - drivers/input/serio/i8042.c | 4 drivers/iommu/intel/iommu.c | 8 - drivers/iommu/intel/pasid.c | 5 drivers/isdn/mISDN/core.c | 2 drivers/isdn/mISDN/dsp_pipeline.c | 3 drivers/md/dm-ioctl.c | 4 drivers/mfd/lpc_ich.c | 59 +++++++ drivers/misc/vmw_vmci/vmci_queue_pair.c | 2 drivers/mmc/core/core.c | 8 - drivers/mmc/host/sdhci-pci-core.c | 2 drivers/mmc/host/sdhci-pci-o2micro.c | 7 drivers/mtd/spi-nor/controllers/intel-spi-pci.c | 29 ++- drivers/mtd/spi-nor/controllers/intel-spi.c | 51 +++--- drivers/net/ethernet/amazon/ena/ena_netdev.c | 8 - drivers/net/ethernet/atheros/ag71xx.c | 3 drivers/net/ethernet/broadcom/bgmac.c | 1 drivers/net/ethernet/broadcom/bnxt/bnxt.c | 10 + drivers/net/ethernet/cavium/liquidio/lio_main.c | 34 +++- drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c | 10 - drivers/net/ethernet/huawei/hinic/hinic_main.c | 9 + drivers/net/ethernet/microchip/sparx5/sparx5_ethtool.c | 3 drivers/net/ethernet/microchip/sparx5/sparx5_main.c | 3 drivers/net/ethernet/netronome/nfp/nfp_net_ethtool.c | 6 drivers/net/ethernet/pensando/ionic/ionic_main.c | 8 - drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 3 drivers/net/macvlan.c | 6 drivers/net/mhi_net.c | 2 drivers/net/phy/marvell.c | 16 +- drivers/net/thunderbolt.c | 19 +- drivers/nvme/host/ioctl.c | 6 drivers/nvme/host/nvme.h | 16 +- drivers/parport/parport_pc.c | 2 drivers/pinctrl/devicetree.c | 2 drivers/pinctrl/pinctrl-rockchip.c | 40 +++++ drivers/platform/surface/aggregator/ssh_packet_layer.c | 24 ++- drivers/platform/x86/intel/pmc/pltdrv.c | 9 + drivers/s390/scsi/zfcp_fsf.c | 2 drivers/scsi/scsi_debug.c | 6 drivers/scsi/scsi_transport_sas.c | 13 + drivers/siox/siox-core.c | 2 drivers/slimbus/Kconfig | 2 drivers/slimbus/stream.c | 8 - drivers/soc/imx/soc-imx8m.c | 11 + drivers/spi/spi-stm32.c | 1 drivers/target/loopback/tcm_loop.c | 3 drivers/tty/n_gsm.c | 2 drivers/tty/serial/8250/8250_lpss.c | 18 +- drivers/tty/serial/8250/8250_omap.c | 45 +++--- drivers/tty/serial/8250/8250_port.c | 7 drivers/tty/serial/imx.c | 1 drivers/usb/cdns3/host.c | 56 +++---- drivers/usb/chipidea/otg_fsm.c | 2 drivers/usb/core/quirks.c | 3 drivers/usb/dwc3/host.c | 10 - drivers/usb/host/bcma-hcd.c | 10 - drivers/usb/serial/option.c | 19 ++ drivers/usb/typec/mux/intel_pmc_mux.c | 15 +- drivers/xen/pcpu.c | 2 fs/btrfs/raid56.c | 6 fs/btrfs/tests/qgroup-tests.c | 16 -- fs/buffer.c | 4 fs/cifs/ioctl.c | 4 fs/cifs/smb2ops.c | 4 fs/gfs2/ops_fstype.c | 17 +- fs/hugetlbfs/inode.c | 13 - fs/namei.c | 2 fs/nfs/nfs4proc.c | 6 fs/ntfs/attrib.c | 28 +++ fs/ntfs/inode.c | 7 include/linux/platform_data/x86/intel-spi.h | 6 include/linux/ring_buffer.h | 2 include/linux/trace.h | 4 include/linux/wireless.h | 10 + include/net/ip.h | 2 include/net/ipv6.h | 2 include/soc/at91/sama7-ddr.h | 5 include/uapi/linux/ip.h | 6 include/uapi/linux/ipv6.h | 6 kernel/bpf/percpu_freelist.c | 23 +-- kernel/bpf/verifier.c | 14 + kernel/events/core.c | 25 ++- kernel/kprobes.c | 8 - kernel/trace/ftrace.c | 5 kernel/trace/kprobe_event_gen_test.c | 48 ++++-- kernel/trace/ring_buffer.c | 71 ++++++--- kernel/trace/synth_event_gen_test.c | 16 -- kernel/trace/trace.c | 3 kernel/trace/trace_eprobe.c | 3 kernel/trace/trace_events_synth.c | 5 mm/filemap.c | 2 mm/hugetlb.c | 4 mm/maccess.c | 2 mm/memory-failure.c | 111 ++++++++++----- mm/shmem.c | 51 ++++++ mm/userfaultfd.c | 5 net/9p/trans_fd.c | 45 +++--- net/bluetooth/l2cap_core.c | 2 net/bpf/test_run.c | 1 net/bridge/br_vlan.c | 17 +- net/caif/chnl_net.c | 3 net/dsa/dsa_priv.h | 1 net/dsa/master.c | 3 net/dsa/port.c | 16 ++ net/ipv4/tcp_cdg.c | 2 net/kcm/kcmsock.c | 62 +------- net/wireless/wext-core.c | 17 +- net/x25/x25_dev.c | 2 sound/pci/hda/patch_realtek.c | 2 sound/soc/codecs/jz4725b.c | 34 ++-- sound/soc/codecs/mt6660.c | 8 - sound/soc/codecs/rt1019.c | 20 +- sound/soc/codecs/rt1019.h | 6 sound/soc/codecs/rt1308-sdw.h | 2 sound/soc/codecs/tas2764.c | 19 -- sound/soc/codecs/tas2770.c | 20 -- sound/soc/codecs/wm5102.c | 6 sound/soc/codecs/wm5110.c | 6 sound/soc/codecs/wm8962.c | 54 +++++++ sound/soc/codecs/wm8997.c | 6 sound/soc/intel/boards/sof_sdw.c | 11 + sound/soc/soc-core.c | 17 ++ sound/soc/soc-utils.c | 2 sound/usb/midi.c | 4 tools/testing/selftests/futex/functional/Makefile | 6 tools/testing/selftests/intel_pstate/Makefile | 6 167 files changed, 1331 insertions(+), 611 deletions(-)
Aashish Sharma (1):
tracing: Fix warning on variable 'struct trace_array'
Adrian Hunter (1):
perf/x86/intel/pt: Fix sampling using single range output
Aishwarya Kothari (1):
drm/panel: simple: set bpc field for logic technologies displays
Alban Crequy (1):
maccess: Fix writing offset in case of fault in strncpy_from_kernel_nofault()
Alexander Potapenko (2):
misc/vmw_vmci: fix an infoleak in vmci_host_do_receive_datagram()
mm: fs: initialize fsdata passed to write_begin/write_end interface
Aminuddin Jamaluddin (1):
net: phy: marvell: add sleep time after enabling the loopback bit
Anastasia Belova (2):
cifs: add check for returning value of SMB2_close_init
cifs: add check for returning value of SMB2_set_info_init
Andreas Gruenbacher (1):
gfs2: Switch from strlcpy to strscpy
Andrew Price (1):
gfs2: Check sb_bsize_shift after reading superblock
Baisong Zhong (1):
bpf, test_run: Fix alignment problem in bpf_prog_test_run_skb()
Benjamin Block (1):
scsi: zfcp: Fix double free of FSF request when qdio send fails
Benjamin Coddington (1):
NFSv4: Retry LOCK on OLD_STATEID during delegation return
Benoît Monin (1):
USB: serial: option: add Sierra Wireless EM9191
Brian Norris (1):
firmware: coreboot: Register bus in module init
Chen Jun (1):
Input: i8042 - fix leaking of platform device on module removal
Chen Zhongjin (2):
ASoC: core: Fix use-after-free in snd_soc_exit()
ASoC: soc-utils: Remove __exit for snd_soc_util_exit()
Chevron Li (1):
mmc: sdhci-pci-o2micro: fix card detect fail issue caused by CD# debounce timeout
Chuang Wang (1):
net: macvlan: Use built-in RCU list checking
Claudiu Beznea (1):
ARM: at91: pm: avoid soft resetting AC DLL
Colin Ian King (1):
ASoC: codecs: jz4725b: Fix spelling mistake "Sourc" -> "Source", "Routee" -> "Route"
Cong Wang (1):
kcm: close race conditions on sk_receive_queue
Cristian Marussi (1):
firmware: arm_scmi: Cleanup the core driver removal callback
D Scott Phillips (1):
arm64: Fix bit-shifting UB in the MIDR_CPU_MODEL() macro
Dan Carpenter (1):
drbd: use after free in drbd_create_device()
Daniil Tatianin (1):
ring_buffer: Do not deactivate non-existant pages
Davide Tronchin (3):
USB: serial: option: remove old LARA-R6 PID
USB: serial: option: add u-blox LARA-R6 00B modem
USB: serial: option: add u-blox LARA-L6 modem
Derek Fang (1):
ASoC: rt1019: Fix the TDM settings
Dominique Martinet (2):
9p: trans_fd/p9_conn_cancel: drop client lock earlier net/9p: use a dedicated spinlock for trans_fd
Douglas Anderson (4):
arm64: dts: qcom: sa8155p-adp: Specify which LDO modes are allowed
arm64: dts: qcom: sm8150-xperia-kumano: Specify which LDO modes are allowed
arm64: dts: qcom: sm8250-xperia-edo: Specify which LDO modes are allowed
arm64: dts: qcom: sm8350-hdk: Specify which LDO modes are allowed
Duoming Zhou (2):
tty: n_gsm: fix sleep-in-atomic-context bug in gsm_control_send
usb: chipidea: fix deadlock in ci_otg_del_timer
Emil Flink (1):
ALSA: hda/realtek: fix speakers for Samsung Galaxy Book Pro
Eric Dumazet (3):
macvlan: enforce a consistent minimal mtu
tcp: cdg: allow tcp_cdg_release() to be called multiple times
kcm: avoid potential race in kcm_tx_work
Filipe Manana (1):
btrfs: remove pointless and double ulist frees in error paths of qgroup tests
Gaosheng Cui (2):
drm/vc4: kms: Fix IS_ERR() vs NULL check for vc4_kms
bnxt_en: Remove debugfs when pci_register_driver failed
Greg Kroah-Hartman (1):
Linux 5.15.80
Guangbin Huang (1):
net: hns3: fix setting incorrect phy link ksettings for firmware in resetting process
Hangbin Liu (1):
net: use struct_group to copy ip/ipv6 header addresses
Hans de Goede (1):
ACPI: scan: Add LATT2021 to acpi_ignore_dep_ids[]
Hawkins Jiawei (4):
wifi: wext: use flex array destination for memcpy()
ntfs: fix use-after-free in ntfs_attr_find()
ntfs: fix out-of-bounds read in ntfs_attr_find()
ntfs: check overflow when iterating ATTR_RECORDs
Ido Schimmel (1):
bridge: switchdev: Fix memory leaks when changing VLAN protocol
Ilpo Järvinen (4):
serial: 8250: Fall back to non-DMA Rx if IIR_RDI occurs
serial: 8250: Flush DMA Rx on RLSI
serial: 8250_lpss: Configure DMA also w/o DMA filter
serial: 8250_lpss: Use 16B DMA burst with Elkhart Lake
Jaco Coetzee (1):
nfp: change eeprom length to max length enumerators
James Houghton (1):
hugetlbfs: don't delete error page from pagecache
Johan Hovold (1):
Revert "usb: dwc3: disable USB core PHY management"
Keith Busch (2):
nvme: restrict management ioctls to admin
nvme: ensure subsystem reset is single threaded
Krzysztof Kozlowski (1):
slimbus: stream: correct presence rate frequencies
Li Huafei (1):
kprobes: Skip clearing aggrprobe's post_handler in kprobe-on-ftrace case
Li Jun (1):
usb: cdns3: host: fix endless superspeed hub port reset
Liao Chang (1):
MIPS: Loongson64: Add WARN_ON on kexec related kmalloc failed
Like Xu (1):
KVM: x86/pmu: Do not speculatively query Intel GP PMCs that don't exist yet
Linus Walleij (1):
USB: bcma: Make GPIO explicitly optional
Liu Jian (1):
net: ag71xx: call phylink_disconnect_phy if ag71xx_hw_enable() fail in ag71xx_open()
Luiz Augusto von Dentz (1):
Bluetooth: L2CAP: Fix l2cap_global_chan_by_psm
Maciej W. Rozycki (1):
parport_pc: Avoid FIFO port location truncation
Marco Elver (1):
perf: Improve missing SIGTRAP checking
Marek Vasut (4):
spi: stm32: Print summary 'callbacks suppressed' message
ARM: dts: imx7: Fix NAND controller size-cells
arm64: dts: imx8mm: Fix NAND controller size-cells
arm64: dts: imx8mn: Fix NAND controller size-cells
Mario Limonciello (1):
ACPI: x86: Add another system to quirk list for forcing StorageD3Enable
Martin Povišer (2):
ASoC: tas2770: Fix set_tdm_slot in case of single slot
ASoC: tas2764: Fix set_tdm_slot in case of single slot
Matthias Schiffer (1):
serial: 8250_omap: remove wait loop from Errata i202 workaround
Mauro Lima (1):
spi: intel: Fix the offset to get the 64K erase opcode
Maximilian Luz (1):
platform/surface: aggregator: Do not check for repeated unsequenced packets
Michael Margolin (1):
RDMA/efa: Add EFA 0xefa2 PCI ID
Mihai Sain (1):
ARM: dts: at91: sama7g5: fix signal name of pin PB2
Mika Westerberg (2):
mtd: spi-nor: intel-spi: Disable write protection only if asked
spi: intel: Use correct mask for flash and protected regions
Mikulas Patocka (1):
dm ioctl: fix misbehavior if list_versions races with module loading
Mitja Spes (1):
iio: pressure: ms5611: changed hardcoded SPI speed to value limited
Mohd Faizal Abdul Rahim (1):
net: stmmac: ensure tx function is not running in stmmac_xdp_release()
Mushahid Hussain (1):
speakup: fix a segfault caused by switching consoles
Nam Cao (1):
i2c: i801: add lis3lv02d's I2C address for Vostro 5568
Nathan Huckleberry (1):
drm/imx: imx-tve: Fix return type of imx_tve_connector_mode_valid
Nicolas Dumazet (1):
usb: add NO_LPM quirk for Realforce 87U Keyboard
Pierre-Louis Bossart (1):
ASoC: Intel: sof_sdw: add quirk variant for LAPBC710 NUC15
Qu Wenruo (1):
btrfs: raid56: properly handle the error when unable to find the missing stripe
Quentin Schulz (1):
pinctrl: rockchip: list all pins in a possible mux route for PX30
Rajat Khandelwal (1):
usb: typec: mux: Enter safe mode only when pins need to be reconfigured
Reinhard Speyerer (1):
USB: serial: option: add Fibocom FM160 0x0111 composition
Ricardo Cañuelo (2):
selftests/futex: fix build for clang selftests/intel_pstate: fix build for ARCH=x86_64
Rodrigo Siqueira (2):
drm/amd/display: Remove wrong pipe control lock drm/amd/display: Add HUBP surface flip interrupt handler
Roger Pau Monné (1):
platform/x86/intel: pmc: Don't unconditionally attach Intel PMC when virtualized
Rongwei Zhang (1):
MIPS: fix duplicate definitions for exported symbols
Saravanan Sekar (2):
iio: adc: mp2629: fix wrong comparison of channel
iio: adc: mp2629: fix potential array out of bound access
Serge Semin (1):
block: sed-opal: kmalloc the cmd/resp buffers
Shang XiaoJing (7):
drm/drv: Fix potential memory leak in drm_dev_init()
drm: Fix potential null-ptr-deref in drm_vblank_destroy_worker()
net: microchip: sparx5: Fix potential null-ptr-deref in sparx_stats_init() and sparx5_start()
tracing: Fix memory leak in test_gen_synth_cmd() and test_empty_synth_event()
tracing: Fix wild-memory-access in register_synth_event()
tracing: kprobe: Fix potential null-ptr-deref on trace_event_file in kprobe_event_gen_test_exit()
tracing: kprobe: Fix potential null-ptr-deref on trace_array in kprobe_event_gen_test_exit()
Shawn Guo (1):
serial: imx: Add missing .thaw_noirq hook
Shuah Khan (1):
docs: update mediator contact information in CoC doc
Shuming Fan (1):
ASoC: rt1308-sdw: add the default value of some registers
Siarhei Volkau (4):
ASoC: codecs: jz4725b: add missed Line In power control bit
ASoC: codecs: jz4725b: fix reported volume for Master ctl
ASoC: codecs: jz4725b: use right control for Capture Volume
ASoC: codecs: jz4725b: fix capture selector naming
Steven Rostedt (Google) (3):
tracing/ring-buffer: Have polling block on watermark
tracing: Fix race where eprobes can be called before the event
ring-buffer: Include dropped pages in counting dirty patches
Takashi Iwai (2):
ALSA: usb-audio: Drop snd_BUG_ON() from snd_usbmidi_output_open()
ALSA: hda/realtek: Fix the speaker output on Samsung Galaxy Book Pro 360
Tetsuo Handa (2):
Input: iforce - invert valid length check when fetching device IDs 9p/trans_fd: always use O_NONBLOCK read/write
Thierry Reding (1):
i2c: tegra: Allocate DMA memory for DMA engine
Tina Zhang (2):
iommu/vt-d: Preset Access bit for IOVA in FL non-leaf paging entries iommu/vt-d: Set SRE bit only when hardware has SRS cap
Tony Lindgren (3):
serial: 8250: omap: Fix missing PM runtime calls for omap8250_set_mctrl()
serial: 8250: omap: Fix unpaired pm_runtime_put_sync() in omap8250_remove()
serial: 8250: omap: Flush PM QOS work on remove
Tony Luck (1):
x86/cpu: Add several Intel server CPU model numbers
Vladimir Oltean (1):
net: dsa: make dsa_master_ioctl() see through port_hwtstamp_get() shims
Wang ShaoBo (1):
mISDN: fix misuse of put_device() in mISDN_register_device()
Wang Wensheng (2):
ftrace: Fix the possible incorrect kernel message
ftrace: Optimize the allocation for mcount entries
Wang Yufen (2):
bpf: Fix memory leaks in __check_func_call
tracing: Fix memory leak in tracing_read_pipe()
Wei Yongjun (3):
net: bgmac: Drop free_netdev() from bgmac_enet_remove()
net: mhi: Fix memory leak in mhi_net_dellink() net/x25: Fix skb leak in x25_lapb_receive_frame()
Xiaolei Wang (2):
ASoC: wm8962: Add an event handler for TEMP_HP and TEMP_SPK
soc: imx8m: Enable OCOTP clock before reading the register
Xiongfeng Wang (1):
mmc: sdhci-pci: Fix possible memory leak caused by missing pci_dev_put()
Xiu Jianfeng (1):
ftrace: Fix null pointer dereference in ftrace_add_mod()
Xu Kuohai (1):
bpf: Initialize same number of free nodes for each pcpu_freelist
Yang Shi (3):
mm: hwpoison: refactor refcount check handling
mm: hwpoison: handle non-anonymous THP correctly
mm: shmem: don't truncate page if memory failure happens
Yang Yingliang (11):
scsi: scsi_transport_sas: Fix error handling in sas_phy_add()
siox: fix possible memory leak in siox_device_add()
ata: libata-transport: fix double ata_host_put() in ata_tport_add()
ata: libata-transport: fix error handling in ata_tport_add()
ata: libata-transport: fix error handling in ata_tlink_add()
ata: libata-transport: fix error handling in ata_tdev_add()
mISDN: fix possible memory leak in mISDN_dsp_element_register() xen/pcpu: fix possible memory leak in register_pcpu()
iio: adc: at91_adc: fix possible memory leak in at91_adc_allocate_trigger()
iio: trigger: sysfs: fix possible memory leak in iio_sysfs_trig_init()
scsi: target: tcm_loop: Fix possible name leak in tcm_loop_setup_hba_bus()
Yann Gautier (1):
mmc: core: properly select voltage range without power cycle
Yuan Can (5):
net: hinic: Fix error handling in hinic_module_init()
net: ionic: Fix error handling in ionic_init_module()
net: ena: Fix error handling in ena_init()
net: thunderbolt: Fix error handling in tbnet_init()
scsi: scsi_debug: Fix possible UAF in sdebug_add_host_helper()
Zeng Heng (1):
pinctrl: devicetree: fix null pointer dereferencing in pinctrl_dt_to_map
Zhang Qilong (4):
ASoC: wm5102: Revert "ASoC: wm5102: Fix PM disable depth imbalance in wm5102_probe"
ASoC: wm5110: Revert "ASoC: wm5110: Fix PM disable depth imbalance in wm5110_probe"
ASoC: wm8997: Revert "ASoC: wm8997: Fix PM disable depth imbalance in wm8997_probe"
ASoC: mt6660: Keep the pm_runtime enables before component stuff in mt6660_i2c_probe
Zhang Xiaoxu (1):
cifs: Fix wrong return value checking when GETFLAGS
Zheng Bin (1):
slimbus: qcom-ngd: Fix build error when CONFIG_SLIM_QCOM_NGD_CTRL=y && CONFIG_QCOM_RPROC_COMMON=m
Zhengchao Shao (2):
net: liquidio: release resources when liquidio driver open failed
net: caif: fix double disconnect client in chnl_net_open()
Greg Kroah-Hartman
maintainerDocumentation/process/code-of-conduct-interpretation.rst +1 -1
@@ -51,7 +51,7 @@ the Technical Advisory Board (TAB) or other maintainers if you're uncertain how to handle situations that come up. It will not be considered a violation report unless you want it to be. If you are uncertain about approaching the TAB or any other maintainers, please -reach out to our conflict mediator, Joanna Lee <[email protected]>. +reach out to our conflict mediator, Joanna Lee <[email protected]>. In the end, "be kind to each other" is really what the end goal is for everybody. We know everyone is human and we all fail at times, but the
Makefile +1 -1
@@ -1,7 +1,7 @@ # SPDX-License-Identifier: GPL-2.0 VERSION = 5 PATCHLEVEL = 15 -SUBLEVEL = 79 +SUBLEVEL = 80 EXTRAVERSION = NAME = Trick or Treat
arch/arm/boot/dts/imx7s.dtsi +2 -2
@@ -1252,10 +1252,10 @@ dma_apbh: dma-apbh@33000000 { clocks = <&clks IMX7D_NAND_USDHC_BUS_RAWNAND_CLK>; }; - gpmi: nand-controller@33002000{ + gpmi: nand-controller@33002000 { compatible = "fsl,imx7d-gpmi-nand"; #address-cells = <1>; - #size-cells = <1>; + #size-cells = <0>; reg = <0x33002000 0x2000>, <0x33004000 0x4000>; reg-names = "gpmi-nand", "bch"; interrupts = <GIC_SPI 14 IRQ_TYPE_LEVEL_HIGH>;
arch/arm/boot/dts/sama7g5-pinfunc.h +1 -1
@@ -261,7 +261,7 @@#define PIN_PB2__FLEXCOM6_IO0 PINMUX_PIN(PIN_PB2, 2, 1)#define PIN_PB2__ADTRG PINMUX_PIN(PIN_PB2, 3, 1)#define PIN_PB2__A20 PINMUX_PIN(PIN_PB2, 4, 1) -#define PIN_PB2__FLEXCOM11_IO0 PINMUX_PIN(PIN_PB2, 6, 3) +#define PIN_PB2__FLEXCOM11_IO1 PINMUX_PIN(PIN_PB2, 6, 3)#define PIN_PB3 35#define PIN_PB3__GPIO PINMUX_PIN(PIN_PB3, 0, 0)#define PIN_PB3__RF1 PINMUX_PIN(PIN_PB3, 1, 1)
arch/arm/mach-at91/pm_suspend.S +6 -1
@@ -169,10 +169,15 @@ sr_ena_2: cmp tmp1, #UDDRC_STAT_SELFREF_TYPE_SW bne sr_ena_2 - /* Put DDR PHY's DLL in bypass mode for non-backup modes. */ + /* Disable DX DLLs for non-backup modes. */ cmp r7, #AT91_PM_BACKUP beq sr_ena_3 + /* Do not soft reset the AC DLL. */ + ldr tmp1, [r3, DDR3PHY_ACDLLCR] + bic tmp1, tmp1, DDR3PHY_ACDLLCR_DLLSRST + str tmp1, [r3, DDR3PHY_ACDLLCR] + /* Disable DX DLLs. */ ldr tmp1, [r3, #DDR3PHY_DX0DLLCR] orr tmp1, tmp1, #DDR3PHY_DXDLLCR_DLLDIS
arch/arm64/boot/dts/freescale/imx8mm.dtsi +2 -2
@@ -1014,10 +1014,10 @@ dma_apbh: dma-controller@33000000 { clocks = <&clk IMX8MM_CLK_NAND_USDHC_BUS_RAWNAND_CLK>; }; - gpmi: nand-controller@33002000{ + gpmi: nand-controller@33002000 { compatible = "fsl,imx8mm-gpmi-nand", "fsl,imx7d-gpmi-nand"; #address-cells = <1>; - #size-cells = <1>; + #size-cells = <0>; reg = <0x33002000 0x2000>, <0x33004000 0x4000>; reg-names = "gpmi-nand", "bch"; interrupts = <GIC_SPI 14 IRQ_TYPE_LEVEL_HIGH>;
arch/arm64/boot/dts/freescale/imx8mn.dtsi +1 -1
@@ -998,7 +998,7 @@ dma_apbh: dma-controller@33000000 { gpmi: nand-controller@33002000 { compatible = "fsl,imx8mn-gpmi-nand", "fsl,imx7d-gpmi-nand"; #address-cells = <1>; - #size-cells = <1>; + #size-cells = <0>; reg = <0x33002000 0x2000>, <0x33004000 0x4000>; reg-names = "gpmi-nand", "bch"; interrupts = <GIC_SPI 14 IRQ_TYPE_LEVEL_HIGH>;
arch/arm64/boot/dts/qcom/sa8155p-adp.dts +12 -1
@@ -43,7 +43,6 @@ vreg_s4a_1p8: smps4 { regulator-always-on; regulator-boot-on; - regulator-allow-set-load; vin-supply = <&vreg_3p3>; };
@@ -114,6 +113,9 @@ vreg_l5a_0p88: ldo5 { regulator-max-microvolt = <880000>; regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>; regulator-allow-set-load; + regulator-allowed-modes = + <RPMH_REGULATOR_MODE_LPM + RPMH_REGULATOR_MODE_HPM>; }; vreg_l7a_1p8: ldo7 {
@@ -129,6 +131,9 @@ vreg_l10a_2p96: ldo10 { regulator-max-microvolt = <2960000>; regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>; regulator-allow-set-load; + regulator-allowed-modes = + <RPMH_REGULATOR_MODE_LPM + RPMH_REGULATOR_MODE_HPM>; }; vreg_l11a_0p8: ldo11 {
@@ -235,6 +240,9 @@ vreg_l5c_1p2: ldo5 { regulator-max-microvolt = <1200000>; regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>; regulator-allow-set-load; + regulator-allowed-modes = + <RPMH_REGULATOR_MODE_LPM + RPMH_REGULATOR_MODE_HPM>; }; vreg_l7c_1p8: ldo7 {
@@ -250,6 +258,9 @@ vreg_l8c_1p2: ldo8 { regulator-max-microvolt = <1200000>; regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>; regulator-allow-set-load; + regulator-allowed-modes = + <RPMH_REGULATOR_MODE_LPM + RPMH_REGULATOR_MODE_HPM>; }; vreg_l10c_3p3: ldo10 {
arch/arm64/boot/dts/qcom/sm8150-sony-xperia-kumano.dtsi +6 -0
@@ -348,6 +348,9 @@ vreg_l6c_2p9: ldo6 { regulator-max-microvolt = <2960000>; regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>; regulator-allow-set-load; + regulator-allowed-modes = + <RPMH_REGULATOR_MODE_LPM + RPMH_REGULATOR_MODE_HPM>; }; vreg_l7c_3p0: ldo7 {
@@ -367,6 +370,9 @@ vreg_l9c_2p9: ldo9 { regulator-max-microvolt = <2960000>; regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>; regulator-allow-set-load; + regulator-allowed-modes = + <RPMH_REGULATOR_MODE_LPM + RPMH_REGULATOR_MODE_HPM>; }; vreg_l10c_3p3: ldo10 {
arch/arm64/boot/dts/qcom/sm8250-sony-xperia-edo.dtsi +6 -0
@@ -317,6 +317,9 @@ vreg_l6c_2p9: ldo6 { regulator-max-microvolt = <2960000>; regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>; regulator-allow-set-load; + regulator-allowed-modes = + <RPMH_REGULATOR_MODE_LPM + RPMH_REGULATOR_MODE_HPM>; }; vreg_l7c_2p85: ldo7 {
@@ -339,6 +342,9 @@ vreg_l9c_2p9: ldo9 { regulator-max-microvolt = <2960000>; regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>; regulator-allow-set-load; + regulator-allowed-modes = + <RPMH_REGULATOR_MODE_LPM + RPMH_REGULATOR_MODE_HPM>; }; vreg_l10c_3p3: ldo10 {
arch/arm64/boot/dts/qcom/sm8350-hdk.dts +12 -0
@@ -108,6 +108,9 @@ vreg_l5b_0p88: ldo5 { regulator-max-microvolt = <888000>; regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>; regulator-allow-set-load; + regulator-allowed-modes = + <RPMH_REGULATOR_MODE_LPM + RPMH_REGULATOR_MODE_HPM>; }; vreg_l6b_1p2: ldo6 {
@@ -116,6 +119,9 @@ vreg_l6b_1p2: ldo6 { regulator-max-microvolt = <1208000>; regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>; regulator-allow-set-load; + regulator-allowed-modes = + <RPMH_REGULATOR_MODE_LPM + RPMH_REGULATOR_MODE_HPM>; }; vreg_l7b_2p96: ldo7 {
@@ -124,6 +130,9 @@ vreg_l7b_2p96: ldo7 { regulator-max-microvolt = <2504000>; regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>; regulator-allow-set-load; + regulator-allowed-modes = + <RPMH_REGULATOR_MODE_LPM + RPMH_REGULATOR_MODE_HPM>; }; vreg_l9b_1p2: ldo9 {
@@ -132,6 +141,9 @@ vreg_l9b_1p2: ldo9 { regulator-max-microvolt = <1200000>; regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>; regulator-allow-set-load; + regulator-allowed-modes = + <RPMH_REGULATOR_MODE_LPM + RPMH_REGULATOR_MODE_HPM>; }; };
arch/arm64/include/asm/cputype.h +1 -1
@@ -41,7 +41,7 @@ (((midr) & MIDR_IMPLEMENTOR_MASK) >> MIDR_IMPLEMENTOR_SHIFT)#define MIDR_CPU_MODEL (imp, partnum) \ - (((imp) << MIDR_IMPLEMENTOR_SHIFT) | \ + ((_AT(u32, imp) << MIDR_IMPLEMENTOR_SHIFT) | \ (0xf << MIDR_ARCHITECTURE_SHIFT) | \ ((partnum) << MIDR_PARTNUM_SHIFT))
arch/mips/kernel/relocate_kernel.S +5 -10
@@ -145,8 +145,7 @@ LEAF(kexec_smp_wait) * kexec_args[0..3] are used to prepare register values. */ -kexec_args: - EXPORT(kexec_args) +EXPORT(kexec_args) arg0: PTR_WD 0x0 arg1: PTR_WD 0x0 arg2: PTR_WD 0x0
@@ -159,8 +158,7 @@ arg3: PTR_WD 0x0 * their registers a0-a3. secondary_kexec_args[0..3] are used * to prepare register values. */ -secondary_kexec_args: - EXPORT(secondary_kexec_args) +EXPORT(secondary_kexec_args) s_arg0: PTR_WD 0x0 s_arg1: PTR_WD 0x0 s_arg2: PTR_WD 0x0
@@ -171,19 +169,16 @@ kexec_flag: #endif -kexec_start_address: - EXPORT(kexec_start_address) +EXPORT(kexec_start_address) PTR_WD 0x0 .size kexec_start_address, PTRSIZE -kexec_indirection_page: - EXPORT(kexec_indirection_page) +EXPORT(kexec_indirection_page) PTR_WD 0 .size kexec_indirection_page, PTRSIZE relocate_new_kernel_end: -relocate_new_kernel_size: - EXPORT(relocate_new_kernel_size) +EXPORT(relocate_new_kernel_size) PTR_WD relocate_new_kernel_end - relocate_new_kernel .size relocate_new_kernel_size, PTRSIZE
arch/mips/loongson64/reset.c +10 -0
@@ -16,6 +16,7 @@#include <asm/bootinfo.h> #include <asm/idle.h> #include <asm/reboot.h> +#include <asm/bug.h> #include <loongson.h> #include <boot_param.h>
@@ -159,8 +160,17 @@ static int __init mips_reboot_setup(void)#ifdef CONFIG_KEXEC kexec_argv =kmalloc (KEXEC_ARGV_SIZE ,GFP_KERNEL ); +if (WARN_ON (!kexec_argv)) +return -ENOMEM ; + kdump_argv =kmalloc (KEXEC_ARGV_SIZE ,GFP_KERNEL ); +if (WARN_ON (!kdump_argv)) +return -ENOMEM ; + kexec_envp =kmalloc (KEXEC_ENVP_SIZE ,GFP_KERNEL ); +if (WARN_ON (!kexec_envp)) +return -ENOMEM ; + fw_arg1 =KEXEC_ARGV_ADDR ;memcpy (kexec_envp, (void *)fw_arg2,KEXEC_ENVP_SIZE );
arch/x86/events/intel/pt.c +9 -0
@@ -1247,6 +1247,15 @@ static int pt_buffer_try_single(struct pt_buffer *buf, int nr_pages)if (1 << order != nr_pages) goto out; +/* +* Some processors cannot always support single range for more than +* 4KB - refer errata TGL052, ADL037 and RPL017. Future processors might +* also be affected, so for now rather than trying to keep track of +* which ones, just disable it for all. +*/ +if (nr_pages >1 ) + goto out; + buf->single = true; buf->nr_pages = nr_pages; ret =0 ;
arch/x86/include/asm/intel-family.h +10 -1
@@ -105,10 +105,15 @@#define INTEL_FAM6_SAPPHIRERAPIDS_X 0x8F/* Golden Cove */ +#define INTEL_FAM6_EMERALDRAPIDS_X 0xCF + +#define INTEL_FAM6_GRANITERAPIDS_X 0xAD +#define INTEL_FAM6_GRANITERAPIDS_D 0xAE +#define INTEL_FAM6_ALDERLAKE 0x97/* Golden Cove / Gracemont */ #define INTEL_FAM6_ALDERLAKE_L 0x9A/* Golden Cove / Gracemont */ -/* "Small Core" Processors (Atom) */ +/* "Small Core" Processors (Atom/E-Core) */ #define INTEL_FAM6_ATOM_BONNELL 0x1C/* Diamondville, Pineview */ #define INTEL_FAM6_ATOM_BONNELL_MID 0x26/* Silverthorne, Lincroft */
@@ -135,6 +140,10 @@#define INTEL_FAM6_ATOM_TREMONT 0x96/* Elkhart Lake */ #define INTEL_FAM6_ATOM_TREMONT_L 0x9C/* Jasper Lake */ +#define INTEL_FAM6_SIERRAFOREST_X 0xAF + +#define INTEL_FAM6_GRANDRIDGE 0xB6 +/* Xeon Phi */ #define INTEL_FAM6_XEON_PHI_KNL 0x57/* Knights Landing */
arch/x86/kvm/x86.c +2 -12
@@ -1347,20 +1347,10 @@ static const u32 msrs_to_save_all[] = {MSR_ARCH_PERFMON_PERFCTR0 +2 ,MSR_ARCH_PERFMON_PERFCTR0 +3 ,MSR_ARCH_PERFMON_PERFCTR0 +4 ,MSR_ARCH_PERFMON_PERFCTR0 +5 ,MSR_ARCH_PERFMON_PERFCTR0 +6 ,MSR_ARCH_PERFMON_PERFCTR0 +7 , -MSR_ARCH_PERFMON_PERFCTR0 +8 ,MSR_ARCH_PERFMON_PERFCTR0 +9 , -MSR_ARCH_PERFMON_PERFCTR0 +10 ,MSR_ARCH_PERFMON_PERFCTR0 +11 , -MSR_ARCH_PERFMON_PERFCTR0 +12 ,MSR_ARCH_PERFMON_PERFCTR0 +13 , -MSR_ARCH_PERFMON_PERFCTR0 +14 ,MSR_ARCH_PERFMON_PERFCTR0 +15 , -MSR_ARCH_PERFMON_PERFCTR0 +16 ,MSR_ARCH_PERFMON_PERFCTR0 +17 ,MSR_ARCH_PERFMON_EVENTSEL0 ,MSR_ARCH_PERFMON_EVENTSEL1 ,MSR_ARCH_PERFMON_EVENTSEL0 +2 ,MSR_ARCH_PERFMON_EVENTSEL0 +3 ,MSR_ARCH_PERFMON_EVENTSEL0 +4 ,MSR_ARCH_PERFMON_EVENTSEL0 +5 ,MSR_ARCH_PERFMON_EVENTSEL0 +6 ,MSR_ARCH_PERFMON_EVENTSEL0 +7 , -MSR_ARCH_PERFMON_EVENTSEL0 +8 ,MSR_ARCH_PERFMON_EVENTSEL0 +9 , -MSR_ARCH_PERFMON_EVENTSEL0 +10 ,MSR_ARCH_PERFMON_EVENTSEL0 +11 , -MSR_ARCH_PERFMON_EVENTSEL0 +12 ,MSR_ARCH_PERFMON_EVENTSEL0 +13 , -MSR_ARCH_PERFMON_EVENTSEL0 +14 ,MSR_ARCH_PERFMON_EVENTSEL0 +15 , -MSR_ARCH_PERFMON_EVENTSEL0 +16 ,MSR_ARCH_PERFMON_EVENTSEL0 +17 ,MSR_K7_EVNTSEL0 ,MSR_K7_EVNTSEL1 ,MSR_K7_EVNTSEL2 ,MSR_K7_EVNTSEL3 , MSR_K7_PERFCTR0, MSR_K7_PERFCTR1, MSR_K7_PERFCTR2, MSR_K7_PERFCTR3,
@@ -6449,12 +6439,12 @@ static void kvm_init_msr_list(void) intel_pt_validate_hw_cap(PT_CAP_num_address_ranges) * 2)continue ;break ; - case MSR_ARCH_PERFMON_PERFCTR0 ... MSR_ARCH_PERFMON_PERFCTR0 + 17: + case MSR_ARCH_PERFMON_PERFCTR0 ... MSR_ARCH_PERFMON_PERFCTR0 + 7:if (msrs_to_save_all[i] -MSR_ARCH_PERFMON_PERFCTR0 >=min (INTEL_PMC_MAX_GENERIC , x86_pmu.num_counters_gp))continue ;break ; - case MSR_ARCH_PERFMON_EVENTSEL0 ... MSR_ARCH_PERFMON_EVENTSEL0 + 17: + case MSR_ARCH_PERFMON_EVENTSEL0 ... MSR_ARCH_PERFMON_EVENTSEL0 + 7:if (msrs_to_save_all[i] -MSR_ARCH_PERFMON_EVENTSEL0 >=min (INTEL_PMC_MAX_GENERIC , x86_pmu.num_counters_gp))continue ;
block/sed-opal.c +28 -4
@@ -88,8 +88,8 @@ struct opal_dev {u64 lowest_lba;size_t pos; -u8 cmd[IO_BUFFER_LENGTH ]; -u8 resp[IO_BUFFER_LENGTH ]; +u8 *cmd; +u8 *resp;struct parsed_resp parsed;size_t prev_d_len;
@@ -2134,6 +2134,8 @@ void free_opal_dev(struct opal_dev *dev)return ;clean_opal_dev (dev); +kfree (dev->resp); +kfree (dev->cmd);kfree (dev); }EXPORT_SYMBOL (free_opal_dev);
@@ -2146,17 +2148,39 @@ struct opal_dev *init_opal_dev(void *data, sec_send_recv *send_recv)if (!dev)return NULL ; +/* +* Presumably DMA-able buffers must be cache-aligned. Kmalloc makes +* sure the allocated buffer is DMA-safe in that regard. +*/ + dev->cmd =kmalloc (IO_BUFFER_LENGTH ,GFP_KERNEL ); +if (!dev->cmd) + goto err_free_dev; + + dev->resp =kmalloc (IO_BUFFER_LENGTH ,GFP_KERNEL ); +if (!dev->resp) + goto err_free_cmd; +INIT_LIST_HEAD (&dev->unlk_lst);mutex_init (&dev->dev_lock); dev->data = data; dev->send_recv = send_recv;if (check_opal_support (dev) !=0 ) {pr_debug ("Opal is not supported on this device\n" ); -kfree (dev); -return NULL ; + goto err_free_resp; }return dev; + +err_free_resp: +kfree (dev->resp); + +err_free_cmd: +kfree (dev->cmd); + +err_free_dev: +kfree (dev); + +return NULL ; }EXPORT_SYMBOL (init_opal_dev);
drivers/accessibility/speakup/main.c +1 -1
@@ -1778,7 +1778,7 @@ static void speakup_con_update(struct vc_data *vc) {unsigned long flags; -if (!speakup_console[vc->vc_num] || spk_parked) +if (!speakup_console[vc->vc_num] || spk_parked || !synth)return ;if (!spin_trylock_irqsave (&speakup_info.spinlock, flags))/* Speakup output, discard */
drivers/acpi/scan.c +1 -0
@@ -793,6 +793,7 @@ static bool acpi_info_matches_ids(struct acpi_device_info *info,static const char *const acpi_ignore_dep_ids[] = {"PNP0D80" ,/* Windows-compatible System Power Management Controller */ "INT33BD" ,/* Intel Baytrail Mailbox Device */ +"LATT2021" ,/* Lattice FW Update Client Driver */ NULL };
drivers/acpi/x86/utils.c +6 -0
@@ -210,6 +210,12 @@ static const struct dmi_system_id force_storage_d3_dmi[] = { DMI_MATCH(DMI_PRODUCT_NAME, "Inspiron 14 7425 2-in-1"), } }, + { + .matches = { + DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc."), + DMI_MATCH(DMI_PRODUCT_NAME, "Inspiron 16 5625"), + } + }, {} };
drivers/ata/libata-transport.c +15 -4
@@ -301,7 +301,9 @@ int ata_tport_add(struct device *parent,pm_runtime_enable (dev);pm_runtime_forbid (dev); -transport_add_device (dev); + error =transport_add_device (dev); +if (error) + goto tport_transport_add_err;transport_configure_device (dev); error =ata_tlink_add (&ap->link);
@@ -312,12 +314,12 @@ int ata_tport_add(struct device *parent, tport_link_err:transport_remove_device (dev); + tport_transport_add_err:device_del (dev); tport_err:transport_destroy_device (dev);put_device (dev); -ata_host_put (ap->host);return error; }
@@ -426,7 +428,9 @@ int ata_tlink_add(struct ata_link *link) goto tlink_err; } -transport_add_device (dev); + error =transport_add_device (dev); +if (error) + goto tlink_transport_err;transport_configure_device (dev);ata_for_each_dev (ata_dev, link,ALL ) {
@@ -441,6 +445,7 @@ int ata_tlink_add(struct ata_link *link)ata_tdev_delete (ata_dev); }transport_remove_device (dev); + tlink_transport_err:device_del (dev); tlink_err:transport_destroy_device (dev);
@@ -678,7 +683,13 @@ static int ata_tdev_add(struct ata_device *ata_dev)return error; } -transport_add_device (dev); + error =transport_add_device (dev); +if (error) { +device_del (dev); +ata_tdev_free (ata_dev); +return error; + } +transport_configure_device (dev);return 0 ; }
drivers/block/drbd/drbd_main.c +2 -2
@@ -2699,7 +2699,7 @@ static int init_submitter(struct drbd_device *device)enum drbd_ret_code drbd_create_device (struct drbd_config_context *adm_ctx,unsigned int minor) {struct drbd_resource *resource = adm_ctx->resource; -struct drbd_connection *connection; +struct drbd_connection *connection, *n;struct drbd_device *device;struct drbd_peer_device *peer_device, *tmp_peer_device;struct gendisk *disk;
@@ -2815,7 +2815,7 @@ enum drbd_ret_code drbd_create_device(struct drbd_config_context *adm_ctx, unsigreturn NO_ERROR ; out_idr_remove_from_resource: -for_each_connection (connection, resource) { +for_each_connection_safe (connection, n, resource) { peer_device =idr_remove (&connection->peer_devices, vnr);if (peer_device)kref_put (&connection->kref, drbd_destroy_connection);
drivers/firmware/arm_scmi/bus.c +11 -0
@@ -216,9 +216,20 @@ void scmi_device_destroy(struct scmi_device *scmi_dev)device_unregister (&scmi_dev->dev); } +void scmi_device_link_add (struct device *consumer,struct device *supplier) +{ +struct device_link *link; + + link =device_link_add (consumer, supplier,DL_FLAG_AUTOREMOVE_CONSUMER ); + +WARN_ON (!link); +} +void scmi_set_handle (struct scmi_device *scmi_dev) { scmi_dev->handle =scmi_handle_get (&scmi_dev->dev); +if (scmi_dev->handle) +scmi_device_link_add (&scmi_dev->dev, scmi_dev->handle->dev); }int scmi_protocol_register (const struct scmi_protocol *proto)
drivers/firmware/arm_scmi/common.h +1 -0
@@ -272,6 +272,7 @@ struct scmi_xfer_ops {struct scmi_revision_info *scmi_revision_area_get (const struct scmi_protocol_handle *ph);int scmi_handle_put (const struct scmi_handle *handle); +void scmi_device_link_add (struct device *consumer,struct device *supplier);struct scmi_handle *scmi_handle_get (struct device *dev);void scmi_set_handle (struct scmi_device *scmi_dev); void scmi_setup_protocol_implemented(const struct scmi_protocol_handle *ph,
drivers/firmware/arm_scmi/driver.c +19 -12
@@ -1731,10 +1731,16 @@ int scmi_protocol_device_request(const struct scmi_device_id *id_table) sdev =scmi_get_protocol_device (child, info, id_table->protocol_id, id_table->name); -/* Set handle if not already set: device existed */ -if (sdev && !sdev->handle) - sdev->handle = -scmi_handle_get_from_info_unlocked (info); +if (sdev) { +/* Set handle if not already set: device existed */ +if (!sdev->handle) + sdev->handle = +scmi_handle_get_from_info_unlocked (info); +/* Relink consumer and suppliers */ +if (sdev->handle) +scmi_device_link_add (&sdev->dev, + sdev->handle->dev); + } }else { dev_err(info->dev, "Failed. SCMI protocol %d not active.\n",
@@ -1920,20 +1926,17 @@ void scmi_free_channel(struct scmi_chan_info *cinfo, struct idr *idr, int id)static int scmi_remove (struct platform_device *pdev) { -int ret =0 , id; +int ret, id;struct scmi_info *info =platform_get_drvdata (pdev);struct device_node *child;mutex_lock (&scmi_list_mutex);if (info->users) - ret = -EBUSY ; -else -list_del (&info->node); +dev_warn (&pdev->dev, +"Still active SCMI users will be forcibly unbound.\n" ); +list_del (&info->node);mutex_unlock (&scmi_list_mutex); -if (ret) -return ret; -scmi_notification_exit (&info->handle);mutex_lock (&info->protocols_mtx);
@@ -1945,7 +1948,11 @@ static int scmi_remove(struct platform_device *pdev)idr_destroy (&info->active_protocols);/* Safe to free channels since no more users */ -return scmi_cleanup_txrx_channels (info); + ret =scmi_cleanup_txrx_channels (info); +if (ret) +dev_warn (&pdev->dev,"Failed to cleanup SCMI channels.\n" ); + +return 0 ; } static ssize_t protocol_version_show(struct device *dev,
drivers/firmware/google/coreboot_table.c +29 -8
@@ -149,12 +149,8 @@ static int coreboot_table_probe(struct platform_device *pdev)if (!ptr)return -ENOMEM ; - ret =bus_register (&coreboot_bus_type); -if (!ret) { - ret =coreboot_table_populate (dev, ptr); -if (ret) -bus_unregister (&coreboot_bus_type); - } + ret =coreboot_table_populate (dev, ptr); +memunmap (ptr);return ret;
@@ -169,7 +165,6 @@ static int __cb_dev_unregister(struct device *dev, void *dummy)static int coreboot_table_remove (struct platform_device *pdev) {bus_for_each_dev (&coreboot_bus_type,NULL ,NULL , __cb_dev_unregister); -bus_unregister (&coreboot_bus_type);return 0 ; }
@@ -199,6 +194,32 @@ static struct platform_driver coreboot_table_driver = { .of_match_table = of_match_ptr(coreboot_of_match), }, }; -module_platform_driver (coreboot_table_driver); + +static int __init coreboot_table_driver_init (void ) +{ +int ret; + + ret =bus_register (&coreboot_bus_type); +if (ret) +return ret; + + ret =platform_driver_register (&coreboot_table_driver); +if (ret) { +bus_unregister (&coreboot_bus_type); +return ret; + } + +return 0 ; +} + +static void __exit coreboot_table_driver_exit(void) +{ +platform_driver_unregister (&coreboot_table_driver); +bus_unregister (&coreboot_bus_type); +} + +module_init (coreboot_table_driver_init); +module_exit (coreboot_table_driver_exit); +MODULE_AUTHOR ("Google, Inc." );MODULE_LICENSE ("GPL" );
drivers/gpu/drm/amd/display/dc/dcn20/dcn20_hwseq.c +1 -1
@@ -1765,7 +1765,7 @@ void dcn20_post_unlock_program_front_end(for (j =0 ; j <TIMEOUT_FOR_PIPE_ENABLE_MS *1000 && hubp->funcs->hubp_is_flip_pending (hubp); j++) -mdelay (1 ); +udelay (1 ); } }
drivers/gpu/drm/amd/display/dc/dcn31/dcn31_hubp.c +1 -0
@@ -79,6 +79,7 @@ static struct hubp_funcs dcn31_hubp_funcs = { .hubp_init = hubp3_init, .set_unbounded_requesting = hubp31_set_unbounded_requesting, .hubp_soft_reset = hubp31_soft_reset, + .hubp_set_flip_int = hubp1_set_flip_int, .hubp_in_blank = hubp1_in_blank, };
drivers/gpu/drm/drm_drv.c +1 -1
@@ -614,7 +614,7 @@ static int drm_dev_init(struct drm_device *dev,mutex_init (&dev->clientlist_mutex);mutex_init (&dev->master_mutex); - ret =drmm_add_action (dev, drm_dev_init_release,NULL ); + ret =drmm_add_action_or_reset (dev, drm_dev_init_release,NULL );if (ret)return ret;
drivers/gpu/drm/drm_internal.h +2 -1
@@ -104,7 +104,8 @@ static inline void drm_vblank_flush_worker(struct drm_vblank_crtc *vblank)static inline void drm_vblank_destroy_worker (struct drm_vblank_crtc *vblank) { -kthread_destroy_worker (vblank->worker); +if (vblank->worker) +kthread_destroy_worker (vblank->worker); }int drm_vblank_worker_init (struct drm_vblank_crtc *vblank);
drivers/gpu/drm/imx/imx-tve.c +3 -2
@@ -217,8 +217,9 @@ static int imx_tve_connector_get_modes(struct drm_connector *connector)return ret; } -static int imx_tve_connector_mode_valid (struct drm_connector *connector, -struct drm_display_mode *mode) +static enum drm_mode_status +imx_tve_connector_mode_valid (struct drm_connector *connector, +struct drm_display_mode *mode) {struct imx_tve *tve =con_to_tve (connector);unsigned long rate;
drivers/gpu/drm/panel/panel-simple.c +2 -0
@@ -3090,6 +3090,7 @@ static const struct display_timing logictechno_lt161010_2nh_timing = {static const struct panel_desc logictechno_lt161010_2nh = { .timings = &logictechno_lt161010_2nh_timing, .num_timings =1 , + .bpc =6 , .size = { .width =154 , .height =86 ,
@@ -3119,6 +3120,7 @@ static const struct display_timing logictechno_lt170410_2whc_timing = {static const struct panel_desc logictechno_lt170410_2whc = { .timings = &logictechno_lt170410_2whc_timing, .num_timings =1 , + .bpc =8 , .size = { .width =217 , .height =136 ,
drivers/gpu/drm/vc4/vc4_kms.c +4 -4
@@ -193,8 +193,8 @@ vc4_hvs_get_new_global_state(struct drm_atomic_state *state)struct drm_private_state *priv_state; priv_state =drm_atomic_get_new_private_obj_state (state, &vc4->hvs_channels); -if (IS_ERR (priv_state)) -return ERR_CAST (priv_state); +if (!priv_state) +return ERR_PTR (-EINVAL );return to_vc4_hvs_state (priv_state); }
@@ -206,8 +206,8 @@ vc4_hvs_get_old_global_state(struct drm_atomic_state *state)struct drm_private_state *priv_state; priv_state =drm_atomic_get_old_private_obj_state (state, &vc4->hvs_channels); -if (IS_ERR (priv_state)) -return ERR_CAST (priv_state); +if (!priv_state) +return ERR_PTR (-EINVAL );return to_vc4_hvs_state (priv_state); }
drivers/i2c/busses/i2c-i801.c +1 -0
@@ -1242,6 +1242,7 @@ static const struct {*/ { "Latitude 5480", 0x29 }, { "Vostro V131", 0x1d }, + { "Vostro 5568", 0x29 }, };static void register_dell_lis3lv02d_i2c_device (struct i801_priv *priv)
drivers/i2c/busses/i2c-tegra.c +10 -6
@@ -283,6 +283,7 @@ struct tegra_i2c_dev {struct dma_chan *tx_dma_chan;struct dma_chan *rx_dma_chan;unsigned int dma_buf_size; +struct device *dma_dev;dma_addr_t dma_phys;void *dma_buf;
@@ -419,7 +420,7 @@ static int tegra_i2c_dma_submit(struct tegra_i2c_dev *i2c_dev, size_t len)static void tegra_i2c_release_dma (struct tegra_i2c_dev *i2c_dev) {if (i2c_dev->dma_buf) { -dma_free_coherent (i2c_dev->dev, i2c_dev->dma_buf_size, +dma_free_coherent (i2c_dev->dma_dev, i2c_dev->dma_buf_size, i2c_dev->dma_buf, i2c_dev->dma_phys); i2c_dev->dma_buf =NULL ; }
@@ -466,10 +467,13 @@ static int tegra_i2c_init_dma(struct tegra_i2c_dev *i2c_dev) i2c_dev->tx_dma_chan = chan; +WARN_ON (i2c_dev->tx_dma_chan->device != i2c_dev->rx_dma_chan->device); + i2c_dev->dma_dev = chan->device->dev; + i2c_dev->dma_buf_size = i2c_dev->hw->quirks->max_write_len +I2C_PACKET_HEADER_SIZE ; - dma_buf =dma_alloc_coherent (i2c_dev->dev, i2c_dev->dma_buf_size, + dma_buf =dma_alloc_coherent (i2c_dev->dma_dev, i2c_dev->dma_buf_size, &dma_phys,GFP_KERNEL | __GFP_NOWARN);if (!dma_buf) {dev_err (i2c_dev->dev,"failed to allocate DMA buffer\n" );
@@ -1255,7 +1259,7 @@ static int tegra_i2c_xfer_msg(struct tegra_i2c_dev *i2c_dev,if (i2c_dev->dma_mode) {if (i2c_dev->msg_read) { -dma_sync_single_for_device (i2c_dev->dev, +dma_sync_single_for_device (i2c_dev->dma_dev, i2c_dev->dma_phys, xfer_size,DMA_FROM_DEVICE );
@@ -1263,7 +1267,7 @@ static int tegra_i2c_xfer_msg(struct tegra_i2c_dev *i2c_dev,if (err)return err; }else { -dma_sync_single_for_cpu (i2c_dev->dev, +dma_sync_single_for_cpu (i2c_dev->dma_dev, i2c_dev->dma_phys, xfer_size,DMA_TO_DEVICE ); }
@@ -1276,7 +1280,7 @@ static int tegra_i2c_xfer_msg(struct tegra_i2c_dev *i2c_dev,memcpy (i2c_dev->dma_buf +I2C_PACKET_HEADER_SIZE , msg->buf, msg->len); -dma_sync_single_for_device (i2c_dev->dev, +dma_sync_single_for_device (i2c_dev->dma_dev, i2c_dev->dma_phys, xfer_size,DMA_TO_DEVICE );
@@ -1327,7 +1331,7 @@ static int tegra_i2c_xfer_msg(struct tegra_i2c_dev *i2c_dev, }if (i2c_dev->msg_read && i2c_dev->msg_err ==I2C_ERR_NONE ) { -dma_sync_single_for_cpu (i2c_dev->dev, +dma_sync_single_for_cpu (i2c_dev->dma_dev, i2c_dev->dma_phys, xfer_size,DMA_FROM_DEVICE );
drivers/iio/adc/at91_adc.c +3 -1
@@ -634,8 +634,10 @@ static struct iio_trigger *at91_adc_allocate_trigger(struct iio_dev *idev, trig->ops = &at91_adc_trigger_ops; ret =iio_trigger_register (trig); -if (ret) +if (ret) { +iio_trigger_free (trig);return NULL ; + }return trig; }
drivers/iio/adc/mp2629_adc.c +3 -2
@@ -56,7 +56,8 @@ static struct iio_map mp2629_adc_maps[] = {MP2629_MAP (SYSTEM_VOLT ,"system-volt" ),MP2629_MAP (INPUT_VOLT ,"input-volt" ),MP2629_MAP (BATT_CURRENT ,"batt-current" ), -MP2629_MAP (INPUT_CURRENT ,"input-current" ) + MP2629_MAP(INPUT_CURRENT, "input-current"), + { } }; static int mp2629_read_raw(struct iio_dev *indio_dev,
@@ -73,7 +74,7 @@ static int mp2629_read_raw(struct iio_dev *indio_dev,if (ret)return ret; -if (chan->address ==MP2629_INPUT_VOLT ) +if (chan->channel ==MP2629_INPUT_VOLT ) rval &=GENMASK (6 ,0 ); *val = rval;return IIO_VAL_INT ;
drivers/iio/pressure/ms5611_spi.c +1 -1
@@ -94,7 +94,7 @@ static int ms5611_spi_probe(struct spi_device *spi)spi_set_drvdata (spi, indio_dev); spi->mode =SPI_MODE_0 ; - spi->max_speed_hz =20000000 ; + spi->max_speed_hz =min (spi->max_speed_hz,20000000U ); spi->bits_per_word =8 ; ret =spi_setup (spi);if (ret <0 )
drivers/iio/trigger/iio-trig-sysfs.c +5 -1
@@ -208,9 +208,13 @@ static int iio_sysfs_trigger_remove(int id)static int __init iio_sysfs_trig_init (void ) { +int ret;device_initialize (&iio_sysfs_trig_dev);dev_set_name (&iio_sysfs_trig_dev,"iio_sysfs_trigger" ); -return device_add (&iio_sysfs_trig_dev); + ret =device_add (&iio_sysfs_trig_dev); +if (ret) +put_device (&iio_sysfs_trig_dev); +return ret; }module_init (iio_sysfs_trig_init);
drivers/infiniband/hw/efa/efa_main.c +3 -1
@@ -1,6 +1,6 @@// SPDX-License-Identifier: GPL-2.0 OR BSD-2-Clause /* -* Copyright 2018-2021 Amazon.com, Inc. or its affiliates. All rights reserved. +* Copyright 2018-2022 Amazon.com, Inc. or its affiliates. All rights reserved. */ #include <linux/module.h>
@@ -14,10 +14,12 @@#define PCI_DEV_ID_EFA0_VF 0xefa0#define PCI_DEV_ID_EFA1_VF 0xefa1 +#define PCI_DEV_ID_EFA2_VF 0xefa2static const struct pci_device_id efa_pci_tbl[] = { {PCI_VDEVICE (AMAZON ,PCI_DEV_ID_EFA0_VF ) }, {PCI_VDEVICE (AMAZON ,PCI_DEV_ID_EFA1_VF ) }, + {PCI_VDEVICE (AMAZON ,PCI_DEV_ID_EFA2_VF ) }, { } };
drivers/input/joystick/iforce/iforce-main.c +4 -4
@@ -273,22 +273,22 @@ int iforce_init_device(struct device *parent, u16 bustype,* Get device info. */ -if (!iforce_get_id_packet (iforce,'M' , buf, &len) || len <3 ) +if (!iforce_get_id_packet (iforce,'M' , buf, &len) && len >=3 ) input_dev->id.vendor =get_unaligned_le16 (buf +1 );else dev_warn (&iforce->dev->dev,"Device does not respond to id packet M\n" ); -if (!iforce_get_id_packet (iforce,'P' , buf, &len) || len <3 ) +if (!iforce_get_id_packet (iforce,'P' , buf, &len) && len >=3 ) input_dev->id.product =get_unaligned_le16 (buf +1 );else dev_warn (&iforce->dev->dev,"Device does not respond to id packet P\n" ); -if (!iforce_get_id_packet (iforce,'B' , buf, &len) || len <3 ) +if (!iforce_get_id_packet (iforce,'B' , buf, &len) && len >=3 ) iforce->device_memory.end =get_unaligned_le16 (buf +1 );else dev_warn (&iforce->dev->dev,"Device does not respond to id packet B\n" ); -if (!iforce_get_id_packet (iforce,'N' , buf, &len) || len <2 ) +if (!iforce_get_id_packet (iforce,'N' , buf, &len) && len >=2 ) ff_effects = buf[1 ];else dev_warn (&iforce->dev->dev,"Device does not respond to id packet N\n" );
drivers/input/serio/i8042.c +0 -4
@@ -1543,8 +1543,6 @@ static int i8042_probe(struct platform_device *dev) {int error; - i8042_platform_device = dev; -if (i8042_reset ==I8042_RESET_ALWAYS ) { error =i8042_controller_selftest ();if (error)
@@ -1582,7 +1580,6 @@ static int i8042_probe(struct platform_device *dev)i8042_free_aux_ports ();/* in case KBD failed but AUX not */ i8042_free_irqs ();i8042_controller_reset (false); - i8042_platform_device =NULL ;return error; }
@@ -1592,7 +1589,6 @@ static int i8042_remove(struct platform_device *dev)i8042_unregister_ports ();i8042_free_irqs ();i8042_controller_reset (false); - i8042_platform_device =NULL ;return 0 ; }
drivers/iommu/intel/iommu.c +3 -5
@@ -1048,11 +1048,9 @@ static struct dma_pte *pfn_to_dma_pte(struct dmar_domain *domain,domain_flush_cache (domain, tmp_page,VTD_PAGE_SIZE ); pteval = ((uint64_t )virt_to_dma_pfn (tmp_page) <<VTD_PAGE_SHIFT ) |DMA_PTE_READ |DMA_PTE_WRITE ; -if (domain_use_first_level (domain)) { - pteval |=DMA_FL_PTE_XD |DMA_FL_PTE_US ; -if (iommu_is_dma_domain (&domain->domain)) - pteval |=DMA_FL_PTE_ACCESS ; - } +if (domain_use_first_level (domain)) + pteval |=DMA_FL_PTE_XD |DMA_FL_PTE_US |DMA_FL_PTE_ACCESS ; +if (cmpxchg64 (&pte->val,0ULL , pteval))/* Someone else set it while we were thinking; use theirs. */ free_pgtable_page (tmp_page);
drivers/iommu/intel/pasid.c +3 -2
@@ -717,7 +717,7 @@ int intel_pasid_setup_second_level(struct intel_iommu *iommu,* Since it is a second level only translation setup, we should * set SRE bit as well (addresses are expected to be GPAs). */ -if (pasid !=PASID_RID2PASID ) +if (pasid !=PASID_RID2PASID &&ecap_srs (iommu->ecap))pasid_set_sre (pte);pasid_set_present (pte);pasid_flush_caches (iommu, pte, pasid, did);
@@ -756,7 +756,8 @@ int intel_pasid_setup_pass_through(struct intel_iommu *iommu,* We should set SRE bit as well since the addresses are expected * to be GPAs. */ -pasid_set_sre (pte); +if (ecap_srs (iommu->ecap)) +pasid_set_sre (pte);pasid_set_present (pte);pasid_flush_caches (iommu, pte, pasid, did);
drivers/isdn/mISDN/core.c +1 -1
@@ -222,7 +222,7 @@ mISDN_register_device(struct mISDNdevice *dev, err =get_free_devid ();if (err <0 ) - goto error1; +return err; dev->id = err;device_initialize (&dev->dev);
drivers/isdn/mISDN/dsp_pipeline.c +2 -1
@@ -77,6 +77,7 @@ int mISDN_dsp_element_register(struct mISDN_dsp_element *elem)if (!entry)return -ENOMEM ; +INIT_LIST_HEAD (&entry->list); entry->elem = elem; entry->dev.class = elements_class;
@@ -107,7 +108,7 @@ int mISDN_dsp_element_register(struct mISDN_dsp_element *elem)device_unregister (&entry->dev);return ret; err1: -kfree (entry); +put_device (&entry->dev);return ret; }EXPORT_SYMBOL (mISDN_dsp_element_register);
drivers/md/dm-ioctl.c +2 -2
@@ -655,7 +655,7 @@ static void list_version_get_needed(struct target_type *tt, void *needed_param)size_t *needed = needed_param; *needed +=sizeof (struct dm_target_versions ); - *needed +=strlen (tt->name); + *needed +=strlen (tt->name) +1 ; *needed +=ALIGN_MASK ; }
@@ -720,7 +720,7 @@ static int __list_versions(struct dm_ioctl *param, size_t param_size, const char iter_info.old_vers =NULL ; iter_info.vers = vers; iter_info.flags =0 ; - iter_info.end = (char *)vers+len; + iter_info.end = (char *)vers + needed;/* * Now loop through filling out the names & versions.
drivers/mfd/lpc_ich.c +54 -5
94 lines not on this page · raw message
drivers/misc/vmw_vmci/vmci_queue_pair.c +2 -0
@@ -854,6 +854,7 @@ static int qp_notify_peer_local(bool attach, struct vmci_handle handle)u32 context_id =vmci_get_context_id ();struct vmci_event_qp ev; +memset (&ev,0 ,sizeof (ev)); ev.msg.hdr.dst =vmci_make_handle (context_id,VMCI_EVENT_HANDLER ); ev.msg.hdr.src =vmci_make_handle (VMCI_HYPERVISOR_CONTEXT_ID ,VMCI_CONTEXT_RESOURCE_ID );
@@ -1467,6 +1468,7 @@ static int qp_notify_peer(bool attach,* kernel. */ +memset (&ev,0 ,sizeof (ev)); ev.msg.hdr.dst =vmci_make_handle (peer_id,VMCI_EVENT_HANDLER ); ev.msg.hdr.src =vmci_make_handle (VMCI_HYPERVISOR_CONTEXT_ID ,VMCI_CONTEXT_RESOURCE_ID );
drivers/mmc/core/core.c +7 -1
@@ -1132,7 +1132,13 @@ u32 mmc_select_voltage(struct mmc_host *host, u32 ocr)mmc_power_cycle (host, ocr); }else { bit =fls (ocr) -1 ; - ocr &=3 << bit; +/* +* The bit variable represents the highest voltage bit set in +* the OCR register. +* To keep a range of 2 values (e.g. 3.2V/3.3V and 3.3V/3.4V), +* we must shift the mask '3' with (bit - 1). +*/ + ocr &=3 << (bit -1 );if (bit != host->ios.vdd)dev_warn (mmc_dev (host),"exceeding card's volts\n" ); }
drivers/mmc/host/sdhci-pci-core.c +2 -0
@@ -1818,6 +1818,8 @@ static int amd_probe(struct sdhci_pci_chip *chip) } } +pci_dev_put (smbus_dev); +if (gen ==AMD_CHIPSET_BEFORE_ML || gen ==AMD_CHIPSET_CZ ) chip->quirks2 |=SDHCI_QUIRK2_CLEAR_TRANSFERMODE_REG_BEFORE_CMD ;
drivers/mmc/host/sdhci-pci-o2micro.c +7 -0
@@ -31,6 +31,7 @@#define O2_SD_CAPS 0xE0#define O2_SD_ADMA1 0xE2#define O2_SD_ADMA2 0xE7 +#define O2_SD_MISC_CTRL2 0xF0#define O2_SD_INF_MOD 0xF1#define O2_SD_MISC_CTRL4 0xFC#define O2_SD_MISC_CTRL 0x1C0
@@ -830,6 +831,12 @@ static int sdhci_pci_o2_probe(struct sdhci_pci_chip *chip)/* Set Tuning Windows to 5 */ pci_write_config_byte (chip->pdev,O2_SD_TUNING_CTRL ,0x55 ); +//Adjust 1st and 2nd CD debounce time +pci_read_config_dword (chip->pdev,O2_SD_MISC_CTRL2 , &scratch_32); + scratch_32 &=0xFFE7FFFF ; + scratch_32 |=0x00180000 ; +pci_write_config_dword (chip->pdev,O2_SD_MISC_CTRL2 , scratch_32); +pci_write_config_dword (chip->pdev,O2_SD_DETECT_SETTING ,1 );/* Lock WP */ ret =pci_read_config_byte (chip->pdev,O2_SD_LOCK_WP , &scratch);
drivers/mtd/spi-nor/controllers/intel-spi-pci.c +19 -10
@@ -16,12 +16,30 @@#define BCR 0xdc#define BCR_WPD BIT(0) +static bool intel_spi_pci_set_writeable (void __iomem *base,void *data) +{ +struct pci_dev *pdev = data; +u32 bcr; + +/* Try to make the chip read/write */ +pci_read_config_dword (pdev,BCR , &bcr); +if (!(bcr &BCR_WPD )) { + bcr |=BCR_WPD ; +pci_write_config_dword (pdev,BCR , bcr); +pci_read_config_dword (pdev,BCR , &bcr); + } + +return bcr &BCR_WPD ; +} +static const struct intel_spi_boardinfo bxt_info = { .type =INTEL_SPI_BXT , + .set_writeable = intel_spi_pci_set_writeable, };static const struct intel_spi_boardinfo cnl_info = { .type =INTEL_SPI_CNL , + .set_writeable = intel_spi_pci_set_writeable, }; static int intel_spi_pci_probe(struct pci_dev *pdev,
@@ -29,7 +47,6 @@ static int intel_spi_pci_probe(struct pci_dev *pdev, {struct intel_spi_boardinfo *info;struct intel_spi *ispi; -u32 bcr;int ret; ret =pcim_enable_device (pdev);
@@ -41,15 +58,7 @@ static int intel_spi_pci_probe(struct pci_dev *pdev,if (!info)return -ENOMEM ; -/* Try to make the chip read/write */ -pci_read_config_dword (pdev,BCR , &bcr); -if (!(bcr &BCR_WPD )) { - bcr |=BCR_WPD ; -pci_write_config_dword (pdev,BCR , bcr); -pci_read_config_dword (pdev,BCR , &bcr); - } - info->writeable = !!(bcr &BCR_WPD ); - + info->data = pdev; ispi =intel_spi_probe (&pdev->dev, &pdev->resource[0 ], info);if (IS_ERR (ispi))return PTR_ERR (ispi);
drivers/mtd/spi-nor/controllers/intel-spi.c +24 -27
119 lines not on this page · raw message
drivers/net/ethernet/amazon/ena/ena_netdev.c +7 -1
@@ -4583,13 +4583,19 @@ static struct pci_driver ena_pci_driver = {static int __init ena_init (void ) { +int ret; + ena_wq =create_singlethread_workqueue (DRV_MODULE_NAME );if (!ena_wq) {pr_err ("Failed to create workqueue\n" );return -ENOMEM ; } -return pci_register_driver (&ena_pci_driver); + ret =pci_register_driver (&ena_pci_driver); +if (ret) +destroy_workqueue (ena_wq); + +return ret; } static void __exit ena_cleanup(void)
drivers/net/ethernet/atheros/ag71xx.c +2 -1
@@ -1480,7 +1480,7 @@ static int ag71xx_open(struct net_device *ndev)if (ret) {netif_err (ag, link, ndev,"phylink_of_phy_connect filed with err: %i\n" , ret); - goto err; +return ret; } max_frame_len =ag71xx_max_frame_len (ndev->mtu);
@@ -1501,6 +1501,7 @@ static int ag71xx_open(struct net_device *ndev) err:ag71xx_rings_cleanup (ag); +phylink_disconnect_phy (ag->phylink);return ret; }
drivers/net/ethernet/broadcom/bgmac.c +0 -1
@@ -1568,7 +1568,6 @@ void bgmac_enet_remove(struct bgmac *bgmac)phy_disconnect (bgmac->net_dev->phydev);netif_napi_del (&bgmac->napi);bgmac_dma_free (bgmac); -free_netdev (bgmac->net_dev); }EXPORT_SYMBOL_GPL (bgmac_enet_remove);
drivers/net/ethernet/broadcom/bnxt/bnxt.c +9 -1
@@ -13697,8 +13697,16 @@ static struct pci_driver bnxt_pci_driver = {static int __init bnxt_init (void ) { +int err; +bnxt_debug_init (); -return pci_register_driver (&bnxt_pci_driver); + err =pci_register_driver (&bnxt_pci_driver); +if (err) { +bnxt_debug_exit (); +return err; + } + +return 0 ; } static void __exit bnxt_exit(void)
drivers/net/ethernet/cavium/liquidio/lio_main.c +26 -8
@@ -1798,13 +1798,10 @@ static int liquidio_open(struct net_device *netdev)ifstate_set (lio,LIO_IFSTATE_RUNNING ); -if (OCTEON_CN23XX_PF (oct)) { -if (!oct->msix_on) -if (setup_tx_poll_fn (netdev)) -return -1 ; - }else { -if (setup_tx_poll_fn (netdev)) -return -1 ; +if (!OCTEON_CN23XX_PF (oct) || (OCTEON_CN23XX_PF (oct) && !oct->msix_on)) { + ret =setup_tx_poll_fn (netdev); +if (ret) + goto err_poll; }netif_tx_start_all_queues (netdev);
@@ -1817,7 +1814,7 @@ static int liquidio_open(struct net_device *netdev)/* tell Octeon to start forwarding packets to host */ ret =send_rx_ctrl_cmd (lio,1 );if (ret) -return ret; + goto err_rx_ctrl;/* start periodical statistics fetch */ INIT_DELAYED_WORK (&lio->stats_wk.work, lio_fetch_stats);
@@ -1828,6 +1825,27 @@ static int liquidio_open(struct net_device *netdev)dev_info (&oct->pci_dev->dev,"%s interface is opened\n" , netdev->name); +return 0 ; + +err_rx_ctrl: +if (!OCTEON_CN23XX_PF (oct) || (OCTEON_CN23XX_PF (oct) && !oct->msix_on)) +cleanup_tx_poll_fn (netdev); +err_poll: +if (lio->ptp_clock) { +ptp_clock_unregister (lio->ptp_clock); + lio->ptp_clock =NULL ; + } + +if (oct->props[lio->ifidx].napi_enabled ==1 ) { +list_for_each_entry_safe (napi, n, &netdev->napi_list, dev_list) +napi_disable (napi); + + oct->props[lio->ifidx].napi_enabled =0 ; + +if (OCTEON_CN23XX_PF (oct)) + oct->droq[0 ]->ops.poll_mode =0 ; + } +return ret; }
drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c +7 -3
@@ -3172,6 +3172,7 @@ static int hclge_update_tp_port_info(struct hclge_dev *hdev) hdev->hw.mac.autoneg = cmd.base.autoneg; hdev->hw.mac.speed = cmd.base.speed; hdev->hw.mac.duplex = cmd.base.duplex; +linkmode_copy (hdev->hw.mac.advertising, cmd.link_modes.advertising);return 0 ; }
@@ -11669,9 +11670,12 @@ static int hclge_init_ae_dev(struct hnae3_ae_dev *ae_dev)if (ret) goto err_msi_irq_uninit; -if (hdev->hw.mac.media_type ==HNAE3_MEDIA_TYPE_COPPER && - !hnae3_dev_phy_imp_supported (hdev)) { - ret =hclge_mac_mdio_config (hdev); +if (hdev->hw.mac.media_type ==HNAE3_MEDIA_TYPE_COPPER ) { +if (hnae3_dev_phy_imp_supported (hdev)) + ret =hclge_update_tp_port_info (hdev); +else + ret =hclge_mac_mdio_config (hdev); +if (ret) goto err_msi_irq_uninit; }
drivers/net/ethernet/huawei/hinic/hinic_main.c +8 -1
@@ -1482,8 +1482,15 @@ static struct pci_driver hinic_driver = {static int __init hinic_module_init (void ) { +int ret; +hinic_dbg_register_debugfs (HINIC_DRV_NAME ); -return pci_register_driver (&hinic_driver); + + ret =pci_register_driver (&hinic_driver); +if (ret) +hinic_dbg_unregister_debugfs (); + +return ret; } static void __exit hinic_module_exit(void)
drivers/net/ethernet/microchip/sparx5/sparx5_ethtool.c +3 -0
@@ -1219,6 +1219,9 @@ int sparx_stats_init(struct sparx5 *sparx5)snprintf (queue_name,sizeof (queue_name),"%s-stats" ,dev_name (sparx5->dev)); sparx5->stats_queue =create_singlethread_workqueue (queue_name); +if (!sparx5->stats_queue) +return -ENOMEM ; +INIT_DELAYED_WORK (&sparx5->stats_work, sparx5_check_stats_work);queue_delayed_work (sparx5->stats_queue, &sparx5->stats_work,SPX5_STATS_CHECK_DELAY );
drivers/net/ethernet/microchip/sparx5/sparx5_main.c +3 -0
@@ -629,6 +629,9 @@ static int sparx5_start(struct sparx5 *sparx5)snprintf (queue_name,sizeof (queue_name),"%s-mact" ,dev_name (sparx5->dev)); sparx5->mact_queue =create_singlethread_workqueue (queue_name); +if (!sparx5->mact_queue) +return -ENOMEM ; +INIT_DELAYED_WORK (&sparx5->mact_work, sparx5_mact_pull_work);queue_delayed_work (sparx5->mact_queue, &sparx5->mact_work,SPX5_MACT_PULL_DELAY );
drivers/net/ethernet/netronome/nfp/nfp_net_ethtool.c +3 -3
@@ -1264,15 +1264,15 @@ nfp_port_get_module_info(struct net_device *netdev,if (data <0x3 ) { modinfo->type =ETH_MODULE_SFF_8436 ; - modinfo->eeprom_len =ETH_MODULE_SFF_8436_LEN ; + modinfo->eeprom_len =ETH_MODULE_SFF_8436_MAX_LEN ; }else { modinfo->type =ETH_MODULE_SFF_8636 ; - modinfo->eeprom_len =ETH_MODULE_SFF_8636_LEN ; + modinfo->eeprom_len =ETH_MODULE_SFF_8636_MAX_LEN ; }break ;case NFP_INTERFACE_QSFP28 : modinfo->type =ETH_MODULE_SFF_8636 ; - modinfo->eeprom_len =ETH_MODULE_SFF_8636_LEN ; + modinfo->eeprom_len =ETH_MODULE_SFF_8636_MAX_LEN ;break ;default : netdev_err(netdev, "Unsupported module 0x%x detected\n",
drivers/net/ethernet/pensando/ionic/ionic_main.c +7 -1
@@ -588,8 +588,14 @@ int ionic_port_reset(struct ionic *ionic)static int __init ionic_init_module (void ) { +int ret; +ionic_debugfs_create (); -return ionic_bus_register_driver (); + ret =ionic_bus_register_driver (); +if (ret) +ionic_debugfs_destroy (); + +return ret; } static void __exit ionic_cleanup_module(void)
drivers/net/ethernet/stmicro/stmmac/stmmac_main.c +3 -0
@@ -6494,6 +6494,9 @@ void stmmac_xdp_release(struct net_device *dev)struct stmmac_priv *priv =netdev_priv (dev);u32 chan; +/* Ensure tx function is not running */ +netif_tx_disable (dev); +/* Disable NAPI process */ stmmac_disable_all_queues (priv);
drivers/net/macvlan.c +3 -3
@@ -141,7 +141,7 @@ static struct macvlan_source_entry *macvlan_hash_lookup_source(u32 idx =macvlan_eth_hash (addr);struct hlist_head *h = &vlan->port->vlan_source_hash[idx]; -hlist_for_each_entry_rcu (entry, h, hlist) { +hlist_for_each_entry_rcu (entry, h, hlist,lockdep_rtnl_is_held ()) {if (ether_addr_equal_64bits (entry->addr, addr) && entry->vlan == vlan)return entry;
@@ -1181,7 +1181,7 @@ void macvlan_common_setup(struct net_device *dev) {ether_setup (dev); - dev->min_mtu =0 ; +/* ether_setup() has set dev->min_mtu to ETH_MIN_MTU. */ dev->max_mtu =ETH_MAX_MTU ; dev->priv_flags &= ~IFF_TX_SKB_SHARING ;netif_keep_dst (dev);
@@ -1635,7 +1635,7 @@ static int macvlan_fill_info_macaddr(struct sk_buff *skb,struct hlist_head *h = &vlan->port->vlan_source_hash[i];struct macvlan_source_entry *entry; -hlist_for_each_entry_rcu (entry, h, hlist) { +hlist_for_each_entry_rcu (entry, h, hlist,lockdep_rtnl_is_held ()) {if (entry->vlan != vlan)continue ;if (nla_put (skb,IFLA_MACVLAN_MACADDR ,ETH_ALEN , entry->addr))
drivers/net/mhi_net.c +2 -0
@@ -343,6 +343,8 @@ static void mhi_net_dellink(struct mhi_device *mhi_dev, struct net_device *ndev)kfree_skb (mhi_netdev->skbagg_head); +free_netdev (ndev); +dev_set_drvdata (&mhi_dev->dev,NULL ); }
drivers/net/phy/marvell.c +9 -7
@@ -1976,14 +1976,16 @@ static int m88e1510_loopback(struct phy_device *phydev, bool enable)if (err <0 )return err; -/* FIXME: Based on trial and error test, it seem 1G need to have -* delay between soft reset and loopback enablement. -*/ -if (phydev->speed ==SPEED_1000 ) -msleep (1000 ); + err =phy_modify (phydev,MII_BMCR ,BMCR_LOOPBACK , +BMCR_LOOPBACK ); -return phy_modify (phydev,MII_BMCR ,BMCR_LOOPBACK , -BMCR_LOOPBACK ); +if (!err) { +/* It takes some time for PHY device to switch +* into/out-of loopback mode. +*/ +msleep (1000 ); + } +return err; }else { err =phy_modify (phydev,MII_BMCR ,BMCR_LOOPBACK ,0 );if (err <0 )
drivers/net/thunderbolt.c +14 -5
@@ -1377,12 +1377,21 @@ static int __init tbnet_init(void) TBNET_MATCH_FRAGS_ID | TBNET_64K_FRAMES); ret =tb_register_property_dir ("network" , tbnet_dir); -if (ret) { -tb_property_free_dir (tbnet_dir); -return ret; - } +if (ret) + goto err_free_dir; + + ret =tb_register_service_driver (&tbnet_driver); +if (ret) + goto err_unregister; -return tb_register_service_driver (&tbnet_driver); +return 0 ; + +err_unregister: +tb_unregister_property_dir ("network" , tbnet_dir); +err_free_dir: +tb_property_free_dir (tbnet_dir); + +return ret; }module_init (tbnet_init);
drivers/nvme/host/ioctl.c +6 -0
@@ -484,11 +484,17 @@ long nvme_dev_ioctl(struct file *file, unsigned int cmd,case NVME_IOCTL_IO_CMD :return nvme_dev_user_cmd (ctrl, argp);case NVME_IOCTL_RESET : +if (!capable (CAP_SYS_ADMIN )) +return -EACCES ;dev_warn (ctrl->device,"resetting controller\n" );return nvme_reset_ctrl_sync (ctrl);case NVME_IOCTL_SUBSYS_RESET : +if (!capable (CAP_SYS_ADMIN )) +return -EACCES ;return nvme_reset_subsystem (ctrl);case NVME_IOCTL_RESCAN : +if (!capable (CAP_SYS_ADMIN )) +return -EACCES ;nvme_queue_scan (ctrl);return 0 ;default :
drivers/nvme/host/nvme.h +13 -3
@@ -558,11 +558,23 @@ static inline void nvme_fault_inject_fini(struct nvme_fault_inject *fault_inj)static inline void nvme_should_fail (struct request *req) {}#endif +bool nvme_wait_reset (struct nvme_ctrl *ctrl); +int nvme_try_sched_reset (struct nvme_ctrl *ctrl); +static inline int nvme_reset_subsystem (struct nvme_ctrl *ctrl) { +int ret; +if (!ctrl->subsystem)return -ENOTTY ; -return ctrl->ops->reg_write32 (ctrl,NVME_REG_NSSR ,0x4E564D65 ); +if (!nvme_wait_reset (ctrl)) +return -EBUSY ; + + ret = ctrl->ops->reg_write32 (ctrl,NVME_REG_NSSR ,0x4E564D65 ); +if (ret) +return ret; + +return nvme_try_sched_reset (ctrl); }/*
@@ -650,7 +662,6 @@ void nvme_cancel_tagset(struct nvme_ctrl *ctrl);void nvme_cancel_admin_tagset (struct nvme_ctrl *ctrl);bool nvme_change_ctrl_state (struct nvme_ctrl *ctrl,enum nvme_ctrl_state new_state); -bool nvme_wait_reset (struct nvme_ctrl *ctrl);int nvme_disable_ctrl (struct nvme_ctrl *ctrl);int nvme_enable_ctrl (struct nvme_ctrl *ctrl);int nvme_shutdown_ctrl (struct nvme_ctrl *ctrl);
@@ -734,7 +745,6 @@ int nvme_set_queue_count(struct nvme_ctrl *ctrl, int *count);void nvme_stop_keep_alive (struct nvme_ctrl *ctrl);int nvme_reset_ctrl (struct nvme_ctrl *ctrl);int nvme_reset_ctrl_sync (struct nvme_ctrl *ctrl); -int nvme_try_sched_reset (struct nvme_ctrl *ctrl);int nvme_delete_ctrl (struct nvme_ctrl *ctrl);void nvme_queue_scan (struct nvme_ctrl *ctrl); int nvme_get_log(struct nvme_ctrl *ctrl, u32 nsid, u8 log_page, u8 lsp, u8 csi,
drivers/parport/parport_pc.c +1 -1
@@ -468,7 +468,7 @@ static size_t parport_pc_fifo_write_block_pio(struct parport *port,const unsigned char *bufp = buf;size_t left = length;unsigned long expire = jiffies + port->physport->cad->timeout; -const int fifo =FIFO (port); +const unsigned long fifo =FIFO (port);int poll_for =8 ;/* 80 usecs */ const struct parport_pc_private *priv = port->physport->private_data;const int fifo_depth = priv->fifo_depth;
drivers/pinctrl/devicetree.c +2 -0
@@ -220,6 +220,8 @@ int pinctrl_dt_to_map(struct pinctrl *p, struct pinctrl_dev *pctldev)for (state =0 ; ; state++) {/* Retrieve the pinctrl-* property */ propname =kasprintf (GFP_KERNEL ,"pinctrl-%d" , state); +if (!propname) +return -ENOMEM ; prop =of_find_property (np, propname, &size);kfree (propname);if (!prop) {
drivers/pinctrl/pinctrl-rockchip.c +40 -0
@@ -608,14 +608,54 @@ static void rockchip_get_recalced_mux(struct rockchip_pin_bank *bank, int pin, }static struct rockchip_mux_route_data px30_mux_route_data[] = { +RK_MUXROUTE_SAME (2 ,RK_PB4 ,1 ,0x184 ,BIT (16 +7 )),/* cif-d0m0 */ +RK_MUXROUTE_SAME (3 ,RK_PA1 ,3 ,0x184 ,BIT (16 +7 ) |BIT (7 )),/* cif-d0m1 */ +RK_MUXROUTE_SAME (2 ,RK_PB6 ,1 ,0x184 ,BIT (16 +7 )),/* cif-d1m0 */ +RK_MUXROUTE_SAME (3 ,RK_PA2 ,3 ,0x184 ,BIT (16 +7 ) |BIT (7 )),/* cif-d1m1 */ RK_MUXROUTE_SAME (2 ,RK_PA0 ,1 ,0x184 ,BIT (16 +7 )),/* cif-d2m0 */ RK_MUXROUTE_SAME (3 ,RK_PA3 ,3 ,0x184 ,BIT (16 +7 ) |BIT (7 )),/* cif-d2m1 */ +RK_MUXROUTE_SAME (2 ,RK_PA1 ,1 ,0x184 ,BIT (16 +7 )),/* cif-d3m0 */ +RK_MUXROUTE_SAME (3 ,RK_PA5 ,3 ,0x184 ,BIT (16 +7 ) |BIT (7 )),/* cif-d3m1 */ +RK_MUXROUTE_SAME (2 ,RK_PA2 ,1 ,0x184 ,BIT (16 +7 )),/* cif-d4m0 */ +RK_MUXROUTE_SAME (3 ,RK_PA7 ,3 ,0x184 ,BIT (16 +7 ) |BIT (7 )),/* cif-d4m1 */ +RK_MUXROUTE_SAME (2 ,RK_PA3 ,1 ,0x184 ,BIT (16 +7 )),/* cif-d5m0 */ +RK_MUXROUTE_SAME (3 ,RK_PB0 ,3 ,0x184 ,BIT (16 +7 ) |BIT (7 )),/* cif-d5m1 */ +RK_MUXROUTE_SAME (2 ,RK_PA4 ,1 ,0x184 ,BIT (16 +7 )),/* cif-d6m0 */ +RK_MUXROUTE_SAME (3 ,RK_PB1 ,3 ,0x184 ,BIT (16 +7 ) |BIT (7 )),/* cif-d6m1 */ +RK_MUXROUTE_SAME (2 ,RK_PA5 ,1 ,0x184 ,BIT (16 +7 )),/* cif-d7m0 */ +RK_MUXROUTE_SAME (3 ,RK_PB4 ,3 ,0x184 ,BIT (16 +7 ) |BIT (7 )),/* cif-d7m1 */ +RK_MUXROUTE_SAME (2 ,RK_PA6 ,1 ,0x184 ,BIT (16 +7 )),/* cif-d8m0 */ +RK_MUXROUTE_SAME (3 ,RK_PB6 ,3 ,0x184 ,BIT (16 +7 ) |BIT (7 )),/* cif-d8m1 */ +RK_MUXROUTE_SAME (2 ,RK_PA7 ,1 ,0x184 ,BIT (16 +7 )),/* cif-d9m0 */ +RK_MUXROUTE_SAME (3 ,RK_PB7 ,3 ,0x184 ,BIT (16 +7 ) |BIT (7 )),/* cif-d9m1 */ +RK_MUXROUTE_SAME (2 ,RK_PB7 ,1 ,0x184 ,BIT (16 +7 )),/* cif-d10m0 */ +RK_MUXROUTE_SAME (3 ,RK_PC6 ,3 ,0x184 ,BIT (16 +7 ) |BIT (7 )),/* cif-d10m1 */ +RK_MUXROUTE_SAME (2 ,RK_PC0 ,1 ,0x184 ,BIT (16 +7 )),/* cif-d11m0 */ +RK_MUXROUTE_SAME (3 ,RK_PC7 ,3 ,0x184 ,BIT (16 +7 ) |BIT (7 )),/* cif-d11m1 */ +RK_MUXROUTE_SAME (2 ,RK_PB0 ,1 ,0x184 ,BIT (16 +7 )),/* cif-vsyncm0 */ +RK_MUXROUTE_SAME (3 ,RK_PD1 ,3 ,0x184 ,BIT (16 +7 ) |BIT (7 )),/* cif-vsyncm1 */ +RK_MUXROUTE_SAME (2 ,RK_PB1 ,1 ,0x184 ,BIT (16 +7 )),/* cif-hrefm0 */ +RK_MUXROUTE_SAME (3 ,RK_PD2 ,3 ,0x184 ,BIT (16 +7 ) |BIT (7 )),/* cif-hrefm1 */ +RK_MUXROUTE_SAME (2 ,RK_PB2 ,1 ,0x184 ,BIT (16 +7 )),/* cif-clkinm0 */ +RK_MUXROUTE_SAME (3 ,RK_PD3 ,3 ,0x184 ,BIT (16 +7 ) |BIT (7 )),/* cif-clkinm1 */ +RK_MUXROUTE_SAME (2 ,RK_PB3 ,1 ,0x184 ,BIT (16 +7 )),/* cif-clkoutm0 */ +RK_MUXROUTE_SAME (3 ,RK_PD0 ,3 ,0x184 ,BIT (16 +7 ) |BIT (7 )),/* cif-clkoutm1 */ RK_MUXROUTE_SAME (3 ,RK_PC6 ,2 ,0x184 ,BIT (16 +8 )),/* pdm-m0 */ RK_MUXROUTE_SAME (2 ,RK_PC6 ,1 ,0x184 ,BIT (16 +8 ) |BIT (8 )),/* pdm-m1 */ +RK_MUXROUTE_SAME (3 ,RK_PD3 ,2 ,0x184 ,BIT (16 +8 )),/* pdm-sdi0m0 */ +RK_MUXROUTE_SAME (2 ,RK_PC5 ,2 ,0x184 ,BIT (16 +8 ) |BIT (8 )),/* pdm-sdi0m1 */ RK_MUXROUTE_SAME (1 ,RK_PD3 ,2 ,0x184 ,BIT (16 +10 )),/* uart2-rxm0 */ RK_MUXROUTE_SAME (2 ,RK_PB6 ,2 ,0x184 ,BIT (16 +10 ) |BIT (10 )),/* uart2-rxm1 */ +RK_MUXROUTE_SAME (1 ,RK_PD2 ,2 ,0x184 ,BIT (16 +10 )),/* uart2-txm0 */ +RK_MUXROUTE_SAME (2 ,RK_PB4 ,2 ,0x184 ,BIT (16 +10 ) |BIT (10 )),/* uart2-txm1 */ RK_MUXROUTE_SAME (0 ,RK_PC1 ,2 ,0x184 ,BIT (16 +9 )),/* uart3-rxm0 */ RK_MUXROUTE_SAME (1 ,RK_PB7 ,2 ,0x184 ,BIT (16 +9 ) |BIT (9 )),/* uart3-rxm1 */ +RK_MUXROUTE_SAME (0 ,RK_PC0 ,2 ,0x184 ,BIT (16 +9 )),/* uart3-txm0 */ +RK_MUXROUTE_SAME (1 ,RK_PB6 ,2 ,0x184 ,BIT (16 +9 ) |BIT (9 )),/* uart3-txm1 */ +RK_MUXROUTE_SAME (0 ,RK_PC2 ,2 ,0x184 ,BIT (16 +9 )),/* uart3-ctsm0 */ +RK_MUXROUTE_SAME (1 ,RK_PB4 ,2 ,0x184 ,BIT (16 +9 ) |BIT (9 )),/* uart3-ctsm1 */ +RK_MUXROUTE_SAME (0 ,RK_PC3 ,2 ,0x184 ,BIT (16 +9 )),/* uart3-rtsm0 */ +RK_MUXROUTE_SAME (1 ,RK_PB5 ,2 ,0x184 ,BIT (16 +9 ) |BIT (9 )),/* uart3-rtsm1 */ };static struct rockchip_mux_route_data rk3128_mux_route_data[] = {
drivers/platform/surface/aggregator/ssh_packet_layer.c +20 -4
@@ -1596,16 +1596,32 @@ static void ssh_ptl_timeout_reap(struct work_struct *work)ssh_ptl_tx_wakeup_packet (ptl); } -static bool ssh_ptl_rx_retransmit_check (struct ssh_ptl *ptl,u8 seq) +static bool ssh_ptl_rx_retransmit_check (struct ssh_ptl *ptl,const struct ssh_frame *frame) {int i; +/* +* Ignore unsequenced packets. On some devices (notably Surface Pro 9), +* unsequenced events will always be sent with SEQ=0x00. Attempting to +* detect retransmission would thus just block all events. +* +* While sequence numbers would also allow detection of retransmitted +* packets in unsequenced communication, they have only ever been used +* to cover edge-cases in sequenced transmission. In particular, the +* only instance of packets being retransmitted (that we are aware of) +* is due to an ACK timeout. As this does not happen in unsequenced +* communication, skip the retransmission check for those packets +* entirely. +*/ +if (frame->type ==SSH_FRAME_TYPE_DATA_NSQ ) +return false; +/* * Check if SEQ has been seen recently (i.e. packet was * re-transmitted and we should ignore it). */ for (i =0 ; i <ARRAY_SIZE (ptl->rx.blocked.seqs); i++) { -if (likely (ptl->rx.blocked.seqs[i] != seq)) +if (likely (ptl->rx.blocked.seqs[i] != frame->seq))continue ;ptl_dbg (ptl,"ptl: ignoring repeated data packet\n" );
@@ -1613,7 +1629,7 @@ static bool ssh_ptl_rx_retransmit_check(struct ssh_ptl *ptl, u8 seq) }/* Update list of blocked sequence IDs. */ - ptl->rx.blocked.seqs[ptl->rx.blocked.offset] = seq; + ptl->rx.blocked.seqs[ptl->rx.blocked.offset] = frame->seq; ptl->rx.blocked.offset = (ptl->rx.blocked.offset +1 ) %ARRAY_SIZE (ptl->rx.blocked.seqs);
@@ -1624,7 +1640,7 @@ static void ssh_ptl_rx_dataframe(struct ssh_ptl *ptl, const struct ssh_frame *frame, const struct ssam_span *payload) { - if (ssh_ptl_rx_retransmit_check(ptl, frame->seq)) + if (ssh_ptl_rx_retransmit_check(ptl, frame)) return; ptl->ops.data_received (ptl, payload);
drivers/platform/x86/intel/pmc/pltdrv.c +9 -0
@@ -18,6 +18,8 @@#include <asm/cpu_device_id.h> #include <asm/intel-family.h> +#include <xen/xen.h> +static void intel_pmc_core_release (struct device *dev) {kfree (dev);
@@ -53,6 +55,13 @@ static int __init pmc_core_platform_init(void)if (acpi_dev_present ("INT33A1" ,NULL ,-1 ))return -ENODEV ; +/* +* Skip forcefully attaching the device for VMs. Make an exception for +* Xen dom0, which does have full hardware access. +*/ +if (cpu_feature_enabled (X86_FEATURE_HYPERVISOR ) && !xen_initial_domain ()) +return -ENODEV ; +if (!x86_match_cpu (intel_pmc_core_platform_ids))return -ENODEV ;
drivers/s390/scsi/zfcp_fsf.c +1 -1
@@ -884,7 +884,7 @@ static int zfcp_fsf_req_send(struct zfcp_fsf_req *req)const bool is_srb =zfcp_fsf_req_is_status_read_buffer (req);struct zfcp_adapter *adapter = req->adapter;struct zfcp_qdio *qdio = adapter->qdio; -int req_id = req->req_id; +unsigned long req_id = req->req_id;zfcp_reqlist_add (adapter->req_list, req);
drivers/scsi/scsi_debug.c +5 -1
@@ -7132,8 +7132,12 @@ static int sdebug_add_host_helper(int per_host_idx)dev_set_name (&sdbg_host->dev,"adapter%d" , sdebug_num_hosts); error =device_register (&sdbg_host->dev); -if (error) +if (error) { +spin_lock (&sdebug_host_list_lock); +list_del (&sdbg_host->host_list); +spin_unlock (&sdebug_host_list_lock); goto clean; + } ++sdebug_num_hosts;return 0 ;
drivers/scsi/scsi_transport_sas.c +9 -4
@@ -716,12 +716,17 @@ int sas_phy_add(struct sas_phy *phy)int error; error =device_add (&phy->dev); -if (!error) { -transport_add_device (&phy->dev); -transport_configure_device (&phy->dev); +if (error) +return error; + + error =transport_add_device (&phy->dev); +if (error) { +device_del (&phy->dev); +return error; } +transport_configure_device (&phy->dev); -return error; +return 0 ; }EXPORT_SYMBOL (sas_phy_add);
drivers/siox/siox-core.c +2 -0
@@ -839,6 +839,8 @@ static struct siox_device *siox_device_add(struct siox_master *smaster, err_device_register:/* don't care to make the buffer smaller again */ +put_device (&sdevice->dev); + sdevice =NULL ; err_buf_alloc:siox_master_unlock (smaster);
drivers/slimbus/Kconfig +1 -1
@@ -23,7 +23,7 @@ config SLIM_QCOM_CTRL config SLIM_QCOM_NGD_CTRL tristate "Qualcomm SLIMbus Satellite Non-Generic Device Component" depends on HAS_IOMEM && DMA_ENGINE && NET - depends on QCOM_RPROC_COMMON || COMPILE_TEST + depends on QCOM_RPROC_COMMON || (COMPILE_TEST && !QCOM_RPROC_COMMON) depends on ARCH_QCOM || COMPILE_TEST select QCOM_QMI_HELPERS select QCOM_PDR_HELPERS
drivers/slimbus/stream.c +4 -4
@@ -67,10 +67,10 @@ static const int slim_presence_rate_table[] = {384000 ,768000 ,0 ,/* Reserved */ -110250 , -220500 , -441000 , -882000 , +11025 , +22050 , +44100 , +88200 ,176400 ,352800 , 705600,
drivers/soc/imx/soc-imx8m.c +11 -0
@@ -11,6 +11,7 @@#include <linux/platform_device.h> #include <linux/arm-smccc.h> #include <linux/of.h> +#include <linux/clk.h> #define REV_B1 0x21
@@ -56,6 +57,7 @@ static u32 __init imx8mq_soc_revision(void)void __iomem *ocotp_base;u32 magic;u32 rev; +struct clk *clk; np =of_find_compatible_node (NULL ,NULL ,"fsl,imx8mq-ocotp" );if (!np)
@@ -63,6 +65,13 @@ static u32 __init imx8mq_soc_revision(void) ocotp_base =of_iomap (np,0 );WARN_ON (!ocotp_base); + clk =of_clk_get_by_name (np,NULL ); +if (!clk) { +WARN_ON (!clk); +return 0 ; + } + +clk_prepare_enable (clk);/* * SOC revision on older imx8mq is not available in fuses so query
@@ -79,6 +88,8 @@ static u32 __init imx8mq_soc_revision(void) soc_uid <<=32 ; soc_uid |=readl_relaxed (ocotp_base +OCOTP_UID_LOW ); +clk_disable_unprepare (clk); +clk_put (clk);iounmap (ocotp_base);of_node_put (np);
drivers/spi/spi-stm32.c +1 -0
@@ -886,6 +886,7 @@ static irqreturn_t stm32h7_spi_irq_thread(int irq, void *dev_id) static DEFINE_RATELIMIT_STATE(rs, DEFAULT_RATELIMIT_INTERVAL * 10, 1); +ratelimit_set_flags (&rs,RATELIMIT_MSG_ON_RELEASE );if (__ratelimit (&rs))dev_dbg_ratelimited (spi->dev,"Communication suspended\n" );if (!spi->cur_usedma && (spi->rx_buf && (spi->rx_len >0 )))
drivers/target/loopback/tcm_loop.c +2 -1
@@ -397,6 +397,7 @@ static int tcm_loop_setup_hba_bus(struct tcm_loop_hba *tl_hba, int tcm_loop_host ret =device_register (&tl_hba->dev);if (ret) {pr_err ("device_register() failed for tl_hba->dev: %d\n" , ret); +put_device (&tl_hba->dev);return -ENODEV ; }
@@ -1073,7 +1074,7 @@ static struct se_wwn *tcm_loop_make_scsi_hba(*/ ret =tcm_loop_setup_hba_bus (tl_hba, tcm_loop_hba_no_cnt);if (ret) - goto out; +return ERR_PTR (ret); sh = tl_hba->sh; tcm_loop_hba_no_cnt++;
drivers/tty/n_gsm.c +1 -1
@@ -1577,7 +1577,7 @@ static struct gsm_control *gsm_control_send(struct gsm_mux *gsm, unsigned int command, u8 *data, int clen) { struct gsm_control *ctrl = kzalloc(sizeof(struct gsm_control), -GFP_KERNEL ); +GFP_ATOMIC );unsigned long flags;if (ctrl ==NULL )return NULL ;
drivers/tty/serial/8250/8250_lpss.c +14 -4
@@ -177,6 +177,9 @@ static int ehl_serial_setup(struct lpss8250 *lpss, struct uart_port *port)* matching with the registered General Purpose DMA controllers. */ up->dma = dma; + + lpss->dma_maxburst =16 ; +return 0 ; }
@@ -278,8 +281,13 @@ static int lpss8250_dma_setup(struct lpss8250 *lpss, struct uart_8250_port *portstruct dw_dma_slave *rx_param, *tx_param;struct device *dev = port->port.dev; -if (!lpss->dma_param.dma_dev) +if (!lpss->dma_param.dma_dev) { + dma = port->dma; +if (dma) + goto out_configuration_only; +return 0 ; + } rx_param =devm_kzalloc (dev,sizeof (*rx_param),GFP_KERNEL );if (!rx_param)
@@ -290,16 +298,18 @@ static int lpss8250_dma_setup(struct lpss8250 *lpss, struct uart_8250_port *portreturn -ENOMEM ; *rx_param = lpss->dma_param; - dma->rxconf.src_maxburst = lpss->dma_maxburst; - *tx_param = lpss->dma_param; - dma->txconf.dst_maxburst = lpss->dma_maxburst; dma->fn = lpss8250_dma_filter; dma->rx_param = rx_param; dma->tx_param = tx_param; port->dma = dma; + +out_configuration_only: + dma->rxconf.src_maxburst = lpss->dma_maxburst; + dma->txconf.dst_maxburst = lpss->dma_maxburst; +return 0 ; }
drivers/tty/serial/8250/8250_omap.c +26 -19
82 lines not on this page · raw message
drivers/tty/serial/8250/8250_port.c +5 -2
@@ -1885,10 +1885,13 @@ EXPORT_SYMBOL_GPL(serial8250_modem_status);static bool handle_rx_dma (struct uart_8250_port *up,unsigned int iir) {switch (iir &0x3f ) { -case UART_IIR_RX_TIMEOUT : -serial8250_rx_dma_flush (up); +case UART_IIR_RDI : +if (!up->dma->rx_running) +break ; fallthrough;case UART_IIR_RLSI : +case UART_IIR_RX_TIMEOUT : +serial8250_rx_dma_flush (up);return true; }return up->dma->rx_dma (up);
drivers/tty/serial/imx.c +1 -0
@@ -2563,6 +2563,7 @@ static const struct dev_pm_ops imx_uart_pm_ops = { .suspend_noirq = imx_uart_suspend_noirq, .resume_noirq = imx_uart_resume_noirq, .freeze_noirq = imx_uart_suspend_noirq, + .thaw_noirq = imx_uart_resume_noirq, .restore_noirq = imx_uart_resume_noirq, .suspend = imx_uart_suspend, .resume = imx_uart_resume,
drivers/usb/cdns3/host.c +28 -28
71 lines not on this page · raw message
drivers/usb/chipidea/otg_fsm.c +2 -0
@@ -256,8 +256,10 @@ static void ci_otg_del_timer(struct ci_hdrc *ci, enum otg_fsm_timer t) ci->enabled_otg_timer_bits &= ~(1 << t);if (ci->next_otg_timer == t) {if (ci->enabled_otg_timer_bits ==0 ) { +spin_unlock_irqrestore (&ci->lock, flags);/* No enabled timers after delete it */ hrtimer_cancel (&ci->otg_fsm_hrtimer); +spin_lock_irqsave (&ci->lock, flags); ci->next_otg_timer =NUM_OTG_FSM_TIMERS ; }else {/* Find the next timer */
drivers/usb/core/quirks.c +3 -0
@@ -362,6 +362,9 @@ static const struct usb_device_id usb_quirk_list[] = { { USB_DEVICE(0x0781, 0x5583), .driver_info = USB_QUIRK_NO_LPM }, { USB_DEVICE(0x0781, 0x5591), .driver_info = USB_QUIRK_NO_LPM }, + /* Realforce 87U Keyboard */ + { USB_DEVICE(0x0853, 0x011b), .driver_info = USB_QUIRK_NO_LPM }, + /* M-Systems Flash Disk Pioneers */ { USB_DEVICE(0x08ec, 0x1000), .driver_info = USB_QUIRK_RESET_RESUME },
drivers/usb/dwc3/host.c +0 -10
@@ -10,13 +10,8 @@#include <linux/acpi.h> #include <linux/platform_device.h> -#include "../host/xhci-plat.h" #include "core.h" -static const struct xhci_plat_priv dwc3_xhci_plat_priv = { - .quirks =XHCI_SKIP_PHY_INIT , -}; -static int dwc3_host_get_irq (struct dwc3 *dwc) {struct platform_device *dwc3_pdev =to_platform_device (dwc->dev);
@@ -92,11 +87,6 @@ int dwc3_host_init(struct dwc3 *dwc) goto err; } - ret =platform_device_add_data (xhci, &dwc3_xhci_plat_priv, -sizeof (dwc3_xhci_plat_priv)); -if (ret) - goto err; -memset (props,0 ,sizeof (struct property_entry ) *ARRAY_SIZE (props));if (dwc->usb3_lpm_capable)
drivers/usb/host/bcma-hcd.c +6 -4
@@ -285,7 +285,7 @@ static void bcma_hci_platform_power_gpio(struct bcma_device *dev, bool val) {struct bcma_hcd_device *usb_dev =bcma_get_drvdata (dev); -if (IS_ERR_OR_NULL (usb_dev->gpio_desc)) +if (!usb_dev->gpio_desc)return ;gpiod_set_value (usb_dev->gpio_desc, val);
@@ -406,9 +406,11 @@ static int bcma_hcd_probe(struct bcma_device *core)return -ENOMEM ; usb_dev->core = core; -if (core->dev.of_node) - usb_dev->gpio_desc =devm_gpiod_get (&core->dev,"vcc" , -GPIOD_OUT_HIGH ); + usb_dev->gpio_desc =devm_gpiod_get_optional (&core->dev,"vcc" , +GPIOD_OUT_HIGH ); +if (IS_ERR (usb_dev->gpio_desc)) +return dev_err_probe (&core->dev,PTR_ERR (usb_dev->gpio_desc), +"error obtaining VCC GPIO" );switch (core->id.id) {case BCMA_CORE_USB20_HOST :
drivers/usb/serial/option.c +17 -2
@@ -162,6 +162,8 @@ static void option_instat_callback(struct urb *urb);#define NOVATELWIRELESS_PRODUCT_G2 0xA010#define NOVATELWIRELESS_PRODUCT_MC551 0xB001 +#define UBLOX_VENDOR_ID 0x1546 +/* AMOI PRODUCTS */ #define AMOI_VENDOR_ID 0x1614#define AMOI_PRODUCT_H01 0x0800
@@ -240,7 +242,6 @@ static void option_instat_callback(struct urb *urb);#define QUECTEL_PRODUCT_UC15 0x9090/* These u-blox products use Qualcomm's vendor ID */ #define UBLOX_PRODUCT_R410M 0x90b2 -#define UBLOX_PRODUCT_R6XX 0x90fa/* These Yuga products use Qualcomm's vendor ID */ #define YUGA_PRODUCT_CLM920_NC5 0x9625
@@ -581,6 +582,9 @@ static void option_instat_callback(struct urb *urb);#define OPPO_VENDOR_ID 0x22d9#define OPPO_PRODUCT_R11 0x276c +/* Sierra Wireless products */ +#define SIERRA_VENDOR_ID 0x1199 +#define SIERRA_PRODUCT_EM9191 0x90d3/* Device flags */
@@ -1124,8 +1128,16 @@ static const struct usb_device_id option_ids[] = {/* u-blox products using Qualcomm vendor ID */ { USB_DEVICE(QUALCOMM_VENDOR_ID, UBLOX_PRODUCT_R410M), .driver_info = RSVD(1) | RSVD(3) }, - { USB_DEVICE(QUALCOMM_VENDOR_ID, UBLOX_PRODUCT_R6XX), + { USB_DEVICE(QUALCOMM_VENDOR_ID, 0x908b), /* u-blox LARA-R6 00B */ + .driver_info = RSVD(4) }, + { USB_DEVICE(QUALCOMM_VENDOR_ID, 0x90fa), .driver_info = RSVD(3) }, +/* u-blox products */ + { USB_DEVICE(UBLOX_VENDOR_ID, 0x1341) }, /* u-blox LARA-L6 */ + { USB_DEVICE(UBLOX_VENDOR_ID, 0x1342), /* u-blox LARA-L6 (RMNET) */ + .driver_info = RSVD(4) }, + { USB_DEVICE(UBLOX_VENDOR_ID, 0x1343), /* u-blox LARA-L6 (ECM) */ + .driver_info = RSVD(4) },/* Quectel products using Quectel vendor ID */ { USB_DEVICE_AND_INTERFACE_INFO(QUECTEL_VENDOR_ID, QUECTEL_PRODUCT_EC21, 0xff, 0xff, 0xff), .driver_info = NUMEP2 },
@@ -2167,6 +2179,7 @@ static const struct usb_device_id option_ids[] = { { USB_DEVICE_INTERFACE_CLASS(0x2cb7, 0x010a, 0xff) }, /* Fibocom MA510 (ECM mode) */ { USB_DEVICE_AND_INTERFACE_INFO(0x2cb7, 0x010b, 0xff, 0xff, 0x30) }, /* Fibocom FG150 Diag */ { USB_DEVICE_AND_INTERFACE_INFO(0x2cb7, 0x010b, 0xff, 0, 0) }, /* Fibocom FG150 AT */ + { USB_DEVICE_INTERFACE_CLASS(0x2cb7, 0x0111, 0xff) }, /* Fibocom FM160 (MBIM mode) */ { USB_DEVICE_INTERFACE_CLASS(0x2cb7, 0x01a0, 0xff) }, /* Fibocom NL668-AM/NL652-EU (laptop MBIM) */ { USB_DEVICE_INTERFACE_CLASS(0x2cb7, 0x01a2, 0xff) }, /* Fibocom FM101-GL (laptop MBIM) */ { USB_DEVICE_INTERFACE_CLASS(0x2cb7, 0x01a4, 0xff), /* Fibocom FM101-GL (laptop MBIM) */
@@ -2176,6 +2189,8 @@ static const struct usb_device_id option_ids[] = { { USB_DEVICE_INTERFACE_CLASS(0x305a, 0x1405, 0xff) }, /* GosunCn GM500 MBIM */ { USB_DEVICE_INTERFACE_CLASS(0x305a, 0x1406, 0xff) }, /* GosunCn GM500 ECM/NCM */ { USB_DEVICE_AND_INTERFACE_INFO(OPPO_VENDOR_ID, OPPO_PRODUCT_R11, 0xff, 0xff, 0x30) }, + { USB_DEVICE_AND_INTERFACE_INFO(SIERRA_VENDOR_ID, SIERRA_PRODUCT_EM9191, 0xff, 0xff, 0x30) }, + { USB_DEVICE_AND_INTERFACE_INFO(SIERRA_VENDOR_ID, SIERRA_PRODUCT_EM9191, 0xff, 0, 0) }, { } /* Terminating entry */ };MODULE_DEVICE_TABLE (usb, option_ids);
drivers/usb/typec/mux/intel_pmc_mux.c +13 -2
@@ -352,13 +352,24 @@ pmc_usb_mux_usb4(struct pmc_usb_port *port, struct typec_mux_state *state)return pmc_usb_command (port, (void *)&req,sizeof (req)); } -static int pmc_usb_mux_safe_state (struct pmc_usb_port *port) +static int pmc_usb_mux_safe_state (struct pmc_usb_port *port, +struct typec_mux_state *state) {u8 msg;if (IOM_PORT_ACTIVITY_IS (port->iom_status,SAFE_MODE ))return 0 ; +if ((IOM_PORT_ACTIVITY_IS (port->iom_status,DP ) || +IOM_PORT_ACTIVITY_IS (port->iom_status,DP_MFD )) && + state->alt && state->alt->svid ==USB_TYPEC_DP_SID ) +return 0 ; + +if ((IOM_PORT_ACTIVITY_IS (port->iom_status,TBT ) || +IOM_PORT_ACTIVITY_IS (port->iom_status,ALT_MODE_TBT_USB )) && + state->alt && state->alt->svid ==USB_TYPEC_TBT_SID ) +return 0 ; + msg =PMC_USB_SAFE_MODE ; msg |= port->usb3_port <<PMC_USB_MSG_USB3_PORT_SHIFT ;
@@ -426,7 +437,7 @@ pmc_usb_mux_set(struct typec_mux *mux, struct typec_mux_state *state)return 0 ;if (state->mode ==TYPEC_STATE_SAFE ) -return pmc_usb_mux_safe_state (port); +return pmc_usb_mux_safe_state (port, state);if (state->mode ==TYPEC_STATE_USB )return pmc_usb_connect (port, port->role);
drivers/xen/pcpu.c +1 -1
@@ -228,7 +228,7 @@ static int register_pcpu(struct pcpu *pcpu) err =device_register (dev);if (err) { -pcpu_release (dev); +put_device (dev);return err; }
fs/btrfs/raid56.c +4 -2
@@ -2728,8 +2728,10 @@ raid56_alloc_missing_rbio(struct btrfs_fs_info *fs_info, struct bio *bio, rbio->faila =find_logical_bio_stripe (rbio, bio);if (rbio->faila ==-1 ) { -BUG (); -kfree (rbio); +btrfs_warn_rl (fs_info, +"can not determine the failed stripe number for full stripe %llu" , + bioc->raid_map[0 ]); +__free_raid_bio (rbio);return NULL ; }
fs/btrfs/tests/qgroup-tests.c +4 -12
@@ -225,7 +225,6 @@ static int test_no_shared_qgroup(struct btrfs_root *root,*/ ret =btrfs_find_all_roots (&trans, fs_info, nodesize,0 , &old_roots, false);if (ret) { -ulist_free (old_roots);test_err ("couldn't find old roots: %d" , ret);return ret; }
@@ -240,7 +239,6 @@ static int test_no_shared_qgroup(struct btrfs_root *root, ret =btrfs_find_all_roots (&trans, fs_info, nodesize,0 , &new_roots, false);if (ret) {ulist_free (old_roots); -ulist_free (new_roots);test_err ("couldn't find old roots: %d" , ret);return ret; }
@@ -252,17 +250,18 @@ static int test_no_shared_qgroup(struct btrfs_root *root,return ret; } +/* btrfs_qgroup_account_extent() always frees the ulists passed to it. */ + old_roots =NULL ; + new_roots =NULL ; +if (btrfs_verify_qgroup_counts (fs_info,BTRFS_FS_TREE_OBJECTID , nodesize, nodesize)) {test_err ("qgroup counts didn't match expected values" );return -EINVAL ; } - old_roots =NULL ; - new_roots =NULL ; ret =btrfs_find_all_roots (&trans, fs_info, nodesize,0 , &old_roots, false);if (ret) { -ulist_free (old_roots);test_err ("couldn't find old roots: %d" , ret);return ret; }
@@ -276,7 +275,6 @@ static int test_no_shared_qgroup(struct btrfs_root *root, ret =btrfs_find_all_roots (&trans, fs_info, nodesize,0 , &new_roots, false);if (ret) {ulist_free (old_roots); -ulist_free (new_roots);test_err ("couldn't find old roots: %d" , ret);return ret; }
@@ -326,7 +324,6 @@ static int test_multiple_refs(struct btrfs_root *root, ret =btrfs_find_all_roots (&trans, fs_info, nodesize,0 , &old_roots, false);if (ret) { -ulist_free (old_roots);test_err ("couldn't find old roots: %d" , ret);return ret; }
@@ -341,7 +338,6 @@ static int test_multiple_refs(struct btrfs_root *root, ret =btrfs_find_all_roots (&trans, fs_info, nodesize,0 , &new_roots, false);if (ret) {ulist_free (old_roots); -ulist_free (new_roots);test_err ("couldn't find old roots: %d" , ret);return ret; }
@@ -361,7 +357,6 @@ static int test_multiple_refs(struct btrfs_root *root, ret =btrfs_find_all_roots (&trans, fs_info, nodesize,0 , &old_roots, false);if (ret) { -ulist_free (old_roots);test_err ("couldn't find old roots: %d" , ret);return ret; }
@@ -376,7 +371,6 @@ static int test_multiple_refs(struct btrfs_root *root, ret =btrfs_find_all_roots (&trans, fs_info, nodesize,0 , &new_roots, false);if (ret) {ulist_free (old_roots); -ulist_free (new_roots);test_err ("couldn't find old roots: %d" , ret);return ret; }
@@ -402,7 +396,6 @@ static int test_multiple_refs(struct btrfs_root *root, ret =btrfs_find_all_roots (&trans, fs_info, nodesize,0 , &old_roots, false);if (ret) { -ulist_free (old_roots);test_err ("couldn't find old roots: %d" , ret);return ret; }
@@ -417,7 +410,6 @@ static int test_multiple_refs(struct btrfs_root *root, ret =btrfs_find_all_roots (&trans, fs_info, nodesize,0 , &new_roots, false);if (ret) {ulist_free (old_roots); -ulist_free (new_roots);test_err ("couldn't find old roots: %d" , ret);return ret; }
fs/buffer.c +2 -2
@@ -2352,7 +2352,7 @@ int generic_cont_expand_simple(struct inode *inode, loff_t size) {struct address_space *mapping = inode->i_mapping;struct page *page; -void *fsdata; +void *fsdata =NULL ;int err; err =inode_newsize_ok (inode, size);
@@ -2378,7 +2378,7 @@ static int cont_expand_zero(struct file *file, struct address_space *mapping,struct inode *inode = mapping->host;unsigned int blocksize =i_blocksize (inode);struct page *page; -void *fsdata; +void *fsdata =NULL ;pgoff_t index, curidx;loff_t curpos;unsigned zerofrom, offset, len;
fs/cifs/ioctl.c +2 -2
@@ -342,7 +342,7 @@ long cifs_ioctl(struct file *filep, unsigned int command, unsigned long arg) rc =put_user (ExtAttrBits &FS_FL_USER_VISIBLE , (int __user *)arg); -if (rc !=EOPNOTSUPP ) +if (rc != -EOPNOTSUPP ) break; }#endif /* CONFIG_CIFS_POSIX */
@@ -371,7 +371,7 @@ long cifs_ioctl(struct file *filep, unsigned int command, unsigned long arg)* pSMBFile->fid.netfid, * extAttrBits, * &ExtAttrMask); -* if (rc != EOPNOTSUPP) +* if (rc != -EOPNOTSUPP) * break; */
fs/cifs/smb2ops.c +4 -0
@@ -1361,6 +1361,8 @@ smb2_set_ea(const unsigned int xid, struct cifs_tcon *tcon,COMPOUND_FID , current->tgid,FILE_FULL_EA_INFORMATION , SMB2_O_INFO_FILE, 0, data, size); +if (rc) + goto sea_exit;smb2_set_next_command (tcon, &rqst[1 ]);smb2_set_related (&rqst[1 ]);
@@ -1371,6 +1373,8 @@ smb2_set_ea(const unsigned int xid, struct cifs_tcon *tcon, rqst[2 ].rq_nvec =1 ; rc =SMB2_close_init (tcon, server, &rqst[2 ],COMPOUND_FID ,COMPOUND_FID , false); +if (rc) + goto sea_exit;smb2_set_related (&rqst[2 ]); rc = compound_send_recv(xid, ses, server,
fs/gfs2/ops_fstype.c +11 -6
@@ -180,7 +180,10 @@ static int gfs2_check_sb(struct gfs2_sbd *sdp, int silent)pr_warn ("Invalid block size\n" );return -EINVAL ; } - +if (sb->sb_bsize_shift !=ffs (sb->sb_bsize) -1 ) { +pr_warn ("Invalid block size shift\n" ); +return -EINVAL ; + }return 0 ; }
@@ -385,8 +388,10 @@ static int init_names(struct gfs2_sbd *sdp, int silent)if (!table[0 ]) table = sdp->sd_vfs->s_id; -strlcpy (sdp->sd_proto_name, proto,GFS2_FSNAME_LEN ); -strlcpy (sdp->sd_table_name, table,GFS2_FSNAME_LEN ); +BUILD_BUG_ON (GFS2_LOCKNAME_LEN >GFS2_FSNAME_LEN ); + +strscpy (sdp->sd_proto_name, proto,GFS2_LOCKNAME_LEN ); +strscpy (sdp->sd_table_name, table,GFS2_LOCKNAME_LEN ); table = sdp->sd_table_name;while ((table =strchr (table,'/' )))
@@ -1443,13 +1448,13 @@ static int gfs2_parse_param(struct fs_context *fc, struct fs_parameter *param)switch (o) {case Opt_lockproto: -strlcpy (args->ar_lockproto, param->string,GFS2_LOCKNAME_LEN ); +strscpy (args->ar_lockproto, param->string,GFS2_LOCKNAME_LEN );break ;case Opt_locktable: -strlcpy (args->ar_locktable, param->string,GFS2_LOCKNAME_LEN ); +strscpy (args->ar_locktable, param->string,GFS2_LOCKNAME_LEN );break ;case Opt_hostdata: -strlcpy (args->ar_hostdata, param->string,GFS2_LOCKNAME_LEN ); +strscpy (args->ar_hostdata, param->string,GFS2_LOCKNAME_LEN );break ;case Opt_spectator: args->ar_spectator =1 ;
fs/hugetlbfs/inode.c +6 -7
@@ -361,6 +361,12 @@ static ssize_t hugetlbfs_read_iter(struct kiocb *iocb, struct iov_iter *to) }else {unlock_page (page); +if (PageHWPoison (page)) { +put_page (page); + retval = -EIO ; +break ; + } +/* * We have the page, copy it to user space buffer. */
@@ -984,13 +990,6 @@ static int hugetlbfs_migrate_page(struct address_space *mapping,static int hugetlbfs_error_remove_page (struct address_space *mapping,struct page *page) { -struct inode *inode = mapping->host; -pgoff_t index = page->index; - -remove_huge_page (page); -if (unlikely (hugetlb_unreserve_pages (inode, index, index +1 ,1 ))) -hugetlb_fix_reserve_counts (inode); -return 0 ; }
fs/namei.c +1 -1
@@ -5013,7 +5013,7 @@ int __page_symlink(struct inode *inode, const char *symname, int len, int nofs) {struct address_space *mapping = inode->i_mapping;struct page *page; -void *fsdata; +void *fsdata =NULL ;int err;unsigned int flags =0 ;if (nofs)
fs/nfs/nfs4proc.c +4 -2
@@ -7118,6 +7118,7 @@ static void nfs4_lock_done(struct rpc_task *task, void *calldata) {struct nfs4_lockdata *data = calldata;struct nfs4_lock_state *lsp = data->lsp; +struct nfs_server *server =NFS_SERVER (d_inode (data->ctx->dentry));dprintk ("%s: begin!\n" , __func__);
@@ -7127,8 +7128,7 @@ static void nfs4_lock_done(struct rpc_task *task, void *calldata) data->rpc_status = task->tk_status;switch (task->tk_status) {case 0 : -renew_lease (NFS_SERVER (d_inode (data->ctx->dentry)), - data->timestamp); +renew_lease (server, data->timestamp);if (data->arg.new_lock && !data->cancelled) { data->fl.fl_flags &= ~(FL_SLEEP |FL_ACCESS );if (locks_lock_inode_wait (lsp->ls_state->inode, &data->fl) <0 )
@@ -7149,6 +7149,8 @@ static void nfs4_lock_done(struct rpc_task *task, void *calldata)if (!nfs4_stateid_match (&data->arg.open_stateid, &lsp->ls_state->open_stateid)) goto out_restart; +else if (nfs4_async_handle_error (task, server, lsp->ls_state,NULL ) == -EAGAIN ) + goto out_restart; }else if (!nfs4_stateid_match (&data->arg.lock_stateid, &lsp->ls_stateid)) goto out_restart;
fs/ntfs/attrib.c +24 -4
@@ -594,17 +594,37 @@ static int ntfs_attr_find(const ATTR_TYPE type, const ntfschar *name,for (;; a = (ATTR_RECORD *)((u8 *)a +le32_to_cpu (a->length))) {u8 *mrec_end = (u8 *)ctx->mrec +le32_to_cpu (ctx->mrec->bytes_allocated); -u8 *name_end = (u8 *)a +le16_to_cpu (a->name_offset) + - a->name_length *sizeof (ntfschar); -if ((u8 *)a < (u8 *)ctx->mrec || (u8 *)a > mrec_end || - name_end > mrec_end) +u8 *name_end; + +/* check whether ATTR_RECORD wrap */ +if ((u8 *)a < (u8 *)ctx->mrec) +break ; + +/* check whether Attribute Record Header is within bounds */ +if ((u8 *)a > mrec_end || + (u8 *)a +sizeof (ATTR_RECORD ) > mrec_end) +break ; + +/* check whether ATTR_RECORD's name is within bounds */ + name_end = (u8 *)a +le16_to_cpu (a->name_offset) + + a->name_length *sizeof (ntfschar); +if (name_end > mrec_end)break ; + ctx->attr = a;if (unlikely (le32_to_cpu (a->type) >le32_to_cpu (type) || a->type ==AT_END ))return -ENOENT ;if (unlikely (!a->length))break ; + +/* check whether ATTR_RECORD's length wrap */ +if ((u8 *)a +le32_to_cpu (a->length) < (u8 *)a) +break ; +/* check whether ATTR_RECORD's length is within bounds */ +if ((u8 *)a +le32_to_cpu (a->length) > mrec_end) +break ; +if (a->type != type)continue ;/*
fs/ntfs/inode.c +7 -0
@@ -1829,6 +1829,13 @@ int ntfs_read_inode_mount(struct inode *vi) goto err_out; } +/* Sanity check offset to the first attribute */ +if (le16_to_cpu (m->attrs_offset) >=le32_to_cpu (m->bytes_allocated)) { +ntfs_error (sb,"Incorrect mft offset to the first attribute %u in superblock." , +le16_to_cpu (m->attrs_offset)); + goto err_out; + } +/* Need this to sanity check attribute list references to $MFT. */ vi->i_generation = ni->seq_no =le16_to_cpu (m->sequence_number);
include/linux/platform_data/x86/intel-spi.h +4 -2
@@ -19,11 +19,13 @@ enum intel_spi_type {/** * struct intel_spi_boardinfo - Board specific data for Intel SPI driver * @type: Type which this controller is compatible with -* @writeable: The chip is writeable +* @set_writeable: Try to make the chip writeable (optional) +* @data: Data to be passed to @set_writeable can be %NULL */ struct intel_spi_boardinfo {enum intel_spi_type type; -bool writeable; +bool (*set_writeable)(void __iomem *base,void *data); +void *data; };#endif /* INTEL_SPI_PDATA_H */
include/linux/ring_buffer.h +1 -1
@@ -100,7 +100,7 @@ __ring_buffer_alloc(unsigned long size, unsigned flags, struct lock_class_key *kint ring_buffer_wait (struct trace_buffer *buffer,int cpu,int full);__poll_t ring_buffer_poll_wait (struct trace_buffer *buffer,int cpu, -struct file *filp,poll_table *poll_table); +struct file *filp,poll_table *poll_table,int full);void ring_buffer_wake_waiters (struct trace_buffer *buffer,int cpu);#define RING_BUFFER_ALL_CPUS -1
include/linux/trace.h +2 -2
@@ -26,13 +26,13 @@ struct trace_export {int flags; }; +struct trace_array ; +#ifdef CONFIG_TRACING int register_ftrace_export (struct trace_export *export);int unregister_ftrace_export (struct trace_export *export); -struct trace_array ; -void trace_printk_init_buffers (void ); __printf(3, 4) int trace_array_printk(struct trace_array *tr, unsigned long ip,
include/linux/wireless.h +9 -1
@@ -26,7 +26,15 @@ struct compat_iw_point {struct __compat_iw_event {__u16 len;/* Real length of this stuff */ __u16 cmd;/* Wireless IOCTL */ -compat_caddr_t pointer; + +union { +compat_caddr_t pointer; + +/* we need ptr_bytes to make memcpy() run-time destination +* buffer bounds checking happy, nothing special +*/ + DECLARE_FLEX_ARRAY(__u8, ptr_bytes); + }; };#define IW_EV_COMPAT_LCP_LEN offsetof(struct __compat_iw_event, pointer)#define IW_EV_COMPAT_POINT_OFF offsetof(struct compat_iw_point, length)
include/net/ip.h +1 -1
@@ -559,7 +559,7 @@ static inline void iph_to_flow_copy_v4addrs(struct flow_keys *flow, BUILD_BUG_ON(offsetof(typeof(flow->addrs), v4addrs.dst) != offsetof(typeof(flow->addrs), v4addrs.src) + sizeof(flow->addrs.v4addrs.src)); -memcpy (&flow->addrs.v4addrs, &iph->saddr,sizeof (flow->addrs.v4addrs)); +memcpy (&flow->addrs.v4addrs, &iph->addrs,sizeof (flow->addrs.v4addrs)); flow->control.addr_type =FLOW_DISSECTOR_KEY_IPV4_ADDRS ; }
include/net/ipv6.h +1 -1
@@ -843,7 +843,7 @@ static inline void iph_to_flow_copy_v6addrs(struct flow_keys *flow, BUILD_BUG_ON(offsetof(typeof(flow->addrs), v6addrs.dst) != offsetof(typeof(flow->addrs), v6addrs.src) + sizeof(flow->addrs.v6addrs.src)); -memcpy (&flow->addrs.v6addrs, &iph->saddr,sizeof (flow->addrs.v6addrs)); +memcpy (&flow->addrs.v6addrs, &iph->addrs,sizeof (flow->addrs.v6addrs)); flow->control.addr_type =FLOW_DISSECTOR_KEY_IPV6_ADDRS ; }
include/soc/at91/sama7-ddr.h +4 -1
@@ -26,7 +26,10 @@#define DDR3PHY_PGSR (0x0C)/* DDR3PHY PHY General Status Register */ #define DDR3PHY_PGSR_IDONE (1 << 0)/* Initialization Done */ -#define DDR3PHY_ACIOCR (0x24)/* DDR3PHY AC I/O Configuration Register */ +#define DDR3PHY_ACDLLCR (0x14)/* DDR3PHY AC DLL Control Register */ +#define DDR3PHY_ACDLLCR_DLLSRST (1 << 30)/* DLL Soft Reset */ + +#define DDR3PHY_ACIOCR (0x24)/* DDR3PHY AC I/O Configuration Register */ #define DDR3PHY_ACIOCR_CSPDD_CS0 (1 << 18)/* CS#[0] Power Down Driver */ #define DDR3PHY_ACIOCR_CKPDD_CK0 (1 << 8)/* CK[0] Power Down Driver */ #define DDR3PHY_ACIORC_ACPDD (1 << 3)/* AC Power Down Driver */
include/uapi/linux/ip.h +4 -2
@@ -100,8 +100,10 @@ struct iphdr {__u8 ttl;__u8 protocol;__sum16 check; -__be32 saddr; -__be32 daddr; + __struct_group(/* no tag */, addrs, /* no attrs */, + __be32 saddr; +__be32 daddr; + );/*The options start here. */ };
include/uapi/linux/ipv6.h +4 -2
@@ -130,8 +130,10 @@ struct ipv6hdr {__u8 nexthdr;__u8 hop_limit; -struct in6_addr saddr; -struct in6_addr daddr; + __struct_group(/* no tag */, addrs, /* no attrs */, +struct in6_addr saddr; +struct in6_addr daddr; + ); };
kernel/bpf/percpu_freelist.c +11 -12
@@ -102,22 +102,21 @@ void pcpu_freelist_populate(struct pcpu_freelist *s, void *buf, u32 elem_size, u32 nr_elems) {struct pcpu_freelist_head *head; -int i, cpu, pcpu_entries; +unsigned int cpu, cpu_idx, i, j, n, m; - pcpu_entries = nr_elems /num_possible_cpus () +1 ; - i =0 ; + n = nr_elems /num_possible_cpus (); + m = nr_elems %num_possible_cpus (); + cpu_idx =0 ;for_each_possible_cpu (cpu) { -again: head =per_cpu_ptr (s->freelist, cpu); -/* No locking required as this is not visible yet. */ -pcpu_freelist_push_node (head, buf); - i++; - buf += elem_size; -if (i == nr_elems) -break ; -if (i % pcpu_entries) - goto again; + j = n + (cpu_idx < m ?1 :0 ); +for (i =0 ; i < j; i++) { +/* No locking required as this is not visible yet. */ +pcpu_freelist_push_node (head, buf); + buf += elem_size; + } + cpu_idx++; } }
kernel/bpf/verifier.c +9 -5
@@ -5808,11 +5808,11 @@ static int __check_func_call(struct bpf_verifier_env *env, struct bpf_insn *insn/* Transfer references to the callee */ err =copy_reference_state (callee, caller);if (err) -return err; + goto err_out; err =set_callee_state_cb (env, caller, callee, *insn_idx);if (err) -return err; + goto err_out;clear_caller_saved_regs (env, caller->regs);
@@ -5829,6 +5829,11 @@ static int __check_func_call(struct bpf_verifier_env *env, struct bpf_insn *insnprint_verifier_state (env, callee); }return 0 ; + +err_out: +free_func_state (callee); + state->frame[state->curframe +1 ] =NULL ; +return err; } int map_set_for_each_callback_args(struct bpf_verifier_env *env,
@@ -5966,8 +5971,7 @@ static int prepare_func_exit(struct bpf_verifier_env *env, int *insn_idx)return -EINVAL ; } - state->curframe--; - caller = state->frame[state->curframe]; + caller = state->frame[state->curframe -1 ];if (callee->in_callback_fn) {/* enforce R0 return value range [0, 1]. */ struct tnum range =tnum_range (0 ,1 );
@@ -6006,7 +6010,7 @@ static int prepare_func_exit(struct bpf_verifier_env *env, int *insn_idx) }/* clear everything in the callee */ free_func_state (callee); - state->frame[state->curframe +1 ] =NULL ; + state->frame[state->curframe--] =NULL ;return 0 ; }
kernel/events/core.c +19 -6
@@ -9323,14 +9323,27 @@ static int __perf_event_overflow(struct perf_event *event, }if (event->attr.sigtrap) { -/* -* Should not be able to return to user space without processing -* pending_sigtrap (kernel events can overflow multiple times). -*/ -WARN_ON_ONCE (event->pending_sigtrap && event->attr.exclude_kernel); +unsigned int pending_id =1 ; + +if (regs) + pending_id =hash32_ptr ((void *)instruction_pointer (regs)) ?:1 ;if (!event->pending_sigtrap) { - event->pending_sigtrap =1 ; + event->pending_sigtrap = pending_id;local_inc (&event->ctx->nr_pending); + }else if (event->attr.exclude_kernel) { +/* +* Should not be able to return to user space without +* consuming pending_sigtrap; with exceptions: +* +* 1. Where !exclude_kernel, events can overflow again +* in the kernel without returning to user space. +* +* 2. Events that can overflow again before the IRQ- +* work without user space progress (e.g. hrtimer). +* To approximate progress (with false negatives), +* check 32-bit hash of the current IP. +*/ +WARN_ON_ONCE (event->pending_sigtrap != pending_id); } event->pending_addr = data->addr;irq_work_queue (&event->pending_irq);
kernel/kprobes.c +7 -1
@@ -1760,7 +1760,13 @@ static int __unregister_kprobe_top(struct kprobe *p)if ((list_p != p) && (list_p->post_handler)) goto noclean; } - ap->post_handler =NULL ; +/* +* For the kprobe-on-ftrace case, we keep the +* post_handler setting to identify this aggrprobe +* armed with kprobe_ipmodify_ops. +*/ +if (!kprobe_ftrace (ap)) + ap->post_handler =NULL ; } noclean:/*
kernel/trace/ftrace.c +3 -2
@@ -1295,6 +1295,7 @@ static int ftrace_add_mod(struct trace_array *tr,if (!ftrace_mod)return -ENOMEM ; +INIT_LIST_HEAD (&ftrace_mod->list); ftrace_mod->func =kstrdup (func,GFP_KERNEL ); ftrace_mod->module =kstrdup (module,GFP_KERNEL ); ftrace_mod->enable = enable;
@@ -3174,7 +3175,7 @@ static int ftrace_allocate_records(struct ftrace_page *pg, int count)/* if we can't allocate this size, try something smaller */ if (!order)return -ENOMEM ; - order >>=1 ; + order--; goto again; }
@@ -6870,7 +6871,7 @@ void __init ftrace_init(void) }pr_info ("ftrace: allocating %ld entries in %ld pages\n" , - count, count /ENTRIES_PER_PAGE +1 ); + count,DIV_ROUND_UP (count,ENTRIES_PER_PAGE )); last_ftrace_enabled = ftrace_enabled =1 ;
kernel/trace/kprobe_event_gen_test.c +32 -16
84 lines not on this page · raw message
kernel/trace/ring_buffer.c +50 -21
89 lines not on this page · raw message
mm/memory-failure.c +77 -34
111 lines not on this page · raw message
mm/shmem.c +45 -6
51 lines not on this page · raw message
net/9p/trans_fd.c +29 -16
45 lines not on this page · raw message
net/kcm/kcmsock.c +9 -53
62 lines not on this page · raw message
sound/soc/codecs/wm8962.c +52 -2
54 lines not on this page · raw message
tools/testing/selftests/futex/functional/Makefile +2 -4
Lines of this file are not shown. View the raw message.
tools/testing/selftests/intel_pstate/Makefile +3 -3
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.