Commit graph android_kernel_motorola_sm6375/fs
Author SHA1 Message Date
Michael Bestas
9c70abfc5e
Merge tag 'ASB-2022-11-01_11-5.4' of https://android.googlesource.com/kernel/common into android13-5.4-lahaina
https://source.android.com/docs/security/bulletin/2022-11-01

* tag 'ASB-2022-11-01_11-5.4' of https://android.googlesource.com/kernel/common:
  UPSTREAM: mm/mremap: hold the rmap lock in write mode when moving page table entries.
  FROMLIST: binder: fix UAF of alloc->vma in race with munmap()
  UPSTREAM: mm: Fix TLB flush for not-first PFNMAP mappings in unmap_region()
  UPSTREAM: mm: Force TLB flush for PFNMAP mappings before unlink_file_vma()
  UPSTREAM: af_key: Do not call xfrm_probe_algs in parallel
  UPSTREAM: wifi: cfg80211: fix u8 overflow in cfg80211_update_notlisted_nontrans()
  UPSTREAM: wifi: cfg80211/mac80211: reject bad MBSSID elements
  UPSTREAM: wifi: cfg80211: ensure length byte is present before access
  UPSTREAM: wifi: cfg80211: fix BSS refcounting bugs
  UPSTREAM: wifi: cfg80211: avoid nontransmitted BSS list corruption
  UPSTREAM: wifi: mac80211_hwsim: avoid mac80211 warning on bad rate
  UPSTREAM: wifi: cfg80211: update hidden BSSes to avoid WARN_ON
  UPSTREAM: mac80211: mlme: find auth challenge directly
  UPSTREAM: wifi: mac80211: don't parse mbssid in assoc response
  UPSTREAM: wifi: mac80211: fix MBSSID parsing use-after-free
  ANDROID: Drop explicit 'CONFIG_INIT_STACK_ALL_ZERO=y' from gki_defconfig
  UPSTREAM: hardening: Remove Clang's enable flag for -ftrivial-auto-var-init=zero
  UPSTREAM: hardening: Avoid harmless Clang option under CONFIG_INIT_STACK_ALL_ZERO
  UPSTREAM: hardening: Clarify Kconfig text for auto-var-init
  ANDROID: GKI: Update FCNT KMI symbol list
  ANDROID: Fix kenelci build-break for !CONFIG_PERF_EVENTS
  BACKPORT: HID: steam: Prevent NULL pointer dereference in steam_{recv,send}_report
  ANDROID: ABI: Update allowed list for QCOM
  UPSTREAM: wifi: mac80211_hwsim: use 32-bit skb cookie
  UPSTREAM: wifi: mac80211_hwsim: add back erroneously removed cast
  UPSTREAM: wifi: mac80211_hwsim: fix race condition in pending packet
  ANDROID: incfs: Add check for ATTR_KILL_SUID and ATTR_MODE in incfs_setattr
  Linux 5.4.210
  x86/speculation: Add LFENCE to RSB fill sequence
  x86/speculation: Add RSB VM Exit protections
  macintosh/adb: fix oob read in do_adb_query() function
  media: v4l2-mem2mem: Apply DST_QUEUE_OFF_BASE on MMAP buffers across ioctls
  selftests: KVM: Handle compiler optimizations in ucall
  KVM: Don't null dereference ops->destroy
  selftests/bpf: Fix "dubious pointer arithmetic" test
  selftests/bpf: Fix test_align verifier log patterns
  bpf: Test_verifier, #70 error message updates for 32-bit right shift
  selftests/bpf: Extend verifier and bpf_sock tests for dst_port loads
  bpf: Verifer, adjust_scalar_min_max_vals to always call update_reg_bounds()
  ACPI: APEI: Better fix to avoid spamming the console with old error logs
  ACPI: video: Shortening quirk list by identifying Clevo by board_name only
  ACPI: video: Force backlight native for some TongFang devices
  thermal: Fix NULL pointer dereferences in of_thermal_ functions
  ANDROID: GKI: db845c: Update symbols list and ABI
  Linux 5.4.209
  scsi: core: Fix race between handling STS_RESOURCE and completion
  mt7601u: add USB device ID for some versions of XiaoDu WiFi Dongle.
  ARM: crypto: comment out gcc warning that breaks clang builds
  sctp: leave the err path free in sctp_stream_init to sctp_stream_free
  sfc: disable softirqs for ptp TX
  perf symbol: Correct address for bss symbols
  virtio-net: fix the race between refill work and close
  netfilter: nf_queue: do not allow packet truncation below transport header offset
  sctp: fix sleep in atomic context bug in timer handlers
  i40e: Fix interface init with MSI interrupts (no MSI-X)
  tcp: Fix a data-race around sysctl_tcp_comp_sack_nr.
  tcp: Fix a data-race around sysctl_tcp_comp_sack_delay_ns.
  Documentation: fix sctp_wmem in ip-sysctl.rst
  tcp: Fix a data-race around sysctl_tcp_invalid_ratelimit.
  tcp: Fix a data-race around sysctl_tcp_autocorking.
  tcp: Fix a data-race around sysctl_tcp_min_rtt_wlen.
  tcp: Fix a data-race around sysctl_tcp_min_tso_segs.
  net: sungem_phy: Add of_node_put() for reference returned by of_get_parent()
  igmp: Fix data-races around sysctl_igmp_qrv.
  ipv6/addrconf: fix a null-ptr-deref bug for ip6_ptr
  net: ping6: Fix memleak in ipv6_renew_options().
  tcp: Fix a data-race around sysctl_tcp_challenge_ack_limit.
  tcp: Fix a data-race around sysctl_tcp_limit_output_bytes.
  scsi: ufs: host: Hold reference returned by of_parse_phandle()
  ice: do not setup vlan for loopback VSI
  ice: check (DD | EOF) bits on Rx descriptor rather than (EOP | RS)
  tcp: Fix a data-race around sysctl_tcp_nometrics_save.
  tcp: Fix a data-race around sysctl_tcp_frto.
  tcp: Fix a data-race around sysctl_tcp_adv_win_scale.
  tcp: Fix a data-race around sysctl_tcp_app_win.
  tcp: Fix data-races around sysctl_tcp_dsack.
  s390/archrandom: prevent CPACF trng invocations in interrupt context
  ntfs: fix use-after-free in ntfs_ucsncmp()
  Bluetooth: L2CAP: Fix use-after-free caused by l2cap_chan_put
  ANDROID: restore some removed refcount functions
  ANDROID: add tty_schedule_flip() back to the kernel
  Linux 5.4.208
  x86: drop bogus "cc" clobber from __try_cmpxchg_user_asm()
  net: usb: ax88179_178a needs FLAG_SEND_ZLP
  tty: use new tty_insert_flip_string_and_push_buffer() in pty_write()
  tty: extract tty_flip_buffer_commit() from tty_flip_buffer_push()
  tty: drop tty_schedule_flip()
  tty: the rest, stop using tty_schedule_flip()
  tty: drivers/tty/, stop using tty_schedule_flip()
  Bluetooth: Fix bt_skb_sendmmsg not allocating partial chunks
  Bluetooth: SCO: Fix sco_send_frame returning skb->len
  Bluetooth: Fix passing NULL to PTR_ERR
  Bluetooth: RFCOMM: Replace use of memcpy_from_msg with bt_skb_sendmmsg
  Bluetooth: SCO: Replace use of memcpy_from_msg with bt_skb_sendmsg
  Bluetooth: Add bt_skb_sendmmsg helper
  Bluetooth: Add bt_skb_sendmsg helper
  ALSA: memalloc: Align buffer allocations in page size
  bitfield.h: Fix "type of reg too small for mask" test
  x86/mce: Deduplicate exception handling
  mmap locking API: initial implementation as rwsem wrappers
  x86/uaccess: Implement macros for CMPXCHG on user addresses
  x86: get rid of small constant size cases in raw_copy_{to,from}_user()
  locking/refcount: Consolidate implementations of refcount_t
  locking/refcount: Consolidate REFCOUNT_{MAX,SATURATED} definitions
  locking/refcount: Move saturation warnings out of line
  locking/refcount: Improve performance of generic REFCOUNT_FULL code
  locking/refcount: Move the bulk of the REFCOUNT_FULL implementation into the <linux/refcount.h> header
  locking/refcount: Remove unused refcount_*_checked() variants
  locking/refcount: Ensure integer operands are treated as signed
  locking/refcount: Define constants for saturation and max refcount values
  ima: remove the IMA_TEMPLATE Kconfig option
  dlm: fix pending remove if msg allocation fails
  bpf: Make sure mac_header was set before using it
  mm/mempolicy: fix uninit-value in mpol_rebind_policy()
  spi: bcm2835: bcm2835_spi_handle_err(): fix NULL pointer deref for non DMA transfers
  tcp: Fix data-races around sysctl_tcp_max_reordering.
  tcp: Fix a data-race around sysctl_tcp_rfc1337.
  tcp: Fix a data-race around sysctl_tcp_stdurg.
  tcp: Fix a data-race around sysctl_tcp_retrans_collapse.
  tcp: Fix data-races around sysctl_tcp_slow_start_after_idle.
  tcp: Fix a data-race around sysctl_tcp_thin_linear_timeouts.
  tcp: Fix data-races around sysctl_tcp_recovery.
  tcp: Fix a data-race around sysctl_tcp_early_retrans.
  tcp: Fix data-races around sysctl knobs related to SYN option.
  udp: Fix a data-race around sysctl_udp_l3mdev_accept.
  ipv4: Fix a data-race around sysctl_fib_multipath_use_neigh.
  be2net: Fix buffer overflow in be_get_module_eeprom
  gpio: pca953x: only use single read/write for No AI mode
  ixgbe: Add locking to prevent panic when setting sriov_numvfs to zero
  i40e: Fix erroneous adapter reinitialization during recovery process
  iavf: Fix handling of dummy receive descriptors
  tcp: Fix data-races around sysctl_tcp_fastopen.
  tcp: Fix data-races around sysctl_max_syn_backlog.
  tcp: Fix a data-race around sysctl_tcp_tw_reuse.
  tcp: Fix a data-race around sysctl_tcp_notsent_lowat.
  tcp: Fix data-races around some timeout sysctl knobs.
  tcp: Fix data-races around sysctl_tcp_reordering.
  tcp: Fix data-races around sysctl_tcp_syncookies.
  igmp: Fix a data-race around sysctl_igmp_max_memberships.
  igmp: Fix data-races around sysctl_igmp_llm_reports.
  net/tls: Fix race in TLS device down flow
  net: stmmac: fix dma queue left shift overflow issue
  i2c: cadence: Change large transfer count reset logic to be unconditional
  tcp: Fix a data-race around sysctl_tcp_probe_interval.
  tcp: Fix a data-race around sysctl_tcp_probe_threshold.
  tcp: Fix a data-race around sysctl_tcp_mtu_probe_floor.
  tcp: Fix data-races around sysctl_tcp_min_snd_mss.
  tcp: Fix data-races around sysctl_tcp_base_mss.
  tcp: Fix data-races around sysctl_tcp_mtu_probing.
  tcp/dccp: Fix a data-race around sysctl_tcp_fwmark_accept.
  ip: Fix a data-race around sysctl_fwmark_reflect.
  ip: Fix data-races around sysctl_ip_nonlocal_bind.
  ip: Fix data-races around sysctl_ip_fwd_use_pmtu.
  ip: Fix data-races around sysctl_ip_no_pmtu_disc.
  igc: Reinstate IGC_REMOVED logic and implement it properly
  perf/core: Fix data race between perf_event_set_output() and perf_mmap_close()
  pinctrl: ralink: Check for null return of devm_kcalloc
  power/reset: arm-versatile: Fix refcount leak in versatile_reboot_probe
  xfrm: xfrm_policy: fix a possible double xfrm_pols_put() in xfrm_bundle_lookup()
  serial: mvebu-uart: correctly report configured baudrate value
  PCI: hv: Fix interrupt mapping for multi-MSI
  PCI: hv: Reuse existing IRTE allocation in compose_msi_msg()
  PCI: hv: Fix hv_arch_irq_unmask() for multi-MSI
  PCI: hv: Fix multi-MSI to allow more than one MSI vector
  xen/gntdev: Ignore failure to unmap INVALID_GRANT_HANDLE
  lockdown: Fix kexec lockdown bypass with ima policy
  mlxsw: spectrum_router: Fix IPv4 nexthop gateway indication
  riscv: add as-options for modules with assembly compontents
  pinctrl: stm32: fix optional IRQ support to gpios
  Revert "cgroup: Use separate src/dst nodes when preloading css_sets for migration"
  Linux 5.4.207
  can: m_can: m_can_tx_handler(): fix use after free of skb
  serial: pl011: UPSTAT_AUTORTS requires .throttle/unthrottle
  serial: stm32: Clear prev values before setting RTS delays
  serial: 8250: fix return error code in serial8250_request_std_resource()
  tty: serial: samsung_tty: set dma burst_size to 1
  usb: dwc3: gadget: Fix event pending check
  usb: typec: add missing uevent when partner support PD
  USB: serial: ftdi_sio: add Belimo device ids
  signal handling: don't use BUG_ON() for debugging
  ARM: dts: stm32: use the correct clock source for CEC on stm32mp151
  soc: ixp4xx/npe: Fix unused match warning
  x86: Clear .brk area at early boot
  irqchip: or1k-pic: Undefine mask_ack for level triggered hardware
  ASoC: madera: Fix event generation for rate controls
  ASoC: madera: Fix event generation for OUT1 demux
  ASoC: cs47l15: Fix event generation for low power mux control
  ASoC: wm5110: Fix DRE control
  ASoC: ops: Fix off by one in range control validation
  net: sfp: fix memory leak in sfp_probe()
  nvme: fix regression when disconnect a recovering ctrl
  NFC: nxp-nci: don't print header length mismatch on i2c error
  net: tipc: fix possible refcount leak in tipc_sk_create()
  platform/x86: hp-wmi: Ignore Sanitization Mode event
  cpufreq: pmac32-cpufreq: Fix refcount leak bug
  netfilter: br_netfilter: do not skip all hooks with 0 priority
  virtio_mmio: Restore guest page size on resume
  virtio_mmio: Add missing PM calls to freeze/restore
  mm: sysctl: fix missing numa_stat when !CONFIG_HUGETLB_PAGE
  sfc: fix kernel panic when creating VF
  seg6: bpf: fix skb checksum in bpf_push_seg6_encap()
  seg6: fix skb checksum in SRv6 End.B6 and End.B6.Encaps behaviors
  seg6: fix skb checksum evaluation in SRH encapsulation/insertion
  sfc: fix use after free when disabling sriov
  net: ftgmac100: Hold reference returned by of_get_child_by_name()
  ipv4: Fix data-races around sysctl_ip_dynaddr.
  raw: Fix a data-race around sysctl_raw_l3mdev_accept.
  icmp: Fix a data-race around sysctl_icmp_ratemask.
  icmp: Fix a data-race around sysctl_icmp_ratelimit.
  drm/i915/gt: Serialize TLB invalidates with GT resets
  ARM: dts: sunxi: Fix SPI NOR campatible on Orange Pi Zero
  ARM: dts: at91: sama5d2: Fix typo in i2s1 node
  ipv4: Fix a data-race around sysctl_fib_sync_mem.
  icmp: Fix data-races around sysctl.
  cipso: Fix data-races around sysctl.
  net: Fix data-races around sysctl_mem.
  inetpeer: Fix data-races around sysctl.
  net: stmmac: dwc-qos: Disable split header for Tegra194
  ASoC: sgtl5000: Fix noise on shutdown/remove
  ima: Fix a potential integer overflow in ima_appraise_measurement
  drm/i915: fix a possible refcount leak in intel_dp_add_mst_connector()
  ARM: 9210/1: Mark the FDT_FIXED sections as shareable
  ARM: 9209/1: Spectre-BHB: avoid pr_info() every time a CPU comes out of idle
  ARM: dts: imx6qdl-ts7970: Fix ngpio typo and count
  ext4: fix race condition between ext4_write and ext4_convert_inline_data
  sched/rt: Disable RT_RUNTIME_SHARE by default
  Revert "evm: Fix memleak in init_desc"
  nilfs2: fix incorrect masking of permission flags for symlinks
  drm/panfrost: Fix shrinker list corruption by madvise IOCTL
  cgroup: Use separate src/dst nodes when preloading css_sets for migration
  wifi: mac80211: fix queue selection for mesh/OCB interfaces
  ARM: 9214/1: alignment: advance IT state after emulating Thumb instruction
  ARM: 9213/1: Print message about disabled Spectre workarounds only once
  ip: fix dflt addr selection for connected nexthop
  net: sock: tracing: Fix sock_exceed_buf_limit not to dereference stale pointer
  tracing/histograms: Fix memory leak problem
  xen/netback: avoid entering xenvif_rx_next_skb() with an empty rx queue
  ALSA: hda/realtek - Enable the headset-mic on a Xiaomi's laptop
  ALSA: hda/realtek - Fix headset mic problem for a HP machine with alc221
  ALSA: hda/realtek - Fix headset mic problem for a HP machine with alc671
  ALSA: hda/conexant: Apply quirk for another HP ProDesk 600 G3 model
  ALSA: hda - Add fixup for Dell Latitidue E5430
  Linux 5.4.206
  Revert "mtd: rawnand: gpmi: Fix setting busy timeout setting"
  Linux 5.4.205
  dmaengine: ti: Add missing put_device in ti_dra7_xbar_route_allocate
  dmaengine: ti: Fix refcount leak in ti_dra7_xbar_route_allocate
  dmaengine: at_xdma: handle errors of at_xdmac_alloc_desc() correctly
  dmaengine: pl330: Fix lockdep warning about non-static key
  ida: don't use BUG_ON() for debugging
  dt-bindings: dma: allwinner,sun50i-a64-dma: Fix min/max typo
  misc: rtsx_usb: set return value in rsp_buf alloc err path
  misc: rtsx_usb: use separate command and response buffers
  misc: rtsx_usb: fix use of dma mapped buffer for usb bulk transfer
  dmaengine: imx-sdma: Allow imx8m for imx7 FW revs
  i2c: cadence: Unregister the clk notifier in error path
  selftests: forwarding: fix error message in learning_test
  selftests: forwarding: fix learning_test when h1 supports IFF_UNICAST_FLT
  selftests: forwarding: fix flood_unicast_test when h2 supports IFF_UNICAST_FLT
  ibmvnic: Properly dispose of all skbs during a failover.
  ARM: at91: pm: use proper compatibles for sam9x60's rtc and rtt
  ARM: at91: pm: use proper compatible for sama5d2's rtc
  pinctrl: sunxi: sunxi_pconf_set: use correct offset
  pinctrl: sunxi: a83t: Fix NAND function name for some pins
  ARM: meson: Fix refcount leak in meson_smp_prepare_cpus
  xfs: remove incorrect ASSERT in xfs_rename
  can: kvaser_usb: kvaser_usb_leaf: fix bittiming limits
  can: kvaser_usb: kvaser_usb_leaf: fix CAN clock frequency regression
  can: kvaser_usb: replace run-time checks with struct kvaser_usb_driver_info
  powerpc/powernv: delay rng platform device creation until later in boot
  video: of_display_timing.h: include errno.h
  fbcon: Prevent that screen size is smaller than font size
  fbcon: Disallow setting font bigger than screen size
  fbmem: Check virtual screen sizes in fb_set_var()
  fbdev: fbmem: Fix logo center image dx issue
  iommu/vt-d: Fix PCI bus rescan device hot add
  net: rose: fix UAF bug caused by rose_t0timer_expiry
  usbnet: fix memory leak in error case
  can: gs_usb: gs_usb_open/close(): fix memory leak
  can: grcan: grcan_probe(): remove extra of_node_get()
  can: bcm: use call_rcu() instead of costly synchronize_rcu()
  mm/slub: add missing TID updates on slab deactivation
  esp: limit skb_page_frag_refill use to a single page
  Linux 5.4.204
  clocksource/drivers/ixp4xx: remove EXPORT_SYMBOL_GPL from ixp4xx_timer_setup()
  net: usb: qmi_wwan: add Telit 0x1070 composition
  net: usb: qmi_wwan: add Telit 0x1060 composition
  xen/arm: Fix race in RB-tree based P2M accounting
  xen/blkfront: force data bouncing when backend is untrusted
  xen/netfront: force data bouncing when backend is untrusted
  xen/netfront: fix leaking data in shared pages
  xen/blkfront: fix leaking data in shared pages
  selftests/rseq: Change type of rseq_offset to ptrdiff_t
  selftests/rseq: x86-32: use %gs segment selector for accessing rseq thread area
  selftests/rseq: x86-64: use %fs segment selector for accessing rseq thread area
  selftests/rseq: Fix: work-around asm goto compiler bugs
  selftests/rseq: Remove arm/mips asm goto compiler work-around
  selftests/rseq: Fix warnings about #if checks of undefined tokens
  selftests/rseq: Fix ppc32 offsets by using long rather than off_t
  selftests/rseq: Fix ppc32 missing instruction selection "u" and "x" for load/store
  selftests/rseq: Fix ppc32: wrong rseq_cs 32-bit field pointer on big endian
  selftests/rseq: Uplift rseq selftests for compatibility with glibc-2.35
  selftests/rseq: Introduce thread pointer getters
  selftests/rseq: Introduce rseq_get_abi() helper
  selftests/rseq: Remove volatile from __rseq_abi
  selftests/rseq: Remove useless assignment to cpu variable
  selftests/rseq: introduce own copy of rseq uapi header
  selftests/rseq: remove ARRAY_SIZE define from individual tests
  rseq/selftests,x86_64: Add rseq_offset_deref_addv()
  ipv6/sit: fix ipip6_tunnel_get_prl return value
  sit: use min
  net: dsa: bcm_sf2: force pause link settings
  hwmon: (ibmaem) don't call platform_device_del() if platform_device_add() fails
  xen/gntdev: Avoid blocking in unmap_grant_pages()
  net: tun: avoid disabling NAPI twice
  NFC: nxp-nci: Don't issue a zero length i2c_master_read()
  nfc: nfcmrvl: Fix irq_of_parse_and_map() return value
  net: bonding: fix use-after-free after 802.3ad slave unbind
  net: bonding: fix possible NULL deref in rlb code
  net/sched: act_api: Notify user space if any actions were flushed before error
  netfilter: nft_dynset: restore set element counter when failing to update
  s390: remove unneeded 'select BUILD_BIN2C'
  PM / devfreq: exynos-ppmu: Fix refcount leak in of_get_devfreq_events
  caif_virtio: fix race between virtio_device_ready() and ndo_open()
  net: ipv6: unexport __init-annotated seg6_hmac_net_init()
  usbnet: fix memory allocation in helpers
  linux/dim: Fix divide by 0 in RDMA DIM
  RDMA/qedr: Fix reporting QP timeout attribute
  net: tun: stop NAPI when detaching queues
  net: tun: unlink NAPI from device on destruction
  selftests/net: pass ipv6_args to udpgso_bench's IPv6 TCP test
  virtio-net: fix race between ndo_open() and virtio_device_ready()
  net: usb: ax88179_178a: Fix packet receiving
  net: rose: fix UAF bugs caused by timer handler
  SUNRPC: Fix READ_PLUS crasher
  s390/archrandom: simplify back to earlier design and initialize earlier
  dm raid: fix KASAN warning in raid5_add_disks
  dm raid: fix accesses beyond end of raid member array
  powerpc/bpf: Fix use of user_pt_regs in uapi
  powerpc/prom_init: Fix kernel config grep
  nvdimm: Fix badblocks clear off-by-one error
  ipv6: take care of disable_policy when restoring routes
  Linux 5.4.203
  crypto: arm/ghash-ce - define fpu before fpu registers are referenced
  crypto: arm - use Kconfig based compiler checks for crypto opcodes
  ARM: 9029/1: Make iwmmxt.S support Clang's integrated assembler
  ARM: OMAP2+: drop unnecessary adrl
  ARM: 8929/1: use APSR_nzcv instead of r15 as mrc operand
  ARM: 8933/1: replace Sun/Solaris style flag on section directive
  crypto: arm/sha512-neon - avoid ADRL pseudo instruction
  crypto: arm/sha256-neon - avoid ADRL pseudo instruction
  ARM: 8971/1: replace the sole use of a symbol with its definition
  ARM: 8990/1: use VFP assembler mnemonics in register load/store macros
  ARM: 8989/1: use .fpu assembler directives instead of assembler arguments
  net: mscc: ocelot: allow unregistered IP multicast flooding
  kexec_file: drop weak attribute from arch_kexec_apply_relocations[_add]
  powerpc/ftrace: Remove ftrace init tramp once kernel init is complete
  drm: remove drm_fb_helper_modinit
  Linux 5.4.202
  powerpc/pseries: wire up rng during setup_arch()
  kbuild: link vmlinux only once for CONFIG_TRIM_UNUSED_KSYMS (2nd attempt)
  random: update comment from copy_to_user() -> copy_to_iter()
  modpost: fix section mismatch check for exported init/exit sections
  ARM: cns3xxx: Fix refcount leak in cns3xxx_init
  ARM: Fix refcount leak in axxia_boot_secondary
  soc: bcm: brcmstb: pm: pm-arm: Fix refcount leak in brcmstb_pm_probe
  ARM: exynos: Fix refcount leak in exynos_map_pmu
  ARM: dts: imx6qdl: correct PU regulator ramp delay
  powerpc/powernv: wire up rng during setup_arch
  powerpc/rtas: Allow ibm,platform-dump RTAS call with null buffer address
  powerpc: Enable execve syscall exit tracepoint
  parisc: Enable ARCH_HAS_STRICT_MODULE_RWX
  xtensa: Fix refcount leak bug in time.c
  xtensa: xtfpga: Fix refcount leak bug in setup
  iio: adc: axp288: Override TS pin bias current for some models
  iio: adc: stm32: fix maximum clock rate for stm32mp15x
  iio: trigger: sysfs: fix use-after-free on remove
  iio: gyro: mpu3050: Fix the error handling in mpu3050_power_up()
  iio: accel: mma8452: ignore the return value of reset operation
  iio:accel:mxc4005: rearrange iio trigger get and register
  iio:accel:bma180: rearrange iio trigger get and register
  iio:chemical:ccs811: rearrange iio trigger get and register
  usb: chipidea: udc: check request status before setting device address
  xhci: turn off port power in shutdown
  iio: adc: vf610: fix conversion mode sysfs node name
  s390/cpumf: Handle events cycles and instructions identical
  gpio: winbond: Fix error code in winbond_gpio_get()
  Revert "net/tls: fix tls_sk_proto_close executed repeatedly"
  virtio_net: fix xdp_rxq_info bug after suspend/resume
  igb: Make DMA faster when CPU is active on the PCIe link
  regmap-irq: Fix a bug in regmap_irq_enable() for type_in_mask chips
  ice: ethtool: advertise 1000M speeds properly
  afs: Fix dynamic root getattr
  MIPS: Remove repetitive increase irq_err_count
  x86/xen: Remove undefined behavior in setup_features()
  udmabuf: add back sanity check
  net/tls: fix tls_sk_proto_close executed repeatedly
  erspan: do not assume transport header is always set
  drm/msm/mdp4: Fix refcount leak in mdp4_modeset_init_intf
  net/sched: sch_netem: Fix arithmetic in netem_dump() for 32-bit platforms
  bonding: ARP monitor spams NETDEV_NOTIFY_PEERS notifiers
  phy: aquantia: Fix AN when higher speeds than 1G are not advertised
  bpf: Fix request_sock leak in sk lookup helpers
  USB: serial: option: add Quectel RM500K module support
  USB: serial: option: add Quectel EM05-G modem
  USB: serial: option: add Telit LE910Cx 0x1250 composition
  random: quiet urandom warning ratelimit suppression message
  dm mirror log: clear log bits up to BITS_PER_LONG boundary
  dm era: commit metadata in postsuspend after worker stops
  ata: libata: add qc->flags in ata_qc_complete_template tracepoint
  mtd: rawnand: gpmi: Fix setting busy timeout setting
  mmc: sdhci-pci-o2micro: Fix card detect by dealing with debouncing
  net: openvswitch: fix parsing of nw_proto for IPv6 fragments
  ALSA: hda/realtek: Add quirk for Clevo PD70PNT
  ALSA: hda/realtek - ALC897 headset MIC no sound
  ALSA: hda/conexant: Fix missing beep setup
  ALSA: hda/via: Fix missing beep setup
  random: schedule mix_interrupt_randomness() less often
  vt: drop old FONT ioctls
  Linux 5.4.201
  Revert "hwmon: Make chip parameter for with_info API mandatory"
  arm64: mm: Don't invalidate FROM_DEVICE buffers at start of DMA transfer
  tcp: drop the hash_32() part from the index calculation
  tcp: increase source port perturb table to 2^16
  tcp: dynamically allocate the perturb table used by source ports
  tcp: add small random increments to the source port
  tcp: use different parts of the port_offset for index and offset
  tcp: add some entropy in __inet_hash_connect()
  usb: gadget: u_ether: fix regression in setting fixed MAC address
  dm: remove special-casing of bio-based immutable singleton target on NVMe
  s390/mm: use non-quiescing sske for KVM switch to keyed guest
  UPSTREAM: ext4: verify dir block before splitting it
  UPSTREAM: ext4: fix use-after-free in ext4_rename_dir_prepare
  BACKPORT: ext4: Only advertise encrypted_casefold when encryption and unicode are enabled
  BACKPORT: ext4: fix no-key deletion for encrypt+casefold
  BACKPORT: ext4: optimize match for casefolded encrypted dirs
  BACKPORT: ext4: handle casefolding with encryption
  Revert "ANDROID: ext4: Handle casefolding with encryption"
  Revert "ANDROID: ext4: Optimize match for casefolded encrypted dirs"
  ANDROID: cpu/hotplug: avoid breaking Android ABI by fusing cpuhp steps
  ANDROID: change function signatures for some random functions.
  Revert "mailbox: forward the hrtimer if not queued and under a lock"
  Revert "drm: fix EDID struct for old ARM OABI format"
  Revert "ALSA: jack: Access input_dev under mutex"
  Linux 5.4.200
  powerpc/mm: Switch obsolete dssall to .long
  riscv: Less inefficient gcc tishift helpers (and export their symbols)
  RISC-V: fix barrier() use in <vdso/processor.h>
  arm64: kprobes: Use BRK instead of single-step when executing instructions out-of-line
  net: openvswitch: fix leak of nested actions
  net: openvswitch: fix misuse of the cached connection on tuple changes
  net/sched: act_police: more accurate MTU policing
  virtio-pci: Remove wrong address verification in vp_del_vqs()
  ALSA: hda/realtek: fix right sounds and mute/micmute LEDs for HP machine
  ALSA: hda/realtek: fix mute/micmute LEDs for HP 440 G8
  ext4: add reserved GDT blocks check
  ext4: make variable "count" signed
  ext4: fix bug_on ext4_mb_use_inode_pa
  dm mirror log: round up region bitmap size to BITS_PER_LONG
  serial: 8250: Store to lsr_save_flags after lsr read
  usb: gadget: lpc32xx_udc: Fix refcount leak in lpc32xx_udc_probe
  usb: dwc2: Fix memory leak in dwc2_hcd_init
  USB: serial: io_ti: add Agilent E5805A support
  USB: serial: option: add support for Cinterion MV31 with new baseline
  comedi: vmk80xx: fix expression for tx buffer size
  i2c: designware: Use standard optional ref clock implementation
  irqchip/gic-v3: Fix refcount leak in gic_populate_ppi_partitions
  irqchip/gic-v3: Fix error handling in gic_populate_ppi_partitions
  irqchip/gic/realview: Fix refcount leak in realview_gic_of_init
  faddr2line: Fix overlapping text section failures, the sequel
  certs/blacklist_hashes.c: fix const confusion in certs blacklist
  arm64: ftrace: fix branch range checks
  net: bgmac: Fix an erroneous kfree() in bgmac_remove()
  mlxsw: spectrum_cnt: Reorder counter pools
  misc: atmel-ssc: Fix IRQ check in ssc_probe
  tty: goldfish: Fix free_irq() on remove
  i40e: Fix call trace in setup_tx_descriptors
  i40e: Fix calculating the number of queue pairs
  i40e: Fix adding ADQ filter to TC0
  clocksource: hyper-v: unexport __init-annotated hv_init_clocksource()
  pNFS: Don't keep retrying if the server replied NFS4ERR_LAYOUTUNAVAILABLE
  random: credit cpu and bootloader seeds by default
  net: ethernet: mtk_eth_soc: fix misuse of mem alloc interface netdev[napi]_alloc_frag
  ipv6: Fix signed integer overflow in l2tp_ip6_sendmsg
  nfc: nfcmrvl: Fix memory leak in nfcmrvl_play_deferred
  virtio-mmio: fix missing put_device() when vm_cmdline_parent registration failed
  ALSA: hda/realtek - Add HW8326 support
  scsi: pmcraid: Fix missing resource cleanup in error case
  scsi: ipr: Fix missing/incorrect resource cleanup in error case
  scsi: lpfc: Allow reduced polling rate for nvme_admin_async_event cmd completion
  scsi: lpfc: Fix port stuck in bypassed state after LIP in PT2PT topology
  scsi: vmw_pvscsi: Expand vcpuHint to 16 bits
  ASoC: wm_adsp: Fix event generation for wm_adsp_fw_put()
  ASoC: es8328: Fix event generation for deemphasis control
  ASoC: wm8962: Fix suspend while playing music
  ata: libata-core: fix NULL pointer deref in ata_host_alloc_pinfo()
  ASoC: cs42l56: Correct typo in minimum level for SX volume controls
  ASoC: cs42l52: Correct TLV for Bypass Volume
  ASoC: cs53l30: Correct number of volume levels on SX controls
  ASoC: cs35l36: Update digital volume TLV
  ASoC: cs42l52: Fix TLV scales for mixer controls
  dma-debug: make things less spammy under memory pressure
  ASoC: nau8822: Add operation for internal PLL off and on
  powerpc/kasan: Silence KASAN warnings in __get_wchan()
  random: account for arch randomness in bits
  random: mark bootloader randomness code as __init
  random: avoid checking crng_ready() twice in random_init()
  crypto: drbg - make reseeding from get_random_bytes() synchronous
  crypto: drbg - always try to free Jitter RNG instance
  crypto: drbg - move dynamic ->reseed_threshold adjustments to __drbg_seed()
  crypto: drbg - track whether DRBG was seeded with !rng_is_initialized()
  crypto: drbg - prepare for more fine-grained tracking of seeding state
  crypto: drbg - always seeded with SP800-90B compliant noise source
  Revert "random: use static branch for crng_ready()"
  random: check for signals after page of pool writes
  random: wire up fops->splice_{read,write}_iter()
  random: convert to using fops->write_iter()
  random: convert to using fops->read_iter()
  random: unify batched entropy implementations
  random: move randomize_page() into mm where it belongs
  random: move initialization functions out of hot pages
  random: make consistent use of buf and len
  random: use proper return types on get_random_{int,long}_wait()
  random: remove extern from functions in header
  random: use static branch for crng_ready()
  random: credit architectural init the exact amount
  random: handle latent entropy and command line from random_init()
  random: use proper jiffies comparison macro
  random: remove ratelimiting for in-kernel unseeded randomness
  random: move initialization out of reseeding hot path
  random: avoid initializing twice in credit race
  random: use symbolic constants for crng_init states
  siphash: use one source of truth for siphash permutations
  random: help compiler out with fast_mix() by using simpler arguments
  random: do not use input pool from hard IRQs
  random: order timer entropy functions below interrupt functions
  random: do not pretend to handle premature next security model
  random: use first 128 bits of input as fast init
  random: do not use batches when !crng_ready()
  random: insist on random_get_entropy() existing in order to simplify
  xtensa: use fallback for random_get_entropy() instead of zero
  sparc: use fallback for random_get_entropy() instead of zero
  um: use fallback for random_get_entropy() instead of zero
  x86/tsc: Use fallback for random_get_entropy() instead of zero
  nios2: use fallback for random_get_entropy() instead of zero
  arm: use fallback for random_get_entropy() instead of zero
  mips: use fallback for random_get_entropy() instead of just c0 random
  m68k: use fallback for random_get_entropy() instead of zero
  timekeeping: Add raw clock fallback for random_get_entropy()
  powerpc: define get_cycles macro for arch-override
  alpha: define get_cycles macro for arch-override
  parisc: define get_cycles macro for arch-override
  s390: define get_cycles macro for arch-override
  ia64: define get_cycles macro for arch-override
  init: call time_init() before rand_initialize()
  random: fix sysctl documentation nits
  random: document crng_fast_key_erasure() destination possibility
  random: make random_get_entropy() return an unsigned long
  random: allow partial reads if later user copies fail
  random: check for signals every PAGE_SIZE chunk of /dev/[u]random
  random: check for signal_pending() outside of need_resched() check
  random: do not allow user to keep crng key around on stack
  random: do not split fast init input in add_hwgenerator_randomness()
  random: mix build-time latent entropy into pool at init
  random: re-add removed comment about get_random_{u32,u64} reseeding
  random: treat bootloader trust toggle the same way as cpu trust toggle
  random: skip fast_init if hwrng provides large chunk of entropy
  random: check for signal and try earlier when generating entropy
  random: reseed more often immediately after booting
  random: make consistent usage of crng_ready()
  random: use SipHash as interrupt entropy accumulator
  random: replace custom notifier chain with standard one
  random: don't let 644 read-only sysctls be written to
  random: give sysctl_random_min_urandom_seed a more sensible value
  random: do crng pre-init loading in worker rather than irq
  random: unify cycles_t and jiffies usage and types
  random: cleanup UUID handling
  random: only wake up writers after zap if threshold was passed
  random: round-robin registers as ulong, not u32
  random: clear fast pool, crng, and batches in cpuhp bring up
  random: pull add_hwgenerator_randomness() declaration into random.h
  random: check for crng_init == 0 in add_device_randomness()
  random: unify early init crng load accounting
  random: do not take pool spinlock at boot
  random: defer fast pool mixing to worker
  random: rewrite header introductory comment
  random: group sysctl functions
  random: group userspace read/write functions
  random: group entropy collection functions
  random: group entropy extraction functions
  random: group crng functions
  random: group initialization wait functions
  random: remove whitespace and reorder includes
  random: remove useless header comment
  random: introduce drain_entropy() helper to declutter crng_reseed()
  random: deobfuscate irq u32/u64 contributions
  random: add proper SPDX header
  random: remove unused tracepoints
  random: remove ifdef'd out interrupt bench
  random: tie batched entropy generation to base_crng generation
  random: fix locking for crng_init in crng_reseed()
  random: zero buffer after reading entropy from userspace
  random: remove outdated INT_MAX >> 6 check in urandom_read()
  random: make more consistent use of integer types
  random: use hash function for crng_slow_load()
  random: use simpler fast key erasure flow on per-cpu keys
  random: absorb fast pool into input pool after fast load
  random: do not xor RDRAND when writing into /dev/random
  random: ensure early RDSEED goes through mixer on init
  random: inline leaves of rand_initialize()
  random: get rid of secondary crngs
  random: use RDSEED instead of RDRAND in entropy extraction
  random: fix locking in crng_fast_load()
  random: remove batched entropy locking
  random: remove use_input_pool parameter from crng_reseed()
  random: make credit_entropy_bits() always safe
  random: always wake up entropy writers after extraction
  random: use linear min-entropy accumulation crediting
  random: simplify entropy debiting
  random: use computational hash for entropy extraction
  random: only call crng_finalize_init() for primary_crng
  random: access primary_pool directly rather than through pointer
  random: continually use hwgenerator randomness
  random: simplify arithmetic function flow in account()
  random: selectively clang-format where it makes sense
  random: access input_pool_data directly rather than through pointer
  random: cleanup fractional entropy shift constants
  random: prepend remaining pool constants with POOL_
  random: de-duplicate INPUT_POOL constants
  random: remove unused OUTPUT_POOL constants
  random: rather than entropy_store abstraction, use global
  random: remove unused extract_entropy() reserved argument
  random: remove incomplete last_data logic
  random: cleanup integer types
  random: cleanup poolinfo abstraction
  random: fix typo in comments
  random: don't reset crng_init_cnt on urandom_read()
  random: avoid superfluous call to RDRAND in CRNG extraction
  random: early initialization of ChaCha constants
  random: initialize ChaCha20 constants with correct endianness
  random: use IS_ENABLED(CONFIG_NUMA) instead of ifdefs
  random: harmonize "crng init done" messages
  random: mix bootloader randomness into pool
  random: do not re-init if crng_reseed completes before primary init
  random: do not sign extend bytes for rotation when mixing
  random: use BLAKE2s instead of SHA1 in extraction
  random: remove unused irq_flags argument from add_interrupt_randomness()
  random: document add_hwgenerator_randomness() with other input functions
  crypto: blake2s - adjust include guard naming
  crypto: blake2s - include <linux/bug.h> instead of <asm/bug.h>
  MAINTAINERS: co-maintain random.c
  random: remove dead code left over from blocking pool
  random: avoid arch_get_random_seed_long() when collecting IRQ randomness
  random: add arch_get_random_*long_early()
  powerpc: Use bool in archrandom.h
  linux/random.h: Mark CONFIG_ARCH_RANDOM functions __must_check
  linux/random.h: Use false with bool
  linux/random.h: Remove arch_has_random, arch_has_random_seed
  s390: Remove arch_has_random, arch_has_random_seed
  powerpc: Remove arch_has_random, arch_has_random_seed
  x86: Remove arch_has_random, arch_has_random_seed
  random: avoid warnings for !CONFIG_NUMA builds
  random: split primary/secondary crng init paths
  random: remove some dead code of poolinfo
  random: fix typo in add_timer_randomness()
  random: Add and use pr_fmt()
  random: convert to ENTROPY_BITS for better code readability
  random: remove unnecessary unlikely()
  random: remove kernel.random.read_wakeup_threshold
  random: delete code to pull data into pools
  random: remove the blocking pool
  random: make /dev/random be almost like /dev/urandom
  random: ignore GRND_RANDOM in getentropy(2)
  random: add GRND_INSECURE to return best-effort non-cryptographic bytes
  random: Add a urandom_read_nowait() for random APIs that don't warn
  random: Don't wake crng_init_wait when crng_init == 1
  random: don't forget compat_ioctl on urandom
  compat_ioctl: remove /dev/random commands
  lib/crypto: sha1: re-roll loops to reduce code size
  lib/crypto: blake2s: move hmac construction into wireguard
  crypto: blake2s - generic C library implementation and selftest
  nfc: st21nfca: fix incorrect sizing calculations in EVT_TRANSACTION
  bpf: Fix incorrect memory charge cost calculation in stack_map_alloc()
  9p: missing chunk of "fs/9p: Don't update file type when updating file attributes"
  Revert "ext4: fix use-after-free in ext4_rename_dir_prepare"
  Revert "ext4: verify dir block before splitting it"
  Linux 5.4.199
  x86/speculation/mmio: Print SMT warning
  KVM: x86/speculation: Disable Fill buffer clear within guests
  x86/speculation/mmio: Reuse SRBDS mitigation for SBDS
  x86/speculation/srbds: Update SRBDS mitigation selection
  x86/speculation/mmio: Add sysfs reporting for Processor MMIO Stale Data
  x86/speculation/mmio: Enable CPU Fill buffer clearing on idle
  x86/bugs: Group MDS, TAA & Processor MMIO Stale Data mitigations
  x86/speculation/mmio: Add mitigation for Processor MMIO Stale Data
  x86/speculation: Add a common function for MD_CLEAR mitigation update
  x86/speculation/mmio: Enumerate Processor MMIO Stale Data bug
  Documentation: Add documentation for Processor MMIO Stale Data
  x86/cpu: Add another Alder Lake CPU to the Intel family
  x86/cpu: Add Lakefield, Alder Lake and Rocket Lake models to the to Intel CPU family
  x86/cpu: Add Jasper Lake to Intel family
  cpu/speculation: Add prototype for cpu_show_srbds()
  Linux 5.4.198
  tcp: fix tcp_mtup_probe_success vs wrong snd_cwnd
  mtd: cfi_cmdset_0002: Use chip_ready() for write on S29GL064N
  md/raid0: Ignore RAID0 layout if the second zone has only one device
  powerpc/32: Fix overread/overwrite of thread_struct via ptrace
  Input: bcm5974 - set missing URB_NO_TRANSFER_DMA_MAP urb flag
  ixgbe: fix unexpected VLAN Rx in promisc mode on VF
  ixgbe: fix bcast packets Rx on VF after promisc removal
  nfc: st21nfca: fix memory leaks in EVT_TRANSACTION handling
  nfc: st21nfca: fix incorrect validating logic in EVT_TRANSACTION
  mmc: block: Fix CQE recovery reset success
  ata: libata-transport: fix {dma|pio|xfer}_mode sysfs files
  cifs: return errors during session setup during reconnects
  ALSA: hda/conexant - Fix loopback issue with CX20632
  scripts/gdb: change kernel config dumping method
  vringh: Fix loop descriptors check in the indirect cases
  nodemask: Fix return values to be unsigned
  cifs: version operations for smb20 unneeded when legacy support disabled
  s390/gmap: voluntarily schedule during key setting
  nbd: fix io hung while disconnecting device
  nbd: fix race between nbd_alloc_config() and module removal
  nbd: call genl_unregister_family() first in nbd_cleanup()
  x86/cpu: Elide KCSAN for cpu_has() and friends
  modpost: fix undefined behavior of is_arm_mapping_symbol()
  drm/radeon: fix a possible null pointer dereference
  ceph: allow ceph.dir.rctime xattr to be updatable
  Revert "net: af_key: add check for pfkey_broadcast in function pfkey_process"
  scsi: myrb: Fix up null pointer access on myrb_cleanup()
  md: protect md_unregister_thread from reentrancy
  watchdog: wdat_wdt: Stop watchdog when rebooting the system
  kernfs: Separate kernfs_pr_cont_buf and rename_lock.
  serial: msm_serial: disable interrupts in __msm_console_write()
  staging: rtl8712: fix uninit-value in r871xu_drv_init()
  staging: rtl8712: fix uninit-value in usb_read8() and friends
  clocksource/drivers/sp804: Avoid error on multiple instances
  extcon: Modify extcon device to be created after driver data is set
  misc: rtsx: set NULL intfdata when probe fails
  usb: dwc2: gadget: don't reset gadget's driver->bus
  USB: hcd-pci: Fully suspend across freeze/thaw cycle
  drivers: usb: host: Fix deadlock in oxu_bus_suspend()
  drivers: tty: serial: Fix deadlock in sa1100_set_termios()
  USB: host: isp116x: check return value after calling platform_get_resource()
  drivers: staging: rtl8192e: Fix deadlock in rtllib_beacons_stop()
  drivers: staging: rtl8192u: Fix deadlock in ieee80211_beacons_stop()
  tty: Fix a possible resource leak in icom_probe
  tty: synclink_gt: Fix null-pointer-dereference in slgt_clean()
  lkdtm/usercopy: Expand size of "out of frame" object
  iio: st_sensors: Add a local lock for protecting odr
  iio: dummy: iio_simple_dummy: check the return value of kstrdup()
  drm: imx: fix compiler warning with gcc-12
  net: altera: Fix refcount leak in altera_tse_mdio_create
  ip_gre: test csum_start instead of transport header
  net/mlx5: fs, fail conflicting actions
  net/mlx5: Rearm the FW tracer after each tracer event
  net: ipv6: unexport __init-annotated seg6_hmac_init()
  net: xfrm: unexport __init-annotated xfrm4_protocol_init()
  net: mdio: unexport __init-annotated mdio_bus_init()
  SUNRPC: Fix the calculation of xdr->end in xdr_get_next_encode_buffer()
  net/mlx4_en: Fix wrong return value on ioctl EEPROM query failure
  net: dsa: lantiq_gswip: Fix refcount leak in gswip_gphy_fw_list
  bpf, arm64: Clear prog->jited_len along prog->jited
  af_unix: Fix a data-race in unix_dgram_peer_wake_me().
  xen: unexport __init-annotated xen_xlate_map_ballooned_pages()
  netfilter: nf_tables: memleak flow rule from commit path
  ata: pata_octeon_cf: Fix refcount leak in octeon_cf_probe
  netfilter: nat: really support inet nat without l3 address
  xprtrdma: treat all calls not a bcall when bc_serv is NULL
  video: fbdev: pxa3xx-gcu: release the resources correctly in pxa3xx_gcu_probe/remove()
  NFSv4: Don't hold the layoutget locks across multiple RPC calls
  dmaengine: zynqmp_dma: In struct zynqmp_dma_chan fix desc_size data type
  m68knommu: fix undefined reference to `_init_sp'
  m68knommu: set ZERO_PAGE() to the allocated zeroed page
  i2c: cadence: Increase timeout per message if necessary
  f2fs: remove WARN_ON in f2fs_is_valid_blkaddr
  tracing: Avoid adding tracer option before update_tracer_options
  tracing: Fix sleeping function called from invalid context on RT kernel
  mips: cpc: Fix refcount leak in mips_cpc_default_phys_base
  perf c2c: Fix sorting in percent_rmt_hitm_cmp()
  tipc: check attribute length for bearer name
  afs: Fix infinite loop found by xfstest generic/676
  tcp: tcp_rtx_synack() can be called from process context
  net: sched: add barrier to fix packet stuck problem for lockless qdisc
  net/mlx5e: Update netdev features after changing XDP state
  net/mlx5: Don't use already freed action pointer
  nfp: only report pause frame configuration for physical device
  ubi: ubi_create_volume: Fix use-after-free when volume creation failed
  jffs2: fix memory leak in jffs2_do_fill_super
  modpost: fix removing numeric suffixes
  net: dsa: mv88e6xxx: Fix refcount leak in mv88e6xxx_mdios_register
  net: ethernet: mtk_eth_soc: out of bounds read in mtk_hwlro_get_fdir_entry()
  net: sched: fixed barrier to prevent skbuff sticking in qdisc backlog
  s390/crypto: fix scatterwalk_unmap() callers in AES-GCM
  clocksource/drivers/oxnas-rps: Fix irq_of_parse_and_map() return value
  ASoC: fsl_sai: Fix FSL_SAI_xDR/xFR definition
  watchdog: ts4800_wdt: Fix refcount leak in ts4800_wdt_probe
  driver core: fix deadlock in __device_attach
  driver: base: fix UAF when driver_attach failed
  bus: ti-sysc: Fix warnings for unbind for serial
  firmware: dmi-sysfs: Fix memory leak in dmi_sysfs_register_handle
  serial: stm32-usart: Correct CSIZE, bits, and parity
  serial: st-asc: Sanitize CSIZE and correct PARENB for CS7
  serial: sifive: Sanitize CSIZE and c_iflag
  serial: sh-sci: Don't allow CS5-6
  serial: txx9: Don't allow CS5-6
  serial: rda-uart: Don't allow CS5-6
  serial: digicolor-usart: Don't allow CS5-6
  serial: 8250_fintek: Check SER_RS485_RTS_* only with RS485
  serial: meson: acquire port->lock in startup()
  rtc: mt6397: check return value after calling platform_get_resource()
  clocksource/drivers/riscv: Events are stopped during CPU suspend
  soc: rockchip: Fix refcount leak in rockchip_grf_init
  coresight: cpu-debug: Replace mutex with mutex_trylock on panic notifier
  serial: sifive: Report actual baud base rather than fixed 115200
  phy: qcom-qmp: fix pipe-clock imbalance on power-on failure
  rpmsg: qcom_smd: Fix returning 0 if irq_of_parse_and_map() fails
  iio: adc: sc27xx: Fine tune the scale calibration values
  iio: adc: sc27xx: fix read big scale voltage not right
  iio: adc: stmpe-adc: Fix wait_for_completion_timeout return value check
  firmware: stratix10-svc: fix a missing check on list iterator
  usb: dwc3: pci: Fix pm_runtime_get_sync() error checking
  rpmsg: qcom_smd: Fix irq_of_parse_and_map() return value
  pwm: lp3943: Fix duty calculation in case period was clamped
  staging: fieldbus: Fix the error handling path in anybuss_host_common_probe()
  usb: musb: Fix missing of_node_put() in omap2430_probe
  USB: storage: karma: fix rio_karma_init return
  usb: usbip: add missing device lock on tweak configuration cmd
  usb: usbip: fix a refcount leak in stub_probe()
  tty: serial: fsl_lpuart: fix potential bug when using both of_alias_get_id and ida_simple_get
  tty: serial: owl: Fix missing clk_disable_unprepare() in owl_uart_probe
  tty: goldfish: Use tty_port_destroy() to destroy port
  iio: adc: ad7124: Remove shift from scan_type
  staging: greybus: codecs: fix type confusion of list iterator variable
  pcmcia: db1xxx_ss: restrict to MIPS_DB1XXX boards
  md: bcache: check the return value of kzalloc() in detached_dev_do_request()
  block: fix bio_clone_blkg_association() to associate with proper blkcg_gq
  bfq: Make sure bfqg for which we are queueing requests is online
  bfq: Get rid of __bio_blkcg() usage
  bfq: Remove pointless bfq_init_rq() calls
  bfq: Drop pointless unlock-lock pair
  bfq: Avoid merging queues with different parents
  MIPS: IP27: Remove incorrect `cpu_has_fpu' override
  RDMA/rxe: Generate a completion for unsupported/invalid opcode
  Kconfig: add config option for asm goto w/ outputs
  phy: qcom-qmp: fix reset-controller leak on probe errors
  blk-iolatency: Fix inflight count imbalances and IO hangs on offline
  dt-bindings: gpio: altera: correct interrupt-cells
  docs/conf.py: Cope with removal of language=None in Sphinx 5.0.0
  ARM: pxa: maybe fix gpio lookup tables
  phy: qcom-qmp: fix struct clk leak on probe errors
  arm64: dts: qcom: ipq8074: fix the sleep clock frequency
  gma500: fix an incorrect NULL check on list iterator
  tilcdc: tilcdc_external: fix an incorrect NULL check on list iterator
  serial: pch: don't overwrite xmit->buf[0] by x_char
  carl9170: tx: fix an incorrect use of list iterator
  ASoC: rt5514: Fix event generation for "DSP Voice Wake Up" control
  rtl818x: Prevent using not initialized queues
  hugetlb: fix huge_pmd_unshare address update
  nodemask.h: fix compilation error with GCC12
  iommu/msm: Fix an incorrect NULL check on list iterator
  um: Fix out-of-bounds read in LDT setup
  um: chan_user: Fix winch_tramp() return value
  mac80211: upgrade passive scan to active scan on DFS channels after beacon rx
  irqchip: irq-xtensa-mx: fix initial IRQ affinity
  irqchip/armada-370-xp: Do not touch Performance Counter Overflow on A375, A38x, A39x
  RDMA/hfi1: Fix potential integer multiplication overflow errors
  Kconfig: Add option for asm goto w/ tied outputs to workaround clang-13 bug
  media: coda: Add more H264 levels for CODA960
  media: coda: Fix reported H264 profile
  mtd: cfi_cmdset_0002: Move and rename chip_check/chip_ready/chip_good_for_write
  md: fix an incorrect NULL check in md_reload_sb
  md: fix an incorrect NULL check in does_sb_need_changing
  drm/bridge: analogix_dp: Grab runtime PM reference for DP-AUX
  drm/nouveau/clk: Fix an incorrect NULL check on list iterator
  drm/etnaviv: check for reaped mapping in etnaviv_iommu_unmap_gem
  drm/amdgpu/cs: make commands with 0 chunks illegal behaviour.
  scsi: ufs: qcom: Add a readl() to make sure ref_clk gets enabled
  scsi: dc395x: Fix a missing check on list iterator
  ocfs2: dlmfs: fix error handling of user_dlm_destroy_lock
  dlm: fix missing lkb refcount handling
  dlm: fix plock invalid read
  mm, compaction: fast_find_migrateblock() should return pfn in the target zone
  PCI: qcom: Fix unbalanced PHY init on probe errors
  PCI: qcom: Fix runtime PM imbalance on probe errors
  PCI/PM: Fix bridge_d3_blacklist[] Elo i2 overwrite of Gigabyte X299
  tracing: Fix potential double free in create_var_ref()
  ACPI: property: Release subnode properties with data nodes
  ext4: avoid cycles in directory h-tree
  ext4: verify dir block before splitting it
  ext4: fix bug_on in ext4_writepages
  ext4: fix warning in ext4_handle_inode_extension
  ext4: fix use-after-free in ext4_rename_dir_prepare
  netfilter: nf_tables: disallow non-stateful expression in sets earlier
  bfq: Track whether bfq_group is still online
  bfq: Update cgroup information before merging bio
  bfq: Split shared queues on move between cgroups
  efi: Do not import certificates from UEFI Secure Boot for T2 Macs
  fs-writeback: writeback_sb_inodes:Recalculate 'wrote' according skipped pages
  iwlwifi: mvm: fix assert 1F04 upon reconfig
  wifi: mac80211: fix use-after-free in chanctx code
  f2fs: fix fallocate to use file_modified to update permissions consistently
  f2fs: don't need inode lock for system hidden quota
  f2fs: fix deadloop in foreground GC
  f2fs: fix to clear dirty inode in f2fs_evict_inode()
  f2fs: fix to do sanity check on block address in f2fs_do_zero_range()
  f2fs: fix to avoid f2fs_bug_on() in dec_valid_node_count()
  perf jevents: Fix event syntax error caused by ExtSel
  perf c2c: Use stdio interface if slang is not supported
  iommu/amd: Increase timeout waiting for GA log enablement
  dmaengine: stm32-mdma: remove GISR1 register
  video: fbdev: clcdfb: Fix refcount leak in clcdfb_of_vram_setup
  NFSv4/pNFS: Do not fail I/O when we fail to allocate the pNFS layout
  NFS: Don't report errors from nfs_pageio_complete() more than once
  NFS: Do not report flush errors in nfs_write_end()
  NFS: Do not report EINTR/ERESTARTSYS as mapping errors
  i2c: at91: Initialize dma_buf in at91_twi_xfer()
  i2c: at91: use dma safe buffers
  iommu/mediatek: Add list_del in mtk_iommu_remove
  f2fs: fix dereference of stale list iterator after loop body
  Input: stmfts - do not leave device disabled in stmfts_input_open
  RDMA/hfi1: Prevent use of lock before it is initialized
  mailbox: forward the hrtimer if not queued and under a lock
  mfd: davinci_voicecodec: Fix possible null-ptr-deref davinci_vc_probe()
  powerpc/fsl_rio: Fix refcount leak in fsl_rio_setup
  macintosh: via-pmu and via-cuda need RTC_LIB
  powerpc/perf: Fix the threshold compare group constraint for power9
  powerpc/64: Only WARN if __pa()/__va() called with bad addresses
  Input: sparcspkr - fix refcount leak in bbc_beep_probe
  crypto: cryptd - Protect per-CPU resource by disabling BH.
  tty: fix deadlock caused by calling printk() under tty_port->lock
  PCI: imx6: Fix PERST# start-up sequence
  ipc/mqueue: use get_tree_nodev() in mqueue_get_tree()
  proc: fix dentry/inode overinstantiating under /proc/${pid}/net
  powerpc/4xx/cpm: Fix return value of __setup() handler
  powerpc/idle: Fix return value of __setup() handler
  powerpc/8xx: export 'cpm_setbrg' for modules
  dax: fix cache flush on PMD-mapped pages
  drivers/base/node.c: fix compaction sysfs file leak
  pinctrl: mvebu: Fix irq_of_parse_and_map() return value
  nvdimm: Allow overwrite in the presence of disabled dimms
  firmware: arm_scmi: Fix list protocols enumeration in the base protocol
  scsi: fcoe: Fix Wstringop-overflow warnings in fcoe_wwn_from_mac()
  mfd: ipaq-micro: Fix error check return value of platform_get_irq()
  powerpc/fadump: fix PT_LOAD segment for boot memory area
  arm: mediatek: select arch timer for mt7629
  crypto: marvell/cesa - ECB does not IV
  misc: ocxl: fix possible double free in ocxl_file_register_afu
  ARM: dts: bcm2835-rpi-b: Fix GPIO line names
  ARM: dts: bcm2837-rpi-3-b-plus: Fix GPIO line name of power LED
  ARM: dts: bcm2837-rpi-cm3-io3: Fix GPIO line names for SMPS I2C
  ARM: dts: bcm2835-rpi-zero-w: Fix GPIO line name for Wifi/BT
  can: xilinx_can: mark bit timing constants as const
  KVM: nVMX: Leave most VM-Exit info fields unmodified on failed VM-Entry
  PCI: rockchip: Fix find_first_zero_bit() limit
  PCI: cadence: Fix find_first_zero_bit() limit
  soc: qcom: smsm: Fix missing of_node_put() in smsm_parse_ipc
  soc: qcom: smp2p: Fix missing of_node_put() in smp2p_parse_ipc
  ARM: dts: suniv: F1C100: fix watchdog compatible
  arm64: dts: rockchip: Move drive-impedance-ohm to emmc phy on rk3399
  net/smc: postpone sk_refcnt increment in connect()
  rxrpc: Fix decision on when to generate an IDLE ACK
  rxrpc: Don't let ack.previousPacket regress
  rxrpc: Fix overlapping ACK accounting
  rxrpc: Don't try to resend the request if we're receiving the reply
  rxrpc: Fix listen() setting the bar too high for the prealloc rings
  NFC: hci: fix sleep in atomic context bugs in nfc_hci_hcp_message_tx
  ASoC: wm2000: fix missing clk_disable_unprepare() on error in wm2000_anc_transition()
  thermal/drivers/broadcom: Fix potential NULL dereference in sr_thermal_probe
  drm: msm: fix possible memory leak in mdp5_crtc_cursor_set()
  drm/msm/a6xx: Fix refcount leak in a6xx_gpu_init
  ext4: reject the 'commit' option on ext2 filesystems
  media: ov7670: remove ov7670_power_off from ov7670_remove
  sctp: read sk->sk_bound_dev_if once in sctp_rcv()
  m68k: math-emu: Fix dependencies of math emulation support
  Bluetooth: fix dangling sco_conn and use-after-free in sco_sock_timeout
  media: vsp1: Fix offset calculation for plane cropping
  media: pvrusb2: fix array-index-out-of-bounds in pvr2_i2c_core_init
  media: exynos4-is: Change clk_disable to clk_disable_unprepare
  media: st-delta: Fix PM disable depth imbalance in delta_probe
  media: aspeed: Fix an error handling path in aspeed_video_probe()
  scripts/faddr2line: Fix overlapping text section failures
  regulator: pfuze100: Fix refcount leak in pfuze_parse_regulators_dt
  ASoC: mxs-saif: Fix refcount leak in mxs_saif_probe
  ASoC: fsl: Fix refcount leak in imx_sgtl5000_probe
  perf/amd/ibs: Use interrupt regs ip for stack unwinding
  Revert "cpufreq: Fix possible race in cpufreq online error path"
  iomap: iomap_write_failed fix
  media: uvcvideo: Fix missing check to determine if element is found in list
  drm/msm: return an error pointer in msm_gem_prime_get_sg_table()
  drm/msm/mdp5: Return error code in mdp5_mixer_release when deadlock is detected
  drm/msm/mdp5: Return error code in mdp5_pipe_release when deadlock is detected
  regulator: core: Fix enable_count imbalance with EXCLUSIVE_GET
  x86/mm: Cleanup the control_va_addr_alignment() __setup handler
  irqchip/aspeed-i2c-ic: Fix irq_of_parse_and_map() return value
  irqchip/exiu: Fix acknowledgment of edge triggered interrupts
  x86: Fix return value of __setup handlers
  virtio_blk: fix the discard_granularity and discard_alignment queue limits
  drm/rockchip: vop: fix possible null-ptr-deref in vop_bind()
  drm/msm/hdmi: fix error check return value of irq_of_parse_and_map()
  drm/msm/hdmi: check return value after calling platform_get_resource_byname()
  drm/msm/dsi: fix error checks and return values for DSI xmit functions
  drm/msm/disp/dpu1: set vbif hw config to NULL to avoid use after memory free during pm runtime resume
  perf tools: Add missing headers needed by util/data.h
  ASoC: rk3328: fix disabling mclk on pclk probe failure
  x86/speculation: Add missing prototype for unpriv_ebpf_notify()
  x86/pm: Fix false positive kmemleak report in msr_build_context()
  scsi: ufs: core: Exclude UECxx from SFR dump list
  of: overlay: do not break notify on NOTIFY_{OK|STOP}
  fsnotify: fix wrong lockdep annotations
  inotify: show inotify mask flags in proc fdinfo
  ath9k_htc: fix potential out of bounds access with invalid rxstatus->rs_keyix
  cpufreq: Fix possible race in cpufreq online error path
  spi: img-spfi: Fix pm_runtime_get_sync() error checking
  sched/fair: Fix cfs_rq_clock_pelt() for throttled cfs_rq
  drm/bridge: Fix error handling in analogix_dp_probe
  HID: elan: Fix potential double free in elan_input_configured
  HID: hid-led: fix maximum brightness for Dream Cheeky
  drbd: fix duplicate array initializer
  efi: Add missing prototype for efi_capsule_setup_info
  NFC: NULL out the dev->rfkill to prevent UAF
  spi: spi-ti-qspi: Fix return value handling of wait_for_completion_timeout
  drm: mali-dp: potential dereference of null pointer
  drm/komeda: Fix an undefined behavior bug in komeda_plane_add()
  nl80211: show SSID for P2P_GO interfaces
  bpf: Fix excessive memory allocation in stack_map_alloc()
  drm/vc4: txp: Force alpha to be 0xff if it's disabled
  drm/vc4: txp: Don't set TXP_VSTART_AT_EOF
  drm/mediatek: Fix mtk_cec_mask()
  x86/delay: Fix the wrong asm constraint in delay_loop()
  ASoC: mediatek: Fix missing of_node_put in mt2701_wm8960_machine_probe
  ASoC: mediatek: Fix error handling in mt8173_max98090_dev_probe
  drm/bridge: adv7511: clean up CEC adapter when probe fails
  drm/edid: fix invalid EDID extension block filtering
  ath9k: fix ar9003_get_eepmisc
  drm: fix EDID struct for old ARM OABI format
  RDMA/hfi1: Prevent panic when SDMA is disabled
  powerpc/iommu: Add missing of_node_put in iommu_init_early_dart
  macintosh/via-pmu: Fix build failure when CONFIG_INPUT is disabled
  powerpc/powernv: fix missing of_node_put in uv_init()
  powerpc/xics: fix refcount leak in icp_opal_init()
  tracing: incorrect isolate_mote_t cast in mm_vmscan_lru_isolate
  PCI: Avoid pci_dev_lock() AB/BA deadlock with sriov_numvfs_store()
  ARM: hisi: Add missing of_node_put after of_find_compatible_node
  ARM: dts: exynos: add atmel,24c128 fallback to Samsung EEPROM
  ARM: versatile: Add missing of_node_put in dcscb_init
  fat: add ratelimit to fat*_ent_bread()
  powerpc/fadump: Fix fadump to work with a different endian capture kernel
  ARM: OMAP1: clock: Fix UART rate reporting algorithm
  fs: jfs: fix possible NULL pointer dereference in dbFree()
  PM / devfreq: rk3399_dmc: Disable edev on remove()
  ARM: dts: ox820: align interrupt controller node name with dtschema
  IB/rdmavt: add missing locks in rvt_ruc_loopback
  selftests/bpf: fix btf_dump/btf_dump due to recent clang change
  eth: tg3: silence the GCC 12 array-bounds warning
  rxrpc: Return an error to sendmsg if call failed
  hwmon: Make chip parameter for with_info API mandatory
  ASoC: max98357a: remove dependency on GPIOLIB
  media: exynos4-is: Fix compile warning
  net: phy: micrel: Allow probing without .driver_data
  nbd: Fix hung on disconnect request if socket is closed before
  ASoC: rt5645: Fix errorenous cleanup order
  nvme-pci: fix a NULL pointer dereference in nvme_alloc_admin_tags
  openrisc: start CPU timer early in boot
  media: cec-adap.c: fix is_configuring state
  media: coda: limit frame interval enumeration to supported encoder frame sizes
  rtlwifi: Use pr_warn instead of WARN_ONCE
  ipmi: Fix pr_fmt to avoid compilation issues
  ipmi:ssif: Check for NULL msg when handling events and messages
  ACPI: PM: Block ASUS B1400CEAE from suspend to idle by default
  dma-debug: change allocation mode from GFP_NOWAIT to GFP_ATIOMIC
  spi: stm32-qspi: Fix wait_cmd timeout in APM mode
  s390/preempt: disable __preempt_count_add() optimization for PROFILE_ALL_BRANCHES
  ASoC: tscs454: Add endianness flag in snd_soc_component_driver
  HID: bigben: fix slab-out-of-bounds Write in bigben_probe
  drm/amdgpu/ucode: Remove firmware load type check in amdgpu_ucode_free_bo
  mlxsw: spectrum_dcb: Do not warn about priority changes
  ASoC: dapm: Don't fold register value changes into notifications
  net/mlx5: fs, delete the FTE when there are no rules attached to it
  ipv6: Don't send rs packets to the interface of ARPHRD_TUNNEL
  drm: msm: fix error check return value of irq_of_parse_and_map()
  arm64: compat: Do not treat syscall number as ESR_ELx for a bad syscall
  drm/amd/pm: fix the compile warning
  drm/plane: Move range check for format_count earlier
  scsi: megaraid: Fix error check return value of register_chrdev()
  mmc: jz4740: Apply DMA engine limits to maximum segment size
  md/bitmap: don't set sb values if can't pass sanity check
  media: cx25821: Fix the warning when removing the module
  media: pci: cx23885: Fix the error handling in cx23885_initdev()
  media: venus: hfi: avoid null dereference in deinit
  ath9k: fix QCA9561 PA bias level
  drm/amd/pm: fix double free in si_parse_power_table()
  tools/power turbostat: fix ICX DRAM power numbers
  spi: spi-rspi: Remove setting {src,dst}_{addr,addr_width} based on DMA direction
  ALSA: jack: Access input_dev under mutex
  drm/komeda: return early if drm_universal_plane_init() fails.
  ACPICA: Avoid cache flush inside virtual machines
  fbcon: Consistently protect deferred_takeover with console_lock()
  ipv6: fix locking issues with loops over idev->addr_list
  ipw2x00: Fix potential NULL dereference in libipw_xmit()
  b43: Fix assigning negative value to unsigned variable
  b43legacy: Fix assigning negative value to unsigned variable
  mwifiex: add mutex lock for call in mwifiex_dfs_chan_sw_work_queue
  drm/virtio: fix NULL pointer dereference in virtio_gpu_conn_get_modes
  btrfs: repair super block num_devices automatically
  btrfs: add "0x" prefix for unsupported optional features
  ptrace: Reimplement PTRACE_KILL by always sending SIGKILL
  ptrace/xtensa: Replace PT_SINGLESTEP with TIF_SINGLESTEP
  ptrace/um: Replace PT_DTRACE with TIF_SINGLESTEP
  perf/x86/intel: Fix event constraints for ICL
  usb: core: hcd: Add support for deferring roothub registration
  USB: new quirk for Dell Gen 2 devices
  USB: serial: option: add Quectel BG95 modem
  ALSA: hda/realtek - Fix microphone noise on ASUS TUF B550M-PLUS
  binfmt_flat: do not stop relocating GOT entries prematurely on riscv

 Conflicts:
	Documentation/devicetree/bindings/dma/allwinner,sun50i-a64-dma.yaml
	Documentation/devicetree/bindings~HEAD
	drivers/char/Kconfig
	drivers/mmc/core/block.c
	kernel/sysctl.c

