Linux 5.15.79
Greg Kroah-Hartman
maintainerI'm announcing the release of the 5.15.79 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/virt/kvm/devices/vm.rst | 3 Makefile | 2 arch/arm64/kernel/efi.c | 52 ++- arch/mips/kernel/jump_label.c | 2 arch/riscv/kernel/process.c | 2 arch/riscv/kernel/setup.c | 1 arch/riscv/kernel/vdso/Makefile | 2 arch/riscv/mm/init.c | 1 arch/s390/kvm/kvm-s390.c | 26 + arch/s390/kvm/kvm-s390.h | 1 arch/x86/include/asm/msr-index.h | 8 arch/x86/kernel/cpu/amd.c | 6 arch/x86/kernel/cpu/hygon.c | 4 arch/x86/kvm/svm/svm.c | 10 arch/x86/kvm/x86.c | 2 arch/x86/power/cpu.c | 1 drivers/ata/libata-scsi.c | 3 drivers/dma/at_hdmac.c | 153 +++------- drivers/dma/at_hdmac_regs.h | 10 drivers/dma/mv_xor_v2.c | 1 drivers/dma/pxa_dma.c | 4 drivers/dma/ti/k3-udma-glue.c | 3 drivers/gpu/drm/amd/amdkfd/kfd_migrate.c | 49 ++- drivers/gpu/drm/amd/amdkfd/kfd_priv.h | 1 drivers/gpu/drm/amd/amdkfd/kfd_svm.c | 2 drivers/gpu/drm/amd/pm/swsmu/smu11/sienna_cichlid_ppt.c | 4 drivers/gpu/drm/i915/gem/i915_gem_dmabuf.c | 4 drivers/gpu/drm/vc4/vc4_drv.c | 7 drivers/hid/hid-hyperv.c | 2 drivers/hwspinlock/qcom_hwspinlock.c | 2 drivers/mmc/host/sdhci-cqhci.h | 24 + drivers/mmc/host/sdhci-esdhc-imx.c | 7 drivers/mmc/host/sdhci-of-arasan.c | 3 drivers/mmc/host/sdhci-tegra.c | 3 drivers/mmc/host/sdhci_am654.c | 7 drivers/net/ethernet/apm/xgene/xgene_enet_main.c | 4 drivers/net/ethernet/aquantia/atlantic/aq_macsec.c | 2 drivers/net/ethernet/aquantia/atlantic/macsec/macsec_api.c | 18 - drivers/net/ethernet/broadcom/Kconfig | 2 drivers/net/ethernet/broadcom/bnxt/bnxt.c | 2 drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c | 2 drivers/net/ethernet/chelsio/cxgb3/cxgb3_main.c | 1 drivers/net/ethernet/chelsio/cxgb4vf/cxgb4vf_main.c | 2 drivers/net/ethernet/freescale/fman/mac.c | 9 drivers/net/ethernet/marvell/mv643xx_eth.c | 1 drivers/net/ethernet/marvell/octeontx2/nic/otx2_common.c | 3 drivers/net/ethernet/marvell/octeontx2/nic/otx2_common.h | 1 drivers/net/ethernet/marvell/octeontx2/nic/otx2_pf.c | 135 ++++++-- drivers/net/ethernet/marvell/octeontx2/nic/otx2_struct.h | 57 +++ drivers/net/ethernet/marvell/octeontx2/nic/otx2_txrx.c | 69 ++++ drivers/net/ethernet/marvell/octeontx2/nic/otx2_txrx.h | 5 drivers/net/ethernet/marvell/prestera/prestera_rxtx.c | 7 drivers/net/ethernet/mellanox/mlx5/core/cmd.c | 11 drivers/net/ethernet/mellanox/mlx5/core/en/rep/bridge.c | 31 ++ drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads_termtbl.c | 14 drivers/net/ethernet/neterion/s2io.c | 29 + drivers/net/ethernet/ni/nixge.c | 1 drivers/net/ethernet/stmicro/stmmac/dwmac-intel.c | 14 drivers/net/ethernet/stmicro/stmmac/dwmac-loongson.c | 39 ++ drivers/net/ethernet/stmicro/stmmac/dwmac-meson8b.c | 8 drivers/net/ethernet/ti/cpsw.c | 2 drivers/net/ethernet/tundra/tsi108_eth.c | 5 drivers/net/hamradio/bpqether.c | 2 drivers/net/macsec.c | 23 - drivers/net/macvlan.c | 4 drivers/net/phy/mscc/mscc_macsec.c | 1 drivers/net/tun.c | 18 - drivers/net/wan/lapbether.c | 3 drivers/net/wireless/ath/ath11k/reg.c | 6 drivers/net/wwan/iosm/iosm_ipc_pcie.c | 11 drivers/net/wwan/iosm/iosm_ipc_wwan.c | 1 drivers/net/wwan/mhi_wwan_mbim.c | 1 drivers/phy/ralink/phy-mt7621-pci.c | 3 drivers/phy/st/phy-stm32-usbphyc.c | 2 drivers/platform/x86/hp-wmi.c | 12 drivers/soundwire/qcom.c | 9 drivers/thunderbolt/path.c | 42 +- drivers/thunderbolt/tb.c | 96 +++++- drivers/thunderbolt/tb.h | 5 drivers/thunderbolt/tunnel.c | 27 + drivers/thunderbolt/tunnel.h | 9 fs/btrfs/disk-io.c | 4 fs/btrfs/tests/btrfs-tests.c | 2 fs/btrfs/volumes.c | 27 + fs/btrfs/volumes.h | 2 fs/fuse/readdir.c | 10 fs/nilfs2/segment.c | 15 fs/nilfs2/super.c | 2 fs/nilfs2/the_nilfs.c | 2 fs/udf/namei.c | 2 include/asm-generic/vmlinux.lds.h | 2 include/linux/bpf.h | 1 include/linux/bpf_verifier.h | 21 + include/linux/skmsg.h | 3 include/linux/soc/marvell/octeontx2/asm.h | 15 include/uapi/linux/capability.h | 2 kernel/bpf/verifier.c | 148 ++------- mm/damon/dbgfs.c | 7 mm/memremap.c | 1 mm/userfaultfd.c | 2 net/can/af_can.c | 2 net/can/j1939/main.c | 3 net/core/skbuff.c | 36 +- net/core/skmsg.c | 8 net/core/sock_map.c | 28 + net/ipv4/tcp.c | 2 net/ipv4/tcp_bpf.c | 9 net/ipv6/addrlabel.c | 1 net/mac80211/s1g.c | 3 net/mctp/af_mctp.c | 4 net/mctp/route.c | 2 net/netfilter/nf_tables_api.c | 3 net/netfilter/nfnetlink.c | 1 net/tipc/netlink_compat.c | 2 net/wireless/reg.c | 12 net/wireless/scan.c | 4 scripts/extract-cert.c | 7 scripts/sign-file.c | 7 sound/hda/hdac_sysfs.c | 4 sound/pci/hda/hda_intel.c | 3 sound/pci/hda/patch_ca0132.c | 1 sound/pci/hda/patch_realtek.c | 1 sound/usb/card.c | 29 + sound/usb/quirks-table.h | 4 sound/usb/quirks.c | 1 tools/arch/x86/include/asm/msr-index.h | 8 tools/bpf/bpftool/common.c | 3 tools/perf/.gitignore | 1 tools/perf/util/stat-display.c | 2 129 files changed, 1092 insertions(+), 528 deletions(-)
Alex Barba (1):
bnxt_en: fix potentially incorrect return value for ndo_rx_flow_steer
Alex Sierra (1):
drm/amdkfd: avoid recursive lock in migrations back to RAM
Alexander Potapenko (1):
ipv6: addrlabel: fix infoleak when sending struct ifaddrlblmsg to network
Anders Roxell (1):
marvell: octeontx2: build error: unknown type name 'u64'
Antoine Tenart (2):
net: phy: mscc: macsec: clear encryption keys when freeing a flow
net: atlantic: macsec: clear encryption keys from the stack
Ard Biesheuvel (1):
arm64: efi: Fix handling of misaligned runtime regions and drop warning
Arend van Spriel (1):
wifi: cfg80211: fix memory leak in query_regdb_file()
Athira Rajeev (1):
perf stat: Fix printing os->prefix in CSV metrics output
Borislav Petkov (1):
x86/cpu: Restore AMD's DE_CFG MSR after resume
Brian Norris (5):
mmc: cqhci: Provide helper for resetting both SDHCI and CQHCI
mmc: sdhci-of-arasan: Fix SDHCI_RESET_ALL for CQHCI
mmc: sdhci_am654: Fix SDHCI_RESET_ALL for CQHCI
mmc: sdhci-tegra: Fix SDHCI_RESET_ALL for CQHCI
mms: sdhci-esdhc-imx: Fix SDHCI_RESET_ALL for CQHCI
Christophe JAILLET (1):
dmaengine: mv_xor_v2: Fix a resource leak in mv_xor_v2_remove()
Chuang Wang (1):
net: macvlan: fix memory leaks of macvlan_common_newlink
Cong Wang (1):
bpf, sock_map: Move cancel_work_sync() out of sock lock
Conor Dooley (1):
riscv: fix reserved memory setup
Dan Carpenter (1):
phy: stm32: fix an error code in probe
Donglin Peng (1):
perf tools: Add the include/perf/ directory to .gitignore
Doug Brown (1):
dmaengine: pxa_dma: use platform_get_irq_optional
Edson Juliano Drosdeck (1):
ALSA: hda/realtek: Add Positivo C6300 model quirk
Eric Dumazet (1):
net: tun: call napi_schedule_prep() to ensure we own a napi
Evan Quan (1):
ALSA: hda/hdmi - enable runtime pm for more AMD display audio
Gaosheng Cui (1):
capabilities: fix undefined behavior in bit shift for CAP_TO_MASK
Geetha sowjanya (1):
octeontx2-pf: Use hardware register for CQE count
Greg Kroah-Hartman (1):
Linux 5.15.79
Guchun Chen (1):
drm/amdgpu: disable BACO on special BEIGE_GOBY card
HW He (2):
net: wwan: iosm: fix memory leak in ipc_wwan_dellink
net: wwan: mhi: fix memory leak in mhi_mbim_dellink
Haibo Chen (1):
mmc: sdhci-esdhc-imx: use the correct host caps for MMC_CAP_8_BIT_DATA
Howard Hsu (1):
wifi: mac80211: Set TWT Information Frame Disabled bit as 1
Jiaxun Yang (1):
MIPS: jump_label: Fix compat branch range check
Jiri Benc (1):
net: gso: fix panic on frag_list with mixed head alloc types
Jisheng Zhang (2):
riscv: process: fix kernel info leakage
riscv: vdso: fix build with llvm
Johannes Berg (1):
wifi: cfg80211: silence a sparse RCU warning
Johannes Thumshirn (1):
btrfs: zoned: initialize device's zone info for seeding
John Fastabend (1):
bpf: Fix sockmap calling sleepable function in teardown path
John Thomson (1):
phy: ralink: mt7621-pci: add sentinel to quirks table
Jorge Lopez (1):
platform/x86: hp_wmi: Fix rfkill causing soft blocked wifi
Jussi Laako (1):
ALSA: usb-audio: Add DSD support for Accuphase DAC-60
Kees Cook (1):
bpf, verifier: Fix memory leak in array reallocation for stack state
Krzysztof Kozlowski (1):
hwspinlock: qcom: correct MMIO max register for newer SoCs
Kumar Kartikeya Dwivedi (1):
bpf: Add helper macro bpf_for_each_reg_in_vstate
Linus Torvalds (1):
cert host tools: Stop complaining about deprecated OpenSSL functions
Liu Shixin (1):
btrfs: fix match incorrectly in dev_args_match_device
Lu Wei (1):
tcp: prohibit TCP_REPAIR_OPTIONS if data was already sent
M Chetan Kumar (1):
net: wwan: iosm: fix memory leak in ipc_pcie_read_bios_cfg
Matthew Auld (1):
drm/i915/dmabuf: fix sg_table handling in map_dma_buf
Michael Chan (1):
bnxt_en: Fix possible crash in bnxt_hwrm_set_coal()
Mika Westerberg (1):
thunderbolt: Tear down existing tunnels when resuming from hibernate
Miklos Szeredi (1):
fuse: fix readdir cache race
Nathan Chancellor (1):
vmlinux.lds.h: Fix placement of '.data..decrypted' section
Nico Boehr (1):
KVM: s390: pv: don't allow userspace to set the clock under PV
Oliver Hartkopp (1):
can: j1939: j1939_send_one(): fix missing CAN header initialization
Pankaj Gupta (1):
mm/memremap.c: map FS_DAX device memory as decrypted
Peter Xu (1):
mm/shmem: use page_mapping() to detect page cache for uffd continue
Philip Yang (2):
drm/amdkfd: handle CPU fault on COW mapping drm/amdkfd: Migrate in CPU page fault use current mm
Pu Lehui (1):
bpftool: Fix NULL pointer dereference when pin {PROG, MAP, LINK} without FILE
Rasmus Villemoes (1):
net: stmmac: dwmac-meson8b: fix meson8b_devm_clk_prepare_enable()
Ratheesh Kannoth (1):
octeontx2-pf: NIX TX overwrites SQ_CTX_HW_S[SQ_INT]
Roi Dayan (1):
net/mlx5e: E-Switch, Fix comparing termination table instance
Roy Novich (1):
net/mlx5: Allow async trigger completion execution on single CPU systems
Ryusuke Konishi (2):
nilfs2: fix deadlock in nilfs_count_free_blocks()
nilfs2: fix use-after-free bug of ns_writer on remount
Sabrina Dubroca (4):
macsec: delete new rxsc when offload fails
macsec: fix secy->n_rx_sc accounting
macsec: fix detection of RXSCs when toggling offloading
macsec: clear encryption keys from the stack after setting up offload
Sanjay R Mehta (1):
thunderbolt: Add DP OUT resource when DP tunnel is discovered
Sean Anderson (1):
net: fman: Unregister ethernet device on removal
SeongJae Park (1):
mm/damon/dbgfs: check if rm_contexts input is for a real context
Shigeru Yoshida (1):
netfilter: Cleanup nft_net->module_list from nf_tables_exit_net()
Shin'ichiro Kawasaki (1):
ata: libata-scsi: fix SYNCHRONIZE CACHE (16) command failure
Srinivas Kandagatla (2):
soundwire: qcom: reinit broadcast completion
soundwire: qcom: check for outanding writes before doing a read
Takashi Iwai (2):
ALSA: usb-audio: Yet more regression for for the delayed card registration
ALSA: usb-audio: Add quirk entry for M-Audio Micro
Tan, Tee Min (1):
stmmac: intel: Update PCH PTP clock rate from 200MHz to 204.8MHz
Tudor Ambarus (15):
dmaengine: at_hdmac: Fix at_lli struct definition
dmaengine: at_hdmac: Don't start transactions at tx_submit level
dmaengine: at_hdmac: Start transfer for cyclic channels in issue_pending
dmaengine: at_hdmac: Fix premature completion of desc in issue_pending
dmaengine: at_hdmac: Do not call the complete callback on device_terminate_all
dmaengine: at_hdmac: Protect atchan->status with the channel lock
dmaengine: at_hdmac: Fix concurrency problems by removing atc_complete_all()
dmaengine: at_hdmac: Fix concurrency over descriptor
dmaengine: at_hdmac: Free the memset buf without holding the chan lock
dmaengine: at_hdmac: Fix concurrency over the active list
dmaengine: at_hdmac: Fix descriptor handling when issuing it to hardware
dmaengine: at_hdmac: Fix completion of unissued descriptor in case of errors
dmaengine: at_hdmac: Don't allow CPU to reorder channel enable
dmaengine: at_hdmac: Fix impossible condition
dmaengine: at_hdmac: Check return code of dma_async_device_register
Vlad Buslov (1):
net/mlx5: Bridge, verify LAG state when adding bond to bridge
Wang Yufen (3):
bpf, sockmap: Fix the sk->sk_forward_alloc warning of sk_stream_kill_queues
bpf, sockmap: Fix sk->sk_forward_alloc warn_on in sk_stream_kill_queues
net: tun: Fix memory leaks of napi_get_fragsWei Yongjun (1):
mctp: Fix an error handling path in mctp_init()
Wen Gong (1):
wifi: ath11k: avoid deadlock during regulatory update in ath11k_regd_update()
Wong Vee Khee (1):
stmmac: intel: Enable 2.5Gbps for Intel AlderLake-S
Xian Wang (1):
ALSA: hda/ca0132: add quirk for EVGA Z390 DARK
Xin Long (1):
tipc: fix the msg->req tlv len check in tipc_nl_compat_name_table_dump_header
Yang Li (1):
drm/amdkfd: Fix NULL pointer dereference in svm_migrate_to_ram()
Yang Yingliang (5):
HID: hyperv: fix possible memory leak in mousevsc_probe()
dmaengine: ti: k3-udma-glue: fix memory leak when register device fail
stmmac: dwmac-loongson: fix missing pci_disable_msi() while module exiting
stmmac: dwmac-loongson: fix missing pci_disable_device() in loongson_dwmac_probe()
stmmac: dwmac-loongson: fix missing of_node_put() while module exiting
Ye Bin (1):
ALSA: hda: fix potential memleak in 'add_widget_node'
Youlin Li (1):
bpf: Fix wrong reg type conversion in release_reference()
Yuan Can (1):
drm/vc4: Fix missing platform_unregister_drivers() call in vc4_drm_register()
YueHaibing (1):
net: broadcom: Fix BCMGENET Kconfig
Zhang Xiaoxu (1):
btrfs: selftests: fix wrong error check in btrfs_free_dummy_root()
ZhangPeng (1):
udf: Fix a slab-out-of-bounds write bug in udf_find_entry()
Zhengchao Shao (13):
net: lapbether: fix issue of dev reference count leakage in lapbeth_device_event()
hamradio: fix issue of dev reference count leakage in bpq_device_event()
can: af_can: fix NULL pointer dereference in can_rx_register()
net: lapbether: fix issue of invalid opcode in lapbeth_open()
drivers: net: xgene: disable napi when register irq failed in xgene_enet_open()
net: marvell: prestera: fix memory leak in prestera_rxtx_switch_init()
net: nixge: disable napi when enable interrupts failed in nixge_open()
net: cpsw: disable napi in cpsw_ndo_open()
net: cxgb3_main: disable napi when bind qsets failed in cxgb_up()
cxgb4vf: shut down the adapter when t4vf_update_port_info() failed in cxgb4vf_open()
ethernet: s2io: disable napi when start nic failed in s2io_card_up()
net: mv643xx_eth: disable napi when init rxq or txq failed in mv643xx_eth_open()
ethernet: tundra: free irq when alloc ring failed in tsi108_open()
Ziyang Xuan (1):
netfilter: nfnetlink: fix potential dead lock in nfnetlink_rcv_msg()
Greg Kroah-Hartman
maintainerDocumentation/virt/kvm/devices/vm.rst +3 -0
@@ -215,6 +215,7 @@ KVM_S390_VM_TOD_EXT). :Parameters: address of a buffer in user space to store the data (u8) to :Returns: -EFAULT if the given address is not accessible from kernel space; -EINVAL if setting the TOD clock extension to != 0 is not supported + -EOPNOTSUPP for a PV guest (TOD managed by the ultravisor) 3.2. ATTRIBUTE: KVM_S390_VM_TOD_LOW -----------------------------------
@@ -224,6 +225,7 @@ the POP (u64). :Parameters: address of a buffer in user space to store the data (u64) to :Returns: -EFAULT if the given address is not accessible from kernel space + -EOPNOTSUPP for a PV guest (TOD managed by the ultravisor) 3.3. ATTRIBUTE: KVM_S390_VM_TOD_EXT -----------------------------------
@@ -237,6 +239,7 @@ it, it is stored as 0 and not allowed to be set to a value != 0. (kvm_s390_vm_tod_clock) to :Returns: -EFAULT if the given address is not accessible from kernel space; -EINVAL if setting the TOD clock extension to != 0 is not supported + -EOPNOTSUPP for a PV guest (TOD managed by the ultravisor) 4. GROUP: KVM_S390_VM_CRYPTO ============================
Makefile +1 -1
@@ -1,7 +1,7 @@ # SPDX-License-Identifier: GPL-2.0 VERSION = 5 PATCHLEVEL = 15 -SUBLEVEL = 78 +SUBLEVEL = 79 EXTRAVERSION = NAME = Trick or Treat
arch/arm64/kernel/efi.c +34 -18
79 lines not on this page · raw message
arch/mips/kernel/jump_label.c +1 -1
@@ -56,7 +56,7 @@ void arch_jump_label_transform(struct jump_entry *e,* The branch offset must fit in the instruction's 26 * bit field. */ -WARN_ON ((offset >=BIT (25 )) || +WARN_ON ((offset >= (long )BIT (25 )) || (offset < -(long )BIT (25 ))); insn.j_format.opcode = bc6_op;
arch/riscv/kernel/process.c +2 -0
@@ -124,6 +124,8 @@ int copy_thread(unsigned long clone_flags, unsigned long usp, unsigned long arg, {struct pt_regs *childregs =task_pt_regs (p); +memset (&p->thread.s,0 ,sizeof (p->thread.s)); +/* p->thread holds context to be restored by __switch_to() */ if (unlikely (p->flags & (PF_KTHREAD |PF_IO_WORKER ))) {/* Kernel thread */
arch/riscv/kernel/setup.c +1 -0
@@ -291,6 +291,7 @@ void __init setup_arch(char **cmdline_p) else pr_err("No DTB found in kernel mappings\n");#endif +early_init_fdt_scan_reserved_mem ();misc_mem_init ();init_resources ();
arch/riscv/kernel/vdso/Makefile +1 -1
@@ -30,7 +30,7 @@ obj-y += vdso.o CPPFLAGS_vdso.lds += -P -C -U$(ARCH) # Disable -pg to prevent insert call site -CFLAGS_REMOVE_vgettimeofday.o = $(CC_FLAGS_FTRACE) -Os +CFLAGS_REMOVE_vgettimeofday.o = $(CC_FLAGS_FTRACE) # Disable profiling and instrumentation for VDSO code GCOV_PROFILE := n
arch/riscv/mm/init.c +0 -1
@@ -242,7 +242,6 @@ static void __init setup_bootmem(void)memblock_reserve (dtb_early_pa,fdt_totalsize (dtb_early_va)); } -early_init_fdt_scan_reserved_mem ();dma_contiguous_reserve (dma32_phys_limit);if (IS_ENABLED (CONFIG_64BIT ))hugetlb_cma_reserve (PUD_SHIFT -PAGE_SHIFT );
arch/s390/kvm/kvm-s390.c +17 -9
@@ -1117,6 +1117,8 @@ static int kvm_s390_vm_get_migration(struct kvm *kvm,return 0 ; } +static void __kvm_s390_set_tod_clock (struct kvm *kvm,const struct kvm_s390_vm_tod_clock *gtod); +static int kvm_s390_set_tod_ext (struct kvm *kvm,struct kvm_device_attr *attr) {struct kvm_s390_vm_tod_clock gtod;
@@ -1126,7 +1128,7 @@ static int kvm_s390_set_tod_ext(struct kvm *kvm, struct kvm_device_attr *attr)if (!test_kvm_facility (kvm,139 ) && gtod.epoch_idx)return -EINVAL ; -kvm_s390_set_tod_clock (kvm, >od); +__kvm_s390_set_tod_clock (kvm, >od);VM_EVENT (kvm,3 ,"SET: TOD extension: 0x%x, TOD base: 0x%llx" , gtod.epoch_idx, gtod.tod);
@@ -1157,7 +1159,7 @@ static int kvm_s390_set_tod_low(struct kvm *kvm, struct kvm_device_attr *attr) sizeof(gtod.tod)))return -EFAULT ; -kvm_s390_set_tod_clock (kvm, >od); +__kvm_s390_set_tod_clock (kvm, >od);VM_EVENT (kvm,3 ,"SET: TOD base: 0x%llx" , gtod.tod);return 0 ; }
@@ -1169,6 +1171,16 @@ static int kvm_s390_set_tod(struct kvm *kvm, struct kvm_device_attr *attr)if (attr->flags)return -EINVAL ; +mutex_lock (&kvm->lock); +/* +* For protected guests, the TOD is managed by the ultravisor, so trying +* to change it will never bring the expected results. +*/ +if (kvm_s390_pv_is_protected (kvm)) { + ret = -EOPNOTSUPP ; + goto out_unlock; + } +switch (attr->attr) {case KVM_S390_VM_TOD_EXT : ret =kvm_s390_set_tod_ext (kvm, attr);
@@ -1183,6 +1195,9 @@ static int kvm_s390_set_tod(struct kvm *kvm, struct kvm_device_attr *attr) ret = -ENXIO ;break ; } + +out_unlock: +mutex_unlock (&kvm->lock);return ret; }
@@ -3941,13 +3956,6 @@ static void __kvm_s390_set_tod_clock(struct kvm *kvm, const struct kvm_s390_vm_tpreempt_enable (); } -void kvm_s390_set_tod_clock (struct kvm *kvm,const struct kvm_s390_vm_tod_clock *gtod) -{ -mutex_lock (&kvm->lock); -__kvm_s390_set_tod_clock (kvm, gtod); -mutex_unlock (&kvm->lock); -} -int kvm_s390_try_set_tod_clock (struct kvm *kvm,const struct kvm_s390_vm_tod_clock *gtod) {if (!mutex_trylock (&kvm->lock))
arch/s390/kvm/kvm-s390.h +0 -1
@@ -326,7 +326,6 @@ int kvm_s390_handle_sigp(struct kvm_vcpu *vcpu);int kvm_s390_handle_sigp_pei (struct kvm_vcpu *vcpu);/* implemented in kvm-s390.c */ -void kvm_s390_set_tod_clock (struct kvm *kvm,const struct kvm_s390_vm_tod_clock *gtod);int kvm_s390_try_set_tod_clock (struct kvm *kvm,const struct kvm_s390_vm_tod_clock *gtod);long kvm_arch_fault_in_page (struct kvm_vcpu *vcpu,gpa_t gpa,int writable);int kvm_s390_store_status_unloaded (struct kvm_vcpu *vcpu,unsigned long addr);
arch/x86/include/asm/msr-index.h +5 -3
@@ -495,6 +495,11 @@#define MSR_AMD64_CPUID_FN_1 0xc0011004#define MSR_AMD64_LS_CFG 0xc0011020#define MSR_AMD64_DC_CFG 0xc0011022 + +#define MSR_AMD64_DE_CFG 0xc0011029 +#define MSR_AMD64_DE_CFG_LFENCE_SERIALIZE_BIT 1 +#define MSR_AMD64_DE_CFG_LFENCE_SERIALIZE BIT_ULL(MSR_AMD64_DE_CFG_LFENCE_SERIALIZE_BIT) +#define MSR_AMD64_BU_CFG2 0xc001102a#define MSR_AMD64_IBSFETCHCTL 0xc0011030#define MSR_AMD64_IBSFETCHLINAD 0xc0011031
@@ -572,9 +577,6 @@#define FAM10H_MMIO_CONF_BASE_MASK 0xfffffffULL#define FAM10H_MMIO_CONF_BASE_SHIFT 20#define MSR_FAM10H_NODE_ID 0xc001100c -#define MSR_F10H_DECFG 0xc0011029 -#define MSR_F10H_DECFG_LFENCE_SERIALIZE_BIT 1 -#define MSR_F10H_DECFG_LFENCE_SERIALIZE BIT_ULL(MSR_F10H_DECFG_LFENCE_SERIALIZE_BIT)/* K8 MSRs */ #define MSR_K8_TOP_MEM1 0xc001001a
arch/x86/kernel/cpu/amd.c +2 -4
@@ -794,8 +794,6 @@ static void init_amd_gh(struct cpuinfo_x86 *c)set_cpu_bug (c,X86_BUG_AMD_TLB_MMATCH ); } -#define MSR_AMD64_DE_CFG 0xC0011029 -static void init_amd_ln (struct cpuinfo_x86 *c) {/*
@@ -990,8 +988,8 @@ static void init_amd(struct cpuinfo_x86 *c)* msr_set_bit() uses the safe accessors, too, even if the MSR * is not present. */ -msr_set_bit (MSR_F10H_DECFG , -MSR_F10H_DECFG_LFENCE_SERIALIZE_BIT ); +msr_set_bit (MSR_AMD64_DE_CFG , +MSR_AMD64_DE_CFG_LFENCE_SERIALIZE_BIT );/* A serializing LFENCE stops RDTSC speculation */ set_cpu_cap (c,X86_FEATURE_LFENCE_RDTSC );
arch/x86/kernel/cpu/hygon.c +2 -2
@@ -326,8 +326,8 @@ static void init_hygon(struct cpuinfo_x86 *c)* msr_set_bit() uses the safe accessors, too, even if the MSR * is not present. */ -msr_set_bit (MSR_F10H_DECFG , -MSR_F10H_DECFG_LFENCE_SERIALIZE_BIT ); +msr_set_bit (MSR_AMD64_DE_CFG , +MSR_AMD64_DE_CFG_LFENCE_SERIALIZE_BIT );/* A serializing LFENCE stops RDTSC speculation */ set_cpu_cap (c,X86_FEATURE_LFENCE_RDTSC );
arch/x86/kvm/svm/svm.c +5 -5
@@ -2666,9 +2666,9 @@ static int svm_get_msr_feature(struct kvm_msr_entry *msr) msr->data =0 ;switch (msr->index) { -case MSR_F10H_DECFG : -if (boot_cpu_has (X86_FEATURE_LFENCE_RDTSC )) - msr->data |=MSR_F10H_DECFG_LFENCE_SERIALIZE ; +case MSR_AMD64_DE_CFG : +if (cpu_feature_enabled (X86_FEATURE_LFENCE_RDTSC )) + msr->data |=MSR_AMD64_DE_CFG_LFENCE_SERIALIZE ;break ;case MSR_IA32_PERF_CAPABILITIES :return 0 ;
@@ -2777,7 +2777,7 @@ static int svm_get_msr(struct kvm_vcpu *vcpu, struct msr_data *msr_info) msr_info->data =0x1E ; }break ; -case MSR_F10H_DECFG : +case MSR_AMD64_DE_CFG : msr_info->data = svm->msr_decfg;break ;default :
@@ -2977,7 +2977,7 @@ static int svm_set_msr(struct kvm_vcpu *vcpu, struct msr_data *msr)case MSR_VM_IGNNE :vcpu_unimpl (vcpu,"unimplemented wrmsr: 0x%x data 0x%llx\n" , ecx, data);break ; -case MSR_F10H_DECFG : { +case MSR_AMD64_DE_CFG : {struct kvm_msr_entry msr_entry; msr_entry.index = msr->index;
arch/x86/kvm/x86.c +1 -1
@@ -1464,7 +1464,7 @@ static const u32 msr_based_features_all[] = {MSR_IA32_VMX_EPT_VPID_CAP ,MSR_IA32_VMX_VMFUNC , -MSR_F10H_DECFG , +MSR_AMD64_DE_CFG ,MSR_IA32_UCODE_REV ,MSR_IA32_ARCH_CAPABILITIES , MSR_IA32_PERF_CAPABILITIES,
arch/x86/power/cpu.c +1 -0
@@ -519,6 +519,7 @@ static void pm_save_spec_msr(void)MSR_TSX_FORCE_ABORT ,MSR_IA32_MCU_OPT_CTRL ,MSR_AMD64_LS_CFG , +MSR_AMD64_DE_CFG , };msr_build_context (spec_msr_id,ARRAY_SIZE (spec_msr_id));
drivers/ata/libata-scsi.c +3 -0
@@ -3259,6 +3259,7 @@ static unsigned int ata_scsiop_maint_in(struct ata_scsi_args *args, u8 *rbuf)case REPORT_LUNS :case REQUEST_SENSE :case SYNCHRONIZE_CACHE : +case SYNCHRONIZE_CACHE_16 :case REZERO_UNIT :case SEEK_6 :case SEEK_10 :
@@ -3925,6 +3926,7 @@ static inline ata_xlat_func_t ata_get_xlat_func(struct ata_device *dev, u8 cmd)return ata_scsi_write_same_xlat;case SYNCHRONIZE_CACHE : +case SYNCHRONIZE_CACHE_16 :if (ata_try_flush_cache (dev))return ata_scsi_flush_xlat;break ;
@@ -4170,6 +4172,7 @@ void ata_scsi_simulate(struct ata_device *dev, struct scsi_cmnd *cmd)* turning this into a no-op. */ case SYNCHRONIZE_CACHE : +case SYNCHRONIZE_CACHE_16 : fallthrough;/* no-op's, complete with success */
drivers/dma/at_hdmac.c +60 -93
274 lines not on this page · raw message
drivers/dma/at_hdmac_regs.h +5 -5
@@ -186,13 +186,13 @@/* LLI == Linked List Item; aka DMA buffer descriptor */ struct at_lli {/* values that are not changed by hardware */ -dma_addr_t saddr; -dma_addr_t daddr; +u32 saddr; +u32 daddr;/* value that may get written back: */ -u32 ctrla; +u32 ctrla;/* more values that are not changed by hardware */ -u32 ctrlb; -dma_addr_t dscr;/* chain to next lli */ +u32 ctrlb; +u32 dscr;/* chain to next lli */ };/**
drivers/dma/mv_xor_v2.c +1 -0
@@ -899,6 +899,7 @@ static int mv_xor_v2_remove(struct platform_device *pdev)tasklet_kill (&xor_dev->irq_tasklet);clk_disable_unprepare (xor_dev->clk); +clk_disable_unprepare (xor_dev->reg_clk);return 0 ; }
drivers/dma/pxa_dma.c +2 -2
@@ -1248,14 +1248,14 @@ static int pxad_init_phys(struct platform_device *op,return -ENOMEM ;for (i =0 ; i < nb_phy_chans; i++) -if (platform_get_irq (op, i) >0 ) +if (platform_get_irq_optional (op, i) >0 ) nr_irq++;for (i =0 ; i < nb_phy_chans; i++) { phy = &pdev->phys[i]; phy->base = pdev->base; phy->idx = i; - irq =platform_get_irq (op, i); + irq =platform_get_irq_optional (op, i);if ((nr_irq >1 ) && (irq >0 )) ret = devm_request_irq(&op->dev, irq, pxad_chan_handler,
drivers/dma/ti/k3-udma-glue.c +3 -0
@@ -299,6 +299,7 @@ struct k3_udma_glue_tx_channel *k3_udma_glue_request_tx_chn(struct device *dev, ret =device_register (&tx_chn->common.chan_dev);if (ret) {dev_err (dev,"Channel Device registration failed %d\n" , ret); +put_device (&tx_chn->common.chan_dev); tx_chn->common.chan_dev.parent =NULL ; goto err; }
@@ -917,6 +918,7 @@ k3_udma_glue_request_rx_chn_priv(struct device *dev, const char *name, ret =device_register (&rx_chn->common.chan_dev);if (ret) {dev_err (dev,"Channel Device registration failed %d\n" , ret); +put_device (&rx_chn->common.chan_dev); rx_chn->common.chan_dev.parent =NULL ; goto err; }
@@ -1048,6 +1050,7 @@ k3_udma_glue_request_remote_rx_chn(struct device *dev, const char *name, ret =device_register (&rx_chn->common.chan_dev);if (ret) {dev_err (dev,"Channel Device registration failed %d\n" , ret); +put_device (&rx_chn->common.chan_dev); rx_chn->common.chan_dev.parent =NULL ; goto err; }
drivers/gpu/drm/amd/amdkfd/kfd_migrate.c +34 -15
87 lines not on this page · raw message
drivers/gpu/drm/amd/amdkfd/kfd_priv.h +1 -0
@@ -755,6 +755,7 @@ struct svm_range_list {atomic_t evicted_ranges;struct delayed_work restore_work;DECLARE_BITMAP (bitmap_supported,MAX_GPU_INSTANCE ); +struct task_struct *faulting_task; };/* Process data */
drivers/gpu/drm/amd/amdkfd/kfd_svm.c +2 -0
@@ -1489,9 +1489,11 @@ static int svm_range_validate_and_map(struct mm_struct *mm, next =min (vma->vm_end, end); npages = (next - addr) >>PAGE_SHIFT ; +WRITE_ONCE (p->svms.faulting_task, current); r =amdgpu_hmm_range_get_pages (&prange->notifier, mm,NULL , addr, npages, &hmm_range, readonly, true, owner); +WRITE_ONCE (p->svms.faulting_task,NULL );if (r) {pr_debug ("failed %d to get svm range pages\n" , r); goto unreserve_out;
drivers/gpu/drm/amd/pm/swsmu/smu11/sienna_cichlid_ppt.c +3 -1
@@ -366,7 +366,9 @@ static void sienna_cichlid_check_bxco_support(struct smu_context *smu)if (((adev->pdev->device ==0x73A1 ) && (adev->pdev->revision ==0x00 )) || ((adev->pdev->device ==0x73BF ) && - (adev->pdev->revision ==0xCF ))) + (adev->pdev->revision ==0xCF )) || + ((adev->pdev->device ==0x7422 ) && + (adev->pdev->revision ==0x00 ))) smu_baco->platform_support = false; }
drivers/gpu/drm/i915/gem/i915_gem_dmabuf.c +2 -2
@@ -34,13 +34,13 @@ static struct sg_table *i915_gem_map_dma_buf(struct dma_buf_attachment *attachme goto err; } - ret =sg_alloc_table (st, obj->mm.pages->nents,GFP_KERNEL ); + ret =sg_alloc_table (st, obj->mm.pages->orig_nents,GFP_KERNEL );if (ret) goto err_free; src = obj->mm.pages->sgl; dst = st->sgl; -for (i =0 ; i < obj->mm.pages->nents; i++) { +for (i =0 ; i < obj->mm.pages->orig_nents; i++) {sg_set_page (dst,sg_page (src), src->length,0 ); dst =sg_next (dst); src =sg_next (src);
drivers/gpu/drm/vc4/vc4_drv.c +6 -1
@@ -383,7 +383,12 @@ static int __init vc4_drm_register(void)if (ret)return ret; -return platform_driver_register (&vc4_platform_driver); + ret =platform_driver_register (&vc4_platform_driver); +if (ret) +platform_unregister_drivers (component_drivers, +ARRAY_SIZE (component_drivers)); + +return ret; } static void __exit vc4_drm_unregister(void)
drivers/hid/hid-hyperv.c +1 -1
@@ -498,7 +498,7 @@ static int mousevsc_probe(struct hv_device *device, ret =hid_add_device (hid_dev);if (ret) - goto probe_err1; + goto probe_err2; ret =hid_parse (hid_dev);
drivers/hwspinlock/qcom_hwspinlock.c +1 -1
@@ -105,7 +105,7 @@ static const struct regmap_config tcsr_mutex_config = { .reg_bits = 32, .reg_stride = 4, .val_bits = 32, - .max_register = 0x40000, + .max_register = 0x20000, .fast_io = true, };
drivers/mmc/host/sdhci-cqhci.h new file +24 -0
@@ -0,0 +1,24 @@ +/* SPDX-License-Identifier: GPL-2.0-only */ +/* +* Copyright 2022 The Chromium OS Authors +* +* Support that applies to the combination of SDHCI and CQHCI, while not +* expressing a dependency between the two modules. +*/ + +#ifndef __MMC_HOST_SDHCI_CQHCI_H__ +#define __MMC_HOST_SDHCI_CQHCI_H__ + +#include "cqhci.h" +#include "sdhci.h" + +static inline void sdhci_and_cqhci_reset (struct sdhci_host *host,u8 mask) +{ +if ((host->mmc->caps2 &MMC_CAP2_CQE ) && (mask &SDHCI_RESET_ALL ) && + host->mmc->cqe_private) +cqhci_deactivate (host->mmc); + +sdhci_reset (host, mask); +} + +#endif /* __MMC_HOST_SDHCI_CQHCI_H__ */
drivers/mmc/host/sdhci-esdhc-imx.c +4 -3
@@ -25,6 +25,7 @@#include <linux/of_device.h> #include <linux/pinctrl/consumer.h> #include <linux/pm_runtime.h> +#include "sdhci-cqhci.h" #include "sdhci-pltfm.h" #include "sdhci-esdhc.h" #include "cqhci.h"
@@ -1273,7 +1274,7 @@ static void esdhc_set_uhs_signaling(struct sdhci_host *host, unsigned timing)static void esdhc_reset (struct sdhci_host *host,u8 mask) { -sdhci_reset (host, mask); +sdhci_and_cqhci_reset (host, mask);sdhci_writel (host, host->ier,SDHCI_INT_ENABLE );sdhci_writel (host, host->ier,SDHCI_SIGNAL_ENABLE );
@@ -1654,14 +1655,14 @@ static int sdhci_esdhc_imx_probe(struct platform_device *pdev)if (imx_data->socdata->flags &ESDHC_FLAG_ERR004536 ) host->quirks |=SDHCI_QUIRK_BROKEN_ADMA ; -if (host->caps &MMC_CAP_8_BIT_DATA && +if (host->mmc->caps &MMC_CAP_8_BIT_DATA && imx_data->socdata->flags &ESDHC_FLAG_HS400 ) host->mmc->caps2 |=MMC_CAP2_HS400 ;if (imx_data->socdata->flags &ESDHC_FLAG_BROKEN_AUTO_CMD23 ) host->quirks2 |=SDHCI_QUIRK2_ACMD23_BROKEN ; -if (host->caps &MMC_CAP_8_BIT_DATA && +if (host->mmc->caps &MMC_CAP_8_BIT_DATA && imx_data->socdata->flags &ESDHC_FLAG_HS400_ES ) { host->mmc->caps2 |=MMC_CAP2_HS400_ES ; host->mmc_host_ops.hs400_enhanced_strobe =
drivers/mmc/host/sdhci-of-arasan.c +2 -1
@@ -25,6 +25,7 @@#include <linux/firmware/xlnx-zynqmp.h> #include "cqhci.h" +#include "sdhci-cqhci.h" #include "sdhci-pltfm.h" #define SDHCI_ARASAN_VENDOR_REGISTER 0x78
@@ -359,7 +360,7 @@ static void sdhci_arasan_reset(struct sdhci_host *host, u8 mask)struct sdhci_pltfm_host *pltfm_host =sdhci_priv (host);struct sdhci_arasan_data *sdhci_arasan =sdhci_pltfm_priv (pltfm_host); -sdhci_reset (host, mask); +sdhci_and_cqhci_reset (host, mask);if (sdhci_arasan->quirks &SDHCI_ARASAN_QUIRK_FORCE_CDTEST ) { ctrl =sdhci_readb (host,SDHCI_HOST_CONTROL );
drivers/mmc/host/sdhci-tegra.c +2 -1
@@ -24,6 +24,7 @@#include <linux/gpio/consumer.h> #include <linux/ktime.h> +#include "sdhci-cqhci.h" #include "sdhci-pltfm.h" #include "cqhci.h"
@@ -363,7 +364,7 @@ static void tegra_sdhci_reset(struct sdhci_host *host, u8 mask)const struct sdhci_tegra_soc_data *soc_data = tegra_host->soc_data;u32 misc_ctrl, clk_ctrl, pad_ctrl; -sdhci_reset (host, mask); +sdhci_and_cqhci_reset (host, mask);if (!(mask &SDHCI_RESET_ALL ))return ;
drivers/mmc/host/sdhci_am654.c +4 -3
@@ -15,6 +15,7 @@#include <linux/sys_soc.h> #include "cqhci.h" +#include "sdhci-cqhci.h" #include "sdhci-pltfm.h" /* CTL_CFG Registers */
@@ -378,7 +379,7 @@ static void sdhci_am654_reset(struct sdhci_host *host, u8 mask)struct sdhci_pltfm_host *pltfm_host =sdhci_priv (host);struct sdhci_am654_data *sdhci_am654 =sdhci_pltfm_priv (pltfm_host); -sdhci_reset (host, mask); +sdhci_and_cqhci_reset (host, mask);if (sdhci_am654->quirks &SDHCI_AM654_QUIRK_FORCE_CDTEST ) { ctrl =sdhci_readb (host,SDHCI_HOST_CONTROL );
@@ -464,7 +465,7 @@ static struct sdhci_ops sdhci_am654_ops = { .set_clock = sdhci_am654_set_clock, .write_b = sdhci_am654_write_b, .irq = sdhci_am654_cqhci_irq, - .reset = sdhci_reset, + .reset = sdhci_and_cqhci_reset, };static const struct sdhci_pltfm_data sdhci_am654_pdata = {
@@ -494,7 +495,7 @@ static struct sdhci_ops sdhci_j721e_8bit_ops = { .set_clock = sdhci_am654_set_clock, .write_b = sdhci_am654_write_b, .irq = sdhci_am654_cqhci_irq, - .reset = sdhci_reset, + .reset = sdhci_and_cqhci_reset, };static const struct sdhci_pltfm_data sdhci_j721e_8bit_pdata = {
drivers/net/ethernet/apm/xgene/xgene_enet_main.c +3 -1
@@ -1004,8 +1004,10 @@ static int xgene_enet_open(struct net_device *ndev)xgene_enet_napi_enable (pdata); ret =xgene_enet_register_irq (ndev); -if (ret) +if (ret) { +xgene_enet_napi_disable (pdata);return ret; + }if (ndev->phydev) {phy_start (ndev->phydev);
drivers/net/ethernet/aquantia/atlantic/aq_macsec.c +2 -0
@@ -585,6 +585,7 @@ static int aq_update_txsa(struct aq_nic_s *nic, const unsigned int sc_idx, ret =aq_mss_set_egress_sakey_record (hw, &key_rec, sa_idx); +memzero_explicit (&key_rec,sizeof (key_rec));return ret; }
@@ -932,6 +933,7 @@ static int aq_update_rxsa(struct aq_nic_s *nic, const unsigned int sc_idx, ret =aq_mss_set_ingress_sakey_record (hw, &sa_key_record, sa_idx); +memzero_explicit (&sa_key_record,sizeof (sa_key_record));return ret; }
drivers/net/ethernet/aquantia/atlantic/macsec/macsec_api.c +11 -7
@@ -757,6 +757,7 @@ set_ingress_sakey_record(struct aq_hw_s *hw, u16 table_index) {u16 packed_record[18 ]; +int ret;if (table_index >=NUMROWS_INGRESSSAKEYRECORD )return -EINVAL ;
@@ -789,9 +790,12 @@ set_ingress_sakey_record(struct aq_hw_s *hw, packed_record[16 ] = rec->key_len &0x3 ; -return set_raw_ingress_record (hw, packed_record,18 ,2 , -ROWOFFSET_INGRESSSAKEYRECORD + - table_index); + ret =set_raw_ingress_record (hw, packed_record,18 ,2 , +ROWOFFSET_INGRESSSAKEYRECORD + + table_index); + +memzero_explicit (packed_record,sizeof (packed_record)); +return ret; } int aq_mss_set_ingress_sakey_record(struct aq_hw_s *hw,
@@ -1739,14 +1743,14 @@ static int set_egress_sakey_record(struct aq_hw_s *hw, ret =set_raw_egress_record (hw, packed_record,8 ,2 ,ROWOFFSET_EGRESSSAKEYRECORD + table_index);if (unlikely (ret)) -return ret; + goto clear_key; ret =set_raw_egress_record (hw, packed_record +8 ,8 ,2 ,ROWOFFSET_EGRESSSAKEYRECORD + table_index -32 ); -if (unlikely (ret)) -return ret; -return 0 ; +clear_key: +memzero_explicit (packed_record,sizeof (packed_record)); +return ret; } int aq_mss_set_egress_sakey_record(struct aq_hw_s *hw,
drivers/net/ethernet/broadcom/Kconfig +1 -1
@@ -77,7 +77,7 @@ config BCMGENET select BCM7XXX_PHY select MDIO_BCM_UNIMAC select DIMLIB - select BROADCOM_PHY if ARCH_BCM2835 + select BROADCOM_PHY if (ARCH_BCM2835 && PTP_1588_CLOCK_OPTIONAL) help This driver supports the built-in Ethernet MACs found in the Broadcom BCM7xxx Set Top Box family chipset.
drivers/net/ethernet/broadcom/bnxt/bnxt.c +1 -1
@@ -12605,8 +12605,8 @@ static int bnxt_rx_flow_steer(struct net_device *dev, const struct sk_buff *skb,rcu_read_lock ();hlist_for_each_entry_rcu (fltr, head, hash) {if (bnxt_fltr_match (fltr, new_fltr)) { + rc = fltr->sw_id;rcu_read_unlock (); - rc =0 ; goto err_free; } }
drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c +1 -1
@@ -132,7 +132,7 @@ static int bnxt_set_coalesce(struct net_device *dev, } reset_coalesce: -if (netif_running (dev)) { +if (test_bit (BNXT_STATE_OPEN , &bp->state)) {if (update_stats) { rc =bnxt_close_nic (bp, true, false);if (!rc)
drivers/net/ethernet/chelsio/cxgb3/cxgb3_main.c +1 -0
@@ -1302,6 +1302,7 @@ static int cxgb_up(struct adapter *adap)if (ret <0 ) {CH_ERR (adap,"failed to bind qsets, err %d\n" , ret);t3_intr_disable (adap); +quiesce_rx (adap);free_irq_resources (adap); err = ret; goto out;
drivers/net/ethernet/chelsio/cxgb4vf/cxgb4vf_main.c +1 -1
@@ -858,7 +858,7 @@ static int cxgb4vf_open(struct net_device *dev)*/ err =t4vf_update_port_info (pi);if (err <0 ) -return err; + goto err_unwind;/* * Note that this interface is up and start everything up ...
drivers/net/ethernet/freescale/fman/mac.c +9 -0
@@ -882,12 +882,21 @@ static int mac_probe(struct platform_device *_of_dev)return err; } +static int mac_remove (struct platform_device *pdev) +{ +struct mac_device *mac_dev =platform_get_drvdata (pdev); + +platform_device_unregister (mac_dev->priv->eth_dev); +return 0 ; +} +static struct platform_driver mac_driver = { .driver = { .name =KBUILD_MODNAME , .of_match_table = mac_match, }, .probe = mac_probe, + .remove = mac_remove, };builtin_platform_driver (mac_driver);
drivers/net/ethernet/marvell/mv643xx_eth.c +1 -0
@@ -2477,6 +2477,7 @@ static int mv643xx_eth_open(struct net_device *dev)for (i =0 ; i < mp->rxq_count; i++)rxq_deinit (mp->rxq + i); out: +napi_disable (&mp->napi);free_irq (dev->irq, dev);return err;
drivers/net/ethernet/marvell/octeontx2/nic/otx2_common.c +3 -0
@@ -1013,6 +1013,9 @@ int otx2_config_nix_queues(struct otx2_nic *pfvf)return err; } + pfvf->cq_op_addr = (__force u64 *)otx2_get_regaddr (pfvf, +NIX_LF_CQ_OP_STATUS ); +/* Initialize work queue for receive buffer refill */ pfvf->refill_wrk =devm_kcalloc (pfvf->dev, pfvf->qset.cq_cnt,sizeof (struct refill_work ),GFP_KERNEL );
drivers/net/ethernet/marvell/octeontx2/nic/otx2_common.h +1 -0
@@ -337,6 +337,7 @@ struct otx2_nic {#define OTX2_FLAG_TC_MATCHALL_INGRESS_ENABLED BIT_ULL(13)#define OTX2_FLAG_DMACFLTR_SUPPORT BIT_ULL(14)u64 flags; +u64 *cq_op_addr;struct otx2_qset qset;struct otx2_hw hw;
drivers/net/ethernet/marvell/octeontx2/nic/otx2_pf.c +105 -30
163 lines not on this page · raw message
drivers/net/ethernet/marvell/octeontx2/nic/otx2_struct.h +57 -0
61 lines not on this page · raw message
drivers/net/ethernet/marvell/octeontx2/nic/otx2_txrx.c +62 -7
118 lines not on this page · raw message
drivers/net/ethernet/marvell/octeontx2/nic/otx2_txrx.h +5 -0
@@ -56,6 +56,9 @@*/ #define CQ_QCOUNT_DEFAULT 1 +#define CQ_OP_STAT_OP_ERR 63 +#define CQ_OP_STAT_CQ_ERR 46 +struct queue_stats {u64 bytes;u64 pkts;
@@ -122,6 +125,8 @@ struct otx2_cq_queue {u16 pool_ptrs;u32 cqe_cnt;u32 cq_head; +u32 cq_tail; +u32 pend_cqe;void *cqe_base;struct qmem *cqe;struct otx2_pool *rbpool;
drivers/net/ethernet/marvell/prestera/prestera_rxtx.c +6 -1
@@ -776,6 +776,7 @@ static netdev_tx_t prestera_sdma_xmit(struct prestera_sdma *sdma,int prestera_rxtx_switch_init (struct prestera_switch *sw) {struct prestera_rxtx *rxtx; +int err; rxtx =kzalloc (sizeof (*rxtx),GFP_KERNEL );if (!rxtx)
@@ -783,7 +784,11 @@ int prestera_rxtx_switch_init(struct prestera_switch *sw) sw->rxtx = rxtx; -return prestera_sdma_switch_init (sw); + err =prestera_sdma_switch_init (sw); +if (err) +kfree (rxtx); + +return err; }void prestera_rxtx_switch_fini (struct prestera_switch *sw)
drivers/net/ethernet/mellanox/mlx5/core/cmd.c +8 -3
@@ -1699,12 +1699,17 @@ void mlx5_cmd_flush(struct mlx5_core_dev *dev)struct mlx5_cmd *cmd = &dev->cmd;int i; -for (i =0 ; i < cmd->max_reg_cmds; i++) -while (down_trylock (&cmd->sem)) +for (i =0 ; i < cmd->max_reg_cmds; i++) { +while (down_trylock (&cmd->sem)) {mlx5_cmd_trigger_completions (dev); +cond_resched (); + } + } -while (down_trylock (&cmd->pages_sem)) +while (down_trylock (&cmd->pages_sem)) {mlx5_cmd_trigger_completions (dev); +cond_resched (); + }/* Unlock cmdif */ up (&cmd->pages_sem);
drivers/net/ethernet/mellanox/mlx5/core/en/rep/bridge.c +31 -0
@@ -164,6 +164,36 @@ static int mlx5_esw_bridge_port_changeupper(struct notifier_block *nb, void *ptrreturn err; } +static int +mlx5_esw_bridge_changeupper_validate_netdev (void *ptr) +{ +struct net_device *dev =netdev_notifier_info_to_dev (ptr); +struct netdev_notifier_changeupper_info *info = ptr; +struct net_device *upper = info->upper_dev; +struct net_device *lower; +struct list_head *iter; + +if (!netif_is_bridge_master (upper) || !netif_is_lag_master (dev)) +return 0 ; + +netdev_for_each_lower_dev (dev, lower, iter) { +struct mlx5_core_dev *mdev; +struct mlx5e_priv *priv; + +if (!mlx5e_eswitch_rep (lower)) +continue ; + + priv =netdev_priv (lower); + mdev = priv->mdev; +if (!mlx5_lag_is_active (mdev)) +return -EAGAIN ; +if (!mlx5_lag_is_shared_fdb (mdev)) +return -EOPNOTSUPP ; + } + +return 0 ; +} +static int mlx5_esw_bridge_switchdev_port_event (struct notifier_block *nb,unsigned long event,void *ptr) {
@@ -171,6 +201,7 @@ static int mlx5_esw_bridge_switchdev_port_event(struct notifier_block *nb,switch (event) {case NETDEV_PRECHANGEUPPER : + err =mlx5_esw_bridge_changeupper_validate_netdev (ptr);break ;case NETDEV_CHANGEUPPER :
drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads_termtbl.c +8 -6
@@ -30,9 +30,9 @@ mlx5_eswitch_termtbl_hash(struct mlx5_flow_act *flow_act, sizeof(dest->vport.num), hash); hash =jhash ((const void *)&dest->vport.vhca_id,sizeof (dest->vport.num), hash); -if (dest->vport.pkt_reformat) - hash =jhash (dest->vport.pkt_reformat, -sizeof (*dest->vport.pkt_reformat), +if (flow_act->pkt_reformat) + hash =jhash (flow_act->pkt_reformat, +sizeof (*flow_act->pkt_reformat), hash);return hash; }
@@ -53,9 +53,11 @@ mlx5_eswitch_termtbl_cmp(struct mlx5_flow_act *flow_act1,if (ret)return ret; -return dest1->vport.pkt_reformat && dest2->vport.pkt_reformat ? -memcmp (dest1->vport.pkt_reformat, dest2->vport.pkt_reformat, -sizeof (*dest1->vport.pkt_reformat)) :0 ; +if (flow_act1->pkt_reformat && flow_act2->pkt_reformat) +return memcmp (flow_act1->pkt_reformat, flow_act2->pkt_reformat, +sizeof (*flow_act1->pkt_reformat)); + +return !(flow_act1->pkt_reformat == flow_act2->pkt_reformat); } static int
drivers/net/ethernet/neterion/s2io.c +20 -9
@@ -7125,9 +7125,8 @@ static int s2io_card_up(struct s2io_nic *sp)if (ret) {DBG_PRINT (ERR_DBG ,"%s: Out of memory in Open\n" , dev->name); -s2io_reset (sp); -free_rx_buffers (sp); -return -ENOMEM ; + ret = -ENOMEM ; + goto err_fill_buff; }DBG_PRINT (INFO_DBG ,"Buf in ring:%d is %d:\n" , i, ring->rx_bufs_left);
@@ -7165,18 +7164,16 @@ static int s2io_card_up(struct s2io_nic *sp)/* Enable Rx Traffic and interrupts on the NIC */ if (start_nic (sp)) {DBG_PRINT (ERR_DBG ,"%s: Starting NIC failed\n" , dev->name); -s2io_reset (sp); -free_rx_buffers (sp); -return -ENODEV ; + ret = -ENODEV ; + goto err_out; }/* Add interrupt service routine */ if (s2io_add_isr (sp) !=0 ) {if (sp->config.intr_type ==MSI_X )s2io_rem_isr (sp); -s2io_reset (sp); -free_rx_buffers (sp); -return -ENODEV ; + ret = -ENODEV ; + goto err_out; }timer_setup (&sp->alarm_timer, s2io_alarm_handle,0 );
@@ -7196,6 +7193,20 @@ static int s2io_card_up(struct s2io_nic *sp) }return 0 ; + +err_out: +if (config->napi) { +if (config->intr_type ==MSI_X ) { +for (i =0 ; i < sp->config.rx_ring_num; i++) +napi_disable (&sp->mac_control.rings[i].napi); + }else { +napi_disable (&sp->napi); + } + } +err_fill_buff: +s2io_reset (sp); +free_rx_buffers (sp); +return ret; }/**
drivers/net/ethernet/ni/nixge.c +1 -0
@@ -899,6 +899,7 @@ static int nixge_open(struct net_device *ndev) err_rx_irq:free_irq (priv->tx_irq, ndev); err_tx_irq: +napi_disable (&priv->napi);phy_stop (phy);phy_disconnect (phy);tasklet_kill (&priv->dma_err_tasklet);
drivers/net/ethernet/stmicro/stmmac/dwmac-intel.c +10 -4
@@ -593,7 +593,6 @@ static int ehl_common_data(struct pci_dev *pdev, { plat->rx_queues_to_use =8 ; plat->tx_queues_to_use =8 ; - plat->clk_ptp_rate =200000000 ; plat->use_phy_wol =1 ; plat->safety_feat_cfg->tsoee =1 ;
@@ -618,6 +617,8 @@ static int ehl_sgmii_data(struct pci_dev *pdev, plat->serdes_powerup = intel_serdes_powerup; plat->serdes_powerdown = intel_serdes_powerdown; + plat->clk_ptp_rate =204800000 ; +return ehl_common_data (pdev, plat); }
@@ -631,6 +632,8 @@ static int ehl_rgmii_data(struct pci_dev *pdev, plat->bus_id =1 ; plat->phy_interface =PHY_INTERFACE_MODE_RGMII ; + plat->clk_ptp_rate =204800000 ; +return ehl_common_data (pdev, plat); }
@@ -647,6 +650,8 @@ static int ehl_pse0_common_data(struct pci_dev *pdev, plat->bus_id =2 ; plat->addr64 =32 ; + plat->clk_ptp_rate =200000000 ; +intel_mgbe_pse_crossts_adj (intel_priv,EHL_PSE_ART_MHZ );return ehl_common_data (pdev, plat);
@@ -686,6 +691,8 @@ static int ehl_pse1_common_data(struct pci_dev *pdev, plat->bus_id =3 ; plat->addr64 =32 ; + plat->clk_ptp_rate =200000000 ; +intel_mgbe_pse_crossts_adj (intel_priv,EHL_PSE_ART_MHZ );return ehl_common_data (pdev, plat);
@@ -721,7 +728,8 @@ static int tgl_common_data(struct pci_dev *pdev, { plat->rx_queues_to_use =6 ; plat->tx_queues_to_use =4 ; - plat->clk_ptp_rate =200000000 ; + plat->clk_ptp_rate =204800000 ; + plat->speed_mode_2500 = intel_speed_mode_2500; plat->safety_feat_cfg->tsoee =1 ; plat->safety_feat_cfg->mrxpee =0 ;
@@ -741,7 +749,6 @@ static int tgl_sgmii_phy0_data(struct pci_dev *pdev, { plat->bus_id =1 ; plat->phy_interface =PHY_INTERFACE_MODE_SGMII ; - plat->speed_mode_2500 = intel_speed_mode_2500; plat->serdes_powerup = intel_serdes_powerup; plat->serdes_powerdown = intel_serdes_powerdown;return tgl_common_data (pdev, plat);
@@ -756,7 +763,6 @@ static int tgl_sgmii_phy1_data(struct pci_dev *pdev, { plat->bus_id =2 ; plat->phy_interface =PHY_INTERFACE_MODE_SGMII ; - plat->speed_mode_2500 = intel_speed_mode_2500; plat->serdes_powerup = intel_serdes_powerup; plat->serdes_powerdown = intel_serdes_powerdown;return tgl_common_data (pdev, plat);
drivers/net/ethernet/stmicro/stmmac/dwmac-loongson.c +31 -8
@@ -75,20 +75,24 @@ static int loongson_dwmac_probe(struct pci_dev *pdev, const struct pci_device_id plat->mdio_bus_data =devm_kzalloc (&pdev->dev,sizeof (*plat->mdio_bus_data),GFP_KERNEL ); -if (!plat->mdio_bus_data) -return -ENOMEM ; +if (!plat->mdio_bus_data) { + ret = -ENOMEM ; + goto err_put_node; + } plat->mdio_bus_data->needs_reset = true; } plat->dma_cfg =devm_kzalloc (&pdev->dev,sizeof (*plat->dma_cfg),GFP_KERNEL ); -if (!plat->dma_cfg) -return -ENOMEM ; +if (!plat->dma_cfg) { + ret = -ENOMEM ; + goto err_put_node; + }/* Enable pci device */ ret =pci_enable_device (pdev);if (ret) {dev_err (&pdev->dev,"%s: ERROR: failed to enable device\n" , __func__); -return ret; + goto err_put_node; }/* Get the base address of device */
@@ -97,7 +101,7 @@ static int loongson_dwmac_probe(struct pci_dev *pdev, const struct pci_device_idcontinue ; ret =pcim_iomap_regions (pdev,BIT (0 ),pci_name (pdev));if (ret) -return ret; + goto err_disable_device;break ; }
@@ -108,7 +112,8 @@ static int loongson_dwmac_probe(struct pci_dev *pdev, const struct pci_device_id phy_mode =device_get_phy_mode (&pdev->dev);if (phy_mode <0 ) {dev_err (&pdev->dev,"phy_mode not found\n" ); -return phy_mode; + ret = phy_mode; + goto err_disable_device; } plat->phy_interface = phy_mode;
@@ -125,6 +130,7 @@ static int loongson_dwmac_probe(struct pci_dev *pdev, const struct pci_device_idif (res.irq <0 ) {dev_err (&pdev->dev,"IRQ macirq not found\n" ); ret = -ENODEV ; + goto err_disable_msi; } res.wol_irq =of_irq_get_byname (np,"eth_wake_irq" );
@@ -137,15 +143,31 @@ static int loongson_dwmac_probe(struct pci_dev *pdev, const struct pci_device_idif (res.lpi_irq <0 ) {dev_err (&pdev->dev,"IRQ eth_lpi not found\n" ); ret = -ENODEV ; + goto err_disable_msi; } -return stmmac_dvr_probe (&pdev->dev, plat, &res); + ret =stmmac_dvr_probe (&pdev->dev, plat, &res); +if (ret) + goto err_disable_msi; + +return ret; + +err_disable_msi: +pci_disable_msi (pdev); +err_disable_device: +pci_disable_device (pdev); +err_put_node: +of_node_put (plat->mdio_node); +return ret; }static void loongson_dwmac_remove (struct pci_dev *pdev) { +struct net_device *ndev =dev_get_drvdata (&pdev->dev); +struct stmmac_priv *priv =netdev_priv (ndev);int i; +of_node_put (priv->plat->mdio_node);stmmac_dvr_remove (&pdev->dev);for (i =0 ; i <PCI_STD_NUM_BARS ; i++) {
@@ -155,6 +177,7 @@ static void loongson_dwmac_remove(struct pci_dev *pdev)break ; } +pci_disable_msi (pdev);pci_disable_device (pdev); }
drivers/net/ethernet/stmicro/stmmac/dwmac-meson8b.c +3 -5
@@ -272,11 +272,9 @@ static int meson8b_devm_clk_prepare_enable(struct meson8b_dwmac *dwmac,if (ret)return ret; -devm_add_action_or_reset (dwmac->dev, - (void (*)(void *))clk_disable_unprepare, - dwmac->rgmii_tx_clk); - -return 0 ; +return devm_add_action_or_reset (dwmac->dev, + (void (*)(void *))clk_disable_unprepare, + clk); }static int meson8b_init_rgmii_delays (struct meson8b_dwmac *dwmac)
drivers/net/ethernet/ti/cpsw.c +2 -0
@@ -856,6 +856,8 @@ static int cpsw_ndo_open(struct net_device *ndev) err_cleanup:if (!cpsw->usage_count) { +napi_disable (&cpsw->napi_rx); +napi_disable (&cpsw->napi_tx);cpdma_ctlr_stop (cpsw->dma);cpsw_destroy_xdp_rxqs (cpsw); }
drivers/net/ethernet/tundra/tsi108_eth.c +4 -1
@@ -1302,12 +1302,15 @@ static int tsi108_open(struct net_device *dev) data->rxring =dma_alloc_coherent (&data->pdev->dev, rxring_size, &data->rxdma,GFP_KERNEL ); -if (!data->rxring) +if (!data->rxring) { +free_irq (data->irq_num, dev);return -ENOMEM ; + } data->txring =dma_alloc_coherent (&data->pdev->dev, txring_size, &data->txdma,GFP_KERNEL );if (!data->txring) { +free_irq (data->irq_num, dev);dma_free_coherent (&data->pdev->dev, rxring_size, data->rxring, data->rxdma);return -ENOMEM ;
drivers/net/hamradio/bpqether.c +1 -1
@@ -534,7 +534,7 @@ static int bpq_device_event(struct notifier_block *this,if (!net_eq (dev_net (dev), &init_net))return NOTIFY_DONE ; -if (!dev_is_ethdev (dev)) +if (!dev_is_ethdev (dev) && !bpq_get_ax25_dev (dev))return NOTIFY_DONE ;switch (event) {
drivers/net/macsec.c +13 -10
@@ -1386,7 +1386,8 @@ static struct macsec_rx_sc *del_rx_sc(struct macsec_secy *secy, sci_t sci)return NULL ; } -static struct macsec_rx_sc *create_rx_sc (struct net_device *dev,sci_t sci) +static struct macsec_rx_sc *create_rx_sc (struct net_device *dev,sci_t sci, +bool active) {struct macsec_rx_sc *rx_sc;struct macsec_dev *macsec;
@@ -1410,7 +1411,7 @@ static struct macsec_rx_sc *create_rx_sc(struct net_device *dev, sci_t sci) } rx_sc->sci = sci; - rx_sc->active = true; + rx_sc->active = active;refcount_set (&rx_sc->refcnt,1 ); secy = &macsec_priv (dev)->secy;
@@ -1819,6 +1820,7 @@ static int macsec_add_rxsa(struct sk_buff *skb, struct genl_info *info) secy->key_len); err =macsec_offload (ops->mdo_add_rxsa, &ctx); +memzero_explicit (ctx.sa.key, secy->key_len);if (err) goto cleanup; }
@@ -1863,7 +1865,7 @@ static int macsec_add_rxsc(struct sk_buff *skb, struct genl_info *info)struct macsec_rx_sc *rx_sc;struct nlattr *tb_rxsc[MACSEC_RXSC_ATTR_MAX +1 ];struct macsec_secy *secy; -bool was_active; +bool active = true;int ret;if (!attrs[MACSEC_ATTR_IFINDEX ])
@@ -1885,16 +1887,15 @@ static int macsec_add_rxsc(struct sk_buff *skb, struct genl_info *info) secy = &macsec_priv (dev)->secy; sci =nla_get_sci (tb_rxsc[MACSEC_RXSC_ATTR_SCI ]); - rx_sc =create_rx_sc (dev, sci); +if (tb_rxsc[MACSEC_RXSC_ATTR_ACTIVE ]) + active =nla_get_u8 (tb_rxsc[MACSEC_RXSC_ATTR_ACTIVE ]); + + rx_sc =create_rx_sc (dev, sci, active);if (IS_ERR (rx_sc)) {rtnl_unlock ();return PTR_ERR (rx_sc); } - was_active = rx_sc->active; -if (tb_rxsc[MACSEC_RXSC_ATTR_ACTIVE ]) - rx_sc->active = !!nla_get_u8 (tb_rxsc[MACSEC_RXSC_ATTR_ACTIVE ]); -if (macsec_is_offloaded (netdev_priv (dev))) {const struct macsec_ops *ops;struct macsec_context ctx;
@@ -1918,7 +1919,8 @@ static int macsec_add_rxsc(struct sk_buff *skb, struct genl_info *info)return 0 ; cleanup: - rx_sc->active = was_active; +del_rx_sc (secy, sci); +free_rx_sc (rx_sc);rtnl_unlock ();return ret; }
@@ -2061,6 +2063,7 @@ static int macsec_add_txsa(struct sk_buff *skb, struct genl_info *info) secy->key_len); err =macsec_offload (ops->mdo_add_txsa, &ctx); +memzero_explicit (ctx.sa.key, secy->key_len);if (err) goto cleanup; }
@@ -2557,7 +2560,7 @@ static bool macsec_is_configured(struct macsec_dev *macsec)struct macsec_tx_sc *tx_sc = &secy->tx_sc;int i; -if (secy->n_rx_sc >0 ) +if (secy->rx_sc)return true;for (i =0 ; i <MACSEC_NUM_AN ; i++)
drivers/net/macvlan.c +3 -1
@@ -1521,8 +1521,10 @@ int macvlan_common_newlink(struct net *src_net, struct net_device *dev,/* the macvlan port may be freed by macvlan_uninit when fail to register. * so we destroy the macvlan port only when it's valid. */ -if (create &&macvlan_port_get_rtnl (lowerdev)) +if (create &&macvlan_port_get_rtnl (lowerdev)) { +macvlan_flush_sources (port, vlan);macvlan_port_destroy (port->dev); + }return err; }EXPORT_SYMBOL_GPL (macvlan_common_newlink);
drivers/net/phy/mscc/mscc_macsec.c +1 -0
@@ -632,6 +632,7 @@ static void vsc8584_macsec_free_flow(struct vsc8531_private *priv,list_del (&flow->list);clear_bit (flow->index, bitmap); +memzero_explicit (flow->key,sizeof (flow->key));kfree (flow); }
drivers/net/tun.c +13 -5
@@ -1949,17 +1949,25 @@ static ssize_t tun_get_user(struct tun_struct *tun, struct tun_file *tfile, skb_headlen(skb));if (unlikely (headlen >skb_headlen (skb))) { +WARN_ON_ONCE (1 ); + err = -ENOMEM ;atomic_long_inc (&tun->dev->rx_dropped); +napi_busy:napi_free_frags (&tfile->napi);rcu_read_unlock ();mutex_unlock (&tfile->napi_mutex); -WARN_ON (1 ); -return -ENOMEM ; +return err; } -local_bh_disable (); -napi_gro_frags (&tfile->napi); -local_bh_enable (); +if (likely (napi_schedule_prep (&tfile->napi))) { +local_bh_disable (); +napi_gro_frags (&tfile->napi); +napi_complete (&tfile->napi); +local_bh_enable (); + }else { + err = -EBUSY ; + goto napi_busy; + }mutex_unlock (&tfile->napi_mutex); }else if (tfile->napi_enabled) {struct sk_buff_head *queue = &tfile->sk.sk_write_queue;
drivers/net/wan/lapbether.c +2 -1
@@ -325,6 +325,7 @@ static int lapbeth_open(struct net_device *dev) err =lapb_register (dev, &lapbeth_callbacks);if (err !=LAPB_OK ) { +napi_disable (&lapbeth->napi);pr_err ("lapb_register error: %d\n" , err);return -ENODEV ; }
@@ -446,7 +447,7 @@ static int lapbeth_device_event(struct notifier_block *this,if (dev_net (dev) != &init_net)return NOTIFY_DONE ; -if (!dev_is_ethdev (dev)) +if (!dev_is_ethdev (dev) && !lapbeth_get_x25_dev (dev))return NOTIFY_DONE ;switch (event) {
drivers/net/wireless/ath/ath11k/reg.c +1 -5
@@ -247,11 +247,7 @@ int ath11k_regd_update(struct ath11k *ar) goto err; } -rtnl_lock (); -wiphy_lock (ar->hw->wiphy); - ret =regulatory_set_wiphy_regd_sync (ar->hw->wiphy, regd_copy); -wiphy_unlock (ar->hw->wiphy); -rtnl_unlock (); + ret =regulatory_set_wiphy_regd (ar->hw->wiphy, regd_copy);kfree (regd_copy);
drivers/net/wwan/iosm/iosm_ipc_pcie.c +8 -3
@@ -232,6 +232,7 @@ static void ipc_pcie_config_init(struct iosm_pcie *ipc_pcie)*/ static enum ipc_pcie_sleep_state ipc_pcie_read_bios_cfg (struct device *dev) { +enum ipc_pcie_sleep_state sleep_state =IPC_PCIE_D0L12 ;union acpi_object *object;acpi_handle handle_acpi;
@@ -242,12 +243,16 @@ static enum ipc_pcie_sleep_state ipc_pcie_read_bios_cfg(struct device *dev) } object =acpi_evaluate_dsm (handle_acpi, &wwan_acpi_guid,0 ,3 ,NULL ); +if (!object) + goto default_ret; + +if (object->integer.value ==3 ) + sleep_state =IPC_PCIE_D3L2 ; -if (object && object->integer.value ==3 ) -return IPC_PCIE_D3L2 ; +kfree (object); default_ret: -return IPC_PCIE_D0L12 ; +return sleep_state; } static int ipc_pcie_probe(struct pci_dev *pci,
drivers/net/wwan/iosm/iosm_ipc_wwan.c +1 -0
@@ -167,6 +167,7 @@ static void ipc_wwan_setup(struct net_device *iosm_dev) iosm_dev->max_mtu =ETH_MAX_MTU ; iosm_dev->flags =IFF_POINTOPOINT |IFF_NOARP ; + iosm_dev->needs_free_netdev = true; iosm_dev->netdev_ops = &ipc_inm_ops; }
drivers/net/wwan/mhi_wwan_mbim.c +1 -0
@@ -582,6 +582,7 @@ static void mhi_mbim_setup(struct net_device *ndev) ndev->min_mtu =ETH_MIN_MTU ; ndev->max_mtu =MHI_MAX_BUF_SZ - ndev->needed_headroom; ndev->tx_queue_len =1000 ; + ndev->needs_free_netdev = true; }static const struct wwan_ops mhi_mbim_wwan_ops = {
drivers/phy/ralink/phy-mt7621-pci.c +2 -1
@@ -280,7 +280,8 @@ static struct phy *mt7621_pcie_phy_of_xlate(struct device *dev, }static const struct soc_device_attribute mt7621_pci_quirks_match[] = { - { .soc_id ="mt7621" , .revision ="E2" } + { .soc_id ="mt7621" , .revision ="E2" }, + {/* sentinel */ } };static const struct regmap_config mt7621_pci_phy_regmap_config = {
drivers/phy/st/phy-stm32-usbphyc.c +2 -0
@@ -532,6 +532,8 @@ static int stm32_usbphyc_probe(struct platform_device *pdev) ret =of_property_read_u32 (child,"reg" , &index);if (ret || index > usbphyc->nphys) {dev_err (&phy->dev,"invalid reg property: %d\n" , ret); +if (!ret) + ret = -EINVAL ; goto put_child; }
drivers/platform/x86/hp-wmi.c +10 -2
@@ -984,8 +984,16 @@ static int __init hp_wmi_bios_setup(struct platform_device *device) wwan_rfkill =NULL ; rfkill2_count =0 ; -if (hp_wmi_rfkill_setup (device)) -hp_wmi_rfkill2_setup (device); +/* +* In pre-2009 BIOS, command 1Bh return 0x4 to indicate that +* BIOS no longer controls the power for the wireless +* devices. All features supported by this command will no +* longer be supported. +*/ +if (!hp_wmi_bios_2009_later ()) { +if (hp_wmi_rfkill_setup (device)) +hp_wmi_rfkill2_setup (device); + }thermal_profile_setup ();
drivers/soundwire/qcom.c +9 -0
@@ -315,6 +315,9 @@ static int qcom_swrm_cmd_fifo_wr_cmd(struct qcom_swrm_ctrl *swrm, u8 cmd_data,if (swrm_wait_for_wr_fifo_avail (swrm))return SDW_CMD_FAIL_OTHER ; +if (cmd_id ==SWR_BROADCAST_CMD_ID ) +reinit_completion (&swrm->broadcast); +/* Its assumed that write is okay as we do not get any status back */ swrm->reg_write (swrm,SWRM_CMD_FIFO_WR_CMD , val);
@@ -348,6 +351,12 @@ static int qcom_swrm_cmd_fifo_rd_cmd(struct qcom_swrm_ctrl *swrm, val =swrm_get_packed_reg_val (&swrm->rcmd_id, len, dev_addr, reg_addr); +/* +* Check for outstanding cmd wrt. write fifo depth to avoid +* overflow as read will also increase write fifo cnt. +*/ +swrm_wait_for_wr_fifo_avail (swrm); +/* wait for FIFO RD to complete to avoid overflow */ usleep_range (100 ,105 ); swrm->reg_write (swrm,SWRM_CMD_FIFO_RD_CMD , val);
drivers/thunderbolt/path.c +25 -17
85 lines not on this page · raw message
drivers/thunderbolt/tb.c +80 -16
148 lines not on this page · raw message
drivers/thunderbolt/tb.h +4 -1
@@ -354,6 +354,7 @@ enum tb_path_port {* when deactivating this path * @hops: Path hops * @path_length: How many hops the path uses +* @alloc_hopid: Does this path consume port HopID * * A path consists of a number of hops (see &struct tb_path_hop). To * establish a PCIe tunnel two paths have to be created between the two
@@ -374,6 +375,7 @@ struct tb_path {bool clear_fc;struct tb_path_hop *hops;int path_length; +bool alloc_hopid; };/* HopIDs 0-7 are reserved by the Thunderbolt protocol */
@@ -957,7 +959,8 @@ int tb_dp_port_enable(struct tb_port *port, bool enable);struct tb_path *tb_path_discover (struct tb_port *src,int src_hopid,struct tb_port *dst,int dst_hopid, -struct tb_port **last,const char *name); +struct tb_port **last,const char *name, +bool alloc_hopid);struct tb_path *tb_path_alloc (struct tb *tb,struct tb_port *src,int src_hopid,struct tb_port *dst,int dst_hopid,int link_nr,const char *name);
drivers/thunderbolt/tunnel.c +17 -10
@@ -207,12 +207,14 @@ static int tb_pci_init_path(struct tb_path *path)* tb_tunnel_discover_pci() - Discover existing PCIe tunnels * @tb: Pointer to the domain structure * @down: PCIe downstream adapter +* @alloc_hopid: Allocate HopIDs from visited ports * * If @down adapter is active, follows the tunnel to the PCIe upstream * adapter and back. Returns the discovered tunnel or %NULL if there was * no tunnel. */ -struct tb_tunnel *tb_tunnel_discover_pci (struct tb *tb,struct tb_port *down) +struct tb_tunnel *tb_tunnel_discover_pci (struct tb *tb,struct tb_port *down, +bool alloc_hopid) {struct tb_tunnel *tunnel;struct tb_path *path;
@@ -233,7 +235,7 @@ struct tb_tunnel *tb_tunnel_discover_pci(struct tb *tb, struct tb_port *down)* case. */ path =tb_path_discover (down,TB_PCI_HOPID ,NULL ,-1 , - &tunnel->dst_port,"PCIe Up" ); + &tunnel->dst_port,"PCIe Up" , alloc_hopid);if (!path) {/* Just disable the downstream port */ tb_pci_port_enable (down, false);
@@ -244,7 +246,7 @@ struct tb_tunnel *tb_tunnel_discover_pci(struct tb *tb, struct tb_port *down) goto err_free; path =tb_path_discover (tunnel->dst_port,-1 , down,TB_PCI_HOPID ,NULL , -"PCIe Down" ); +"PCIe Down" , alloc_hopid);if (!path) goto err_deactivate; tunnel->paths[TB_PCI_PATH_DOWN ] = path;
@@ -761,6 +763,7 @@ static int tb_dp_init_video_path(struct tb_path *path)* tb_tunnel_discover_dp() - Discover existing Display Port tunnels * @tb: Pointer to the domain structure * @in: DP in adapter +* @alloc_hopid: Allocate HopIDs from visited ports * * If @in adapter is active, follows the tunnel to the DP out adapter * and back. Returns the discovered tunnel or %NULL if there was no
@@ -768,7 +771,8 @@ static int tb_dp_init_video_path(struct tb_path *path)* * Return: DP tunnel or %NULL if no tunnel found. */ -struct tb_tunnel *tb_tunnel_discover_dp (struct tb *tb,struct tb_port *in) +struct tb_tunnel *tb_tunnel_discover_dp (struct tb *tb,struct tb_port *in, +bool alloc_hopid) {struct tb_tunnel *tunnel;struct tb_port *port;
@@ -787,7 +791,7 @@ struct tb_tunnel *tb_tunnel_discover_dp(struct tb *tb, struct tb_port *in) tunnel->src_port = in; path =tb_path_discover (in,TB_DP_VIDEO_HOPID ,NULL ,-1 , - &tunnel->dst_port,"Video" ); + &tunnel->dst_port,"Video" , alloc_hopid);if (!path) {/* Just disable the DP IN port */ tb_dp_port_enable (in, false);
@@ -797,14 +801,15 @@ struct tb_tunnel *tb_tunnel_discover_dp(struct tb *tb, struct tb_port *in)if (tb_dp_init_video_path (tunnel->paths[TB_DP_VIDEO_PATH_OUT ])) goto err_free; - path =tb_path_discover (in,TB_DP_AUX_TX_HOPID ,NULL ,-1 ,NULL ,"AUX TX" ); + path =tb_path_discover (in,TB_DP_AUX_TX_HOPID ,NULL ,-1 ,NULL ,"AUX TX" , + alloc_hopid);if (!path) goto err_deactivate; tunnel->paths[TB_DP_AUX_PATH_OUT ] = path;tb_dp_init_aux_path (tunnel->paths[TB_DP_AUX_PATH_OUT ]); path =tb_path_discover (tunnel->dst_port,-1 , in,TB_DP_AUX_RX_HOPID , - &port,"AUX RX" ); + &port,"AUX RX" , alloc_hopid);if (!path) goto err_deactivate; tunnel->paths[TB_DP_AUX_PATH_IN ] = path;
@@ -1344,12 +1349,14 @@ static void tb_usb3_init_path(struct tb_path *path)* tb_tunnel_discover_usb3() - Discover existing USB3 tunnels * @tb: Pointer to the domain structure * @down: USB3 downstream adapter +* @alloc_hopid: Allocate HopIDs from visited ports * * If @down adapter is active, follows the tunnel to the USB3 upstream * adapter and back. Returns the discovered tunnel or %NULL if there was * no tunnel. */ -struct tb_tunnel *tb_tunnel_discover_usb3 (struct tb *tb,struct tb_port *down) +struct tb_tunnel *tb_tunnel_discover_usb3 (struct tb *tb,struct tb_port *down, +bool alloc_hopid) {struct tb_tunnel *tunnel;struct tb_path *path;
@@ -1370,7 +1377,7 @@ struct tb_tunnel *tb_tunnel_discover_usb3(struct tb *tb, struct tb_port *down)* case. */ path =tb_path_discover (down,TB_USB3_HOPID ,NULL ,-1 , - &tunnel->dst_port,"USB3 Down" ); + &tunnel->dst_port,"USB3 Down" , alloc_hopid);if (!path) {/* Just disable the downstream port */ tb_usb3_port_enable (down, false);
@@ -1380,7 +1387,7 @@ struct tb_tunnel *tb_tunnel_discover_usb3(struct tb *tb, struct tb_port *down)tb_usb3_init_path (tunnel->paths[TB_USB3_PATH_DOWN ]); path =tb_path_discover (tunnel->dst_port,-1 , down,TB_USB3_HOPID ,NULL , -"USB3 Up" ); +"USB3 Up" , alloc_hopid);if (!path) goto err_deactivate; tunnel->paths[TB_USB3_PATH_UP ] = path;
drivers/thunderbolt/tunnel.h +6 -3
@@ -64,10 +64,12 @@ struct tb_tunnel {int allocated_down; }; -struct tb_tunnel *tb_tunnel_discover_pci (struct tb *tb,struct tb_port *down); +struct tb_tunnel *tb_tunnel_discover_pci (struct tb *tb,struct tb_port *down, +bool alloc_hopid);struct tb_tunnel *tb_tunnel_alloc_pci (struct tb *tb,struct tb_port *up,struct tb_port *down); -struct tb_tunnel *tb_tunnel_discover_dp (struct tb *tb,struct tb_port *in); +struct tb_tunnel *tb_tunnel_discover_dp (struct tb *tb,struct tb_port *in, +bool alloc_hopid);struct tb_tunnel *tb_tunnel_alloc_dp (struct tb *tb,struct tb_port *in,struct tb_port *out,int link_nr,int max_up,int max_down);
@@ -77,7 +79,8 @@ struct tb_tunnel *tb_tunnel_alloc_dma(struct tb *tb, struct tb_port *nhi, int receive_ring);bool tb_tunnel_match_dma (const struct tb_tunnel *tunnel,int transmit_path,int transmit_ring,int receive_path,int receive_ring); -struct tb_tunnel *tb_tunnel_discover_usb3 (struct tb *tb,struct tb_port *down); +struct tb_tunnel *tb_tunnel_discover_usb3 (struct tb *tb,struct tb_port *down, +bool alloc_hopid);struct tb_tunnel *tb_tunnel_alloc_usb3 (struct tb *tb,struct tb_port *up,struct tb_port *down,int max_up,int max_down);
fs/btrfs/disk-io.c +3 -1
@@ -2404,7 +2404,9 @@ static int btrfs_read_roots(struct btrfs_fs_info *fs_info) fs_info->dev_root = root; }/* Initialize fs_info for all devices in any case */ -btrfs_init_devices_late (fs_info); + ret =btrfs_init_devices_late (fs_info); +if (ret) + goto out;/* If IGNOREDATACSUMS is set don't bother reading the csum root. */ if (!btrfs_test_opt (fs_info,IGNOREDATACSUMS )) {
fs/btrfs/tests/btrfs-tests.c +1 -1
@@ -199,7 +199,7 @@ void btrfs_free_dummy_fs_info(struct btrfs_fs_info *fs_info)void btrfs_free_dummy_root (struct btrfs_root *root) { -if (!root) +if (IS_ERR_OR_NULL (root))return ;/* Will be freed by btrfs_free_fs_roots */ if (WARN_ON (test_bit (BTRFS_ROOT_IN_RADIX , &root->state)))
fs/btrfs/volumes.c +17 -10
@@ -6841,18 +6841,18 @@ static bool dev_args_match_fs_devices(const struct btrfs_dev_lookup_args *args,static bool dev_args_match_device (const struct btrfs_dev_lookup_args *args,const struct btrfs_device *device) { -ASSERT ((args->devid != (u64)-1 ) || args->missing); +if (args->missing) { +if (test_bit (BTRFS_DEV_STATE_IN_FS_METADATA , &device->dev_state) && + !device->bdev) +return true; +return false; + } -if ((args->devid != (u64)-1 ) && device->devid != args->devid) +if (device->devid != args->devid)return false;if (args->uuid &&memcmp (device->uuid, args->uuid,BTRFS_UUID_SIZE ) !=0 )return false; -if (!args->missing) -return true; -if (test_bit (BTRFS_DEV_STATE_IN_FS_METADATA , &device->dev_state) && - !device->bdev) -return true; -return false; +return true; }/*
@@ -7681,10 +7681,11 @@ int btrfs_read_chunk_tree(struct btrfs_fs_info *fs_info)return ret; } -void btrfs_init_devices_late (struct btrfs_fs_info *fs_info) +int btrfs_init_devices_late (struct btrfs_fs_info *fs_info) {struct btrfs_fs_devices *fs_devices = fs_info->fs_devices, *seed_devs;struct btrfs_device *device; +int ret =0 ; fs_devices->fs_info = fs_info;
@@ -7693,12 +7694,18 @@ void btrfs_init_devices_late(struct btrfs_fs_info *fs_info) device->fs_info = fs_info;list_for_each_entry (seed_devs, &fs_devices->seed_list, seed_list) { -list_for_each_entry (device, &seed_devs->devices, dev_list) +list_for_each_entry (device, &seed_devs->devices, dev_list) { device->fs_info = fs_info; + ret =btrfs_get_dev_zone_info (device, false); +if (ret) +break ; + } seed_devs->fs_info = fs_info; }mutex_unlock (&fs_devices->device_list_mutex); + +return ret; } static u64 btrfs_dev_stats_value(const struct extent_buffer *eb,
fs/btrfs/volumes.h +1 -1
@@ -539,7 +539,7 @@ int find_free_dev_extent(struct btrfs_device *device, u64 num_bytes,void btrfs_dev_stat_inc_and_print (struct btrfs_device *dev,int index);int btrfs_get_dev_stats (struct btrfs_fs_info *fs_info,struct btrfs_ioctl_get_dev_stats *stats); -void btrfs_init_devices_late (struct btrfs_fs_info *fs_info); +int btrfs_init_devices_late (struct btrfs_fs_info *fs_info);int btrfs_init_dev_stats (struct btrfs_fs_info *fs_info);int btrfs_run_dev_stats (struct btrfs_trans_handle *trans);void btrfs_rm_dev_replace_remove_srcdev (struct btrfs_device *srcdev);
fs/fuse/readdir.c +9 -1
@@ -77,8 +77,10 @@ static void fuse_add_dirent_to_cache(struct file *file, goto unlock; addr =kmap_atomic (page); -if (!offset) +if (!offset) {clear_page (addr); +SetPageUptodate (page); + }memcpy (addr + offset, dirent, reclen);kunmap_atomic (addr); fi->rdc.size = (index <<PAGE_SHIFT ) + offset + reclen;
@@ -516,6 +518,12 @@ static int fuse_readdir_cached(struct file *file, struct dir_context *ctx) page =find_get_page_flags (file->f_mapping, index,FGP_ACCESSED |FGP_LOCK ); +/* Page gone missing, then re-added to cache, but not initialized? */ +if (page && !PageUptodate (page)) { +unlock_page (page); +put_page (page); + page =NULL ; + }spin_lock (&fi->rdc.lock);if (!page) {/*
fs/nilfs2/segment.c +8 -7
@@ -317,7 +317,7 @@ void nilfs_relax_pressure_in_lock(struct super_block *sb)struct the_nilfs *nilfs = sb->s_fs_info;struct nilfs_sc_info *sci = nilfs->ns_writer; -if (!sci || !sci->sc_flush_request) +if (sb_rdonly (sb) ||unlikely (!sci) || !sci->sc_flush_request)return ;set_bit (NILFS_SC_PRIOR_FLUSH , &sci->sc_flags);
@@ -2243,7 +2243,7 @@ int nilfs_construct_segment(struct super_block *sb)struct nilfs_transaction_info *ti;int err; -if (!sci) +if (sb_rdonly (sb) ||unlikely (!sci))return -EROFS ;/* A call inside transactions causes a deadlock. */
@@ -2282,7 +2282,7 @@ int nilfs_construct_dsync_segment(struct super_block *sb, struct inode *inode,struct nilfs_transaction_info ti;int err =0 ; -if (!sci) +if (sb_rdonly (sb) ||unlikely (!sci))return -EROFS ;nilfs_transaction_lock (sb, &ti,0 );
@@ -2778,11 +2778,12 @@ int nilfs_attach_log_writer(struct super_block *sb, struct nilfs_root *root)if (nilfs->ns_writer) {/* -* This happens if the filesystem was remounted -* read/write after nilfs_error degenerated it into a -* read-only mount. +* This happens if the filesystem is made read-only by +* __nilfs_error or nilfs_remount and then remounted +* read/write. In these cases, reuse the existing +* writer. */ -nilfs_detach_log_writer (sb); +return 0 ; } nilfs->ns_writer =nilfs_segctor_new (sb, root);
fs/nilfs2/super.c +0 -2
@@ -1133,8 +1133,6 @@ static int nilfs_remount(struct super_block *sb, int *flags, char *data)if ((bool )(*flags &SB_RDONLY ) ==sb_rdonly (sb)) goto out;if (*flags &SB_RDONLY ) { -/* Shutting down log writer */ -nilfs_detach_log_writer (sb); sb->s_flags |=SB_RDONLY ;/*
fs/nilfs2/the_nilfs.c +0 -2
@@ -690,9 +690,7 @@ int nilfs_count_free_blocks(struct the_nilfs *nilfs, sector_t *nblocks) {unsigned long ncleansegs; -down_read (&NILFS_MDT (nilfs->ns_dat)->mi_sem); ncleansegs =nilfs_sufile_get_ncleansegs (nilfs->ns_sufile); -up_read (&NILFS_MDT (nilfs->ns_dat)->mi_sem); *nblocks = (sector_t )ncleansegs * nilfs->ns_blocks_per_segment;return 0 ; }
fs/udf/namei.c +1 -1
@@ -240,7 +240,7 @@ static struct fileIdentDesc *udf_find_entry(struct inode *dir, poffset - lfi); else {if (!copy_name) { - copy_name =kmalloc (UDF_NAME_LEN , + copy_name =kmalloc (UDF_NAME_LEN_CS0 ,GFP_NOFS );if (!copy_name) { fi =ERR_PTR (-ENOMEM );
include/asm-generic/vmlinux.lds.h +1 -1
@@ -337,6 +337,7 @@#define DATA_DATA \ *(.xiptext) \ *(DATA_MAIN) \ + *(.data..decrypted) \ *(.ref.data) \ *(.data..shared_aligned)/* percpu related */ \ MEM_KEEP(init.data*) \
@@ -969,7 +970,6 @@#ifdef CONFIG_AMD_MEM_ENCRYPT #define PERCPU_DECRYPTED_SECTION \ . = ALIGN(PAGE_SIZE); \ - *(.data..decrypted) \ *(.data..percpu..decrypted) \ . = ALIGN(PAGE_SIZE);#else
include/linux/bpf.h +1 -0
@@ -2022,6 +2022,7 @@ int sock_map_get_from_fd(const union bpf_attr *attr, struct bpf_prog *prog);int sock_map_prog_detach (const union bpf_attr *attr,enum bpf_prog_type ptype);int sock_map_update_elem_sys (struct bpf_map *map,void *key,void *value,u64 flags);void sock_map_unhash (struct sock *sk); +void sock_map_destroy (struct sock *sk);void sock_map_close (struct sock *sk,long timeout);#else static inline int bpf_prog_offload_init(struct bpf_prog *prog,
include/linux/bpf_verifier.h +21 -0
@@ -328,6 +328,27 @@ struct bpf_verifier_state { iter < frame->allocated_stack /BPF_REG_SIZE ; \ iter++, reg = bpf_get_spilled_reg(iter, frame)) +/* Invoke __expr over regsiters in __vst, setting __state and __reg */ +#define bpf_for_each_reg_in_vstate (__vst, __state, __reg, __expr) \ + ({ \ + struct bpf_verifier_state *___vstate = __vst; \ + int ___i, ___j; \ + for (___i = 0; ___i <= ___vstate->curframe; ___i++) { \ + struct bpf_reg_state *___regs; \ + __state = ___vstate->frame[___i]; \ + ___regs = __state->regs; \ + for (___j = 0; ___j < MAX_BPF_REG; ___j++) { \ + __reg = &___regs[___j]; \ + (void)(__expr); \ + } \ + bpf_for_each_spilled_reg(___j, __state, __reg) { \ + if (!__reg) \ + continue; \ + (void)(__expr); \ + } \ + } \ + }) +/* linked list of verifier states used to prune search */ struct bpf_verifier_state_list {struct bpf_verifier_state state;
include/linux/skmsg.h +2 -1
@@ -96,6 +96,7 @@ struct sk_psock {spinlock_t link_lock;refcount_t refcnt;void (*saved_unhash)(struct sock *sk); +void (*saved_destroy)(struct sock *sk);void (*saved_close)(struct sock *sk,long timeout);void (*saved_write_space)(struct sock *sk);void (*saved_data_ready)(struct sock *sk);
@@ -381,7 +382,7 @@ static inline void sk_psock_report_error(struct sk_psock *psock, int err) }struct sk_psock *sk_psock_init (struct sock *sk,int node); -void sk_psock_stop (struct sk_psock *psock,bool wait); +void sk_psock_stop (struct sk_psock *psock);#if IS_ENABLED (CONFIG_BPF_STREAM_PARSER )int sk_psock_init_strp (struct sock *sk,struct sk_psock *psock);
include/linux/soc/marvell/octeontx2/asm.h +15 -0
@@ -5,6 +5,7 @@#ifndef __SOC_OTX2_ASM_H#define __SOC_OTX2_ASM_H +#include <linux/types.h> #if defined(CONFIG_ARM64 )/* * otx2_lmt_flush is used for LMT store operation.
@@ -34,9 +35,23 @@ : [rf] "+r"(val) \ : [rs] "r"(addr)); \ }) + +static inline u64 otx2_atomic64_fetch_add(u64 incr, u64 *ptr) +{ +u64 result; + + asmvolatile (".cpu generic+lse\n" +"ldadda %x[i], %x[r], [%[b]]" + : [r]"=r" (result),"+m" (*ptr) + : [i]"r" (incr), [b]"r" (ptr) + :"memory" ); +return result; +} +#else #define otx2_lmt_flush (ioaddr) ({ 0; })#define cn10k_lmt_flush (val, addr) ({ addr = val; }) +#define otx2_atomic64_fetch_add (incr, ptr) ({ incr; })#endif #endif /* __SOC_OTX2_ASM_H */
include/uapi/linux/capability.h +1 -1
@@ -426,7 +426,7 @@ struct vfs_ns_cap_data {*/ #define CAP_TO_INDEX (x) ((x) >> 5)/* 1 << 5 == bits in __u32 */ -#define CAP_TO_MASK (x) (1 << ((x) & 31))/* mask for indexed __u32 */ +#define CAP_TO_MASK (x) (1U << ((x) & 31))/* mask for indexed __u32 */ #endif /* _UAPI_LINUX_CAPABILITY_H */
kernel/bpf/verifier.c +39 -109
236 lines not on this page · raw message
mm/damon/dbgfs.c +7 -0
@@ -441,6 +441,7 @@ static ssize_t dbgfs_mk_context_write(struct file *file,static int dbgfs_rm_context (char *name) {struct dentry *root, *dir, **new_dirs; +struct inode *inode;struct damon_ctx **new_ctxs;int i, j;int ret =0 ;
@@ -456,6 +457,12 @@ static int dbgfs_rm_context(char *name)if (!dir)return -ENOENT ; + inode =d_inode (dir); +if (!S_ISDIR (inode->i_mode)) { + ret = -EINVAL ; + goto out_dput; + } + new_dirs =kmalloc_array (dbgfs_nr_ctxs -1 ,sizeof (*dbgfs_dirs),GFP_KERNEL );if (!new_dirs) {
mm/memremap.c +1 -0
@@ -327,6 +327,7 @@ void *memremap_pages(struct dev_pagemap *pgmap, int nid)WARN (1 ,"File system DAX not supported\n" );return ERR_PTR (-EINVAL ); } + params.pgprot =pgprot_decrypted (params.pgprot);break ;case MEMORY_DEVICE_GENERIC :break ;
mm/userfaultfd.c +1 -1
@@ -63,7 +63,7 @@ int mfill_atomic_install_pte(struct mm_struct *dst_mm, pmd_t *dst_pmd,pte_t _dst_pte, *dst_pte;bool writable = dst_vma->vm_flags &VM_WRITE ;bool vm_shared = dst_vma->vm_flags &VM_SHARED ; -bool page_in_cache = page->mapping; +bool page_in_cache =page_mapping (page);spinlock_t *ptl;struct inode *inode;pgoff_t offset, max_off;
net/can/af_can.c +1 -1
@@ -451,7 +451,7 @@ int can_rx_register(struct net *net, struct net_device *dev, canid_t can_id,/* insert new receiver (dev,canid,mask) -> (func,data) */ -if (dev && dev->type !=ARPHRD_CAN ) +if (dev && (dev->type !=ARPHRD_CAN || !can_get_ml_priv (dev)))return -ENODEV ;if (dev && !net_eq (net,dev_net (dev)))
net/can/j1939/main.c +3 -0
@@ -332,6 +332,9 @@ int j1939_send_one(struct j1939_priv *priv, struct sk_buff *skb)/* re-claim the CAN_HDR from the SKB */ cf =skb_push (skb,J1939_CAN_HDR ); +/* initialize header structure */ +memset (cf,0 ,J1939_CAN_HDR ); +/* make it a full can frame again */
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.