Linux 6.9.10
Greg Kroah-Hartman
maintainerI'm announcing the release of the 6.9.10 kernel.
All users of the 6.9 kernel series must upgrade.
The updated 6.9.y git tree can be found at:
git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git linux-6.9.y
and can be browsed at the normal kernel.org git web browser:
https://git.kernel.org/?p=linux/kernel/git/stable/linux-stable.git;a=summary
thanks,
greg k-h
------------
Documentation/admin-guide/cifs/usage.rst | 36 - Documentation/devicetree/bindings/cache/qcom,llcc.yaml | 2 Makefile | 2 arch/arm/mach-davinci/pm.c | 2 arch/arm64/boot/dts/allwinner/sun50i-h64-remix-mini-pc.dts | 2 arch/arm64/boot/dts/qcom/qdu1000.dtsi | 16 arch/arm64/boot/dts/qcom/sa8775p.dtsi | 2 arch/arm64/boot/dts/qcom/sc8180x.dtsi | 11 arch/arm64/boot/dts/qcom/sc8280xp-lenovo-thinkpad-x13s.dts | 15 arch/arm64/boot/dts/qcom/sm6115.dtsi | 1 arch/arm64/boot/dts/qcom/x1e80100-crd.dts | 13 arch/arm64/boot/dts/qcom/x1e80100-qcp.dts | 9 arch/arm64/boot/dts/qcom/x1e80100.dtsi | 10 arch/s390/mm/pgalloc.c | 4 arch/x86/entry/entry_64_compat.S | 14 drivers/acpi/processor_idle.c | 37 - drivers/char/hpet.c | 34 + drivers/cpufreq/acpi-cpufreq.c | 4 drivers/cpufreq/cpufreq.c | 3 drivers/firmware/cirrus/cs_dsp.c | 227 ++++++++---- drivers/i2c/busses/i2c-rcar.c | 27 + drivers/i2c/i2c-core-base.c | 1 drivers/i2c/i2c-slave-testunit.c | 7 drivers/iio/industrialio-trigger.c | 2 drivers/misc/fastrpc.c | 41 +- drivers/misc/mchp_pci1xxxx/mchp_pci1xxxx_otpe2p.c | 4 drivers/misc/mei/platform-vsc.c | 4 drivers/misc/mei/vsc-tp.c | 16 drivers/mmc/host/davinci_mmc.c | 3 drivers/mmc/host/sdhci.c | 15 drivers/net/dsa/lan9303-core.c | 23 - drivers/net/ethernet/broadcom/asp2/bcmasp.c | 1 drivers/net/ethernet/intel/i40e/i40e_adminq.h | 4 drivers/net/ethernet/intel/i40e/i40e_main.c | 9 drivers/net/ethernet/lantiq_etop.c | 4 drivers/net/ethernet/marvell/octeontx2/af/mbox.h | 2 drivers/net/ethernet/marvell/octeontx2/af/npc.h | 8 drivers/net/ethernet/marvell/octeontx2/af/rvu.c | 2 drivers/net/ethernet/marvell/octeontx2/af/rvu_cpt.c | 23 - drivers/net/ethernet/marvell/octeontx2/af/rvu_nix.c | 12 drivers/net/ethernet/mediatek/mtk_star_emac.c | 7 drivers/net/ethernet/micrel/ks8851_common.c | 10 drivers/net/ethernet/micrel/ks8851_spi.c | 4 drivers/net/phy/microchip_t1.c | 2 drivers/net/ppp/ppp_generic.c | 15 drivers/net/wireguard/allowedips.c | 4 drivers/net/wireguard/queueing.h | 4 drivers/net/wireguard/send.c | 2 drivers/nvmem/core.c | 7 drivers/nvmem/meson-efuse.c | 14 drivers/nvmem/rmem.c | 5 drivers/platform/x86/toshiba_acpi.c | 1 drivers/pmdomain/qcom/rpmhpd.c | 7 drivers/spi/spi-axi-spi-engine.c | 26 - drivers/spi/spi-mux.c | 1 drivers/spi/spi.c | 20 - drivers/tty/serial/imx.c | 51 ++ drivers/tty/serial/ma35d1_serial.c | 13 drivers/ufs/core/ufs-mcq.c | 11 drivers/ufs/core/ufshcd.c | 2 drivers/usb/core/config.c | 18 drivers/usb/core/of.c | 7 drivers/usb/core/quirks.c | 3 drivers/usb/dwc3/dwc3-pci.c | 8 drivers/usb/gadget/configfs.c | 3 drivers/usb/host/xhci.c | 16 drivers/usb/serial/mos7840.c | 45 ++ drivers/usb/serial/option.c | 38 ++ drivers/vfio/pci/vfio_pci_core.c | 2 fs/cachefiles/daemon.c | 4 fs/cachefiles/internal.h | 3 fs/cachefiles/ondemand.c | 52 ++ fs/cachefiles/xattr.c | 5 fs/dcache.c | 12 fs/ext4/sysfs.c | 2 fs/locks.c | 2 fs/minix/namei.c | 3 fs/nilfs2/dir.c | 32 + fs/smb/client/cifsglob.h | 4 fs/smb/server/smb2pdu.c | 13 fs/userfaultfd.c | 7 include/linux/mmzone.h | 3 include/linux/pagemap.h | 11 include/linux/spi/spi.h | 4 include/linux/swap.h | 3 include/net/tcx.h | 13 include/uapi/misc/fastrpc.h | 3 kernel/bpf/bpf_local_storage.c | 4 kernel/bpf/helpers.c | 243 +++++++++---- kernel/sched/deadline.c | 7 kernel/sched/fair.c | 12 mm/damon/core.c | 23 + mm/filemap.c | 10 mm/memcontrol.c | 11 mm/migrate.c | 13 mm/readahead.c | 8 mm/shmem.c | 15 mm/vmalloc.c | 10 mm/workingset.c | 14 net/ceph/mon_client.c | 14 net/core/datagram.c | 3 net/core/skmsg.c | 3 net/ethtool/ioctl.c | 3 net/ethtool/linkstate.c | 41 +- net/ipv4/tcp_input.c | 11 net/ipv4/tcp_timer.c | 17 net/ipv4/udp.c | 4 net/netfilter/nf_tables_api.c | 158 -------- net/netfilter/nfnetlink_queue.c | 2 net/sched/act_ct.c | 8 net/sched/sch_ingress.c | 12 net/sunrpc/xprtsock.c | 7 scripts/ld-version.sh | 8 scripts/package/kernel.spec | 1 sound/pci/hda/patch_realtek.c | 4 sound/soc/sof/intel/hda-dai.c | 12 tools/testing/selftests/wireguard/qemu/Makefile | 8 117 files changed, 1272 insertions(+), 588 deletions(-)
Abel Vesa (1):
arm64: dts: qcom: x1e80100: Fix PCIe 6a reg offsets and add MHI
Adrian Hunter (1):
mmc: sdhci: Fix max_seg_size for 64KiB PAGE_SIZE
Alan Stern (1):
USB: core: Fix duplicate endpoint bug by clearing reserved bits in the descriptor
Aleksander Jan Bajkowski (1):
net: ethernet: lantiq_etop: fix double free in detach
Aleksandr Loktionov (1):
i40e: fix: remove needless retries of NVM update
Aleksandr Mishin (1):
octeontx2-af: Fix incorrect value output on error path in rvu_check_rsrc_availability()
Alexandre Chartre (1):
x86/bhi: Avoid warning in #DB handler due to BHI mitigation
Andre Przywara (1):
arm64: dts: allwinner: Fix PMIC interrupt number
Armin Wolf (1):
platform/x86: toshiba_acpi: Fix array out-of-bounds access
Audra Mitchell (1):
Fix userfaultfd_api to return EINVAL as expected
Baokun Li (5):
cachefiles: propagate errors from vfs_getxattr() to avoid infinite loop
cachefiles: stop sending new request when dropping object
cachefiles: cancel all requests for the object that is being dropped
cachefiles: cyclic allocation of msg_id to avoid reuse
ext4: avoid ptr null pointer dereference
Bastien Curutchet (1):
mmc: davinci_mmc: Prevent transmitted data size from exceeding sgm's length
Benjamin Tissoires (2):
bpf: make timer data struct more generic
bpf: replace bpf_timer_init with a generic helper
Bjorn Andersson (1):
arm64: dts: qcom: sc8180x: Fix LLCC reg property again
Bjørn Mork (1):
USB: serial: option: add Fibocom FM350-GL
Brian Foster (1):
vfs: don't mod negative dentry count when on shrinker list
Caleb Connolly (1):
arm64: dts: qcom: sm6115: add iommu for sdhc_1
Chen Ni (1):
ARM: davinci: Convert comma to semicolon
Chengen Du (1):
net/sched: Fix UAF when resolving a clash
Christian Eggers (1):
dsa: lan9303: Fix mapping between DSA port number and PHY address
Cong Zhang (1):
arm64: dts: qcom: sa8775p: Correct IRQ number of EL2 non-secure physical timer
Dan Carpenter (1):
net: bcmasp: Fix error code in probe()
Daniel Borkmann (2):
bpf: Fix too early release of tcx_entry
net, sunrpc: Remap EPERM in case of connection failure in xs_tcp_setup_socket
Daniele Palmas (2):
USB: serial: option: add Telit generic core-dump composition
USB: serial: option: add Telit FN912 rmnet compositions
David Lechner (3):
spi: axi-spi-engine: fix sleep calculation
spi: don't unoptimize message in spi_async()
spi: add defer_optimize_message controller flag
Dmitry Antipov (1):
ppp: reject claimed-as-LCP but actually malformed packets
Dmitry Smirnov (1):
USB: serial: mos7840: fix crash on resume
Edson Juliano Drosdeck (1):
ALSA: hda/realtek: Limit mic boost on VAIO PRO PX
Ekansh Gupta (6):
misc: fastrpc: Fix DSP capabilities request
misc: fastrpc: Avoid updating PD type for capability request
misc: fastrpc: Copy the complete capability structure to user
misc: fastrpc: Fix memory leak in audio daemon attach operation
misc: fastrpc: Fix ownership reassignment of remote heap
misc: fastrpc: Restrict untrusted app to attach to privileged PD
Eric Dumazet (1):
tcp: avoid too many retransmit packets
Florian Westphal (2):
netfilter: nfnetlink_queue: drop bogus WARN_ON
netfilter: nf_tables: prefer nft_chain_validate
Gavin Shan (4):
mm/filemap: skip to create PMD-sized page cache if needed mm/filemap: make MAX_PAGECACHE_ORDER acceptable to xarray mm/readahead: limit page cache size in page_cache_ra_order() mm/shmem: disable PMD-sized page cache if needed
Geliang Tang (1):
skmsg: Skip zero length skb in sk_msg_recvmsg
Greg Kroah-Hartman (1):
Linux 6.9.10
He Zhe (1):
hpet: Support 32-bit userspace
Heikki Krogerus (1):
usb: dwc3: pci: add support for the Intel Panther Lake
Heiko Carstens (1):
s390/mm: Add NULL pointer check to crst_table_free() base_crst_free()
Helge Deller (1):
wireguard: allowedips: avoid unaligned 64-bit memory accesses
Hobin Woo (1):
ksmbd: discard write access to the directory open
Hou Tao (1):
cachefiles: wait for ondemand_object_worker to finish when dropping object
Hugh Dickins (2):
net: fix rc7's __skb_datagram_iter()
mm: fix crashes from deferred split racing folio migration
Ilya Dryomov (1):
libceph: fix race between delayed_work() and ceph_monc_stop()
Jacky Huang (1):
tty: serial: ma35d1: Add a NULL check for of_node
Jason A. Donenfeld (3):
wireguard: selftests: use acpi=off instead of -no-acpi for recent QEMU
wireguard: queueing: annotate intentional data race in cpu round robin
wireguard: send: annotate intentional data race in checking empty queue
Javier Carrasco (1):
usb: core: add missing of_node_put() in usb_of_has_devices_or_graph
Jeff Layton (1):
filelock: fix potential use-after-free in posix_lock_inode
Jian Hui Lee (1):
net: ethernet: mtk-star-emac: set mac_managed_pm when probing
Jingbo Xu (1):
cachefiles: add missing lock protection when polling
Johan Hovold (1):
arm64: dts: qcom: sc8280xp-x13s: fix touchscreen power on
Jose Ignacio Tornos Martinez (1):
kbuild: rpm-pkg: avoid the warnings with dtb's listed twice
Josh Don (1):
Revert "sched/fair: Make sure to try to detach at least one movable task"
Joy Chakraborty (3):
misc: microchip: pci1xxxx: Fix return value of nvmem callbacks
nvmem: rmem: Fix return value of rmem_read()
nvmem: meson-efuse: Fix return value of nvmem callbacks
João Paulo Gonçalves (1):
iio: trigger: Fix condition for own trigger
Kai Vehmanen (1):
ASoC: SOF: Intel: hda: fix null deref on system suspend entry
Kiran Kumar K (1):
octeontx2-af: fix issue with IPv6 ext match for RSS
Komal Bajaj (2):
arm64: dts: qcom: qdu1000: Fix LLCC reg property
Revert "dt-bindings: cache: qcom,llcc: correct QDU1000 reg entries"
Konrad Dybcio (1):
arm64: dts: qcom: x1e80100-*: Allocate some CMA buffers
Krzysztof Kozlowski (2):
arm64: dts: qcom: x1e80100-crd: fix WCD audio codec TX port mapping
arm64: dts: qcom: x1e80100-crd: fix DAI used for headset recording
Kuan-Wei Chiu (1):
ACPI: processor_idle: Fix invalid comparison with insertion sort for latency
Kumar Kartikeya Dwivedi (2):
bpf: Fail bpf_timer_cancel when callback is being cancelled
bpf: Defer work in bpf_timer_cancel_and_free
Kuniyuki Iwashima (1):
udp: Set SOCK_RCU_FREE earlier in udp_lib_get_port().
Lee Jones (1):
usb: gadget: configfs: Prevent OOB read/write in usb_string_copy()
Mank Wang (1):
USB: serial: option: add Netprisma LCUK54 series modules
Mario Limonciello (2):
cpufreq: ACPI: Mark boost policy as enabled when setting boost
cpufreq: Allow drivers to advertise boost enabled
Mathias Nyman (1):
xhci: always resume roothubs if xHC was reset during resume
Matthew Wilcox (Oracle) (1):
minixfs: Fix minixfs_rename with HIGHMEM
Michal Kubiak (1):
i40e: Fix XDP program unloading while removing the driver
Michal Mazur (1):
octeontx2-af: fix detection of IP layer
Michał Kopeć (1):
ALSA: hda/realtek: add quirk for Clevo V5[46]0TU
Mohammad Shehar Yaar Tausif (1):
bpf: fix order of args in call to bpf_map_kvcalloc
Nathan Chancellor (1):
kbuild: Make ld-version.sh more robust against version string changes
Nazar Bilinskyi (1):
ALSA: hda/realtek: Enable Mute LED on HP 250 G7
Neal Cardwell (1):
tcp: fix incorrect undo caused by DSACK of TLP retransmit
Nhat Pham (1):
cachestat: do not flush stats in recency check
Nithin Dabilpuram (1):
octeontx2-af: replace cpt slot with lf id on reg write
Oleksij Rempel (2):
net: phy: microchip: lan87xx: reinit PHY after cable test
ethtool: netlink: do not return SQI value if link is down
Peter Wang (2):
scsi: ufs: core: Fix ufshcd_clear_cmd racing issue
scsi: ufs: core: Fix ufshcd_abort_one racing issue
Rasmus Villemoes (1):
serial: imx: ensure RTS signal is not left active after shutdown
Richard Fitzgerald (5):
firmware: cs_dsp: Fix overflow checking of wmfw header
firmware: cs_dsp: Return error if block header overflows file
firmware: cs_dsp: Validate payload length before processing block
firmware: cs_dsp: Prevent buffer overrun when processing V2 alg headers
firmware: cs_dsp: Use strnlen() on name fields in V1 wmfw files
Ronald Wahl (2):
net: ks8851: Fix deadlock with the SPI chip variant
net: ks8851: Fix potential TX stall after interface reopen
Ryusuke Konishi (1):
nilfs2: fix kernel bug on rename operation of broken directory
Saeed Mahameed (1):
net: ethtool: Fix RSS setting
Satheesh Paul (1):
octeontx2-af: fix issue with IPv4 match for RSS
SeongJae Park (1):
mm/damon/core: merge regions aggressively when max_nr_regions is unmet
Slark Xiao (1):
USB: serial: option: add support for Foxconn T99W651
Srujana Challa (1):
octeontx2-af: fix a issue with cpt_lf_alloc mailbox
Steve French (1):
cifs: fix setting SecurityFlags to true
Taniya Das (1):
pmdomain: qcom: rpmhpd: Skip retention level for Power Domains
Thomas Weißschuh (2):
nvmem: core: only change name to fram for current attribute
nvmem: core: limit cell sysfs permissions to main attribute ones
Uladzislau Rezki (Sony) (1):
mm: vmalloc: check if a hash-index is in cpu_possible_mask
Vanillan Wang (1):
USB: serial: option: add Rolling RW350-GL variants
Waiman Long (1):
mm: prevent derefencing NULL ptr in pfn_section_valid()
Wander Lairson Costa (1):
sched/deadline: Fix task_struct reference leak
WangYuli (1):
USB: Add USB_QUIRK_NO_SET_INTF quirk for START BP-850k
Wentong Wu (3):
mei: vsc: Enhance IVSC chipset stability during warm reboot
mei: vsc: Prevent timeout error with added delay post-firmware download
mei: vsc: Utilize the appropriate byte order swap function
Wolfram Sang (5):
i2c: rcar: bring hardware to known state when probing
i2c: rcar: clear NO_RXDMA flag after resetting
i2c: mark HostNotify target address as used
i2c: rcar: ensure Gen3+ reset does not disturb local targets
i2c: testunit: avoid re-issued work after read message
Yi Liu (1):
vfio/pci: Init the count variable in collecting hot-reset devices
ZhangPeng (1):
filemap: replace pte_offset_map() with pte_offset_map_nolock()
linke li (1):
fs/dcache: Re-use value stored to dentry->d_flags instead of re-reading
Greg Kroah-Hartman
maintainerDocumentation/admin-guide/cifs/usage.rst +11 -25
@@ -723,40 +723,26 @@ Configuration pseudo-files: ======================= ======================================================= SecurityFlags Flags which control security negotiation and also packet signing. Authentication (may/must) - flags (e.g. for NTLM and/or NTLMv2) may be combined with + flags (e.g. for NTLMv2) may be combined with the signing flags. Specifying two different password hashing mechanisms (as "must use") on the other hand does not make much sense. Default flags are:: - 0x07007 - - (NTLM, NTLMv2 and packet signing allowed). The maximum - allowable flags if you want to allow mounts to servers - using weaker password hashes is 0x37037 (lanman, - plaintext, ntlm, ntlmv2, signing allowed). Some - SecurityFlags require the corresponding menuconfig - options to be enabled. Enabling plaintext - authentication currently requires also enabling - lanman authentication in the security flags - because the cifs module only supports sending - laintext passwords using the older lanman dialect - form of the session setup SMB. (e.g. for authentication - using plain text passwords, set the SecurityFlags - to 0x30030):: + 0x00C5 + + (NTLMv2 and packet signing allowed). Some SecurityFlags + may require enabling a corresponding menuconfig option. may use packet signing 0x00001 must use packet signing 0x01001 - may use NTLM (most common password hash) 0x00002 - must use NTLM 0x02002 may use NTLMv2 0x00004 must use NTLMv2 0x04004 - may use Kerberos security 0x00008 - must use Kerberos 0x08008 - may use lanman (weak) password hash 0x00010 - must use lanman password hash 0x10010 - may use plaintext passwords 0x00020 - must use plaintext passwords 0x20020 - (reserved for future packet encryption) 0x00040 + may use Kerberos security (krb5) 0x00008 + must use Kerberos 0x08008 + may use NTLMSSP 0x00080 + must use NTLMSSP 0x80080 + seal (packet encryption) 0x00040 + must seal (not implemented yet) 0x40040 cifsFYI If set to non-zero value, additional debug information will be logged to the system error log. This field
Documentation/devicetree/bindings/cache/qcom,llcc.yaml +1 -1
@@ -66,7 +66,6 @@ allOf: compatible: contains: enum: - - qcom,qdu1000-llcc - qcom,sc7180-llcc - qcom,sm6350-llcc then:
@@ -104,6 +103,7 @@ allOf: compatible: contains: enum: + - qcom,qdu1000-llcc - qcom,sc8180x-llcc - qcom,sc8280xp-llcc - qcom,x1e80100-llcc
Makefile +1 -1
@@ -1,7 +1,7 @@ # SPDX-License-Identifier: GPL-2.0 VERSION = 6 PATCHLEVEL = 9 -SUBLEVEL = 9 +SUBLEVEL = 10 EXTRAVERSION = NAME = Hurr durr I'ma ninja sloth
arch/arm/mach-davinci/pm.c +1 -1
@@ -61,7 +61,7 @@ static void davinci_pm_suspend(void)/* Configure sleep count in deep sleep register */ val =__raw_readl (pm_config.deepsleep_reg); - val &= ~DEEPSLEEP_SLEEPCOUNT_MASK , + val &= ~DEEPSLEEP_SLEEPCOUNT_MASK ; val |= pm_config.sleepcount;__raw_writel (val, pm_config.deepsleep_reg);
arch/arm64/boot/dts/allwinner/sun50i-h64-remix-mini-pc.dts +1 -1
@@ -191,7 +191,7 @@ axp803: pmic@3a3 { compatible = "x-powers,axp803"; reg = <0x3a3>; interrupt-parent = <&r_intc>; - interrupts = <GIC_SPI 0 IRQ_TYPE_LEVEL_LOW>; + interrupts = <GIC_SPI 32 IRQ_TYPE_LEVEL_LOW>; x-powers,drive-vbus-en; vin1-supply = <®_vcc5v>;
arch/arm64/boot/dts/qcom/qdu1000.dtsi +15 -1
@@ -1459,9 +1459,23 @@ gem_noc: interconnect@19100000 { system-cache-controller@19200000 { compatible = "qcom,qdu1000-llcc"; - reg = <0 0x19200000 0 0xd80000>, + reg = <0 0x19200000 0 0x80000>, + <0 0x19300000 0 0x80000>, + <0 0x19600000 0 0x80000>, + <0 0x19700000 0 0x80000>, + <0 0x19a00000 0 0x80000>, + <0 0x19b00000 0 0x80000>, + <0 0x19e00000 0 0x80000>, + <0 0x19f00000 0 0x80000>, <0 0x1a200000 0 0x80000>; reg-names = "llcc0_base", + "llcc1_base", + "llcc2_base", + "llcc3_base", + "llcc4_base", + "llcc5_base", + "llcc6_base", + "llcc7_base", "llcc_broadcast_base"; interrupts = <GIC_SPI 266 IRQ_TYPE_LEVEL_HIGH>; };
arch/arm64/boot/dts/qcom/sa8775p.dtsi +1 -1
@@ -3605,7 +3605,7 @@ arch_timer: timer { interrupts = <GIC_PPI 13 (GIC_CPU_MASK_SIMPLE(8) | IRQ_TYPE_LEVEL_LOW)>, <GIC_PPI 14 (GIC_CPU_MASK_SIMPLE(8) | IRQ_TYPE_LEVEL_LOW)>, <GIC_PPI 11 (GIC_CPU_MASK_SIMPLE(8) | IRQ_TYPE_LEVEL_LOW)>, - <GIC_PPI 12 (GIC_CPU_MASK_SIMPLE(8) | IRQ_TYPE_LEVEL_LOW)>; + <GIC_PPI 10 (GIC_CPU_MASK_SIMPLE(8) | IRQ_TYPE_LEVEL_LOW)>; }; pcie0: pcie@1c00000 {
arch/arm64/boot/dts/qcom/sc8180x.dtsi +7 -4
@@ -2608,11 +2608,14 @@ usb_sec_dpphy: dp-phy@88ef200 { system-cache-controller@9200000 { compatible = "qcom,sc8180x-llcc"; - reg = <0 0x09200000 0 0x50000>, <0 0x09280000 0 0x50000>, - <0 0x09300000 0 0x50000>, <0 0x09380000 0 0x50000>, - <0 0x09600000 0 0x50000>; + reg = <0 0x09200000 0 0x58000>, <0 0x09280000 0 0x58000>, + <0 0x09300000 0 0x58000>, <0 0x09380000 0 0x58000>, + <0 0x09400000 0 0x58000>, <0 0x09480000 0 0x58000>, + <0 0x09500000 0 0x58000>, <0 0x09580000 0 0x58000>, + <0 0x09600000 0 0x58000>; reg-names = "llcc0_base", "llcc1_base", "llcc2_base", - "llcc3_base", "llcc_broadcast_base"; + "llcc3_base", "llcc4_base", "llcc5_base", + "llcc6_base", "llcc7_base", "llcc_broadcast_base"; interrupts = <GIC_SPI 582 IRQ_TYPE_LEVEL_HIGH>; };
arch/arm64/boot/dts/qcom/sc8280xp-lenovo-thinkpad-x13s.dts +8 -7
@@ -618,15 +618,16 @@ &i2c4 { status = "okay"; - /* FIXME: verify */ touchscreen@10 { - compatible = "hid-over-i2c"; + compatible = "elan,ekth5015m", "elan,ekth6915"; reg = <0x10>; - hid-descr-addr = <0x1>; interrupts-extended = <&tlmm 175 IRQ_TYPE_LEVEL_LOW>; - vdd-supply = <&vreg_misc_3p3>; - vddl-supply = <&vreg_s10b>; + reset-gpios = <&tlmm 99 (GPIO_ACTIVE_LOW | GPIO_OPEN_DRAIN)>; + no-reset-on-power-off; + + vcc33-supply = <&vreg_misc_3p3>; + vccio-supply = <&vreg_misc_3p3>; pinctrl-names = "default"; pinctrl-0 = <&ts0_default>;
@@ -1417,8 +1418,8 @@ int-n-pins { reset-n-pins { pins = "gpio99"; function = "gpio"; - output-high; - drive-strength = <16>; + drive-strength = <2>; + bias-disable; }; };
arch/arm64/boot/dts/qcom/sm6115.dtsi +1 -0
@@ -1090,6 +1090,7 @@ sdhc_1: mmc@4744000 { power-domains = <&rpmpd SM6115_VDDCX>; operating-points-v2 = <&sdhc1_opp_table>; + iommus = <&apps_smmu 0x00c0 0x0>; interconnects = <&system_noc MASTER_SDCC_1 RPM_ALWAYS_TAG &bimc SLAVE_EBI_CH0 RPM_ALWAYS_TAG>, <&bimc MASTER_AMPSS_M0 RPM_ALWAYS_TAG
arch/arm64/boot/dts/qcom/x1e80100-crd.dts +11 -2
@@ -48,6 +48,15 @@ chosen { stdout-path = "serial0:115200n8"; }; + reserved-memory { + linux,cma { + compatible = "shared-dma-pool"; + size = <0x0 0x8000000>; + reusable; + linux,cma-default; + }; + }; + sound { compatible = "qcom,x1e80100-sndcard"; model = "X1E80100-CRD";
@@ -92,7 +101,7 @@ cpu { }; codec { - sound-dai = <&wcd938x 1>, <&swr2 0>, <&lpass_txmacro 0>; + sound-dai = <&wcd938x 1>, <&swr2 1>, <&lpass_txmacro 0>; }; platform {
@@ -727,7 +736,7 @@ &swr2 { wcd_tx: codec@0,3 { compatible = "sdw20217010d00"; reg = <0 3>; - qcom,tx-port-mapping = <1 1 2 3>; + qcom,tx-port-mapping = <2 2 3 4>; }; };
arch/arm64/boot/dts/qcom/x1e80100-qcp.dts +9 -0
@@ -22,6 +22,15 @@ chosen { stdout-path = "serial0:115200n8"; }; + reserved-memory { + linux,cma { + compatible = "shared-dma-pool"; + size = <0x0 0x8000000>; + reusable; + linux,cma-default; + }; + }; + vph_pwr: vph-pwr-regulator { compatible = "regulator-fixed";
arch/arm64/boot/dts/qcom/x1e80100.dtsi +6 -4
@@ -2737,15 +2737,17 @@ pcie6a: pci@1bf8000 { device_type = "pci"; compatible = "qcom,pcie-x1e80100"; reg = <0 0x01bf8000 0 0x3000>, - <0 0x70000000 0 0xf1d>, - <0 0x70000f20 0 0xa8>, + <0 0x70000000 0 0xf20>, + <0 0x70000f40 0 0xa8>, <0 0x70001000 0 0x1000>, - <0 0x70100000 0 0x100000>; + <0 0x70100000 0 0x100000>, + <0 0x01bfb000 0 0x1000>; reg-names = "parf", "dbi", "elbi", "atu", - "config"; + "config", + "mhi"; #address-cells = <3>; #size-cells = <2>; ranges = <0x01000000 0 0x00000000 0 0x70200000 0 0x100000>,
arch/s390/mm/pgalloc.c +4 -0
@@ -55,6 +55,8 @@ unsigned long *crst_table_alloc(struct mm_struct *mm)void crst_table_free (struct mm_struct *mm,unsigned long *table) { +if (!table) +return ;pagetable_free (virt_to_ptdesc (table)); }
@@ -262,6 +264,8 @@ static unsigned long *base_crst_alloc(unsigned long val)static void base_crst_free (unsigned long *table) { +if (!table) +return ;pagetable_free (virt_to_ptdesc (table)); }
arch/x86/entry/entry_64_compat.S +10 -4
@@ -90,10 +90,6 @@ SYM_INNER_LABEL(entry_SYSENTER_compat_after_hwframe, SYM_L_GLOBAL) cld - IBRS_ENTER - UNTRAIN_RET - CLEAR_BRANCH_HISTORY - /* * SYSENTER doesn't filter flags, so we need to clear NT and AC * ourselves. To save a few cycles, we can check whether
@@ -117,6 +113,16 @@ SYM_INNER_LABEL(entry_SYSENTER_compat_after_hwframe, SYM_L_GLOBAL) jnz .Lsysenter_fix_flags .Lsysenter_flags_fixed: + /* + * CPU bugs mitigations mechanisms can call other functions. They + * should be invoked after making sure TF is cleared because + * single-step is ignored only for instructions inside the + * entry_SYSENTER_compat function. + */ + IBRS_ENTER + UNTRAIN_RET + CLEAR_BRANCH_HISTORY + movq %rsp, %rdi call do_SYSENTER_32 jmp sysret32_from_system_call
drivers/acpi/processor_idle.c +16 -21
@@ -16,7 +16,6 @@#include <linux/acpi.h> #include <linux/dmi.h> #include <linux/sched.h> /* need_resched() */ -#include <linux/sort.h> #include <linux/tick.h> #include <linux/cpuidle.h> #include <linux/cpu.h>
@@ -386,25 +385,24 @@ static void acpi_processor_power_verify_c3(struct acpi_processor *pr,acpi_write_bit_register (ACPI_BITREG_BUS_MASTER_RLD ,1 ); } -static int acpi_cst_latency_cmp (const void *a,const void *b) +static void acpi_cst_latency_sort (struct acpi_processor_cx *states,size_t length) { -const struct acpi_processor_cx *x = a, *y = b; +int i, j, k; -if (!(x->valid && y->valid)) -return 0 ; -if (x->latency > y->latency) -return 1 ; -if (x->latency < y->latency) -return -1 ; -return 0 ; -} -static void acpi_cst_latency_swap (void *a,void *b,int n) -{ -struct acpi_processor_cx *x = a, *y = b; +for (i =1 ; i < length; i++) { +if (!states[i].valid) +continue ; -if (!(x->valid && y->valid)) -return ; -swap (x->latency, y->latency); +for (j = i -1 , k = i; j >=0 ; j--) { +if (!states[j].valid) +continue ; + +if (states[j].latency > states[k].latency) +swap (states[j].latency, states[k].latency); + + k = j; + } + } }static int acpi_processor_power_verify (struct acpi_processor *pr)
@@ -449,10 +447,7 @@ static int acpi_processor_power_verify(struct acpi_processor *pr)if (buggy_latency) {pr_notice ("FW issue: working around C-state latencies out of order\n" ); -sort (&pr->power.states[1 ], max_cstate, -sizeof (struct acpi_processor_cx ), - acpi_cst_latency_cmp, - acpi_cst_latency_swap); +acpi_cst_latency_sort (&pr->power.states[1 ], max_cstate); }lapic_timer_propagate_broadcast (pr);
drivers/char/hpet.c +29 -5
@@ -269,8 +269,13 @@ hpet_read(struct file *file, char __user *buf, size_t count, loff_t * ppos)if (!devp->hd_ireqfreq)return -EIO ; -if (count <sizeof (unsigned long )) -return -EINVAL ; +if (in_compat_syscall ()) { +if (count <sizeof (compat_ulong_t)) +return -EINVAL ; + }else { +if (count <sizeof (unsigned long )) +return -EINVAL ; + }add_wait_queue (&devp->hd_waitqueue, &wait);
@@ -294,9 +299,16 @@ hpet_read(struct file *file, char __user *buf, size_t count, loff_t * ppos)schedule (); } - retval =put_user (data, (unsigned long __user *)buf); -if (!retval) - retval =sizeof (unsigned long ); +if (in_compat_syscall ()) { + retval =put_user (data, (compat_ulong_t __user *)buf); +if (!retval) + retval =sizeof (compat_ulong_t); + }else { + retval =put_user (data, (unsigned long __user *)buf); +if (!retval) + retval =sizeof (unsigned long ); + } + out:__set_current_state (TASK_RUNNING );remove_wait_queue (&devp->hd_waitqueue, &wait);
@@ -651,12 +663,24 @@ struct compat_hpet_info {unsigned short hi_timer; }; +/* 32-bit types would lead to different command codes which should be +* translated into 64-bit ones before passed to hpet_ioctl_common +*/ +#define COMPAT_HPET_INFO _IOR('h', 0x03, struct compat_hpet_info) +#define COMPAT_HPET_IRQFREQ _IOW('h', 0x6, compat_ulong_t) +static long hpet_compat_ioctl (struct file *file,unsigned int cmd,unsigned long arg) {struct hpet_info info;int err; +if (cmd ==COMPAT_HPET_INFO ) + cmd =HPET_INFO ; + +if (cmd ==COMPAT_HPET_IRQFREQ ) + cmd =HPET_IRQFREQ ; +mutex_lock (&hpet_mutex); err =hpet_ioctl_common (file->private_data, cmd, arg, &info);mutex_unlock (&hpet_mutex);
drivers/cpufreq/acpi-cpufreq.c +3 -1
@@ -890,8 +890,10 @@ static int acpi_cpufreq_cpu_init(struct cpufreq_policy *policy)if (perf->states[0 ].core_frequency *1000 != freq_table[0 ].frequency)pr_warn (FW_WARN "P-state 0 is not max freq\n" ); -if (acpi_cpufreq_driver.set_boost) +if (acpi_cpufreq_driver.set_boost) {set_boost (policy, acpi_cpufreq_driver.boost_enabled); + policy->boost_enabled = acpi_cpufreq_driver.boost_enabled; + }return result;
drivers/cpufreq/cpufreq.c +2 -1
@@ -1431,7 +1431,8 @@ static int cpufreq_online(unsigned int cpu) }/* Let the per-policy boost flag mirror the cpufreq_driver boost during init */ - policy->boost_enabled =cpufreq_boost_enabled () &&policy_has_boost_freq (policy); +if (cpufreq_boost_enabled () &&policy_has_boost_freq (policy)) + policy->boost_enabled = true;/* * The initialization has succeeded and the policy is online.
drivers/firmware/cirrus/cs_dsp.c +162 -65
376 lines not on this page · raw message
drivers/i2c/busses/i2c-rcar.c +21 -6
@@ -257,6 +257,14 @@ static void rcar_i2c_init(struct rcar_i2c_priv *priv) } } +static void rcar_i2c_reset_slave (struct rcar_i2c_priv *priv) +{ +rcar_i2c_write (priv,ICSIER ,0 ); +rcar_i2c_write (priv,ICSSR ,0 ); +rcar_i2c_write (priv,ICSCR ,SDBS ); +rcar_i2c_write (priv,ICSAR ,0 );/* Gen2: must be 0 if not using slave */ +} +static int rcar_i2c_bus_barrier (struct rcar_i2c_priv *priv) {int ret;
@@ -875,6 +883,10 @@ static int rcar_i2c_do_reset(struct rcar_i2c_priv *priv) {int ret; +/* Don't reset if a slave instance is currently running */ +if (priv->slave) +return -EISCONN ; + ret =reset_control_reset (priv->rstc);if (ret)return ret;
@@ -903,10 +915,10 @@ static int rcar_i2c_master_xfer(struct i2c_adapter *adap,/* Gen3+ needs a reset. That also allows RXDMA once */ if (priv->devtype >=I2C_RCAR_GEN3 ) { - priv->flags &= ~ID_P_NO_RXDMA ; ret =rcar_i2c_do_reset (priv);if (ret) goto out; + priv->flags &= ~ID_P_NO_RXDMA ; }rcar_i2c_init (priv);
@@ -1033,11 +1045,8 @@ static int rcar_unreg_slave(struct i2c_client *slave)/* ensure no irq is running before clearing ptr */ disable_irq (priv->irq); -rcar_i2c_write (priv,ICSIER ,0 ); -rcar_i2c_write (priv,ICSSR ,0 ); +rcar_i2c_reset_slave (priv);enable_irq (priv->irq); -rcar_i2c_write (priv,ICSCR ,SDBS ); -rcar_i2c_write (priv,ICSAR ,0 );/* Gen2: must be 0 if not using slave */ priv->slave =NULL ;
@@ -1152,7 +1161,9 @@ static int rcar_i2c_probe(struct platform_device *pdev) goto out_pm_disable; } -rcar_i2c_write (priv,ICSAR ,0 );/* Gen2: must be 0 if not using slave */ +/* Bring hardware to known state */ +rcar_i2c_init (priv); +rcar_i2c_reset_slave (priv);if (priv->devtype <I2C_RCAR_GEN3 ) { irqflags |=IRQF_NO_THREAD ;
@@ -1168,6 +1179,7 @@ static int rcar_i2c_probe(struct platform_device *pdev)if (of_property_read_bool (dev->of_node,"smbus" )) priv->flags |=ID_P_HOST_NOTIFY ; +/* R-Car Gen3+ needs a reset before every transfer */ if (priv->devtype >=I2C_RCAR_GEN3 ) { priv->rstc =devm_reset_control_get_exclusive (&pdev->dev,NULL );if (IS_ERR (priv->rstc)) {
@@ -1178,6 +1190,9 @@ static int rcar_i2c_probe(struct platform_device *pdev) ret =reset_control_status (priv->rstc);if (ret <0 ) goto out_pm_put; + +/* hard reset disturbs HostNotify local target, so disable it */ + priv->flags &= ~ID_P_HOST_NOTIFY ; } ret =platform_get_irq (pdev,0 );
drivers/i2c/i2c-core-base.c +1 -0
@@ -1067,6 +1067,7 @@ EXPORT_SYMBOL(i2c_find_device_by_fwnode);static const struct i2c_device_id dummy_id[] = { {"dummy" ,0 }, + {"smbus_host_notify" ,0 }, { }, };
drivers/i2c/i2c-slave-testunit.c +7 -0
@@ -118,6 +118,13 @@ static int i2c_slave_testunit_slave_cb(struct i2c_client *client,queue_delayed_work (system_long_wq, &tu->worker,msecs_to_jiffies (10 * tu->regs[TU_REG_DELAY ])); } + +/* +* Reset reg_idx to avoid that work gets queued again in case of +* STOP after a following read message. But do not clear TU regs +* here because we still need them in the workqueue! +*/ + tu->reg_idx =0 ;break ;case I2C_SLAVE_WRITE_REQUESTED :
drivers/iio/industrialio-trigger.c +1 -1
@@ -322,7 +322,7 @@ int iio_trigger_attach_poll_func(struct iio_trigger *trig,* this is the case if the IIO device and the trigger device share the * same parent device. */ -if (iio_validate_own_trigger (pf->indio_dev, trig)) +if (!iio_validate_own_trigger (pf->indio_dev, trig)) trig->attached_own_device = true;return ret;
drivers/misc/fastrpc.c +32 -9
103 lines not on this page · raw message
drivers/misc/mchp_pci1xxxx/mchp_pci1xxxx_otpe2p.c +0 -4
@@ -153,7 +153,6 @@ static int pci1xxxx_eeprom_read(void *priv_t, unsigned int off, buf[byte] =readl (rb +MMAP_EEPROM_OFFSET (EEPROM_DATA_REG )); } - ret = byte; error:release_sys_lock (priv);return ret;
@@ -197,7 +196,6 @@ static int pci1xxxx_eeprom_write(void *priv_t, unsigned int off, goto error; } } - ret = byte; error:release_sys_lock (priv);return ret;
@@ -258,7 +256,6 @@ static int pci1xxxx_otp_read(void *priv_t, unsigned int off, buf[byte] =readl (rb +MMAP_OTP_OFFSET (OTP_RD_DATA_OFFSET )); } - ret = byte; error:release_sys_lock (priv);return ret;
@@ -315,7 +312,6 @@ static int pci1xxxx_otp_write(void *priv_t, unsigned int off, goto error; } } - ret = byte; error:release_sys_lock (priv);return ret;
drivers/misc/mei/platform-vsc.c +2 -2
@@ -28,8 +28,8 @@#define MEI_VSC_MAX_MSG_SIZE 512 -#define MEI_VSC_POLL_DELAY_US (50 * USEC_PER_MSEC) -#define MEI_VSC_POLL_TIMEOUT_US (200 * USEC_PER_MSEC) +#define MEI_VSC_POLL_DELAY_US (100 * USEC_PER_MSEC) +#define MEI_VSC_POLL_TIMEOUT_US (400 * USEC_PER_MSEC)#define mei_dev_to_vsc_hw (dev) ((struct mei_vsc_hw *)((dev)->hw))
drivers/misc/mei/vsc-tp.c +15 -1
@@ -336,7 +336,7 @@ int vsc_tp_rom_xfer(struct vsc_tp *tp, const void *obuf, void *ibuf, size_t len)return ret;if (ibuf) -cpu_to_be32_array (ibuf, tp->rx_buf, words); +be32_to_cpu_array (ibuf, tp->rx_buf, words);return ret; }
@@ -568,6 +568,19 @@ static void vsc_tp_remove(struct spi_device *spi)free_irq (spi->irq, tp); } +static void vsc_tp_shutdown (struct spi_device *spi) +{ +struct vsc_tp *tp =spi_get_drvdata (spi); + +platform_device_unregister (tp->pdev); + +mutex_destroy (&tp->mutex); + +vsc_tp_reset (tp); + +free_irq (spi->irq, tp); +} +static const struct acpi_device_id vsc_tp_acpi_ids[] = { {"INTC1009" },/* Raptor Lake */ {"INTC1058" },/* Tiger Lake */
@@ -580,6 +593,7 @@ MODULE_DEVICE_TABLE(acpi, vsc_tp_acpi_ids);static struct spi_driver vsc_tp_driver = { .probe = vsc_tp_probe, .remove = vsc_tp_remove, + .shutdown = vsc_tp_shutdown, .driver = { .name ="vsc-tp" , .acpi_match_table = vsc_tp_acpi_ids,
drivers/mmc/host/davinci_mmc.c +3 -0
@@ -224,6 +224,9 @@ static void davinci_fifo_data_trans(struct mmc_davinci_host *host, } p = sgm->addr; +if (n > sgm->length) + n = sgm->length; +/* NOTE: we never transfer more than rw_threshold bytes * to/from the fifo here; there's no I/O overlap. * This also assumes that access width( i.e. ACCWD) is 4 bytes
drivers/mmc/host/sdhci.c +15 -0
@@ -4727,6 +4727,21 @@ int sdhci_setup_host(struct sdhci_host *host)if (host->quirks &SDHCI_QUIRK_BROKEN_ADMA_ZEROLEN_DESC ) { host->max_adma =65532 ;/* 32-bit alignment */ mmc->max_seg_size =65535 ; +/* +* sdhci_adma_table_pre() expects to define 1 DMA +* descriptor per segment, so the maximum segment size +* is set accordingly. SDHCI allows up to 64KiB per DMA +* descriptor (16-bit field), but some controllers do +* not support "zero means 65536" reducing the maximum +* for them to 65535. That is a problem if PAGE_SIZE is +* 64KiB because the block layer does not support +* max_seg_size < PAGE_SIZE, however +* sdhci_adma_table_pre() has a workaround to handle +* that case, and split the descriptor. Refer also +* comment in sdhci_adma_table_pre(). +*/ +if (mmc->max_seg_size <PAGE_SIZE ) + mmc->max_seg_size =PAGE_SIZE ; }else { mmc->max_seg_size =65536 ; }
drivers/net/dsa/lan9303-core.c +10 -13
@@ -1048,31 +1048,31 @@ static int lan9303_get_sset_count(struct dsa_switch *ds, int port, int sset)return ARRAY_SIZE (lan9303_mib); } -static int lan9303_phy_read (struct dsa_switch *ds,int phy,int regnum) +static int lan9303_phy_read (struct dsa_switch *ds,int port,int regnum) {struct lan9303 *chip = ds->priv;int phy_base = chip->phy_addr_base; -if (phy == phy_base) +if (port ==0 )return lan9303_virt_phy_reg_read (chip, regnum); -if (phy > phy_base +2 ) +if (port >2 )return -ENODEV ; -return chip->ops->phy_read (chip, phy, regnum); +return chip->ops->phy_read (chip, phy_base + port, regnum); } -static int lan9303_phy_write (struct dsa_switch *ds,int phy,int regnum, +static int lan9303_phy_write (struct dsa_switch *ds,int port,int regnum,u16 val) {struct lan9303 *chip = ds->priv;int phy_base = chip->phy_addr_base; -if (phy == phy_base) +if (port ==0 )return lan9303_virt_phy_reg_write (chip, regnum, val); -if (phy > phy_base +2 ) +if (port >2 )return -ENODEV ; -return chip->ops->phy_write (chip, phy, regnum, val); +return chip->ops->phy_write (chip, phy_base + port, regnum, val); } static int lan9303_port_enable(struct dsa_switch *ds, int port,
@@ -1100,7 +1100,7 @@ static void lan9303_port_disable(struct dsa_switch *ds, int port)vlan_vid_del (dsa_port_to_conduit (dp),htons (ETH_P_8021Q ), port);lan9303_disable_processing_port (chip, port); -lan9303_phy_write (ds, chip->phy_addr_base + port,MII_BMCR ,BMCR_PDOWN ); +lan9303_phy_write (ds, port,MII_BMCR ,BMCR_PDOWN ); } static int lan9303_port_bridge_join(struct dsa_switch *ds, int port,
@@ -1355,8 +1355,6 @@ static const struct dsa_switch_ops lan9303_switch_ops = {static int lan9303_register_switch (struct lan9303 *chip) { -int base; - chip->ds =devm_kzalloc (chip->dev,sizeof (*chip->ds),GFP_KERNEL );if (!chip->ds)return -ENOMEM ;
@@ -1365,8 +1363,7 @@ static int lan9303_register_switch(struct lan9303 *chip) chip->ds->num_ports =LAN9303_NUM_PORTS ; chip->ds->priv = chip; chip->ds->ops = &lan9303_switch_ops; - base = chip->phy_addr_base; - chip->ds->phys_mii_mask =GENMASK (LAN9303_NUM_PORTS -1 + base, base); + chip->ds->phys_mii_mask =GENMASK (LAN9303_NUM_PORTS -1 ,0 );return dsa_register_switch (chip->ds); }
drivers/net/ethernet/broadcom/asp2/bcmasp.c +1 -0
@@ -1380,6 +1380,7 @@ static int bcmasp_probe(struct platform_device *pdev)dev_err (dev,"Cannot create eth interface %d\n" , i);bcmasp_remove_intfs (priv);of_node_put (intf_node); + ret = -ENOMEM ; goto of_put_exit; }list_add_tail (&intf->list, &priv->intfs);
drivers/net/ethernet/intel/i40e/i40e_adminq.h +0 -4
@@ -109,10 +109,6 @@ static inline int i40e_aq_rc_to_posix(int aq_ret, int aq_rc) -EFBIG, /* I40E_AQ_RC_EFBIG */ }; -/* aq_rc is invalid if AQ timed out */ -if (aq_ret == -EIO ) -return -EAGAIN ; -if (!((u32 )aq_rc < (sizeof (aq_to_posix) /sizeof ((aq_to_posix)[0 ]))))return -ERANGE ;
drivers/net/ethernet/intel/i40e/i40e_main.c +4 -5
@@ -13264,6 +13264,10 @@ static int i40e_xdp_setup(struct i40e_vsi *vsi, struct bpf_prog *prog,bool need_reset;int i; +/* VSI shall be deleted in a moment, block loading new programs */ +if (prog &&test_bit (__I40E_IN_REMOVE, pf->state)) +return -EINVAL ; +/* Don't allow frames that span over multiple buffers */ if (vsi->netdev->mtu > frame_size -I40E_PACKET_HDR_PAD ) {NL_SET_ERR_MSG_MOD (extack,"MTU too large for linear frames and XDP prog does not support frags" );
@@ -13272,14 +13276,9 @@ static int i40e_xdp_setup(struct i40e_vsi *vsi, struct bpf_prog *prog,/* When turning XDP on->off/off->on we reset and rebuild the rings. */ need_reset = (i40e_enabled_xdp_vsi (vsi) != !!prog); -if (need_reset)i40e_prep_for_reset (pf); -/* VSI shall be deleted in a moment, just return EINVAL */ -if (test_bit (__I40E_IN_REMOVE, pf->state)) -return -EINVAL ; - old_prog =xchg (&vsi->xdp_prog, prog);if (need_reset) {
drivers/net/ethernet/lantiq_etop.c +2 -2
@@ -217,9 +217,9 @@ ltq_etop_free_channel(struct net_device *dev, struct ltq_etop_chan *ch)if (ch->dma.irq)free_irq (ch->dma.irq, priv);if (IS_RX (ch->idx)) { -int desc; +struct ltq_dma_channel *dma = &ch->dma; -for (desc =0 ; desc <LTQ_DESC_NUM ; desc++) +for (dma->desc =0 ; dma->desc <LTQ_DESC_NUM ; dma->desc++)dev_kfree_skb_any (ch->skb[ch->dma.desc]); } }
drivers/net/ethernet/marvell/octeontx2/af/mbox.h +1 -1
@@ -1746,7 +1746,7 @@ struct cpt_lf_alloc_req_msg {u16 nix_pf_func;u16 sso_pf_func;u16 eng_grpmsk; -int blkaddr; +u8 blkaddr; u8 ctx_ilen_valid : 1; u8 ctx_ilen : 7; };
drivers/net/ethernet/marvell/octeontx2/af/npc.h +6 -2
@@ -63,8 +63,13 @@ enum npc_kpu_lb_ltype { NPC_LT_LB_CUSTOM1 = 0xF, }; +/* Don't modify ltypes up to IP6_EXT, otherwise length and checksum of IP +* headers may not be checked correctly. IPv4 ltypes and IPv6 ltypes must +* differ only at bit 0 so mask 0xE can be used to detect extended headers. +*/ enum npc_kpu_lc_ltype { -NPC_LT_LC_IP =1 , +NPC_LT_LC_PTP =1 , +NPC_LT_LC_IP ,NPC_LT_LC_IP_OPT ,NPC_LT_LC_IP6 ,NPC_LT_LC_IP6_EXT ,
@@ -72,7 +77,6 @@ enum npc_kpu_lc_ltype {NPC_LT_LC_RARP ,NPC_LT_LC_MPLS ,NPC_LT_LC_NSH , -NPC_LT_LC_PTP ,NPC_LT_LC_FCOE ,NPC_LT_LC_NGIO , NPC_LT_LC_CUSTOM0 = 0xE,
drivers/net/ethernet/marvell/octeontx2/af/rvu.c +1 -1
@@ -1643,7 +1643,7 @@ static int rvu_check_rsrc_availability(struct rvu *rvu,if (req->ssow > block->lf.max) {dev_err (&rvu->pdev->dev,"Func 0x%x: Invalid SSOW req, %d > max %d\n" , - pcifunc, req->sso, block->lf.max); + pcifunc, req->ssow, block->lf.max);return -EINVAL ; } mappedlfs =rvu_get_rsrc_mapcount (pfvf, block->addr);
drivers/net/ethernet/marvell/octeontx2/af/rvu_cpt.c +16 -7
@@ -696,7 +696,8 @@ int rvu_mbox_handler_cpt_rd_wr_register(struct rvu *rvu,struct cpt_rd_wr_reg_msg *req, struct cpt_rd_wr_reg_msg *rsp) { - int blkaddr; + u64 offset = req->reg_offset; +int blkaddr, lf; blkaddr =validate_and_get_cpt_blkaddr (req->blkaddr);if (blkaddr <0 )
@@ -707,17 +708,25 @@ int rvu_mbox_handler_cpt_rd_wr_register(struct rvu *rvu, !is_cpt_vf(rvu, req->hdr.pcifunc))return CPT_AF_ERR_ACCESS_DENIED ; - rsp->reg_offset = req->reg_offset; - rsp->ret_val = req->ret_val; - rsp->is_write = req->is_write; -if (!is_valid_offset (rvu, req))return CPT_AF_ERR_ACCESS_DENIED ; +/* Translate local LF used by VFs to global CPT LF */ + lf =rvu_get_lf (rvu, &rvu->hw->block[blkaddr], req->hdr.pcifunc, + (offset &0xFFF ) >>3 ); + +/* Translate local LF's offset to global CPT LF's offset */ + offset &=0xFF000 ; + offset += lf <<3 ; + + rsp->reg_offset = offset; + rsp->ret_val = req->ret_val; + rsp->is_write = req->is_write; +if (req->is_write) -rvu_write64 (rvu, blkaddr, req->reg_offset, req->val); +rvu_write64 (rvu, blkaddr, offset, req->val);else - rsp->val =rvu_read64 (rvu, blkaddr, req->reg_offset); + rsp->val =rvu_read64 (rvu, blkaddr, offset);return 0 ; }
drivers/net/ethernet/marvell/octeontx2/af/rvu_nix.c +8 -4
@@ -3864,6 +3864,11 @@ static int get_flowkey_alg_idx(struct nix_hw *nix_hw, u32 flow_cfg)return -ERANGE ; } +/* Mask to match ipv6(NPC_LT_LC_IP6) and ipv6 ext(NPC_LT_LC_IP6_EXT) */ +#define NPC_LT_LC_IP6_MATCH_MSK ((~(NPC_LT_LC_IP6 ^ NPC_LT_LC_IP6_EXT)) & 0xf) +/* Mask to match both ipv4(NPC_LT_LC_IP) and ipv4 ext(NPC_LT_LC_IP_OPT) */ +#define NPC_LT_LC_IP_MATCH_MSK ((~(NPC_LT_LC_IP ^ NPC_LT_LC_IP_OPT)) & 0xf) +static int set_flowkey_fields (struct nix_rx_flowkey_alg *alg,u32 flow_cfg) {int idx, nr_field, key_off, field_marker, keyoff_marker;
@@ -3933,7 +3938,7 @@ static int set_flowkey_fields(struct nix_rx_flowkey_alg *alg, u32 flow_cfg) field->hdr_offset =9 ;/* offset */ field->bytesm1 =0 ;/* 1 byte */ field->ltype_match =NPC_LT_LC_IP ; - field->ltype_mask =0xF ; + field->ltype_mask =NPC_LT_LC_IP_MATCH_MSK ;break ;case NIX_FLOW_KEY_TYPE_IPV4 :case NIX_FLOW_KEY_TYPE_INNR_IPV4 :
@@ -3960,8 +3965,7 @@ static int set_flowkey_fields(struct nix_rx_flowkey_alg *alg, u32 flow_cfg) field->bytesm1 =3 ;/* DIP, 4 bytes */ } } - - field->ltype_mask =0xF ;/* Match only IPv4 */ + field->ltype_mask =NPC_LT_LC_IP_MATCH_MSK ; keyoff_marker = false;break ;case NIX_FLOW_KEY_TYPE_IPV6 :
@@ -3990,7 +3994,7 @@ static int set_flowkey_fields(struct nix_rx_flowkey_alg *alg, u32 flow_cfg) field->bytesm1 =15 ;/* DIP,16 bytes */ } } - field->ltype_mask =0xF ;/* Match only IPv6 */ + field->ltype_mask =NPC_LT_LC_IP6_MATCH_MSK ;break ;case NIX_FLOW_KEY_TYPE_TCP :case NIX_FLOW_KEY_TYPE_UDP :
drivers/net/ethernet/mediatek/mtk_star_emac.c +7 -0
@@ -1524,6 +1524,7 @@ static int mtk_star_probe(struct platform_device *pdev) {struct device_node *of_node;struct mtk_star_priv *priv; +struct phy_device *phydev;struct net_device *ndev;struct device *dev;void __iomem *base;
@@ -1649,6 +1650,12 @@ static int mtk_star_probe(struct platform_device *pdev)netif_napi_add (ndev, &priv->rx_napi, mtk_star_rx_poll);netif_napi_add_tx (ndev, &priv->tx_napi, mtk_star_tx_poll); + phydev =of_phy_find_device (priv->phy_node); +if (phydev) { + phydev->mac_managed_pm = true; +put_device (&phydev->mdio.dev); + } +return devm_register_netdev (dev, ndev); }
drivers/net/ethernet/micrel/ks8851_common.c +5 -5
@@ -352,11 +352,11 @@ static irqreturn_t ks8851_irq(int irq, void *_ks)netif_dbg (ks, intr, ks->netdev,"%s: txspace %d\n" , __func__, tx_space); -spin_lock (&ks->statelock); +spin_lock_bh (&ks->statelock); ks->tx_space = tx_space;if (netif_queue_stopped (ks->netdev))netif_wake_queue (ks->netdev); -spin_unlock (&ks->statelock); +spin_unlock_bh (&ks->statelock); }if (status &IRQ_SPIBEI ) {
@@ -482,6 +482,7 @@ static int ks8851_net_open(struct net_device *dev)ks8851_wrreg16 (ks,KS_IER , ks->rc_ier); ks->queued_len =0 ; + ks->tx_space =ks8851_rdreg16 (ks,KS_TXMIR );netif_start_queue (ks->netdev);netif_dbg (ks, ifup, ks->netdev,"network device up\n" );
@@ -635,14 +636,14 @@ static void ks8851_set_rx_mode(struct net_device *dev)/* schedule work to do the actual set of the data if needed */ -spin_lock (&ks->statelock); +spin_lock_bh (&ks->statelock);if (memcmp (&rxctrl, &ks->rxctrl,sizeof (rxctrl)) !=0 ) {memcpy (&ks->rxctrl, &rxctrl,sizeof (ks->rxctrl));schedule_work (&ks->rxctrl_work); } -spin_unlock (&ks->statelock); +spin_unlock_bh (&ks->statelock); }static int ks8851_set_mac_address (struct net_device *dev,void *addr)
@@ -1101,7 +1102,6 @@ int ks8851_probe_common(struct net_device *netdev, struct device *dev,int ret; ks->netdev = netdev; - ks->tx_space =6144 ; ks->gpio =devm_gpiod_get_optional (dev,"reset" ,GPIOD_OUT_HIGH ); ret =PTR_ERR_OR_ZERO (ks->gpio);
drivers/net/ethernet/micrel/ks8851_spi.c +2 -2
@@ -340,10 +340,10 @@ static void ks8851_tx_work(struct work_struct *work) tx_space =ks8851_rdreg16_spi (ks,KS_TXMIR ); -spin_lock (&ks->statelock); +spin_lock_bh (&ks->statelock); ks->queued_len -= dequeued_len; ks->tx_space = tx_space; -spin_unlock (&ks->statelock); +spin_unlock_bh (&ks->statelock);ks8851_unlock_spi (ks, &flags); }
drivers/net/phy/microchip_t1.c +1 -1
@@ -748,7 +748,7 @@ static int lan87xx_cable_test_report(struct phy_device *phydev)ethnl_cable_test_result (phydev,ETHTOOL_A_CABLE_PAIR_A ,lan87xx_cable_test_report_trans (detect)); -return 0 ; +return phy_init_hw (phydev); } static int lan87xx_cable_test_get_status(struct phy_device *phydev,
drivers/net/ppp/ppp_generic.c +15 -0
@@ -70,6 +70,7 @@#define MPHDRLEN_SSN 4/* ditto with short sequence numbers */ #define PPP_PROTO_LEN 2 +#define PPP_LCP_HDRLEN 4/* * An instance of /dev/ppp can be associated with either a ppp
@@ -493,6 +494,15 @@ static ssize_t ppp_read(struct file *file, char __user *buf,return ret; } +static bool ppp_check_packet (struct sk_buff *skb,size_t count) +{ +/* LCP packets must include LCP header which 4 bytes long: +* 1-byte code, 1-byte identifier, and 2-byte length. +*/ +return get_unaligned_be16 (skb->data) !=PPP_LCP || + count >=PPP_PROTO_LEN +PPP_LCP_HDRLEN ; +} +static ssize_t ppp_write (struct file *file,const char __user *buf,size_t count,loff_t *ppos) {
@@ -515,6 +525,11 @@ static ssize_t ppp_write(struct file *file, const char __user *buf,kfree_skb (skb); goto out; } + ret = -EINVAL ; +if (unlikely (!ppp_check_packet (skb, count))) { +kfree_skb (skb); + goto out; + }switch (pf->kind) {case INTERFACE :
drivers/net/wireguard/allowedips.c +2 -2
@@ -15,8 +15,8 @@ static void swap_endian(u8 *dst, const u8 *src, u8 bits)if (bits ==32 ) { *(u32 *)dst =be32_to_cpu (*(const __be32 *)src); }else if (bits ==128 ) { - ((u64 *)dst)[0 ] =be64_to_cpu (((const __be64 *)src)[0 ]); - ((u64 *)dst)[1 ] =be64_to_cpu (((const __be64 *)src)[1 ]); + ((u64 *)dst)[0 ] =get_unaligned_be64 (src); + ((u64 *)dst)[1 ] =get_unaligned_be64 (src +8 ); } }
drivers/net/wireguard/queueing.h +2 -2
@@ -124,10 +124,10 @@ static inline int wg_cpumask_choose_online(int *stored_cpu, unsigned int id)*/ static inline int wg_cpumask_next_online (int *last_cpu) { -int cpu =cpumask_next (*last_cpu, cpu_online_mask); +int cpu =cpumask_next (READ_ONCE (*last_cpu), cpu_online_mask);if (cpu >= nr_cpu_ids) cpu =cpumask_first (cpu_online_mask); - *last_cpu = cpu; +WRITE_ONCE (*last_cpu, cpu);return cpu; }
drivers/net/wireguard/send.c +1 -1
@@ -222,7 +222,7 @@ void wg_packet_send_keepalive(struct wg_peer *peer) {struct sk_buff *skb; -if (skb_queue_empty (&peer->staged_packet_queue)) { +if (skb_queue_empty_lockless (&peer->staged_packet_queue)) { skb =alloc_skb (DATA_PACKET_HEAD_ROOM +MESSAGE_MINIMUM_LENGTH ,GFP_ATOMIC );if (unlikely (!skb))
drivers/nvmem/core.c +3 -4
@@ -396,10 +396,9 @@ static int nvmem_sysfs_setup_compat(struct nvmem_device *nvmem,if (!config->base_dev)return -EINVAL ; -if (config->type ==NVMEM_TYPE_FRAM ) - bin_attr_nvmem_eeprom_compat.attr.name ="fram" ; - nvmem->eeprom = bin_attr_nvmem_eeprom_compat; +if (config->type ==NVMEM_TYPE_FRAM ) + nvmem->eeprom.attr.name ="fram" ; nvmem->eeprom.attr.mode =nvmem_bin_attr_get_umode (nvmem); nvmem->eeprom.size = nvmem->size;#ifdef CONFIG_DEBUG_LOCK_ALLOC
@@ -463,7 +462,7 @@ static int nvmem_populate_sysfs_cells(struct nvmem_device *nvmem)"%s@%x,%x" , entry->name, entry->offset, entry->bit_offset); - attrs[i].attr.mode =0444 ; + attrs[i].attr.mode =0444 &nvmem_bin_attr_get_umode (nvmem); attrs[i].size = entry->bytes; attrs[i].read = &nvmem_cell_attr_read; attrs[i].private = entry;
drivers/nvmem/meson-efuse.c +10 -4
@@ -18,18 +18,24 @@ static int meson_efuse_read(void *context, unsigned int offset, void *val, size_t bytes) {struct meson_sm_firmware *fw = context; +int ret; -return meson_sm_call_read (fw, (u8 *)val, bytes,SM_EFUSE_READ , offset, - bytes,0 ,0 ,0 ); + ret =meson_sm_call_read (fw, (u8 *)val, bytes,SM_EFUSE_READ , offset, + bytes,0 ,0 ,0 ); + +return ret <0 ? ret :0 ; }static int meson_efuse_write (void *context,unsigned int offset,void *val,size_t bytes) {struct meson_sm_firmware *fw = context; +int ret; + + ret =meson_sm_call_write (fw, (u8 *)val, bytes,SM_EFUSE_WRITE , offset, + bytes,0 ,0 ,0 ); -return meson_sm_call_write (fw, (u8 *)val, bytes,SM_EFUSE_WRITE , offset, - bytes,0 ,0 ,0 ); +return ret <0 ? ret :0 ; }static const struct of_device_id meson_efuse_match[] = {
drivers/nvmem/rmem.c +4 -1
@@ -46,7 +46,10 @@ static int rmem_read(void *context, unsigned int offset,memunmap (addr); -return count; +if (count <0 ) +return count; + +return count == bytes ?0 : -EIO ; }static int rmem_probe (struct platform_device *pdev)
drivers/platform/x86/toshiba_acpi.c +1 -0
@@ -3304,6 +3304,7 @@ static const struct dmi_system_id toshiba_dmi_quirks[] __initconst = { }, .driver_data = (void *)(QUIRK_TURN_ON_PANEL_ON_RESUME | QUIRK_HCI_HOTKEY_QUICKSTART), }, + { } };static int toshiba_acpi_add (struct acpi_device *acpi_dev)
drivers/pmdomain/qcom/rpmhpd.c +7 -0
@@ -40,6 +40,7 @@* @addr: Resource address as looped up using resource name from * cmd-db * @state_synced: Indicator that sync_state has been invoked for the rpmhpd resource +* @skip_retention_level: Indicate that retention level should not be used for the power domain */ struct rpmhpd {struct device *dev;
@@ -56,6 +57,7 @@ struct rpmhpd {const char *res_name;u32 addr;bool state_synced; +bool skip_retention_level; };struct rpmhpd_desc {
@@ -173,6 +175,7 @@ static struct rpmhpd mxc = { .pd = { .name = "mxc", }, .peer = &mxc_ao, .res_name = "mxc.lvl", + .skip_retention_level = true, };static struct rpmhpd mxc_ao = {
@@ -180,6 +183,7 @@ static struct rpmhpd mxc_ao = { .active_only = true, .peer = &mxc, .res_name = "mxc.lvl", + .skip_retention_level = true, };static struct rpmhpd nsp = {
@@ -819,6 +823,9 @@ static int rpmhpd_update_level_mapping(struct rpmhpd *rpmhpd)return -EINVAL ;for (i =0 ; i < rpmhpd->level_count; i++) { +if (rpmhpd->skip_retention_level && buf[i] ==RPMH_REGULATOR_LEVEL_RETENTION ) +continue ; + rpmhpd->level[i] = buf[i];/* Remember the first corner with non-zero level */
drivers/spi/spi-axi-spi-engine.c +18 -8
@@ -164,16 +164,20 @@ static void spi_engine_gen_xfer(struct spi_engine_program *p, bool dry, }static void spi_engine_gen_sleep (struct spi_engine_program *p,bool dry, -int delay_ns,u32 sclk_hz) +int delay_ns,int inst_ns,u32 sclk_hz) {unsigned int t; -/* negative delay indicates error, e.g. from spi_delay_to_ns() */ -if (delay_ns <=0 ) +/* +* Negative delay indicates error, e.g. from spi_delay_to_ns(). And if +* delay is less that the instruction execution time, there is no need +* for an extra sleep instruction since the instruction execution time +* will already cover the required delay. +*/ +if (delay_ns <0 || delay_ns <= inst_ns)return ; -/* rounding down since executing the instruction adds a couple of ticks delay */ - t =DIV_ROUND_DOWN_ULL ((u64 )delay_ns * sclk_hz,NSEC_PER_SEC ); + t =DIV_ROUND_UP_ULL ((u64)(delay_ns - inst_ns) * sclk_hz,NSEC_PER_SEC );while (t) {unsigned int n =min (t,256U );
@@ -220,10 +224,16 @@ static void spi_engine_compile_message(struct spi_message *msg, bool dry,struct spi_device *spi = msg->spi;struct spi_controller *host = spi->controller;struct spi_transfer *xfer; -int clk_div, new_clk_div; +int clk_div, new_clk_div, inst_ns;bool keep_cs = false;u8 bits_per_word =0 ; +/* +* Take into account instruction execution time for more accurate sleep +* times, especially when the delay is small. +*/ + inst_ns =DIV_ROUND_UP (NSEC_PER_SEC , host->max_speed_hz); + clk_div =1 ; spi_engine_program_add_cmd(p, dry,
@@ -252,7 +262,7 @@ static void spi_engine_compile_message(struct spi_message *msg, bool dry,spi_engine_gen_xfer (p, dry, xfer);spi_engine_gen_sleep (p, dry,spi_delay_to_ns (&xfer->delay, xfer), - xfer->effective_speed_hz); + inst_ns, xfer->effective_speed_hz);if (xfer->cs_change) {if (list_is_last (&xfer->transfer_list, &msg->transfers)) {
@@ -262,7 +272,7 @@ static void spi_engine_compile_message(struct spi_message *msg, bool dry,spi_engine_gen_cs (p, dry, spi, false);spi_engine_gen_sleep (p, dry,spi_delay_to_ns ( - &xfer->cs_change_delay, xfer), + &xfer->cs_change_delay, xfer), inst_ns, xfer->effective_speed_hz);if (!list_next_entry (xfer, transfer_list)->cs_off)
drivers/spi/spi-mux.c +1 -0
@@ -162,6 +162,7 @@ static int spi_mux_probe(struct spi_device *spi) ctlr->bus_num =-1 ; ctlr->dev.of_node = spi->dev.of_node; ctlr->must_async = true; + ctlr->defer_optimize_message = true; ret =devm_spi_register_controller (&spi->dev, ctlr);if (ret)
drivers/spi/spi.c +17 -3
@@ -2137,7 +2137,8 @@ static void __spi_unoptimize_message(struct spi_message *msg)*/ static void spi_maybe_unoptimize_message (struct spi_message *msg) { -if (!msg->pre_optimized && msg->optimized) +if (!msg->pre_optimized && msg->optimized && + !msg->spi->controller->defer_optimize_message)__spi_unoptimize_message (msg); }
@@ -4285,6 +4286,11 @@ static int __spi_optimize_message(struct spi_device *spi,static int spi_maybe_optimize_message (struct spi_device *spi,struct spi_message *msg) { +if (spi->controller->defer_optimize_message) { + msg->spi = spi; +return 0 ; + } +if (msg->pre_optimized)return 0 ;
@@ -4315,6 +4321,13 @@ int spi_optimize_message(struct spi_device *spi, struct spi_message *msg) {int ret; +/* +* Pre-optimization is not supported and optimization is deferred e.g. +* when using spi-mux. +*/ +if (spi->controller->defer_optimize_message) +return 0 ; + ret =__spi_optimize_message (spi, msg);if (ret)return ret;
@@ -4341,6 +4354,9 @@ EXPORT_SYMBOL_GPL(spi_optimize_message);*/ void spi_unoptimize_message (struct spi_message *msg) { +if (msg->spi->controller->defer_optimize_message) +return ; +__spi_unoptimize_message (msg); msg->pre_optimized = false; }
@@ -4423,8 +4439,6 @@ int spi_async(struct spi_device *spi, struct spi_message *message)spin_unlock_irqrestore (&ctlr->bus_lock_spinlock, flags); -spi_maybe_unoptimize_message (message); -return ret; }EXPORT_SYMBOL_GPL (spi_async);
drivers/tty/serial/imx.c +51 -0
63 lines not on this page · raw message
drivers/tty/serial/ma35d1_serial.c +7 -6
@@ -688,12 +688,13 @@ static int ma35d1serial_probe(struct platform_device *pdev)struct uart_ma35d1_port *up;int ret =0 ; -if (pdev->dev.of_node) { - ret =of_alias_get_id (pdev->dev.of_node,"serial" ); -if (ret <0 ) { -dev_err (&pdev->dev,"failed to get alias/pdev id, errno %d\n" , ret); -return ret; - } +if (!pdev->dev.of_node) +return -ENODEV ; + + ret =of_alias_get_id (pdev->dev.of_node,"serial" ); +if (ret <0 ) { +dev_err (&pdev->dev,"failed to get alias/pdev id, errno %d\n" , ret); +return ret; } up = &ma35d1serial_ports[ret]; up->port.line = ret;
drivers/ufs/core/ufs-mcq.c +6 -5
@@ -105,16 +105,15 @@ EXPORT_SYMBOL_GPL(ufshcd_mcq_config_mac);* @hba: per adapter instance * @req: pointer to the request to be issued * -* Return: the hardware queue instance on which the request would -* be queued. +* Return: the hardware queue instance on which the request will be or has +* been queued. %NULL if the request has already been freed. */ struct ufs_hw_queue *ufshcd_mcq_req_to_hwq (struct ufs_hba *hba,struct request *req) { -u32 utag =blk_mq_unique_tag (req); -u32 hwq =blk_mq_unique_tag_to_hwq (utag); +struct blk_mq_hw_ctx *hctx =READ_ONCE (req->mq_hctx); -return &hba->uhq[hwq]; +return hctx ? &hba->uhq[hctx->queue_num] :NULL ; }/**
@@ -515,6 +514,8 @@ int ufshcd_mcq_sq_cleanup(struct ufs_hba *hba, int task_tag)if (!cmd)return -EINVAL ; hwq =ufshcd_mcq_req_to_hwq (hba,scsi_cmd_to_rq (cmd)); +if (!hwq) +return 0 ; }else { hwq = hba->dev_cmd_queue; }
drivers/ufs/core/ufshcd.c +2 -0
@@ -6506,6 +6506,8 @@ static bool ufshcd_abort_one(struct request *rq, void *priv)/* Release cmd in MCQ mode if abort succeeds */ if (is_mcq_enabled (hba) && (*ret ==0 )) { hwq =ufshcd_mcq_req_to_hwq (hba,scsi_cmd_to_rq (lrbp->cmd)); +if (!hwq) +return 0 ;spin_lock_irqsave (&hwq->cq_lock, flags);if (ufshcd_cmd_inflight (lrbp->cmd))ufshcd_release_scsi_cmd (hba, lrbp);
drivers/usb/core/config.c +15 -3
@@ -291,6 +291,20 @@ static int usb_parse_endpoint(struct device *ddev, int cfgno,if (ifp->desc.bNumEndpoints >= num_ep) goto skip_to_next_endpoint_or_interface_descriptor; +/* Save a copy of the descriptor and use it instead of the original */ + endpoint = &ifp->endpoint[ifp->desc.bNumEndpoints]; +memcpy (&endpoint->desc, d, n); + d = &endpoint->desc; + +/* Clear the reserved bits in bEndpointAddress */ + i = d->bEndpointAddress & + (USB_ENDPOINT_DIR_MASK |USB_ENDPOINT_NUMBER_MASK ); +if (i != d->bEndpointAddress) { +dev_notice (ddev,"config %d interface %d altsetting %d has an endpoint descriptor with address 0x%X, changing to 0x%X\n" , + cfgno, inum, asnum, d->bEndpointAddress, i); + endpoint->desc.bEndpointAddress = i; + } +/* Check for duplicate endpoint addresses */ if (config_endpoint_is_duplicate (config, inum, asnum, d)) { dev_notice(ddev, "config %d interface %d altsetting %d has a duplicate endpoint with address 0x%X, skipping\n",
@@ -308,10 +322,8 @@ static int usb_parse_endpoint(struct device *ddev, int cfgno, } } - endpoint = &ifp->endpoint[ifp->desc.bNumEndpoints]; +/* Accept this endpoint */ ++ifp->desc.bNumEndpoints; - -memcpy (&endpoint->desc, d, n);INIT_LIST_HEAD (&endpoint->urb_list);/*
drivers/usb/core/of.c +5 -2
@@ -84,9 +84,12 @@ static bool usb_of_has_devices_or_graph(const struct usb_device *hub)if (of_graph_is_present (np))return true; -for_each_child_of_node (np, child) -if (of_property_present (child,"reg" )) +for_each_child_of_node (np, child) { +if (of_property_present (child,"reg" )) { +of_node_put (child);return true; + } + }return false; }
drivers/usb/core/quirks.c +3 -0
@@ -506,6 +506,9 @@ static const struct usb_device_id usb_quirk_list[] = { { USB_DEVICE(0x1b1c, 0x1b38), .driver_info = USB_QUIRK_DELAY_INIT | USB_QUIRK_DELAY_CTRL_MSG }, + /* START BP-850k Printer */ + { USB_DEVICE(0x1bc3, 0x0003), .driver_info = USB_QUIRK_NO_SET_INTF }, + /* MIDI keyboard WORLDE MINI */ { USB_DEVICE(0x1c75, 0x0204), .driver_info = USB_QUIRK_CONFIG_INTF_STRINGS },
drivers/usb/dwc3/dwc3-pci.c +8 -0
@@ -54,6 +54,10 @@#define PCI_DEVICE_ID_INTEL_MTL 0x7e7e#define PCI_DEVICE_ID_INTEL_ARLH_PCH 0x777e#define PCI_DEVICE_ID_INTEL_TGL 0x9a15 +#define PCI_DEVICE_ID_INTEL_PTLH 0xe332 +#define PCI_DEVICE_ID_INTEL_PTLH_PCH 0xe37e +#define PCI_DEVICE_ID_INTEL_PTLU 0xe432 +#define PCI_DEVICE_ID_INTEL_PTLU_PCH 0xe47e#define PCI_DEVICE_ID_AMD_MR 0x163a#define PCI_INTEL_BXT_DSM_GUID "732b85d5-b7a7-4a1b-9ba0-4bbd00ffd511"
@@ -430,6 +434,10 @@ static const struct pci_device_id dwc3_pci_id_table[] = { { PCI_DEVICE_DATA(INTEL, MTLS, &dwc3_pci_intel_swnode) }, { PCI_DEVICE_DATA(INTEL, ARLH_PCH, &dwc3_pci_intel_swnode) }, { PCI_DEVICE_DATA(INTEL, TGL, &dwc3_pci_intel_swnode) }, + { PCI_DEVICE_DATA(INTEL, PTLH, &dwc3_pci_intel_swnode) }, + { PCI_DEVICE_DATA(INTEL, PTLH_PCH, &dwc3_pci_intel_swnode) }, + { PCI_DEVICE_DATA(INTEL, PTLU, &dwc3_pci_intel_swnode) }, + { PCI_DEVICE_DATA(INTEL, PTLU_PCH, &dwc3_pci_intel_swnode) }, { PCI_DEVICE_DATA(AMD, NL_USB, &dwc3_pci_amd_swnode) }, { PCI_DEVICE_DATA(AMD, MR, &dwc3_pci_amd_mr_swnode) },
drivers/usb/gadget/configfs.c +3 -0
@@ -115,9 +115,12 @@ static int usb_string_copy(const char *s, char **s_copy)int ret;char *str;char *copy = *s_copy; + ret =strlen (s);if (ret >USB_MAX_STRING_LEN )return -EOVERFLOW ; +if (ret <1 ) +return -EINVAL ;if (copy) { str = copy;
drivers/usb/host/xhci.c +13 -3
@@ -1125,10 +1125,20 @@ int xhci_resume(struct xhci_hcd *xhci, pm_message_t msg)xhci_dbg (xhci,"Start the secondary HCD\n" ); retval =xhci_run (xhci->shared_hcd); } - +if (retval) +return retval; +/* +* Resume roothubs unconditionally as PORTSC change bits are not +* immediately visible after xHC reset +*/ hcd->state =HC_STATE_SUSPENDED ; -if (xhci->shared_hcd) + +if (xhci->shared_hcd) { xhci->shared_hcd->state =HC_STATE_SUSPENDED ; +usb_hcd_resume_root_hub (xhci->shared_hcd); + } +usb_hcd_resume_root_hub (hcd); + goto done; }
@@ -1152,7 +1162,6 @@ int xhci_resume(struct xhci_hcd *xhci, pm_message_t msg)xhci_dbc_resume (xhci); - done:if (retval ==0 ) {/* * Resume roothubs only if there are pending events.
@@ -1178,6 +1187,7 @@ int xhci_resume(struct xhci_hcd *xhci, pm_message_t msg)usb_hcd_resume_root_hub (hcd); } } +done:/* * If system is subject to the Quirk, Compliance Mode Timer needs to * be re-initialized Always after a system resume. Ports are subject
drivers/usb/serial/mos7840.c +45 -0
57 lines not on this page · raw message
drivers/usb/serial/option.c +38 -0
@@ -1425,6 +1425,10 @@ static const struct usb_device_id option_ids[] = { .driver_info = NCTRL(0) | RSVD(1) }, { USB_DEVICE_INTERFACE_CLASS(TELIT_VENDOR_ID, 0x1901, 0xff), /* Telit LN940 (MBIM) */ .driver_info = NCTRL(0) }, + { USB_DEVICE_INTERFACE_CLASS(TELIT_VENDOR_ID, 0x3000, 0xff), /* Telit FN912 */ + .driver_info = RSVD(0) | NCTRL(3) }, + { USB_DEVICE_INTERFACE_CLASS(TELIT_VENDOR_ID, 0x3001, 0xff), /* Telit FN912 */ + .driver_info = RSVD(0) | NCTRL(2) | RSVD(3) | RSVD(4) }, { USB_DEVICE_INTERFACE_CLASS(TELIT_VENDOR_ID, 0x7010, 0xff), /* Telit LE910-S1 (RNDIS) */ .driver_info = NCTRL(2) }, { USB_DEVICE_INTERFACE_CLASS(TELIT_VENDOR_ID, 0x7011, 0xff), /* Telit LE910-S1 (ECM) */
@@ -1433,6 +1437,8 @@ static const struct usb_device_id option_ids[] = { .driver_info = NCTRL(2) }, { USB_DEVICE_INTERFACE_CLASS(TELIT_VENDOR_ID, 0x701b, 0xff), /* Telit LE910R1 (ECM) */ .driver_info = NCTRL(2) }, + { USB_DEVICE_INTERFACE_CLASS(TELIT_VENDOR_ID, 0x9000, 0xff), /* Telit generic core-dump device */ + .driver_info = NCTRL(0) }, { USB_DEVICE(TELIT_VENDOR_ID, 0x9010), /* Telit SBL FN980 flashing device */ .driver_info = NCTRL(0) | ZLP }, { USB_DEVICE(TELIT_VENDOR_ID, 0x9200), /* Telit LE910S1 flashing device */
@@ -2224,6 +2230,10 @@ static const struct usb_device_id option_ids[] = { { USB_DEVICE_AND_INTERFACE_INFO(MEDIATEK_VENDOR_ID, MEDIATEK_PRODUCT_7106_2COM, 0x02, 0x02, 0x01) }, { USB_DEVICE_AND_INTERFACE_INFO(MEDIATEK_VENDOR_ID, MEDIATEK_PRODUCT_DC_4COM2, 0xff, 0x02, 0x01) }, { USB_DEVICE_AND_INTERFACE_INFO(MEDIATEK_VENDOR_ID, MEDIATEK_PRODUCT_DC_4COM2, 0xff, 0x00, 0x00) }, + { USB_DEVICE_AND_INTERFACE_INFO(MEDIATEK_VENDOR_ID, 0x7126, 0xff, 0x00, 0x00), + .driver_info = NCTRL(2) }, + { USB_DEVICE_AND_INTERFACE_INFO(MEDIATEK_VENDOR_ID, 0x7127, 0xff, 0x00, 0x00), + .driver_info = NCTRL(2) | NCTRL(3) | NCTRL(4) }, { USB_DEVICE(CELLIENT_VENDOR_ID, CELLIENT_PRODUCT_MEN200) }, { USB_DEVICE(CELLIENT_VENDOR_ID, CELLIENT_PRODUCT_MPL200), .driver_info = RSVD(1) | RSVD(4) },
@@ -2284,6 +2294,8 @@ static const struct usb_device_id option_ids[] = { .driver_info = RSVD(3) }, { USB_DEVICE_INTERFACE_CLASS(0x0489, 0xe0f0, 0xff), /* Foxconn T99W373 MBIM */ .driver_info = RSVD(3) }, + { USB_DEVICE_INTERFACE_CLASS(0x0489, 0xe145, 0xff), /* Foxconn T99W651 RNDIS */ + .driver_info = RSVD(5) | RSVD(6) }, { USB_DEVICE(0x1508, 0x1001), /* Fibocom NL668 (IOT version) */ .driver_info = RSVD(4) | RSVD(5) | RSVD(6) }, { USB_DEVICE(0x1782, 0x4d10) }, /* Fibocom L610 (AT mode) */
@@ -2321,6 +2333,32 @@ static const struct usb_device_id option_ids[] = { .driver_info = RSVD(4) }, { USB_DEVICE_INTERFACE_CLASS(0x33f8, 0x0115, 0xff), /* Rolling RW135-GL (laptop MBIM) */ .driver_info = RSVD(5) }, + { USB_DEVICE_INTERFACE_CLASS(0x33f8, 0x0802, 0xff), /* Rolling RW350-GL (laptop MBIM) */ + .driver_info = RSVD(5) }, + { USB_DEVICE_AND_INTERFACE_INFO(0x3731, 0x0100, 0xff, 0xff, 0x30) }, /* NetPrisma LCUK54-WWD for Global */ + { USB_DEVICE_AND_INTERFACE_INFO(0x3731, 0x0100, 0xff, 0x00, 0x40) }, + { USB_DEVICE_AND_INTERFACE_INFO(0x3731, 0x0100, 0xff, 0xff, 0x40) }, + { USB_DEVICE_AND_INTERFACE_INFO(0x3731, 0x0101, 0xff, 0xff, 0x30) }, /* NetPrisma LCUK54-WRD for Global SKU */ + { USB_DEVICE_AND_INTERFACE_INFO(0x3731, 0x0101, 0xff, 0x00, 0x40) }, + { USB_DEVICE_AND_INTERFACE_INFO(0x3731, 0x0101, 0xff, 0xff, 0x40) }, + { USB_DEVICE_AND_INTERFACE_INFO(0x3731, 0x0106, 0xff, 0xff, 0x30) }, /* NetPrisma LCUK54-WRD for China SKU */ + { USB_DEVICE_AND_INTERFACE_INFO(0x3731, 0x0106, 0xff, 0x00, 0x40) }, + { USB_DEVICE_AND_INTERFACE_INFO(0x3731, 0x0106, 0xff, 0xff, 0x40) }, + { USB_DEVICE_AND_INTERFACE_INFO(0x3731, 0x0111, 0xff, 0xff, 0x30) }, /* NetPrisma LCUK54-WWD for SA */ + { USB_DEVICE_AND_INTERFACE_INFO(0x3731, 0x0111, 0xff, 0x00, 0x40) }, + { USB_DEVICE_AND_INTERFACE_INFO(0x3731, 0x0111, 0xff, 0xff, 0x40) }, + { USB_DEVICE_AND_INTERFACE_INFO(0x3731, 0x0112, 0xff, 0xff, 0x30) }, /* NetPrisma LCUK54-WWD for EU */ + { USB_DEVICE_AND_INTERFACE_INFO(0x3731, 0x0112, 0xff, 0x00, 0x40) }, + { USB_DEVICE_AND_INTERFACE_INFO(0x3731, 0x0112, 0xff, 0xff, 0x40) }, + { USB_DEVICE_AND_INTERFACE_INFO(0x3731, 0x0113, 0xff, 0xff, 0x30) }, /* NetPrisma LCUK54-WWD for NA */ + { USB_DEVICE_AND_INTERFACE_INFO(0x3731, 0x0113, 0xff, 0x00, 0x40) }, + { USB_DEVICE_AND_INTERFACE_INFO(0x3731, 0x0113, 0xff, 0xff, 0x40) }, + { USB_DEVICE_AND_INTERFACE_INFO(0x3731, 0x0115, 0xff, 0xff, 0x30) }, /* NetPrisma LCUK54-WWD for China EDU */ + { USB_DEVICE_AND_INTERFACE_INFO(0x3731, 0x0115, 0xff, 0x00, 0x40) }, + { USB_DEVICE_AND_INTERFACE_INFO(0x3731, 0x0115, 0xff, 0xff, 0x40) }, + { USB_DEVICE_AND_INTERFACE_INFO(0x3731, 0x0116, 0xff, 0xff, 0x30) }, /* NetPrisma LCUK54-WWD for Golbal EDU */ + { USB_DEVICE_AND_INTERFACE_INFO(0x3731, 0x0116, 0xff, 0x00, 0x40) }, + { USB_DEVICE_AND_INTERFACE_INFO(0x3731, 0x0116, 0xff, 0xff, 0x40) }, { 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, 0xff, 0x40) },
drivers/vfio/pci/vfio_pci_core.c +1 -1
@@ -1260,7 +1260,7 @@ static int vfio_pci_ioctl_get_pci_hot_reset_info(struct vfio_pci_hot_reset_info hdr;struct vfio_pci_fill_info fill = {};bool slot = false; -int ret, count; +int ret, count =0 ;if (copy_from_user (&hdr, arg, minsz))return -EFAULT ;
fs/cachefiles/daemon.c +2 -2
@@ -366,14 +366,14 @@ static __poll_t cachefiles_daemon_poll(struct file *file,if (cachefiles_in_ondemand_mode (cache)) {if (!xa_empty (&cache->reqs)) { -rcu_read_lock (); +xas_lock (&xas);xas_for_each_marked (&xas, req,ULONG_MAX ,CACHEFILES_REQ_NEW ) {if (!cachefiles_ondemand_is_reopening_read (req)) { mask |=EPOLLIN ;break ; } } -rcu_read_unlock (); +xas_unlock (&xas); } }else {if (test_bit (CACHEFILES_STATE_CHANGED , &cache->flags))
fs/cachefiles/internal.h +3 -0
@@ -48,6 +48,7 @@ enum cachefiles_object_state {CACHEFILES_ONDEMAND_OBJSTATE_CLOSE ,/* Anonymous fd closed by daemon or initial state */ CACHEFILES_ONDEMAND_OBJSTATE_OPEN ,/* Anonymous fd associated with object is available */ CACHEFILES_ONDEMAND_OBJSTATE_REOPENING ,/* Object that was closed and is being reopened. */ + CACHEFILES_ONDEMAND_OBJSTATE_DROPPING, /* Object is being dropped. */ }; struct cachefiles_ondemand_info {
@@ -128,6 +129,7 @@ struct cachefiles_cache {unsigned long req_id_next;struct xarray ondemand_ids;/* xarray for ondemand_id allocation */ u32 ondemand_id_next; +u32 msg_id_next; };static inline bool cachefiles_in_ondemand_mode (struct cachefiles_cache *cache)
@@ -335,6 +337,7 @@ cachefiles_ondemand_set_object_##_state(struct cachefiles_object *object) \CACHEFILES_OBJECT_STATE_FUNCS (open,OPEN );CACHEFILES_OBJECT_STATE_FUNCS (close,CLOSE );CACHEFILES_OBJECT_STATE_FUNCS (reopening,REOPENING ); +CACHEFILES_OBJECT_STATE_FUNCS (dropping,DROPPING );static inline bool cachefiles_ondemand_is_reopening_read (struct cachefiles_req *req) {
fs/cachefiles/ondemand.c +46 -6
88 lines not on this page · raw message
fs/cachefiles/xattr.c +4 -1
@@ -110,9 +110,11 @@ int cachefiles_check_auxdata(struct cachefiles_object *object, struct file *fileif (xlen ==0 ) xlen =vfs_getxattr (&nop_mnt_idmap, dentry, cachefiles_xattr_cache, buf, tlen);if (xlen != tlen) { -if (xlen <0 ) +if (xlen <0 ) { + ret = xlen;trace_cachefiles_vfs_error (object,file_inode (file), xlen, cachefiles_trace_getxattr_error); + }if (xlen == -EIO ) cachefiles_io_error_obj( object,
@@ -252,6 +254,7 @@ int cachefiles_check_volume_xattr(struct cachefiles_volume *volume) xlen =vfs_getxattr (&nop_mnt_idmap, dentry, cachefiles_xattr_cache, buf, len);if (xlen != len) {if (xlen <0 ) { + ret = xlen;trace_cachefiles_vfs_error (NULL ,d_inode (dentry), xlen, cachefiles_trace_getxattr_error);if (xlen == -EIO )
fs/dcache.c +9 -3
@@ -355,7 +355,11 @@ static inline void __d_clear_type_and_inode(struct dentry *dentry) flags &= ~DCACHE_ENTRY_TYPE ;WRITE_ONCE (dentry->d_flags, flags); dentry->d_inode =NULL ; -if (dentry->d_flags &DCACHE_LRU_LIST ) +/* +* The negative counter only tracks dentries on the LRU. Don't inc if +* d_lru is on another list. +*/ +if ((flags & (DCACHE_LRU_LIST |DCACHE_SHRINK_LIST )) ==DCACHE_LRU_LIST )this_cpu_inc (nr_dentry_negative); }
@@ -1844,9 +1848,11 @@ static void __d_instantiate(struct dentry *dentry, struct inode *inode)spin_lock (&dentry->d_lock);/* -* Decrement negative dentry count if it was in the LRU list. +* The negative counter only tracks dentries on the LRU. Don't dec if +* d_lru is on another list. */ -if (dentry->d_flags &DCACHE_LRU_LIST ) +if ((dentry->d_flags & + (DCACHE_LRU_LIST |DCACHE_SHRINK_LIST )) ==DCACHE_LRU_LIST )this_cpu_dec (nr_dentry_negative);hlist_add_head (&dentry->d_u.d_alias, &inode->i_dentry);raw_write_seqcount_begin (&dentry->d_seq);
fs/ext4/sysfs.c +2 -0
@@ -473,6 +473,8 @@ static ssize_t ext4_attr_store(struct kobject *kobj, *((unsigned int *) ptr) = t;return len;case attr_clusters_in_group: +if (!ptr) +return 0 ; ret =kstrtouint (skip_spaces (buf),0 , &t);if (ret)return ret;
fs/locks.c +1 -1
@@ -1367,9 +1367,9 @@ static int posix_lock_inode(struct inode *inode, struct file_lock *request,locks_wake_up_blocks (&left->c); } out: +trace_posix_lock_inode (inode, request, error);spin_unlock (&ctx->flc_lock);percpu_up_read (&file_rwsem); -trace_posix_lock_inode (inode, request, error);/* * Free any unused locks. */
fs/minix/namei.c +1 -2
@@ -213,8 +213,7 @@ static int minix_rename(struct mnt_idmap *idmap,if (!new_de) goto out_dir; err =minix_set_link (new_de, new_page, old_inode); -kunmap (new_page); -put_page (new_page); +unmap_and_put_page (new_page, new_de);if (err) goto out_dir;inode_set_ctime_current (new_inode);
fs/nilfs2/dir.c +30 -2
@@ -384,11 +384,39 @@ struct nilfs_dir_entry *nilfs_find_entry(struct inode *dir,struct nilfs_dir_entry *nilfs_dotdot (struct inode *dir,struct folio **foliop) { -struct nilfs_dir_entry *de =nilfs_get_folio (dir,0 , foliop); +struct folio *folio; +struct nilfs_dir_entry *de, *next_de; +size_t limit; +char *msg; + de =nilfs_get_folio (dir,0 , &folio);if (IS_ERR (de))return NULL ; -return nilfs_next_entry (de); + + limit =nilfs_last_byte (dir,0 );/* is a multiple of chunk size */ +if (unlikely (!limit ||le64_to_cpu (de->inode) != dir->i_ino || + !nilfs_match (1 ,"." , de))) { + msg ="missing '.'" ; + goto fail; + } + + next_de =nilfs_next_entry (de); +/* +* If "next_de" has not reached the end of the chunk, there is +* at least one more record. Check whether it matches "..". +*/ +if (unlikely ((char *)next_de == (char *)de +nilfs_chunk_size (dir) || + !nilfs_match (2 ,".." , next_de))) { + msg ="missing '..'" ; + goto fail; + } + *foliop = folio; +return next_de; + +fail: +nilfs_error (dir->i_sb,"directory #%lu %s" , dir->i_ino, msg); +folio_release_kmap (folio, de); +return NULL ; }ino_t nilfs_inode_by_name (struct inode *dir,const struct qstr *qstr)
fs/smb/client/cifsglob.h +2 -2
@@ -1938,8 +1938,8 @@ require use of the stronger protocol */#define CIFSSEC_MUST_SEAL 0x40040/* not supported yet */ #define CIFSSEC_MUST_NTLMSSP 0x80080/* raw ntlmssp with ntlmv2 */ -#define CIFSSEC_DEF (CIFSSEC_MAY_SIGN | CIFSSEC_MAY_NTLMV2 | CIFSSEC_MAY_NTLMSSP) -#define CIFSSEC_MAX (CIFSSEC_MUST_NTLMV2) +#define CIFSSEC_DEF (CIFSSEC_MAY_SIGN | CIFSSEC_MAY_NTLMV2 | CIFSSEC_MAY_NTLMSSP | CIFSSEC_MAY_SEAL) +#define CIFSSEC_MAX (CIFSSEC_MAY_SIGN | CIFSSEC_MUST_KRB5 | CIFSSEC_MAY_SEAL)#define CIFSSEC_AUTH_MASK (CIFSSEC_MAY_NTLMV2 | CIFSSEC_MAY_KRB5 | CIFSSEC_MAY_NTLMSSP)/* *****************************************************************
fs/smb/server/smb2pdu.c +11 -2
@@ -2051,15 +2051,22 @@ int smb2_tree_connect(struct ksmbd_work *work)* @access: file access flags * @disposition: file disposition flags * @may_flags: set with MAY_ flags +* @is_dir: is creating open flags for directory * * Return: file open flags */ static int smb2_create_open_flags (bool file_present,__le32 access,__le32 disposition, -int *may_flags) +int *may_flags, +bool is_dir) {int oflags =O_NONBLOCK |O_LARGEFILE ; +if (is_dir) { + access &= ~FILE_WRITE_DESIRE_ACCESS_LE ; +ksmbd_debug (SMB ,"Discard write access to a directory\n" ); + } +if (access &FILE_READ_DESIRED_ACCESS_LE && access &FILE_WRITE_DESIRE_ACCESS_LE ) { oflags |=O_RDWR ;
@@ -3167,7 +3174,9 @@ int smb2_open(struct ksmbd_work *work) open_flags =smb2_create_open_flags (file_present, daccess, req->CreateDisposition, - &may_flags); + &may_flags, + req->CreateOptions &FILE_DIRECTORY_FILE_LE || + (file_present &&S_ISDIR (d_inode (path.dentry)->i_mode)));if (!test_tree_conn_flag (tcon,KSMBD_TREE_CONN_FLAG_WRITABLE )) {if (open_flags & (O_CREAT |O_TRUNC )) {
fs/userfaultfd.c +6 -1
@@ -2053,7 +2053,7 @@ static int userfaultfd_api(struct userfaultfd_ctx *ctx, goto out; features = uffdio_api.features; ret = -EINVAL ; -if (uffdio_api.api !=UFFD_API || (features & ~UFFD_API_FEATURES )) +if (uffdio_api.api !=UFFD_API ) goto err_out; ret = -EPERM ;if ((features &UFFD_FEATURE_EVENT_FORK ) && !capable (CAP_SYS_PTRACE ))
@@ -2077,6 +2077,11 @@ static int userfaultfd_api(struct userfaultfd_ctx *ctx, uffdio_api.features &= ~UFFD_FEATURE_WP_UNPOPULATED ; uffdio_api.features &= ~UFFD_FEATURE_WP_ASYNC ;#endif + + ret = -EINVAL ; +if (features & ~uffdio_api.features) + goto err_out; + uffdio_api.ioctls =UFFD_API_IOCTLS ; ret = -EFAULT ;if (copy_to_user (buf, &uffdio_api,sizeof (uffdio_api)))
include/linux/mmzone.h +2 -1
@@ -1976,8 +1976,9 @@ static inline int subsection_map_index(unsigned long pfn)static inline int pfn_section_valid (struct mem_section *ms,unsigned long pfn) {int idx =subsection_map_index (pfn); +struct mem_section_usage *usage =READ_ONCE (ms->usage); -return test_bit (idx,READ_ONCE (ms->usage)->subsection_map); +return usage ?test_bit (idx, usage->subsection_map) :0 ; }#else static inline int pfn_section_valid (struct mem_section *ms,unsigned long pfn)
include/linux/pagemap.h +9 -2
@@ -352,11 +352,18 @@ static inline void mapping_set_gfp_mask(struct address_space *m, gfp_t mask)* a good order (that's 1MB if you're using 4kB pages) */ #ifdef CONFIG_TRANSPARENT_HUGEPAGE -#define MAX_PAGECACHE_ORDER HPAGE_PMD_ORDER +#define PREFERRED_MAX_PAGECACHE_ORDER HPAGE_PMD_ORDER#else -#define MAX_PAGECACHE_ORDER 8 +#define PREFERRED_MAX_PAGECACHE_ORDER 8#endif +/* +* xas_split_alloc() does not support arbitrary orders. This implies no +* 512MB THP on ARM64 with 64KB base page size. +*/ +#define MAX_XAS_ORDER (XA_CHUNK_SHIFT * 2 - 1) +#define MAX_PAGECACHE_ORDER min(MAX_XAS_ORDER, PREFERRED_MAX_PAGECACHE_ORDER) +/** * mapping_set_large_folios() - Indicate the file supports large folios. * @mapping: The file.
include/linux/spi/spi.h +4 -0
@@ -532,6 +532,9 @@ extern struct spi_device *spi_new_ancillary_device(struct spi_device *spi, u8 ch* @queue_empty: signal green light for opportunistically skipping the queue * for spi_sync transfers. * @must_async: disable all fast paths in the core +* @defer_optimize_message: set to true if controller cannot pre-optimize messages +* and needs to defer the optimization step until the message is actually +* being transferred * * Each SPI controller can communicate with one or more @spi_device * children. These make a small bus, sharing MOSI, MISO and SCK signals
@@ -775,6 +778,7 @@ struct spi_controller {/* Flag for enabling opportunistic skipping of the queue in spi_sync */ bool queue_empty;bool must_async; +bool defer_optimize_message; };static inline void *spi_controller_get_devdata (struct spi_controller *ctlr)
include/linux/swap.h +2 -1
@@ -344,7 +344,8 @@ static inline swp_entry_t page_swap_entry(struct page *page) }/* linux/mm/workingset.c */ -bool workingset_test_recent (void *shadow,bool file,bool *workingset); +bool workingset_test_recent (void *shadow,bool file,bool *workingset, +bool flush);void workingset_age_nonresident (struct lruvec *lruvec,unsigned long nr_pages);void *workingset_eviction (struct folio *folio,struct mem_cgroup *target_memcg);void workingset_refault (struct folio *folio,void *shadow);
include/net/tcx.h +9 -4
@@ -13,7 +13,7 @@ struct mini_Qdisc;struct tcx_entry {struct mini_Qdisc __rcu *miniq;struct bpf_mprog_bundle bundle; -bool miniq_active; +u32 miniq_active;struct rcu_head rcu; };
@@ -124,11 +124,16 @@ static inline void tcx_skeys_dec(bool ingress)tcx_dec (); } -static inline void tcx_miniq_set_active (struct bpf_mprog_entry *entry, -const bool active) +static inline void tcx_miniq_inc (struct bpf_mprog_entry *entry) {ASSERT_RTNL (); -tcx_entry (entry)->miniq_active = active; +tcx_entry (entry)->miniq_active++; +} + +static inline void tcx_miniq_dec (struct bpf_mprog_entry *entry) +{ +ASSERT_RTNL (); +tcx_entry (entry)->miniq_active--; }static inline bool tcx_entry_is_active (struct bpf_mprog_entry *entry)
include/uapi/misc/fastrpc.h +3 -0
@@ -8,11 +8,14 @@#define FASTRPC_IOCTL_ALLOC_DMA_BUFF _IOWR('R', 1, struct fastrpc_alloc_dma_buf)#define FASTRPC_IOCTL_FREE_DMA_BUFF _IOWR('R', 2, __u32)#define FASTRPC_IOCTL_INVOKE _IOWR('R', 3, struct fastrpc_invoke) +/* This ioctl is only supported with secure device nodes */ #define FASTRPC_IOCTL_INIT_ATTACH _IO('R', 4)#define FASTRPC_IOCTL_INIT_CREATE _IOWR('R', 5, struct fastrpc_init_create)#define FASTRPC_IOCTL_MMAP _IOWR('R', 6, struct fastrpc_req_mmap)#define FASTRPC_IOCTL_MUNMAP _IOWR('R', 7, struct fastrpc_req_munmap) +/* This ioctl is only supported with secure device nodes */ #define FASTRPC_IOCTL_INIT_ATTACH_SNS _IO('R', 8) +/* This ioctl is only supported with secure device nodes */ #define FASTRPC_IOCTL_INIT_CREATE_STATIC _IOWR('R', 9, struct fastrpc_init_create_static)#define FASTRPC_IOCTL_MEM_MAP _IOWR('R', 10, struct fastrpc_mem_map)#define FASTRPC_IOCTL_MEM_UNMAP _IOWR('R', 11, struct fastrpc_mem_unmap)
kernel/bpf/bpf_local_storage.c +2 -2
@@ -782,8 +782,8 @@ bpf_local_storage_map_alloc(union bpf_attr *attr, nbuckets =max_t (u32,2 , nbuckets); smap->bucket_log =ilog2 (nbuckets); - smap->buckets =bpf_map_kvcalloc (&smap->map,sizeof (*smap->buckets), - nbuckets,GFP_USER | __GFP_NOWARN); + smap->buckets =bpf_map_kvcalloc (&smap->map, nbuckets, +sizeof (*smap->buckets),GFP_USER | __GFP_NOWARN);if (!smap->buckets) { err = -ENOMEM ; goto free_smap;
kernel/bpf/helpers.c +174 -69
406 lines not on this page · raw message
kernel/sched/deadline.c +6 -1
@@ -1805,8 +1805,13 @@ static void enqueue_task_dl(struct rq *rq, struct task_struct *p, int flags)* The replenish timer needs to be canceled. No * problem if it fires concurrently: boosted threads * are ignored in dl_task_timer(). +* +* If the timer callback was running (hrtimer_try_to_cancel == -1), +* it will eventually call put_task_struct(). */ -hrtimer_try_to_cancel (&p->dl.dl_timer); +if (hrtimer_try_to_cancel (&p->dl.dl_timer) ==1 && + !dl_server (&p->dl)) +put_task_struct (p); p->dl.dl_throttled =0 ; } }else if (!dl_prio (p->normal_prio)) {
kernel/sched/fair.c +3 -9
@@ -9106,12 +9106,8 @@ static int detach_tasks(struct lb_env *env)break ; env->loop++; -/* -* We've more or less seen every task there is, call it quits -* unless we haven't found any movable task yet. -*/ -if (env->loop > env->loop_max && - !(env->flags &LBF_ALL_PINNED )) +/* We've more or less seen every task there is, call it quits */ +if (env->loop > env->loop_max)break ;/* take a breather every nr_migrate tasks */
@@ -11363,9 +11359,7 @@ static int load_balance(int this_cpu, struct rq *this_rq,if (env.flags &LBF_NEED_BREAK ) { env.flags &= ~LBF_NEED_BREAK ; -/* Stop if we tried all running tasks */ -if (env.loop < busiest->nr_running) - goto more_balance; + goto more_balance; }/*
mm/damon/core.c +20 -3
@@ -1357,14 +1357,31 @@ static void damon_merge_regions_of(struct damon_target *t, unsigned int thres,* access frequencies are similar. This is for minimizing the monitoring * overhead under the dynamically changeable access pattern. If a merge was * unnecessarily made, later 'kdamond_split_regions()' will revert it. +* +* The total number of regions could be higher than the user-defined limit, +* max_nr_regions for some cases. For example, the user can update +* max_nr_regions to a number that lower than the current number of regions +* while DAMON is running. For such a case, repeat merging until the limit is +* met while increasing @threshold up to possible maximum level. */ static void kdamond_merge_regions (struct damon_ctx *c,unsigned int threshold,unsigned long sz_limit) {struct damon_target *t; - -damon_for_each_target (t, c) -damon_merge_regions_of (t, threshold, sz_limit); +unsigned int nr_regions; +unsigned int max_thres; + + max_thres = c->attrs.aggr_interval / + (c->attrs.sample_interval ? c->attrs.sample_interval :1 ); +do { + nr_regions =0 ; +damon_for_each_target (t, c) { +damon_merge_regions_of (t, threshold, sz_limit); + nr_regions +=damon_nr_regions (t); + } + threshold =max (1 , threshold *2 ); + }while (nr_regions > c->attrs.max_nr_regions && + threshold /2 < max_thres); }/*
mm/filemap.c +7 -3
@@ -3100,7 +3100,7 @@ static struct file *do_sync_mmap_readahead(struct vm_fault *vmf)#ifdef CONFIG_TRANSPARENT_HUGEPAGE /* Use the readahead code, even if readahead is disabled */ -if (vm_flags &VM_HUGEPAGE ) { +if ((vm_flags &VM_HUGEPAGE ) &&HPAGE_PMD_ORDER <=MAX_PAGECACHE_ORDER ) { fpin =maybe_unlock_mmap_for_io (vmf, fpin); ractl._index &= ~((unsigned long )HPAGE_PMD_NR -1 ); ra->size =HPAGE_PMD_NR ;
@@ -3207,7 +3207,8 @@ static vm_fault_t filemap_fault_recheck_pte_none(struct vm_fault *vmf)if (!(vmf->flags &FAULT_FLAG_ORIG_PTE_VALID ))return 0 ; - ptep =pte_offset_map (vmf->pmd, vmf->address); + ptep =pte_offset_map_nolock (vma->vm_mm, vmf->pmd, vmf->address, + &vmf->ptl);if (unlikely (!ptep))return VM_FAULT_NOPAGE ;
@@ -4153,6 +4154,9 @@ static void filemap_cachestat(struct address_space *mapping,XA_STATE (xas, &mapping->i_pages, first_index);struct folio *folio; +/* Flush stats (and potentially sleep) outside the RCU read section. */ +mem_cgroup_flush_stats_ratelimited (NULL ); +rcu_read_lock ();xas_for_each (&xas, folio, last_index) {int order;
@@ -4216,7 +4220,7 @@ static void filemap_cachestat(struct address_space *mapping, goto resched; }#endif -if (workingset_test_recent (shadow, true, &workingset)) +if (workingset_test_recent (shadow, true, &workingset, false)) cs->nr_recently_evicted += nr_pages; goto resched;
mm/memcontrol.c +0 -11
@@ -7609,17 +7609,6 @@ void mem_cgroup_migrate(struct folio *old, struct folio *new)/* Transfer the charge and the css ref */ commit_charge (new, memcg); -/* -* If the old folio is a large folio and is in the split queue, it needs -* to be removed from the split queue now, in case getting an incorrect -* split queue in destroy_large_folio() after the memcg of the old folio -* is cleared. -* -* In addition, the old folio is about to be freed after migration, so -* removing from the split queue a bit earlier seems reasonable. -*/ -if (folio_test_large (old) &&folio_test_large_rmappable (old)) -folio_undo_large_rmappable (old);
Lines of this file are not shown. View the raw message.
net/ethtool/linkstate.c +28 -13
41 lines not on this page · raw message
net/netfilter/nf_tables_api.c +13 -145
158 lines not on this page · raw message
tools/testing/selftests/wireguard/qemu/Makefile +4 -4
Lines of this file are not shown. View the raw message.
The rest of this diff is not shown. View the raw message.
Part of the diff is not shown here. View the raw message.