Change-Id: If11e1865055bfb94b3268960268c88c3dfc032c3
2022-11-09 19:53:28 +02:00
Michael Bestas
4220ba2dae
Merge tag 'LA.UM.9.14.r1-20700-LAHAINA.QSSI13.0' of https://git.codelinaro.org/clo/la/kernel/msm-5.4 into android13-5.4-lahaina
"LA.UM.9.14.r1-20700-LAHAINA.QSSI13.0"

* tag 'LA.UM.9.14.r1-20700-LAHAINA.QSSI13.0' of https://git.codelinaro.org/clo/la/kernel/msm-5.4:
  msm: adsprpc: fix UAF process init_mem
  msm: ipa3: Add multi IDU support for external router mode FR
  cpu-topology: Don't error on more than CONFIG_NR_CPUS CPUs in device tree
  soc: qcom: socinfo: correct the name of softsku_id
  cnss2: Add code to fallback to non-contiguous FW mem allocation
  defconfig: sdxlemur: Enable configs on sdxlemur
  soc: qcom: socinfo: Get SKU ID from kernel command line
  BACKPORT: f2fs: do not set compression bit if kernel doesn't support
  UPSTREAM: f2fs: fix UAF in f2fs_available_free_memory
  ANDROID: f2fs: check nr_pages for readahead
  UPSTREAM: f2fs: guarantee to write dirty data when enabling checkpoint back
  FROMGIT: f2fs: flush data when enabling checkpoint back
  BACKPORT: f2fs: introduce FI_COMPRESS_RELEASED instead of using IMMUTABLE bit
  BACKPORT: f2fs: enforce the immutable flag on open files
  BACKPORT: f2fs: change i_compr_blocks of inode to atomic value
  BACKPORT: f2fs: make file immutable even if releasing zero compression block
  BACKPORT: f2fs: compress: remove unneeded preallocation
  ANDROID: binder: fix pending prio state for early exit
  ANDROID: binder: fix race in priority restore
  ANDROID: binder: switch task argument for binder_thread
  ANDROID: binder: pass desired priority by reference
  ANDROID: binder: fold common setup of node_prio
  BACKPORT: Bluetooth: L2CAP: Fix use-after-free caused by l2cap_chan_put
  FROMLIST: binder: fix UAF of ref->proc caused by race condition

Change-Id: I18e9ed7b3659a920fb9048976d171d3666fe4ed3
2022-11-09 19:36:48 +02:00
Michael Bestas
566743e4e4
Merge tag '5.19.1' of https://github.com/namjaejeon/linux-exfat-oot into android13-5.4-lahaina
exfat: release 5.19.1 version
Major changes are:
 - fix referencing wrong parent directory information during rename.
 - introduce a sys_tz mount option to use system timezone.
 - improve performance while zeroing a cluster with dirsync mount option.
 - fix slab-out-bounds in exat_clear_bitmap() reported from syzbot.
 - Add keep_last_dots mount option to allow access to paths with trailing dots.
 - Avoid repetitive volume dirty bit set/clear to improve storage life time.
 - Fix ->i_blocks truncation issue that still exists elsewhere.
 - 4 cleanups & typos fixes.
 - Move super block magic number to magic.h
 - Fix missing REQ_SYNC in exfat_update_bhs().
 - Fix ->i_blocks truncation issue caused by wrong 32bit mask.

 Conflicts:
	fs/exfat/Kconfig
	fs/exfat/Makefile
	fs/exfat/balloc.c
	fs/exfat/cache.c
	fs/exfat/dir.c
	fs/exfat/exfat_fs.h
	fs/exfat/exfat_raw.h
	fs/exfat/fatent.c
	fs/exfat/file.c
	fs/exfat/inode.c
	fs/exfat/misc.c
	fs/exfat/namei.c
	fs/exfat/nls.c
	fs/exfat/super.c

