Linux 5.10.138
Greg Kroah-Hartman
maintainerI'm announcing the release of the 5.10.138 kernel.
All users of the 5.10 kernel series must upgrade.
The updated 5.10.y git tree can be found at:
git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git linux-5.10.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/atomic_bitops.txt | 2 Documentation/devicetree/bindings/arm/qcom.yaml | 2 Documentation/devicetree/bindings/clock/qcom,gcc-msm8996.yaml | 16 Documentation/devicetree/bindings/regulator/nxp,pca9450-regulator.yaml | 11 Documentation/firmware-guide/acpi/apei/einj.rst | 2 Makefile | 8 arch/csky/kernel/probes/kprobes.c | 4 arch/mips/cavium-octeon/octeon-platform.c | 3 arch/mips/mm/tlbex.c | 4 arch/nios2/include/asm/entry.h | 3 arch/nios2/include/asm/ptrace.h | 2 arch/nios2/kernel/entry.S | 22 arch/nios2/kernel/signal.c | 3 arch/nios2/kernel/syscall_table.c | 1 arch/powerpc/Makefile | 26 arch/powerpc/kernel/pci-common.c | 16 arch/powerpc/kernel/prom.c | 7 arch/powerpc/platforms/Kconfig.cputype | 21 arch/riscv/kernel/sys_riscv.c | 5 arch/riscv/kernel/traps.c | 4 arch/um/os-Linux/skas/process.c | 17 arch/x86/mm/init_64.c | 2 drivers/acpi/pci_mcfg.c | 3 drivers/acpi/property.c | 8 drivers/ata/libata-eh.c | 1 drivers/atm/idt77252.c | 1 drivers/block/zram/zcomp.c | 11 drivers/clk/qcom/clk-alpha-pll.c | 2 drivers/clk/qcom/gcc-ipq8074.c | 1 drivers/clk/ti/clk-44xx.c | 210 +++--- drivers/clk/ti/clk-54xx.c | 160 ++-- drivers/clk/ti/clkctrl.c | 4 drivers/dma/sprd-dma.c | 5 drivers/gpu/drm/meson/meson_drv.c | 5 drivers/gpu/drm/meson/meson_viu.c | 22 drivers/gpu/drm/sun4i/sun6i_mipi_dsi.c | 10 drivers/i2c/busses/i2c-imx.c | 20 drivers/infiniband/sw/rxe/rxe_param.h | 6 drivers/infiniband/sw/rxe/rxe_task.c | 16 drivers/irqchip/irq-tegra.c | 10 drivers/md/md.c | 1 drivers/md/raid5.c | 2 drivers/misc/cxl/irq.c | 1 drivers/misc/uacce/uacce.c | 133 ++-- drivers/mmc/host/meson-gx-mmc.c | 6 drivers/mmc/host/pxamci.c | 4 drivers/net/can/spi/mcp251x.c | 18 drivers/net/can/usb/ems_usb.c | 2 drivers/net/dsa/microchip/ksz9477.c | 3 drivers/net/dsa/mv88e6060.c | 3 drivers/net/dsa/ocelot/felix_vsc9959.c | 3 drivers/net/dsa/sja1105/sja1105_devlink.c | 2 drivers/net/ethernet/aquantia/atlantic/aq_nic.c | 21 drivers/net/ethernet/broadcom/bgmac.c | 2 drivers/net/ethernet/freescale/dpaa2/dpaa2-eth.c | 4 drivers/net/ethernet/freescale/fec_ptp.c | 6 drivers/net/ethernet/intel/i40e/i40e_main.c | 4 drivers/net/ethernet/intel/iavf/iavf_adminq.c | 15 drivers/net/ethernet/intel/ice/ice_switch.c | 2 drivers/net/ethernet/intel/igb/igb.h | 2 drivers/net/ethernet/intel/igb/igb_main.c | 12 drivers/net/ethernet/moxa/moxart_ether.c | 20 drivers/net/ethernet/netronome/nfp/nfp_net_ethtool.c | 2 drivers/net/ethernet/stmicro/stmmac/dwmac-intel.c | 1 drivers/net/geneve.c | 15 drivers/net/plip/plip.c | 2 drivers/net/virtio_net.c | 5 drivers/ntb/test/ntb_tool.c | 8 drivers/nvme/target/tcp.c | 3 drivers/pci/pcie/err.c | 3 drivers/pci/quirks.c | 3 drivers/pinctrl/intel/pinctrl-intel.c | 14 drivers/pinctrl/nomadik/pinctrl-nomadik.c | 4 drivers/pinctrl/qcom/pinctrl-msm8916.c | 4 drivers/pinctrl/qcom/pinctrl-sm8250.c | 2 drivers/pinctrl/sunxi/pinctrl-sun50i-h6-r.c | 1 drivers/pinctrl/sunxi/pinctrl-sunxi.c | 7 drivers/platform/chrome/cros_ec_proto.c | 8 drivers/scsi/lpfc/lpfc_debugfs.c | 20 drivers/spi/spi-meson-spicc.c | 129 +++ drivers/tee/tee_core.c | 3 drivers/tee/tee_shm.c | 3 drivers/tty/serial/ucc_uart.c | 2 drivers/usb/cdns3/gadget.c | 2 drivers/usb/dwc2/gadget.c | 3 drivers/usb/gadget/function/uvc_video.c | 2 drivers/usb/gadget/legacy/inode.c | 1 drivers/usb/host/ohci-ppc-of.c | 1 drivers/usb/renesas_usbhs/rza.c | 4 drivers/vfio/vfio.c | 1 drivers/video/fbdev/i740fb.c | 9 drivers/virt/vboxguest/vboxguest_linux.c | 9 drivers/xen/xenbus/xenbus_dev_frontend.c | 4 fs/btrfs/tree-log.c | 4 fs/ceph/caps.c | 27 fs/ceph/mds_client.c | 7 fs/ceph/mds_client.h | 6 fs/cifs/smb2ops.c | 5 fs/ext4/namei.c | 7 fs/ext4/resize.c | 10 fs/f2fs/node.c | 6 fs/f2fs/segment.c | 13 fs/nfs/nfs4idmap.c | 46 - fs/nfs/nfs4proc.c | 20 include/asm-generic/bitops/atomic.h | 6 include/linux/netfilter/nfnetlink.h | 27 include/linux/nmi.h | 2 include/linux/uacce.h | 6 include/sound/control.h | 2 include/sound/core.h | 8 kernel/bpf/arraymap.c | 6 kernel/bpf/cgroup.c | 70 +- kernel/bpf/hashtab.c | 2 kernel/trace/trace_events.c | 1 kernel/trace/trace_probe.c | 5 kernel/watchdog.c | 21 lib/list_debug.c | 12 net/can/j1939/socket.c | 5 net/can/j1939/transport.c | 8 net/core/bpf_sk_storage.c | 12 net/core/devlink.c | 4 net/core/sock_map.c | 20 net/ipv6/ip6_output.c | 3 net/netfilter/ipset/ip_set_core.c | 17 net/netfilter/nf_conntrack_netlink.c | 77 -- net/netfilter/nf_tables_api.c | 325 ++++------ net/netfilter/nf_tables_trace.c | 9 net/netfilter/nfnetlink_acct.c | 11 net/netfilter/nfnetlink_cthelper.c | 11 net/netfilter/nfnetlink_cttimeout.c | 22 net/netfilter/nfnetlink_log.c | 11 net/netfilter/nfnetlink_queue.c | 12 net/netfilter/nft_compat.c | 11 net/netlink/genetlink.c | 6 net/netlink/policy.c | 14 net/qrtr/qrtr.c | 42 - net/rds/ib_recv.c | 1 net/sunrpc/auth.c | 2 net/sunrpc/backchannel_rqst.c | 14 net/vmw_vsock/af_vsock.c | 10 scripts/Makefile.gcc-plugins | 2 scripts/dummy-tools/gcc | 8 scripts/module.lds.S | 2 security/apparmor/apparmorfs.c | 2 security/apparmor/audit.c | 2 security/apparmor/domain.c | 2 security/apparmor/include/lib.h | 5 security/apparmor/include/policy.h | 2 security/apparmor/label.c | 13 security/apparmor/mount.c | 8 security/apparmor/policy_unpack.c | 12 sound/core/control.c | 7 sound/core/info.c | 6 sound/core/misc.c | 94 ++ sound/core/timer.c | 11 sound/pci/hda/patch_realtek.c | 1 sound/soc/codecs/tas2770.c | 98 +-- sound/soc/codecs/tas2770.h | 5 sound/soc/sof/intel/hda.c | 22 sound/usb/card.c | 8 sound/usb/mixer_maps.c | 34 - tools/build/feature/test-libcrypto.c | 15 tools/perf/util/probe-event.c | 6 tools/testing/selftests/ftrace/test.d/kprobe/kprobe_syntax_errors.tc | 1 tools/vm/slabinfo.c | 32 165 files changed, 1539 insertions(+), 1042 deletions(-)
Aaron Lu (1):
x86/mm: Use proper mask when setting PUD mapping
Al Viro (6):
nios2: page fault et.al. are *not* restartable syscalls...
nios2: don't leave NULLs in sys_call_table[]
nios2: traced syscall does need to check the syscall number
nios2: fix syscall restart checks
nios2: restarts apply only to the first sigframe we build...
nios2: add force_successful_syscall_return()
Alan Brady (1):
i40e: Fix to stop tx_timeout recovery if GLOBR fails
Amadeusz Sławiński (1):
ALSA: info: Fix llseek return value when using callback
Amelie Delaunay (1):
usb: dwc2: gadget: remove D+ pull-up while no vbus with usb-role-switch
Andrew Donnellan (1):
gcc-plugins: Undefine LATENT_ENTROPY_PLUGIN when plugin disabled for a file
Andy Shevchenko (1):
pinctrl: intel: Check against matching data instead of ACPI companion
Arun Ramadoss (1):
net: dsa: microchip: ksz9477: fix fdb_dump last invalid entry
Bard Liao (1):
ASoC: SOF: intel: move sof_intel_dsp_desc() forward
Bob Pearson (1):
RDMA/rxe: Limit the number of calls to each tasklet
Celeste Liu (1):
riscv: mmap with PROT_WRITE but no PROT_READ is invalid
Chao Yu (2):
f2fs: fix to avoid use f2fs_bug_on() in f2fs_new_node_page()
f2fs: fix to do sanity check on segment type in build_sit_entries()
Chen Lin (1):
dpaa2-eth: trace the allocated address instead of page struct
Chia-Lin Kao (AceLan) (1):
net: atlantic: fix aq_vec index out of range error
Christoffer Sandberg (1):
ALSA: hda/realtek: Add quirk for Clevo NS50PU, NS70PU
Christophe JAILLET (6):
mmc: pxamci: Fix another error handling path in pxamci_probe()
mmc: pxamci: Fix an error handling path in pxamci_probe()
mmc: meson-gx: Fix an error handling path in meson_mmc_probe()
perf probe: Fix an error handling path in 'parse_perf_probe_command()'
stmmac: intel: Add a missing clk_disable_unprepare() call in intel_eth_pci_remove()
cxl: Fix a memory leak in an error handling path
Christophe Leroy (1):
powerpc/32: Don't always pass -mcpu=powerpc to the compiler
Csókás Bence (1):
fec: Fix timer capture timing in fec_ptp_enable_pps()
Damien Le Moal (1):
ata: libata-eh: Add missing command name
Dan Aloni (1):
sunrpc: fix expiry of auth creds
Dan Carpenter (3):
NTB: ntb_tool: uninitialized heap data in tool_fn_write() xen/xenbus: fix return type in xenbus_file_read()
netfilter: nftables: fix a warning message in nf_tables_commit_audit_collect()
Dmitry Baryshkov (1):
dt-bindings: clock: qcom,gcc-msm8996: add more GCC clock sources
Dongliang Mu (1):
netfilter: nf_tables: fix audit memory leak in nf_tables_commit
Duoming Zhou (1):
atm: idt77252: fix use-after-free bugs caused by tst_timer
Fedor Pchelkin (2):
can: j1939: j1939_sk_queue_activate_next_locked(): replace WARN_ON_ONCE with netdev_warn_once()
can: j1939: j1939_session_destroy(): fix memory leak of skbs
Filipe Manana (1):
btrfs: fix lost error handling when looking up extended ref on log replay
Florian Westphal (1):
plip: avoid rcu debug splat
Frank Li (1):
usb: cdns3 fix use-after-free at workaround 2
Frieder Schrempf (1):
regulator: pca9450: Remove restrictions for regulator-name
Greg Kroah-Hartman (1):
Linux 5.10.138
Grzegorz Siwik (1):
ice: Ignore EEXIST when setting promisc mode
Guenter Roeck (1):
lib/list_debug.c: Detect uninitialized lists
Hector Martin (1):
locking/atomic: Make test_and_*_bit() ordered on failure
Helge Deller (1):
modules: Ensure natural alignment for .altinstructions and __bug_table sections
Hou Tao (5):
bpf: Acquire map uref in .init_seq_private for array map iterator
bpf: Acquire map uref in .init_seq_private for hash map iterator
bpf: Acquire map uref in .init_seq_private for sock local storage map iterator
bpf: Acquire map uref in .init_seq_private for sock{map,hash} iterator
bpf: Check the validity of max_rdwr_access for sock local storage map iterator
Huacai Chen (1):
PCI/ACPI: Guard ARM64-specific mcfg_quirks
Ido Schimmel (1):
devlink: Fix use-after-free after a failed reload
Jakub Kicinski (1):
net: genl: fix error path memory leak in policy dumping
James Smart (1):
scsi: lpfc: Prevent buffer overflow crashes in debugfs with malformed user input
Jason A. Donenfeld (1):
um: add "noreboot" command line option for PANIC_TIMEOUT=-1 setups
Jean-Philippe Brucker (1):
uacce: Handle parent device removal or parent driver module rmmod
Jeff Layton (1):
ceph: don't leak snap_rwsem in handle_cap_grant
Jens Wiklander (1):
tee: fix memory leak in tee_shm_register()
Jianhua Lu (1):
pinctrl: qcom: sm8250: Fix PDC map
John Johansen (5):
apparmor: fix quiet_denied for file rules
apparmor: fix absroot causing audited secids to begin with =
apparmor: Fix failed mount permission check error message
apparmor: fix setting unconfined mode on a loaded profile
apparmor: fix overlapping attachment computation
Jozef Martiniak (1):
gadgetfs: ep_io - wait until IRQ finishes
Keith Busch (1):
PCI/ERR: Retain status from error notification
Kiselev, Oleg (1):
ext4: avoid resizing to a partial cluster size
Krzysztof Kozlowski (1):
dt-bindings: arm: qcom: fix MSM8916 MTP compatibles
Laurent Dufour (1):
watchdog: export lockup_detector_reconfigure
Liang He (5):
drm/meson: Fix refcount bugs in meson_vpu_has_available_connectors()
usb: host: ohci-ppc-of: Fix refcount leak bug
usb: renesas: Fix refcount leak bug
tty: serial: Fix refcount leak bug in ucc_uart.c
mips: cavium-octeon: Fix missing of_node_put() in octeon2_usb_clocks_start
Liao Chang (1):
csky/kprobe: reclaim insn_slot on kprobe unregistration
Lin Ma (1):
igb: Add lock to avoid data race
Logan Gunthorpe (1):
md: Notify sysfs sync_completed in md_reap_sync_thread()
Luís Henriques (1):
ceph: use correct index when encoding client supported features
Marc Kleine-Budde (1):
can: ems_usb: fix clang's -Wunaligned-access warning
Martin Povišer (4):
ASoC: tas2770: Set correct FSYNC polarity
ASoC: tas2770: Allow mono streams
ASoC: tas2770: Drop conflicting set_bias_level power setting
ASoC: tas2770: Fix handling of mute/unmute
Masahiro Yamada (1):
kbuild: fix the modules order between drivers and libs
Matthew Wilcox (Oracle) (1):
qrtr: Convert qrtr_ports from IDR to XArray
Matthias May (3):
geneve: do not use RT_TOS for IPv6 flowlabel
ipv6: do not use RT_TOS for IPv6 flowlabel
geneve: fix TOS inheriting for ipv4
Miaoqian Lin (1):
pinctrl: nomadik: Fix refcount leak in nmk_pinctrl_dt_subnode_to_map
Michael Ellerman (1):
powerpc/pci: Fix get_phb_number() locking
Michael Grzeschik (1):
usb: gadget: uvc: call uvc uvcg_warn on completed status instead of uvcg_info
Mikulas Patocka (1):
rds: add missing barrier to release_refill
Nathan Chancellor (1):
MIPS: tlbex: Explicitly compare _PAGE_NO_EXEC against 0
Neil Armstrong (1):
spi: meson-spicc: add local pow2 clock ops to preserve rate between messages
Nikita Travkin (1):
pinctrl: qcom: msm8916: Allow CAMSS GP clocks to be muxed
Ondrej Mosnacek (1):
kbuild: dummy-tools: avoid tmpdir leak in dummy gcc
Pablo Neira Ayuso (5):
netfilter: nf_tables: really skip inactive sets when allocating name
netfilter: nf_tables: validate NFTA_SET_ELEM_OBJREF based on NFT_SET_OBJECT flag
netfilter: nf_tables: check NFT_SET_CONCAT flag if field_count is specified
netfilter: nftables: add helper function to set the base sequence number
netfilter: add helper function to set up the nfnetlink header and use it
Pascal Terjan (1):
vboxguest: Do not use devm for irq
Pavan Chebbi (1):
PCI: Add ACS quirk for Broadcom BCM5750x NICs
Peilin Ye (2):
vsock: Fix memory leak in vsock_connect()
vsock: Set socket state back to SS_UNCONNECTED in vsock_connect_timeout()
Przemyslaw Patynowski (1):
iavf: Fix adminq error handling
Qifu Zhang (1):
Documentation: ACPI: EINJ: Fix obsolete example
Richard Guy Briggs (1):
audit: log nftables configuration change events once per table
Robert Marko (1):
clk: qcom: ipq8074: dont disable gcc_sleep_clk_src
Roberto Sassu (1):
tools build: Switch to new openssl API for test-libcrypto
Rustam Subkhankulov (1):
net: dsa: sja1105: fix buffer overflow in sja1105_setup_devlink_regions()
Sagi Grimberg (1):
nvmet-tcp: fix lockdep complaint on nvmet_tcp_wq flush during queue teardown
Sai Prakash Ranjan (2):
irqchip/tegra: Fix overflow implicit truncation warnings drm/meson: Fix overflow implicit truncation warnings
Sakari Ailus (1):
ACPI: property: Return type of acpi_add_nondev_subnodes() should be bool
Samuel Holland (2):
pinctrl: sunxi: Add I/O bias setting for H6 R-PIO drm/sun4i: dsi: Prevent underflow when computing packet sizes
Sandor Bodo-Merle (1):
net: bgmac: Fix a BUG triggered by wrong bytes_compl
Schspa Shi (1):
vfio: Clear the caps->buf to NULL after free
Sebastian Würl (1):
can: mcp251x: Fix race condition on receive interrupt
Sergei Antonov (2):
net: dsa: mv88e6060: prevent crash on an unused port
net: moxa: pass pdev instead of ndev to DMA functions
Sergey Senozhatsky (1):
zram: do not lookup algorithm in backends table
Steve French (1):
smb3: check xattr value length earlier
Steven Rostedt (Google) (3):
tracing: Have filter accept "common_cpu" to be consistent selftests/kprobe: Do not test for GRP/ without event failures tracing/probes: Have kprobes and uprobes use $COMM too
Tadeusz Struk (1):
bpf: Fix KASAN use-after-free Read in compute_effective_progs
Takashi Iwai (4):
ALSA: usb-audio: More comprehensive mixer map for ASUS ROG Zenith II
ALSA: core: Add async signal helpers
ALSA: timer: Use deferred fasync helper
ALSA: control: Use deferred fasync helper
Tom Rix (1):
apparmor: fix aa_label_asxprint return check
Tony Lindgren (1):
clk: ti: Stop using legacy clkctrl names for omap4 and 5
Trond Myklebust (5):
NFSv4.1: Don't decrease the value of seq_nr_highest_sent NFSv4.1: Handle NFS4ERR_DELAY replies to OP_SEQUENCE correctly
NFSv4: Fix races in the legacy idmapper upcall NFSv4/pnfs: Fix a use-after-free bug in open
SUNRPC: Reinitialise the backchannel request buffers before reuse
Tzung-Bi Shih (1):
platform/chrome: cros_ec_proto: don't show MKBP version if unsupported
Uwe Kleine-König (2):
i2c: imx: Make sure to unregister adapter on remove()
dmaengine: sprd: Cleanup in .remove() after pm_runtime_get_sync() failed
Vladimir Oltean (1):
net: dsa: felix: fix ethtool 256-511 and 512-1023 TX packet counters
Vladimir Zapolskiy (1):
clk: qcom: clk-alpha-pll: fix clk_trion_pll_configure description
Wentao_Liang (1):
drivers:md:fix a potential use-after-free bug
Xianting Tian (1):
RISC-V: Add fast call path of crash_kexec()
Xin Xiong (1):
apparmor: fix reference count leak in aa_pivotroot()
Xiu Jianfeng (1):
apparmor: Fix memleak in aa_simple_write_to_buffer()
Xuan Zhuo (1):
virtio_net: fix memory leak inside XPD_TX with mergeable
Ye Bin (1):
ext4: avoid remove directory when directory is corrupted
Yu Xiao (1):
nfp: ethtool: fix the display error of ethtool -m DEVNAME
Yuanzheng Song (1):
tools/vm/slabinfo: use alphabetic order when two values are equal
Zhang Xianwei (1):
NFSv4.1: RECLAIM_COMPLETE must handle EACCES
Zheyu Ma (1):
video: fbdev: i740fb: Check the argument of i740_calc_vclk()
Zhouyi Zhou (1):
powerpc/64: Init jump labels before parse_early_param()
Greg Kroah-Hartman
maintainerDocumentation/atomic_bitops.txt +1 -1
@@ -59,7 +59,7 @@ Like with atomic_t, the rule of thumb is: - RMW operations that have a return value are fully ordered. - RMW operations that are conditional are unordered on FAILURE, - otherwise the above rules apply. In the case of test_and_{}_bit() operations, + otherwise the above rules apply. In the case of test_and_set_bit_lock(), if the bit in memory is unchanged by the operation then it is deemed to have failed.
Documentation/devicetree/bindings/arm/qcom.yaml +1 -1
@@ -123,8 +123,8 @@ properties: - const: qcom,msm8974 - items: - - const: qcom,msm8916-mtp/1 - const: qcom,msm8916-mtp + - const: qcom,msm8916-mtp/1 - const: qcom,msm8916 - items:
Documentation/devicetree/bindings/clock/qcom,gcc-msm8996.yaml +16 -0
@@ -22,16 +22,32 @@ properties: const: qcom,gcc-msm8996 clocks: + minItems: 3 items: - description: XO source - description: Second XO source - description: Sleep clock source + - description: PCIe 0 PIPE clock (optional) + - description: PCIe 1 PIPE clock (optional) + - description: PCIe 2 PIPE clock (optional) + - description: USB3 PIPE clock (optional) + - description: UFS RX symbol 0 clock (optional) + - description: UFS RX symbol 1 clock (optional) + - description: UFS TX symbol 0 clock (optional) clock-names: + minItems: 3 items: - const: cxo - const: cxo2 - const: sleep_clk + - const: pcie_0_pipe_clk_src + - const: pcie_1_pipe_clk_src + - const: pcie_2_pipe_clk_src + - const: usb3_phy_pipe_clk_src + - const: ufs_rx_symbol_0_clk_src + - const: ufs_rx_symbol_1_clk_src + - const: ufs_tx_symbol_0_clk_src '#clock-cells': const: 1
Documentation/devicetree/bindings/regulator/nxp,pca9450-regulator.yaml +0 -11
@@ -47,12 +47,6 @@ properties: description: Properties for single LDO regulator. - properties: - regulator-name: - pattern: "^LDO[1-5]$" - description: - should be "LDO1", ..., "LDO5" - unevaluatedProperties: false "^BUCK[1-6]$":
@@ -62,11 +56,6 @@ properties: Properties for single BUCK regulator. properties: - regulator-name: - pattern: "^BUCK[1-6]$" - description: - should be "BUCK1", ..., "BUCK6" - nxp,dvs-run-voltage: $ref: "/schemas/types.yaml#/definitions/uint32" minimum: 600000
Documentation/firmware-guide/acpi/apei/einj.rst +1 -1
@@ -168,7 +168,7 @@ An error injection example:: 0x00000008 Memory Correctable 0x00000010 Memory Uncorrectable non-fatal # echo 0x12345000 > param1 # Set memory address for injection - # echo $((-1 << 12)) > param2 # Mask 0xfffffffffffff000 - anywhere in this page + # echo 0xfffffffffffff000 > param2 # Mask - anywhere in this page # echo 0x8 > error_type # Choose correctable memory error # echo 1 > error_inject # Inject now
Makefile +3 -5
@@ -1,7 +1,7 @@ # SPDX-License-Identifier: GPL-2.0 VERSION = 5 PATCHLEVEL = 10 -SUBLEVEL = 137 +SUBLEVEL = 138 EXTRAVERSION = NAME = Dare mighty things
@@ -1133,13 +1133,11 @@ vmlinux-alldirs := $(sort $(vmlinux-dirs) Documentation \ $(patsubst %/,%,$(filter %/, $(core-) \ $(drivers-) $(libs-)))) -subdir-modorder := $(addsuffix modules.order,$(filter %/, \ - $(core-y) $(core-m) $(libs-y) $(libs-m) \ - $(drivers-y) $(drivers-m))) - build-dirs := $(vmlinux-dirs) clean-dirs := $(vmlinux-alldirs) +subdir-modorder := $(addsuffix /modules.order, $(build-dirs)) + # Externally visible symbols (used by link-vmlinux.sh) KBUILD_VMLINUX_OBJS := $(head-y) $(patsubst %/,%/built-in.a, $(core-y)) KBUILD_VMLINUX_OBJS += $(addsuffix built-in.a, $(filter %/, $(libs-y)))
arch/csky/kernel/probes/kprobes.c +4 -0
@@ -124,6 +124,10 @@ void __kprobes arch_disarm_kprobe(struct kprobe *p)void __kprobes arch_remove_kprobe (struct kprobe *p) { +if (p->ainsn.api.insn) { +free_insn_slot (p->ainsn.api.insn,0 ); + p->ainsn.api.insn =NULL ; + } }static void __kprobes save_previous_kprobe (struct kprobe_ctlblk *kcb)
arch/mips/cavium-octeon/octeon-platform.c +2 -1
@@ -86,11 +86,12 @@ static void octeon2_usb_clocks_start(struct device *dev) "refclk-frequency", &clock_rate);if (i) {dev_err (dev,"No UCTL \"refclk-frequency\"\n" ); +of_node_put (uctl_node); goto exit; } i =of_property_read_string (uctl_node,"refclk-type" , &clock_type); - +of_node_put (uctl_node);if (!i &&strcmp ("crystal" , clock_type) ==0 ) is_crystal_clock = true; }
arch/mips/mm/tlbex.c +2 -2
@@ -633,7 +633,7 @@ static __maybe_unused void build_convert_pte_to_entrylo(u32 **p,return ; } -if (cpu_has_rixi && !!_PAGE_NO_EXEC) { +if (cpu_has_rixi && _PAGE_NO_EXEC !=0 ) {if (fill_includes_sw_bits) {UASM_i_ROTR (p, reg, reg,ilog2 (_PAGE_GLOBAL)); }else {
@@ -2572,7 +2572,7 @@ static void check_pabits(void)unsigned long entry;unsigned pabits, fillbits; -if (!cpu_has_rixi || !_PAGE_NO_EXEC) { +if (!cpu_has_rixi || _PAGE_NO_EXEC ==0 ) {/* * We'll only be making use of the fact that we can rotate bits * into the fill if the CPU supports RIXI, so don't bother
arch/nios2/include/asm/entry.h +2 -1
@@ -50,7 +50,8 @@ stw r13, PT_R13(sp) stw r14, PT_R14(sp) stw r15, PT_R15(sp) - stw r2, PT_ORIG_R2(sp) + movi r24, -1 + stw r24, PT_ORIG_R2(sp) stw r7, PT_ORIG_R7(sp) stw ra, PT_RA(sp)
arch/nios2/include/asm/ptrace.h +2 -0
@@ -74,6 +74,8 @@ extern void show_regs(struct pt_regs *); ((struct pt_regs *)((unsigned long )current_thread_info () +THREAD_SIZE )\ - 1) +#define force_successful_syscall_return () (current_pt_regs()->orig_r2 = -1) +int do_syscall_trace_enter (void );void do_syscall_trace_exit (void );#endif /* __ASSEMBLY__ */
arch/nios2/kernel/entry.S +15 -7
@@ -185,6 +185,7 @@ ENTRY(handle_system_call) ldw r5, PT_R5(sp) local_restart: + stw r2, PT_ORIG_R2(sp) /* Check that the requested system call is within limits */ movui r1, __NR_syscalls bgeu r2, r1, ret_invsyscall
@@ -192,7 +193,6 @@ local_restart: movhi r11, %hiadj(sys_call_table) add r1, r1, r11 ldw r1, %lo(sys_call_table)(r1) - beq r1, r0, ret_invsyscall /* Check if we are being traced */ GET_THREAD_INFO r11
@@ -213,6 +213,9 @@ local_restart: translate_rc_and_ret: movi r1, 0 bge r2, zero, 3f + ldw r1, PT_ORIG_R2(sp) + addi r1, r1, 1 + beq r1, zero, 3f sub r2, zero, r2 movi r1, 1 3:
@@ -255,9 +258,9 @@ traced_system_call: ldw r6, PT_R6(sp) ldw r7, PT_R7(sp) - /* Fetch the syscall function, we don't need to check the boundaries - * since this is already done. - */ + /* Fetch the syscall function. */ + movui r1, __NR_syscalls + bgeu r2, r1, traced_invsyscall slli r1, r2, 2 movhi r11,%hiadj(sys_call_table) add r1, r1, r11
@@ -276,6 +279,9 @@ traced_system_call: translate_rc_and_ret2: movi r1, 0 bge r2, zero, 4f + ldw r1, PT_ORIG_R2(sp) + addi r1, r1, 1 + beq r1, zero, 4f sub r2, zero, r2 movi r1, 1 4:
@@ -287,6 +293,11 @@ end_translate_rc_and_ret2: RESTORE_SWITCH_STACK br ret_from_exception + /* If the syscall number was invalid return ENOSYS */ +traced_invsyscall: + movi r2, -ENOSYS + br translate_rc_and_ret2 + Luser_return: GET_THREAD_INFO r11 /* get thread_info pointer */ ldw r10, TI_FLAGS(r11) /* get thread_info->flags */
@@ -336,9 +347,6 @@ external_interrupt: /* skip if no interrupt is pending */ beq r12, r0, ret_from_interrupt - movi r24, -1 - stw r24, PT_ORIG_R2(sp) - /* * Process an external hardware interrupt. */
arch/nios2/kernel/signal.c +2 -1
@@ -242,7 +242,7 @@ static int do_signal(struct pt_regs *regs)/* * If we were from a system call, check for system call restarting... */ -if (regs->orig_r2 >=0 ) { +if (regs->orig_r2 >=0 && regs->r1) { continue_addr = regs->ea; restart_addr = continue_addr -4 ; retval = regs->r2;
@@ -264,6 +264,7 @@ static int do_signal(struct pt_regs *regs) regs->ea = restart_addr;break ; } + regs->orig_r2 =-1 ; }if (get_signal (&ksig)) {
arch/nios2/kernel/syscall_table.c +1 -0
@@ -13,5 +13,6 @@#define __SYSCALL (nr, call) [nr] = (call),void *sys_call_table[__NR_syscalls] = { + [0 ... __NR_syscalls-1 ] = sys_ni_syscall, #include <asm/unistd.h> };
arch/powerpc/Makefile +1 -25
@@ -17,23 +17,6 @@ HAS_BIARCH := $(call cc-option-yn, -m32) # Set default 32 bits cross compilers for vdso and boot wrapper CROSS32_COMPILE ?= -ifeq ($(HAS_BIARCH),y) -ifeq ($(CROSS32_COMPILE),) -ifdef CONFIG_PPC32 -# These options will be overridden by any -mcpu option that the CPU -# or platform code sets later on the command line, but they are needed -# to set a sane 32-bit cpu target for the 64-bit cross compiler which -# may default to the wrong ISA. -KBUILD_CFLAGS += -mcpu=powerpc -KBUILD_AFLAGS += -mcpu=powerpc -endif -endif -endif - -ifdef CONFIG_PPC_BOOK3S_32 -KBUILD_CFLAGS += -mcpu=powerpc -endif - # If we're on a ppc/ppc64/ppc64le machine use that defconfig, otherwise just use # ppc64_defconfig because we have nothing better to go on. uname := $(shell uname -m)
@@ -190,6 +173,7 @@ endif endif CFLAGS-$(CONFIG_TARGET_CPU_BOOL) += $(call cc-option,-mcpu=$(CONFIG_TARGET_CPU)) +AFLAGS-$(CONFIG_TARGET_CPU_BOOL) += $(call cc-option,-mcpu=$(CONFIG_TARGET_CPU)) # Altivec option not allowed with e500mc64 in GCC. ifdef CONFIG_ALTIVEC
@@ -200,14 +184,6 @@ endif CFLAGS-$(CONFIG_E5500_CPU) += $(E5500_CPU) CFLAGS-$(CONFIG_E6500_CPU) += $(call cc-option,-mcpu=e6500,$(E5500_CPU)) -ifdef CONFIG_PPC32 -ifdef CONFIG_PPC_E500MC -CFLAGS-y += $(call cc-option,-mcpu=e500mc,-mcpu=powerpc) -else -CFLAGS-$(CONFIG_E500) += $(call cc-option,-mcpu=8540 -msoft-float,-mcpu=powerpc) -endif -endif - asinstr := $(call as-instr,lis 9$(comma)foo@high,-DHAVE_AS_ATHIGH=1) KBUILD_CPPFLAGS += -I $(srctree)/arch/$(ARCH) $(asinstr)
arch/powerpc/kernel/pci-common.c +10 -6
@@ -66,10 +66,6 @@ void set_pci_dma_ops(const struct dma_map_ops *dma_ops) pci_dma_ops = dma_ops; } -/* -* This function should run under locking protection, specifically -* hose_spinlock. -*/ static int get_phb_number (struct device_node *dn) {int ret, phb_id =-1 ;
@@ -106,15 +102,20 @@ static int get_phb_number(struct device_node *dn)if (!ret) phb_id = (int )(prop & (MAX_PHBS -1 )); +spin_lock (&hose_spinlock); +/* We need to be sure to not use the same PHB number twice. */ if ((phb_id >=0 ) && !test_and_set_bit (phb_id, phb_bitmap)) -return phb_id; + goto out_unlock;/* If everything fails then fallback to dynamic PHB numbering. */ phb_id =find_first_zero_bit (phb_bitmap,MAX_PHBS );BUG_ON (phb_id >=MAX_PHBS );set_bit (phb_id, phb_bitmap); +out_unlock: +spin_unlock (&hose_spinlock); +return phb_id; }
@@ -125,10 +126,13 @@ struct pci_controller *pcibios_alloc_controller(struct device_node *dev) phb =zalloc_maybe_bootmem (sizeof (struct pci_controller ),GFP_KERNEL );if (phb ==NULL )return NULL ; -spin_lock (&hose_spinlock); + phb->global_number =get_phb_number (dev); + +spin_lock (&hose_spinlock);list_add_tail (&phb->list_node, &hose_list);spin_unlock (&hose_spinlock); + phb->dn = dev; phb->is_dynamic =slab_is_available ();#ifdef CONFIG_PPC64
arch/powerpc/kernel/prom.c +7 -0
@@ -750,6 +750,13 @@ void __init early_init_devtree(void *params)of_scan_flat_dt (early_init_dt_scan_root,NULL );of_scan_flat_dt (early_init_dt_scan_memory_ppc,NULL ); +/* +* As generic code authors expect to be able to use static keys +* in early_param() handlers, we initialize the static keys just +* before parsing early params (it's fine to call jump_label_init() +* more than once). +*/ +jump_label_init ();parse_early_param ();/* make sure we've parsed cmdline for mem= before this */
arch/powerpc/platforms/Kconfig.cputype +18 -3
@@ -119,9 +119,9 @@ config GENERIC_CPU depends on PPC64 && CPU_LITTLE_ENDIAN select ARCH_HAS_FAST_MULTIPLIER -config GENERIC_CPU +config POWERPC_CPU bool "Generic 32 bits powerpc" - depends on PPC32 && !PPC_8xx + depends on PPC32 && !PPC_8xx && !PPC_85xx config CELL_CPU bool "Cell Broadband Engine"
@@ -175,11 +175,23 @@ config G4_CPU depends on PPC_BOOK3S_32 select ALTIVEC +config E500_CPU + bool "e500 (8540)" + depends on PPC_85xx && !PPC_E500MC + +config E500MC_CPU + bool "e500mc" + depends on PPC_85xx && PPC_E500MC + +config TOOLCHAIN_DEFAULT_CPU + bool "Rely on the toolchain's implicit default CPU" + depends on PPC32 + endchoice config TARGET_CPU_BOOL bool - default !GENERIC_CPU + default !GENERIC_CPU && !TOOLCHAIN_DEFAULT_CPU config TARGET_CPU string
@@ -194,6 +206,9 @@ config TARGET_CPU default "e300c2" if E300C2_CPU default "e300c3" if E300C3_CPU default "G4" if G4_CPU + default "8540" if E500_CPU + default "e500mc" if E500MC_CPU + default "powerpc" if POWERPC_CPU config PPC_BOOK3S def_bool y
arch/riscv/kernel/sys_riscv.c +2 -3
@@ -18,9 +18,8 @@ static long riscv_sys_mmap(unsigned long addr, unsigned long len,if (unlikely (offset & (~PAGE_MASK >> page_shift_offset)))return -EINVAL ; -if ((prot &PROT_WRITE ) && (prot &PROT_EXEC )) -if (unlikely (!(prot &PROT_READ ))) -return -EINVAL ; +if (unlikely ((prot &PROT_WRITE ) && !(prot &PROT_READ ))) +return -EINVAL ;return ksys_mmap_pgoff (addr, len, prot, flags, fd, offset >> (PAGE_SHIFT - page_shift_offset));
arch/riscv/kernel/traps.c +4 -0
@@ -15,6 +15,7 @@#include <linux/mm.h> #include <linux/module.h> #include <linux/irq.h> +#include <linux/kexec.h> #include <asm/processor.h> #include <asm/ptrace.h>
@@ -43,6 +44,9 @@ void die(struct pt_regs *regs, const char *str) ret =notify_die (DIE_OOPS , str, regs,0 , regs->cause,SIGSEGV ); +if (regs &&kexec_should_crash (current)) +crash_kexec (regs); +bust_spinlocks (0 );add_taint (TAINT_DIE ,LOCKDEP_NOW_UNRELIABLE );spin_unlock_irq (&die_lock);
arch/um/os-Linux/skas/process.c +16 -1
@@ -5,6 +5,7 @@*/ #include <stdlib.h> +#include <stdbool.h> #include <unistd.h> #include <sched.h> #include <errno.h>
@@ -644,10 +645,24 @@ void halt_skas(void)UML_LONGJMP (&initial_jmpbuf,INIT_JMP_HALT ); } +static bool noreboot; + +static int __init noreboot_cmd_param (char *str,int *add) +{ + noreboot = true; +return 0 ; +} + +__uml_setup ("noreboot" , noreboot_cmd_param, +"noreboot\n" +" Rather than rebooting, exit always, akin to QEMU's -no-reboot option.\n" +" This is useful if you're using CONFIG_PANIC_TIMEOUT in order to catch\n" +" crashes in CI\n" ); +void reboot_skas (void ) {block_signals_trace (); -UML_LONGJMP (&initial_jmpbuf,INIT_JMP_REBOOT ); +UML_LONGJMP (&initial_jmpbuf, noreboot ?INIT_JMP_HALT :INIT_JMP_REBOOT ); }void __switch_mm (struct mm_id *mm_idp)
arch/x86/mm/init_64.c +1 -1
@@ -645,7 +645,7 @@ phys_pud_init(pud_t *pud_page, unsigned long paddr, unsigned long paddr_end, pages++;spin_lock (&init_mm.page_table_lock); - prot =__pgprot (pgprot_val (prot) | __PAGE_KERNEL_LARGE); + prot =__pgprot (pgprot_val (prot) | _PAGE_PSE); set_pte_init((pte_t *)pud, pfn_pte((paddr & PUD_MASK) >> PAGE_SHIFT,
drivers/acpi/pci_mcfg.c +3 -0
@@ -41,6 +41,8 @@ struct mcfg_fixup { static struct mcfg_fixup mcfg_quirks[] = {/* { OEM_ID, OEM_TABLE_ID, REV, SEGMENT, BUS_RANGE, ops, cfgres }, */ +#ifdef CONFIG_ARM64 +#define AL_ECAM (table_id, rev, seg, ops) \ { "AMAZON", table_id, rev, seg, MCFG_BUS_ANY, ops }
@@ -162,6 +164,7 @@ static struct mcfg_fixup mcfg_quirks[] = {ALTRA_ECAM_QUIRK (1 ,13 ),ALTRA_ECAM_QUIRK (1 ,14 ), ALTRA_ECAM_QUIRK(1, 15), +#endif /* ARM64 */ };static char mcfg_oem_id[ACPI_OEM_ID_SIZE ];
drivers/acpi/property.c +4 -4
@@ -155,10 +155,10 @@ static bool acpi_nondev_subnode_ok(acpi_handle scope,return acpi_nondev_subnode_data_ok (handle, link, list, parent); } -static int acpi_add_nondev_subnodes (acpi_handle scope, -const union acpi_object *links, -struct list_head *list, -struct fwnode_handle *parent) +static bool acpi_add_nondev_subnodes (acpi_handle scope, +const union acpi_object *links, +struct list_head *list, +struct fwnode_handle *parent) {bool ret = false;int i;
drivers/ata/libata-eh.c +1 -0
@@ -2131,6 +2131,7 @@ const char *ata_get_cmd_descript(u8 command) { ATA_CMD_WRITE_QUEUED_FUA_EXT, "WRITE DMA QUEUED FUA EXT" }, { ATA_CMD_FPDMA_READ, "READ FPDMA QUEUED" }, { ATA_CMD_FPDMA_WRITE, "WRITE FPDMA QUEUED" }, + { ATA_CMD_NCQ_NON_DATA, "NCQ NON-DATA" }, { ATA_CMD_FPDMA_SEND, "SEND FPDMA QUEUED" }, { ATA_CMD_FPDMA_RECV, "RECEIVE FPDMA QUEUED" }, { ATA_CMD_PIO_READ, "READ SECTOR(S)" },
drivers/atm/idt77252.c +1 -0
@@ -3767,6 +3767,7 @@ static void __exit idt77252_exit(void) card = idt77252_chain; dev = card->atmdev; idt77252_chain = card->next; +del_timer_sync (&card->tst_timer);if (dev->phy->stop) dev->phy->stop (dev);
drivers/block/zram/zcomp.c +5 -6
@@ -61,12 +61,6 @@ static int zcomp_strm_init(struct zcomp_strm *zstrm, struct zcomp *comp)bool zcomp_available_algorithm (const char *comp) { -int i; - - i =sysfs_match_string (backends, comp); -if (i >=0 ) -return true; -/* * Crypto does not ignore a trailing new line symbol, * so make sure you don't supply a string containing
@@ -215,6 +209,11 @@ struct zcomp *zcomp_create(const char *compress)struct zcomp *comp;int error; +/* +* Crypto API will execute /sbin/modprobe if the compression module +* is not loaded yet. We must do it here, otherwise we are about to +* call /sbin/modprobe under CPU hot-plug lock. +*/ if (!zcomp_available_algorithm (compress))return ERR_PTR (-EINVAL );
drivers/clk/qcom/clk-alpha-pll.c +1 -1
@@ -1379,7 +1379,7 @@ const struct clk_ops clk_alpha_pll_postdiv_fabia_ops = {EXPORT_SYMBOL_GPL (clk_alpha_pll_postdiv_fabia_ops);/** -* clk_lucid_pll_configure - configure the lucid pll +* clk_trion_pll_configure - configure the trion pll * * @pll: clk alpha pll * @regmap: register map
drivers/clk/qcom/gcc-ipq8074.c +1 -0
@@ -662,6 +662,7 @@ static struct clk_branch gcc_sleep_clk_src = { }, .num_parents = 1, .ops = &clk_branch2_ops, + .flags = CLK_IS_CRITICAL, }, }, };
drivers/clk/ti/clk-44xx.c +105 -105
339 lines not on this page · raw message
drivers/clk/ti/clk-54xx.c +80 -80
249 lines not on this page · raw message
drivers/clk/ti/clkctrl.c +0 -4
@@ -511,10 +511,6 @@ static void __init _ti_omap4_clkctrl_setup(struct device_node *node)char *c;u16 soc_mask =0 ; -if (!(ti_clk_get_features ()->flags &TI_CLK_CLKCTRL_COMPAT ) && -of_node_name_eq (node,"clk" )) - ti_clk_features.flags |=TI_CLK_CLKCTRL_COMPAT ; - addrp =of_get_address (node,0 ,NULL ,NULL ); addr = (u32 )of_translate_address (node, addrp);
drivers/dma/sprd-dma.c +1 -4
@@ -1236,11 +1236,8 @@ static int sprd_dma_remove(struct platform_device *pdev) {struct sprd_dma_dev *sdev =platform_get_drvdata (pdev);struct sprd_dma_chn *c, *cn; -int ret; - ret =pm_runtime_get_sync (&pdev->dev); -if (ret <0 ) -return ret; +pm_runtime_get_sync (&pdev->dev);/* explicitly free the irq */ if (sdev->irq >0 )
drivers/gpu/drm/meson/meson_drv.c +4 -1
@@ -116,8 +116,11 @@ static bool meson_vpu_has_available_connectors(struct device *dev)for_each_endpoint_of_node (dev->of_node, ep) {/* If the endpoint node exists, consider it enabled */ remote =of_graph_get_remote_port (ep); -if (remote) +if (remote) { +of_node_put (remote); +of_node_put (ep);return true; + } }return false;
drivers/gpu/drm/meson/meson_viu.c +11 -11
@@ -469,17 +469,17 @@ void meson_viu_init(struct meson_drm *priv) priv->io_base + _REG(VD2_IF0_LUMA_FIFO_SIZE));if (meson_vpu_is_compatible (priv,VPU_COMPATIBLE_G12A )) { -writel_relaxed (VIU_OSD_BLEND_REORDER (0 ,1 ) | -VIU_OSD_BLEND_REORDER (1 ,0 ) | -VIU_OSD_BLEND_REORDER (2 ,0 ) | -VIU_OSD_BLEND_REORDER (3 ,0 ) | -VIU_OSD_BLEND_DIN_EN (1 ) | -VIU_OSD_BLEND1_DIN3_BYPASS_TO_DOUT1 | -VIU_OSD_BLEND1_DOUT_BYPASS_TO_BLEND2 | -VIU_OSD_BLEND_DIN0_BYPASS_TO_DOUT0 | -VIU_OSD_BLEND_BLEN2_PREMULT_EN (1 ) | -VIU_OSD_BLEND_HOLD_LINES (4 ), - priv->io_base +_REG (VIU_OSD_BLEND_CTRL )); +u32 val = (u32 )VIU_OSD_BLEND_REORDER (0 ,1 ) | + (u32 )VIU_OSD_BLEND_REORDER (1 ,0 ) | + (u32 )VIU_OSD_BLEND_REORDER (2 ,0 ) | + (u32 )VIU_OSD_BLEND_REORDER (3 ,0 ) | + (u32 )VIU_OSD_BLEND_DIN_EN (1 ) | + (u32 )VIU_OSD_BLEND1_DIN3_BYPASS_TO_DOUT1 | + (u32 )VIU_OSD_BLEND1_DOUT_BYPASS_TO_BLEND2 | + (u32 )VIU_OSD_BLEND_DIN0_BYPASS_TO_DOUT0 | + (u32 )VIU_OSD_BLEND_BLEN2_PREMULT_EN (1 ) | + (u32 )VIU_OSD_BLEND_HOLD_LINES (4 ); +writel_relaxed (val, priv->io_base +_REG (VIU_OSD_BLEND_CTRL ));writel_relaxed (OSD_BLEND_PATH_SEL_ENABLE , priv->io_base +_REG (OSD1_BLEND_SRC_CTRL ));
drivers/gpu/drm/sun4i/sun6i_mipi_dsi.c +5 -5
@@ -531,7 +531,7 @@ static void sun6i_dsi_setup_timings(struct sun6i_dsi *dsi, struct drm_display_mode *mode) {struct mipi_dsi_device *device = dsi->device; -unsigned int Bpp =mipi_dsi_pixel_format_to_bpp (device->format) /8 ; +int Bpp =mipi_dsi_pixel_format_to_bpp (device->format) /8 ;u16 hbp =0 , hfp =0 , hsa =0 , hblk =0 , vblk =0 ;u32 basic_ctl =0 ;size_t bytes;
@@ -555,7 +555,7 @@ static void sun6i_dsi_setup_timings(struct sun6i_dsi *dsi,* (4 bytes). Its minimal size is therefore 10 bytes */ #define HSA_PACKET_OVERHEAD 10 - hsa =max ((unsigned int )HSA_PACKET_OVERHEAD , + hsa =max (HSA_PACKET_OVERHEAD , (mode->hsync_end - mode->hsync_start) * Bpp -HSA_PACKET_OVERHEAD );/*
@@ -564,7 +564,7 @@ static void sun6i_dsi_setup_timings(struct sun6i_dsi *dsi,* therefore 6 bytes */ #define HBP_PACKET_OVERHEAD 6 - hbp =max ((unsigned int )HBP_PACKET_OVERHEAD , + hbp =max (HBP_PACKET_OVERHEAD , (mode->htotal - mode->hsync_end) * Bpp -HBP_PACKET_OVERHEAD );/*
@@ -574,7 +574,7 @@ static void sun6i_dsi_setup_timings(struct sun6i_dsi *dsi,* 16 bytes */ #define HFP_PACKET_OVERHEAD 16 - hfp =max ((unsigned int )HFP_PACKET_OVERHEAD , + hfp =max (HFP_PACKET_OVERHEAD , (mode->hsync_start - mode->hdisplay) * Bpp -HFP_PACKET_OVERHEAD );/*
@@ -583,7 +583,7 @@ static void sun6i_dsi_setup_timings(struct sun6i_dsi *dsi,* bytes). Its minimal size is therefore 10 bytes. */ #define HBLK_PACKET_OVERHEAD 10 - hblk =max ((unsigned int )HBLK_PACKET_OVERHEAD , + hblk =max (HBLK_PACKET_OVERHEAD , (mode->htotal - (mode->hsync_end - mode->hsync_start)) * Bpp -HBLK_PACKET_OVERHEAD );
drivers/i2c/busses/i2c-imx.c +11 -9
@@ -1280,9 +1280,7 @@ static int i2c_imx_remove(struct platform_device *pdev)struct imx_i2c_struct *i2c_imx =platform_get_drvdata (pdev);int irq, ret; - ret =pm_runtime_resume_and_get (&pdev->dev); -if (ret <0 ) -return ret; + ret =pm_runtime_get_sync (&pdev->dev);/* remove adapter */ dev_dbg (&i2c_imx->adapter.dev,"adapter removed\n" );
@@ -1291,17 +1289,21 @@ static int i2c_imx_remove(struct platform_device *pdev)if (i2c_imx->dma)i2c_imx_dma_free (i2c_imx); -/* setup chip registers to defaults */ -imx_i2c_write_reg (0 , i2c_imx,IMX_I2C_IADR ); -imx_i2c_write_reg (0 , i2c_imx,IMX_I2C_IFDR ); -imx_i2c_write_reg (0 , i2c_imx,IMX_I2C_I2CR ); -imx_i2c_write_reg (0 , i2c_imx,IMX_I2C_I2SR ); +if (ret ==0 ) { +/* setup chip registers to defaults */ +imx_i2c_write_reg (0 , i2c_imx,IMX_I2C_IADR ); +imx_i2c_write_reg (0 , i2c_imx,IMX_I2C_IFDR ); +imx_i2c_write_reg (0 , i2c_imx,IMX_I2C_I2CR ); +imx_i2c_write_reg (0 , i2c_imx,IMX_I2C_I2SR ); +clk_disable (i2c_imx->clk); + }clk_notifier_unregister (i2c_imx->clk, &i2c_imx->clk_change_nb); irq =platform_get_irq (pdev,0 );if (irq >=0 )free_irq (irq, i2c_imx); -clk_disable_unprepare (i2c_imx->clk); + +clk_unprepare (i2c_imx->clk);pm_runtime_put_noidle (&pdev->dev);pm_runtime_disable (&pdev->dev);
drivers/infiniband/sw/rxe/rxe_param.h +6 -0
@@ -98,6 +98,12 @@ enum rxe_device_param {RXE_INFLIGHT_SKBS_PER_QP_HIGH =64 ,RXE_INFLIGHT_SKBS_PER_QP_LOW =16 , +/* Max number of interations of each tasklet +* before yielding the cpu to let other +* work make progress +*/ +RXE_MAX_ITERATIONS =1024 , +/* Delay before calling arbiter timer */ RXE_NSEC_ARB_TIMER_DELAY = 200,
drivers/infiniband/sw/rxe/rxe_task.c +12 -4
@@ -8,7 +8,7 @@#include <linux/interrupt.h> #include <linux/hardirq.h> -#include "rxe_task.h" +#include "rxe.h" int __rxe_do_task (struct rxe_task *task)
@@ -34,6 +34,7 @@ void rxe_do_task(struct tasklet_struct *t)int ret;unsigned long flags;struct rxe_task *task =from_tasklet (task, t, tasklet); +unsigned int iterations =RXE_MAX_ITERATIONS ;spin_lock_irqsave (&task->state_lock, flags);switch (task->state) {
@@ -62,13 +63,20 @@ void rxe_do_task(struct tasklet_struct *t)spin_lock_irqsave (&task->state_lock, flags);switch (task->state) {case TASK_STATE_BUSY : -if (ret) +if (ret) { task->state =TASK_STATE_START ; -else + }else if (iterations--) { cont =1 ; + }else { +/* reschedule the tasklet and exit +* the loop to give up the cpu +*/ +tasklet_schedule (&task->tasklet); + task->state =TASK_STATE_START ; + }break ; -/* soneone tried to run the task since the last time we called +/* someone tried to run the task since the last time we called * func, so we will call one more time regardless of the * return value */
drivers/irqchip/irq-tegra.c +5 -5
@@ -148,10 +148,10 @@ static int tegra_ictlr_suspend(void) lic->cop_iep[i] =readl_relaxed (ictlr +ICTLR_COP_IEP_CLASS );/* Disable COP interrupts */ -writel_relaxed (~0ul , ictlr +ICTLR_COP_IER_CLR ); +writel_relaxed (GENMASK (31 ,0 ), ictlr +ICTLR_COP_IER_CLR );/* Disable CPU interrupts */ -writel_relaxed (~0ul , ictlr +ICTLR_CPU_IER_CLR ); +writel_relaxed (GENMASK (31 ,0 ), ictlr +ICTLR_CPU_IER_CLR );/* Enable the wakeup sources of ictlr */ writel_relaxed (lic->ictlr_wake_mask[i], ictlr +ICTLR_CPU_IER_SET );
@@ -172,12 +172,12 @@ static void tegra_ictlr_resume(void)writel_relaxed (lic->cpu_iep[i], ictlr +ICTLR_CPU_IEP_CLASS ); -writel_relaxed (~0ul , ictlr +ICTLR_CPU_IER_CLR ); +writel_relaxed (GENMASK (31 ,0 ), ictlr +ICTLR_CPU_IER_CLR );writel_relaxed (lic->cpu_ier[i], ictlr +ICTLR_CPU_IER_SET );writel_relaxed (lic->cop_iep[i], ictlr +ICTLR_COP_IEP_CLASS ); -writel_relaxed (~0ul , ictlr +ICTLR_COP_IER_CLR ); +writel_relaxed (GENMASK (31 ,0 ), ictlr +ICTLR_COP_IER_CLR );writel_relaxed (lic->cop_ier[i], ictlr +ICTLR_COP_IER_SET ); }
@@ -312,7 +312,7 @@ static int __init tegra_ictlr_init(struct device_node *node, lic->base[i] = base;/* Disable all interrupts */ -writel_relaxed (~0UL , base +ICTLR_CPU_IER_CLR ); +writel_relaxed (GENMASK (31 ,0 ), base +ICTLR_CPU_IER_CLR );/* All interrupts target IRQ */ writel_relaxed (0 , base +ICTLR_CPU_IEP_CLASS );
drivers/md/md.c +1 -0
@@ -9424,6 +9424,7 @@ void md_reap_sync_thread(struct mddev *mddev)wake_up (&resync_wait);/* flag recovery needed just to double check */ set_bit (MD_RECOVERY_NEEDED , &mddev->recovery); +sysfs_notify_dirent_safe (mddev->sysfs_completed);sysfs_notify_dirent_safe (mddev->sysfs_action);md_new_event (mddev);if (mddev->event_work.func)
drivers/md/raid5.c +1 -1
@@ -2864,10 +2864,10 @@ static void raid5_end_write_request(struct bio *bi)if (!test_and_clear_bit (R5_DOUBLE_LOCKED , &sh->dev[i].flags))clear_bit (R5_LOCKED , &sh->dev[i].flags);set_bit (STRIPE_HANDLE , &sh->state); -raid5_release_stripe (sh);if (sh->batch_head && sh != sh->batch_head)raid5_release_stripe (sh->batch_head); +raid5_release_stripe (sh); }static void raid5_error (struct mddev *mddev,struct md_rdev *rdev)
drivers/misc/cxl/irq.c +1 -0
@@ -349,6 +349,7 @@ int afu_allocate_irqs(struct cxl_context *ctx, u32 count) out: cxl_ops->release_irq_ranges (&ctx->irqs, ctx->afu->adapter); +bitmap_free (ctx->irq_bitmap);afu_irq_name_free (ctx);return -ENOMEM ; }
drivers/misc/uacce/uacce.c +87 -46
252 lines not on this page · raw message
drivers/mmc/host/meson-gx-mmc.c +4 -2
@@ -1161,8 +1161,10 @@ static int meson_mmc_probe(struct platform_device *pdev) } ret =device_reset_optional (&pdev->dev); -if (ret) -return dev_err_probe (&pdev->dev, ret,"device reset failed\n" ); +if (ret) { +dev_err_probe (&pdev->dev, ret,"device reset failed\n" ); + goto free_host; + } res =platform_get_resource (pdev,IORESOURCE_MEM ,0 ); host->regs =devm_ioremap_resource (&pdev->dev, res);
drivers/mmc/host/pxamci.c +2 -2
@@ -648,7 +648,7 @@ static int pxamci_probe(struct platform_device *pdev) ret =pxamci_of_init (pdev, mmc);if (ret) -return ret; + goto out; host =mmc_priv (mmc); host->mmc = mmc;
@@ -672,7 +672,7 @@ static int pxamci_probe(struct platform_device *pdev) ret =pxamci_init_ocr (host);if (ret <0 ) -return ret; + goto out; mmc->caps =0 ; host->cmdat =0 ;
drivers/net/can/spi/mcp251x.c +15 -3
@@ -1074,9 +1074,6 @@ static irqreturn_t mcp251x_can_ist(int irq, void *dev_id)mcp251x_read_2regs (spi,CANINTF , &intf, &eflag); -/* mask out flags we don't care about */ - intf &=CANINTF_RX |CANINTF_TX |CANINTF_ERR ; -/* receive buffer 0 */ if (intf &CANINTF_RX0IF ) {mcp251x_hw_rx (spi,0 );
@@ -1086,6 +1083,18 @@ static irqreturn_t mcp251x_can_ist(int irq, void *dev_id)if (mcp251x_is_2510 (spi))mcp251x_write_bits (spi,CANINTF ,CANINTF_RX0IF ,0x00 ); + +/* check if buffer 1 is already known to be full, no need to re-read */ +if (!(intf &CANINTF_RX1IF )) { +u8 intf1, eflag1; + +/* intf needs to be read again to avoid a race condition */ +mcp251x_read_2regs (spi,CANINTF , &intf1, &eflag1); + +/* combine flags from both operations for error handling */ + intf |= intf1; + eflag |= eflag1; + } }/* receive buffer 1 */
@@ -1096,6 +1105,9 @@ static irqreturn_t mcp251x_can_ist(int irq, void *dev_id) clear_intf |=CANINTF_RX1IF ; } +/* mask out flags we don't care about */ + intf &=CANINTF_RX |CANINTF_TX |CANINTF_ERR ; +/* any error or tx interrupt we need to clear? */ if (intf & (CANINTF_ERR |CANINTF_TX )) clear_intf |= intf & (CANINTF_ERR |CANINTF_TX );
drivers/net/can/usb/ems_usb.c +1 -1
@@ -194,7 +194,7 @@ struct __packed ems_cpc_msg {__le32 ts_sec;/* timestamp in seconds */ __le32 ts_nsec;/* timestamp in nano seconds */ -union { +union __packed {u8 generic[64 ];struct cpc_can_msg can_msg;struct cpc_can_params can_params;
drivers/net/dsa/microchip/ksz9477.c +3 -0
@@ -762,6 +762,9 @@ static int ksz9477_port_fdb_dump(struct dsa_switch *ds, int port, goto exit; } +if (!(ksz_data &ALU_VALID )) +continue ; +/* read ALU table */ ksz9477_read_table (dev, alu_table);
drivers/net/dsa/mv88e6060.c +3 -0
@@ -118,6 +118,9 @@ static int mv88e6060_setup_port(struct mv88e6060_priv *priv, int p)int addr =REG_PORT (p);int ret; +if (dsa_is_unused_port (priv->ds, p)) +return 0 ; +/* Do not force flow control, disable Ingress and Egress * Header tagging, disable VLAN tunneling, and set the port * state to Forwarding. Additionally, if this is the CPU
drivers/net/dsa/ocelot/felix_vsc9959.c +2 -1
@@ -578,7 +578,8 @@ static const struct ocelot_stat_layout vsc9959_stats_layout[] = { { .offset = 0x87, .name = "tx_frames_below_65_octets", }, { .offset = 0x88, .name = "tx_frames_65_to_127_octets", }, { .offset = 0x89, .name = "tx_frames_128_255_octets", }, - { .offset = 0x8B, .name = "tx_frames_256_511_octets", }, + { .offset = 0x8A, .name = "tx_frames_256_511_octets", }, + { .offset = 0x8B, .name = "tx_frames_512_1023_octets", }, { .offset = 0x8C, .name = "tx_frames_1024_1526_octets", }, { .offset = 0x8D, .name = "tx_frames_over_1526_octets", }, { .offset = 0x8E, .name = "tx_yellow_prio_0", },
drivers/net/dsa/sja1105/sja1105_devlink.c +1 -1
@@ -93,7 +93,7 @@ static int sja1105_setup_devlink_regions(struct dsa_switch *ds) region =dsa_devlink_region_create (ds, ops,1 , size);if (IS_ERR (region)) { -while (i-- >=0 ) +while (--i >=0 )dsa_devlink_region_destroy (priv->regions[i]);return PTR_ERR (region); }
drivers/net/ethernet/aquantia/atlantic/aq_nic.c +8 -13
@@ -265,12 +265,10 @@ static void aq_nic_service_timer_cb(struct timer_list *t)static void aq_nic_polling_timer_cb (struct timer_list *t) {struct aq_nic_s *self =from_timer (self, t, polling_timer); -struct aq_vec_s *aq_vec =NULL ;unsigned int i =0U ; -for (i =0U , aq_vec = self->aq_vec[0 ]; - self->aq_vecs > i; ++i, aq_vec = self->aq_vec[i]) -aq_vec_isr (i, (void *)aq_vec); +for (i =0U ; self->aq_vecs > i; ++i) +aq_vec_isr (i, (void *)self->aq_vec[i]);mod_timer (&self->polling_timer, jiffies +AQ_CFG_POLLING_TIMER_INTERVAL );
@@ -872,7 +870,6 @@ int aq_nic_get_regs_count(struct aq_nic_s *self)u64 *aq_nic_get_stats (struct aq_nic_s *self,u64 *data) { -struct aq_vec_s *aq_vec =NULL ;struct aq_stats_s *stats;unsigned int count =0U ;unsigned int i =0U ;
@@ -922,11 +919,11 @@ u64 *aq_nic_get_stats(struct aq_nic_s *self, u64 *data) data += i;for (tc =0U ; tc < self->aq_nic_cfg.tcs; tc++) { -for (i =0U , aq_vec = self->aq_vec[0 ]; - aq_vec && self->aq_vecs > i; - ++i, aq_vec = self->aq_vec[i]) { +for (i =0U ; self->aq_vecs > i; ++i) { +if (!self->aq_vec[i]) +break ; data += count; - count =aq_vec_get_sw_stats (aq_vec, tc, data); + count =aq_vec_get_sw_stats (self->aq_vec[i], tc, data); } }
@@ -1240,7 +1237,6 @@ int aq_nic_set_loopback(struct aq_nic_s *self)int aq_nic_stop (struct aq_nic_s *self) { -struct aq_vec_s *aq_vec =NULL ;unsigned int i =0U ;netif_tx_disable (self->ndev);
@@ -1258,9 +1254,8 @@ int aq_nic_stop(struct aq_nic_s *self)aq_ptp_irq_free (self); -for (i =0U , aq_vec = self->aq_vec[0 ]; - self->aq_vecs > i; ++i, aq_vec = self->aq_vec[i]) -aq_vec_stop (aq_vec); +for (i =0U ; self->aq_vecs > i; ++i) +aq_vec_stop (self->aq_vec[i]);aq_ptp_ring_stop (self);
drivers/net/ethernet/broadcom/bgmac.c +1 -1
@@ -189,8 +189,8 @@ static netdev_tx_t bgmac_dma_tx_add(struct bgmac *bgmac, } slot->skb = skb; - ring->end += nr_frags +1 ;netdev_sent_queue (net_dev, skb->len); + ring->end += nr_frags +1 ;wmb ();
drivers/net/ethernet/freescale/dpaa2/dpaa2-eth.c +2 -2
@@ -1349,8 +1349,8 @@ static int dpaa2_eth_add_bufs(struct dpaa2_eth_priv *priv, buf_array[i] = addr;/* tracing point */ -trace_dpaa2_eth_buf_seed (priv->net_dev, - page,DPAA2_ETH_RX_BUF_RAW_SIZE , +trace_dpaa2_eth_buf_seed (priv->net_dev,page_address (page), +DPAA2_ETH_RX_BUF_RAW_SIZE , addr, priv->rx_buf_size, bpid); }
drivers/net/ethernet/freescale/fec_ptp.c +1 -5
@@ -136,11 +136,7 @@ static int fec_ptp_enable_pps(struct fec_enet_private *fep, uint enable)* NSEC_PER_SEC - ts.tv_nsec. Add the remaining nanoseconds * to current timer would be next second. */ - tempval =readl (fep->hwp +FEC_ATIME_CTRL ); - tempval |=FEC_T_CTRL_CAPTURE ; -writel (tempval, fep->hwp +FEC_ATIME_CTRL ); - - tempval =readl (fep->hwp +FEC_ATIME ); + tempval = fep->cc.read (&fep->cc);/* Convert the ptp local counter to 1588 timestamp */ ns =timecounter_cyc2time (&fep->tc, tempval); ts =ns_to_timespec64 (ns);
drivers/net/ethernet/intel/i40e/i40e_main.c +3 -1
@@ -382,7 +382,9 @@ static void i40e_tx_timeout(struct net_device *netdev, unsigned int txqueue)set_bit (__I40E_GLOBAL_RESET_REQUESTED, pf->state);break ;default : -netdev_err (netdev,"tx_timeout recovery unsuccessful\n" ); +netdev_err (netdev,"tx_timeout recovery unsuccessful, device is in non-recoverable state.\n" ); +set_bit (__I40E_DOWN_REQUESTED, pf->state); +set_bit (__I40E_VSI_DOWN_REQUESTED, vsi->state);break ; }
drivers/net/ethernet/intel/iavf/iavf_adminq.c +13 -2
@@ -324,6 +324,7 @@ static enum iavf_status iavf_config_arq_regs(struct iavf_hw *hw)static enum iavf_status iavf_init_asq (struct iavf_hw *hw) {enum iavf_status ret_code =0 ; +int i;if (hw->aq.asq.count >0 ) {/* queue already initialized */
@@ -354,12 +355,17 @@ static enum iavf_status iavf_init_asq(struct iavf_hw *hw)/* initialize base registers */ ret_code =iavf_config_asq_regs (hw);if (ret_code) - goto init_adminq_free_rings; + goto init_free_asq_bufs;/* success! */ hw->aq.asq.count = hw->aq.num_asq_entries; goto init_adminq_exit; +init_free_asq_bufs: +for (i =0 ; i < hw->aq.num_asq_entries; i++) +iavf_free_dma_mem (hw, &hw->aq.asq.r.asq_bi[i]); +iavf_free_virt_mem (hw, &hw->aq.asq.dma_head); + init_adminq_free_rings:iavf_free_adminq_asq (hw);
@@ -383,6 +389,7 @@ static enum iavf_status iavf_init_asq(struct iavf_hw *hw)static enum iavf_status iavf_init_arq (struct iavf_hw *hw) {enum iavf_status ret_code =0 ; +int i;if (hw->aq.arq.count >0 ) {/* queue already initialized */
@@ -413,12 +420,16 @@ static enum iavf_status iavf_init_arq(struct iavf_hw *hw)/* initialize base registers */ ret_code =iavf_config_arq_regs (hw);if (ret_code) - goto init_adminq_free_rings; + goto init_free_arq_bufs;/* success! */ hw->aq.arq.count = hw->aq.num_arq_entries; goto init_adminq_exit; +init_free_arq_bufs: +for (i =0 ; i < hw->aq.num_arq_entries; i++) +iavf_free_dma_mem (hw, &hw->aq.arq.r.arq_bi[i]); +iavf_free_virt_mem (hw, &hw->aq.arq.dma_head); init_adminq_free_rings:iavf_free_adminq_arq (hw);
drivers/net/ethernet/intel/ice/ice_switch.c +1 -1
@@ -2590,7 +2590,7 @@ ice_set_vlan_vsi_promisc(struct ice_hw *hw, u16 vsi_handle, u8 promisc_mask,else status =ice_set_vsi_promisc (hw, vsi_handle, promisc_mask, vlan_id); -if (status) +if (status && status != -EEXIST )break ; }
drivers/net/ethernet/intel/igb/igb.h +2 -0
@@ -664,6 +664,8 @@ struct igb_adapter {struct igb_mac_addr *mac_table;struct vf_mac_filter vf_macs;struct vf_mac_filter *vf_mac_list; +/* lock for VF resources */ +spinlock_t vfs_lock; };/* flags controlling PTP/1588 function */
drivers/net/ethernet/intel/igb/igb_main.c +11 -1
@@ -3638,6 +3638,7 @@ static int igb_disable_sriov(struct pci_dev *pdev)struct net_device *netdev =pci_get_drvdata (pdev);struct igb_adapter *adapter =netdev_priv (netdev);struct e1000_hw *hw = &adapter->hw; +unsigned long flags;/* reclaim resources allocated to VFs */ if (adapter->vf_data) {
@@ -3650,12 +3651,13 @@ static int igb_disable_sriov(struct pci_dev *pdev)pci_disable_sriov (pdev);msleep (500 ); } - +spin_lock_irqsave (&adapter->vfs_lock, flags);kfree (adapter->vf_mac_list); adapter->vf_mac_list =NULL ;kfree (adapter->vf_data); adapter->vf_data =NULL ; adapter->vfs_allocated_count =0 ; +spin_unlock_irqrestore (&adapter->vfs_lock, flags);wr32 (E1000_IOVCTL ,E1000_IOVCTL_REUSE_VFQ );wrfl ();msleep (100 );
@@ -3815,7 +3817,9 @@ static void igb_remove(struct pci_dev *pdev)igb_release_hw_control (adapter);#ifdef CONFIG_PCI_IOV +rtnl_lock ();igb_disable_sriov (pdev); +rtnl_unlock ();#endif unregister_netdev (netdev);
@@ -3975,6 +3979,9 @@ static int igb_sw_init(struct igb_adapter *adapter)spin_lock_init (&adapter->nfc_lock);spin_lock_init (&adapter->stats64_lock); + +/* init spinlock to avoid concurrency of VF resources */ +spin_lock_init (&adapter->vfs_lock);#ifdef CONFIG_PCI_IOV switch (hw->mac.type) {case e1000_82576:
@@ -7852,8 +7859,10 @@ static void igb_rcv_msg_from_vf(struct igb_adapter *adapter, u32 vf)static void igb_msg_task (struct igb_adapter *adapter) {struct e1000_hw *hw = &adapter->hw; +unsigned long flags;u32 vf; +spin_lock_irqsave (&adapter->vfs_lock, flags);for (vf =0 ; vf < adapter->vfs_allocated_count; vf++) {/* process any reset requests */ if (!igb_check_for_rst (hw, vf))
@@ -7867,6 +7876,7 @@ static void igb_msg_task(struct igb_adapter *adapter)if (!igb_check_for_ack (hw, vf))igb_rcv_ack_from_vf (adapter, vf); } +spin_unlock_irqrestore (&adapter->vfs_lock, flags); }/**
drivers/net/ethernet/moxa/moxart_ether.c +10 -10
@@ -77,7 +77,7 @@ static void moxart_mac_free_memory(struct net_device *ndev)int i;for (i =0 ; i <RX_DESC_NUM ; i++) -dma_unmap_single (&ndev->dev, priv->rx_mapping[i], +dma_unmap_single (&priv->pdev->dev, priv->rx_mapping[i], priv->rx_buf_size,DMA_FROM_DEVICE );if (priv->tx_desc_base)
@@ -147,11 +147,11 @@ static void moxart_mac_setup_desc_ring(struct net_device *ndev) desc + RX_REG_OFFSET_DESC1); priv->rx_buf[i] = priv->rx_buf_base + priv->rx_buf_size * i; - priv->rx_mapping[i] =dma_map_single (&ndev->dev, + priv->rx_mapping[i] =dma_map_single (&priv->pdev->dev, priv->rx_buf[i], priv->rx_buf_size,DMA_FROM_DEVICE ); -if (dma_mapping_error (&ndev->dev, priv->rx_mapping[i])) +if (dma_mapping_error (&priv->pdev->dev, priv->rx_mapping[i]))netdev_err (ndev,"DMA mapping error\n" ); moxart_desc_write(priv->rx_mapping[i],
@@ -240,7 +240,7 @@ static int moxart_rx_poll(struct napi_struct *napi, int budget)if (len >RX_BUF_SIZE ) len =RX_BUF_SIZE ; -dma_sync_single_for_cpu (&ndev->dev, +dma_sync_single_for_cpu (&priv->pdev->dev, priv->rx_mapping[rx_head], priv->rx_buf_size,DMA_FROM_DEVICE ); skb =netdev_alloc_skb_ip_align (ndev, len);
@@ -294,7 +294,7 @@ static void moxart_tx_finished(struct net_device *ndev)unsigned int tx_tail = priv->tx_tail;while (tx_tail != tx_head) { -dma_unmap_single (&ndev->dev, priv->tx_mapping[tx_tail], +dma_unmap_single (&priv->pdev->dev, priv->tx_mapping[tx_tail], priv->tx_len[tx_tail],DMA_TO_DEVICE ); ndev->stats.tx_packets++;
@@ -358,9 +358,9 @@ static netdev_tx_t moxart_mac_start_xmit(struct sk_buff *skb, len = skb->len >TX_BUF_SIZE ?TX_BUF_SIZE : skb->len; - priv->tx_mapping[tx_head] =dma_map_single (&ndev->dev, skb->data, + priv->tx_mapping[tx_head] =dma_map_single (&priv->pdev->dev, skb->data, len,DMA_TO_DEVICE ); -if (dma_mapping_error (&ndev->dev, priv->tx_mapping[tx_head])) { +if (dma_mapping_error (&priv->pdev->dev, priv->tx_mapping[tx_head])) {netdev_err (ndev,"DMA mapping error\n" ); goto out_unlock; }
@@ -379,7 +379,7 @@ static netdev_tx_t moxart_mac_start_xmit(struct sk_buff *skb, len =ETH_ZLEN ; } -dma_sync_single_for_device (&ndev->dev, priv->tx_mapping[tx_head], +dma_sync_single_for_device (&priv->pdev->dev, priv->tx_mapping[tx_head], priv->tx_buf_size,DMA_TO_DEVICE ); txdes1 =TX_DESC1_LTS |TX_DESC1_FTS | (len &TX_DESC1_BUF_SIZE_MASK );
@@ -494,7 +494,7 @@ static int moxart_mac_probe(struct platform_device *pdev) priv->tx_buf_size =TX_BUF_SIZE ; priv->rx_buf_size =RX_BUF_SIZE ; - priv->tx_desc_base =dma_alloc_coherent (&pdev->dev,TX_REG_DESC_SIZE * + priv->tx_desc_base =dma_alloc_coherent (p_dev,TX_REG_DESC_SIZE *TX_DESC_NUM , &priv->tx_base,GFP_DMA |GFP_KERNEL );if (!priv->tx_desc_base) {
@@ -502,7 +502,7 @@ static int moxart_mac_probe(struct platform_device *pdev) goto init_fail; } - priv->rx_desc_base =dma_alloc_coherent (&pdev->dev,RX_REG_DESC_SIZE * + priv->rx_desc_base =dma_alloc_coherent (p_dev,RX_REG_DESC_SIZE *RX_DESC_NUM , &priv->rx_base,GFP_DMA |GFP_KERNEL );if (!priv->rx_desc_base) {
drivers/net/ethernet/netronome/nfp/nfp_net_ethtool.c +2 -0
@@ -1225,6 +1225,8 @@ nfp_port_get_module_info(struct net_device *netdev,u8 data; port =nfp_port_from_netdev (netdev); +/* update port state to get latest interface */ +set_bit (NFP_PORT_CHANGED , &port->flags); eth_port =nfp_port_get_eth_port (port);if (!eth_port)return -EOPNOTSUPP ;
drivers/net/ethernet/stmicro/stmmac/dwmac-intel.c +1 -0
@@ -669,6 +669,7 @@ static void intel_eth_pci_remove(struct pci_dev *pdev)pci_free_irq_vectors (pdev); +clk_disable_unprepare (priv->plat->stmmac_clk);clk_unregister_fixed_rate (priv->plat->stmmac_clk);pcim_iounmap_regions (pdev,BIT (0 ));
drivers/net/geneve.c +9 -6
@@ -772,7 +772,8 @@ static struct rtable *geneve_get_v4_rt(struct sk_buff *skb,struct geneve_sock *gs4, struct flowi4 *fl4, const struct ip_tunnel_info *info, - __be16 dport, __be16 sport) + __be16 dport, __be16 sport, + __u8 *full_tos) { bool use_cache = ip_tunnel_dst_cache_usable(skb, info);struct geneve_dev *geneve =netdev_priv (dev);
@@ -797,6 +798,8 @@ static struct rtable *geneve_get_v4_rt(struct sk_buff *skb, use_cache = false; } fl4->flowi4_tos =RT_TOS (tos); +if (full_tos) + *full_tos = tos; dst_cache = (struct dst_cache *)&info->dst_cache;if (use_cache) {
@@ -850,8 +853,7 @@ static struct dst_entry *geneve_get_v6_dst(struct sk_buff *skb, use_cache = false; } - fl6->flowlabel =ip6_make_flowinfo (RT_TOS (prio), - info->key.label); + fl6->flowlabel =ip6_make_flowinfo (prio, info->key.label); dst_cache = (struct dst_cache *)&info->dst_cache;if (use_cache) { dst =dst_cache_get_ip6 (dst_cache, &fl6->saddr);
@@ -885,6 +887,7 @@ static int geneve_xmit_skb(struct sk_buff *skb, struct net_device *dev,const struct ip_tunnel_key *key = &info->key;struct rtable *rt;struct flowi4 fl4; +__u8 full_tos;__u8 tos, ttl;__be16 df =0 ;__be16 sport;
@@ -895,7 +898,7 @@ static int geneve_xmit_skb(struct sk_buff *skb, struct net_device *dev, sport =udp_flow_src_port (geneve->net, skb,1 ,USHRT_MAX , true); rt =geneve_get_v4_rt (skb, dev, gs4, &fl4, info, - geneve->cfg.info.key.tp_dst, sport); + geneve->cfg.info.key.tp_dst, sport, &full_tos);if (IS_ERR (rt))return PTR_ERR (rt);
@@ -939,7 +942,7 @@ static int geneve_xmit_skb(struct sk_buff *skb, struct net_device *dev, df = key->tun_flags &TUNNEL_DONT_FRAGMENT ?htons (IP_DF ) :0 ; }else { - tos =ip_tunnel_ecn_encap (fl4.flowi4_tos,ip_hdr (skb), skb); + tos =ip_tunnel_ecn_encap (full_tos,ip_hdr (skb), skb);if (geneve->cfg.ttl_inherit) ttl =ip_tunnel_get_ttl (ip_hdr (skb), skb);else
@@ -1121,7 +1124,7 @@ static int geneve_fill_metadata_dst(struct net_device *dev, struct sk_buff *skb) 1, USHRT_MAX, true); rt =geneve_get_v4_rt (skb, dev, gs4, &fl4, info, - geneve->cfg.info.key.tp_dst, sport); + geneve->cfg.info.key.tp_dst, sport,NULL );if (IS_ERR (rt))return PTR_ERR (rt);
drivers/net/plip/plip.c +1 -1
@@ -1103,7 +1103,7 @@ plip_open(struct net_device *dev)/* Any address will do - we take the first. We already have the first two bytes filled with 0xfc, from plip_init_dev(). */ -const struct in_ifaddr *ifa =rcu_dereference (in_dev->ifa_list); +const struct in_ifaddr *ifa =rtnl_dereference (in_dev->ifa_list);if (ifa !=NULL ) {memcpy (dev->dev_addr+2 , &ifa->ifa_local,4 ); }
drivers/net/virtio_net.c +4 -1
@@ -968,8 +968,11 @@ static struct sk_buff *receive_mergeable(struct net_device *dev,case XDP_TX : stats->xdp_tx++; xdpf =xdp_convert_buff_to_frame (&xdp); -if (unlikely (!xdpf)) +if (unlikely (!xdpf)) { +if (unlikely (xdp_page != page)) +put_page (xdp_page); goto err_xdp; + } err =virtnet_xdp_xmit (dev,1 , &xdpf,0 );if (unlikely (err <0 )) {trace_xdp_exception (vi->dev, xdp_prog, act);
drivers/ntb/test/ntb_tool.c +5 -3
@@ -367,14 +367,16 @@ static ssize_t tool_fn_write(struct tool_ctx *tc,u64 bits;int n; +if (*offp) +return 0 ; + buf =kmalloc (size +1 ,GFP_KERNEL );if (!buf)return -ENOMEM ; - ret =simple_write_to_buffer (buf, size, offp, ubuf, size); -if (ret <0 ) { +if (copy_from_user (buf, ubuf, size)) {kfree (buf); -return ret; +return -EFAULT ; } buf[size] =0 ;
drivers/nvme/target/tcp.c +2 -1
@@ -1802,7 +1802,8 @@ static int __init nvmet_tcp_init(void) {int ret; - nvmet_tcp_wq =alloc_workqueue ("nvmet_tcp_wq" ,WQ_HIGHPRI ,0 ); + nvmet_tcp_wq =alloc_workqueue ("nvmet_tcp_wq" , +WQ_MEM_RECLAIM |WQ_HIGHPRI ,0 );if (!nvmet_tcp_wq)return -ENOMEM ;
drivers/pci/pcie/err.c +1 -2
@@ -196,8 +196,7 @@ pci_ers_result_t pcie_do_recovery(struct pci_dev *dev,pci_dbg (bridge,"broadcast error_detected message\n" );if (state == pci_channel_io_frozen) {pci_walk_bridge (bridge, report_frozen_detected, &status); - status =reset_subordinates (bridge); -if (status !=PCI_ERS_RESULT_RECOVERED ) { +if (reset_subordinates (bridge) !=PCI_ERS_RESULT_RECOVERED ) {pci_warn (bridge,"subordinate device reset failed\n" ); goto failed; }
drivers/pci/quirks.c +3 -0
@@ -4897,6 +4897,9 @@ static const struct pci_dev_acs_enabled { { PCI_VENDOR_ID_AMPERE, 0xE00C, pci_quirk_xgene_acs },/* Broadcom multi-function device */ { PCI_VENDOR_ID_BROADCOM, 0x16D7, pci_quirk_mf_endpoint_acs }, + { PCI_VENDOR_ID_BROADCOM, 0x1750, pci_quirk_mf_endpoint_acs }, + { PCI_VENDOR_ID_BROADCOM, 0x1751, pci_quirk_mf_endpoint_acs }, + { PCI_VENDOR_ID_BROADCOM, 0x1752, pci_quirk_mf_endpoint_acs }, { PCI_VENDOR_ID_BROADCOM, 0xD714, pci_quirk_brcm_acs },/* Amazon Annapurna Labs */ { PCI_VENDOR_ID_AMAZON_ANNAPURNA_LABS, 0x0031, pci_quirk_al_acs },
drivers/pinctrl/intel/pinctrl-intel.c +6 -8
@@ -1571,16 +1571,14 @@ EXPORT_SYMBOL_GPL(intel_pinctrl_probe_by_uid);const struct intel_pinctrl_soc_data *intel_pinctrl_get_soc_data (struct platform_device *pdev) { +const struct intel_pinctrl_soc_data *const *table;const struct intel_pinctrl_soc_data *data =NULL ; -const struct intel_pinctrl_soc_data **table; -struct acpi_device *adev; -unsigned int i; - adev =ACPI_COMPANION (&pdev->dev); -if (adev) { -const void *match =device_get_match_data (&pdev->dev); + table =device_get_match_data (&pdev->dev); +if (table) { +struct acpi_device *adev =ACPI_COMPANION (&pdev->dev); +unsigned int i; - table = (const struct intel_pinctrl_soc_data **)match;for (i =0 ; table[i]; i++) {if (!strcmp (adev->pnp.unique_id, table[i]->uid)) { data = table[i];
@@ -1594,7 +1592,7 @@ const struct intel_pinctrl_soc_data *intel_pinctrl_get_soc_data(struct platform_if (!id)return ERR_PTR (-ENODEV ); - table = (const struct intel_pinctrl_soc_data **)id->driver_data; + table = (const struct intel_pinctrl_soc_data *const *)id->driver_data; data = table[pdev->id]; }
drivers/pinctrl/nomadik/pinctrl-nomadik.c +3 -1
@@ -1421,8 +1421,10 @@ static int nmk_pinctrl_dt_subnode_to_map(struct pinctrl_dev *pctldev, has_config =nmk_pinctrl_dt_get_config (np, &configs); np_config =of_parse_phandle (np,"ste,config" ,0 ); -if (np_config) +if (np_config) { has_config |=nmk_pinctrl_dt_get_config (np_config, &configs); +of_node_put (np_config); + }if (has_config) {const char *gpio_name;const char *pin;
drivers/pinctrl/qcom/pinctrl-msm8916.c +2 -2
@@ -844,8 +844,8 @@ static const struct msm_pingroup msm8916_groups[] = {PINGROUP (28 , pwr_modem_enabled_a,NA ,NA ,NA ,NA ,NA , qdss_tracedata_b,NA , atest_combodac),PINGROUP (29 , cci_i2c,NA ,NA ,NA ,NA ,NA , qdss_tracedata_b,NA , atest_combodac),PINGROUP (30 , cci_i2c,NA ,NA ,NA ,NA ,NA ,NA ,NA , qdss_tracedata_b), -PINGROUP (31 , cci_timer0,NA ,NA ,NA ,NA ,NA ,NA ,NA ,NA ), -PINGROUP (32 , cci_timer1,NA ,NA ,NA ,NA ,NA ,NA ,NA ,NA ), +PINGROUP (31 , cci_timer0, flash_strobe,NA ,NA ,NA ,NA ,NA ,NA ,NA ), +PINGROUP (32 , cci_timer1, flash_strobe,NA ,NA ,NA ,NA ,NA ,NA ,NA ),PINGROUP (33 , cci_async,NA ,NA ,NA ,NA ,NA ,NA ,NA , qdss_tracedata_b),PINGROUP (34 , pwr_nav_enabled_a,NA ,NA ,NA ,NA ,NA ,NA ,NA , qdss_tracedata_b), PINGROUP(35, pwr_crypto_enabled_a, NA, NA, NA, NA, NA, NA, NA, qdss_tracedata_b),
drivers/pinctrl/qcom/pinctrl-sm8250.c +1 -1
@@ -1316,7 +1316,7 @@ static const struct msm_pingroup sm8250_groups[] = {static const struct msm_gpio_wakeirq_map sm8250_pdc_map[] = { {0 ,79 }, {1 ,84 }, {2 ,80 }, {3 ,82 }, {4 ,107 }, {7 ,43 }, {11 ,42 }, {14 ,44 }, {15 ,52 }, {19 ,67 }, {23 ,68 }, {24 ,105 }, - {27 ,92 }, {28 ,106 }, {31 ,69 }, {35 ,70 }, {39 ,37 }, + {27 ,92 }, {28 ,106 }, {31 ,69 }, {35 ,70 }, {39 ,73 }, {40 ,108 }, {43 ,71 }, {45 ,72 }, {47 ,83 }, {51 ,74 }, {55 ,77 }, {59 ,78 }, {63 ,75 }, {64 ,81 }, {65 ,87 }, {66 ,88 }, {67 ,89 }, {68 ,54 }, {70 ,85 }, {77 ,46 }, {80 ,90 }, {81 ,91 }, {83 ,97 },
drivers/pinctrl/sunxi/pinctrl-sun50i-h6-r.c +1 -0
@@ -105,6 +105,7 @@ static const struct sunxi_pinctrl_desc sun50i_h6_r_pinctrl_data = { .npins = ARRAY_SIZE(sun50i_h6_r_pins), .pin_base = PL_BASE, .irq_banks = 2, + .io_bias_cfg_variant = BIAS_VOLTAGE_PIO_POW_MODE_SEL, };static int sun50i_h6_r_pinctrl_probe (struct platform_device *pdev)
drivers/pinctrl/sunxi/pinctrl-sunxi.c +4 -3
@@ -624,7 +624,7 @@ static int sunxi_pinctrl_set_io_bias_cfg(struct sunxi_pinctrl *pctl,unsigned pin, struct regulator *supply) { - unsigned short bank = pin / PINS_PER_BANK; + unsigned short bank;unsigned long flags;u32 val, reg;int uV;
@@ -640,6 +640,9 @@ static int sunxi_pinctrl_set_io_bias_cfg(struct sunxi_pinctrl *pctl,if (uV ==0 )return 0 ; + pin -= pctl->desc->pin_base; + bank = pin /PINS_PER_BANK ; +switch (pctl->desc->io_bias_cfg_variant) {case BIAS_VOLTAGE_GRP_CONFIG :/*
@@ -657,8 +660,6 @@ static int sunxi_pinctrl_set_io_bias_cfg(struct sunxi_pinctrl *pctl,else val =0xD ;/* 3.3V */ - pin -= pctl->desc->pin_base; - reg =readl (pctl->membase +sunxi_grp_config_reg (pin)); reg &= ~IO_BIAS_MASK ;writel (reg | val, pctl->membase +sunxi_grp_config_reg (pin));
drivers/platform/chrome/cros_ec_proto.c +4 -4
@@ -507,13 +507,13 @@ int cros_ec_query_all(struct cros_ec_device *ec_dev) ret =cros_ec_get_host_command_version_mask (ec_dev,EC_CMD_GET_NEXT_EVENT , &ver_mask); -if (ret <0 || ver_mask ==0 ) +if (ret <0 || ver_mask ==0 ) { ec_dev->mkbp_event_supported =0 ; -else + }else { ec_dev->mkbp_event_supported =fls (ver_mask); -dev_dbg (ec_dev->dev,"MKBP support version %u\n" , - ec_dev->mkbp_event_supported -1 ); +dev_dbg (ec_dev->dev,"MKBP support version %u\n" , ec_dev->mkbp_event_supported -1 ); + }/* Probe if host sleep v1 is supported for S0ix failure detection. */ ret = cros_ec_get_host_command_version_mask(ec_dev,
drivers/scsi/lpfc/lpfc_debugfs.c +10 -10
@@ -2609,8 +2609,8 @@ lpfc_debugfs_multixripools_write(struct file *file, const char __user *buf,struct lpfc_sli4_hdw_queue *qp;struct lpfc_multixri_pool *multixri_pool; -if (nbytes >64 ) - nbytes =64 ; +if (nbytes >sizeof (mybuf) -1 ) + nbytes =sizeof (mybuf) -1 ;memset (mybuf,0 ,sizeof (mybuf));
@@ -2690,8 +2690,8 @@ lpfc_debugfs_nvmestat_write(struct file *file, const char __user *buf,if (!phba->targetport)return -ENXIO ; -if (nbytes >64 ) - nbytes =64 ; +if (nbytes >sizeof (mybuf) -1 ) + nbytes =sizeof (mybuf) -1 ;memset (mybuf,0 ,sizeof (mybuf));
@@ -2828,8 +2828,8 @@ lpfc_debugfs_ioktime_write(struct file *file, const char __user *buf,char mybuf[64 ];char *pbuf; -if (nbytes >64 ) - nbytes =64 ; +if (nbytes >sizeof (mybuf) -1 ) + nbytes =sizeof (mybuf) -1 ;memset (mybuf,0 ,sizeof (mybuf));
@@ -2956,8 +2956,8 @@ lpfc_debugfs_nvmeio_trc_write(struct file *file, const char __user *buf,char mybuf[64 ];char *pbuf; -if (nbytes >63 ) - nbytes =63 ; +if (nbytes >sizeof (mybuf) -1 ) + nbytes =sizeof (mybuf) -1 ;memset (mybuf,0 ,sizeof (mybuf));
@@ -3062,8 +3062,8 @@ lpfc_debugfs_hdwqstat_write(struct file *file, const char __user *buf,char *pbuf;int i; -if (nbytes >64 ) - nbytes =64 ; +if (nbytes >sizeof (mybuf) -1 ) + nbytes =sizeof (mybuf) -1 ;memset (mybuf,0 ,sizeof (mybuf));
drivers/spi/spi-meson-spicc.c +101 -28
204 lines not on this page · raw message
drivers/tee/tee_core.c +3 -0
@@ -334,6 +334,9 @@ tee_ioctl_shm_register(struct tee_context *ctx,if (data.flags)return -EINVAL ; +if (!access_ok ((void __user *)(unsigned long )data.addr, data.length)) +return -EFAULT ; + shm =tee_shm_register (ctx, data.addr, data.length,TEE_SHM_DMA_BUF |TEE_SHM_USER_MAPPED );if (IS_ERR (shm))
drivers/tee/tee_shm.c +0 -3
@@ -222,9 +222,6 @@ struct tee_shm *tee_shm_register(struct tee_context *ctx, unsigned long addr, goto err; } -if (!access_ok ((void __user *)addr, length)) -return ERR_PTR (-EFAULT ); -mutex_lock (&teedev->mutex); shm->id =idr_alloc (&teedev->idr, shm,1 ,0 ,GFP_KERNEL );mutex_unlock (&teedev->mutex);
drivers/tty/serial/ucc_uart.c +2 -0
@@ -1137,6 +1137,8 @@ static unsigned int soc_info(unsigned int *rev_h, unsigned int *rev_l)/* No compatible property, so try the name. */ soc_string = np->name; +of_node_put (np); +/* Extract the SOC number from the "PowerPC," string */ if ((sscanf (soc_string,"PowerPC,%u" , &soc) !=1 ) || !soc)return 0 ;
drivers/usb/cdns3/gadget.c +1 -1
@@ -655,9 +655,9 @@ static void cdns3_wa2_remove_old_request(struct cdns3_endpoint *priv_ep)trace_cdns3_wa2 (priv_ep,"removes eldest request" );kfree (priv_req->request.buf); +list_del_init (&priv_req->list);cdns3_gadget_ep_free_request (&priv_ep->endpoint, &priv_req->request); -list_del_init (&priv_req->list); --priv_ep->wa2_counter;if (!chain)
drivers/usb/dwc2/gadget.c +2 -1
@@ -3593,7 +3593,8 @@ void dwc2_hsotg_core_disconnect(struct dwc2_hsotg *hsotg)void dwc2_hsotg_core_connect (struct dwc2_hsotg *hsotg) {/* remove the soft-disconnect and let's go */ -dwc2_clear_bit (hsotg,DCTL ,DCTL_SFTDISCON ); +if (!hsotg->role_sw || (dwc2_readl (hsotg,GOTGCTL ) &GOTGCTL_BSESVLD )) +dwc2_clear_bit (hsotg,DCTL ,DCTL_SFTDISCON ); }/**
drivers/usb/gadget/function/uvc_video.c +1 -1
@@ -159,7 +159,7 @@ uvc_video_complete(struct usb_ep *ep, struct usb_request *req)break ;default : -uvcg_info (&video->uvc->func, +uvcg_warn (&video->uvc->func,"VS request completed with status %d.\n" , req->status);uvcg_queue_cancel (queue,0 );
drivers/usb/gadget/legacy/inode.c +1 -0
@@ -362,6 +362,7 @@ ep_io (struct ep_data *epdata, void *buf, unsigned len)spin_unlock_irq (&epdata->dev->lock);DBG (epdata->dev,"endpoint gone\n" ); +wait_for_completion (&done); epdata->status = -ENODEV ; } }
drivers/usb/host/ohci-ppc-of.c +1 -0
@@ -169,6 +169,7 @@ static int ohci_hcd_ppc_of_probe(struct platform_device *op)release_mem_region (res.start,0x4 ); }else pr_debug ("%s: cannot get ehci offset from fdt\n" , __FILE__); +of_node_put (np); }irq_dispose_mapping (irq);
drivers/usb/renesas_usbhs/rza.c +4 -0
@@ -23,6 +23,10 @@ static int usbhs_rza1_hardware_init(struct platform_device *pdev) extal_clk =of_find_node_by_name (NULL ,"extal" );of_property_read_u32 (usb_x1_clk,"clock-frequency" , &freq_usb);of_property_read_u32 (extal_clk,"clock-frequency" , &freq_extal); + +of_node_put (usb_x1_clk); +of_node_put (extal_clk); +if (freq_usb ==0 ) {if (freq_extal ==12000000 ) {/* Select 12MHz XTAL */
drivers/vfio/vfio.c +1 -0
@@ -1783,6 +1783,7 @@ struct vfio_info_cap_header *vfio_info_cap_add(struct vfio_info_cap *caps, buf =krealloc (caps->buf, caps->size + size,GFP_KERNEL );if (!buf) {kfree (caps->buf); + caps->buf =NULL ; caps->size =0 ;return ERR_PTR (-ENOMEM ); }
drivers/video/fbdev/i740fb.c +7 -2
@@ -400,7 +400,7 @@ static int i740fb_decode_var(const struct fb_var_screeninfo *var,u32 xres, right, hslen, left, xtotal;u32 yres, lower, vslen, upper, ytotal;u32 vxres, xoffset, vyres, yoffset; -u32 bpp, base, dacspeed24, mem; +u32 bpp, base, dacspeed24, mem, freq;u8 r7;int i;
@@ -643,7 +643,12 @@ static int i740fb_decode_var(const struct fb_var_screeninfo *var, par->atc[VGA_ATC_OVERSCAN ] =0 ;/* Calculate VCLK that most closely matches the requested dot clock */ -i740_calc_vclk ((((u32 )1e9 ) / var->pixclock) * (u32)(1e3 ), par); + freq = (((u32 )1e9 ) / var->pixclock) * (u32)(1e3 ); +if (freq <I740_RFREQ_FIX ) { +fb_dbg (info,"invalid pixclock\n" ); + freq =I740_RFREQ_FIX ; + } +i740_calc_vclk (freq, par);/* Since we program the clocks ourselves, always use VCLK2. */ par->misc |=0x0C ;
drivers/virt/vboxguest/vboxguest_linux.c +6 -3
@@ -356,8 +356,8 @@ static int vbg_pci_probe(struct pci_dev *pci, const struct pci_device_id *id) goto err_vbg_core_exit; } - ret =devm_request_irq (dev, pci->irq, vbg_core_isr,IRQF_SHARED , -DEVICE_NAME , gdev); + ret =request_irq (pci->irq, vbg_core_isr,IRQF_SHARED ,DEVICE_NAME , + gdev);if (ret) {vbg_err ("vboxguest: Error requesting irq: %d\n" , ret); goto err_vbg_core_exit;
@@ -367,7 +367,7 @@ static int vbg_pci_probe(struct pci_dev *pci, const struct pci_device_id *id)if (ret) {vbg_err ("vboxguest: Error misc_register %s failed: %d\n" ,DEVICE_NAME , ret); - goto err_vbg_core_exit; + goto err_free_irq; } ret =misc_register (&gdev->misc_device_user);
@@ -403,6 +403,8 @@ static int vbg_pci_probe(struct pci_dev *pci, const struct pci_device_id *id)misc_deregister (&gdev->misc_device_user); err_unregister_misc_device:misc_deregister (&gdev->misc_device); +err_free_irq: +free_irq (pci->irq, gdev); err_vbg_core_exit:vbg_core_exit (gdev); err_disable_pcidev:
@@ -419,6 +421,7 @@ static void vbg_pci_remove(struct pci_dev *pci) vbg_gdev =NULL ;mutex_unlock (&vbg_gdev_mutex); +free_irq (pci->irq, gdev);device_remove_file (gdev->dev, &dev_attr_host_features);device_remove_file (gdev->dev, &dev_attr_host_version);misc_deregister (&gdev->misc_device_user);
drivers/xen/xenbus/xenbus_dev_frontend.c +2 -2
@@ -128,7 +128,7 @@ static ssize_t xenbus_file_read(struct file *filp, {struct xenbus_file_priv *u = filp->private_data;struct read_buffer *rb; -unsigned i; +ssize_t i;int ret;mutex_lock (&u->reply_mutex);
@@ -148,7 +148,7 @@ static ssize_t xenbus_file_read(struct file *filp, rb = list_entry(u->read_buffers.next, struct read_buffer, list); i =0 ;while (i < len) { -unsigned sz =min ((unsigned )len - i, rb->len - rb->cons); +size_t sz =min_t (size_t, len - i, rb->len - rb->cons); ret =copy_to_user (ubuf + i, &rb->msg[rb->cons], sz);
fs/btrfs/tree-log.c +3 -1
@@ -1075,7 +1075,9 @@ static inline int __add_inode_ref(struct btrfs_trans_handle *trans, extref =btrfs_lookup_inode_extref (NULL , root, path, name, namelen, inode_objectid, parent_objectid,0 ,0 ); -if (!IS_ERR_OR_NULL (extref)) { +if (IS_ERR (extref)) { +return PTR_ERR (extref); + }else if (extref) {u32 item_size;u32 cur_offset =0 ;unsigned long base;
fs/ceph/caps.c +13 -14
@@ -3501,24 +3501,23 @@ static void handle_cap_grant(struct inode *inode, fill_inline = true; } -if (ci->i_auth_cap == cap && -le32_to_cpu (grant->op) ==CEPH_CAP_OP_IMPORT ) { -if (newcaps & ~extra_info->issued) - wake = true; +if (le32_to_cpu (grant->op) ==CEPH_CAP_OP_IMPORT ) { +if (ci->i_auth_cap == cap) { +if (newcaps & ~extra_info->issued) + wake = true; + +if (ci->i_requested_max_size > max_size || + !(le32_to_cpu (grant->wanted) &CEPH_CAP_ANY_FILE_WR )) { +/* re-request max_size if necessary */ + ci->i_requested_max_size =0 ; + wake = true; + } -if (ci->i_requested_max_size > max_size || - !(le32_to_cpu (grant->wanted) &CEPH_CAP_ANY_FILE_WR )) { -/* re-request max_size if necessary */ - ci->i_requested_max_size =0 ; - wake = true; +ceph_kick_flushing_inode_caps (session, ci); } - -ceph_kick_flushing_inode_caps (session, ci); -spin_unlock (&ci->i_ceph_lock);up_read (&session->s_mdsc->snap_rwsem); - }else { -spin_unlock (&ci->i_ceph_lock); } +spin_unlock (&ci->i_ceph_lock);if (fill_inline) ceph_fill_inline_data(inode, NULL, extra_info->inline_data,
fs/ceph/mds_client.c +5 -2
@@ -1184,14 +1184,17 @@ static int encode_supported_features(void **p, void *end)if (count >0 ) {size_t i;size_t size =FEATURE_BYTES (count); +unsigned long bit;if (WARN_ON_ONCE (*p +4 + size > end))return -ERANGE ;ceph_encode_32 (p, size);memset (*p,0 , size); -for (i =0 ; i < count; i++) - ((unsigned char *)(*p))[i /8 ] |=BIT (feature_bits[i] %8 ); +for (i =0 ; i < count; i++) { + bit = feature_bits[i]; + ((unsigned char *)(*p))[bit /8 ] |=BIT (bit %8 ); + } *p += size; }else {if (WARN_ON_ONCE (*p +4 > end))
fs/ceph/mds_client.h +0 -6
@@ -33,10 +33,6 @@ enum ceph_feature_type { CEPHFS_FEATURE_MAX = CEPHFS_FEATURE_METRIC_COLLECT, }; -/* -* This will always have the highest feature bit value -* as the last element of the array. -*/ #define CEPHFS_FEATURES_CLIENT_SUPPORTED { \ 0, 1, 2, 3, 4, 5, 6, 7, \ CEPHFS_FEATURE_MIMIC, \
@@ -45,8 +41,6 @@ enum ceph_feature_type {CEPHFS_FEATURE_MULTI_RECONNECT , \CEPHFS_FEATURE_DELEG_INO , \CEPHFS_FEATURE_METRIC_COLLECT , \ - \ -CEPHFS_FEATURE_MAX , \ } #define CEPHFS_FEATURES_CLIENT_REQUIRED {}
fs/cifs/smb2ops.c +3 -2
@@ -1000,9 +1000,7 @@ move_smb2_ea_to_cifs(char *dst, size_t dst_size,size_t name_len, value_len, user_name_len;while (src_size >0 ) { - name = &src->ea_data[0 ]; name_len = (size_t )src->ea_name_length; - value = &src->ea_data[src->ea_name_length +1 ]; value_len = (size_t )le16_to_cpu (src->ea_value_length);if (name_len ==0 )
@@ -1014,6 +1012,9 @@ move_smb2_ea_to_cifs(char *dst, size_t dst_size, goto out; } + name = &src->ea_data[0 ]; + value = &src->ea_data[src->ea_name_length +1 ]; +if (ea_name) {if (ea_name_len == name_len &&memcmp (ea_name, name, name_len) ==0 ) {
fs/ext4/namei.c +2 -5
@@ -2961,11 +2961,8 @@ bool ext4_empty_dir(struct inode *inode) de = (struct ext4_dir_entry_2 *) (bh->b_data + (offset & (sb->s_blocksize -1 )));if (ext4_check_dir_entry (inode,NULL , de, bh, - bh->b_data, bh->b_size, offset)) { - offset = (offset | (sb->s_blocksize -1 )) +1 ; -continue ; - } -if (le32_to_cpu (de->inode)) { + bh->b_data, bh->b_size, offset) || +le32_to_cpu (de->inode)) {brelse (bh);return false; }
fs/ext4/resize.c +10 -0
@@ -1957,6 +1957,16 @@ int ext4_resize_fs(struct super_block *sb, ext4_fsblk_t n_blocks_count) }brelse (bh); +/* +* For bigalloc, trim the requested size to the nearest cluster +* boundary to avoid creating an unusable filesystem. We do this +* silently, instead of returning an error, to avoid breaking +* callers that blindly resize the filesystem to the full size of +* the underlying block device. +*/ +if (ext4_has_feature_bigalloc (sb)) + n_blocks_count &= ~((1 <<EXT4_CLUSTER_BITS (sb)) -1 ); + retry: o_blocks_count =ext4_blocks_count (es);
fs/f2fs/node.c +5 -1
@@ -1238,7 +1238,11 @@ struct page *f2fs_new_node_page(struct dnode_of_data *dn, unsigned int ofs)dec_valid_node_count (sbi, dn->inode, !ofs); goto fail; } -f2fs_bug_on (sbi, new_ni.blk_addr !=NULL_ADDR ); +if (unlikely (new_ni.blk_addr !=NULL_ADDR )) { + err = -EFSCORRUPTED ; +set_sbi_flag (sbi,SBI_NEED_FSCK ); + goto fail; + }#endif new_ni.nid = dn->nid; new_ni.ino = dn->inode->i_ino;
fs/f2fs/segment.c +13 -0
@@ -4449,6 +4449,12 @@ static int build_sit_entries(struct f2fs_sb_info *sbi)return err;seg_info_from_raw_sit (se, &sit); +if (se->type >=NR_PERSISTENT_LOG ) { +f2fs_err (sbi,"Invalid segment type: %u, segno: %u" , + se->type, start); +return -EFSCORRUPTED ; + } + sit_valid_blocks[SE_PAGETYPE (se)] += se->valid_blocks;/* build discard map only one time */
@@ -4495,6 +4501,13 @@ static int build_sit_entries(struct f2fs_sb_info *sbi)break ;seg_info_from_raw_sit (se, &sit); +if (se->type >=NR_PERSISTENT_LOG ) { +f2fs_err (sbi,"Invalid segment type: %u, segno: %u" , + se->type, start); + err = -EFSCORRUPTED ; +break ; + } + sit_valid_blocks[SE_PAGETYPE (se)] += se->valid_blocks;if (is_set_ckpt_flags (sbi,CP_TRIMMED_FLAG )) {
fs/nfs/nfs4idmap.c +24 -22
102 lines not on this page · raw message
fs/nfs/nfs4proc.c +11 -9
@@ -790,10 +790,9 @@ static void nfs4_slot_sequence_record_sent(struct nfs4_slot *slot,if ((s32)(seqnr - slot->seq_nr_highest_sent) >0 ) slot->seq_nr_highest_sent = seqnr; } -static void nfs4_slot_sequence_acked (struct nfs4_slot *slot, -u32 seqnr) +static void nfs4_slot_sequence_acked (struct nfs4_slot *slot,u32 seqnr) { - slot->seq_nr_highest_sent = seqnr; +nfs4_slot_sequence_record_sent (slot, seqnr); slot->seq_nr_last_acked = seqnr; }
@@ -860,7 +859,6 @@ static int nfs41_sequence_process(struct rpc_task *task, __func__, slot->slot_nr, slot->seq_nr); -nfs4_slot_sequence_acked (slot, slot->seq_nr); goto out_retry;case -NFS4ERR_RETRY_UNCACHED_REP :case -NFS4ERR_SEQ_FALSE_RETRY :
@@ -3086,12 +3084,13 @@ static int _nfs4_open_and_get_state(struct nfs4_opendata *opendata, } out: -if (opendata->lgp) { -nfs4_lgopen_release (opendata->lgp); - opendata->lgp =NULL ; - } -if (!opendata->cancelled) +if (!opendata->cancelled) { +if (opendata->lgp) { +nfs4_lgopen_release (opendata->lgp); + opendata->lgp =NULL ; + }nfs4_sequence_free_slot (&opendata->o_res.seq_res); + }return ret; }
@@ -9275,6 +9274,9 @@ static int nfs41_reclaim_complete_handle_errors(struct rpc_task *task, struct nfrpc_delay (task,NFS4_POLL_RETRY_MAX ); fallthrough;case -NFS4ERR_RETRY_UNCACHED_REP : +case -EACCES : +dprintk ("%s: failed to reclaim complete error %d for server %s, retrying\n" , + __func__, task->tk_status, clp->cl_hostname);return -EAGAIN ;case -NFS4ERR_BADSESSION :case -NFS4ERR_DEADSESSION :
include/asm-generic/bitops/atomic.h +0 -6
@@ -35,9 +35,6 @@ static inline int test_and_set_bit(unsigned int nr, volatile unsigned long *p)unsigned long mask =BIT_MASK (nr); p +=BIT_WORD (nr); -if (READ_ONCE (*p) & mask) -return 1 ; - old =atomic_long_fetch_or (mask, (atomic_long_t *)p);return !!(old & mask); }
@@ -48,9 +45,6 @@ static inline int test_and_clear_bit(unsigned int nr, volatile unsigned long *p)unsigned long mask =BIT_MASK (nr);
Lines of this file are not shown. View the raw message.
kernel/bpf/cgroup.c +60 -10
70 lines not on this page · raw message
net/netfilter/nf_conntrack_netlink.c +21 -56
77 lines not on this page · raw message
net/netfilter/nf_tables_api.c +162 -163
325 lines not on this page · raw message
net/qrtr/qrtr.c +14 -28
42 lines not on this page · raw message
sound/core/misc.c +94 -0
94 lines not on this page · raw message
sound/soc/codecs/tas2770.c +43 -55
98 lines not on this page · raw message
tools/testing/selftests/ftrace/test.d/kprobe/kprobe_syntax_errors.tc +0 -1
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.