Change-Id: I5fd39768b9fb0419602fc77153de39291e6a1f1d
2022-10-02 20:39:21 +03:00
Greg Kroah-Hartman
7e6cbbe7e5 Merge tag 'android11-5.4.210_r00' into android11-5.4
This is the merge of the upstream LTS release of 5.4.210 into the
android11-5.4 branch.

It contains the following commits:

ab6cb81d83 Merge 5.4.210 into android11-5.4-lts
de0cd3ea70 Linux 5.4.210
b58882c69f x86/speculation: Add LFENCE to RSB fill sequence
f2f41ef035 x86/speculation: Add RSB VM Exit protections
3a0ef79c6a macintosh/adb: fix oob read in do_adb_query() function
54e1abbe85 media: v4l2-mem2mem: Apply DST_QUEUE_OFF_BASE on MMAP buffers across ioctls
17c2356e46 selftests: KVM: Handle compiler optimizations in ucall
170465715a KVM: Don't null dereference ops->destroy
6098562ed9 selftests/bpf: Fix "dubious pointer arithmetic" test
6a9b3f0f3b selftests/bpf: Fix test_align verifier log patterns
9d6f67365d bpf: Test_verifier, #70 error message updates for 32-bit right shift
751f05bc6f selftests/bpf: Extend verifier and bpf_sock tests for dst_port loads
7c1134c7da bpf: Verifer, adjust_scalar_min_max_vals to always call update_reg_bounds()
a8ba72bbed ACPI: APEI: Better fix to avoid spamming the console with old error logs
fa829bd4af ACPI: video: Shortening quirk list by identifying Clevo by board_name only
8ed6e5c5e2 ACPI: video: Force backlight native for some TongFang devices
828f4c3168 thermal: Fix NULL pointer dereferences in of_thermal_ functions
cc62c7de3d ANDROID: GKI: db845c: Update symbols list and ABI
60bba945eb Merge 5.4.209 into android11-5.4-lts
8d8935e76f Linux 5.4.209
0b0088e475 scsi: core: Fix race between handling STS_RESOURCE and completion
85fe8623f0 mt7601u: add USB device ID for some versions of XiaoDu WiFi Dongle.
d5a596c148 ARM: crypto: comment out gcc warning that breaks clang builds
8d6dab81ee sctp: leave the err path free in sctp_stream_init to sctp_stream_free
a49282eca8 sfc: disable softirqs for ptp TX
7799f742f2 perf symbol: Correct address for bss symbols
388b3f14ff virtio-net: fix the race between refill work and close
52be29e8b6 netfilter: nf_queue: do not allow packet truncation below transport header offset
8e0ed463db sctp: fix sleep in atomic context bug in timer handlers
bc135e464d i40e: Fix interface init with MSI interrupts (no MSI-X)
46462e26e6 tcp: Fix a data-race around sysctl_tcp_comp_sack_nr.
d42f68a9ce tcp: Fix a data-race around sysctl_tcp_comp_sack_delay_ns.
c2b57a4d3f Documentation: fix sctp_wmem in ip-sysctl.rst
2d30375343 tcp: Fix a data-race around sysctl_tcp_invalid_ratelimit.
5d235c2fc2 tcp: Fix a data-race around sysctl_tcp_autocorking.
e02c7ee5a4 tcp: Fix a data-race around sysctl_tcp_min_rtt_wlen.
558a294960 tcp: Fix a data-race around sysctl_tcp_min_tso_segs.
fb200869ea net: sungem_phy: Add of_node_put() for reference returned by of_get_parent()
e20dd1b0e0 igmp: Fix data-races around sysctl_igmp_qrv.
73e5a0b591 ipv6/addrconf: fix a null-ptr-deref bug for ip6_ptr
421e5dd1f1 net: ping6: Fix memleak in ipv6_renew_options().
3d492b008b tcp: Fix a data-race around sysctl_tcp_challenge_ack_limit.
dfdc635d55 tcp: Fix a data-race around sysctl_tcp_limit_output_bytes.
d62e255ecc scsi: ufs: host: Hold reference returned by of_parse_phandle()
b1343528c7 ice: do not setup vlan for loopback VSI
15d0198601 ice: check (DD | EOF) bits on Rx descriptor rather than (EOP | RS)
cd23a2ad7b tcp: Fix a data-race around sysctl_tcp_nometrics_save.
f9a03fd8ed tcp: Fix a data-race around sysctl_tcp_frto.
3be498bcf6 tcp: Fix a data-race around sysctl_tcp_adv_win_scale.
f4b83df011 tcp: Fix a data-race around sysctl_tcp_app_win.
f240d0cad2 tcp: Fix data-races around sysctl_tcp_dsack.
b9f937d3d5 s390/archrandom: prevent CPACF trng invocations in interrupt context
911904c577 ntfs: fix use-after-free in ntfs_ucsncmp()
098e07ef00 Bluetooth: L2CAP: Fix use-after-free caused by l2cap_chan_put
5b72a540b0 ANDROID: restore some removed refcount functions
380aec8a64 ANDROID: add tty_schedule_flip() back to the kernel
b1e3be07f2 Merge 5.4.208 into android11-5.4-lts
77ba2b9b46 Linux 5.4.208
ca5762c589 x86: drop bogus "cc" clobber from __try_cmpxchg_user_asm()
f88d8c1882 net: usb: ax88179_178a needs FLAG_SEND_ZLP
f7785092cb tty: use new tty_insert_flip_string_and_push_buffer() in pty_write()
815d936e92 tty: extract tty_flip_buffer_commit() from tty_flip_buffer_push()
2ea77b0b6d tty: drop tty_schedule_flip()
f20912215c tty: the rest, stop using tty_schedule_flip()
aa60c0cce8 tty: drivers/tty/, stop using tty_schedule_flip()
126137a53d Bluetooth: Fix bt_skb_sendmmsg not allocating partial chunks
836b47e643 Bluetooth: SCO: Fix sco_send_frame returning skb->len
aa2d34cab3 Bluetooth: Fix passing NULL to PTR_ERR
10bacb8917 Bluetooth: RFCOMM: Replace use of memcpy_from_msg with bt_skb_sendmmsg
bf46574d46 Bluetooth: SCO: Replace use of memcpy_from_msg with bt_skb_sendmsg
f00b06003b Bluetooth: Add bt_skb_sendmmsg helper
55bf99849b Bluetooth: Add bt_skb_sendmsg helper
015af30d37 ALSA: memalloc: Align buffer allocations in page size
352affc31e bitfield.h: Fix "type of reg too small for mask" test
0a0fbbd6cb x86/mce: Deduplicate exception handling
b524137fa1 mmap locking API: initial implementation as rwsem wrappers
592a1c6066 x86/uaccess: Implement macros for CMPXCHG on user addresses
1d778b54a5 x86: get rid of small constant size cases in raw_copy_{to,from}_user()
d0d583484d locking/refcount: Consolidate implementations of refcount_t
dab787c73f locking/refcount: Consolidate REFCOUNT_{MAX,SATURATED} definitions
0d3182fbe6 locking/refcount: Move saturation warnings out of line
809554147d locking/refcount: Improve performance of generic REFCOUNT_FULL code
9c9269977f locking/refcount: Move the bulk of the REFCOUNT_FULL implementation into the <linux/refcount.h> header
04bff7d7b8 locking/refcount: Remove unused refcount_*_checked() variants
513b19a43b locking/refcount: Ensure integer operands are treated as signed
68b4ee68e8 locking/refcount: Define constants for saturation and max refcount values
3f71d0e292 ima: remove the IMA_TEMPLATE Kconfig option
bc7581e36d dlm: fix pending remove if msg allocation fails
4f1d21c77b bpf: Make sure mac_header was set before using it
a1f8765f68 mm/mempolicy: fix uninit-value in mpol_rebind_policy()
76668d2a2f spi: bcm2835: bcm2835_spi_handle_err(): fix NULL pointer deref for non DMA transfers
50a1d3d097 tcp: Fix data-races around sysctl_tcp_max_reordering.
c64b99819d tcp: Fix a data-race around sysctl_tcp_rfc1337.
6cc566df68 tcp: Fix a data-race around sysctl_tcp_stdurg.
7f68bed16c tcp: Fix a data-race around sysctl_tcp_retrans_collapse.
369d99c2b8 tcp: Fix data-races around sysctl_tcp_slow_start_after_idle.
492f3713b2 tcp: Fix a data-race around sysctl_tcp_thin_linear_timeouts.
92c35113c6 tcp: Fix data-races around sysctl_tcp_recovery.
83767fe800 tcp: Fix a data-race around sysctl_tcp_early_retrans.
795aee11fd tcp: Fix data-races around sysctl knobs related to SYN option.
f39b03bd72 udp: Fix a data-race around sysctl_udp_l3mdev_accept.
6727f39e99 ipv4: Fix a data-race around sysctl_fib_multipath_use_neigh.
a8569f76df be2net: Fix buffer overflow in be_get_module_eeprom
91d6aa19dd gpio: pca953x: only use single read/write for No AI mode
031af9e617 ixgbe: Add locking to prevent panic when setting sriov_numvfs to zero
55a2a28b32 i40e: Fix erroneous adapter reinitialization during recovery process
d88d59faf4 iavf: Fix handling of dummy receive descriptors
25d53d858a tcp: Fix data-races around sysctl_tcp_fastopen.
78420d8e46 tcp: Fix data-races around sysctl_max_syn_backlog.
dc58e68d1e tcp: Fix a data-race around sysctl_tcp_tw_reuse.
e9362a9938 tcp: Fix a data-race around sysctl_tcp_notsent_lowat.
b0d9f04c87 tcp: Fix data-races around some timeout sysctl knobs.
ea309c467d tcp: Fix data-races around sysctl_tcp_reordering.
b222de2560 tcp: Fix data-races around sysctl_tcp_syncookies.
ff55c025e6 igmp: Fix a data-race around sysctl_igmp_max_memberships.
1656ecaddf igmp: Fix data-races around sysctl_igmp_llm_reports.
2aad2c5745 net/tls: Fix race in TLS device down flow
573768dede net: stmmac: fix dma queue left shift overflow issue
911b81fca2 i2c: cadence: Change large transfer count reset logic to be unconditional
73a1158875 tcp: Fix a data-race around sysctl_tcp_probe_interval.
b04817c94f tcp: Fix a data-race around sysctl_tcp_probe_threshold.
033963b220 tcp: Fix a data-race around sysctl_tcp_mtu_probe_floor.
fdb96b69f5 tcp: Fix data-races around sysctl_tcp_min_snd_mss.
30b73edc1d tcp: Fix data-races around sysctl_tcp_base_mss.
f966773e13 tcp: Fix data-races around sysctl_tcp_mtu_probing.
a7386602a2 tcp/dccp: Fix a data-race around sysctl_tcp_fwmark_accept.
25a635a67c ip: Fix a data-race around sysctl_fwmark_reflect.
281de37199 ip: Fix data-races around sysctl_ip_nonlocal_bind.
7828309df0 ip: Fix data-races around sysctl_ip_fwd_use_pmtu.
5af6d92263 ip: Fix data-races around sysctl_ip_no_pmtu_disc.
16cb6717f4 igc: Reinstate IGC_REMOVED logic and implement it properly
98c3c8fd0d perf/core: Fix data race between perf_event_set_output() and perf_mmap_close()
6194c02149 pinctrl: ralink: Check for null return of devm_kcalloc
78bdf732cf power/reset: arm-versatile: Fix refcount leak in versatile_reboot_probe
f4248bdb7d xfrm: xfrm_policy: fix a possible double xfrm_pols_put() in xfrm_bundle_lookup()
c68f6e2e4f serial: mvebu-uart: correctly report configured baudrate value
2230428fb8 PCI: hv: Fix interrupt mapping for multi-MSI
7121d7120f PCI: hv: Reuse existing IRTE allocation in compose_msi_msg()
584c9d4180 PCI: hv: Fix hv_arch_irq_unmask() for multi-MSI
8e94cc8830 PCI: hv: Fix multi-MSI to allow more than one MSI vector
3048666143 xen/gntdev: Ignore failure to unmap INVALID_GRANT_HANDLE
ed3fea5506 lockdown: Fix kexec lockdown bypass with ima policy
c3856fe718 mlxsw: spectrum_router: Fix IPv4 nexthop gateway indication
c3dc751184 riscv: add as-options for modules with assembly compontents
e5a6b05d0c pinctrl: stm32: fix optional IRQ support to gpios
06f012f2c0 Merge branch 'android11-5.4' into branch 'android11-5.4-lts'
d3891851c5 Revert "cgroup: Use separate src/dst nodes when preloading css_sets for migration"
836d95bfdc Merge 5.4.207 into android11-5.4-lts
002c3bbb47 Linux 5.4.207
08d90846e4 can: m_can: m_can_tx_handler(): fix use after free of skb
579c8a2e63 serial: pl011: UPSTAT_AUTORTS requires .throttle/unthrottle
0c8649a497 serial: stm32: Clear prev values before setting RTS delays
f4c7f5028b serial: 8250: fix return error code in serial8250_request_std_resource()
07379bd79d tty: serial: samsung_tty: set dma burst_size to 1
edcb261221 usb: dwc3: gadget: Fix event pending check
40034fe6b8 usb: typec: add missing uevent when partner support PD
42373b717a USB: serial: ftdi_sio: add Belimo device ids
cbc98dcc38 signal handling: don't use BUG_ON() for debugging
172cd32ada ARM: dts: stm32: use the correct clock source for CEC on stm32mp151
c7d4b3ec63 soc: ixp4xx/npe: Fix unused match warning
a3c7c1a726 x86: Clear .brk area at early boot
549f70b299 irqchip: or1k-pic: Undefine mask_ack for level triggered hardware
b0f41db500 ASoC: madera: Fix event generation for rate controls
79067a6632 ASoC: madera: Fix event generation for OUT1 demux
0e7e515a67 ASoC: cs47l15: Fix event generation for low power mux control
20b921f22a ASoC: wm5110: Fix DRE control
f298d2e4c6 ASoC: ops: Fix off by one in range control validation
ede990cfc4 net: sfp: fix memory leak in sfp_probe()
555cee1bc4 nvme: fix regression when disconnect a recovering ctrl
08082a642a NFC: nxp-nci: don't print header length mismatch on i2c error
4919d82f70 net: tipc: fix possible refcount leak in tipc_sk_create()
70d8aee1de platform/x86: hp-wmi: Ignore Sanitization Mode event
8dda30f81c cpufreq: pmac32-cpufreq: Fix refcount leak bug
b749af1b8f netfilter: br_netfilter: do not skip all hooks with 0 priority
0c9203e75d virtio_mmio: Restore guest page size on resume
569f1ee032 virtio_mmio: Add missing PM calls to freeze/restore
70433d9ea6 mm: sysctl: fix missing numa_stat when !CONFIG_HUGETLB_PAGE
da346adcf5 sfc: fix kernel panic when creating VF
ba60ca0ed1 seg6: bpf: fix skb checksum in bpf_push_seg6_encap()
de7849d9de seg6: fix skb checksum in SRv6 End.B6 and End.B6.Encaps behaviors
487f0f77f1 seg6: fix skb checksum evaluation in SRH encapsulation/insertion
bcad880865 sfc: fix use after free when disabling sriov
b8d77f2396 net: ftgmac100: Hold reference returned by of_get_child_by_name()
9b61d3f6df ipv4: Fix data-races around sysctl_ip_dynaddr.
cc9540ba5b raw: Fix a data-race around sysctl_raw_l3mdev_accept.
df691b9910 icmp: Fix a data-race around sysctl_icmp_ratemask.
8bc1f68714 icmp: Fix a data-race around sysctl_icmp_ratelimit.
3093a6fe31 drm/i915/gt: Serialize TLB invalidates with GT resets
40d58aad2f ARM: dts: sunxi: Fix SPI NOR campatible on Orange Pi Zero
bf676c9408 ARM: dts: at91: sama5d2: Fix typo in i2s1 node
7c1acd98fb ipv4: Fix a data-race around sysctl_fib_sync_mem.
0cba7ca667 icmp: Fix data-races around sysctl.
0e41a0f73c cipso: Fix data-races around sysctl.
861f1852af net: Fix data-races around sysctl_mem.
8d2daf565f inetpeer: Fix data-races around sysctl.
2968830c9b net: stmmac: dwc-qos: Disable split header for Tegra194
1273fd5153 ASoC: sgtl5000: Fix noise on shutdown/remove
388f3df7c3 ima: Fix a potential integer overflow in ima_appraise_measurement
72f231b9a8 drm/i915: fix a possible refcount leak in intel_dp_add_mst_connector()
0f02e7c02b ARM: 9210/1: Mark the FDT_FIXED sections as shareable
41ea241fb3 ARM: 9209/1: Spectre-BHB: avoid pr_info() every time a CPU comes out of idle
851730a198 ARM: dts: imx6qdl-ts7970: Fix ngpio typo and count
18881d7e51 ext4: fix race condition between ext4_write and ext4_convert_inline_data
423f269500 sched/rt: Disable RT_RUNTIME_SHARE by default
31e99fa969 Revert "evm: Fix memleak in init_desc"
d85d19f3b6 nilfs2: fix incorrect masking of permission flags for symlinks
393594aad5 drm/panfrost: Fix shrinker list corruption by madvise IOCTL
ad44e05f3e cgroup: Use separate src/dst nodes when preloading css_sets for migration
444be5a02b wifi: mac80211: fix queue selection for mesh/OCB interfaces
dba5484769 ARM: 9214/1: alignment: advance IT state after emulating Thumb instruction
b4d99aa5ae ARM: 9213/1: Print message about disabled Spectre workarounds only once
2c1cc40fb2 ip: fix dflt addr selection for connected nexthop
fb5a7f1548 net: sock: tracing: Fix sock_exceed_buf_limit not to dereference stale pointer
ecc6dec12c tracing/histograms: Fix memory leak problem
7425479d20 xen/netback: avoid entering xenvif_rx_next_skb() with an empty rx queue
9026b280eb ALSA: hda/realtek - Enable the headset-mic on a Xiaomi's laptop
bbb82d4d9b ALSA: hda/realtek - Fix headset mic problem for a HP machine with alc221
7e2fbf2d9b ALSA: hda/realtek - Fix headset mic problem for a HP machine with alc671
33d33a66e3 ALSA: hda/conexant: Apply quirk for another HP ProDesk 600 G3 model
5e7cc47ab9 ALSA: hda - Add fixup for Dell Latitidue E5430
f0aba2ea80 Merge 5.4.206 into android11-5.4-lts
6584107915 Linux 5.4.206
15a3adfe75 Revert "mtd: rawnand: gpmi: Fix setting busy timeout setting"
a5112e9833 Merge 5.4.205 into android11-5.4-lts
0ec831fa97 Linux 5.4.205
1be11d7f3c dmaengine: ti: Add missing put_device in ti_dra7_xbar_route_allocate
b31ab13256 dmaengine: ti: Fix refcount leak in ti_dra7_xbar_route_allocate
f19026ede2 dmaengine: at_xdma: handle errors of at_xdmac_alloc_desc() correctly
164e88024f dmaengine: pl330: Fix lockdep warning about non-static key
5af3f2a697 ida: don't use BUG_ON() for debugging
d88022b41e dt-bindings: dma: allwinner,sun50i-a64-dma: Fix min/max typo
aaf875578f misc: rtsx_usb: set return value in rsp_buf alloc err path
29612c43a2 misc: rtsx_usb: use separate command and response buffers
0e517d0d7f misc: rtsx_usb: fix use of dma mapped buffer for usb bulk transfer
858c2d0708 dmaengine: imx-sdma: Allow imx8m for imx7 FW revs
6758690689 i2c: cadence: Unregister the clk notifier in error path
acb72388ae selftests: forwarding: fix error message in learning_test
7adf3d45c4 selftests: forwarding: fix learning_test when h1 supports IFF_UNICAST_FLT
681738560b selftests: forwarding: fix flood_unicast_test when h2 supports IFF_UNICAST_FLT
0711d15ccb ibmvnic: Properly dispose of all skbs during a failover.
aa698affa6 ARM: at91: pm: use proper compatibles for sam9x60's rtc and rtt
6b4747d5af ARM: at91: pm: use proper compatible for sama5d2's rtc
1235402750 pinctrl: sunxi: sunxi_pconf_set: use correct offset
12a6905369 pinctrl: sunxi: a83t: Fix NAND function name for some pins
3cf8ece911 ARM: meson: Fix refcount leak in meson_smp_prepare_cpus
c465bbcd3c xfs: remove incorrect ASSERT in xfs_rename
845dac0276 can: kvaser_usb: kvaser_usb_leaf: fix bittiming limits
9afdff9dd8 can: kvaser_usb: kvaser_usb_leaf: fix CAN clock frequency regression
93f228fcbe can: kvaser_usb: replace run-time checks with struct kvaser_usb_driver_info
0adb049bac powerpc/powernv: delay rng platform device creation until later in boot
782b65ee7b video: of_display_timing.h: include errno.h
af93e82197 fbcon: Prevent that screen size is smaller than font size
4f34f380f9 fbcon: Disallow setting font bigger than screen size
997d86cd3e fbmem: Check virtual screen sizes in fb_set_var()
407c1b491f fbdev: fbmem: Fix logo center image dx issue
14ff118431 iommu/vt-d: Fix PCI bus rescan device hot add
800bb66ab2 net: rose: fix UAF bug caused by rose_t0timer_expiry
04894ab34f usbnet: fix memory leak in error case
6f655b5e13 can: gs_usb: gs_usb_open/close(): fix memory leak
eb7bbd7728 can: grcan: grcan_probe(): remove extra of_node_get()
5b48f5711f can: bcm: use call_rcu() instead of costly synchronize_rcu()
e7e3e90d67 mm/slub: add missing TID updates on slab deactivation
3defefd22a esp: limit skb_page_frag_refill use to a single page
63b83aede5 Merge 5.4.204 into android11-5.4-lts
49286fbdad Linux 5.4.204
0ac2845937 clocksource/drivers/ixp4xx: remove EXPORT_SYMBOL_GPL from ixp4xx_timer_setup()
d40057538b net: usb: qmi_wwan: add Telit 0x1070 composition
ea89a522b4 net: usb: qmi_wwan: add Telit 0x1060 composition
5c03cad51b xen/arm: Fix race in RB-tree based P2M accounting
60ac50daad xen/blkfront: force data bouncing when backend is untrusted
ede57be88a xen/netfront: force data bouncing when backend is untrusted
04945b5beb xen/netfront: fix leaking data in shared pages
42112e8f94 xen/blkfront: fix leaking data in shared pages
b7c996abe5 selftests/rseq: Change type of rseq_offset to ptrdiff_t
dc28252880 selftests/rseq: x86-32: use %gs segment selector for accessing rseq thread area
f89d15c986 selftests/rseq: x86-64: use %fs segment selector for accessing rseq thread area
618da2318e selftests/rseq: Fix: work-around asm goto compiler bugs
58082d4e81 selftests/rseq: Remove arm/mips asm goto compiler work-around
1c9f13880f selftests/rseq: Fix warnings about #if checks of undefined tokens
6f87493c3a selftests/rseq: Fix ppc32 offsets by using long rather than off_t
4e9c8fd7f7 selftests/rseq: Fix ppc32 missing instruction selection "u" and "x" for load/store
d0ca70238f selftests/rseq: Fix ppc32: wrong rseq_cs 32-bit field pointer on big endian
20e2f01085 selftests/rseq: Uplift rseq selftests for compatibility with glibc-2.35
71c04fdf59 selftests/rseq: Introduce thread pointer getters
f491e073b9 selftests/rseq: Introduce rseq_get_abi() helper
158d91ffe0 selftests/rseq: Remove volatile from __rseq_abi
7037c511f6 selftests/rseq: Remove useless assignment to cpu variable
9aa134cb66 selftests/rseq: introduce own copy of rseq uapi header
8417f44759 selftests/rseq: remove ARRAY_SIZE define from individual tests
b131190070 rseq/selftests,x86_64: Add rseq_offset_deref_addv()
7b6bffcfb9 ipv6/sit: fix ipip6_tunnel_get_prl return value
05387c4ff5 sit: use min
e99a986161 net: dsa: bcm_sf2: force pause link settings
ac9cd4f66a hwmon: (ibmaem) don't call platform_device_del() if platform_device_add() fails
ee25841221 xen/gntdev: Avoid blocking in unmap_grant_pages()
5eac00ef2a net: tun: avoid disabling NAPI twice
8f968872ec NFC: nxp-nci: Don't issue a zero length i2c_master_read()
37287fd28f nfc: nfcmrvl: Fix irq_of_parse_and_map() return value
893825289b net: bonding: fix use-after-free after 802.3ad slave unbind
6fdef80e7e net: bonding: fix possible NULL deref in rlb code
bb1dc7cc57 net/sched: act_api: Notify user space if any actions were flushed before error
3b2ddeb89f netfilter: nft_dynset: restore set element counter when failing to update
5b3a1c6bca s390: remove unneeded 'select BUILD_BIN2C'
bdecd912e9 PM / devfreq: exynos-ppmu: Fix refcount leak in of_get_devfreq_events
e1284ec4a6 caif_virtio: fix race between virtio_device_ready() and ndo_open()
9204bc3e87 net: ipv6: unexport __init-annotated seg6_hmac_net_init()
7a79f71f69 usbnet: fix memory allocation in helpers
5af106f8e0 linux/dim: Fix divide by 0 in RDMA DIM
85d7d672e8 RDMA/qedr: Fix reporting QP timeout attribute
ea0519bc57 net: tun: stop NAPI when detaching queues
a8cf919022 net: tun: unlink NAPI from device on destruction
22e7546101 selftests/net: pass ipv6_args to udpgso_bench's IPv6 TCP test
1d877327da virtio-net: fix race between ndo_open() and virtio_device_ready()
7f89bb5d71 net: usb: ax88179_178a: Fix packet receiving
bb91556d2a net: rose: fix UAF bugs caused by timer handler
76a477d398 SUNRPC: Fix READ_PLUS crasher
13816057ea s390/archrandom: simplify back to earlier design and initialize earlier
f157bd9cf3 dm raid: fix KASAN warning in raid5_add_disks
90de153575 dm raid: fix accesses beyond end of raid member array
b6125c5dc3 powerpc/bpf: Fix use of user_pt_regs in uapi
1ef2e87736 powerpc/prom_init: Fix kernel config grep
d5e32f08e7 nvdimm: Fix badblocks clear off-by-one error
53fb996f27 ipv6: take care of disable_policy when restoring routes
15a9d795eb Merge 5.4.203 into android11-5.4-lts
871cbc208b Linux 5.4.203
572cc34503 crypto: arm/ghash-ce - define fpu before fpu registers are referenced
3bf992f9d9 crypto: arm - use Kconfig based compiler checks for crypto opcodes
1b43c30cd5 ARM: 9029/1: Make iwmmxt.S support Clang's integrated assembler
9e00e5d195 ARM: OMAP2+: drop unnecessary adrl
3657432a75 ARM: 8929/1: use APSR_nzcv instead of r15 as mrc operand
02c200fdba ARM: 8933/1: replace Sun/Solaris style flag on section directive
54e6ecd5b7 crypto: arm/sha512-neon - avoid ADRL pseudo instruction
5e6f800332 crypto: arm/sha256-neon - avoid ADRL pseudo instruction
e120403c0e ARM: 8971/1: replace the sole use of a symbol with its definition
0a43679016 ARM: 8990/1: use VFP assembler mnemonics in register load/store macros
472671eec9 ARM: 8989/1: use .fpu assembler directives instead of assembler arguments
2bfb0d43a4 net: mscc: ocelot: allow unregistered IP multicast flooding
223d551a66 kexec_file: drop weak attribute from arch_kexec_apply_relocations[_add]
ab3ed204a1 powerpc/ftrace: Remove ftrace init tramp once kernel init is complete
77e2ad0918 drm: remove drm_fb_helper_modinit
476819f502 Merge branch 'android11-5.4' into branch 'android11-5.4-lts'
8e932637c7 Merge 5.4.202 into android11-5.4-lts
9ef3ad40a8 Linux 5.4.202
ceda71d49f powerpc/pseries: wire up rng during setup_arch()
ece9838902 kbuild: link vmlinux only once for CONFIG_TRIM_UNUSED_KSYMS (2nd attempt)
2a81e81314 random: update comment from copy_to_user() -> copy_to_iter()
80f0038d75 modpost: fix section mismatch check for exported init/exit sections
d1359e4129 ARM: cns3xxx: Fix refcount leak in cns3xxx_init
29ca9c4efa ARM: Fix refcount leak in axxia_boot_secondary
734a4d1514 soc: bcm: brcmstb: pm: pm-arm: Fix refcount leak in brcmstb_pm_probe
f9b77a5293 ARM: exynos: Fix refcount leak in exynos_map_pmu
615907ccc4 ARM: dts: imx6qdl: correct PU regulator ramp delay
93e6137d2a powerpc/powernv: wire up rng during setup_arch
97808c7817 powerpc/rtas: Allow ibm,platform-dump RTAS call with null buffer address
b623297932 powerpc: Enable execve syscall exit tracepoint
e0701f150b parisc: Enable ARCH_HAS_STRICT_MODULE_RWX
e5234a9d64 xtensa: Fix refcount leak bug in time.c
a52972ee70 xtensa: xtfpga: Fix refcount leak bug in setup
f0fc7cdf5f iio: adc: axp288: Override TS pin bias current for some models
11c7ea38be iio: adc: stm32: fix maximum clock rate for stm32mp15x
5e39397d60 iio: trigger: sysfs: fix use-after-free on remove
6d2e68d021 iio: gyro: mpu3050: Fix the error handling in mpu3050_power_up()
1ad6d66854 iio: accel: mma8452: ignore the return value of reset operation
a391bced84 iio:accel:mxc4005: rearrange iio trigger get and register
23c158caa0 iio:accel:bma180: rearrange iio trigger get and register
8ea16a64aa iio:chemical:ccs811: rearrange iio trigger get and register
2333db14d8 usb: chipidea: udc: check request status before setting device address
47e41b4dab xhci: turn off port power in shutdown
d62d1c606d iio: adc: vf610: fix conversion mode sysfs node name
741b6c8363 s390/cpumf: Handle events cycles and instructions identical
4837d1c812 gpio: winbond: Fix error code in winbond_gpio_get()
bb18ad00c0 Revert "net/tls: fix tls_sk_proto_close executed repeatedly"
8c7a32b7c1 virtio_net: fix xdp_rxq_info bug after suspend/resume
28a78414f2 igb: Make DMA faster when CPU is active on the PCIe link
a5ed066bc2 regmap-irq: Fix a bug in regmap_irq_enable() for type_in_mask chips
844168a5da ice: ethtool: advertise 1000M speeds properly
e3a232e576 afs: Fix dynamic root getattr
cacab1e620 MIPS: Remove repetitive increase irq_err_count
788c954f19 x86/xen: Remove undefined behavior in setup_features()
c7bdaad9cb udmabuf: add back sanity check
05c6c36c79 net/tls: fix tls_sk_proto_close executed repeatedly
02da602bc2 erspan: do not assume transport header is always set
d1592d3e36 drm/msm/mdp4: Fix refcount leak in mdp4_modeset_init_intf
f1f9c2a5a3 net/sched: sch_netem: Fix arithmetic in netem_dump() for 32-bit platforms
47d31b97bf bonding: ARP monitor spams NETDEV_NOTIFY_PEERS notifiers
104a59b745 phy: aquantia: Fix AN when higher speeds than 1G are not advertised
8ffe2e50e9 bpf: Fix request_sock leak in sk lookup helpers
f074ab2539 USB: serial: option: add Quectel RM500K module support
ea7b23eade USB: serial: option: add Quectel EM05-G modem
613c849d73 USB: serial: option: add Telit LE910Cx 0x1250 composition
ae183969bd random: quiet urandom warning ratelimit suppression message
06a24ddba9 dm mirror log: clear log bits up to BITS_PER_LONG boundary
1f350f3cf0 dm era: commit metadata in postsuspend after worker stops
0e75acbe1b ata: libata: add qc->flags in ata_qc_complete_template tracepoint
71c76f56b9 mtd: rawnand: gpmi: Fix setting busy timeout setting
c8d37e6ca1 mmc: sdhci-pci-o2micro: Fix card detect by dealing with debouncing
af28f602df net: openvswitch: fix parsing of nw_proto for IPv6 fragments
6fda65dabd ALSA: hda/realtek: Add quirk for Clevo PD70PNT
5fbad99e76 ALSA: hda/realtek - ALC897 headset MIC no sound
cf81f367cf ALSA: hda/conexant: Fix missing beep setup
eca9b5e36e ALSA: hda/via: Fix missing beep setup
1df5178fde random: schedule mix_interrupt_randomness() less often
c87e851b23 vt: drop old FONT ioctls
d7a5d91fa5 Merge 5.4.201 into android11-5.4-lts
23db944f75 Linux 5.4.201
3994d2ee55 Revert "hwmon: Make chip parameter for with_info API mandatory"
7b9c3bfbad arm64: mm: Don't invalidate FROM_DEVICE buffers at start of DMA transfer
2e1591c27b tcp: drop the hash_32() part from the index calculation
c26e1addf1 tcp: increase source port perturb table to 2^16
77d29f3b18 tcp: dynamically allocate the perturb table used by source ports
7c0a777b7d tcp: add small random increments to the source port
53c5de3092 tcp: use different parts of the port_offset for index and offset
95921a3bab tcp: add some entropy in __inet_hash_connect()
bdcbf2602f usb: gadget: u_ether: fix regression in setting fixed MAC address
2577d67a9a dm: remove special-casing of bio-based immutable singleton target on NVMe
4143503b48 s390/mm: use non-quiescing sske for KVM switch to keyed guest
1dd92ce7e8 UPSTREAM: ext4: verify dir block before splitting it
1765fa5267 UPSTREAM: ext4: fix use-after-free in ext4_rename_dir_prepare
24ee3133e7 BACKPORT: ext4: Only advertise encrypted_casefold when encryption and unicode are enabled
4adf828284 BACKPORT: ext4: fix no-key deletion for encrypt+casefold
7f4133a55e BACKPORT: ext4: optimize match for casefolded encrypted dirs
ce3b26019c BACKPORT: ext4: handle casefolding with encryption
8515bb68ee Revert "ANDROID: ext4: Handle casefolding with encryption"
91b58da1b3 Revert "ANDROID: ext4: Optimize match for casefolded encrypted dirs"
467eb53acd ANDROID: cpu/hotplug: avoid breaking Android ABI by fusing cpuhp steps
c566c065e8 ANDROID: change function signatures for some random functions.
b2351c2368 Merge 5.4.200 into android11-5.4-lts
4c5060a549 Merge 5.4.199 into android11-5.4-lts
bba1b765b9 Revert "mailbox: forward the hrtimer if not queued and under a lock"
829ffaa71c Revert "drm: fix EDID struct for old ARM OABI format"
864659cb5f Revert "ALSA: jack: Access input_dev under mutex"
f0c280af0e Linux 5.4.200
ab8dff4b71 powerpc/mm: Switch obsolete dssall to .long
1a48a41f14 riscv: Less inefficient gcc tishift helpers (and export their symbols)
2464a1c0de RISC-V: fix barrier() use in <vdso/processor.h>
490a02cd82 arm64: kprobes: Use BRK instead of single-step when executing instructions out-of-line
ef6f9ce0a7 net: openvswitch: fix leak of nested actions
6bb3c77c74 net: openvswitch: fix misuse of the cached connection on tuple changes
b47319b4aa net/sched: act_police: more accurate MTU policing
13fbdea118 virtio-pci: Remove wrong address verification in vp_del_vqs()
80e4d8a274 ALSA: hda/realtek: fix right sounds and mute/micmute LEDs for HP machine
119e0268cc ALSA: hda/realtek: fix mute/micmute LEDs for HP 440 G8
fba5428917 ext4: add reserved GDT blocks check
4ca0d2f1e0 ext4: make variable "count" signed
a6b31616e5 ext4: fix bug_on ext4_mb_use_inode_pa
ae46031287 dm mirror log: round up region bitmap size to BITS_PER_LONG
64d2df6480 serial: 8250: Store to lsr_save_flags after lsr read
b75bddfcc1 usb: gadget: lpc32xx_udc: Fix refcount leak in lpc32xx_udc_probe
6506aff2dc usb: dwc2: Fix memory leak in dwc2_hcd_init
940653b51c USB: serial: io_ti: add Agilent E5805A support
31363b2b86 USB: serial: option: add support for Cinterion MV31 with new baseline
d0c3730f27 comedi: vmk80xx: fix expression for tx buffer size
bf833c4848 i2c: designware: Use standard optional ref clock implementation
8d884c08ee irqchip/gic-v3: Fix refcount leak in gic_populate_ppi_partitions
58e67c81e2 irqchip/gic-v3: Fix error handling in gic_populate_ppi_partitions
56526c3883 irqchip/gic/realview: Fix refcount leak in realview_gic_of_init
4695bafabf faddr2line: Fix overlapping text section failures, the sequel
1b34d6a938 certs/blacklist_hashes.c: fix const confusion in certs blacklist
fb775ee3cf arm64: ftrace: fix branch range checks
0e21311ba4 net: bgmac: Fix an erroneous kfree() in bgmac_remove()
c19cdd72b3 mlxsw: spectrum_cnt: Reorder counter pools
c03304dc42 misc: atmel-ssc: Fix IRQ check in ssc_probe
f7183c76d5 tty: goldfish: Fix free_irq() on remove
ff6e03fe84 i40e: Fix call trace in setup_tx_descriptors
4b94408e16 i40e: Fix calculating the number of queue pairs
43f65970ee i40e: Fix adding ADQ filter to TC0
cff3a7ce6e clocksource: hyper-v: unexport __init-annotated hv_init_clocksource()
11c870c0b5 pNFS: Don't keep retrying if the server replied NFS4ERR_LAYOUTUNAVAILABLE
e32fe87afc random: credit cpu and bootloader seeds by default
9e4cab02b7 net: ethernet: mtk_eth_soc: fix misuse of mem alloc interface netdev[napi]_alloc_frag
2f42389d27 ipv6: Fix signed integer overflow in l2tp_ip6_sendmsg
6b4d8b44e7 nfc: nfcmrvl: Fix memory leak in nfcmrvl_play_deferred
786428a1de virtio-mmio: fix missing put_device() when vm_cmdline_parent registration failed
aacb264d54 ALSA: hda/realtek - Add HW8326 support
ff882404df scsi: pmcraid: Fix missing resource cleanup in error case
c481192236 scsi: ipr: Fix missing/incorrect resource cleanup in error case
fe0855944a scsi: lpfc: Allow reduced polling rate for nvme_admin_async_event cmd completion
1f1be79189 scsi: lpfc: Fix port stuck in bypassed state after LIP in PT2PT topology
001de3d8ce scsi: vmw_pvscsi: Expand vcpuHint to 16 bits
9e3a0d3fc7 ASoC: wm_adsp: Fix event generation for wm_adsp_fw_put()
bc046649c5 ASoC: es8328: Fix event generation for deemphasis control
a81f5a7f7a ASoC: wm8962: Fix suspend while playing music
253334f84c ata: libata-core: fix NULL pointer deref in ata_host_alloc_pinfo()
052cd621ac ASoC: cs42l56: Correct typo in minimum level for SX volume controls
6d180913b3 ASoC: cs42l52: Correct TLV for Bypass Volume
385a031c56 ASoC: cs53l30: Correct number of volume levels on SX controls
675b6a49cf ASoC: cs35l36: Update digital volume TLV
b00f63dba5 ASoC: cs42l52: Fix TLV scales for mixer controls
cd8c1e6c01 dma-debug: make things less spammy under memory pressure
a45e19fd6e ASoC: nau8822: Add operation for internal PLL off and on
348831a9e8 powerpc/kasan: Silence KASAN warnings in __get_wchan()
5624055c8f random: account for arch randomness in bits
c0bf6bfce7 random: mark bootloader randomness code as __init
f96250197b random: avoid checking crng_ready() twice in random_init()
072cd87d12 crypto: drbg - make reseeding from get_random_bytes() synchronous
e9eb0c4741 crypto: drbg - always try to free Jitter RNG instance
f284afc3a9 crypto: drbg - move dynamic ->reseed_threshold adjustments to __drbg_seed()
babba4bf53 crypto: drbg - track whether DRBG was seeded with !rng_is_initialized()
1b93b302e9 crypto: drbg - prepare for more fine-grained tracking of seeding state
98e574a734 crypto: drbg - always seeded with SP800-90B compliant noise source
61f87ea3f9 Revert "random: use static branch for crng_ready()"
3faf33a856 random: check for signals after page of pool writes
2177cef53e random: wire up fops->splice_{read,write}_iter()
35db2a0731 random: convert to using fops->write_iter()
43e62db84a random: convert to using fops->read_iter()
c23188facd random: unify batched entropy implementations
1aeedbe02b random: move randomize_page() into mm where it belongs
ceaf1feefe random: move initialization functions out of hot pages
d3bf98d61f random: make consistent use of buf and len
70fce7f105 random: use proper return types on get_random_{int,long}_wait()
d05948dc23 random: remove extern from functions in header
d8b4296417 random: use static branch for crng_ready()
087a14b9cf random: credit architectural init the exact amount
ac48f7bee1 random: handle latent entropy and command line from random_init()
736a22645d random: use proper jiffies comparison macro
3266fba206 random: remove ratelimiting for in-kernel unseeded randomness
c5373bd6e4 random: move initialization out of reseeding hot path
0747ad152f random: avoid initializing twice in credit race
0baeec0eff random: use symbolic constants for crng_init states
55d64df3ad siphash: use one source of truth for siphash permutations
e4e8a9f8a6 random: help compiler out with fast_mix() by using simpler arguments
bf3b51eb0f random: do not use input pool from hard IRQs
6d4203a2cd random: order timer entropy functions below interrupt functions
58da574f10 random: do not pretend to handle premature next security model
e739d5bd14 random: use first 128 bits of input as fast init
c44f8b3863 random: do not use batches when !crng_ready()
e247ea8d97 random: insist on random_get_entropy() existing in order to simplify
9bfbcb37e5 xtensa: use fallback for random_get_entropy() instead of zero
fa15650b51 sparc: use fallback for random_get_entropy() instead of zero
9dfc14590c um: use fallback for random_get_entropy() instead of zero
0cc41e2c73 x86/tsc: Use fallback for random_get_entropy() instead of zero
f2a6e87270 nios2: use fallback for random_get_entropy() instead of zero
db1d13fe4c arm: use fallback for random_get_entropy() instead of zero
6fa912f987 mips: use fallback for random_get_entropy() instead of just c0 random
36f38f838c m68k: use fallback for random_get_entropy() instead of zero
a7d04ca9da timekeeping: Add raw clock fallback for random_get_entropy()
eb2f9d72f3 powerpc: define get_cycles macro for arch-override
10455a367c alpha: define get_cycles macro for arch-override
5f0b77ca19 parisc: define get_cycles macro for arch-override
80459abc9f s390: define get_cycles macro for arch-override
7338564449 ia64: define get_cycles macro for arch-override
5fac866639 init: call time_init() before rand_initialize()
b88ae87b10 random: fix sysctl documentation nits
4654257483 random: document crng_fast_key_erasure() destination possibility
ec07b34945 random: make random_get_entropy() return an unsigned long
fe156368f9 random: allow partial reads if later user copies fail
70788723da random: check for signals every PAGE_SIZE chunk of /dev/[u]random
2ce859d91f random: check for signal_pending() outside of need_resched() check
0e8030c9e0 random: do not allow user to keep crng key around on stack
95aed891f7 random: do not split fast init input in add_hwgenerator_randomness()
1d53d5a097 random: mix build-time latent entropy into pool at init
0aba75c617 random: re-add removed comment about get_random_{u32,u64} reseeding
81ea8a609b random: treat bootloader trust toggle the same way as cpu trust toggle
a08d52a608 random: skip fast_init if hwrng provides large chunk of entropy
8320bc665c random: check for signal and try earlier when generating entropy
3a53b818bb random: reseed more often immediately after booting
905759e0fc random: make consistent usage of crng_ready()
ad4c6bd98c random: use SipHash as interrupt entropy accumulator
631503001c random: replace custom notifier chain with standard one
1ae73fb2a6 random: don't let 644 read-only sysctls be written to
ed40975710 random: give sysctl_random_min_urandom_seed a more sensible value
75d95c1b5d random: do crng pre-init loading in worker rather than irq
219c84fe93 random: unify cycles_t and jiffies usage and types
673637c4c9 random: cleanup UUID handling
4d5151cc28 random: only wake up writers after zap if threshold was passed
ac0081dec7 random: round-robin registers as ulong, not u32
62cd795e46 random: clear fast pool, crng, and batches in cpuhp bring up
a7f8f385bb random: pull add_hwgenerator_randomness() declaration into random.h
ff607fc760 random: check for crng_init == 0 in add_device_randomness()
20788eb4ce random: unify early init crng load accounting
49567f9477 random: do not take pool spinlock at boot
4a61bf7f9b random: defer fast pool mixing to worker
944d1bd0e5 random: rewrite header introductory comment
c0e35949c7 random: group sysctl functions
d946084180 random: group userspace read/write functions
565a66043b random: group entropy collection functions
f2d587c493 random: group entropy extraction functions
a8786d5476 random: group crng functions
c12dfec1aa random: group initialization wait functions
22e3db57ab random: remove whitespace and reorder includes
cee64be605 random: remove useless header comment
904e6123c4 random: introduce drain_entropy() helper to declutter crng_reseed()
47c56790d5 random: deobfuscate irq u32/u64 contributions
e280b79c31 random: add proper SPDX header
776927dfd4 random: remove unused tracepoints
d68883956d random: remove ifdef'd out interrupt bench
4a14a5a696 random: tie batched entropy generation to base_crng generation
d8a6684950 random: fix locking for crng_init in crng_reseed()
b1d5611381 random: zero buffer after reading entropy from userspace
21da00f8cb random: remove outdated INT_MAX >> 6 check in urandom_read()
b530684129 random: make more consistent use of integer types
3eed6af93e random: use hash function for crng_slow_load()
cee3c70569 random: use simpler fast key erasure flow on per-cpu keys
ea9941fd6e random: absorb fast pool into input pool after fast load
a3562bf4e8 random: do not xor RDRAND when writing into /dev/random
574c883950 random: ensure early RDSEED goes through mixer on init
d3d3c1c214 random: inline leaves of rand_initialize()
817315517a random: get rid of secondary crngs
c15fc80b7d random: use RDSEED instead of RDRAND in entropy extraction
72db8151c8 random: fix locking in crng_fast_load()
7229c6d90a random: remove batched entropy locking
6c89115792 random: remove use_input_pool parameter from crng_reseed()
4ef908fb81 random: make credit_entropy_bits() always safe
42a9a7e807 random: always wake up entropy writers after extraction
373ef51f3e random: use linear min-entropy accumulation crediting
a1a2bae5ef random: simplify entropy debiting
4e5814bd2e random: use computational hash for entropy extraction
99a0f8e22d random: only call crng_finalize_init() for primary_crng
88609b892f random: access primary_pool directly rather than through pointer
0b9f9b94f1 random: continually use hwgenerator randomness
811e333c4e random: simplify arithmetic function flow in account()
56de23dcf9 random: selectively clang-format where it makes sense
86eac12b1c random: access input_pool_data directly rather than through pointer
4f5400ca7f random: cleanup fractional entropy shift constants
1b6f1d32a8 random: prepend remaining pool constants with POOL_
0fe4a64fd9 random: de-duplicate INPUT_POOL constants
e35576c4cb random: remove unused OUTPUT_POOL constants
74cb3093f2 random: rather than entropy_store abstraction, use global
14652d8642 random: remove unused extract_entropy() reserved argument
12f17e3f3a random: remove incomplete last_data logic
adcbbb44cc random: cleanup integer types
4ac4c7f057 random: cleanup poolinfo abstraction
5c3818e3bd random: fix typo in comments
0a7e658102 random: don't reset crng_init_cnt on urandom_read()
8d7c55563e random: avoid superfluous call to RDRAND in CRNG extraction
8b4695640b random: early initialization of ChaCha constants
cfc6906500 random: initialize ChaCha20 constants with correct endianness
922d082e33 random: use IS_ENABLED(CONFIG_NUMA) instead of ifdefs
565b3af168 random: harmonize "crng init done" messages
346c4a697c random: mix bootloader randomness into pool
afce74c0c0 random: do not re-init if crng_reseed completes before primary init
d76758c712 random: do not sign extend bytes for rotation when mixing
c2f0a89cd1 random: use BLAKE2s instead of SHA1 in extraction
6e6ae70c1e random: remove unused irq_flags argument from add_interrupt_randomness()
2580b0b3fd random: document add_hwgenerator_randomness() with other input functions
3cc36a4aa1 crypto: blake2s - adjust include guard naming
09342a544c crypto: blake2s - include <linux/bug.h> instead of <asm/bug.h>
f850f3643d MAINTAINERS: co-maintain random.c
967e3a136f random: remove dead code left over from blocking pool
610f0b439a random: avoid arch_get_random_seed_long() when collecting IRQ randomness
ad3fce6691 random: add arch_get_random_*long_early()
41b0d3e86c powerpc: Use bool in archrandom.h
89533373e1 linux/random.h: Mark CONFIG_ARCH_RANDOM functions __must_check
0222f9f1d1 linux/random.h: Use false with bool
15f93060b7 linux/random.h: Remove arch_has_random, arch_has_random_seed
a95ed04e21 s390: Remove arch_has_random, arch_has_random_seed
aab52172d9 powerpc: Remove arch_has_random, arch_has_random_seed
35e28a05f6 x86: Remove arch_has_random, arch_has_random_seed
98f749e297 random: avoid warnings for !CONFIG_NUMA builds
c13b9c3627 random: split primary/secondary crng init paths
c070b07aaf random: remove some dead code of poolinfo
898498bb44 random: fix typo in add_timer_randomness()
2c53d6d6a7 random: Add and use pr_fmt()
f3375cfe31 random: convert to ENTROPY_BITS for better code readability
9f757cad20 random: remove unnecessary unlikely()
4431c366fe random: remove kernel.random.read_wakeup_threshold
ec134003cc random: delete code to pull data into pools
a9564e14c6 random: remove the blocking pool
940cbc47b3 random: make /dev/random be almost like /dev/urandom
c4edc1055c random: ignore GRND_RANDOM in getentropy(2)
7f9f864af0 random: add GRND_INSECURE to return best-effort non-cryptographic bytes
479d39707f random: Add a urandom_read_nowait() for random APIs that don't warn
69441ba56f random: Don't wake crng_init_wait when crng_init == 1
69ef3109d4 random: don't forget compat_ioctl on urandom
927fc225af compat_ioctl: remove /dev/random commands
996fba14fa lib/crypto: sha1: re-roll loops to reduce code size
c4f4837440 lib/crypto: blake2s: move hmac construction into wireguard
97126d2f65 crypto: blake2s - generic C library implementation and selftest
76101f1b7f nfc: st21nfca: fix incorrect sizing calculations in EVT_TRANSACTION
e804587ecd bpf: Fix incorrect memory charge cost calculation in stack_map_alloc()
f91da317e6 9p: missing chunk of "fs/9p: Don't update file type when updating file attributes"
cf729493b6 Revert "ext4: fix use-after-free in ext4_rename_dir_prepare"
10f5759c4e Revert "ext4: verify dir block before splitting it"
a778a36923 Merge 5.4.198 into android11-5.4-lts
a31bd36611 Linux 5.4.199
4cc40b1022 x86/speculation/mmio: Print SMT warning
d49c22094e KVM: x86/speculation: Disable Fill buffer clear within guests
d961592635 x86/speculation/mmio: Reuse SRBDS mitigation for SBDS
bc64f38b5a x86/speculation/srbds: Update SRBDS mitigation selection
020ce7495c x86/speculation/mmio: Add sysfs reporting for Processor MMIO Stale Data
8d25482fc9 x86/speculation/mmio: Enable CPU Fill buffer clearing on idle
7f898baa20 x86/bugs: Group MDS, TAA & Processor MMIO Stale Data mitigations
0800f1b45b x86/speculation/mmio: Add mitigation for Processor MMIO Stale Data
ae649e0cbf x86/speculation: Add a common function for MD_CLEAR mitigation update
814ccb6730 x86/speculation/mmio: Enumerate Processor MMIO Stale Data bug
91f8147c83 Documentation: Add documentation for Processor MMIO Stale Data
1e9f4e8a7a x86/cpu: Add another Alder Lake CPU to the Intel family
45e744de25 x86/cpu: Add Lakefield, Alder Lake and Rocket Lake models to the to Intel CPU family
79568d5515 x86/cpu: Add Jasper Lake to Intel family
9e2efaa5dd cpu/speculation: Add prototype for cpu_show_srbds()
9d6e67bf50 Linux 5.4.198
602b338e3c tcp: fix tcp_mtup_probe_success vs wrong snd_cwnd
b35e08edb2 mtd: cfi_cmdset_0002: Use chip_ready() for write on S29GL064N
0c12d76255 md/raid0: Ignore RAID0 layout if the second zone has only one device
0c4bc0a2f8 powerpc/32: Fix overread/overwrite of thread_struct via ptrace
3c953d47eb Input: bcm5974 - set missing URB_NO_TRANSFER_DMA_MAP urb flag
6ec537c500 ixgbe: fix unexpected VLAN Rx in promisc mode on VF
24030768a7 ixgbe: fix bcast packets Rx on VF after promisc removal
3eca2c42da nfc: st21nfca: fix memory leaks in EVT_TRANSACTION handling
31f9c39b4a nfc: st21nfca: fix incorrect validating logic in EVT_TRANSACTION
4f4ab50046 mmc: block: Fix CQE recovery reset success
0245434e38 ata: libata-transport: fix {dma|pio|xfer}_mode sysfs files
b651f70ed3 cifs: return errors during session setup during reconnects
850965edc8 ALSA: hda/conexant - Fix loopback issue with CX20632
6c04a2ae03 scripts/gdb: change kernel config dumping method
1a36f77dc2 vringh: Fix loop descriptors check in the indirect cases
a3f9b0afd8 nodemask: Fix return values to be unsigned
9b306339a5 cifs: version operations for smb20 unneeded when legacy support disabled
5cb13cdc18 s390/gmap: voluntarily schedule during key setting
69893d6d7f nbd: fix io hung while disconnecting device
8a7da4ced2 nbd: fix race between nbd_alloc_config() and module removal
1be608e1ee nbd: call genl_unregister_family() first in nbd_cleanup()
045045b522 x86/cpu: Elide KCSAN for cpu_has() and friends
460083de66 modpost: fix undefined behavior of is_arm_mapping_symbol()
28fd384c78 drm/radeon: fix a possible null pointer dereference
9223144fdd ceph: allow ceph.dir.rctime xattr to be updatable
7df12bee54 Revert "net: af_key: add check for pfkey_broadcast in function pfkey_process"
0331d261c3 scsi: myrb: Fix up null pointer access on myrb_cleanup()
cf6b931687 md: protect md_unregister_thread from reentrancy
99e4c67a55 watchdog: wdat_wdt: Stop watchdog when rebooting the system
6fd031799e kernfs: Separate kernfs_pr_cont_buf and rename_lock.
19f4b51b83 serial: msm_serial: disable interrupts in __msm_console_write()
52a0d88c32 staging: rtl8712: fix uninit-value in r871xu_drv_init()
58762f1c63 staging: rtl8712: fix uninit-value in usb_read8() and friends
1bcfb95de1 clocksource/drivers/sp804: Avoid error on multiple instances
d472c78cc8 extcon: Modify extcon device to be created after driver data is set
fa0b2dd682 misc: rtsx: set NULL intfdata when probe fails
d232ca0bbc usb: dwc2: gadget: don't reset gadget's driver->bus
3a7170a3de USB: hcd-pci: Fully suspend across freeze/thaw cycle
2dcec0bc14 drivers: usb: host: Fix deadlock in oxu_bus_suspend()
09a5958a24 drivers: tty: serial: Fix deadlock in sa1100_set_termios()
c91a74b1f0 USB: host: isp116x: check return value after calling platform_get_resource()
64b05fa212 drivers: staging: rtl8192e: Fix deadlock in rtllib_beacons_stop()
1fbe033c52 drivers: staging: rtl8192u: Fix deadlock in ieee80211_beacons_stop()
8c014373f1 tty: Fix a possible resource leak in icom_probe
f6e07eb7eb tty: synclink_gt: Fix null-pointer-dereference in slgt_clean()
1b04c934e1 lkdtm/usercopy: Expand size of "out of frame" object
ca2498cce8 iio: st_sensors: Add a local lock for protecting odr
ab75e02366 iio: dummy: iio_simple_dummy: check the return value of kstrdup()
36acb4d9ce drm: imx: fix compiler warning with gcc-12
8174acbef8 net: altera: Fix refcount leak in altera_tse_mdio_create
3d08bc3a5d ip_gre: test csum_start instead of transport header
957d298526 net/mlx5: fs, fail conflicting actions
8a6740fdc5 net/mlx5: Rearm the FW tracer after each tracer event
317260b3eb net: ipv6: unexport __init-annotated seg6_hmac_init()
ef6d2354de net: xfrm: unexport __init-annotated xfrm4_protocol_init()
6a90a44d53 net: mdio: unexport __init-annotated mdio_bus_init()
978dcc55cf SUNRPC: Fix the calculation of xdr->end in xdr_get_next_encode_buffer()
180473e8e4 net/mlx4_en: Fix wrong return value on ioctl EEPROM query failure
7c8df6fad4 net: dsa: lantiq_gswip: Fix refcount leak in gswip_gphy_fw_list
e412b3d178 bpf, arm64: Clear prog->jited_len along prog->jited
556720013c af_unix: Fix a data-race in unix_dgram_peer_wake_me().
b49c884146 xen: unexport __init-annotated xen_xlate_map_ballooned_pages()
5b8d63489c netfilter: nf_tables: memleak flow rule from commit path
d5a1e7f33c ata: pata_octeon_cf: Fix refcount leak in octeon_cf_probe
e0212033ff netfilter: nat: really support inet nat without l3 address
da99331fa6 xprtrdma: treat all calls not a bcall when bc_serv is NULL
48dea4d3a1 video: fbdev: pxa3xx-gcu: release the resources correctly in pxa3xx_gcu_probe/remove()
a2b3be930e NFSv4: Don't hold the layoutget locks across multiple RPC calls
83960276ff dmaengine: zynqmp_dma: In struct zynqmp_dma_chan fix desc_size data type
4917e43bca m68knommu: fix undefined reference to `_init_sp'
f6bdafbb9b m68knommu: set ZERO_PAGE() to the allocated zeroed page
27fdb45723 i2c: cadence: Increase timeout per message if necessary
0a7a1fc7e7 f2fs: remove WARN_ON in f2fs_is_valid_blkaddr
23b2163b88 tracing: Avoid adding tracer option before update_tracer_options
48c6ee7d6c tracing: Fix sleeping function called from invalid context on RT kernel
cc0aed22d3 mips: cpc: Fix refcount leak in mips_cpc_default_phys_base
ff66ae4359 perf c2c: Fix sorting in percent_rmt_hitm_cmp()
8b91d0dfc8 tipc: check attribute length for bearer name
c2eba68d18 afs: Fix infinite loop found by xfstest generic/676
d05c2fdf8e tcp: tcp_rtx_synack() can be called from process context
1bd2f7f38b net: sched: add barrier to fix packet stuck problem for lockless qdisc
77b954ce2d net/mlx5e: Update netdev features after changing XDP state
a4c52440ac net/mlx5: Don't use already freed action pointer
00803d3051 nfp: only report pause frame configuration for physical device
8302620aeb ubi: ubi_create_volume: Fix use-after-free when volume creation failed
d3a4fff1e7 jffs2: fix memory leak in jffs2_do_fill_super
acf92b5257 modpost: fix removing numeric suffixes
a101793994 net: dsa: mv88e6xxx: Fix refcount leak in mv88e6xxx_mdios_register
2bd1faedb7 net: ethernet: mtk_eth_soc: out of bounds read in mtk_hwlro_get_fdir_entry()
be73e3bf68 net: sched: fixed barrier to prevent skbuff sticking in qdisc backlog
51ed32c1cf s390/crypto: fix scatterwalk_unmap() callers in AES-GCM
80f6712f24 clocksource/drivers/oxnas-rps: Fix irq_of_parse_and_map() return value
e5d479d73f ASoC: fsl_sai: Fix FSL_SAI_xDR/xFR definition
5b110d9404 watchdog: ts4800_wdt: Fix refcount leak in ts4800_wdt_probe
593b595332 driver core: fix deadlock in __device_attach
5d709f58c7 driver: base: fix UAF when driver_attach failed
3157118c17 bus: ti-sysc: Fix warnings for unbind for serial
a724634b2a firmware: dmi-sysfs: Fix memory leak in dmi_sysfs_register_handle
c3a16e7c86 serial: stm32-usart: Correct CSIZE, bits, and parity
29d963635e serial: st-asc: Sanitize CSIZE and correct PARENB for CS7
5c01c19f64 serial: sifive: Sanitize CSIZE and c_iflag
841cab744c serial: sh-sci: Don't allow CS5-6
942aa88467 serial: txx9: Don't allow CS5-6
eb8de4bac3 serial: rda-uart: Don't allow CS5-6
0de3d2344e serial: digicolor-usart: Don't allow CS5-6
035bc3b734 serial: 8250_fintek: Check SER_RS485_RTS_* only with RS485
1b3ae6d850 serial: meson: acquire port->lock in startup()
d77f28c1bc rtc: mt6397: check return value after calling platform_get_resource()
d041e88574 clocksource/drivers/riscv: Events are stopped during CPU suspend
69a30b2ed6 soc: rockchip: Fix refcount leak in rockchip_grf_init
0f91755514 coresight: cpu-debug: Replace mutex with mutex_trylock on panic notifier
47e4c42faa serial: sifive: Report actual baud base rather than fixed 115200
f2a16af2ee phy: qcom-qmp: fix pipe-clock imbalance on power-on failure
b6b0f8904b rpmsg: qcom_smd: Fix returning 0 if irq_of_parse_and_map() fails
088f449d9d iio: adc: sc27xx: Fine tune the scale calibration values
e5d48301d1 iio: adc: sc27xx: fix read big scale voltage not right
0f57d13930 iio: adc: stmpe-adc: Fix wait_for_completion_timeout return value check
bec18bb00f firmware: stratix10-svc: fix a missing check on list iterator
8ad7b3d9f8 usb: dwc3: pci: Fix pm_runtime_get_sync() error checking
1026ee392b rpmsg: qcom_smd: Fix irq_of_parse_and_map() return value
89d1b9dfcc pwm: lp3943: Fix duty calculation in case period was clamped
8e9f3f508a staging: fieldbus: Fix the error handling path in anybuss_host_common_probe()
67c2aa77b4 usb: musb: Fix missing of_node_put() in omap2430_probe
b78499772f USB: storage: karma: fix rio_karma_init return
72ab0f6f2b usb: usbip: add missing device lock on tweak configuration cmd
2f0ae93ec3 usb: usbip: fix a refcount leak in stub_probe()
077f58e469 tty: serial: fsl_lpuart: fix potential bug when using both of_alias_get_id and ida_simple_get
7320308b18 tty: serial: owl: Fix missing clk_disable_unprepare() in owl_uart_probe
9ae3d073f7 tty: goldfish: Use tty_port_destroy() to destroy port
d88fdea147 iio: adc: ad7124: Remove shift from scan_type
1aa30dc883 staging: greybus: codecs: fix type confusion of list iterator variable
6c8c536e00 pcmcia: db1xxx_ss: restrict to MIPS_DB1XXX boards
4faa6308e1 md: bcache: check the return value of kzalloc() in detached_dev_do_request()
5f62b21b7c block: fix bio_clone_blkg_association() to associate with proper blkcg_gq
ccddf8cd41 bfq: Make sure bfqg for which we are queueing requests is online
8afc13b958 bfq: Get rid of __bio_blkcg() usage
be1b78f949 bfq: Remove pointless bfq_init_rq() calls
f885f55033 bfq: Drop pointless unlock-lock pair
97be7d13fb bfq: Avoid merging queues with different parents
5407341053 MIPS: IP27: Remove incorrect `cpu_has_fpu' override
427c3c7ebd RDMA/rxe: Generate a completion for unsupported/invalid opcode
4946cfd1c8 Kconfig: add config option for asm goto w/ outputs
7ac21b24af phy: qcom-qmp: fix reset-controller leak on probe errors
d19fa8f252 blk-iolatency: Fix inflight count imbalances and IO hangs on offline
8a068913d1 dt-bindings: gpio: altera: correct interrupt-cells
3b8c37780d docs/conf.py: Cope with removal of language=None in Sphinx 5.0.0
da9634374d ARM: pxa: maybe fix gpio lookup tables
1668ad1036 phy: qcom-qmp: fix struct clk leak on probe errors
2040b60765 arm64: dts: qcom: ipq8074: fix the sleep clock frequency
8dd2e5f9c1 gma500: fix an incorrect NULL check on list iterator
a62591e361 tilcdc: tilcdc_external: fix an incorrect NULL check on list iterator
77ec584d3d serial: pch: don't overwrite xmit->buf[0] by x_char
f6cb1470ba carl9170: tx: fix an incorrect use of list iterator
2ea49d6310 ASoC: rt5514: Fix event generation for "DSP Voice Wake Up" control
b8ce58ab80 rtl818x: Prevent using not initialized queues
6f4a489d84 hugetlb: fix huge_pmd_unshare address update
73bdb2359d nodemask.h: fix compilation error with GCC12
6e071eaf50 iommu/msm: Fix an incorrect NULL check on list iterator
9caad70819 um: Fix out-of-bounds read in LDT setup
6cbe83680f um: chan_user: Fix winch_tramp() return value
3466e42652 mac80211: upgrade passive scan to active scan on DFS channels after beacon rx
cf465ecfe3 irqchip: irq-xtensa-mx: fix initial IRQ affinity
36bab24bb8 irqchip/armada-370-xp: Do not touch Performance Counter Overflow on A375, A38x, A39x
8858284dd7 RDMA/hfi1: Fix potential integer multiplication overflow errors
6462323626 Kconfig: Add option for asm goto w/ tied outputs to workaround clang-13 bug
532aa3f7a5 media: coda: Add more H264 levels for CODA960
adcea1c8ee media: coda: Fix reported H264 profile
f2c2ad538e mtd: cfi_cmdset_0002: Move and rename chip_check/chip_ready/chip_good_for_write
16e993ac7c md: fix an incorrect NULL check in md_reload_sb
d0bdc809f7 md: fix an incorrect NULL check in does_sb_need_changing
3623f833e1 drm/bridge: analogix_dp: Grab runtime PM reference for DP-AUX
8fa6eb03e3 drm/nouveau/clk: Fix an incorrect NULL check on list iterator
19323b3671 drm/etnaviv: check for reaped mapping in etnaviv_iommu_unmap_gem
c12984cdb0 drm/amdgpu/cs: make commands with 0 chunks illegal behaviour.
8e105178c2 scsi: ufs: qcom: Add a readl() to make sure ref_clk gets enabled
494685db00 scsi: dc395x: Fix a missing check on list iterator
82bf8e7271 ocfs2: dlmfs: fix error handling of user_dlm_destroy_lock
17ea634849 dlm: fix missing lkb refcount handling
49cd9eb7b9 dlm: fix plock invalid read
f160e7b4b0 mm, compaction: fast_find_migrateblock() should return pfn in the target zone
665602c837 PCI: qcom: Fix unbalanced PHY init on probe errors
c3919b10c4 PCI: qcom: Fix runtime PM imbalance on probe errors
c99306cf59 PCI/PM: Fix bridge_d3_blacklist[] Elo i2 overwrite of Gigabyte X299
c27f744cee tracing: Fix potential double free in create_var_ref()
742736dc9c ACPI: property: Release subnode properties with data nodes
e157c8f87e ext4: avoid cycles in directory h-tree
17034d45ec ext4: verify dir block before splitting it
73fd5b1928 ext4: fix bug_on in ext4_writepages
0ab308d72a ext4: fix warning in ext4_handle_inode_extension
eaecf7ebfd ext4: fix use-after-free in ext4_rename_dir_prepare
f36736fbd4 netfilter: nf_tables: disallow non-stateful expression in sets earlier
28a8060a0b bfq: Track whether bfq_group is still online
da9f3025d5 bfq: Update cgroup information before merging bio
31326bf551 bfq: Split shared queues on move between cgroups
b1cda6dd2c efi: Do not import certificates from UEFI Secure Boot for T2 Macs
440d345d02 fs-writeback: writeback_sb_inodes:Recalculate 'wrote' according skipped pages
e0dddab01f iwlwifi: mvm: fix assert 1F04 upon reconfig
265bec4779 wifi: mac80211: fix use-after-free in chanctx code
9259227605 f2fs: fix fallocate to use file_modified to update permissions consistently
1f926457c3 f2fs: don't need inode lock for system hidden quota
12ffc0044a f2fs: fix deadloop in foreground GC
54c116615c f2fs: fix to clear dirty inode in f2fs_evict_inode()
7361c9f2bd f2fs: fix to do sanity check on block address in f2fs_do_zero_range()
f8b3c3fcf3 f2fs: fix to avoid f2fs_bug_on() in dec_valid_node_count()
7f51f27345 perf jevents: Fix event syntax error caused by ExtSel
9eb684dc41 perf c2c: Use stdio interface if slang is not supported
e23eb2f43f iommu/amd: Increase timeout waiting for GA log enablement
db7ea8b261 dmaengine: stm32-mdma: remove GISR1 register
8db59df7f5 video: fbdev: clcdfb: Fix refcount leak in clcdfb_of_vram_setup
dcc00106c3 NFSv4/pNFS: Do not fail I/O when we fail to allocate the pNFS layout
3d216510f8 NFS: Don't report errors from nfs_pageio_complete() more than once
55f0fc32b2 NFS: Do not report flush errors in nfs_write_end()
59137943af NFS: Do not report EINTR/ERESTARTSYS as mapping errors
4826af9a07 i2c: at91: Initialize dma_buf in at91_twi_xfer()
d77a0f2842 i2c: at91: use dma safe buffers
e4db5f4b68 iommu/mediatek: Add list_del in mtk_iommu_remove
5e47a7add3 f2fs: fix dereference of stale list iterator after loop body
c8735252f9 Input: stmfts - do not leave device disabled in stmfts_input_open
addb192000 RDMA/hfi1: Prevent use of lock before it is initialized
6d8b9f574b mailbox: forward the hrtimer if not queued and under a lock
49c1e32e7b mfd: davinci_voicecodec: Fix possible null-ptr-deref davinci_vc_probe()
bcb6c4c5eb powerpc/fsl_rio: Fix refcount leak in fsl_rio_setup
2631fe5b53 macintosh: via-pmu and via-cuda need RTC_LIB
bc21634ce4 powerpc/perf: Fix the threshold compare group constraint for power9
cf0b52858f powerpc/64: Only WARN if __pa()/__va() called with bad addresses
bbc2b0ce60 Input: sparcspkr - fix refcount leak in bbc_beep_probe
6d7b2cf5c7 crypto: cryptd - Protect per-CPU resource by disabling BH.
3219ac364a tty: fix deadlock caused by calling printk() under tty_port->lock
ded067f24b PCI: imx6: Fix PERST# start-up sequence
0b35a685d9 ipc/mqueue: use get_tree_nodev() in mqueue_get_tree()
203537caad proc: fix dentry/inode overinstantiating under /proc/${pid}/net
6cdb6582b5 powerpc/4xx/cpm: Fix return value of __setup() handler
337eef19aa powerpc/idle: Fix return value of __setup() handler
1d83f30421 powerpc/8xx: export 'cpm_setbrg' for modules
662b70a45b dax: fix cache flush on PMD-mapped pages
386e69e068 drivers/base/node.c: fix compaction sysfs file leak
d1f908bd01 pinctrl: mvebu: Fix irq_of_parse_and_map() return value
9282496aac nvdimm: Allow overwrite in the presence of disabled dimms
b0e4bafac8 firmware: arm_scmi: Fix list protocols enumeration in the base protocol
ffd3bed66b scsi: fcoe: Fix Wstringop-overflow warnings in fcoe_wwn_from_mac()
829ea47487 mfd: ipaq-micro: Fix error check return value of platform_get_irq()
8c4eeab726 powerpc/fadump: fix PT_LOAD segment for boot memory area
bbf58e9742 arm: mediatek: select arch timer for mt7629
e7a0d0c280 crypto: marvell/cesa - ECB does not IV
de65c32ace misc: ocxl: fix possible double free in ocxl_file_register_afu
7f287d0c70 ARM: dts: bcm2835-rpi-b: Fix GPIO line names
3a37022d48 ARM: dts: bcm2837-rpi-3-b-plus: Fix GPIO line name of power LED
fd1c098b3b ARM: dts: bcm2837-rpi-cm3-io3: Fix GPIO line names for SMPS I2C
e0bf7f0844 ARM: dts: bcm2835-rpi-zero-w: Fix GPIO line name for Wifi/BT
e4594ca90b can: xilinx_can: mark bit timing constants as const
6077a1e637 KVM: nVMX: Leave most VM-Exit info fields unmodified on failed VM-Entry
9cccb3f6ed PCI: rockchip: Fix find_first_zero_bit() limit
f063429ac3 PCI: cadence: Fix find_first_zero_bit() limit
5543752a48 soc: qcom: smsm: Fix missing of_node_put() in smsm_parse_ipc
6695755216 soc: qcom: smp2p: Fix missing of_node_put() in smp2p_parse_ipc
56b8d748ec ARM: dts: suniv: F1C100: fix watchdog compatible
754ef324b7 arm64: dts: rockchip: Move drive-impedance-ohm to emmc phy on rk3399
60546c0b4b net/smc: postpone sk_refcnt increment in connect()
91121ee574 rxrpc: Fix decision on when to generate an IDLE ACK
d7b16ee15f rxrpc: Don't let ack.previousPacket regress
2fd958ae29 rxrpc: Fix overlapping ACK accounting
5aa14dafd2 rxrpc: Don't try to resend the request if we're receiving the reply
91b34bf040 rxrpc: Fix listen() setting the bar too high for the prealloc rings
0bfaff00d1 NFC: hci: fix sleep in atomic context bugs in nfc_hci_hcp_message_tx
9934025c4d ASoC: wm2000: fix missing clk_disable_unprepare() on error in wm2000_anc_transition()
b3461ccaa5 thermal/drivers/broadcom: Fix potential NULL dereference in sr_thermal_probe
449374565f drm: msm: fix possible memory leak in mdp5_crtc_cursor_set()
6832e36f15 drm/msm/a6xx: Fix refcount leak in a6xx_gpu_init
48d331a03b ext4: reject the 'commit' option on ext2 filesystems
3dc0323755 media: ov7670: remove ov7670_power_off from ov7670_remove
dc794fa2b3 sctp: read sk->sk_bound_dev_if once in sctp_rcv()
d43a87d660 m68k: math-emu: Fix dependencies of math emulation support
6f55fac0af Bluetooth: fix dangling sco_conn and use-after-free in sco_sock_timeout
c3c8c7e409 media: vsp1: Fix offset calculation for plane cropping
1310fc3538 media: pvrusb2: fix array-index-out-of-bounds in pvr2_i2c_core_init
83345b5365 media: exynos4-is: Change clk_disable to clk_disable_unprepare
b87d3a043b media: st-delta: Fix PM disable depth imbalance in delta_probe
12480f7578 media: aspeed: Fix an error handling path in aspeed_video_probe()
d2b1dc3a04 scripts/faddr2line: Fix overlapping text section failures
0be5d9da57 regulator: pfuze100: Fix refcount leak in pfuze_parse_regulators_dt
18b907ff0a ASoC: mxs-saif: Fix refcount leak in mxs_saif_probe
96fc3da618 ASoC: fsl: Fix refcount leak in imx_sgtl5000_probe
ddb1a77f94 perf/amd/ibs: Use interrupt regs ip for stack unwinding
f2e2e934d2 Revert "cpufreq: Fix possible race in cpufreq online error path"
1253811c71 iomap: iomap_write_failed fix
6b8291e574 media: uvcvideo: Fix missing check to determine if element is found in list
ab888b1a9a drm/msm: return an error pointer in msm_gem_prime_get_sg_table()
22d8424913 drm/msm/mdp5: Return error code in mdp5_mixer_release when deadlock is detected
b2aa2c4efe drm/msm/mdp5: Return error code in mdp5_pipe_release when deadlock is detected
cd4cfd99ec regulator: core: Fix enable_count imbalance with EXCLUSIVE_GET
db5a21f2dd x86/mm: Cleanup the control_va_addr_alignment() __setup handler
d2476a1fc5 irqchip/aspeed-i2c-ic: Fix irq_of_parse_and_map() return value
b97eb924a2 irqchip/exiu: Fix acknowledgment of edge triggered interrupts
9777de28cf x86: Fix return value of __setup handlers
ee3901d7c7 virtio_blk: fix the discard_granularity and discard_alignment queue limits
a9b4599665 drm/rockchip: vop: fix possible null-ptr-deref in vop_bind()
35d9a84e3b drm/msm/hdmi: fix error check return value of irq_of_parse_and_map()
2b3ed7547b drm/msm/hdmi: check return value after calling platform_get_resource_byname()
11709592b3 drm/msm/dsi: fix error checks and return values for DSI xmit functions
ef10d0c68e drm/msm/disp/dpu1: set vbif hw config to NULL to avoid use after memory free during pm runtime resume
db681127e9 perf tools: Add missing headers needed by util/data.h
31de06ef06 ASoC: rk3328: fix disabling mclk on pclk probe failure
ed8d5cf1dc x86/speculation: Add missing prototype for unpriv_ebpf_notify()
1d0c4bc628 x86/pm: Fix false positive kmemleak report in msr_build_context()
b889619eba scsi: ufs: core: Exclude UECxx from SFR dump list
e120d31d04 of: overlay: do not break notify on NOTIFY_{OK|STOP}
b0be017bc5 fsnotify: fix wrong lockdep annotations
60d159e0d0 inotify: show inotify mask flags in proc fdinfo
2326d398cc ath9k_htc: fix potential out of bounds access with invalid rxstatus->rs_keyix
cd1f386120 cpufreq: Fix possible race in cpufreq online error path
e7f0fd6f25 spi: img-spfi: Fix pm_runtime_get_sync() error checking
735b57a960 sched/fair: Fix cfs_rq_clock_pelt() for throttled cfs_rq
55fddbb1e2 drm/bridge: Fix error handling in analogix_dp_probe
f1d4f19a79 HID: elan: Fix potential double free in elan_input_configured
75a89bc1ba HID: hid-led: fix maximum brightness for Dream Cheeky
3caa2d7943 drbd: fix duplicate array initializer
65065f96d5 efi: Add missing prototype for efi_capsule_setup_info
fbf9c4c714 NFC: NULL out the dev->rfkill to prevent UAF
2c59535b6b spi: spi-ti-qspi: Fix return value handling of wait_for_completion_timeout
fa0d7ba25a drm: mali-dp: potential dereference of null pointer
797f8ee35f drm/komeda: Fix an undefined behavior bug in komeda_plane_add()
1a994f1f18 nl80211: show SSID for P2P_GO interfaces
93c0f9d78d bpf: Fix excessive memory allocation in stack_map_alloc()
c398c2149b drm/vc4: txp: Force alpha to be 0xff if it's disabled
8a60b54e41 drm/vc4: txp: Don't set TXP_VSTART_AT_EOF
a0c890c0ae drm/mediatek: Fix mtk_cec_mask()
ea8b2ecc92 x86/delay: Fix the wrong asm constraint in delay_loop()
c71494f5f2 ASoC: mediatek: Fix missing of_node_put in mt2701_wm8960_machine_probe
23f340ed90 ASoC: mediatek: Fix error handling in mt8173_max98090_dev_probe
e92b927fff drm/bridge: adv7511: clean up CEC adapter when probe fails
224e1eef03 drm/edid: fix invalid EDID extension block filtering
6577348668 ath9k: fix ar9003_get_eepmisc
ebede9aadf drm: fix EDID struct for old ARM OABI format
e60ad83f64 RDMA/hfi1: Prevent panic when SDMA is disabled
cb4f2dc513 powerpc/iommu: Add missing of_node_put in iommu_init_early_dart
6557555a86 macintosh/via-pmu: Fix build failure when CONFIG_INPUT is disabled
793b82d1c4 powerpc/powernv: fix missing of_node_put in uv_init()
537a317e5f powerpc/xics: fix refcount leak in icp_opal_init()
a910e96131 tracing: incorrect isolate_mote_t cast in mm_vmscan_lru_isolate
c9a81f9ed6 PCI: Avoid pci_dev_lock() AB/BA deadlock with sriov_numvfs_store()
e109058165 ARM: hisi: Add missing of_node_put after of_find_compatible_node
2f46a955b6 ARM: dts: exynos: add atmel,24c128 fallback to Samsung EEPROM
fcd1999ba9 ARM: versatile: Add missing of_node_put in dcscb_init
fd48cf8f97 fat: add ratelimit to fat*_ent_bread()
60ce637c19 powerpc/fadump: Fix fadump to work with a different endian capture kernel
41c7096286 ARM: OMAP1: clock: Fix UART rate reporting algorithm
e54fd01178 fs: jfs: fix possible NULL pointer dereference in dbFree()
a0180e324a PM / devfreq: rk3399_dmc: Disable edev on remove()
1995a60be7 ARM: dts: ox820: align interrupt controller node name with dtschema
58e55f4f5a IB/rdmavt: add missing locks in rvt_ruc_loopback
56fd9dcfe1 selftests/bpf: fix btf_dump/btf_dump due to recent clang change
063d945795 eth: tg3: silence the GCC 12 array-bounds warning
88d730463e rxrpc: Return an error to sendmsg if call failed
1ec0bc72f5 hwmon: Make chip parameter for with_info API mandatory
a7a41dd473 ASoC: max98357a: remove dependency on GPIOLIB
3cf43978ff media: exynos4-is: Fix compile warning
1e5fbfc2a6 net: phy: micrel: Allow probing without .driver_data
9d1764b926 nbd: Fix hung on disconnect request if socket is closed before
abe7554da6 ASoC: rt5645: Fix errorenous cleanup order
f767296626 nvme-pci: fix a NULL pointer dereference in nvme_alloc_admin_tags
69edf28d2c openrisc: start CPU timer early in boot
67fb494388 media: cec-adap.c: fix is_configuring state
4172a34ef9 media: coda: limit frame interval enumeration to supported encoder frame sizes
8f2a5721cd rtlwifi: Use pr_warn instead of WARN_ONCE
2d966c94ad ipmi: Fix pr_fmt to avoid compilation issues
2064a1eab2 ipmi:ssif: Check for NULL msg when handling events and messages
17cfc94558 ACPI: PM: Block ASUS B1400CEAE from suspend to idle by default
5a71f14a9b dma-debug: change allocation mode from GFP_NOWAIT to GFP_ATIOMIC
6583d0d6ad spi: stm32-qspi: Fix wait_cmd timeout in APM mode
1651a95517 s390/preempt: disable __preempt_count_add() optimization for PROFILE_ALL_BRANCHES
890b16b470 ASoC: tscs454: Add endianness flag in snd_soc_component_driver
00771de7cc HID: bigben: fix slab-out-of-bounds Write in bigben_probe
0d7074792b drm/amdgpu/ucode: Remove firmware load type check in amdgpu_ucode_free_bo
2317f3bfda mlxsw: spectrum_dcb: Do not warn about priority changes
121f56a9a8 ASoC: dapm: Don't fold register value changes into notifications
430af81135 net/mlx5: fs, delete the FTE when there are no rules attached to it
f857855a8a ipv6: Don't send rs packets to the interface of ARPHRD_TUNNEL
b507f067e9 drm: msm: fix error check return value of irq_of_parse_and_map()
efd183d988 arm64: compat: Do not treat syscall number as ESR_ELx for a bad syscall
a610cfe56c drm/amd/pm: fix the compile warning
1e29d829ad drm/plane: Move range check for format_count earlier
e1599ced6b scsi: megaraid: Fix error check return value of register_chrdev()
7923f95997 mmc: jz4740: Apply DMA engine limits to maximum segment size
0959aa00f9 md/bitmap: don't set sb values if can't pass sanity check
222292930c media: cx25821: Fix the warning when removing the module
fa636e9ee4 media: pci: cx23885: Fix the error handling in cx23885_initdev()
0ac84ab507 media: venus: hfi: avoid null dereference in deinit
de16cdf0b7 ath9k: fix QCA9561 PA bias level
af832028af drm/amd/pm: fix double free in si_parse_power_table()
7bd0ac1e23 tools/power turbostat: fix ICX DRAM power numbers
6266ab1f31 spi: spi-rspi: Remove setting {src,dst}_{addr,addr_width} based on DMA direction
f68bed124c ALSA: jack: Access input_dev under mutex
aea748501d drm/komeda: return early if drm_universal_plane_init() fails.
8ded0af90e ACPICA: Avoid cache flush inside virtual machines
c7b41fd76c fbcon: Consistently protect deferred_takeover with console_lock()
4460066eb2 ipv6: fix locking issues with loops over idev->addr_list
8fb1b9beb0 ipw2x00: Fix potential NULL dereference in libipw_xmit()
303380919d b43: Fix assigning negative value to unsigned variable
60d515fd87 b43legacy: Fix assigning negative value to unsigned variable
92225d3c22 mwifiex: add mutex lock for call in mwifiex_dfs_chan_sw_work_queue
f85cb059fa drm/virtio: fix NULL pointer dereference in virtio_gpu_conn_get_modes
670f5e40d7 btrfs: repair super block num_devices automatically
622ced791e btrfs: add "0x" prefix for unsupported optional features
0ca5112047 ptrace: Reimplement PTRACE_KILL by always sending SIGKILL
f5faa24137 ptrace/xtensa: Replace PT_SINGLESTEP with TIF_SINGLESTEP
e10356eae1 ptrace/um: Replace PT_DTRACE with TIF_SINGLESTEP
00c93ce266 perf/x86/intel: Fix event constraints for ICL
1b767500d1 usb: core: hcd: Add support for deferring roothub registration
1147908763 USB: new quirk for Dell Gen 2 devices
7c5a52dd4d USB: serial: option: add Quectel BG95 modem
6b3ecb2d92 ALSA: hda/realtek - Fix microphone noise on ASUS TUF B550M-PLUS
1c6cfb9e8a binfmt_flat: do not stop relocating GOT entries prematurely on riscv

ABI .xml file was updated to add a new function that is now tracked:

1 Added function:

  [A] 'function void refcount_warn_saturate(refcount_struct*, refcount_saturation_type)'

Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: I93ce4a950729a57206f775a11adeec35b7b30fca
2022-09-27 13:18:23 +02:00
Tadeusz Struk
297aa83408 ANDROID: incfs: Add check for ATTR_KILL_SUID and ATTR_MODE in incfs_setattr
Add an explicite check for ATTR_KILL_SUID and ATTR_MODE in incfs_setattr.
Both of these attributes can not be set at the same time, otherwise
notify_change() function will check it and invoke BUG(), crashing
the system.

Bug: 243394930

Signed-off-by: Tadeusz Struk <tadeusz.struk@linaro.org>
Change-Id: I91080d68efbd62f1441e20a5c02feef3d1b06e4e
2022-09-19 15:14:36 -07:00
Srinivasarao Pathipati
accdce3646 Merge android11-5.4.197+ (26eb689) into msm-5.4
* refs/heads/tmp-26eb689:
  BACKPORT: f2fs: do not set compression bit if kernel doesn't support
  UPSTREAM: f2fs: fix UAF in f2fs_available_free_memory
  ANDROID: f2fs: check nr_pages for readahead
  UPSTREAM: f2fs: guarantee to write dirty data when enabling checkpoint back
  FROMGIT: f2fs: flush data when enabling checkpoint back
  BACKPORT: f2fs: introduce FI_COMPRESS_RELEASED instead of using IMMUTABLE bit
  BACKPORT: f2fs: enforce the immutable flag on open files
  BACKPORT: f2fs: change i_compr_blocks of inode to atomic value
  BACKPORT: f2fs: make file immutable even if releasing zero compression block
  BACKPORT: f2fs: compress: remove unneeded preallocation
  ANDROID: binder: fix pending prio state for early exit
  ANDROID: binder: fix race in priority restore
  ANDROID: binder: switch task argument for binder_thread
  ANDROID: binder: pass desired priority by reference
  ANDROID: binder: fold common setup of node_prio
  BACKPORT: Bluetooth: L2CAP: Fix use-after-free caused by l2cap_chan_put
  FROMLIST: binder: fix UAF of ref->proc caused by race condition

Change-Id: I1294f6ad0b47b98ff274e4be52eb280e712f0246
Signed-off-by: Srinivasarao Pathipati <quic_c_spathi@quicinc.com>
2022-09-02 19:41:25 +05:30
Srinivasarao Pathipati
630e7df8c5 Merge android11-5.4.197+ (3970bc6) into msm-5.4
* refs/heads/tmp-3970bc6:
  UPSTREAM: Revert "net: af_key: add check for pfkey_broadcast in function pfkey_process"
  FROMGIT: arm64: fix oops in concurrently setting insn_emulation sysctls
  ANDROID: abi_gki_aarch64_qcom: Add vmemdup_user to qcom symbol list
  ANDROID: GKI: update Sony KMI symbol list
  UPSTREAM: mm: fix misplaced unlock_page in do_wp_page()
  BACKPORT: mm: do_wp_page() simplification
  UPSTREAM: mm/ksm: Remove reuse_ksm_page()
  BACKPORT: ALSA: pcm: Fix races among concurrent prealloc proc writes
  BACKPORT: ALSA: pcm: Fix races among concurrent prepare and hw_params/hw_free calls
  BACKPORT: ALSA: pcm: Fix races among concurrent read/write and buffer changes
  ANDROID: Fix up abi issue with struct snd_pcm_runtime
  BACKPORT: ALSA: pcm: Fix races among concurrent hw_params and hw_free calls
  BACKPORT: nfc: nfcmrvl: main: reorder destructive operations in nfcmrvl_nci_unregister_dev to avoid bugs
  Linux 5.4.197
  bpf: Enlarge offset check value to INT_MAX in bpf_skb_{load,store}_bytes
  NFSD: Fix possible sleep during nfsd4_release_lockowner()
  NFS: Memory allocation failures are not server fatal errors
  docs: submitting-patches: Fix crossref to 'The canonical patch format'
  tpm: ibmvtpm: Correct the return value in tpm_ibmvtpm_probe()
  tpm: Fix buffer access in tpm2_get_tpm_pt()
  HID: multitouch: Add support for Google Whiskers Touchpad
  raid5: introduce MD_BROKEN
  dm verity: set DM_TARGET_IMMUTABLE feature flag
  dm stats: add cond_resched when looping over entries
  dm crypt: make printing of the key constant-time
  dm integrity: fix error code in dm_integrity_ctr()
  zsmalloc: fix races between asynchronous zspage free and page migration
  crypto: ecrdsa - Fix incorrect use of vli_cmp
  netfilter: conntrack: re-fetch conntrack after insertion
  exec: Force single empty string when argv is empty
  drm/i915: Fix -Wstringop-overflow warning in call to intel_read_wm_latency()
  cfg80211: set custom regdomain after wiphy registration
  assoc_array: Fix BUG_ON during garbage collect
  drivers: i2c: thunderx: Allow driver to work with ACPI defined TWSI controllers
  i2c: ismt: Provide a DMA buffer for Interrupt Cause Logging
  net: ftgmac100: Disable hardware checksum on AST2600
  net: af_key: check encryption module availability consistency
  pinctrl: sunxi: fix f1c100s uart2 function
  ACPI: sysfs: Fix BERT error region memory mapping
  ACPI: sysfs: Make sparse happy about address space in use
  media: vim2m: initialize the media device earlier
  media: vim2m: Register video device after setting up internals
  secure_seq: use the 64 bits of the siphash for port offset calculation
  tcp: change source port randomizarion at connect() time
  Input: goodix - fix spurious key release events
  staging: rtl8723bs: prevent ->Ssid overflow in rtw_wx_set_scan()
  x86/pci/xen: Disable PCI/MSI[-X] masking for XEN_HVM guests
  lockdown: also lock down previous kgdb use
  Linux 5.4.196
  afs: Fix afs_getattr() to refetch file status if callback break occurred
  i2c: mt7621: fix missing clk_disable_unprepare() on error in mtk_i2c_probe()
  x86/xen: Mark cpu_bringup_and_idle() as dead_end_function
  x86/xen: fix booting 32-bit pv guest
  Reinstate some of "swiotlb: rework "fix info leak with DMA_FROM_DEVICE""
  ARM: dts: imx7: Use audio_mclk_post_div instead audio_mclk_root_clk
  firmware_loader: use kernel credentials when reading firmware
  net: stmmac: disable Split Header (SPH) for Intel platforms
  block: return ELEVATOR_DISCARD_MERGE if possible
  Input: ili210x - fix reset timing
  net: atlantic: verify hw_head_ lies within TX buffer ring
  net: stmmac: fix missing pci_disable_device() on error in stmmac_pci_probe()
  ethernet: tulip: fix missing pci_disable_device() on error in tulip_init_one()
  selftests: add ping test with ping_group_range tuned
  mac80211: fix rx reordering with non explicit / psmp ack policy
  scsi: qla2xxx: Fix missed DMA unmap for aborted commands
  perf bench numa: Address compiler error on s390
  gpio: mvebu/pwm: Refuse requests with inverted polarity
  gpio: gpio-vf610: do not touch other bits when set the target bit
  net: bridge: Clear offload_fwd_mark when passing frame up bridge interface.
  igb: skip phy status check where unavailable
  ARM: 9197/1: spectre-bhb: fix loop8 sequence for Thumb2
  ARM: 9196/1: spectre-bhb: enable for Cortex-A15
  net: af_key: add check for pfkey_broadcast in function pfkey_process
  net/mlx5e: Properly block LRO when XDP is enabled
  NFC: nci: fix sleep in atomic context bugs caused by nci_skb_alloc
  net/qla3xxx: Fix a test in ql_reset_work()
  clk: at91: generated: consider range when calculating best rate
  ice: fix possible under reporting of ethtool Tx and Rx statistics
  net: vmxnet3: fix possible NULL pointer dereference in vmxnet3_rq_cleanup()
  net: vmxnet3: fix possible use-after-free bugs in vmxnet3_rq_alloc_rx_buf()
  net/sched: act_pedit: sanitize shift argument before usage
  net: macb: Increment rx bd head after allocating skb and buffer
  ARM: dts: aspeed-g6: fix SPI1/SPI2 quad pin group
  ARM: dts: aspeed-g6: remove FWQSPID group in pinctrl dtsi
  dma-buf: fix use of DMA_BUF_SET_NAME_{A,B} in userspace
  drm/dp/mst: fix a possible memory leak in fetch_monitor_name()
  crypto: qcom-rng - fix infinite loop on requests not multiple of WORD_SZ
  KVM: x86/mmu: Update number of zapped pages even if page list is stable
  PCI/PM: Avoid putting Elo i2 PCIe Ports in D3cold
  Fix double fget() in vhost_net_set_backend()
  perf: Fix sys_perf_event_open() race against self
  ALSA: wavefront: Proper check of get_user() error
  SUNRPC: Ensure we flush any closed sockets before xs_xprt_free()
  SUNRPC: Don't call connect() more than once on a TCP socket
  SUNRPC: Prevent immediate close+reconnect
  SUNRPC: Clean up scheduling of autoclose
  mmc: core: Default to generic_cmd6_time as timeout in __mmc_switch()
  mmc: block: Use generic_cmd6_time when modifying INAND_CMD38_ARG_EXT_CSD
  mmc: core: Specify timeouts for BKOPS and CACHE_FLUSH for eMMC
  nilfs2: fix lockdep warnings during disk space reclamation
  nilfs2: fix lockdep warnings in page operations for btree nodes
  ARM: 9191/1: arm/stacktrace, kasan: Silence KASAN warnings in unwind_frame()
  platform/chrome: cros_ec_debugfs: detach log reader wq from devm
  drbd: remove usage of list iterator variable after loop
  MIPS: lantiq: check the return value of kzalloc()
  rtc: mc146818-lib: Fix the AltCentury for AMD platforms
  nvme-multipath: fix hang when disk goes live over reconnect
  ALSA: hda/realtek: Enable headset mic on Lenovo P360
  crypto: x86/chacha20 - Avoid spurious jumps to other functions
  crypto: stm32 - fix reference leak in stm32_crc_remove
  Input: stmfts - fix reference leak in stmfts_input_open
  Input: add bounds checking to input_set_capability()
  um: Cleanup syscall_handler_t definition/cast, fix warning
  rtc: fix use-after-free on device removal
  x86/xen: Make the secondary CPU idle tasks reliable
  x86/xen: Make the boot CPU idle task reliable
  floppy: use a statically allocated error counter
  ANDROID: fix up abi issue with struct snd_pcm_runtime
  Linux 5.4.195
  tty/serial: digicolor: fix possible null-ptr-deref in digicolor_uart_probe()
  ping: fix address binding wrt vrf
  arm[64]/memremap: don't abuse pfn_valid() to ensure presence of linear map
  net: phy: Fix race condition on link status change
  MIPS: fix build with gcc-12
  drm/vmwgfx: Initialize drm_mode_fb_cmd2
  cgroup/cpuset: Remove cpus_allowed/mems_allowed setup in cpuset_init_smp()
  i40e: i40e_main: fix a missing check on list iterator
  drm/nouveau/tegra: Stop using iommu_present()
  serial: 8250_mtk: Fix register address for XON/XOFF character
  serial: 8250_mtk: Fix UART_EFR register address
  slimbus: qcom: Fix IRQ check in qcom_slim_probe
  USB: serial: option: add Fibocom MA510 modem
  USB: serial: option: add Fibocom L610 modem
  USB: serial: qcserial: add support for Sierra Wireless EM7590
  USB: serial: pl2303: add device id for HP LM930 Display
  usb: typec: tcpci: Don't skip cleanup in .remove() on error
  usb: cdc-wdm: fix reading stuck on device close
  tty: n_gsm: fix mux activation issues in gsm_config()
  tcp: resalt the secret every 10 seconds
  net: emaclite: Don't advertise 1000BASE-T and do auto negotiation
  s390: disable -Warray-bounds
  ASoC: ops: Validate input values in snd_soc_put_volsw_range()
  ASoC: max98090: Generate notifications on changes for custom control
  ASoC: max98090: Reject invalid values in custom control put()
  hwmon: (f71882fg) Fix negative temperature
  gfs2: Fix filesystem block deallocation for short writes
  net: sfc: ef10: fix memory leak in efx_ef10_mtd_probe()
  net/smc: non blocking recvmsg() return -EAGAIN when no data and signal_pending
  net/sched: act_pedit: really ensure the skb is writable
  s390/lcs: fix variable dereferenced before check
  s390/ctcm: fix potential memory leak
  s390/ctcm: fix variable dereferenced before check
  hwmon: (ltq-cputemp) restrict it to SOC_XWAY
  dim: initialize all struct fields
  mac80211_hwsim: call ieee80211_tx_prepare_skb under RCU protection
  netlink: do not reset transport header in netlink_recvmsg()
  drm/nouveau: Fix a potential theorical leak in nouveau_get_backlight_name()
  ipv4: drop dst in multicast routing path
  net: Fix features skip in for_each_netdev_feature()
  mac80211: Reset MBSSID parameters upon connection
  hwmon: (tmp401) Add OF device ID table
  batman-adv: Don't skb_split skbuffs with frag_list
  Linux 5.4.194
  mm: userfaultfd: fix missing cache flush in mcopy_atomic_pte() and __mcopy_atomic()
  mm: hugetlb: fix missing cache flush in copy_huge_page_from_user()
  mm: fix missing cache flush for all tail pages of compound page
  Bluetooth: Fix the creation of hdev->name
  KVM: x86/svm: Account for family 17h event renumberings in amd_pmc_perf_hw_id
  x86: kprobes: Prohibit probing on instruction which has emulate prefix
  x86: xen: insn: Decode Xen and KVM emulate-prefix signature
  x86: xen: kvm: Gather the definition of emulate prefixes
  x86/asm: Allow to pass macros to __ASM_FORM()
  KVM: x86/pmu: Refactoring find_arch_event() to pmc_perf_hw_id()
  arm: remove CONFIG_ARCH_HAS_HOLES_MEMORYMODEL
  can: grcan: only use the NAPI poll budget for RX
  can: grcan: grcan_probe(): fix broken system id check for errata workaround needs
  nfp: bpf: silence bitwise vs. logical OR warning
  drm/i915: Cast remain to unsigned long in eb_relocate_vma
  drm/amd/display/dc/gpio/gpio_service: Pass around correct dce_{version, environment} types
  block: drbd: drbd_nl: Make conversion to 'enum drbd_ret_code' explicit
  MIPS: Use address-of operator on section symbols
  ANDROID: GKI: update the abi .xml file
  Revert "tcp: ensure to use the most recently sent skb when filling the rate sample"
  Linux 5.4.193
  mmc: rtsx: add 74 Clocks in power on flow
  PCI: aardvark: Fix reading MSI interrupt number
  PCI: aardvark: Clear all MSIs at setup
  dm: interlock pending dm_io and dm_wait_for_bios_completion
  dm: fix mempool NULL pointer race when completing IO
  tcp: make sure treq->af_specific is initialized
  ALSA: pcm: Fix potential AB/BA lock with buffer_mutex and mmap_lock
  ALSA: pcm: Fix races among concurrent prealloc proc writes
  ALSA: pcm: Fix races among concurrent prepare and hw_params/hw_free calls
  ALSA: pcm: Fix races among concurrent read/write and buffer changes
  ALSA: pcm: Fix races among concurrent hw_params and hw_free calls
  mm: fix unexpected zeroed page mapping with zram swap
  block-map: add __GFP_ZERO flag for alloc_page in function bio_copy_kern
  net: ipv6: ensure we call ipv6_mc_down() at most once
  KVM: LAPIC: Enable timer posted-interrupt only when mwait/hlt is advertised
  x86/kvm: Preserve BSP MSR_KVM_POLL_CONTROL across suspend/resume
  kvm: x86/cpuid: Only provide CPUID leaf 0xA if host has architectural PMU
  NFSv4: Don't invalidate inode attributes on delegation return
  drm/amdkfd: Use drm_priv to pass VM from KFD to amdgpu
  net: igmp: respect RCU rules in ip_mc_source() and ip_mc_msfilter()
  btrfs: always log symlinks in full mode
  smsc911x: allow using IRQ0
  bnxt_en: Fix possible bnxt_open() failure caused by wrong RFS flag
  selftests: mirror_gre_bridge_1q: Avoid changing PVID while interface is operational
  net: emaclite: Add error handling for of_address_to_resource()
  net: stmmac: dwmac-sun8i: add missing of_node_put() in sun8i_dwmac_register_mdio_mux()
  net: ethernet: mediatek: add missing of_node_put() in mtk_sgmii_init()
  RDMA/siw: Fix a condition race issue in MPA request processing
  ASoC: dmaengine: Restore NULL prepare_slave_config() callback
  hwmon: (adt7470) Fix warning on module removal
  NFC: netlink: fix sleep in atomic bug when firmware download timeout
  nfc: nfcmrvl: main: reorder destructive operations in nfcmrvl_nci_unregister_dev to avoid bugs
  nfc: replace improper check device_is_registered() in netlink related functions
  can: grcan: use ofdev->dev when allocating DMA memory
  can: grcan: grcan_close(): fix deadlock
  s390/dasd: Fix read inconsistency for ESE DASD devices
  s390/dasd: Fix read for ESE with blksize < 4k
  s390/dasd: prevent double format of tracks for ESE devices
  s390/dasd: fix data corruption for ESE devices
  ASoC: meson: Fix event generation for G12A tohdmi mux
  ASoC: wm8958: Fix change notifications for DSP controls
  ASoC: da7219: Fix change notifications for tone generator frequency
  genirq: Synchronize interrupt thread startup
  ACPICA: Always create namespace nodes using acpi_ns_create_node()
  firewire: core: extend card->lock in fw_core_handle_bus_reset
  firewire: remove check of list iterator against head past the loop body
  firewire: fix potential uaf in outbound_phy_packet_callback()
  Revert "SUNRPC: attempt AF_LOCAL connect on setup"
  gpiolib: of: fix bounds check for 'gpio-reserved-ranges'
  ALSA: fireworks: fix wrong return count shorter than expected by 4 bytes
  parisc: Merge model and model name into one line in /proc/cpuinfo
  MIPS: Fix CP0 counter erratum detection for R4k CPUs
  Linux 5.4.192
  mm, hugetlb: allow for "high" userspace addresses
  hugetlbfs: get unmapped area below TASK_UNMAPPED_BASE for hugetlbfs
  tty: n_gsm: fix incorrect UA handling
  tty: n_gsm: fix wrong command frame length field encoding
  tty: n_gsm: fix wrong command retry handling
  tty: n_gsm: fix missing explicit ldisc flush
  tty: n_gsm: fix insufficient txframe size
  netfilter: nft_socket: only do sk lookups when indev is available
  tty: n_gsm: fix malformed counter for out of frame data
  tty: n_gsm: fix wrong signal octet encoding in convergence layer type 2
  x86/cpu: Load microcode during restore_processor_state()
  net: ethernet: stmmac: fix write to sgmii_adapter_base
  drivers: net: hippi: Fix deadlock in rr_close()
  cifs: destage any unwritten data to the server before calling copychunk_write
  x86: __memcpy_flushcache: fix wrong alignment if size > 2^32
  ip6_gre: Avoid updating tunnel->tun_hlen in __gre6_xmit()
  ASoC: wm8731: Disable the regulator when probing fails
  tcp: fix F-RTO may not work correctly when receiving DSACK
  ixgbe: ensure IPsec VF<->PF compatibility
  bnx2x: fix napi API usage sequence
  tls: Skip tls_append_frag on zero copy size
  drm/amd/display: Fix memory leak in dcn21_clock_source_create
  net: dsa: lantiq_gswip: Don't set GSWIP_MII_CFG_RMII_CLK
  net: bcmgenet: hide status block before TX timestamping
  clk: sunxi: sun9i-mmc: check return value after calling platform_get_resource()
  bus: sunxi-rsb: Fix the return value of sunxi_rsb_device_create()
  tcp: fix potential xmit stalls caused by TCP_NOTSENT_LOWAT
  ip_gre: Make o_seqno start from 0 in native mode
  net/smc: sync err code when tcp connection was refused
  net: hns3: add validity check for message data length
  cpufreq: fix memory leak in sun50i_cpufreq_nvmem_probe
  pinctrl: pistachio: fix use of irq_of_parse_and_map()
  arm64: dts: imx8mn-ddr4-evk: Describe the 32.768 kHz PMIC clock
  ARM: dts: imx6ull-colibri: fix vqmmc regulator
  sctp: check asoc strreset_chunk in sctp_generate_reconf_event
  tcp: ensure to use the most recently sent skb when filling the rate sample
  tcp: md5: incorrect tcp_header_len for incoming connections
  bpf, lwt: Fix crash when using bpf_skb_set_tunnel_key() from bpf_xmit lwt hook
  mtd: rawnand: Fix return value check of wait_for_completion_timeout
  ipvs: correctly print the memory size of ip_vs_conn_tab
  ARM: dts: logicpd-som-lv: Fix wrong pinmuxing on OMAP35
  ARM: dts: am3517-evm: Fix misc pinmuxing
  ARM: dts: Fix mmc order for omap3-gta04
  phy: ti: Add missing pm_runtime_disable() in serdes_am654_probe
  phy: mapphone-mdm6600: Fix PM error handling in phy_mdm6600_probe
  ARM: dts: at91: Map MCLK for wm8731 on at91sam9g20ek
  phy: ti: omap-usb2: Fix error handling in omap_usb2_enable_clocks
  ARM: OMAP2+: Fix refcount leak in omap_gic_of_init
  phy: samsung: exynos5250-sata: fix missing device put in probe error paths
  phy: samsung: Fix missing of_node_put() in exynos_sata_phy_probe
  ARM: dts: imx6qdl-apalis: Fix sgtl5000 detection issue
  USB: Fix xhci event ring dequeue pointer ERDP update issue
  mtd: rawnand: fix ecc parameters for mt7622
  arm64: dts: meson: remove CPU opps below 1GHz for SM1 boards
  arm64: dts: meson: remove CPU opps below 1GHz for G12B boards
  video: fbdev: udlfb: properly check endpoint type
  hex2bin: fix access beyond string end
  hex2bin: make the function hex_to_bin constant-time
  arch_topology: Do not set llc_sibling if llc_id is invalid
  serial: 8250: Correct the clock for EndRun PTP/1588 PCIe device
  serial: 8250: Also set sticky MCR bits in console restoration
  serial: imx: fix overrun interrupts in DMA mode
  usb: dwc3: gadget: Return proper request status
  usb: dwc3: core: Fix tx/rx threshold settings
  usb: gadget: configfs: clear deactivation flag in configfs_composite_unbind()
  usb: gadget: uvc: Fix crash when encoding data for usb request
  usb: typec: ucsi: Fix role swapping
  usb: misc: fix improper handling of refcount in uss720_probe()
  iio: magnetometer: ak8975: Fix the error handling in ak8975_power_on()
  iio: dac: ad5446: Fix read_raw not returning set value
  iio: dac: ad5592r: Fix the missing return value.
  xhci: increase usb U3 -> U0 link resume timeout from 100ms to 500ms
  xhci: stop polling roothubs after shutdown
  USB: serial: option: add Telit 0x1057, 0x1058, 0x1075 compositions
  USB: serial: option: add support for Cinterion MV32-WA/MV32-WB
  USB: serial: cp210x: add PIDs for Kamstrup USB Meter Reader
  USB: serial: whiteheat: fix heap overflow in WHITEHEAT_GET_DTR_RTS
  USB: quirks: add STRING quirk for VCOM device
  USB: quirks: add a Realtek card reader
  usb: mtu3: fix USB 3.0 dual-role-switch from device to host
  lightnvm: disable the subsystem
  hamradio: remove needs_free_netdev to avoid UAF
  hamradio: defer 6pack kfree after unregister_netdev
  floppy: disable FDRAWCMD by default

 Conflicts:
	drivers/usb/dwc3/gadget.c
	include/linux/dma-mapping.h
	include/linux/stmmac.h
	mm/memory.c

Change-Id: I3bf49e11ae4aeaf1db353efbdfee950cd12de8cf
Signed-off-by: Srinivasarao Pathipati <quic_c_spathi@quicinc.com>
2022-08-16 16:52:01 +05:30
Jaegeuk Kim
26eb689452 BACKPORT: f2fs: do not set compression bit if kernel doesn't support
If kernel doesn't have CONFIG_F2FS_FS_COMPRESSION, a file having FS_COMPR_FL via
ioctl(FS_IOC_SETFLAGS) is unaccessible due to f2fs_is_compress_backend_ready().
Let's avoid it.

Bug: 240921972
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
(cherry picked from commit d5a44717f6e0f0943808671e36b1909619707016)
Change-Id: Ieb0f8945175ea5ccb0060690e882f054360fb8f0
2022-08-10 13:06:44 -07:00
Dongliang Mu
17bdd623f3 UPSTREAM: f2fs: fix UAF in f2fs_available_free_memory
if2fs_fill_super
-> f2fs_build_segment_manager
   -> create_discard_cmd_control
      -> f2fs_start_discard_thread

It invokes kthread_run to create a thread and run issue_discard_thread.

However, if f2fs_build_node_manager fails, the control flow goes to
free_nm and calls f2fs_destroy_node_manager. This function will free
sbi->nm_info. However, if issue_discard_thread accesses sbi->nm_info
after the deallocation, but before the f2fs_stop_discard_thread, it will
cause UAF(Use-after-free).

-> f2fs_destroy_segment_manager
   -> destroy_discard_cmd_control
      -> f2fs_stop_discard_thread

Fix this by stopping discard thread before f2fs_destroy_node_manager.

Note that, the commit d6d2b491a82e1 introduces the call of
f2fs_available_free_memory into issue_discard_thread.

Cc: stable@vger.kernel.org
Fixes: d6d2b491a82e ("f2fs: allow to change discard policy based on cached discard cmds")
Signed-off-by: Dongliang Mu <mudongliangabcd@gmail.com>
Reviewed-by: Chao Yu <chao@kernel.org>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
(cherry picked from commit 5429c9dbc9025f9a166f64e22e3a69c94fd5b29b)
Signed-off-by: Lee Jones <lee.jones@linaro.org>
Change-Id: If121b453455b11b2aded8ba8a3899faad431dbd3
2022-08-10 13:06:44 -07:00
Jaegeuk Kim
7e4f972231 ANDROID: f2fs: check nr_pages for readahead
Old kernel versions have the issue, since upstream f2fs removed this flow by:
commit d4384de9eb5e ("f2fs: Remove readahead collision detection").

Bug: 206148707
Signed-off-by: Jaegeuk Kim <jaegeuk@google.com>
Fixes: 8c95605c41a1 ("f2fs: avoid readahead race condition")
Change-Id: I3a95f0b436d0a5ee420f41d892401a8d79d4fe79
2022-08-10 13:06:44 -07:00
Jaegeuk Kim
f711e743ec UPSTREAM: f2fs: guarantee to write dirty data when enabling checkpoint back
We must flush all the dirty data when enabling checkpoint back. Let's guarantee
that first by adding a retry logic on sync_inodes_sb(). In addition to that,
this patch adds to flush data in fsync when checkpoint is disabled, which can
mitigate the sync_inodes_sb() failures in advance.

Bug: 194449609
Reviewed-by: Chao Yu <chao@kernel.org>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
(cherry picked from commit dddd3d65293a52c2c3850c19b1e5115712e534d8)
Change-Id: I5bbef7386ddbb44fd925262fb68a8ef0a4960993
(cherry picked from commit 90c60a51f510da64554abe9c6b748ed624543192)
2022-08-10 12:46:21 -07:00
Jaegeuk Kim
d7b2931cce FROMGIT: f2fs: flush data when enabling checkpoint back
During checkpoint=disable period, f2fs bypasses all the synchronous IOs such as
sync and fsync. So, when enabling it back, we must flush all of them in order
to keep the data persistent. Otherwise, suddern power-cut right after enabling
checkpoint will cause data loss.

Bug: 171063590
Fixes: 4354994f09 ("f2fs: checkpoint disabling")
Cc: stable@vger.kernel.org
Reviewed-by: Chao Yu <yuchao0@huawei.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
(cherry picked from commit 8d52dbb373579b48f5758dd0cdd2ac0fb4e5be7f git://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs.git dev)
Signed-off-by: Jaegeuk Kim <jaegeuk@google.com>
Change-Id: Iaca2d6fc1841fffa8677d5d592732c94241fb3fb
2022-08-10 12:46:21 -07:00
Aditya Mathur
abb255af77 virtiofs: fix virtio_fs_fiq_ops api
Fixing api signature for virtio_fs_fiq_ops.

Change-Id: Ib6b5112b710b0293d9af5c29e460c07e9d30b153
Signed-off-by: Aditya Mathur <quic_aditmath@quicinc.com>
2022-08-09 02:51:27 -07:00
Jaegeuk Kim
601b2ed3e6 BACKPORT: f2fs: introduce FI_COMPRESS_RELEASED instead of using IMMUTABLE bit
commit c61404153eb6 upstream.

Once we release compressed blocks, we used to set IMMUTABLE bit. But it turned
out it disallows every fs operations which we don't need for compression.

Let's just prevent writing data only.

Bug: 237904436
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Change-Id: I3f91a67da56fe26e39a776a5bc595aa809dc804b
2022-08-04 09:05:59 +00:00
Chao Yu
d2972f90d6 BACKPORT: f2fs: enforce the immutable flag on open files
commit e0fcd01510ad upstream.

This patch ports commit 02b016ca7f ("ext4: enforce the immutable
flag on open files") to f2fs.

According to the chattr man page, "a file with the 'i' attribute
cannot be modified..."  Historically, this was only enforced when the
file was opened, per the rest of the description, "... and the file
can not be opened in write mode".

There is general agreement that we should standardize all file systems
to prevent modifications even for files that were opened at the time
the immutable flag is set.  Eventually, a change to enforce this at
the VFS layer should be landing in mainline.

Bug: 237904436
Cc: stable@kernel.org
Signed-off-by: Chao Yu <yuchao0@huawei.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Change-Id: I9c74498ed3174309ff14158c8c3ad6dee6e1c8ca
2022-08-04 09:05:59 +00:00
Daeho Jeong
d2e72fa0b9 BACKPORT: f2fs: change i_compr_blocks of inode to atomic value
commit c2759ebaf7e8 upstream.

writepages() can be concurrently invoked for the same file by different
threads such as a thread fsyncing the file and a kworker kernel thread.
So, changing i_compr_blocks without protection is racy and we need to
protect it by changing it with atomic type value. Plus, we don't need
a 64bit value for i_compr_blocks, so just we will use a atomic value,
not atomic64.

Bug: 237904436
Signed-off-by: Daeho Jeong <daehojeong@google.com>
Reviewed-by: Chao Yu <yuchao0@huawei.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Change-Id: I11f837249078d1b7ef50ac9c156c375542c714b3
2022-08-04 09:05:59 +00:00
Daeho Jeong
8629059128 BACKPORT: f2fs: make file immutable even if releasing zero compression block
commit 567c4bf54a85 upstream.

When we use F2FS_IOC_RELEASE_COMPRESS_BLOCKS ioctl, if we can't find
any compressed blocks in the file even with large file size, the
ioctl just ends up without changing the file's status as immutable.
It makes the user, who expects that the file is immutable when it
returns successfully, confused.

Bug: 237904436
Signed-off-by: Daeho Jeong <daehojeong@google.com>
Reviewed-by: Chao Yu <yuchao0@huawei.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Change-Id: I2c96428442e69b69c7064096d2e1ce8e2b99cc09
2022-08-04 09:05:59 +00:00
Chao Yu
3cf0f8245d BACKPORT: f2fs: compress: remove unneeded preallocation
commit 8f1d49832636 upstream.

We will reserve iblocks for compression saved, so during compressed
cluster overwrite, we don't need to preallocate blocks for later
write.

In addition, it adds a bug_on to detect wrong reserved iblock number
in __f2fs_cluster_blocks().

Bug fix in the original patch by Jaegeuk:
If we released compressed blocks having an immutable bit, we can see less
number of compressed block addresses. Let's fix wrong BUG_ON.

Bug: 237904436
Signed-off-by: Chao Yu <yuchao0@huawei.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Change-Id: I673af616581a9e7bf711e60d1588856f24f65dc9
2022-08-04 09:05:59 +00:00
Greg Kroah-Hartman
60bba945eb This is the 5.4.209 stable release
-----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCAAdFiEEZH8oZUiU471FcZm+ONu9yGCSaT4FAmLqRxEACgkQONu9yGCS
 aT6POg/+JsjJHkU2o/U+/3wstemdaTBXH3o6uVrHiARosJ0nY2ZIxx+nvhs5d7G4
 xKEEJDoczhYDVjUINEUFztmKwV4jlMvIkubHwk0Z+h0XeV6PuQZ+ZKvgfAHsO3tx
 LuRwLKXdTybMol5UHn1RKuq3iDFO5rR4A6QLJKtDum2P+B1TIzoIdBUE7vPEOtj0
 CvFcjhL80X/l7ARQU5J1oJNWIBLXUY8fpCbR5SiqalJrZm0PMs1jAXWfo0L9Io+U
 mHNnLlH3+Vh6WeaayS2QkhvlTHaJe0CvvdgJfwWc9ypS9vkadbCeaJusBUmn5FpT
 mw73UG8+P6wzTTeIFb/Rrwhz649ZnXXRdExovVn1xpsh/RiztSjMybrqglZrv0QN
 wVnWuMHvwSajmTEsTaSM1sOqbNejYyjw+UgjBOrFW63ZAYonKXXc5CR6zSvSVwVT
 pPKKHVgKCwygeGRmEW8IVhU2dAZbVsm7nrclIVCUCd4B+YzUc9ZzN/XtJEjUIPB0
 HWuAstkOiWjJbIa8ujYm6YKxUVcI3tbTTrVgnIME/o0112YqeuKyodjWG3wQBKrT
 cLGtRLsd7rJrgn8NkludKnikptQ02FfOlTDT45KS8XhG1JTV5+0a35bnmI2541tS
 OZoJRRq/XYyfakUGMG9NwaAIDpRwKHzrBGhDBvSnofq8StvEDjY=
 =SoT3
 -----END PGP SIGNATURE-----

Merge 5.4.209 into android11-5.4-lts

Changes in 5.4.209
	Bluetooth: L2CAP: Fix use-after-free caused by l2cap_chan_put
	ntfs: fix use-after-free in ntfs_ucsncmp()
	s390/archrandom: prevent CPACF trng invocations in interrupt context
	tcp: Fix data-races around sysctl_tcp_dsack.
	tcp: Fix a data-race around sysctl_tcp_app_win.
	tcp: Fix a data-race around sysctl_tcp_adv_win_scale.
	tcp: Fix a data-race around sysctl_tcp_frto.
	tcp: Fix a data-race around sysctl_tcp_nometrics_save.
	ice: check (DD | EOF) bits on Rx descriptor rather than (EOP | RS)
	ice: do not setup vlan for loopback VSI
	scsi: ufs: host: Hold reference returned by of_parse_phandle()
	tcp: Fix a data-race around sysctl_tcp_limit_output_bytes.
	tcp: Fix a data-race around sysctl_tcp_challenge_ack_limit.
	net: ping6: Fix memleak in ipv6_renew_options().
	ipv6/addrconf: fix a null-ptr-deref bug for ip6_ptr
	igmp: Fix data-races around sysctl_igmp_qrv.
	net: sungem_phy: Add of_node_put() for reference returned by of_get_parent()
	tcp: Fix a data-race around sysctl_tcp_min_tso_segs.
	tcp: Fix a data-race around sysctl_tcp_min_rtt_wlen.
	tcp: Fix a data-race around sysctl_tcp_autocorking.
	tcp: Fix a data-race around sysctl_tcp_invalid_ratelimit.
	Documentation: fix sctp_wmem in ip-sysctl.rst
	tcp: Fix a data-race around sysctl_tcp_comp_sack_delay_ns.
	tcp: Fix a data-race around sysctl_tcp_comp_sack_nr.
	i40e: Fix interface init with MSI interrupts (no MSI-X)
	sctp: fix sleep in atomic context bug in timer handlers
	netfilter: nf_queue: do not allow packet truncation below transport header offset
	virtio-net: fix the race between refill work and close
	perf symbol: Correct address for bss symbols
	sfc: disable softirqs for ptp TX
	sctp: leave the err path free in sctp_stream_init to sctp_stream_free
	ARM: crypto: comment out gcc warning that breaks clang builds
	mt7601u: add USB device ID for some versions of XiaoDu WiFi Dongle.
	scsi: core: Fix race between handling STS_RESOURCE and completion
	Linux 5.4.209

Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: I47925760dda15390893286236095322cdfb31837
2022-08-03 12:37:03 +02:00
ChenXiaoSong
911904c577 ntfs: fix use-after-free in ntfs_ucsncmp()
commit 38c9c22a85aeed28d0831f230136e9cf6fa2ed44 upstream.

Syzkaller reported use-after-free bug as follows:

==================================================================
BUG: KASAN: use-after-free in ntfs_ucsncmp+0x123/0x130
Read of size 2 at addr ffff8880751acee8 by task a.out/879

CPU: 7 PID: 879 Comm: a.out Not tainted 5.19.0-rc4-next-20220630-00001-gcc5218c8bd2c-dirty #7
Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS rel-1.16.0-0-gd239552ce722-prebuilt.qemu.org 04/01/2014
Call Trace:
 <TASK>
 dump_stack_lvl+0x1c0/0x2b0
 print_address_description.constprop.0.cold+0xd4/0x484
 print_report.cold+0x55/0x232
 kasan_report+0xbf/0xf0
 ntfs_ucsncmp+0x123/0x130
 ntfs_are_names_equal.cold+0x2b/0x41
 ntfs_attr_find+0x43b/0xb90
 ntfs_attr_lookup+0x16d/0x1e0
 ntfs_read_locked_attr_inode+0x4aa/0x2360
 ntfs_attr_iget+0x1af/0x220
 ntfs_read_locked_inode+0x246c/0x5120
 ntfs_iget+0x132/0x180
 load_system_files+0x1cc6/0x3480
 ntfs_fill_super+0xa66/0x1cf0
 mount_bdev+0x38d/0x460
 legacy_get_tree+0x10d/0x220
 vfs_get_tree+0x93/0x300
 do_new_mount+0x2da/0x6d0
 path_mount+0x496/0x19d0
 __x64_sys_mount+0x284/0x300
 do_syscall_64+0x3b/0xc0
 entry_SYSCALL_64_after_hwframe+0x46/0xb0
RIP: 0033:0x7f3f2118d9ea
Code: 48 8b 0d a9 f4 0b 00 f7 d8 64 89 01 48 83 c8 ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 49 89 ca b8 a5 00 00 00 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 8b 0d 76 f4 0b 00 f7 d8 64 89 01 48
RSP: 002b:00007ffc269deac8 EFLAGS: 00000202 ORIG_RAX: 00000000000000a5
RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 00007f3f2118d9ea
RDX: 0000000020000000 RSI: 0000000020000100 RDI: 00007ffc269dec00
RBP: 00007ffc269dec80 R08: 00007ffc269deb00 R09: 00007ffc269dec44
R10: 0000000000000000 R11: 0000000000000202 R12: 000055f81ab1d220
R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000
 </TASK>

The buggy address belongs to the physical page:
page:0000000085430378 refcount:1 mapcount:1 mapping:0000000000000000 index:0x555c6a81d pfn:0x751ac
memcg:ffff888101f7e180
anon flags: 0xfffffc00a0014(uptodate|lru|mappedtodisk|swapbacked|node=0|zone=1|lastcpupid=0x1fffff)
raw: 000fffffc00a0014 ffffea0001bf2988 ffffea0001de2448 ffff88801712e201
raw: 0000000555c6a81d 0000000000000000 0000000100000000 ffff888101f7e180
page dumped because: kasan: bad access detected

Memory state around the buggy address:
 ffff8880751acd80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
 ffff8880751ace00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
>ffff8880751ace80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
                                                          ^
 ffff8880751acf00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
 ffff8880751acf80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
==================================================================

The reason is that struct ATTR_RECORD->name_offset is 6485, end address of
name string is out of bounds.

Fix this by adding sanity check on end address of attribute name string.

[akpm@linux-foundation.org: coding-style cleanups]
[chenxiaosong2@huawei.com: cleanup suggested by Hawkins Jiawei]
  Link: https://lkml.kernel.org/r/20220709064511.3304299-1-chenxiaosong2@huawei.com
Link: https://lkml.kernel.org/r/20220707105329.4020708-1-chenxiaosong2@huawei.com
Signed-off-by: ChenXiaoSong <chenxiaosong2@huawei.com>
Signed-off-by: Hawkins Jiawei <yin31149@gmail.com>
Cc: Anton Altaparmakov <anton@tuxera.com>
Cc: ChenXiaoSong <chenxiaosong2@huawei.com>
Cc: Yongqiang Liu <liuyongqiang13@huawei.com>
Cc: Zhang Yi <yi.zhang@huawei.com>
Cc: Zhang Xiaoxu <zhangxiaoxu5@huawei.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2022-08-03 11:59:37 +02:00
Greg Kroah-Hartman
b1e3be07f2 This is the 5.4.208 stable release
-----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCAAdFiEEZH8oZUiU471FcZm+ONu9yGCSaT4FAmLj+VAACgkQONu9yGCS
 aT4kpQ//YdoyxUW1lOvPk9PIRm67ZADUXUwKKTTTO9hvOt886YkOaYghZj+nfTQ/
 SKsEFCh+jKRSG2bvnwUBh/sTTBBwUZeMpvfZZl2polhQT6JhJbBOt9+P/5enXN1O
 9grqt2i2QWA4+l52vnDAA7v5UD+td310GiyKmxiKqzAGaVte29kNLPwujZJM7J+Y
 8PUMI9gGEI8skCtjz7VsSIdvqB+p4B67iNnrDRKubOVUlXdr9f8xKj02DbiQxcnR
 TWc1+h7GIjD/Uibsne+pxAi90/V9A3RsNviZ7U3Igf3kCQ+HS7RH4hcSlU0v6GKy
 HDQrr/BHhGtPFtVCR0HJLbHVYmp/J+7H8V7LFY2mTd0lfkT1q58NRfUuGgRmDETI
 Ug3Dx8uxtUHgBPD1hsbyoSo0nYnleoCQZV+DFWTOF26nb1/85fyC+16U6uvagNw5
 Cdpt8ZVW9/qD8WnxnOuP6yvqw4MFZ0pFyhdQxxsyZpBj2sp5gLz6wRKLgUJX3a8q
 hrbWuR17cg+EA86EKZHxa5y4Wzv02FvljfTD60KvXqY67L4iPzrZWDV+ql9FVm/0
 wEYTLCjfDgDG9iY1e7Ns8ajD6KsBGfs0zO0vUFU4/LmX+EsJzJhfJ3c3zJhwrnDA
 ys2N1tvuSoef/4+JKhVfuxuGGl+mFdT+2yzKYCv3g16sX1OVcbA=
 =UvEH
 -----END PGP SIGNATURE-----

Merge 5.4.208 into android11-5.4-lts

Changes in 5.4.208
	pinctrl: stm32: fix optional IRQ support to gpios
	riscv: add as-options for modules with assembly compontents
	mlxsw: spectrum_router: Fix IPv4 nexthop gateway indication
	lockdown: Fix kexec lockdown bypass with ima policy
	xen/gntdev: Ignore failure to unmap INVALID_GRANT_HANDLE
	PCI: hv: Fix multi-MSI to allow more than one MSI vector
	PCI: hv: Fix hv_arch_irq_unmask() for multi-MSI
	PCI: hv: Reuse existing IRTE allocation in compose_msi_msg()
	PCI: hv: Fix interrupt mapping for multi-MSI
	serial: mvebu-uart: correctly report configured baudrate value
	xfrm: xfrm_policy: fix a possible double xfrm_pols_put() in xfrm_bundle_lookup()
	power/reset: arm-versatile: Fix refcount leak in versatile_reboot_probe
	pinctrl: ralink: Check for null return of devm_kcalloc
	perf/core: Fix data race between perf_event_set_output() and perf_mmap_close()
	igc: Reinstate IGC_REMOVED logic and implement it properly
	ip: Fix data-races around sysctl_ip_no_pmtu_disc.
	ip: Fix data-races around sysctl_ip_fwd_use_pmtu.
	ip: Fix data-races around sysctl_ip_nonlocal_bind.
	ip: Fix a data-race around sysctl_fwmark_reflect.
	tcp/dccp: Fix a data-race around sysctl_tcp_fwmark_accept.
	tcp: Fix data-races around sysctl_tcp_mtu_probing.
	tcp: Fix data-races around sysctl_tcp_base_mss.
	tcp: Fix data-races around sysctl_tcp_min_snd_mss.
	tcp: Fix a data-race around sysctl_tcp_mtu_probe_floor.
	tcp: Fix a data-race around sysctl_tcp_probe_threshold.
	tcp: Fix a data-race around sysctl_tcp_probe_interval.
	i2c: cadence: Change large transfer count reset logic to be unconditional
	net: stmmac: fix dma queue left shift overflow issue
	net/tls: Fix race in TLS device down flow
	igmp: Fix data-races around sysctl_igmp_llm_reports.
	igmp: Fix a data-race around sysctl_igmp_max_memberships.
	tcp: Fix data-races around sysctl_tcp_syncookies.
	tcp: Fix data-races around sysctl_tcp_reordering.
	tcp: Fix data-races around some timeout sysctl knobs.
	tcp: Fix a data-race around sysctl_tcp_notsent_lowat.
	tcp: Fix a data-race around sysctl_tcp_tw_reuse.
	tcp: Fix data-races around sysctl_max_syn_backlog.
	tcp: Fix data-races around sysctl_tcp_fastopen.
	iavf: Fix handling of dummy receive descriptors
	i40e: Fix erroneous adapter reinitialization during recovery process
	ixgbe: Add locking to prevent panic when setting sriov_numvfs to zero
	gpio: pca953x: only use single read/write for No AI mode
	be2net: Fix buffer overflow in be_get_module_eeprom
	ipv4: Fix a data-race around sysctl_fib_multipath_use_neigh.
	udp: Fix a data-race around sysctl_udp_l3mdev_accept.
	tcp: Fix data-races around sysctl knobs related to SYN option.
	tcp: Fix a data-race around sysctl_tcp_early_retrans.
	tcp: Fix data-races around sysctl_tcp_recovery.
	tcp: Fix a data-race around sysctl_tcp_thin_linear_timeouts.
	tcp: Fix data-races around sysctl_tcp_slow_start_after_idle.
	tcp: Fix a data-race around sysctl_tcp_retrans_collapse.
	tcp: Fix a data-race around sysctl_tcp_stdurg.
	tcp: Fix a data-race around sysctl_tcp_rfc1337.
	tcp: Fix data-races around sysctl_tcp_max_reordering.
	spi: bcm2835: bcm2835_spi_handle_err(): fix NULL pointer deref for non DMA transfers
	mm/mempolicy: fix uninit-value in mpol_rebind_policy()
	bpf: Make sure mac_header was set before using it
	dlm: fix pending remove if msg allocation fails
	ima: remove the IMA_TEMPLATE Kconfig option
	locking/refcount: Define constants for saturation and max refcount values
	locking/refcount: Ensure integer operands are treated as signed
	locking/refcount: Remove unused refcount_*_checked() variants
	locking/refcount: Move the bulk of the REFCOUNT_FULL implementation into the <linux/refcount.h> header
	locking/refcount: Improve performance of generic REFCOUNT_FULL code
	locking/refcount: Move saturation warnings out of line
	locking/refcount: Consolidate REFCOUNT_{MAX,SATURATED} definitions
	locking/refcount: Consolidate implementations of refcount_t
	x86: get rid of small constant size cases in raw_copy_{to,from}_user()
	x86/uaccess: Implement macros for CMPXCHG on user addresses
	mmap locking API: initial implementation as rwsem wrappers
	x86/mce: Deduplicate exception handling
	bitfield.h: Fix "type of reg too small for mask" test
	ALSA: memalloc: Align buffer allocations in page size
	Bluetooth: Add bt_skb_sendmsg helper
	Bluetooth: Add bt_skb_sendmmsg helper
	Bluetooth: SCO: Replace use of memcpy_from_msg with bt_skb_sendmsg
	Bluetooth: RFCOMM: Replace use of memcpy_from_msg with bt_skb_sendmmsg
	Bluetooth: Fix passing NULL to PTR_ERR
	Bluetooth: SCO: Fix sco_send_frame returning skb->len
	Bluetooth: Fix bt_skb_sendmmsg not allocating partial chunks
	tty: drivers/tty/, stop using tty_schedule_flip()
	tty: the rest, stop using tty_schedule_flip()
	tty: drop tty_schedule_flip()
	tty: extract tty_flip_buffer_commit() from tty_flip_buffer_push()
	tty: use new tty_insert_flip_string_and_push_buffer() in pty_write()
	net: usb: ax88179_178a needs FLAG_SEND_ZLP
	x86: drop bogus "cc" clobber from __try_cmpxchg_user_asm()
	Linux 5.4.208

Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: Ia53caf9bc847b0bb332a5b14972142d46ae5a740
2022-07-30 14:33:25 +02:00
Alexander Aring
bc7581e36d dlm: fix pending remove if msg allocation fails
[ Upstream commit ba58995909b5098ca4003af65b0ccd5a8d13dd25 ]

This patch unsets ls_remove_len and ls_remove_name if a message
allocation of a remove messages fails. In this case we never send a
remove message out but set the per ls ls_remove_len ls_remove_name
variable for a pending remove. Unset those variable should indicate
possible waiters in wait_pending_remove() that no pending remove is
going on at this moment.

Cc: stable@vger.kernel.org
Signed-off-by: Alexander Aring <aahringo@redhat.com>
Signed-off-by: David Teigland <teigland@redhat.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2022-07-29 17:14:16 +02:00
Greg Kroah-Hartman
836d95bfdc This is the 5.4.207 stable release
-----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCAAdFiEEZH8oZUiU471FcZm+ONu9yGCSaT4FAmLZohoACgkQONu9yGCS
 aT4D3RAA1Je6ingEk1e/IMmfWhNu/0AOrULMbrNBdM/WDOlIQLNBchhMa81UXEh7
 OJzt+NyBcuV4x5UdXj1fK3erJXA7tKM3s7BGY7OcXPDMpZjf9uOUV2Tg1Jw1jDbW
 TV7lnWv1YA7ze3eOx6qoR9sNPh4kYiW5DG2ivY8JMblKEz5EPCdvyPSSW+s8kmpg
 ZdyJ0pa3fnS0Di421DzJ+7R1U2t4C1eAz1FkngAyPM47GzwJoJxgcP4Q8syBmwGY
 qylUnrLTBMRtpngayaP15tQtYckGTbsnTUNCTjoW7BhbABkWysc2aVnCYZDLqBck
 C4XjEfBMLByICokuab0ewrzeVzvvHaY31hnhf33hYn6pgIoS5oy4T3mN7T8yEJz9
 zsr+unBioZFiIOqiVgu5A2Rwn3+1x8qOmLZ/x35jqZQCmh0ndlmHUhkdjl3y/68S
 XWvP4zpYBAR7QlW3WsGtFeI9Kbeh6y2tH0J79N5CjctAZFAvUaZd3cSfh3Vck02/
 7Wo9vs5zV8ZvRkdRWEawkrfe/PUImnDmvkv56nTH79bI7qIlpOU6kS6gy0sDzdGl
 YRKv4+jwE9/hJAcWW5S/U3wbfZMxMA6wdt8QcWsn0pXs1WFUQgWeNuyO2HNodff3
 jlp25lEi3C3NSUycmm9IjuG2241hPDYnhqeX0Q4B5ciPHCD4w3o=
 =KtMr
 -----END PGP SIGNATURE-----

Merge 5.4.207 into android11-5.4-lts

Changes in 5.4.207
	ALSA: hda - Add fixup for Dell Latitidue E5430
	ALSA: hda/conexant: Apply quirk for another HP ProDesk 600 G3 model
	ALSA: hda/realtek - Fix headset mic problem for a HP machine with alc671
	ALSA: hda/realtek - Fix headset mic problem for a HP machine with alc221
	ALSA: hda/realtek - Enable the headset-mic on a Xiaomi's laptop
	xen/netback: avoid entering xenvif_rx_next_skb() with an empty rx queue
	tracing/histograms: Fix memory leak problem
	net: sock: tracing: Fix sock_exceed_buf_limit not to dereference stale pointer
	ip: fix dflt addr selection for connected nexthop
	ARM: 9213/1: Print message about disabled Spectre workarounds only once
	ARM: 9214/1: alignment: advance IT state after emulating Thumb instruction
	wifi: mac80211: fix queue selection for mesh/OCB interfaces
	cgroup: Use separate src/dst nodes when preloading css_sets for migration
	drm/panfrost: Fix shrinker list corruption by madvise IOCTL
	nilfs2: fix incorrect masking of permission flags for symlinks
	Revert "evm: Fix memleak in init_desc"
	sched/rt: Disable RT_RUNTIME_SHARE by default
	ext4: fix race condition between ext4_write and ext4_convert_inline_data
	ARM: dts: imx6qdl-ts7970: Fix ngpio typo and count
	ARM: 9209/1: Spectre-BHB: avoid pr_info() every time a CPU comes out of idle
	ARM: 9210/1: Mark the FDT_FIXED sections as shareable
	drm/i915: fix a possible refcount leak in intel_dp_add_mst_connector()
	ima: Fix a potential integer overflow in ima_appraise_measurement
	ASoC: sgtl5000: Fix noise on shutdown/remove
	net: stmmac: dwc-qos: Disable split header for Tegra194
	inetpeer: Fix data-races around sysctl.
	net: Fix data-races around sysctl_mem.
	cipso: Fix data-races around sysctl.
	icmp: Fix data-races around sysctl.
	ipv4: Fix a data-race around sysctl_fib_sync_mem.
	ARM: dts: at91: sama5d2: Fix typo in i2s1 node
	ARM: dts: sunxi: Fix SPI NOR campatible on Orange Pi Zero
	drm/i915/gt: Serialize TLB invalidates with GT resets
	icmp: Fix a data-race around sysctl_icmp_ratelimit.
	icmp: Fix a data-race around sysctl_icmp_ratemask.
	raw: Fix a data-race around sysctl_raw_l3mdev_accept.
	ipv4: Fix data-races around sysctl_ip_dynaddr.
	net: ftgmac100: Hold reference returned by of_get_child_by_name()
	sfc: fix use after free when disabling sriov
	seg6: fix skb checksum evaluation in SRH encapsulation/insertion
	seg6: fix skb checksum in SRv6 End.B6 and End.B6.Encaps behaviors
	seg6: bpf: fix skb checksum in bpf_push_seg6_encap()
	sfc: fix kernel panic when creating VF
	mm: sysctl: fix missing numa_stat when !CONFIG_HUGETLB_PAGE
	virtio_mmio: Add missing PM calls to freeze/restore
	virtio_mmio: Restore guest page size on resume
	netfilter: br_netfilter: do not skip all hooks with 0 priority
	cpufreq: pmac32-cpufreq: Fix refcount leak bug
	platform/x86: hp-wmi: Ignore Sanitization Mode event
	net: tipc: fix possible refcount leak in tipc_sk_create()
	NFC: nxp-nci: don't print header length mismatch on i2c error
	nvme: fix regression when disconnect a recovering ctrl
	net: sfp: fix memory leak in sfp_probe()
	ASoC: ops: Fix off by one in range control validation
	ASoC: wm5110: Fix DRE control
	ASoC: cs47l15: Fix event generation for low power mux control
	ASoC: madera: Fix event generation for OUT1 demux
	ASoC: madera: Fix event generation for rate controls
	irqchip: or1k-pic: Undefine mask_ack for level triggered hardware
	x86: Clear .brk area at early boot
	soc: ixp4xx/npe: Fix unused match warning
	ARM: dts: stm32: use the correct clock source for CEC on stm32mp151
	signal handling: don't use BUG_ON() for debugging
	USB: serial: ftdi_sio: add Belimo device ids
	usb: typec: add missing uevent when partner support PD
	usb: dwc3: gadget: Fix event pending check
	tty: serial: samsung_tty: set dma burst_size to 1
	serial: 8250: fix return error code in serial8250_request_std_resource()
	serial: stm32: Clear prev values before setting RTS delays
	serial: pl011: UPSTAT_AUTORTS requires .throttle/unthrottle
	can: m_can: m_can_tx_handler(): fix use after free of skb
	Linux 5.4.207

Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: Ica75b787bd813b75db73739df2a831dbb4958668
2022-07-23 13:54:07 +02:00
Baokun Li
18881d7e51 ext4: fix race condition between ext4_write and ext4_convert_inline_data
commit f87c7a4b084afc13190cbb263538e444cb2b392a upstream.

Hulk Robot reported a BUG_ON:
 ==================================================================
 EXT4-fs error (device loop3): ext4_mb_generate_buddy:805: group 0,
 block bitmap and bg descriptor inconsistent: 25 vs 31513 free clusters
 kernel BUG at fs/ext4/ext4_jbd2.c:53!
 invalid opcode: 0000 [#1] SMP KASAN PTI
 CPU: 0 PID: 25371 Comm: syz-executor.3 Not tainted 5.10.0+ #1
 RIP: 0010:ext4_put_nojournal fs/ext4/ext4_jbd2.c:53 [inline]
 RIP: 0010:__ext4_journal_stop+0x10e/0x110 fs/ext4/ext4_jbd2.c:116
 [...]
 Call Trace:
  ext4_write_inline_data_end+0x59a/0x730 fs/ext4/inline.c:795
  generic_perform_write+0x279/0x3c0 mm/filemap.c:3344
  ext4_buffered_write_iter+0x2e3/0x3d0 fs/ext4/file.c:270
  ext4_file_write_iter+0x30a/0x11c0 fs/ext4/file.c:520
  do_iter_readv_writev+0x339/0x3c0 fs/read_write.c:732
  do_iter_write+0x107/0x430 fs/read_write.c:861
  vfs_writev fs/read_write.c:934 [inline]
  do_pwritev+0x1e5/0x380 fs/read_write.c:1031
 [...]
 ==================================================================

Above issue may happen as follows:
           cpu1                     cpu2
__________________________|__________________________
do_pwritev
 vfs_writev
  do_iter_write
   ext4_file_write_iter
    ext4_buffered_write_iter
     generic_perform_write
      ext4_da_write_begin
                           vfs_fallocate
                            ext4_fallocate
                             ext4_convert_inline_data
                              ext4_convert_inline_data_nolock
                               ext4_destroy_inline_data_nolock
                                clear EXT4_STATE_MAY_INLINE_DATA
                               ext4_map_blocks
                                ext4_ext_map_blocks
                                 ext4_mb_new_blocks
                                  ext4_mb_regular_allocator
                                   ext4_mb_good_group_nolock
                                    ext4_mb_init_group
                                     ext4_mb_init_cache
                                      ext4_mb_generate_buddy  --> error
       ext4_test_inode_state(inode, EXT4_STATE_MAY_INLINE_DATA)
                                ext4_restore_inline_data
                                 set EXT4_STATE_MAY_INLINE_DATA
       ext4_block_write_begin
      ext4_da_write_end
       ext4_test_inode_state(inode, EXT4_STATE_MAY_INLINE_DATA)
       ext4_write_inline_data_end
        handle=NULL
        ext4_journal_stop(handle)
         __ext4_journal_stop
          ext4_put_nojournal(handle)
           ref_cnt = (unsigned long)handle
           BUG_ON(ref_cnt == 0)  ---> BUG_ON

The lock held by ext4_convert_inline_data is xattr_sem, but the lock
held by generic_perform_write is i_rwsem. Therefore, the two locks can
be concurrent.

To solve above issue, we add inode_lock() for ext4_convert_inline_data().
At the same time, move ext4_convert_inline_data() in front of
ext4_punch_hole(), remove similar handling from ext4_punch_hole().

Fixes: 0c8d414f16 ("ext4: let fallocate handle inline data correctly")
Cc: stable@vger.kernel.org
Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Baokun Li <libaokun1@huawei.com>
Reviewed-by: Jan Kara <jack@suse.cz>
Link: https://lore.kernel.org/r/20220428134031.4153381-1-libaokun1@huawei.com
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Signed-off-by: Tadeusz Struk <tadeusz.struk@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2022-07-21 20:59:18 +02:00
Ryusuke Konishi
d85d19f3b6 nilfs2: fix incorrect masking of permission flags for symlinks
commit 5924e6ec1585445f251ea92713eb15beb732622a upstream.

The permission flags of newly created symlinks are wrongly dropped on
nilfs2 with the current umask value even though symlinks should have 777
(rwxrwxrwx) permissions:

 $ umask
 0022
 $ touch file && ln -s file symlink; ls -l file symlink
 -rw-r--r--. 1 root root 0 Jun 23 16:29 file
 lrwxr-xr-x. 1 root root 4 Jun 23 16:29 symlink -> file

This fixes the bug by inserting a missing check that excludes
symlinks.

Link: https://lkml.kernel.org/r/1655974441-5612-1-git-send-email-konishi.ryusuke@gmail.com
Signed-off-by: Ryusuke Konishi <konishi.ryusuke@gmail.com>
Reported-by: Tommy Pettersson <ptp@lysator.liu.se>
Reported-by: Ciprian Craciun <ciprian.craciun@gmail.com>
Tested-by: Ryusuke Konishi <konishi.ryusuke@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2022-07-21 20:59:18 +02:00
Greg Kroah-Hartman
a5112e9833 This is the 5.4.205 stable release
-----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCAAdFiEEZH8oZUiU471FcZm+ONu9yGCSaT4FAmLNhaMACgkQONu9yGCS
 aT6JwRAAuV/DRuVA4Ad6NmBK1n2Y/G6I2Y7ei8Mzi29Z4PDB0TIBVB7YLj+4Dril
 TJVsjQQmTnXtRF2qvYx1KfjOOL03vzJzm/kwuiAR8Sr8xrw9+klx5ANe4/J5tTkA
 /JyYM5fdhSuuJh1DXT/DPbHzF1DW/hR+4+1+M7Z2lbdFhwkHetIFHO8FBV1Sn946
 y08ERlbZ6Yb5ZX6skxotzj8ZUeOu3IMmhtPLITkzMwV0R+4NXIc7T/hzDiDUZ0go
 dX9Ret+JHoHTVHVJZXjXRHvHEA7K6F6kWBhRysSxYLupjBIqdq0mJqEaAH7xR6YD
 +OZsYilmny96p0SYcrTYJN4Q34PKtJ1yQteb+E872DT78QUX9DrAlXtNGK0IrVxI
 b9B65dy38Rk4tDPEDgO2S7VJbWmPF4EHxl/mUMhmitpanRanLA5CRX/aYGhCmbsV
 GbMUaKaVtPUdaLlOVdGVcNQeYAr3wFSnJg1hD5TpfGUAOny8iBUUsyYoeepT2594
 A1e67ZCpKBdPaQgtXvjfgzjwgvY6tVlSemZEw+LCsLEYWzgQwUhpam3BZfxFYmLx
 LOvA7Tj7uSVupDzSU9/9wbL3ViSbkTr5XJTies5nBSJJR7UlifLm9l4VWSPqijq3
 Z99ir3kruTOVUWZXyxgYPMGE5QAVh9bRXERRhC+tMB13fLXYoHI=
 =nsre
 -----END PGP SIGNATURE-----

Merge 5.4.205 into android11-5.4-lts

Changes in 5.4.205
	esp: limit skb_page_frag_refill use to a single page
	mm/slub: add missing TID updates on slab deactivation
	can: bcm: use call_rcu() instead of costly synchronize_rcu()
	can: grcan: grcan_probe(): remove extra of_node_get()
	can: gs_usb: gs_usb_open/close(): fix memory leak
	usbnet: fix memory leak in error case
	net: rose: fix UAF bug caused by rose_t0timer_expiry
	iommu/vt-d: Fix PCI bus rescan device hot add
	fbdev: fbmem: Fix logo center image dx issue
	fbmem: Check virtual screen sizes in fb_set_var()
	fbcon: Disallow setting font bigger than screen size
	fbcon: Prevent that screen size is smaller than font size
	video: of_display_timing.h: include errno.h
	powerpc/powernv: delay rng platform device creation until later in boot
	can: kvaser_usb: replace run-time checks with struct kvaser_usb_driver_info
	can: kvaser_usb: kvaser_usb_leaf: fix CAN clock frequency regression
	can: kvaser_usb: kvaser_usb_leaf: fix bittiming limits
	xfs: remove incorrect ASSERT in xfs_rename
	ARM: meson: Fix refcount leak in meson_smp_prepare_cpus
	pinctrl: sunxi: a83t: Fix NAND function name for some pins
	pinctrl: sunxi: sunxi_pconf_set: use correct offset
	ARM: at91: pm: use proper compatible for sama5d2's rtc
	ARM: at91: pm: use proper compatibles for sam9x60's rtc and rtt
	ibmvnic: Properly dispose of all skbs during a failover.
	selftests: forwarding: fix flood_unicast_test when h2 supports IFF_UNICAST_FLT
	selftests: forwarding: fix learning_test when h1 supports IFF_UNICAST_FLT
	selftests: forwarding: fix error message in learning_test
	i2c: cadence: Unregister the clk notifier in error path
	dmaengine: imx-sdma: Allow imx8m for imx7 FW revs
	misc: rtsx_usb: fix use of dma mapped buffer for usb bulk transfer
	misc: rtsx_usb: use separate command and response buffers
	misc: rtsx_usb: set return value in rsp_buf alloc err path
	dt-bindings: dma: allwinner,sun50i-a64-dma: Fix min/max typo
	ida: don't use BUG_ON() for debugging
	dmaengine: pl330: Fix lockdep warning about non-static key
	dmaengine: at_xdma: handle errors of at_xdmac_alloc_desc() correctly
	dmaengine: ti: Fix refcount leak in ti_dra7_xbar_route_allocate
	dmaengine: ti: Add missing put_device in ti_dra7_xbar_route_allocate
	Linux 5.4.205

Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: I4703f4f796340ab54bf168101d41da2a001419f0
2022-07-12 21:08:00 +02:00
Eric Sandeen
c465bbcd3c xfs: remove incorrect ASSERT in xfs_rename
commit e445976537ad139162980bee015b7364e5b64fff upstream.

This ASSERT in xfs_rename is a) incorrect, because
(RENAME_WHITEOUT|RENAME_NOREPLACE) is a valid combination, and
b) unnecessary, because actual invalid flag combinations are already
handled at the vfs level in do_renameat2() before we get called.
So, remove it.

Reported-by: Paolo Bonzini <pbonzini@redhat.com>
Signed-off-by: Eric Sandeen <sandeen@redhat.com>
Reviewed-by: Darrick J. Wong <djwong@kernel.org>
Signed-off-by: Darrick J. Wong <djwong@kernel.org>
Fixes: 7dcf5c3e45 ("xfs: add RENAME_WHITEOUT support")
Signed-off-by: Kuniyuki Iwashima <kuniyu@amazon.com>
Acked-by: Darrick J. Wong <djwong@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2022-07-12 16:30:48 +02:00
Greg Kroah-Hartman
8e932637c7 This is the 5.4.202 stable release
-----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCAAdFiEEZH8oZUiU471FcZm+ONu9yGCSaT4FAmK7+C0ACgkQONu9yGCS
 aT7ABRAApBLbHpMdFCb6y74Fou+BzFOCdmP8zhFCShBQM8aWdyjTzCyyF+C9mUQv
 Yxr2dSCRTwlalfL5uuUh1iSIfD6ggM+d7SzZpWz13WeJOECdRmSQYK2yjvdievzb
 Ce3YyqE2XLhZENY6e3tJmk5e0g5Sq3VAgmyghOshaP8Jn63ASuADW+GDjIVn+wSW
 udnq9tSV6Seq6BxTBtz+eX64vwcnRgz1Z0TC/BXlMCnboHJe9W62XejKxm/n/zMF
 d6EoHroY9IV9/OYyfClVJhGx6nnkJc9EnLPejcnF847HGd//Mhx9GOLbf5MUro3b
 ZSPmdPF7XryjX0iBvz1AUIPjHFYhVfXpALz6GtMKvvkX5r42ShwWrmidLjnCOeE3
 TCkwrFYdkGKB3ldsu+OcBh8lEbn8HDmjRY117YEBWRTosn07ANtDFbXHKD+mWQDw
 JjfdxSRuhTEHpgrwDhvLhm2guq7C5zF78O7JWtv7XelI9MyufIkB9RcVqjaMTfpA
 3iqOBICRXrKeSNfCdBACUYm3++XmRFZWgX9mSVWwfXTLWbDzONhY1y1oJdWNFZex
 lQhrEardpxHxVMHEppXioWZhbEC7ugYy6MB67M/aTDcPkxerXh4XGMTPxbMcCEwW
 0sIA0Kfko3j+qWyYtVG5/T3WJQhOKqEjt9B9GtmGKy/3dpRAe48=
 =i4p5
 -----END PGP SIGNATURE-----

Merge 5.4.202 into android11-5.4-lts

Changes in 5.4.202
	vt: drop old FONT ioctls
	random: schedule mix_interrupt_randomness() less often
	ALSA: hda/via: Fix missing beep setup
	ALSA: hda/conexant: Fix missing beep setup
	ALSA: hda/realtek - ALC897 headset MIC no sound
	ALSA: hda/realtek: Add quirk for Clevo PD70PNT
	net: openvswitch: fix parsing of nw_proto for IPv6 fragments
	mmc: sdhci-pci-o2micro: Fix card detect by dealing with debouncing
	mtd: rawnand: gpmi: Fix setting busy timeout setting
	ata: libata: add qc->flags in ata_qc_complete_template tracepoint
	dm era: commit metadata in postsuspend after worker stops
	dm mirror log: clear log bits up to BITS_PER_LONG boundary
	random: quiet urandom warning ratelimit suppression message
	USB: serial: option: add Telit LE910Cx 0x1250 composition
	USB: serial: option: add Quectel EM05-G modem
	USB: serial: option: add Quectel RM500K module support
	bpf: Fix request_sock leak in sk lookup helpers
	phy: aquantia: Fix AN when higher speeds than 1G are not advertised
	bonding: ARP monitor spams NETDEV_NOTIFY_PEERS notifiers
	net/sched: sch_netem: Fix arithmetic in netem_dump() for 32-bit platforms
	drm/msm/mdp4: Fix refcount leak in mdp4_modeset_init_intf
	erspan: do not assume transport header is always set
	net/tls: fix tls_sk_proto_close executed repeatedly
	udmabuf: add back sanity check
	x86/xen: Remove undefined behavior in setup_features()
	MIPS: Remove repetitive increase irq_err_count
	afs: Fix dynamic root getattr
	ice: ethtool: advertise 1000M speeds properly
	regmap-irq: Fix a bug in regmap_irq_enable() for type_in_mask chips
	igb: Make DMA faster when CPU is active on the PCIe link
	virtio_net: fix xdp_rxq_info bug after suspend/resume
	Revert "net/tls: fix tls_sk_proto_close executed repeatedly"
	gpio: winbond: Fix error code in winbond_gpio_get()
	s390/cpumf: Handle events cycles and instructions identical
	iio: adc: vf610: fix conversion mode sysfs node name
	xhci: turn off port power in shutdown
	usb: chipidea: udc: check request status before setting device address
	iio:chemical:ccs811: rearrange iio trigger get and register
	iio:accel:bma180: rearrange iio trigger get and register
	iio:accel:mxc4005: rearrange iio trigger get and register
	iio: accel: mma8452: ignore the return value of reset operation
	iio: gyro: mpu3050: Fix the error handling in mpu3050_power_up()
	iio: trigger: sysfs: fix use-after-free on remove
	iio: adc: stm32: fix maximum clock rate for stm32mp15x
	iio: adc: axp288: Override TS pin bias current for some models
	xtensa: xtfpga: Fix refcount leak bug in setup
	xtensa: Fix refcount leak bug in time.c
	parisc: Enable ARCH_HAS_STRICT_MODULE_RWX
	powerpc: Enable execve syscall exit tracepoint
	powerpc/rtas: Allow ibm,platform-dump RTAS call with null buffer address
	powerpc/powernv: wire up rng during setup_arch
	ARM: dts: imx6qdl: correct PU regulator ramp delay
	ARM: exynos: Fix refcount leak in exynos_map_pmu
	soc: bcm: brcmstb: pm: pm-arm: Fix refcount leak in brcmstb_pm_probe
	ARM: Fix refcount leak in axxia_boot_secondary
	ARM: cns3xxx: Fix refcount leak in cns3xxx_init
	modpost: fix section mismatch check for exported init/exit sections
	random: update comment from copy_to_user() -> copy_to_iter()
	kbuild: link vmlinux only once for CONFIG_TRIM_UNUSED_KSYMS (2nd attempt)
	powerpc/pseries: wire up rng during setup_arch()
	Linux 5.4.202

Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: Ide925d318c8d1f6c3ba72df07c40105a9e5913d5
2022-06-29 09:05:51 +02:00
David Howells
e3a232e576 afs: Fix dynamic root getattr
[ Upstream commit cb78d1b5efffe4cf97e16766329dd7358aed3deb ]

The recent patch to make afs_getattr consult the server didn't account
for the pseudo-inodes employed by the dynamic root-type afs superblock
not having a volume or a server to access, and thus an oops occurs if
such a directory is stat'd.

Fix this by checking to see if the vnode->volume pointer actually points
anywhere before following it in afs_getattr().

This can be tested by stat'ing a directory in /afs.  It may be
sufficient just to do "ls /afs" and the oops looks something like:

        BUG: kernel NULL pointer dereference, address: 0000000000000020
        ...
        RIP: 0010:afs_getattr+0x8b/0x14b
        ...
        Call Trace:
         <TASK>
         vfs_statx+0x79/0xf5
         vfs_fstatat+0x49/0x62

Fixes: 2aeb8c86d499 ("afs: Fix afs_getattr() to refetch file status if callback break occurred")
Reported-by: Marc Dionne <marc.dionne@auristor.com>
Signed-off-by: David Howells <dhowells@redhat.com>
Reviewed-by: Marc Dionne <marc.dionne@auristor.com>
Tested-by: Marc Dionne <marc.dionne@auristor.com>
cc: linux-afs@lists.infradead.org
Link: https://lore.kernel.org/r/165408450783.1031787.7941404776393751186.stgit@warthog.procyon.org.uk/
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2022-06-29 08:58:46 +02:00
Jan Kara
1dd92ce7e8 UPSTREAM: ext4: verify dir block before splitting it
commit 46c116b920ebec58031f0a78c5ea9599b0d2a371 upstream.

Before splitting a directory block verify its directory entries are sane
so that the splitting code does not access memory it should not.

Cc: stable@vger.kernel.org
Signed-off-by: Jan Kara <jack@suse.cz>
Link: https://lore.kernel.org/r/20220518093332.13986-1-jack@suse.cz
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
(cherry picked from commit 17034d45ec)
Change-Id: Iaaecaddd868150834b0cdef0f0889a39c2226e41
2022-06-24 08:10:03 +00:00
Ye Bin
1765fa5267 UPSTREAM: ext4: fix use-after-free in ext4_rename_dir_prepare
commit 0be698ecbe4471fcad80e81ec6a05001421041b3 upstream.

We got issue as follows:
EXT4-fs (loop0): mounted filesystem without journal. Opts: ,errors=continue
ext4_get_first_dir_block: bh->b_data=0xffff88810bee6000 len=34478
ext4_get_first_dir_block: *parent_de=0xffff88810beee6ae bh->b_data=0xffff88810bee6000
ext4_rename_dir_prepare: [1] parent_de=0xffff88810beee6ae
==================================================================
BUG: KASAN: use-after-free in ext4_rename_dir_prepare+0x152/0x220
Read of size 4 at addr ffff88810beee6ae by task rep/1895

CPU: 13 PID: 1895 Comm: rep Not tainted 5.10.0+ #241
Call Trace:
 dump_stack+0xbe/0xf9
 print_address_description.constprop.0+0x1e/0x220
 kasan_report.cold+0x37/0x7f
 ext4_rename_dir_prepare+0x152/0x220
 ext4_rename+0xf44/0x1ad0
 ext4_rename2+0x11c/0x170
 vfs_rename+0xa84/0x1440
 do_renameat2+0x683/0x8f0
 __x64_sys_renameat+0x53/0x60
 do_syscall_64+0x33/0x40
 entry_SYSCALL_64_after_hwframe+0x44/0xa9
RIP: 0033:0x7f45a6fc41c9
RSP: 002b:00007ffc5a470218 EFLAGS: 00000246 ORIG_RAX: 0000000000000108
RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 00007f45a6fc41c9
RDX: 0000000000000005 RSI: 0000000020000180 RDI: 0000000000000005
RBP: 00007ffc5a470240 R08: 00007ffc5a470160 R09: 0000000020000080
R10: 00000000200001c0 R11: 0000000000000246 R12: 0000000000400bb0
R13: 00007ffc5a470320 R14: 0000000000000000 R15: 0000000000000000

The buggy address belongs to the page:
page:00000000440015ce refcount:0 mapcount:0 mapping:0000000000000000 index:0x1 pfn:0x10beee
flags: 0x200000000000000()
raw: 0200000000000000 ffffea00043ff4c8 ffffea0004325608 0000000000000000
raw: 0000000000000001 0000000000000000 00000000ffffffff 0000000000000000
page dumped because: kasan: bad access detected

Memory state around the buggy address:
 ffff88810beee580: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
 ffff88810beee600: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
>ffff88810beee680: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
                                  ^
 ffff88810beee700: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
 ffff88810beee780: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
==================================================================
Disabling lock debugging due to kernel taint
ext4_rename_dir_prepare: [2] parent_de->inode=3537895424
ext4_rename_dir_prepare: [3] dir=0xffff888124170140
ext4_rename_dir_prepare: [4] ino=2
ext4_rename_dir_prepare: ent->dir->i_ino=2 parent=-757071872

Reason is first directory entry which 'rec_len' is 34478, then will get illegal
parent entry. Now, we do not check directory entry after read directory block
in 'ext4_get_first_dir_block'.
To solve this issue, check directory entry in 'ext4_get_first_dir_block'.

[ Trigger an ext4_error() instead of just warning if the directory is
  missing a '.' or '..' entry.   Also make sure we return an error code
  if the file system is corrupted.  -TYT ]

Signed-off-by: Ye Bin <yebin10@huawei.com>
Reviewed-by: Jan Kara <jack@suse.cz>
Link: https://lore.kernel.org/r/20220414025223.4113128-1-yebin10@huawei.com
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Cc: stable@kernel.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
(cherry picked from commit eaecf7ebfd)
Change-Id: Ibdaf266e6444efd9cd8465cb5a7614d437e82ce2
2022-06-24 08:10:03 +00:00
Daniel Rosenberg
24ee3133e7 BACKPORT: ext4: Only advertise encrypted_casefold when encryption and unicode are enabled
[ Upstream commit e71f99f2dfb45f4e7203a0732e85f71ef1d04dab ]

Encrypted casefolding is only supported when both encryption and
casefolding are both enabled in the config.

Fixes: 471fbbea7ff7 ("ext4: handle casefolding with encryption")
Cc: stable@vger.kernel.org # 5.13+
Signed-off-by: Daniel Rosenberg <drosen@google.com>
Link: https://lore.kernel.org/r/20210603094849.314342-1-drosen@google.com
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Change-Id: I4655b3aab60006ea03fb3454a0a833634546373b
2022-06-24 08:10:03 +00:00
Daniel Rosenberg
4adf828284 BACKPORT: ext4: fix no-key deletion for encrypt+casefold
[ Upstream commit 63e7f1289389c8dff3c766f01ac1cc1c874b2ba5 ]

commit 471fbbea7ff7 ("ext4: handle casefolding with encryption") is
missing a few checks for the encryption key which are needed to
support deleting enrypted casefolded files when the key is not
present.

This bug made it impossible to delete encrypted+casefolded directories
without the encryption key, due to errors like:

    W         : EXT4-fs warning (device vdc): __ext4fs_dirhash:270: inode #49202: comm Binder:378_4: Siphash requires key

Repro steps in kvm-xfstests test appliance:
      mkfs.ext4 -F -E encoding=utf8 -O encrypt /dev/vdc
      mount /vdc
      mkdir /vdc/dir
      chattr +F /vdc/dir
      keyid=$(head -c 64 /dev/zero | xfs_io -c add_enckey /vdc | awk '{print $NF}')
      xfs_io -c "set_encpolicy $keyid" /vdc/dir
      for i in `seq 1 100`; do
          mkdir /vdc/dir/$i
      done
      xfs_io -c "rm_enckey $keyid" /vdc
      rm -rf /vdc/dir # fails with the bug

Fixes: 471fbbea7ff7 ("ext4: handle casefolding with encryption")
Signed-off-by: Daniel Rosenberg <drosen@google.com>
Link: https://lore.kernel.org/r/20210522004132.2142563-1-drosen@google.com
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Change-Id: Idbf9a46ebac38df02603c13206b41459762d2b8b
2022-06-24 08:10:03 +00:00
Daniel Rosenberg
7f4133a55e BACKPORT: ext4: optimize match for casefolded encrypted dirs
[ Upstream commit 1ae98e295fa2577fb5e492200c58d10230e00e99 ]

Matching names with casefolded encrypting directories requires
decrypting entries to confirm case since we are case preserving. We can
avoid needing to decrypt if our hash values don't match.

Signed-off-by: Daniel Rosenberg <drosen@google.com>
Link: https://lore.kernel.org/r/20210319073414.1381041-3-drosen@google.com
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Change-Id: Ic74307e53dc59ec47575f33c56e291ccd137520d
2022-06-24 08:10:03 +00:00
Daniel Rosenberg
ce3b26019c BACKPORT: ext4: handle casefolding with encryption
[ Upstream commit 471fbbea7ff7061b2d6474665cb5a2ceb4fd6500 ]

This adds support for encryption with casefolding.

Since the name on disk is case preserving, and also encrypted, we can no
longer just recompute the hash on the fly. Additionally, to avoid
leaking extra information from the hash of the unencrypted name, we use
siphash via an fscrypt v2 policy.

The hash is stored at the end of the directory entry for all entries
inside of an encrypted and casefolded directory apart from those that
deal with '.' and '..'. This way, the change is backwards compatible
with existing ext4 filesystems.

[ Changed to advertise this feature via the file:
  /sys/fs/ext4/features/encrypted_casefold -- TYT ]

Signed-off-by: Daniel Rosenberg <drosen@google.com>
Reviewed-by: Andreas Dilger <adilger@dilger.ca>
Link: https://lore.kernel.org/r/20210319073414.1381041-2-drosen@google.com
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Change-Id: I61653ddb324bae4bad77ccd49384159103b499f5
2022-06-24 08:10:03 +00:00
Daniel Rosenberg
8515bb68ee Revert "ANDROID: ext4: Handle casefolding with encryption"
This reverts commit 268041d71e.

Replacing with upstream version

Signed-off-by: Daniel Rosenberg <drosen@google.com>
Change-Id: Icedfb2bada2722e8325abd3962403d61f6ffd885
2022-06-24 08:10:03 +00:00
Daniel Rosenberg
91b58da1b3 Revert "ANDROID: ext4: Optimize match for casefolded encrypted dirs"
This reverts commit 954d16b089.

Replacing with upstream version

Signed-off-by: Daniel Rosenberg <drosen@google.com>
Change-Id: I3a349e3e6e5101806ba1564d4a2d84796f8b16a3
2022-06-24 08:10:03 +00:00
Greg Kroah-Hartman
b2351c2368 This is the 5.4.200 stable release
-----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCAAdFiEEZH8oZUiU471FcZm+ONu9yGCSaT4FAmKzBvAACgkQONu9yGCS
 aT7I5A//eBWtBQ7E3MDCDTiZW8RQ+VT0dG87UmqmxJBnafbxuywkvasN3ysJu5Pk
 xA5k5MM5zbb5YFVlO+BRqjgj4d/CM1sNW5k6/PQgJnlHTYC4oCRFr5FlBLaGT4ER
 IGIyJciELMJTL02OWIdUFd0yylrDP1tyjpxlmBt3BapY5n4VxqbDQWYHnrZPKAw3
 f2wDzMLMwm5M6/W+TihCaJNOp6N/SZRW1j9RquKBiur3CwA2yRpmIIE/LawVtpK3
 BDuGYYgmQevi7cV2ZIYp8kb05M9n6WEXFlzy0jq2qLfrsc5+pCiiqtjOTDDzQRFd
 k/NXRNoRLNmAZn3JPoF6rMyDlV2LPC16tJ+JsBMHB5CMbcv7kdTh9wxdx842UEkR
 Sck+DRBoErBIIP7uD63fTMTwX7jgC4C7YsZ1abmrY0+ANJ5ribXEKj+XeasDoT5Y
 kt9IJ3HersxM1e6NEDi3L4z7x9v3LbghUmDzZPHnuSZsb3CKUFwDs3hOf+XxhjWE
 Hds98MabbBuzqnWR+GIhBhA1C+CiFF3f3sMMK43sY3dhrqs9S3aZMxWdmBK1Us4y
 D6OK1BCp9oQ5bdstdGtx80HTMU8hUqlu51GMxXolfwcyIKAvLswYzBvGi7Pft2v1
 s+z/1kSIAWpeUf14AUir3eCR07QWEyGiLKgn7JrD2p3irWhfBCM=
 =6xFB
 -----END PGP SIGNATURE-----

Merge 5.4.200 into android11-5.4-lts

Changes in 5.4.200
	9p: missing chunk of "fs/9p: Don't update file type when updating file attributes"
	bpf: Fix incorrect memory charge cost calculation in stack_map_alloc()
	nfc: st21nfca: fix incorrect sizing calculations in EVT_TRANSACTION
	crypto: blake2s - generic C library implementation and selftest
	lib/crypto: blake2s: move hmac construction into wireguard
	lib/crypto: sha1: re-roll loops to reduce code size
	compat_ioctl: remove /dev/random commands
	random: don't forget compat_ioctl on urandom
	random: Don't wake crng_init_wait when crng_init == 1
	random: Add a urandom_read_nowait() for random APIs that don't warn
	random: add GRND_INSECURE to return best-effort non-cryptographic bytes
	random: ignore GRND_RANDOM in getentropy(2)
	random: make /dev/random be almost like /dev/urandom
	random: remove the blocking pool
	random: delete code to pull data into pools
	random: remove kernel.random.read_wakeup_threshold
	random: remove unnecessary unlikely()
	random: convert to ENTROPY_BITS for better code readability
	random: Add and use pr_fmt()
	random: fix typo in add_timer_randomness()
	random: remove some dead code of poolinfo
	random: split primary/secondary crng init paths
	random: avoid warnings for !CONFIG_NUMA builds
	x86: Remove arch_has_random, arch_has_random_seed
	powerpc: Remove arch_has_random, arch_has_random_seed
	s390: Remove arch_has_random, arch_has_random_seed
	linux/random.h: Remove arch_has_random, arch_has_random_seed
	linux/random.h: Use false with bool
	linux/random.h: Mark CONFIG_ARCH_RANDOM functions __must_check
	powerpc: Use bool in archrandom.h
	random: add arch_get_random_*long_early()
	random: avoid arch_get_random_seed_long() when collecting IRQ randomness
	random: remove dead code left over from blocking pool
	MAINTAINERS: co-maintain random.c
	crypto: blake2s - include <linux/bug.h> instead of <asm/bug.h>
	crypto: blake2s - adjust include guard naming
	random: document add_hwgenerator_randomness() with other input functions
	random: remove unused irq_flags argument from add_interrupt_randomness()
	random: use BLAKE2s instead of SHA1 in extraction
	random: do not sign extend bytes for rotation when mixing
	random: do not re-init if crng_reseed completes before primary init
	random: mix bootloader randomness into pool
	random: harmonize "crng init done" messages
	random: use IS_ENABLED(CONFIG_NUMA) instead of ifdefs
	random: initialize ChaCha20 constants with correct endianness
	random: early initialization of ChaCha constants
	random: avoid superfluous call to RDRAND in CRNG extraction
	random: don't reset crng_init_cnt on urandom_read()
	random: fix typo in comments
	random: cleanup poolinfo abstraction
	random: cleanup integer types
	random: remove incomplete last_data logic
	random: remove unused extract_entropy() reserved argument
	random: rather than entropy_store abstraction, use global
	random: remove unused OUTPUT_POOL constants
	random: de-duplicate INPUT_POOL constants
	random: prepend remaining pool constants with POOL_
	random: cleanup fractional entropy shift constants
	random: access input_pool_data directly rather than through pointer
	random: selectively clang-format where it makes sense
	random: simplify arithmetic function flow in account()
	random: continually use hwgenerator randomness
	random: access primary_pool directly rather than through pointer
	random: only call crng_finalize_init() for primary_crng
	random: use computational hash for entropy extraction
	random: simplify entropy debiting
	random: use linear min-entropy accumulation crediting
	random: always wake up entropy writers after extraction
	random: make credit_entropy_bits() always safe
	random: remove use_input_pool parameter from crng_reseed()
	random: remove batched entropy locking
	random: fix locking in crng_fast_load()
	random: use RDSEED instead of RDRAND in entropy extraction
	random: get rid of secondary crngs
	random: inline leaves of rand_initialize()
	random: ensure early RDSEED goes through mixer on init
	random: do not xor RDRAND when writing into /dev/random
	random: absorb fast pool into input pool after fast load
	random: use simpler fast key erasure flow on per-cpu keys
	random: use hash function for crng_slow_load()
	random: make more consistent use of integer types
	random: remove outdated INT_MAX >> 6 check in urandom_read()
	random: zero buffer after reading entropy from userspace
	random: fix locking for crng_init in crng_reseed()
	random: tie batched entropy generation to base_crng generation
	random: remove ifdef'd out interrupt bench
	random: remove unused tracepoints
	random: add proper SPDX header
	random: deobfuscate irq u32/u64 contributions
	random: introduce drain_entropy() helper to declutter crng_reseed()
	random: remove useless header comment
	random: remove whitespace and reorder includes
	random: group initialization wait functions
	random: group crng functions
	random: group entropy extraction functions
	random: group entropy collection functions
	random: group userspace read/write functions
	random: group sysctl functions
	random: rewrite header introductory comment
	random: defer fast pool mixing to worker
	random: do not take pool spinlock at boot
	random: unify early init crng load accounting
	random: check for crng_init == 0 in add_device_randomness()
	random: pull add_hwgenerator_randomness() declaration into random.h
	random: clear fast pool, crng, and batches in cpuhp bring up
	random: round-robin registers as ulong, not u32
	random: only wake up writers after zap if threshold was passed
	random: cleanup UUID handling
	random: unify cycles_t and jiffies usage and types
	random: do crng pre-init loading in worker rather than irq
	random: give sysctl_random_min_urandom_seed a more sensible value
	random: don't let 644 read-only sysctls be written to
	random: replace custom notifier chain with standard one
	random: use SipHash as interrupt entropy accumulator
	random: make consistent usage of crng_ready()
	random: reseed more often immediately after booting
	random: check for signal and try earlier when generating entropy
	random: skip fast_init if hwrng provides large chunk of entropy
	random: treat bootloader trust toggle the same way as cpu trust toggle
	random: re-add removed comment about get_random_{u32,u64} reseeding
	random: mix build-time latent entropy into pool at init
	random: do not split fast init input in add_hwgenerator_randomness()
	random: do not allow user to keep crng key around on stack
	random: check for signal_pending() outside of need_resched() check
	random: check for signals every PAGE_SIZE chunk of /dev/[u]random
	random: allow partial reads if later user copies fail
	random: make random_get_entropy() return an unsigned long
	random: document crng_fast_key_erasure() destination possibility
	random: fix sysctl documentation nits
	init: call time_init() before rand_initialize()
	ia64: define get_cycles macro for arch-override
	s390: define get_cycles macro for arch-override
	parisc: define get_cycles macro for arch-override
	alpha: define get_cycles macro for arch-override
	powerpc: define get_cycles macro for arch-override
	timekeeping: Add raw clock fallback for random_get_entropy()
	m68k: use fallback for random_get_entropy() instead of zero
	mips: use fallback for random_get_entropy() instead of just c0 random
	arm: use fallback for random_get_entropy() instead of zero
	nios2: use fallback for random_get_entropy() instead of zero
	x86/tsc: Use fallback for random_get_entropy() instead of zero
	um: use fallback for random_get_entropy() instead of zero
	sparc: use fallback for random_get_entropy() instead of zero
	xtensa: use fallback for random_get_entropy() instead of zero
	random: insist on random_get_entropy() existing in order to simplify
	random: do not use batches when !crng_ready()
	random: use first 128 bits of input as fast init
	random: do not pretend to handle premature next security model
	random: order timer entropy functions below interrupt functions
	random: do not use input pool from hard IRQs
	random: help compiler out with fast_mix() by using simpler arguments
	siphash: use one source of truth for siphash permutations
	random: use symbolic constants for crng_init states
	random: avoid initializing twice in credit race
	random: move initialization out of reseeding hot path
	random: remove ratelimiting for in-kernel unseeded randomness
	random: use proper jiffies comparison macro
	random: handle latent entropy and command line from random_init()
	random: credit architectural init the exact amount
	random: use static branch for crng_ready()
	random: remove extern from functions in header
	random: use proper return types on get_random_{int,long}_wait()
	random: make consistent use of buf and len
	random: move initialization functions out of hot pages
	random: move randomize_page() into mm where it belongs
	random: unify batched entropy implementations
	random: convert to using fops->read_iter()
	random: convert to using fops->write_iter()
	random: wire up fops->splice_{read,write}_iter()
	random: check for signals after page of pool writes
	Revert "random: use static branch for crng_ready()"
	crypto: drbg - always seeded with SP800-90B compliant noise source
	crypto: drbg - prepare for more fine-grained tracking of seeding state
	crypto: drbg - track whether DRBG was seeded with !rng_is_initialized()
	crypto: drbg - move dynamic ->reseed_threshold adjustments to __drbg_seed()
	crypto: drbg - always try to free Jitter RNG instance
	crypto: drbg - make reseeding from get_random_bytes() synchronous
	random: avoid checking crng_ready() twice in random_init()
	random: mark bootloader randomness code as __init
	random: account for arch randomness in bits
	powerpc/kasan: Silence KASAN warnings in __get_wchan()
	ASoC: nau8822: Add operation for internal PLL off and on
	dma-debug: make things less spammy under memory pressure
	ASoC: cs42l52: Fix TLV scales for mixer controls
	ASoC: cs35l36: Update digital volume TLV
	ASoC: cs53l30: Correct number of volume levels on SX controls
	ASoC: cs42l52: Correct TLV for Bypass Volume
	ASoC: cs42l56: Correct typo in minimum level for SX volume controls
	ata: libata-core: fix NULL pointer deref in ata_host_alloc_pinfo()
	ASoC: wm8962: Fix suspend while playing music
	ASoC: es8328: Fix event generation for deemphasis control
	ASoC: wm_adsp: Fix event generation for wm_adsp_fw_put()
	scsi: vmw_pvscsi: Expand vcpuHint to 16 bits
	scsi: lpfc: Fix port stuck in bypassed state after LIP in PT2PT topology
	scsi: lpfc: Allow reduced polling rate for nvme_admin_async_event cmd completion
	scsi: ipr: Fix missing/incorrect resource cleanup in error case
	scsi: pmcraid: Fix missing resource cleanup in error case
	ALSA: hda/realtek - Add HW8326 support
	virtio-mmio: fix missing put_device() when vm_cmdline_parent registration failed
	nfc: nfcmrvl: Fix memory leak in nfcmrvl_play_deferred
	ipv6: Fix signed integer overflow in l2tp_ip6_sendmsg
	net: ethernet: mtk_eth_soc: fix misuse of mem alloc interface netdev[napi]_alloc_frag
	random: credit cpu and bootloader seeds by default
	pNFS: Don't keep retrying if the server replied NFS4ERR_LAYOUTUNAVAILABLE
	clocksource: hyper-v: unexport __init-annotated hv_init_clocksource()
	i40e: Fix adding ADQ filter to TC0
	i40e: Fix calculating the number of queue pairs
	i40e: Fix call trace in setup_tx_descriptors
	tty: goldfish: Fix free_irq() on remove
	misc: atmel-ssc: Fix IRQ check in ssc_probe
	mlxsw: spectrum_cnt: Reorder counter pools
	net: bgmac: Fix an erroneous kfree() in bgmac_remove()
	arm64: ftrace: fix branch range checks
	certs/blacklist_hashes.c: fix const confusion in certs blacklist
	faddr2line: Fix overlapping text section failures, the sequel
	irqchip/gic/realview: Fix refcount leak in realview_gic_of_init
	irqchip/gic-v3: Fix error handling in gic_populate_ppi_partitions
	irqchip/gic-v3: Fix refcount leak in gic_populate_ppi_partitions
	i2c: designware: Use standard optional ref clock implementation
	comedi: vmk80xx: fix expression for tx buffer size
	USB: serial: option: add support for Cinterion MV31 with new baseline
	USB: serial: io_ti: add Agilent E5805A support
	usb: dwc2: Fix memory leak in dwc2_hcd_init
	usb: gadget: lpc32xx_udc: Fix refcount leak in lpc32xx_udc_probe
	serial: 8250: Store to lsr_save_flags after lsr read
	dm mirror log: round up region bitmap size to BITS_PER_LONG
	ext4: fix bug_on ext4_mb_use_inode_pa
	ext4: make variable "count" signed
	ext4: add reserved GDT blocks check
	ALSA: hda/realtek: fix mute/micmute LEDs for HP 440 G8
	ALSA: hda/realtek: fix right sounds and mute/micmute LEDs for HP machine
	virtio-pci: Remove wrong address verification in vp_del_vqs()
	net/sched: act_police: more accurate MTU policing
	net: openvswitch: fix misuse of the cached connection on tuple changes
	net: openvswitch: fix leak of nested actions
	arm64: kprobes: Use BRK instead of single-step when executing instructions out-of-line
	RISC-V: fix barrier() use in <vdso/processor.h>
	riscv: Less inefficient gcc tishift helpers (and export their symbols)
	powerpc/mm: Switch obsolete dssall to .long
	Linux 5.4.200

Also includes in this merge resolution the following commits from 5.10.y
in order to handle merge issues with previous blake2s changes that are
in the Android tree:
	6048fdcc5f26 ("lib/crypto: blake2s: include as built-in")
	d2a02e3c8bb6 ("lib/crypto: blake2s: avoid indirect calls to compression function for Clang CFI")
	e56e18985596 ("lib/crypto: add prompts back to crypto libraries")

Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: Ie836943a404704937d2d6575f0f51e1d02d24e55
2022-06-23 15:04:40 +02:00
Zhang Yi
fba5428917 ext4: add reserved GDT blocks check
commit b55c3cd102a6f48b90e61c44f7f3dda8c290c694 upstream.

We capture a NULL pointer issue when resizing a corrupt ext4 image which
is freshly clear resize_inode feature (not run e2fsck). It could be
simply reproduced by following steps. The problem is because of the
resize_inode feature was cleared, and it will convert the filesystem to
meta_bg mode in ext4_resize_fs(), but the es->s_reserved_gdt_blocks was
not reduced to zero, so could we mistakenly call reserve_backup_gdb()
and passing an uninitialized resize_inode to it when adding new group
descriptors.

 mkfs.ext4 /dev/sda 3G
 tune2fs -O ^resize_inode /dev/sda #forget to run requested e2fsck
 mount /dev/sda /mnt
 resize2fs /dev/sda 8G

 ========
 BUG: kernel NULL pointer dereference, address: 0000000000000028
 CPU: 19 PID: 3243 Comm: resize2fs Not tainted 5.18.0-rc7-00001-gfde086c5ebfd #748
 ...
 RIP: 0010:ext4_flex_group_add+0xe08/0x2570
 ...
 Call Trace:
  <TASK>
  ext4_resize_fs+0xbec/0x1660
  __ext4_ioctl+0x1749/0x24e0
  ext4_ioctl+0x12/0x20
  __x64_sys_ioctl+0xa6/0x110
  do_syscall_64+0x3b/0x90
  entry_SYSCALL_64_after_hwframe+0x44/0xae
 RIP: 0033:0x7f2dd739617b
 ========

The fix is simple, add a check in ext4_resize_begin() to make sure that
the es->s_reserved_gdt_blocks is zero when the resize_inode feature is
disabled.

Cc: stable@kernel.org
Signed-off-by: Zhang Yi <yi.zhang@huawei.com>
Reviewed-by: Ritesh Harjani <ritesh.list@gmail.com>
Reviewed-by: Jan Kara <jack@suse.cz>
Link: https://lore.kernel.org/r/20220601092717.763694-1-yi.zhang@huawei.com
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2022-06-22 14:11:23 +02:00
Ding Xiang
4ca0d2f1e0 ext4: make variable "count" signed
commit bc75a6eb856cb1507fa907bf6c1eda91b3fef52f upstream.

Since dx_make_map() may return -EFSCORRUPTED now, so change "count" to
be a signed integer so we can correctly check for an error code returned
by dx_make_map().

Fixes: 46c116b920eb ("ext4: verify dir block before splitting it")
Cc: stable@kernel.org
Signed-off-by: Ding Xiang <dingxiang@cmss.chinamobile.com>
Link: https://lore.kernel.org/r/20220530100047.537598-1-dingxiang@cmss.chinamobile.com
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2022-06-22 14:11:23 +02:00
Baokun Li
a6b31616e5 ext4: fix bug_on ext4_mb_use_inode_pa
commit a08f789d2ab5242c07e716baf9a835725046be89 upstream.

Hulk Robot reported a BUG_ON:
==================================================================
kernel BUG at fs/ext4/mballoc.c:3211!
[...]
RIP: 0010:ext4_mb_mark_diskspace_used.cold+0x85/0x136f
[...]
Call Trace:
 ext4_mb_new_blocks+0x9df/0x5d30
 ext4_ext_map_blocks+0x1803/0x4d80
 ext4_map_blocks+0x3a4/0x1a10
 ext4_writepages+0x126d/0x2c30
 do_writepages+0x7f/0x1b0
 __filemap_fdatawrite_range+0x285/0x3b0
 file_write_and_wait_range+0xb1/0x140
 ext4_sync_file+0x1aa/0xca0
 vfs_fsync_range+0xfb/0x260
 do_fsync+0x48/0xa0
[...]
==================================================================

Above issue may happen as follows:
-------------------------------------
do_fsync
 vfs_fsync_range
  ext4_sync_file
   file_write_and_wait_range
    __filemap_fdatawrite_range
     do_writepages
      ext4_writepages
       mpage_map_and_submit_extent
        mpage_map_one_extent
         ext4_map_blocks
          ext4_mb_new_blocks
           ext4_mb_normalize_request
            >>> start + size <= ac->ac_o_ex.fe_logical
           ext4_mb_regular_allocator
            ext4_mb_simple_scan_group
             ext4_mb_use_best_found
              ext4_mb_new_preallocation
               ext4_mb_new_inode_pa
                ext4_mb_use_inode_pa
                 >>> set ac->ac_b_ex.fe_len <= 0
           ext4_mb_mark_diskspace_used
            >>> BUG_ON(ac->ac_b_ex.fe_len <= 0);

we can easily reproduce this problem with the following commands:
	`fallocate -l100M disk`
	`mkfs.ext4 -b 1024 -g 256 disk`
	`mount disk /mnt`
	`fsstress -d /mnt -l 0 -n 1000 -p 1`

The size must be smaller than or equal to EXT4_BLOCKS_PER_GROUP.
Therefore, "start + size <= ac->ac_o_ex.fe_logical" may occur
when the size is truncated. So start should be the start position of
the group where ac_o_ex.fe_logical is located after alignment.
In addition, when the value of fe_logical or EXT4_BLOCKS_PER_GROUP
is very large, the value calculated by start_off is more accurate.

Cc: stable@kernel.org
Fixes: cd648b8a8f ("ext4: trim allocation requests to group size")
Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Baokun Li <libaokun1@huawei.com>
Reviewed-by: Ritesh Harjani <ritesh.list@gmail.com>
Link: https://lore.kernel.org/r/20220528110017.354175-2-libaokun1@huawei.com
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2022-06-22 14:11:23 +02:00
Trond Myklebust
11c870c0b5 pNFS: Don't keep retrying if the server replied NFS4ERR_LAYOUTUNAVAILABLE
[ Upstream commit fe44fb23d6ccde4c914c44ef74ab8d9d9ba02bea ]

If the server tells us that a pNFS layout is not available for a
specific file, then we should not keep pounding it with further
layoutget requests.

Fixes: 183d9e7b11 ("pnfs: rework LAYOUTGET retry handling")
Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com>
Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2022-06-22 14:11:21 +02:00
Arnd Bergmann
927fc225af compat_ioctl: remove /dev/random commands
commit 507e4e2b430b6a27b66f4745564ecaee7967737f upstream.

These are all handled by the random driver, so instead of listing
each ioctl, we can use the generic compat_ptr_ioctl() helper.

Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2022-06-22 14:11:03 +02:00
Al Viro
f91da317e6 9p: missing chunk of "fs/9p: Don't update file type when updating file attributes"
commit b577d0cd2104fdfcf0ded3707540a12be8ddd8b0 upstream.

In commit 45089142b1 Aneesh had missed one (admittedly, very unlikely
to hit) case in v9fs_stat2inode_dotl().  However, the same considerations
apply there as well - we have no business whatsoever to change ->i_rdev
or the file type.

Cc: Tadeusz Struk <tadeusz.struk@linaro.org>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2022-06-22 14:11:02 +02:00
Greg Kroah-Hartman
cf729493b6 Revert "ext4: fix use-after-free in ext4_rename_dir_prepare"
This reverts commit eaecf7ebfd which is
commit 0be698ecbe4471fcad80e81ec6a05001421041b3 upstream as it breaks
the build in Android kernel builds due to out-of-tree changes that were
never merged upstream.

Bug: 236690716
Fixes: bc1a5b8c02ae ("Merge 4.14.283 into android-4.14-stable")
Cc: Daniel Rosenberg <drosen@google.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: I511f362fecb21bdc53fb3a93bb9772be96e7f985
2022-06-21 18:09:41 +02:00
Greg Kroah-Hartman
10f5759c4e Revert "ext4: verify dir block before splitting it"
This reverts commit 17034d45ec which is
commit 46c116b920ebec58031f0a78c5ea9599b0d2a371 upstream,  as it breaks
the build in Android kernel builds due to out-of-tree changes that were
never merged upstream.

Bug: 236690716
Fixes: bc1a5b8c02ae ("Merge 4.14.283 into android-4.14-stable")
Cc: Daniel Rosenberg <drosen@google.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: I08929715fb488a7d1977300e84d0940a9bf4dc98
2022-06-21 18:08:56 +02:00
Greg Kroah-Hartman
a778a36923 This is the 5.4.198 stable release
-----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCAAdFiEEZH8oZUiU471FcZm+ONu9yGCSaT4FAmKos2QACgkQONu9yGCS
 aT4QYQ//WQD/rHjO021lbo/z4eZbWUxjDiQNisJQY4MTCnIJgPYROJ6YLBLL2+of
 VwDdZ0yQNpf3hBA3qgTZ8RgaBinVf+WNAk37Ap/3VFXTExxgyGCx7p/PG+Jx9Jk4
 qd9YPHZCu8g9rQjJoex95fd8Fedu47tzBSd88MoAKiLz90JsNbYUZb+gqdRrLAYc
 6krd7zm7T8Grk31xUWOl/tlUSxveuUuz6QQr5mwPmSyspz4gQXsBlrKSrNSWmk0o
 qtqgqUCypvpKTF7RYiEoS3F8wy4XvWpGsET+W79SJ84inVx3EMsZKXB9GsWVZZgI
 fm3eFjn10NcgA+lvc7TJpwKg0f5g8uHW/06FcfYwgBhbI+otCFDLQkkHtViN0wY2
 gks3PLPsYJdAZTlwIvjNY0XY7wRqjS7Ta1pf+d1po1EndEFAyH76KJaIGCzdVKb4
 OeSEy4Xw8HxmuCO+mrUtRVRqV3Y7x88GuJC359iDKYdDpc+Z21FcvaVcgrR5cy2V
 A7ICKIfNyArgNmWnXQ6UBXqS1rDcoyfJe+0CYyRRdgDO/ON48Mx8FIW9YJrSrMeS
 XEx6cw6VKZ7hE1G71us/ITOOeUlHO93V7Ju+oOcx9Fgew8TZ0mdNMliOFUFaNWPb
 iAG+zZD0jwP5iyx0KFfOJyyuoovEtjBh9ZgVIF5BP3Ry1xRHuHY=
 =oE7B
 -----END PGP SIGNATURE-----

Merge 5.4.198 into android11-5.4-lts

Changes in 5.4.198
	binfmt_flat: do not stop relocating GOT entries prematurely on riscv
	ALSA: hda/realtek - Fix microphone noise on ASUS TUF B550M-PLUS
	USB: serial: option: add Quectel BG95 modem
	USB: new quirk for Dell Gen 2 devices
	usb: core: hcd: Add support for deferring roothub registration
	perf/x86/intel: Fix event constraints for ICL
	ptrace/um: Replace PT_DTRACE with TIF_SINGLESTEP
	ptrace/xtensa: Replace PT_SINGLESTEP with TIF_SINGLESTEP
	ptrace: Reimplement PTRACE_KILL by always sending SIGKILL
	btrfs: add "0x" prefix for unsupported optional features
	btrfs: repair super block num_devices automatically
	drm/virtio: fix NULL pointer dereference in virtio_gpu_conn_get_modes
	mwifiex: add mutex lock for call in mwifiex_dfs_chan_sw_work_queue
	b43legacy: Fix assigning negative value to unsigned variable
	b43: Fix assigning negative value to unsigned variable
	ipw2x00: Fix potential NULL dereference in libipw_xmit()
	ipv6: fix locking issues with loops over idev->addr_list
	fbcon: Consistently protect deferred_takeover with console_lock()
	ACPICA: Avoid cache flush inside virtual machines
	drm/komeda: return early if drm_universal_plane_init() fails.
	ALSA: jack: Access input_dev under mutex
	spi: spi-rspi: Remove setting {src,dst}_{addr,addr_width} based on DMA direction
	tools/power turbostat: fix ICX DRAM power numbers
	drm/amd/pm: fix double free in si_parse_power_table()
	ath9k: fix QCA9561 PA bias level
	media: venus: hfi: avoid null dereference in deinit
	media: pci: cx23885: Fix the error handling in cx23885_initdev()
	media: cx25821: Fix the warning when removing the module
	md/bitmap: don't set sb values if can't pass sanity check
	mmc: jz4740: Apply DMA engine limits to maximum segment size
	scsi: megaraid: Fix error check return value of register_chrdev()
	drm/plane: Move range check for format_count earlier
	drm/amd/pm: fix the compile warning
	arm64: compat: Do not treat syscall number as ESR_ELx for a bad syscall
	drm: msm: fix error check return value of irq_of_parse_and_map()
	ipv6: Don't send rs packets to the interface of ARPHRD_TUNNEL
	net/mlx5: fs, delete the FTE when there are no rules attached to it
	ASoC: dapm: Don't fold register value changes into notifications
	mlxsw: spectrum_dcb: Do not warn about priority changes
	drm/amdgpu/ucode: Remove firmware load type check in amdgpu_ucode_free_bo
	HID: bigben: fix slab-out-of-bounds Write in bigben_probe
	ASoC: tscs454: Add endianness flag in snd_soc_component_driver
	s390/preempt: disable __preempt_count_add() optimization for PROFILE_ALL_BRANCHES
	spi: stm32-qspi: Fix wait_cmd timeout in APM mode
	dma-debug: change allocation mode from GFP_NOWAIT to GFP_ATIOMIC
	ACPI: PM: Block ASUS B1400CEAE from suspend to idle by default
	ipmi:ssif: Check for NULL msg when handling events and messages
	ipmi: Fix pr_fmt to avoid compilation issues
	rtlwifi: Use pr_warn instead of WARN_ONCE
	media: coda: limit frame interval enumeration to supported encoder frame sizes
	media: cec-adap.c: fix is_configuring state
	openrisc: start CPU timer early in boot
	nvme-pci: fix a NULL pointer dereference in nvme_alloc_admin_tags
	ASoC: rt5645: Fix errorenous cleanup order
	nbd: Fix hung on disconnect request if socket is closed before
	net: phy: micrel: Allow probing without .driver_data
	media: exynos4-is: Fix compile warning
	ASoC: max98357a: remove dependency on GPIOLIB
	hwmon: Make chip parameter for with_info API mandatory
	rxrpc: Return an error to sendmsg if call failed
	eth: tg3: silence the GCC 12 array-bounds warning
	selftests/bpf: fix btf_dump/btf_dump due to recent clang change
	IB/rdmavt: add missing locks in rvt_ruc_loopback
	ARM: dts: ox820: align interrupt controller node name with dtschema
	PM / devfreq: rk3399_dmc: Disable edev on remove()
	fs: jfs: fix possible NULL pointer dereference in dbFree()
	ARM: OMAP1: clock: Fix UART rate reporting algorithm
	powerpc/fadump: Fix fadump to work with a different endian capture kernel
	fat: add ratelimit to fat*_ent_bread()
	ARM: versatile: Add missing of_node_put in dcscb_init
	ARM: dts: exynos: add atmel,24c128 fallback to Samsung EEPROM
	ARM: hisi: Add missing of_node_put after of_find_compatible_node
	PCI: Avoid pci_dev_lock() AB/BA deadlock with sriov_numvfs_store()
	tracing: incorrect isolate_mote_t cast in mm_vmscan_lru_isolate
	powerpc/xics: fix refcount leak in icp_opal_init()
	powerpc/powernv: fix missing of_node_put in uv_init()
	macintosh/via-pmu: Fix build failure when CONFIG_INPUT is disabled
	powerpc/iommu: Add missing of_node_put in iommu_init_early_dart
	RDMA/hfi1: Prevent panic when SDMA is disabled
	drm: fix EDID struct for old ARM OABI format
	ath9k: fix ar9003_get_eepmisc
	drm/edid: fix invalid EDID extension block filtering
	drm/bridge: adv7511: clean up CEC adapter when probe fails
	ASoC: mediatek: Fix error handling in mt8173_max98090_dev_probe
	ASoC: mediatek: Fix missing of_node_put in mt2701_wm8960_machine_probe
	x86/delay: Fix the wrong asm constraint in delay_loop()
	drm/mediatek: Fix mtk_cec_mask()
	drm/vc4: txp: Don't set TXP_VSTART_AT_EOF
	drm/vc4: txp: Force alpha to be 0xff if it's disabled
	bpf: Fix excessive memory allocation in stack_map_alloc()
	nl80211: show SSID for P2P_GO interfaces
	drm/komeda: Fix an undefined behavior bug in komeda_plane_add()
	drm: mali-dp: potential dereference of null pointer
	spi: spi-ti-qspi: Fix return value handling of wait_for_completion_timeout
	NFC: NULL out the dev->rfkill to prevent UAF
	efi: Add missing prototype for efi_capsule_setup_info
	drbd: fix duplicate array initializer
	HID: hid-led: fix maximum brightness for Dream Cheeky
	HID: elan: Fix potential double free in elan_input_configured
	drm/bridge: Fix error handling in analogix_dp_probe
	sched/fair: Fix cfs_rq_clock_pelt() for throttled cfs_rq
	spi: img-spfi: Fix pm_runtime_get_sync() error checking
	cpufreq: Fix possible race in cpufreq online error path
	ath9k_htc: fix potential out of bounds access with invalid rxstatus->rs_keyix
	inotify: show inotify mask flags in proc fdinfo
	fsnotify: fix wrong lockdep annotations
	of: overlay: do not break notify on NOTIFY_{OK|STOP}
	scsi: ufs: core: Exclude UECxx from SFR dump list
	x86/pm: Fix false positive kmemleak report in msr_build_context()
	x86/speculation: Add missing prototype for unpriv_ebpf_notify()
	ASoC: rk3328: fix disabling mclk on pclk probe failure
	perf tools: Add missing headers needed by util/data.h
	drm/msm/disp/dpu1: set vbif hw config to NULL to avoid use after memory free during pm runtime resume
	drm/msm/dsi: fix error checks and return values for DSI xmit functions
	drm/msm/hdmi: check return value after calling platform_get_resource_byname()
	drm/msm/hdmi: fix error check return value of irq_of_parse_and_map()
	drm/rockchip: vop: fix possible null-ptr-deref in vop_bind()
	virtio_blk: fix the discard_granularity and discard_alignment queue limits
	x86: Fix return value of __setup handlers
	irqchip/exiu: Fix acknowledgment of edge triggered interrupts
	irqchip/aspeed-i2c-ic: Fix irq_of_parse_and_map() return value
	x86/mm: Cleanup the control_va_addr_alignment() __setup handler
	regulator: core: Fix enable_count imbalance with EXCLUSIVE_GET
	drm/msm/mdp5: Return error code in mdp5_pipe_release when deadlock is detected
	drm/msm/mdp5: Return error code in mdp5_mixer_release when deadlock is detected
	drm/msm: return an error pointer in msm_gem_prime_get_sg_table()
	media: uvcvideo: Fix missing check to determine if element is found in list
	iomap: iomap_write_failed fix
	Revert "cpufreq: Fix possible race in cpufreq online error path"
	perf/amd/ibs: Use interrupt regs ip for stack unwinding
	ASoC: fsl: Fix refcount leak in imx_sgtl5000_probe
	ASoC: mxs-saif: Fix refcount leak in mxs_saif_probe
	regulator: pfuze100: Fix refcount leak in pfuze_parse_regulators_dt
	scripts/faddr2line: Fix overlapping text section failures
	media: aspeed: Fix an error handling path in aspeed_video_probe()
	media: st-delta: Fix PM disable depth imbalance in delta_probe
	media: exynos4-is: Change clk_disable to clk_disable_unprepare
	media: pvrusb2: fix array-index-out-of-bounds in pvr2_i2c_core_init
	media: vsp1: Fix offset calculation for plane cropping
	Bluetooth: fix dangling sco_conn and use-after-free in sco_sock_timeout
	m68k: math-emu: Fix dependencies of math emulation support
	sctp: read sk->sk_bound_dev_if once in sctp_rcv()
	media: ov7670: remove ov7670_power_off from ov7670_remove
	ext4: reject the 'commit' option on ext2 filesystems
	drm/msm/a6xx: Fix refcount leak in a6xx_gpu_init
	drm: msm: fix possible memory leak in mdp5_crtc_cursor_set()
	thermal/drivers/broadcom: Fix potential NULL dereference in sr_thermal_probe
	ASoC: wm2000: fix missing clk_disable_unprepare() on error in wm2000_anc_transition()
	NFC: hci: fix sleep in atomic context bugs in nfc_hci_hcp_message_tx
	rxrpc: Fix listen() setting the bar too high for the prealloc rings
	rxrpc: Don't try to resend the request if we're receiving the reply
	rxrpc: Fix overlapping ACK accounting
	rxrpc: Don't let ack.previousPacket regress
	rxrpc: Fix decision on when to generate an IDLE ACK
	net/smc: postpone sk_refcnt increment in connect()
	arm64: dts: rockchip: Move drive-impedance-ohm to emmc phy on rk3399
	ARM: dts: suniv: F1C100: fix watchdog compatible
	soc: qcom: smp2p: Fix missing of_node_put() in smp2p_parse_ipc
	soc: qcom: smsm: Fix missing of_node_put() in smsm_parse_ipc
	PCI: cadence: Fix find_first_zero_bit() limit
	PCI: rockchip: Fix find_first_zero_bit() limit
	KVM: nVMX: Leave most VM-Exit info fields unmodified on failed VM-Entry
	can: xilinx_can: mark bit timing constants as const
	ARM: dts: bcm2835-rpi-zero-w: Fix GPIO line name for Wifi/BT
	ARM: dts: bcm2837-rpi-cm3-io3: Fix GPIO line names for SMPS I2C
	ARM: dts: bcm2837-rpi-3-b-plus: Fix GPIO line name of power LED
	ARM: dts: bcm2835-rpi-b: Fix GPIO line names
	misc: ocxl: fix possible double free in ocxl_file_register_afu
	crypto: marvell/cesa - ECB does not IV
	arm: mediatek: select arch timer for mt7629
	powerpc/fadump: fix PT_LOAD segment for boot memory area
	mfd: ipaq-micro: Fix error check return value of platform_get_irq()
	scsi: fcoe: Fix Wstringop-overflow warnings in fcoe_wwn_from_mac()
	firmware: arm_scmi: Fix list protocols enumeration in the base protocol
	nvdimm: Allow overwrite in the presence of disabled dimms
	pinctrl: mvebu: Fix irq_of_parse_and_map() return value
	drivers/base/node.c: fix compaction sysfs file leak
	dax: fix cache flush on PMD-mapped pages
	powerpc/8xx: export 'cpm_setbrg' for modules
	powerpc/idle: Fix return value of __setup() handler
	powerpc/4xx/cpm: Fix return value of __setup() handler
	proc: fix dentry/inode overinstantiating under /proc/${pid}/net
	ipc/mqueue: use get_tree_nodev() in mqueue_get_tree()
	PCI: imx6: Fix PERST# start-up sequence
	tty: fix deadlock caused by calling printk() under tty_port->lock
	crypto: cryptd - Protect per-CPU resource by disabling BH.
	Input: sparcspkr - fix refcount leak in bbc_beep_probe
	powerpc/64: Only WARN if __pa()/__va() called with bad addresses
	powerpc/perf: Fix the threshold compare group constraint for power9
	macintosh: via-pmu and via-cuda need RTC_LIB
	powerpc/fsl_rio: Fix refcount leak in fsl_rio_setup
	mfd: davinci_voicecodec: Fix possible null-ptr-deref davinci_vc_probe()
	mailbox: forward the hrtimer if not queued and under a lock
	RDMA/hfi1: Prevent use of lock before it is initialized
	Input: stmfts - do not leave device disabled in stmfts_input_open
	f2fs: fix dereference of stale list iterator after loop body
	iommu/mediatek: Add list_del in mtk_iommu_remove
	i2c: at91: use dma safe buffers
	i2c: at91: Initialize dma_buf in at91_twi_xfer()
	NFS: Do not report EINTR/ERESTARTSYS as mapping errors
	NFS: Do not report flush errors in nfs_write_end()
	NFS: Don't report errors from nfs_pageio_complete() more than once
	NFSv4/pNFS: Do not fail I/O when we fail to allocate the pNFS layout
	video: fbdev: clcdfb: Fix refcount leak in clcdfb_of_vram_setup
	dmaengine: stm32-mdma: remove GISR1 register
	iommu/amd: Increase timeout waiting for GA log enablement
	perf c2c: Use stdio interface if slang is not supported
	perf jevents: Fix event syntax error caused by ExtSel
	f2fs: fix to avoid f2fs_bug_on() in dec_valid_node_count()
	f2fs: fix to do sanity check on block address in f2fs_do_zero_range()
	f2fs: fix to clear dirty inode in f2fs_evict_inode()
	f2fs: fix deadloop in foreground GC
	f2fs: don't need inode lock for system hidden quota
	f2fs: fix fallocate to use file_modified to update permissions consistently
	wifi: mac80211: fix use-after-free in chanctx code
	iwlwifi: mvm: fix assert 1F04 upon reconfig
	fs-writeback: writeback_sb_inodes:Recalculate 'wrote' according skipped pages
	efi: Do not import certificates from UEFI Secure Boot for T2 Macs
	bfq: Split shared queues on move between cgroups
	bfq: Update cgroup information before merging bio
	bfq: Track whether bfq_group is still online
	netfilter: nf_tables: disallow non-stateful expression in sets earlier
	ext4: fix use-after-free in ext4_rename_dir_prepare
	ext4: fix warning in ext4_handle_inode_extension
	ext4: fix bug_on in ext4_writepages
	ext4: verify dir block before splitting it
	ext4: avoid cycles in directory h-tree
	ACPI: property: Release subnode properties with data nodes
	tracing: Fix potential double free in create_var_ref()
	PCI/PM: Fix bridge_d3_blacklist[] Elo i2 overwrite of Gigabyte X299
	PCI: qcom: Fix runtime PM imbalance on probe errors
	PCI: qcom: Fix unbalanced PHY init on probe errors
	mm, compaction: fast_find_migrateblock() should return pfn in the target zone
	dlm: fix plock invalid read
	dlm: fix missing lkb refcount handling
	ocfs2: dlmfs: fix error handling of user_dlm_destroy_lock
	scsi: dc395x: Fix a missing check on list iterator
	scsi: ufs: qcom: Add a readl() to make sure ref_clk gets enabled
	drm/amdgpu/cs: make commands with 0 chunks illegal behaviour.
	drm/etnaviv: check for reaped mapping in etnaviv_iommu_unmap_gem
	drm/nouveau/clk: Fix an incorrect NULL check on list iterator
	drm/bridge: analogix_dp: Grab runtime PM reference for DP-AUX
	md: fix an incorrect NULL check in does_sb_need_changing
	md: fix an incorrect NULL check in md_reload_sb
	mtd: cfi_cmdset_0002: Move and rename chip_check/chip_ready/chip_good_for_write
	media: coda: Fix reported H264 profile
	media: coda: Add more H264 levels for CODA960
	Kconfig: Add option for asm goto w/ tied outputs to workaround clang-13 bug
	RDMA/hfi1: Fix potential integer multiplication overflow errors
	irqchip/armada-370-xp: Do not touch Performance Counter Overflow on A375, A38x, A39x
	irqchip: irq-xtensa-mx: fix initial IRQ affinity
	mac80211: upgrade passive scan to active scan on DFS channels after beacon rx
	um: chan_user: Fix winch_tramp() return value
	um: Fix out-of-bounds read in LDT setup
	iommu/msm: Fix an incorrect NULL check on list iterator
	nodemask.h: fix compilation error with GCC12
	hugetlb: fix huge_pmd_unshare address update
	rtl818x: Prevent using not initialized queues
	ASoC: rt5514: Fix event generation for "DSP Voice Wake Up" control
	carl9170: tx: fix an incorrect use of list iterator
	serial: pch: don't overwrite xmit->buf[0] by x_char
	tilcdc: tilcdc_external: fix an incorrect NULL check on list iterator
	gma500: fix an incorrect NULL check on list iterator
	arm64: dts: qcom: ipq8074: fix the sleep clock frequency
	phy: qcom-qmp: fix struct clk leak on probe errors
	ARM: pxa: maybe fix gpio lookup tables
	docs/conf.py: Cope with removal of language=None in Sphinx 5.0.0
	dt-bindings: gpio: altera: correct interrupt-cells
	blk-iolatency: Fix inflight count imbalances and IO hangs on offline
	phy: qcom-qmp: fix reset-controller leak on probe errors
	Kconfig: add config option for asm goto w/ outputs
	RDMA/rxe: Generate a completion for unsupported/invalid opcode
	MIPS: IP27: Remove incorrect `cpu_has_fpu' override
	bfq: Avoid merging queues with different parents
	bfq: Drop pointless unlock-lock pair
	bfq: Remove pointless bfq_init_rq() calls
	bfq: Get rid of __bio_blkcg() usage
	bfq: Make sure bfqg for which we are queueing requests is online
	block: fix bio_clone_blkg_association() to associate with proper blkcg_gq
	md: bcache: check the return value of kzalloc() in detached_dev_do_request()
	pcmcia: db1xxx_ss: restrict to MIPS_DB1XXX boards
	staging: greybus: codecs: fix type confusion of list iterator variable
	iio: adc: ad7124: Remove shift from scan_type
	tty: goldfish: Use tty_port_destroy() to destroy port
	tty: serial: owl: Fix missing clk_disable_unprepare() in owl_uart_probe
	tty: serial: fsl_lpuart: fix potential bug when using both of_alias_get_id and ida_simple_get
	usb: usbip: fix a refcount leak in stub_probe()
	usb: usbip: add missing device lock on tweak configuration cmd
	USB: storage: karma: fix rio_karma_init return
	usb: musb: Fix missing of_node_put() in omap2430_probe
	staging: fieldbus: Fix the error handling path in anybuss_host_common_probe()
	pwm: lp3943: Fix duty calculation in case period was clamped
	rpmsg: qcom_smd: Fix irq_of_parse_and_map() return value
	usb: dwc3: pci: Fix pm_runtime_get_sync() error checking
	firmware: stratix10-svc: fix a missing check on list iterator
	iio: adc: stmpe-adc: Fix wait_for_completion_timeout return value check
	iio: adc: sc27xx: fix read big scale voltage not right
	iio: adc: sc27xx: Fine tune the scale calibration values
	rpmsg: qcom_smd: Fix returning 0 if irq_of_parse_and_map() fails
	phy: qcom-qmp: fix pipe-clock imbalance on power-on failure
	serial: sifive: Report actual baud base rather than fixed 115200
	coresight: cpu-debug: Replace mutex with mutex_trylock on panic notifier
	soc: rockchip: Fix refcount leak in rockchip_grf_init
	clocksource/drivers/riscv: Events are stopped during CPU suspend
	rtc: mt6397: check return value after calling platform_get_resource()
	serial: meson: acquire port->lock in startup()
	serial: 8250_fintek: Check SER_RS485_RTS_* only with RS485
	serial: digicolor-usart: Don't allow CS5-6
	serial: rda-uart: Don't allow CS5-6
	serial: txx9: Don't allow CS5-6
	serial: sh-sci: Don't allow CS5-6
	serial: sifive: Sanitize CSIZE and c_iflag
	serial: st-asc: Sanitize CSIZE and correct PARENB for CS7
	serial: stm32-usart: Correct CSIZE, bits, and parity
	firmware: dmi-sysfs: Fix memory leak in dmi_sysfs_register_handle
	bus: ti-sysc: Fix warnings for unbind for serial
	driver: base: fix UAF when driver_attach failed
	driver core: fix deadlock in __device_attach
	watchdog: ts4800_wdt: Fix refcount leak in ts4800_wdt_probe
	ASoC: fsl_sai: Fix FSL_SAI_xDR/xFR definition
	clocksource/drivers/oxnas-rps: Fix irq_of_parse_and_map() return value
	s390/crypto: fix scatterwalk_unmap() callers in AES-GCM
	net: sched: fixed barrier to prevent skbuff sticking in qdisc backlog
	net: ethernet: mtk_eth_soc: out of bounds read in mtk_hwlro_get_fdir_entry()
	net: dsa: mv88e6xxx: Fix refcount leak in mv88e6xxx_mdios_register
	modpost: fix removing numeric suffixes
	jffs2: fix memory leak in jffs2_do_fill_super
	ubi: ubi_create_volume: Fix use-after-free when volume creation failed
	nfp: only report pause frame configuration for physical device
	net/mlx5: Don't use already freed action pointer
	net/mlx5e: Update netdev features after changing XDP state
	net: sched: add barrier to fix packet stuck problem for lockless qdisc
	tcp: tcp_rtx_synack() can be called from process context
	afs: Fix infinite loop found by xfstest generic/676
	tipc: check attribute length for bearer name
	perf c2c: Fix sorting in percent_rmt_hitm_cmp()
	mips: cpc: Fix refcount leak in mips_cpc_default_phys_base
	tracing: Fix sleeping function called from invalid context on RT kernel
	tracing: Avoid adding tracer option before update_tracer_options
	f2fs: remove WARN_ON in f2fs_is_valid_blkaddr
	i2c: cadence: Increase timeout per message if necessary
	m68knommu: set ZERO_PAGE() to the allocated zeroed page
	m68knommu: fix undefined reference to `_init_sp'
	dmaengine: zynqmp_dma: In struct zynqmp_dma_chan fix desc_size data type
	NFSv4: Don't hold the layoutget locks across multiple RPC calls
	video: fbdev: pxa3xx-gcu: release the resources correctly in pxa3xx_gcu_probe/remove()
	xprtrdma: treat all calls not a bcall when bc_serv is NULL
	netfilter: nat: really support inet nat without l3 address
	ata: pata_octeon_cf: Fix refcount leak in octeon_cf_probe
	netfilter: nf_tables: memleak flow rule from commit path
	xen: unexport __init-annotated xen_xlate_map_ballooned_pages()
	af_unix: Fix a data-race in unix_dgram_peer_wake_me().
	bpf, arm64: Clear prog->jited_len along prog->jited
	net: dsa: lantiq_gswip: Fix refcount leak in gswip_gphy_fw_list
	net/mlx4_en: Fix wrong return value on ioctl EEPROM query failure
	SUNRPC: Fix the calculation of xdr->end in xdr_get_next_encode_buffer()
	net: mdio: unexport __init-annotated mdio_bus_init()
	net: xfrm: unexport __init-annotated xfrm4_protocol_init()
	net: ipv6: unexport __init-annotated seg6_hmac_init()
	net/mlx5: Rearm the FW tracer after each tracer event
	net/mlx5: fs, fail conflicting actions
	ip_gre: test csum_start instead of transport header
	net: altera: Fix refcount leak in altera_tse_mdio_create
	drm: imx: fix compiler warning with gcc-12
	iio: dummy: iio_simple_dummy: check the return value of kstrdup()
	iio: st_sensors: Add a local lock for protecting odr
	lkdtm/usercopy: Expand size of "out of frame" object
	tty: synclink_gt: Fix null-pointer-dereference in slgt_clean()
	tty: Fix a possible resource leak in icom_probe
	drivers: staging: rtl8192u: Fix deadlock in ieee80211_beacons_stop()
	drivers: staging: rtl8192e: Fix deadlock in rtllib_beacons_stop()
	USB: host: isp116x: check return value after calling platform_get_resource()
	drivers: tty: serial: Fix deadlock in sa1100_set_termios()
	drivers: usb: host: Fix deadlock in oxu_bus_suspend()
	USB: hcd-pci: Fully suspend across freeze/thaw cycle
	usb: dwc2: gadget: don't reset gadget's driver->bus
	misc: rtsx: set NULL intfdata when probe fails
	extcon: Modify extcon device to be created after driver data is set
	clocksource/drivers/sp804: Avoid error on multiple instances
	staging: rtl8712: fix uninit-value in usb_read8() and friends
	staging: rtl8712: fix uninit-value in r871xu_drv_init()
	serial: msm_serial: disable interrupts in __msm_console_write()
	kernfs: Separate kernfs_pr_cont_buf and rename_lock.
	watchdog: wdat_wdt: Stop watchdog when rebooting the system
	md: protect md_unregister_thread from reentrancy
	scsi: myrb: Fix up null pointer access on myrb_cleanup()
	Revert "net: af_key: add check for pfkey_broadcast in function pfkey_process"
	ceph: allow ceph.dir.rctime xattr to be updatable
	drm/radeon: fix a possible null pointer dereference
	modpost: fix undefined behavior of is_arm_mapping_symbol()
	x86/cpu: Elide KCSAN for cpu_has() and friends
	nbd: call genl_unregister_family() first in nbd_cleanup()
	nbd: fix race between nbd_alloc_config() and module removal
	nbd: fix io hung while disconnecting device
	s390/gmap: voluntarily schedule during key setting
	cifs: version operations for smb20 unneeded when legacy support disabled
	nodemask: Fix return values to be unsigned
	vringh: Fix loop descriptors check in the indirect cases
	scripts/gdb: change kernel config dumping method
	ALSA: hda/conexant - Fix loopback issue with CX20632
	cifs: return errors during session setup during reconnects
	ata: libata-transport: fix {dma|pio|xfer}_mode sysfs files
	mmc: block: Fix CQE recovery reset success
	nfc: st21nfca: fix incorrect validating logic in EVT_TRANSACTION
	nfc: st21nfca: fix memory leaks in EVT_TRANSACTION handling
	ixgbe: fix bcast packets Rx on VF after promisc removal
	ixgbe: fix unexpected VLAN Rx in promisc mode on VF
	Input: bcm5974 - set missing URB_NO_TRANSFER_DMA_MAP urb flag
	powerpc/32: Fix overread/overwrite of thread_struct via ptrace
	md/raid0: Ignore RAID0 layout if the second zone has only one device
	mtd: cfi_cmdset_0002: Use chip_ready() for write on S29GL064N
	tcp: fix tcp_mtup_probe_success vs wrong snd_cwnd
	Linux 5.4.198

Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: I05615e33dbd0029f93c9724c9abc9cb9035122d2
2022-06-21 14:58:56 +02:00
Shyam Prasad N
b651f70ed3 cifs: return errors during session setup during reconnects
commit 8ea21823aa584b55ba4b861307093b78054b0c1b upstream.

During reconnects, we check the return value from
cifs_negotiate_protocol, and have handlers for both success
and failures. But if that passes, and cifs_setup_session
returns any errors other than -EACCES, we do not handle
that. This fix adds a handler for that, so that we don't
go ahead and try a tree_connect on a failed session.

Signed-off-by: Shyam Prasad N <sprasad@microsoft.com>
Reviewed-by: Enzo Matsumiya <ematsumiya@suse.de>
Cc: stable@vger.kernel.org
Signed-off-by: Steve French <stfrench@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2022-06-14 18:12:02 +02:00
Steve French
9b306339a5 cifs: version operations for smb20 unneeded when legacy support disabled
[ Upstream commit 7ef93ffccd55fb0ba000ed16ef6a81cd7dee07b5 ]

We should not be including unused smb20 specific code when legacy
support is disabled (CONFIG_CIFS_ALLOW_INSECURE_LEGACY turned
off).  For example smb2_operations and smb2_values aren't used
in that case.  Over time we can move more and more SMB1/CIFS and SMB2.0
code into the insecure legacy ifdefs

Reviewed-by: Ronnie Sahlberg <lsahlber@redhat.com>
Signed-off-by: Steve French <stfrench@microsoft.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2022-06-14 18:12:01 +02:00
Venky Shankar
9223144fdd ceph: allow ceph.dir.rctime xattr to be updatable
[ Upstream commit d7a2dc523085f8b8c60548ceedc696934aefeb0e ]

`rctime' has been a pain point in cephfs due to its buggy
nature - inconsistent values reported and those sorts.
Fixing rctime is non-trivial needing an overall redesign
of the entire nested statistics infrastructure.

As a workaround, PR

     http://github.com/ceph/ceph/pull/37938

allows this extended attribute to be manually set. This allows
users to "fixup" inconsistent rctime values. While this sounds
messy, its probably the wisest approach allowing users/scripts
to workaround buggy rctime values.

The above PR enables Ceph MDS to allow manually setting
rctime extended attribute with the corresponding user-land
changes. We may as well allow the same to be done via kclient
for parity.

Signed-off-by: Venky Shankar <vshankar@redhat.com>
Reviewed-by: Xiubo Li <xiubli@redhat.com>
Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2022-06-14 18:12:01 +02:00