Commit Graph

5601 Commits

Author SHA1 Message Date
Greg Kroah-Hartman
c515597aec Merge 02874ca52d ("tracing: Consider the NULL character when validating the event length") into android12-5.10-lts
Steps on the way to 5.10.229

Resolves conflicts in:
	drivers/net/macsec.c

Change-Id: Ibc2583ddd810808fa9ce619e71935aeb5f97805a
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
2024-11-21 22:24:39 +00:00
Greg Kroah-Hartman
012423e6bd Merge 5.10.228 into android12-5.10-lts
Changes in 5.10.228
	ALSA: hda/conexant - Fix audio routing for HP EliteOne 1000 G2
	net: enetc: add missing static descriptor and inline keyword
	posix-clock: Fix missing timespec64 check in pc_clock_settime()
	arm64: probes: Remove broken LDR (literal) uprobe support
	arm64: probes: Fix simulate_ldr*_literal()
	net: macb: Avoid 20s boot delay by skipping MDIO bus registration for fixed-link PHY
	irqchip/gic-v3-its: Fix VSYNC referencing an unmapped VPE on GIC v4.1
	fat: fix uninitialized variable
	mm/swapfile: skip HugeTLB pages for unuse_vma
	wifi: mac80211: fix potential key use-after-free
	KVM: Fix a data race on last_boosted_vcpu in kvm_vcpu_on_spin()
	io_uring/sqpoll: do not allow pinning outside of cpuset
	io_uring/sqpoll: retain test for whether the CPU is valid
	io_uring/sqpoll: do not put cpumask on stack
	s390/sclp_vt220: Convert newlines to CRLF instead of LFCR
	KVM: s390: Change virtual to physical address access in diag 0x258 handler
	x86/cpufeatures: Define X86_FEATURE_AMD_IBPB_RET
	x86/cpufeatures: Add a IBPB_NO_RET BUG flag
	x86/entry: Have entry_ibpb() invalidate return predictions
	x86/bugs: Skip RSB fill at VMEXIT
	x86/bugs: Do not use UNTRAIN_RET with IBPB on entry
	blk-rq-qos: fix crash on rq_qos_wait vs. rq_qos_wake_function race
	io_uring/sqpoll: close race on waiting for sqring entries
	drm/radeon: Fix encoder->possible_clones
	drm/vmwgfx: Handle surface check failure correctly
	iio: dac: ad5770r: add missing select REGMAP_SPI in Kconfig
	iio: dac: ltc1660: add missing select REGMAP_SPI in Kconfig
	iio: dac: stm32-dac-core: add missing select REGMAP_MMIO in Kconfig
	iio: adc: ti-ads8688: add missing select IIO_(TRIGGERED_)BUFFER in Kconfig
	iio: hid-sensors: Fix an error handling path in _hid_sensor_set_report_latency()
	iio: light: veml6030: fix ALS sensor resolution
	iio: light: veml6030: fix IIO device retrieval from embedded device
	iio: light: opt3001: add missing full-scale range value
	iio: proximity: mb1232: add missing select IIO_(TRIGGERED_)BUFFER in Kconfig
	iio: adc: ti-ads124s08: add missing select IIO_(TRIGGERED_)BUFFER in Kconfig
	Bluetooth: Remove debugfs directory on module init failure
	Bluetooth: btusb: Fix regression with fake CSR controllers 0a12:0001
	xhci: Fix incorrect stream context type macro
	USB: serial: option: add support for Quectel EG916Q-GL
	USB: serial: option: add Telit FN920C04 MBIM compositions
	parport: Proper fix for array out-of-bounds access
	x86/resctrl: Annotate get_mem_config() functions as __init
	x86/apic: Always explicitly disarm TSC-deadline timer
	x86/entry_32: Do not clobber user EFLAGS.ZF
	x86/entry_32: Clear CPU buffers after register restore in NMI return
	irqchip/gic-v4: Don't allow a VMOVP on a dying VPE
	mptcp: track and update contiguous data status
	mptcp: handle consistently DSS corruption
	tcp: fix mptcp DSS corruption due to large pmtu xmit
	nilfs2: propagate directory read errors from nilfs_find_entry()
	powerpc/mm: Always update max/min_low_pfn in mem_topology_setup()
	ALSA: hda/conexant - Use cached pin control for Node 0x1d on HP EliteOne 1000 G2
	Linux 5.10.228

Change-Id: I46a08618e1091915449af89690af27a230a28855
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
2024-11-17 20:12:50 +00:00
Greg Kroah-Hartman
b48eba851f Merge 1ebfa66638 ("drm/amd/display: Add null check for top_pipe_to_program in commit_planes_for_stream") into android12-5.10-lts
Steps on the way to 5.10.227

Change-Id: I5e69192f2ecbbda523c18c2749bb1f181837e99c
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
2024-11-14 11:32:05 +00:00
Greg Kroah-Hartman
9e57ad4546 Merge 0ce9d89343 ("clk: ti: dra7-atl: Fix leak of of_nodes") into android12-5.10-lts
Steps on the way to 5.10.226

Resolves merge conflicts in:
	drivers/dma-buf/heaps/heap-helpers.c
	drivers/usb/dwc3/core.h
	fs/ext4/inline.c

Change-Id: Id7ab496884e549fc85b6fff8254fb56d6785d78c
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
2024-11-12 17:29:46 +00:00
Yu Kuai
20e27c7739 block, bfq: fix procress reference leakage for bfqq in merge chain
[ Upstream commit 73aeab373557fa6ee4ae0b742c6211ccd9859280 ]

Original state:

        Process 1       Process 2       Process 3       Process 4
         (BIC1)          (BIC2)          (BIC3)          (BIC4)
          Λ                |               |               |
           \--------------\ \-------------\ \-------------\|
                           V               V               V
          bfqq1--------->bfqq2---------->bfqq3----------->bfqq4
    ref    0               1               2               4

After commit 0e456dba86c7 ("block, bfq: choose the last bfqq from merge
chain in bfq_setup_cooperator()"), if P1 issues a new IO:

Without the patch:

        Process 1       Process 2       Process 3       Process 4
         (BIC1)          (BIC2)          (BIC3)          (BIC4)
          Λ                |               |               |
           \------------------------------\ \-------------\|
                                           V               V
          bfqq1--------->bfqq2---------->bfqq3----------->bfqq4
    ref    0               0               2               4

bfqq3 will be used to handle IO from P1, this is not expected, IO
should be redirected to bfqq4;

With the patch:

          -------------------------------------------
          |                                         |
        Process 1       Process 2       Process 3   |   Process 4
         (BIC1)          (BIC2)          (BIC3)     |    (BIC4)
                           |               |        |      |
                            \-------------\ \-------------\|
                                           V               V
          bfqq1--------->bfqq2---------->bfqq3----------->bfqq4
    ref    0               0               2               4

IO is redirected to bfqq4, however, procress reference of bfqq3 is still
2, while there is only P2 using it.

Fix the problem by calling bfq_merge_bfqqs() for each bfqq in the merge
chain. Also change bfqq_merge_bfqqs() to return new_bfqq to simplify
code.

Fixes: 0e456dba86c7 ("block, bfq: choose the last bfqq from merge chain in bfq_setup_cooperator()")
Signed-off-by: Yu Kuai <yukuai3@huawei.com>
Link: https://lore.kernel.org/r/20240909134154.954924-3-yukuai1@huaweicloud.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-11-08 16:21:58 +01:00
Omar Sandoval
3bc6d0f8b7 blk-rq-qos: fix crash on rq_qos_wait vs. rq_qos_wake_function race
commit e972b08b91ef48488bae9789f03cfedb148667fb upstream.

We're seeing crashes from rq_qos_wake_function that look like this:

  BUG: unable to handle page fault for address: ffffafe180a40084
  #PF: supervisor write access in kernel mode
  #PF: error_code(0x0002) - not-present page
  PGD 100000067 P4D 100000067 PUD 10027c067 PMD 10115d067 PTE 0
  Oops: Oops: 0002 [#1] PREEMPT SMP PTI
  CPU: 17 UID: 0 PID: 0 Comm: swapper/17 Not tainted 6.12.0-rc3-00013-geca631b8fe80 #11
  Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS rel-1.16.0-0-gd239552ce722-prebuilt.qemu.org 04/01/2014
  RIP: 0010:_raw_spin_lock_irqsave+0x1d/0x40
  Code: 90 90 90 90 90 90 90 90 90 90 90 90 90 f3 0f 1e fa 0f 1f 44 00 00 41 54 9c 41 5c fa 65 ff 05 62 97 30 4c 31 c0 ba 01 00 00 00 <f0> 0f b1 17 75 0a 4c 89 e0 41 5c c3 cc cc cc cc 89 c6 e8 2c 0b 00
  RSP: 0018:ffffafe180580ca0 EFLAGS: 00010046
  RAX: 0000000000000000 RBX: ffffafe180a3f7a8 RCX: 0000000000000011
  RDX: 0000000000000001 RSI: 0000000000000003 RDI: ffffafe180a40084
  RBP: 0000000000000000 R08: 00000000001e7240 R09: 0000000000000011
  R10: 0000000000000028 R11: 0000000000000888 R12: 0000000000000002
  R13: ffffafe180a40084 R14: 0000000000000000 R15: 0000000000000003
  FS:  0000000000000000(0000) GS:ffff9aaf1f280000(0000) knlGS:0000000000000000
  CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
  CR2: ffffafe180a40084 CR3: 000000010e428002 CR4: 0000000000770ef0
  DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
  DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
  PKRU: 55555554
  Call Trace:
   <IRQ>
   try_to_wake_up+0x5a/0x6a0
   rq_qos_wake_function+0x71/0x80
   __wake_up_common+0x75/0xa0
   __wake_up+0x36/0x60
   scale_up.part.0+0x50/0x110
   wb_timer_fn+0x227/0x450
   ...

So rq_qos_wake_function() calls wake_up_process(data->task), which calls
try_to_wake_up(), which faults in raw_spin_lock_irqsave(&p->pi_lock).

p comes from data->task, and data comes from the waitqueue entry, which
is stored on the waiter's stack in rq_qos_wait(). Analyzing the core
dump with drgn, I found that the waiter had already woken up and moved
on to a completely unrelated code path, clobbering what was previously
data->task. Meanwhile, the waker was passing the clobbered garbage in
data->task to wake_up_process(), leading to the crash.

What's happening is that in between rq_qos_wake_function() deleting the
waitqueue entry and calling wake_up_process(), rq_qos_wait() is finding
that it already got a token and returning. The race looks like this:

rq_qos_wait()                           rq_qos_wake_function()
==============================================================
prepare_to_wait_exclusive()
                                        data->got_token = true;
                                        list_del_init(&curr->entry);
if (data.got_token)
        break;
finish_wait(&rqw->wait, &data.wq);
  ^- returns immediately because
     list_empty_careful(&wq_entry->entry)
     is true
... return, go do something else ...
                                        wake_up_process(data->task)
                                          (NO LONGER VALID!)-^

Normally, finish_wait() is supposed to synchronize against the waker.
But, as noted above, it is returning immediately because the waitqueue
entry has already been removed from the waitqueue.

The bug is that rq_qos_wake_function() is accessing the waitqueue entry
AFTER deleting it. Note that autoremove_wake_function() wakes the waiter
and THEN deletes the waitqueue entry, which is the proper order.

Fix it by swapping the order. We also need to use
list_del_init_careful() to match the list_empty_careful() in
finish_wait().

Fixes: 38cfb5a45e ("blk-wbt: improve waking of tasks")
Cc: stable@vger.kernel.org
Signed-off-by: Omar Sandoval <osandov@fb.com>
Acked-by: Tejun Heo <tj@kernel.org>
Reviewed-by: Johannes Thumshirn <johannes.thumshirn@wdc.com>
Link: https://lore.kernel.org/r/d3bee2463a67b1ee597211823bf7ad3721c26e41.1729014591.git.osandov@fb.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2024-10-22 15:39:26 +02:00
Konstantin Ovsepian
1f61d50925 blk_iocost: fix more out of bound shifts
[ Upstream commit 9bce8005ec0dcb23a58300e8522fe4a31da606fa ]

Recently running UBSAN caught few out of bound shifts in the
ioc_forgive_debts() function:

UBSAN: shift-out-of-bounds in block/blk-iocost.c:2142:38
shift exponent 80 is too large for 64-bit type 'u64' (aka 'unsigned long
long')
...
UBSAN: shift-out-of-bounds in block/blk-iocost.c:2144:30
shift exponent 80 is too large for 64-bit type 'u64' (aka 'unsigned long
long')
...
Call Trace:
<IRQ>
dump_stack_lvl+0xca/0x130
__ubsan_handle_shift_out_of_bounds+0x22c/0x280
? __lock_acquire+0x6441/0x7c10
ioc_timer_fn+0x6cec/0x7750
? blk_iocost_init+0x720/0x720
? call_timer_fn+0x5d/0x470
call_timer_fn+0xfa/0x470
? blk_iocost_init+0x720/0x720
__run_timer_base+0x519/0x700
...

Actual impact of this issue was not identified but I propose to fix the
undefined behaviour.
The proposed fix to prevent those out of bound shifts consist of
precalculating exponent before using it the shift operations by taking
min value from the actual exponent and maximum possible number of bits.

Reported-by: Breno Leitao <leitao@debian.org>
Signed-off-by: Konstantin Ovsepian <ovs@ovs.to>
Acked-by: Tejun Heo <tj@kernel.org>
Link: https://lore.kernel.org/r/20240822154137.2627818-1-ovs@ovs.to
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-10-17 15:08:10 +02:00
Riyan Dhiman
4bc4272e25 block: fix potential invalid pointer dereference in blk_add_partition
[ Upstream commit 26e197b7f9240a4ac301dd0ad520c0c697c2ea7d ]

The blk_add_partition() function initially used a single if-condition
(IS_ERR(part)) to check for errors when adding a partition. This was
modified to handle the specific case of -ENXIO separately, allowing the
function to proceed without logging the error in this case. However,
this change unintentionally left a path where md_autodetect_dev()
could be called without confirming that part is a valid pointer.

This commit separates the error handling logic by splitting the
initial if-condition, improving code readability and handling specific
error scenarios explicitly. The function now distinguishes the general
error case from -ENXIO without altering the existing behavior of
md_autodetect_dev() calls.

Fixes: b72053072c (block: allow partitions on host aware zone devices)
Signed-off-by: Riyan Dhiman <riyandhiman14@gmail.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Link: https://lore.kernel.org/r/20240911132954.5874-1-riyandhiman14@gmail.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-10-17 15:07:43 +02:00
Christian Heusel
4d2760df0f block: print symbolic error name instead of error code
[ Upstream commit 25c1772a0493463408489b1fae65cf77fe46cac1 ]

Utilize the %pe print specifier to get the symbolic error name as a
string (i.e "-ENOMEM") in the log message instead of the error code to
increase its readablility.

This change was suggested in
https://lore.kernel.org/all/92972476-0b1f-4d0a-9951-af3fc8bc6e65@suswa.mountain/

Signed-off-by: Christian Heusel <christian@heusel.eu>
Reviewed-by: Chaitanya Kulkarni <kch@nvidia.com>
Link: https://lore.kernel.org/r/20240111231521.1596838-1-christian@heusel.eu
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Stable-dep-of: 26e197b7f924 ("block: fix potential invalid pointer dereference in blk_add_partition")
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-10-17 15:07:43 +02:00
Yu Kuai
3630a18846 block, bfq: don't break merge chain in bfq_split_bfqq()
[ Upstream commit 42c306ed723321af4003b2a41bb73728cab54f85 ]

Consider the following scenario:

    Process 1       Process 2       Process 3       Process 4
     (BIC1)          (BIC2)          (BIC3)          (BIC4)
      Λ               |               |                |
       \-------------\ \-------------\ \--------------\|
                      V               V                V
      bfqq1--------->bfqq2---------->bfqq3----------->bfqq4
ref    0              1               2                4

If Process 1 issue a new IO and bfqq2 is found, and then bfq_init_rq()
decide to spilt bfqq2 by bfq_split_bfqq(). Howerver, procress reference
of bfqq2 is 1 and bfq_split_bfqq() just clear the coop flag, which will
break the merge chain.

Expected result: caller will allocate a new bfqq for BIC1

    Process 1       Process 2       Process 3       Process 4
     (BIC1)          (BIC2)          (BIC3)          (BIC4)
                      |               |                |
                       \-------------\ \--------------\|
                                      V                V
      bfqq1--------->bfqq2---------->bfqq3----------->bfqq4
ref    0              0               1                3

Since the condition is only used for the last bfqq4 when the previous
bfqq2 and bfqq3 are already splited. Fix the problem by checking if
bfqq is the last one in the merge chain as well.

Fixes: 36eca89483 ("block, bfq: add Early Queue Merge (EQM)")
Signed-off-by: Yu Kuai <yukuai3@huawei.com>
Link: https://lore.kernel.org/r/20240902130329.3787024-4-yukuai1@huaweicloud.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-10-17 15:07:43 +02:00
Yu Kuai
a819a496d2 block, bfq: choose the last bfqq from merge chain in bfq_setup_cooperator()
[ Upstream commit 0e456dba86c7f9a19792204a044835f1ca2c8dbb ]

Consider the following merge chain:

Process 1       Process 2       Process 3	Process 4
 (BIC1)          (BIC2)          (BIC3)		 (BIC4)
  Λ                |               |               |
   \--------------\ \-------------\ \-------------\|
                   V               V		   V
  bfqq1--------->bfqq2---------->bfqq3----------->bfqq4

IO from Process 1 will get bfqf2 from BIC1 first, then
bfq_setup_cooperator() will found bfqq2 already merged to bfqq3 and then
handle this IO from bfqq3. However, the merge chain can be much deeper
and bfqq3 can be merged to other bfqq as well.

Fix this problem by iterating to the last bfqq in
bfq_setup_cooperator().

Fixes: 36eca89483 ("block, bfq: add Early Queue Merge (EQM)")
Signed-off-by: Yu Kuai <yukuai3@huawei.com>
Link: https://lore.kernel.org/r/20240902130329.3787024-3-yukuai1@huaweicloud.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-10-17 15:07:42 +02:00
Yu Kuai
e1277ae780 block, bfq: fix possible UAF for bfqq->bic with merge chain
[ Upstream commit 18ad4df091dd5d067d2faa8fce1180b79f7041a7 ]

1) initial state, three tasks:

		Process 1       Process 2	Process 3
		 (BIC1)          (BIC2)		 (BIC3)
		  |  Λ            |  Λ		  |  Λ
		  |  |            |  |		  |  |
		  V  |            V  |		  V  |
		  bfqq1           bfqq2		  bfqq3
process ref:	   1		    1		    1

2) bfqq1 merged to bfqq2:

		Process 1       Process 2	Process 3
		 (BIC1)          (BIC2)		 (BIC3)
		  |               |		  |  Λ
		  \--------------\|		  |  |
		                  V		  V  |
		  bfqq1--------->bfqq2		  bfqq3
process ref:	   0		    2		    1

3) bfqq2 merged to bfqq3:

		Process 1       Process 2	Process 3
		 (BIC1)          (BIC2)		 (BIC3)
	 here -> Λ                |		  |
		  \--------------\ \-------------\|
		                  V		  V
		  bfqq1--------->bfqq2---------->bfqq3
process ref:	   0		    1		    3

In this case, IO from Process 1 will get bfqq2 from BIC1 first, and then
get bfqq3 through merge chain, and finially handle IO by bfqq3.
Howerver, current code will think bfqq2 is owned by BIC1, like initial
state, and set bfqq2->bic to BIC1.

bfq_insert_request
-> by Process 1
 bfqq = bfq_init_rq(rq)
  bfqq = bfq_get_bfqq_handle_split
   bfqq = bic_to_bfqq
   -> get bfqq2 from BIC1
 bfqq->ref++
 rq->elv.priv[0] = bic
 rq->elv.priv[1] = bfqq
 if (bfqq_process_refs(bfqq) == 1)
  bfqq->bic = bic
  -> record BIC1 to bfqq2

  __bfq_insert_request
   new_bfqq = bfq_setup_cooperator
   -> get bfqq3 from bfqq2->new_bfqq
   bfqq_request_freed(bfqq)
   new_bfqq->ref++
   rq->elv.priv[1] = new_bfqq
   -> handle IO by bfqq3

Fix the problem by checking bfqq is from merge chain fist. And this
might fix a following problem reported by our syzkaller(unreproducible):

==================================================================
BUG: KASAN: slab-use-after-free in bfq_do_early_stable_merge block/bfq-iosched.c:5692 [inline]
BUG: KASAN: slab-use-after-free in bfq_do_or_sched_stable_merge block/bfq-iosched.c:5805 [inline]
BUG: KASAN: slab-use-after-free in bfq_get_queue+0x25b0/0x2610 block/bfq-iosched.c:5889
Write of size 1 at addr ffff888123839eb8 by task kworker/0:1H/18595

CPU: 0 PID: 18595 Comm: kworker/0:1H Tainted: G             L     6.6.0-07439-gba2303cacfda #6
Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS rel-1.14.0-0-g155821a1990b-prebuilt.qemu.org 04/01/2014
Workqueue: kblockd blk_mq_requeue_work
Call Trace:
 <TASK>
 __dump_stack lib/dump_stack.c:88 [inline]
 dump_stack_lvl+0x91/0xf0 lib/dump_stack.c:106
 print_address_description mm/kasan/report.c:364 [inline]
 print_report+0x10d/0x610 mm/kasan/report.c:475
 kasan_report+0x8e/0xc0 mm/kasan/report.c:588
 bfq_do_early_stable_merge block/bfq-iosched.c:5692 [inline]
 bfq_do_or_sched_stable_merge block/bfq-iosched.c:5805 [inline]
 bfq_get_queue+0x25b0/0x2610 block/bfq-iosched.c:5889
 bfq_get_bfqq_handle_split+0x169/0x5d0 block/bfq-iosched.c:6757
 bfq_init_rq block/bfq-iosched.c:6876 [inline]
 bfq_insert_request block/bfq-iosched.c:6254 [inline]
 bfq_insert_requests+0x1112/0x5cf0 block/bfq-iosched.c:6304
 blk_mq_insert_request+0x290/0x8d0 block/blk-mq.c:2593
 blk_mq_requeue_work+0x6bc/0xa70 block/blk-mq.c:1502
 process_one_work kernel/workqueue.c:2627 [inline]
 process_scheduled_works+0x432/0x13f0 kernel/workqueue.c:2700
 worker_thread+0x6f2/0x1160 kernel/workqueue.c:2781
 kthread+0x33c/0x440 kernel/kthread.c:388
 ret_from_fork+0x4d/0x80 arch/x86/kernel/process.c:147
 ret_from_fork_asm+0x1b/0x30 arch/x86/entry/entry_64.S:305
 </TASK>

Allocated by task 20776:
 kasan_save_stack+0x20/0x40 mm/kasan/common.c:45
 kasan_set_track+0x25/0x30 mm/kasan/common.c:52
 __kasan_slab_alloc+0x87/0x90 mm/kasan/common.c:328
 kasan_slab_alloc include/linux/kasan.h:188 [inline]
 slab_post_alloc_hook mm/slab.h:763 [inline]
 slab_alloc_node mm/slub.c:3458 [inline]
 kmem_cache_alloc_node+0x1a4/0x6f0 mm/slub.c:3503
 ioc_create_icq block/blk-ioc.c:370 [inline]
 ioc_find_get_icq+0x180/0xaa0 block/blk-ioc.c:436
 bfq_prepare_request+0x39/0xf0 block/bfq-iosched.c:6812
 blk_mq_rq_ctx_init.isra.7+0x6ac/0xa00 block/blk-mq.c:403
 __blk_mq_alloc_requests+0xcc0/0x1070 block/blk-mq.c:517
 blk_mq_get_new_requests block/blk-mq.c:2940 [inline]
 blk_mq_submit_bio+0x624/0x27c0 block/blk-mq.c:3042
 __submit_bio+0x331/0x6f0 block/blk-core.c:624
 __submit_bio_noacct_mq block/blk-core.c:703 [inline]
 submit_bio_noacct_nocheck+0x816/0xb40 block/blk-core.c:732
 submit_bio_noacct+0x7a6/0x1b50 block/blk-core.c:826
 xlog_write_iclog+0x7d5/0xa00 fs/xfs/xfs_log.c:1958
 xlog_state_release_iclog+0x3b8/0x720 fs/xfs/xfs_log.c:619
 xlog_cil_push_work+0x19c5/0x2270 fs/xfs/xfs_log_cil.c:1330
 process_one_work kernel/workqueue.c:2627 [inline]
 process_scheduled_works+0x432/0x13f0 kernel/workqueue.c:2700
 worker_thread+0x6f2/0x1160 kernel/workqueue.c:2781
 kthread+0x33c/0x440 kernel/kthread.c:388
 ret_from_fork+0x4d/0x80 arch/x86/kernel/process.c:147
 ret_from_fork_asm+0x1b/0x30 arch/x86/entry/entry_64.S:305

Freed by task 946:
 kasan_save_stack+0x20/0x40 mm/kasan/common.c:45
 kasan_set_track+0x25/0x30 mm/kasan/common.c:52
 kasan_save_free_info+0x2b/0x50 mm/kasan/generic.c:522
 ____kasan_slab_free mm/kasan/common.c:236 [inline]
 __kasan_slab_free+0x12c/0x1c0 mm/kasan/common.c:244
 kasan_slab_free include/linux/kasan.h:164 [inline]
 slab_free_hook mm/slub.c:1815 [inline]
 slab_free_freelist_hook mm/slub.c:1841 [inline]
 slab_free mm/slub.c:3786 [inline]
 kmem_cache_free+0x118/0x6f0 mm/slub.c:3808
 rcu_do_batch+0x35c/0xe30 kernel/rcu/tree.c:2189
 rcu_core+0x819/0xd90 kernel/rcu/tree.c:2462
 __do_softirq+0x1b0/0x7a2 kernel/softirq.c:553

Last potentially related work creation:
 kasan_save_stack+0x20/0x40 mm/kasan/common.c:45
 __kasan_record_aux_stack+0xaf/0xc0 mm/kasan/generic.c:492
 __call_rcu_common kernel/rcu/tree.c:2712 [inline]
 call_rcu+0xce/0x1020 kernel/rcu/tree.c:2826
 ioc_destroy_icq+0x54c/0x830 block/blk-ioc.c:105
 ioc_release_fn+0xf0/0x360 block/blk-ioc.c:124
 process_one_work kernel/workqueue.c:2627 [inline]
 process_scheduled_works+0x432/0x13f0 kernel/workqueue.c:2700
 worker_thread+0x6f2/0x1160 kernel/workqueue.c:2781
 kthread+0x33c/0x440 kernel/kthread.c:388
 ret_from_fork+0x4d/0x80 arch/x86/kernel/process.c:147
 ret_from_fork_asm+0x1b/0x30 arch/x86/entry/entry_64.S:305

Second to last potentially related work creation:
 kasan_save_stack+0x20/0x40 mm/kasan/common.c:45
 __kasan_record_aux_stack+0xaf/0xc0 mm/kasan/generic.c:492
 __call_rcu_common kernel/rcu/tree.c:2712 [inline]
 call_rcu+0xce/0x1020 kernel/rcu/tree.c:2826
 ioc_destroy_icq+0x54c/0x830 block/blk-ioc.c:105
 ioc_release_fn+0xf0/0x360 block/blk-ioc.c:124
 process_one_work kernel/workqueue.c:2627 [inline]
 process_scheduled_works+0x432/0x13f0 kernel/workqueue.c:2700
 worker_thread+0x6f2/0x1160 kernel/workqueue.c:2781
 kthread+0x33c/0x440 kernel/kthread.c:388
 ret_from_fork+0x4d/0x80 arch/x86/kernel/process.c:147
 ret_from_fork_asm+0x1b/0x30 arch/x86/entry/entry_64.S:305

The buggy address belongs to the object at ffff888123839d68
 which belongs to the cache bfq_io_cq of size 1360
The buggy address is located 336 bytes inside of
 freed 1360-byte region [ffff888123839d68, ffff88812383a2b8)

The buggy address belongs to the physical page:
page:ffffea00048e0e00 refcount:1 mapcount:0 mapping:0000000000000000 index:0xffff88812383f588 pfn:0x123838
head:ffffea00048e0e00 order:3 entire_mapcount:0 nr_pages_mapped:0 pincount:0
flags: 0x17ffffc0000a40(workingset|slab|head|node=0|zone=2|lastcpupid=0x1fffff)
page_type: 0xffffffff()
raw: 0017ffffc0000a40 ffff88810588c200 ffffea00048ffa10 ffff888105889488
raw: ffff88812383f588 0000000000150006 00000001ffffffff 0000000000000000
page dumped because: kasan: bad access detected

Memory state around the buggy address:
 ffff888123839d80: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
 ffff888123839e00: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
>ffff888123839e80: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
                                        ^
 ffff888123839f00: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
 ffff888123839f80: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
==================================================================

Fixes: 36eca89483 ("block, bfq: add Early Queue Merge (EQM)")
Signed-off-by: Yu Kuai <yukuai3@huawei.com>
Link: https://lore.kernel.org/r/20240902130329.3787024-2-yukuai1@huaweicloud.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-10-17 15:07:42 +02:00
Greg Kroah-Hartman
b22678f8ef Merge ddee5b4b6a ("mptcp: pm: avoid possible UaF when selecting endp") into android12-5.10-lts
Steps on the way to 5.10.226

Change-Id: I4ee8b8e793b6ecb98c7078125d994b46b1165c2e
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
2024-09-13 05:19:26 +00:00
Christoph Hellwig
3fd11fe4f2 block: initialize integrity buffer to zero before writing it to media
commit 899ee2c3829c5ac14bfc7d3c4a5846c0b709b78f upstream.

Metadata added by bio_integrity_prep is using plain kmalloc, which leads
to random kernel memory being written media.  For PI metadata this is
limited to the app tag that isn't used by kernel generated metadata,
but for non-PI metadata the entire buffer leaks kernel memory.

Fix this by adding the __GFP_ZERO flag to allocations for writes.

Fixes: 7ba1ba12ee ("block: Block layer data integrity support")
Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Martin K. Petersen <martin.petersen@oracle.com>
Reviewed-by: Kanchan Joshi <joshi.k@samsung.com>
Reviewed-by: Chaitanya Kulkarni <kch@nvidia.com>
Link: https://lore.kernel.org/r/20240613084839.1044015-2-hch@lst.de
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Shivani Agarwal <shivani.agarwal@broadcom.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2024-09-12 11:06:41 +02:00
Christoph Hellwig
5eb04f9894 block: remove the blk_flush_integrity call in blk_integrity_unregister
[ Upstream commit e8bc14d116aeac8f0f133ec8d249acf4e0658da7 ]

Now that there are no indirect calls for PI processing there is no
way to dereference a NULL pointer here.  Additionally drivers now always
freeze the queue (or in case of stacking drivers use their internal
equivalent) around changing the integrity profile.

This is effectively a revert of commit 3df49967f6f1 ("block: flush the
integrity workqueue in blk_integrity_unregister").

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Martin K. Petersen <martin.petersen@oracle.com>
Reviewed-by: Hannes Reinecke <hare@suse.de>
Link: https://lore.kernel.org/r/20240613084839.1044015-7-hch@lst.de
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-09-12 11:06:41 +02:00
Greg Kroah-Hartman
2ebd481b31 Merge 5.10.221 into android12-5.10-lts
Changes in 5.10.221
	tracing/selftests: Fix kprobe event name test for .isra. functions
	null_blk: Print correct max open zones limit in null_init_zoned_dev()
	wifi: mac80211: mesh: Fix leak of mesh_preq_queue objects
	wifi: mac80211: Fix deadlock in ieee80211_sta_ps_deliver_wakeup()
	wifi: cfg80211: pmsr: use correct nla_get_uX functions
	wifi: iwlwifi: mvm: revert gen2 TX A-MPDU size to 64
	wifi: iwlwifi: dbg_ini: move iwl_dbg_tlv_free outside of debugfs ifdef
	wifi: iwlwifi: mvm: check n_ssids before accessing the ssids
	wifi: iwlwifi: mvm: don't read past the mfuart notifcation
	wifi: mac80211: correctly parse Spatial Reuse Parameter Set element
	net/ncsi: add NCSI Intel OEM command to keep PHY up
	net/ncsi: Simplify Kconfig/dts control flow
	net/ncsi: Fix the multi thread manner of NCSI driver
	ipv6: sr: block BH in seg6_output_core() and seg6_input_core()
	net: sched: sch_multiq: fix possible OOB write in multiq_tune()
	vxlan: Fix regression when dropping packets due to invalid src addresses
	tcp: count CLOSE-WAIT sockets for TCP_MIB_CURRESTAB
	net/sched: taprio: always validate TCA_TAPRIO_ATTR_PRIOMAP
	ptp: Fix error message on failed pin verification
	af_unix: Annotate data-race of sk->sk_state in unix_inq_len().
	af_unix: Annotate data-races around sk->sk_state in unix_write_space() and poll().
	af_unix: Annotate data-races around sk->sk_state in sendmsg() and recvmsg().
	af_unix: Annotate data-races around sk->sk_state in UNIX_DIAG.
	af_unix: Annotate data-race of net->unx.sysctl_max_dgram_qlen.
	af_unix: Use unix_recvq_full_lockless() in unix_stream_connect().
	af_unix: Use skb_queue_len_lockless() in sk_diag_show_rqlen().
	af_unix: Annotate data-race of sk->sk_shutdown in sk_diag_fill().
	ipv6: fix possible race in __fib6_drop_pcpu_from()
	usb: gadget: f_fs: Fix race between aio_cancel() and AIO request complete
	drm/amd/display: Handle Y carry-over in VCP X.Y calculation
	serial: sc16is7xx: replace hardcoded divisor value with BIT() macro
	serial: sc16is7xx: fix bug in sc16is7xx_set_baud() when using prescaler
	mmc: davinci: Don't strip remove function when driver is builtin
	selftests/mm: compaction_test: fix incorrect write of zero to nr_hugepages
	selftests/mm: conform test to TAP format output
	selftests/mm: compaction_test: fix bogus test success on Aarch64
	btrfs: fix leak of qgroup extent records after transaction abort
	nilfs2: Remove check for PageError
	nilfs2: return the mapped address from nilfs_get_page()
	nilfs2: fix nilfs_empty_dir() misjudgment and long loop on I/O errors
	USB: class: cdc-wdm: Fix CPU lockup caused by excessive log messages
	mei: me: release irq in mei_me_pci_resume error path
	jfs: xattr: fix buffer overflow for invalid xattr
	xhci: Set correct transferred length for cancelled bulk transfers
	xhci: Apply reset resume quirk to Etron EJ188 xHCI host
	xhci: Apply broken streams quirk to Etron EJ188 xHCI host
	scsi: mpt3sas: Avoid test/set_bit() operating in non-allocated memory
	powerpc/uaccess: Fix build errors seen with GCC 13/14
	Input: try trimming too long modalias strings
	SUNRPC: return proper error from gss_wrap_req_priv
	gpio: tqmx86: fix typo in Kconfig label
	HID: core: remove unnecessary WARN_ON() in implement()
	gpio: tqmx86: store IRQ trigger type and unmask status separately
	iommu/amd: Introduce pci segment structure
	iommu/amd: Fix sysfs leak in iommu init
	iommu: Return right value in iommu_sva_bind_device()
	HID: logitech-dj: Fix memory leak in logi_dj_recv_switch_to_dj_mode()
	drm/vmwgfx: 3D disabled should not effect STDU memory limits
	net: sfp: Always call `sfp_sm_mod_remove()` on remove
	net: hns3: add cond_resched() to hns3 ring buffer init process
	liquidio: Adjust a NULL pointer handling path in lio_vf_rep_copy_packet
	drm/komeda: check for error-valued pointer
	drm/bridge/panel: Fix runtime warning on panel bridge release
	tcp: fix race in tcp_v6_syn_recv_sock()
	net/mlx5e: Fix features validation check for tunneled UDP (non-VXLAN) packets
	Bluetooth: L2CAP: Fix rejecting L2CAP_CONN_PARAM_UPDATE_REQ
	netfilter: ipset: Fix race between namespace cleanup and gc in the list:set type
	net: stmmac: replace priv->speed with the portTransmitRate from the tc-cbs parameters
	net/ipv6: Fix the RT cache flush via sysctl using a previous delay
	ionic: fix use after netif_napi_del()
	iio: adc: ad9467: fix scan type sign
	iio: dac: ad5592r: fix temperature channel scaling value
	iio: imu: inv_icm42600: delete unneeded update watermark call
	drivers: core: synchronize really_probe() and dev_uevent()
	drm/exynos/vidi: fix memory leak in .get_modes()
	drm/exynos: hdmi: report safe 640x480 mode as a fallback when no EDID found
	vmci: prevent speculation leaks by sanitizing event in event_deliver()
	fs/proc: fix softlockup in __read_vmcore
	ocfs2: use coarse time for new created files
	ocfs2: fix races between hole punching and AIO+DIO
	PCI: rockchip-ep: Remove wrong mask on subsys_vendor_id
	dmaengine: axi-dmac: fix possible race in remove()
	remoteproc: k3-r5: Do not allow core1 to power up before core0 via sysfs
	intel_th: pci: Add Granite Rapids support
	intel_th: pci: Add Granite Rapids SOC support
	intel_th: pci: Add Sapphire Rapids SOC support
	intel_th: pci: Add Meteor Lake-S support
	intel_th: pci: Add Lunar Lake support
	nilfs2: fix potential kernel bug due to lack of writeback flag waiting
	tick/nohz_full: Don't abuse smp_call_function_single() in tick_setup_device()
	serial: 8250_pxa: Configure tx_loadsz to match FIFO IRQ level
	hugetlb_encode.h: fix undefined behaviour (34 << 26)
	mptcp: ensure snd_una is properly initialized on connect
	mptcp: pm: inc RmAddr MIB counter once per RM_ADDR ID
	mptcp: pm: update add_addr counters after connect
	remoteproc: k3-r5: Jump to error handling labels in start/stop errors
	greybus: Fix use-after-free bug in gb_interface_release due to race condition.
	usb-storage: alauda: Check whether the media is initialized
	i2c: at91: Fix the functionality flags of the slave-only interface
	i2c: designware: Fix the functionality flags of the slave-only interface
	zap_pid_ns_processes: clear TIF_NOTIFY_SIGNAL along with TIF_SIGPENDING
	padata: Disable BH when taking works lock on MT path
	rcutorture: Fix rcu_torture_one_read() pipe_count overflow comment
	rcutorture: Fix invalid context warning when enable srcu barrier testing
	block/ioctl: prefer different overflow check
	selftests/bpf: Prevent client connect before server bind in test_tc_tunnel.sh
	selftests/bpf: Fix flaky test btf_map_in_map/lookup_update
	batman-adv: bypass empty buckets in batadv_purge_orig_ref()
	wifi: ath9k: work around memset overflow warning
	af_packet: avoid a false positive warning in packet_setsockopt()
	drop_monitor: replace spin_lock by raw_spin_lock
	scsi: qedi: Fix crash while reading debugfs attribute
	kselftest: arm64: Add a null pointer check
	netpoll: Fix race condition in netpoll_owner_active
	HID: Add quirk for Logitech Casa touchpad
	ACPI: video: Add backlight=native quirk for Lenovo Slim 7 16ARH7
	Bluetooth: ath3k: Fix multiple issues reported by checkpatch.pl
	drm/amd/display: Exit idle optimizations before HDCP execution
	ASoC: Intel: sof_sdw: add JD2 quirk for HP Omen 14
	drm/lima: add mask irq callback to gp and pp
	drm/lima: mask irqs in timeout path before hard reset
	powerpc/pseries: Enforce hcall result buffer validity and size
	powerpc/io: Avoid clang null pointer arithmetic warnings
	power: supply: cros_usbpd: provide ID table for avoiding fallback match
	iommu/arm-smmu-v3: Free MSIs in case of ENOMEM
	f2fs: remove clear SB_INLINECRYPT flag in default_options
	usb: misc: uss720: check for incompatible versions of the Belkin F5U002
	udf: udftime: prevent overflow in udf_disk_stamp_to_time()
	PCI/PM: Avoid D3cold for HP Pavilion 17 PC/1972 PCIe Ports
	MIPS: Octeon: Add PCIe link status check
	serial: exar: adding missing CTI and Exar PCI ids
	MIPS: Routerboard 532: Fix vendor retry check code
	mips: bmips: BCM6358: make sure CBR is correctly set
	tracing: Build event generation tests only as modules
	cipso: fix total option length computation
	netrom: Fix a memory leak in nr_heartbeat_expiry()
	ipv6: prevent possible NULL deref in fib6_nh_init()
	ipv6: prevent possible NULL dereference in rt6_probe()
	xfrm6: check ip6_dst_idev() return value in xfrm6_get_saddr()
	netns: Make get_net_ns() handle zero refcount net
	qca_spi: Make interrupt remembering atomic
	net/sched: act_api: rely on rcu in tcf_idr_check_alloc
	net/sched: act_api: fix possible infinite loop in tcf_idr_check_alloc()
	tipc: force a dst refcount before doing decryption
	net/sched: act_ct: set 'net' pointer when creating new nf_flow_table
	sched: act_ct: add netns into the key of tcf_ct_flow_table
	net: stmmac: No need to calculate speed divider when offload is disabled
	virtio_net: checksum offloading handling fix
	netfilter: ipset: Fix suspicious rcu_dereference_protected()
	net: usb: rtl8150 fix unintiatilzed variables in rtl8150_get_link_ksettings
	regulator: core: Fix modpost error "regulator_get_regmap" undefined
	dmaengine: ioat: switch from 'pci_' to 'dma_' API
	dmaengine: ioat: Drop redundant pci_enable_pcie_error_reporting()
	dmaengine: ioatdma: Fix leaking on version mismatch
	dmaengine: ioat: use PCI core macros for PCIe Capability
	dmaengine: ioatdma: Fix error path in ioat3_dma_probe()
	dmaengine: ioatdma: Fix kmemleak in ioat_pci_probe()
	dmaengine: ioatdma: Fix missing kmem_cache_destroy()
	ACPICA: Revert "ACPICA: avoid Info: mapping multiple BARs. Your kernel is fine."
	RDMA/mlx5: Add check for srq max_sge attribute
	ALSA: hda/realtek: Limit mic boost on N14AP7
	drm/radeon: fix UBSAN warning in kv_dpm.c
	gcov: add support for GCC 14
	kcov: don't lose track of remote references during softirqs
	i2c: ocores: set IACK bit after core is enabled
	dt-bindings: i2c: google,cros-ec-i2c-tunnel: correct path to i2c-controller schema
	drm/amd/display: revert Exit idle optimizations before HDCP execution
	ARM: dts: samsung: smdkv310: fix keypad no-autorepeat
	ARM: dts: samsung: exynos4412-origen: fix keypad no-autorepeat
	ARM: dts: samsung: smdk4412: fix keypad no-autorepeat
	rtlwifi: rtl8192de: Style clean-ups
	wifi: rtlwifi: rtl8192de: Fix 5 GHz TX power
	pmdomain: ti-sci: Fix duplicate PD referrals
	knfsd: LOOKUP can return an illegal error value
	spmi: hisi-spmi-controller: Do not override device identifier
	bcache: fix variable length array abuse in btree_iter
	tracing: Add MODULE_DESCRIPTION() to preemptirq_delay_test
	x86/cpu/vfm: Add new macros to work with (vendor/family/model) values
	x86/cpu: Fix x86_match_cpu() to match just X86_VENDOR_INTEL
	r8169: remove unneeded memory barrier in rtl_tx
	r8169: improve rtl_tx
	r8169: improve rtl8169_start_xmit
	r8169: remove nr_frags argument from rtl_tx_slots_avail
	r8169: remove not needed check in rtl8169_start_xmit
	r8169: Fix possible ring buffer corruption on fragmented Tx packets.
	Revert "kheaders: substituting --sort in archive creation"
	kheaders: explicitly define file modes for archived headers
	perf/core: Fix missing wakeup when waiting for context reference
	PCI: Add PCI_ERROR_RESPONSE and related definitions
	x86/amd_nb: Check for invalid SMN reads
	cifs: missed ref-counting smb session in find
	smb: client: fix deadlock in smb2_find_smb_tcon()
	ACPI: Add quirks for AMD Renoir/Lucienne CPUs to force the D3 hint
	ACPI: x86: Add a quirk for Dell Inspiron 14 2-in-1 for StorageD3Enable
	ACPI: x86: Add another system to quirk list for forcing StorageD3Enable
	ACPI: x86: utils: Add Cezanne to the list for forcing StorageD3Enable
	ACPI: x86: utils: Add Picasso to the list for forcing StorageD3Enable
	ACPI: x86: Force StorageD3Enable on more products
	Input: ili210x - fix ili251x_read_touch_data() return value
	pinctrl: fix deadlock in create_pinctrl() when handling -EPROBE_DEFER
	pinctrl: rockchip: fix pinmux bits for RK3328 GPIO2-B pins
	pinctrl: rockchip: fix pinmux bits for RK3328 GPIO3-B pins
	pinctrl/rockchip: separate struct rockchip_pin_bank to a head file
	pinctrl: rockchip: use dedicated pinctrl type for RK3328
	pinctrl: rockchip: fix pinmux reset in rockchip_pmx_set
	drm/amdgpu: fix UBSAN warning in kv_dpm.c
	netfilter: nf_tables: validate family when identifying table via handle
	SUNRPC: Fix null pointer dereference in svc_rqst_free()
	SUNRPC: Fix a NULL pointer deref in trace_svc_stats_latency()
	SUNRPC: Fix svcxdr_init_decode's end-of-buffer calculation
	SUNRPC: Fix svcxdr_init_encode's buflen calculation
	nfsd: hold a lighter-weight client reference over CB_RECALL_ANY
	ASoC: fsl-asoc-card: set priv->pdev before using it
	net: dsa: microchip: fix initial port flush problem
	net: phy: micrel: add Microchip KSZ 9477 to the device table
	xdp: Move the rxq_info.mem clearing to unreg_mem_model()
	xdp: Allow registering memory model without rxq reference
	xdp: Remove WARN() from __xdp_reg_mem_model()
	sparc: fix old compat_sys_select()
	sparc: fix compat recv/recvfrom syscalls
	parisc: use correct compat recv/recvfrom syscalls
	netfilter: nf_tables: fully validate NFT_DATA_VALUE on store to data registers
	drm/panel: ilitek-ili9881c: Fix warning with GPIO controllers that sleep
	mtd: partitions: redboot: Added conversion of operands to a larger type
	bpf: Add a check for struct bpf_fib_lookup size
	net/iucv: Avoid explicit cpumask var allocation on stack
	net/dpaa2: Avoid explicit cpumask var allocation on stack
	ALSA: emux: improve patch ioctl data validation
	media: dvbdev: Initialize sbuf
	soc: ti: wkup_m3_ipc: Send NULL dummy message instead of pointer message
	drm/radeon/radeon_display: Decrease the size of allocated memory
	nvme: fixup comment for nvme RDMA Provider Type
	drm/panel: simple: Add missing display timing flags for KOE TX26D202VM0BWA
	gpio: davinci: Validate the obtained number of IRQs
	gpiolib: cdev: Disallow reconfiguration without direction (uAPI v1)
	x86: stop playing stack games in profile_pc()
	ocfs2: fix DIO failure due to insufficient transaction credits
	mmc: sdhci-pci: Convert PCIBIOS_* return codes to errnos
	mmc: sdhci: Do not invert write-protect twice
	mmc: sdhci: Do not lock spinlock around mmc_gpio_get_ro()
	counter: ti-eqep: enable clock at probe
	iio: adc: ad7266: Fix variable checking bug
	iio: chemical: bme680: Fix pressure value output
	iio: chemical: bme680: Fix calibration data variable
	iio: chemical: bme680: Fix overflows in compensate() functions
	iio: chemical: bme680: Fix sensor data read operation
	net: usb: ax88179_178a: improve link status logs
	usb: gadget: printer: SS+ support
	usb: gadget: printer: fix races against disable
	usb: musb: da8xx: fix a resource leak in probe()
	usb: atm: cxacru: fix endpoint checking in cxacru_bind()
	serial: 8250_omap: Implementation of Errata i2310
	tty: mcf: MCF54418 has 10 UARTS
	net: can: j1939: Initialize unused data in j1939_send_one()
	net: can: j1939: recover socket queue on CAN bus error during BAM transmission
	net: can: j1939: enhanced error handling for tightly received RTS messages in xtp_rx_rts_session_new
	kbuild: Install dtb files as 0644 in Makefile.dtbinst
	csky, hexagon: fix broken sys_sync_file_range
	hexagon: fix fadvise64_64 calling conventions
	drm/nouveau/dispnv04: fix null pointer dereference in nv17_tv_get_ld_modes
	drm/i915/gt: Fix potential UAF by revoke of fence registers
	drm/nouveau/dispnv04: fix null pointer dereference in nv17_tv_get_hd_modes
	batman-adv: Don't accept TT entries for out-of-spec VIDs
	ata: ahci: Clean up sysfs file on error
	ata: libata-core: Fix double free on error
	ftruncate: pass a signed offset
	syscalls: fix compat_sys_io_pgetevents_time64 usage
	mtd: spinand: macronix: Add support for serial NAND flash
	pwm: stm32: Refuse too small period requests
	nfs: Leave pages in the pagecache if readpage failed
	ipv6: annotate some data-races around sk->sk_prot
	ipv6: Fix data races around sk->sk_prot.
	tcp: Fix data races around icsk->icsk_af_ops.
	drivers: fix typo in firmware/efi/memmap.c
	efi: Correct comment on efi_memmap_alloc
	efi: memmap: Move manipulation routines into x86 arch tree
	efi: xen: Set EFI_PARAVIRT for Xen dom0 boot on all architectures
	efi/x86: Free EFI memory map only when installing a new one.
	KVM: arm64: vgic-v4: Make the doorbell request robust w.r.t preemption
	ARM: dts: rockchip: rk3066a: add #sound-dai-cells to hdmi node
	arm64: dts: rockchip: Add sound-dai-cells for RK3368
	xdp: xdp_mem_allocator can be NULL in trace_mem_connect().
	serial: 8250_omap: Fix Errata i2310 with RX FIFO level check
	tracing/net_sched: NULL pointer dereference in perf_trace_qdisc_reset()
	Linux 5.10.221

Change-Id: Icac1c62fcbda5102be7ea031121f28d6fee36875
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
2024-07-17 09:08:09 +00:00
Justin Stitt
58706e482b block/ioctl: prefer different overflow check
[ Upstream commit ccb326b5f9e623eb7f130fbbf2505ec0e2dcaff9 ]

Running syzkaller with the newly reintroduced signed integer overflow
sanitizer shows this report:

[   62.982337] ------------[ cut here ]------------
[   62.985692] cgroup: Invalid name
[   62.986211] UBSAN: signed-integer-overflow in ../block/ioctl.c:36:46
[   62.989370] 9pnet_fd: p9_fd_create_tcp (7343): problem connecting socket to 127.0.0.1
[   62.992992] 9223372036854775807 + 4095 cannot be represented in type 'long long'
[   62.997827] 9pnet_fd: p9_fd_create_tcp (7345): problem connecting socket to 127.0.0.1
[   62.999369] random: crng reseeded on system resumption
[   63.000634] GUP no longer grows the stack in syz-executor.2 (7353): 20002000-20003000 (20001000)
[   63.000668] CPU: 0 PID: 7353 Comm: syz-executor.2 Not tainted 6.8.0-rc2-00035-gb3ef86b5a957 #1
[   63.000677] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
[   63.000682] Call Trace:
[   63.000686]  <TASK>
[   63.000731]  dump_stack_lvl+0x93/0xd0
[   63.000919]  __get_user_pages+0x903/0xd30
[   63.001030]  __gup_longterm_locked+0x153e/0x1ba0
[   63.001041]  ? _raw_read_unlock_irqrestore+0x17/0x50
[   63.001072]  ? try_get_folio+0x29c/0x2d0
[   63.001083]  internal_get_user_pages_fast+0x1119/0x1530
[   63.001109]  iov_iter_extract_pages+0x23b/0x580
[   63.001206]  bio_iov_iter_get_pages+0x4de/0x1220
[   63.001235]  iomap_dio_bio_iter+0x9b6/0x1410
[   63.001297]  __iomap_dio_rw+0xab4/0x1810
[   63.001316]  iomap_dio_rw+0x45/0xa0
[   63.001328]  ext4_file_write_iter+0xdde/0x1390
[   63.001372]  vfs_write+0x599/0xbd0
[   63.001394]  ksys_write+0xc8/0x190
[   63.001403]  do_syscall_64+0xd4/0x1b0
[   63.001421]  ? arch_exit_to_user_mode_prepare+0x3a/0x60
[   63.001479]  entry_SYSCALL_64_after_hwframe+0x6f/0x77
[   63.001535] RIP: 0033:0x7f7fd3ebf539
[   63.001551] Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 f1 14 00 00 90 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 b8 ff ff ff f7 d8 64 89 01 48
[   63.001562] RSP: 002b:00007f7fd32570c8 EFLAGS: 00000246 ORIG_RAX: 0000000000000001
[   63.001584] RAX: ffffffffffffffda RBX: 00007f7fd3ff3f80 RCX: 00007f7fd3ebf539
[   63.001590] RDX: 4db6d1e4f7e43360 RSI: 0000000020000000 RDI: 0000000000000004
[   63.001595] RBP: 00007f7fd3f1e496 R08: 0000000000000000 R09: 0000000000000000
[   63.001599] R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
[   63.001604] R13: 0000000000000006 R14: 00007f7fd3ff3f80 R15: 00007ffd415ad2b8
...
[   63.018142] ---[ end trace ]---

Historically, the signed integer overflow sanitizer did not work in the
kernel due to its interaction with `-fwrapv` but this has since been
changed [1] in the newest version of Clang; It was re-enabled in the
kernel with Commit 557f8c582a9ba8ab ("ubsan: Reintroduce signed overflow
sanitizer").

Let's rework this overflow checking logic to not actually perform an
overflow during the check itself, thus avoiding the UBSAN splat.

[1]: https://github.com/llvm/llvm-project/pull/82432

Signed-off-by: Justin Stitt <justinstitt@google.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Link: https://lore.kernel.org/r/20240507-b4-sio-block-ioctl-v3-1-ba0c2b32275e@google.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-07-05 09:12:33 +02:00
Greg Kroah-Hartman
dde5ece421 Merge 5.10.217 into android12-5.10-lts
Changes in 5.10.217
	dmaengine: pl330: issue_pending waits until WFP state
	dmaengine: Revert "dmaengine: pl330: issue_pending waits until WFP state"
	wifi: nl80211: don't free NULL coalescing rule
	eeprom: at24: Use dev_err_probe for nvmem register failure
	eeprom: at24: Probe for DDR3 thermal sensor in the SPD case
	eeprom: at24: fix memory corruption race condition
	pinctrl: pinctrl-aspeed-g6: Fix register offset for pinconf of GPIOR-T
	pinctrl/meson: fix typo in PDM's pin name
	pinctrl: core: delete incorrect free in pinctrl_enable()
	pinctrl: mediatek: paris: Rework mtk_pinconf_{get,set} switch/case logic
	pinctrl: mediatek: paris: Fix PIN_CONFIG_INPUT_SCHMITT_ENABLE readback
	pinctrl: mediatek: paris: Rework support for PIN_CONFIG_{INPUT,OUTPUT}_ENABLE
	sunrpc: add a struct rpc_stats arg to rpc_create_args
	nfs: expose /proc/net/sunrpc/nfs in net namespaces
	nfs: make the rpc_stat per net namespace
	nfs: Handle error of rpc_proc_register() in nfs_net_init().
	power: rt9455: hide unused rt9455_boost_voltage_values
	pinctrl: devicetree: fix refcount leak in pinctrl_dt_to_map()
	regulator: mt6360: De-capitalize devicetree regulator subnodes
	s390/mm: Fix storage key clearing for guest huge pages
	s390/mm: Fix clearing storage keys for huge pages
	bna: ensure the copied buf is NUL terminated
	octeontx2-af: avoid off-by-one read from userspace
	nsh: Restore skb->{protocol,data,mac_header} for outer header in nsh_gso_segment().
	net l2tp: drop flow hash on forward
	s390/vdso: Add CFI for RA register to asm macro vdso_func
	net: qede: sanitize 'rc' in qede_add_tc_flower_fltr()
	net: qede: use return from qede_parse_flow_attr() for flower
	net: qede: use return from qede_parse_flow_attr() for flow_spec
	net: qede: use return from qede_parse_actions()
	ASoC: Fix 7/8 spaces indentation in Kconfig
	ASoC: meson: cards: select SND_DYNAMIC_MINORS
	cxgb4: Properly lock TX queue for the selftest.
	net: dsa: mv88e6xxx: Fix number of databases for 88E6141 / 88E6341
	net: bridge: fix multicast-to-unicast with fraglist GSO
	net: core: reject skb_copy(_expand) for fraglist GSO skbs
	tipc: fix a possible memleak in tipc_buf_append
	net: gro: add flush check in udp_gro_receive_segment
	clk: sunxi-ng: h6: Reparent CPUX during PLL CPUX rate change
	KVM: arm64: vgic-v2: Use cpuid from userspace as vcpu_id
	KVM: arm64: vgic-v2: Check for non-NULL vCPU in vgic_v2_parse_attr()
	scsi: lpfc: Update lpfc_ramp_down_queue_handler() logic
	gfs2: Fix invalid metadata access in punch_hole
	wifi: mac80211: fix ieee80211_bss_*_flags kernel-doc
	wifi: cfg80211: fix rdev_dump_mpp() arguments order
	net: mark racy access on sk->sk_rcvbuf
	scsi: bnx2fc: Remove spin_lock_bh while releasing resources after upload
	btrfs: return accurate error code on open failure in open_fs_devices()
	ALSA: line6: Zero-initialize message buffers
	net: bcmgenet: Reset RBUF on first open
	ata: sata_gemini: Check clk_enable() result
	firewire: ohci: mask bus reset interrupts between ISR and bottom half
	tools/power turbostat: Fix added raw MSR output
	tools/power turbostat: Fix Bzy_MHz documentation typo
	btrfs: make btrfs_clear_delalloc_extent() free delalloc reserve
	btrfs: always clear PERTRANS metadata during commit
	scsi: target: Fix SELinux error when systemd-modules loads the target module
	blk-iocost: avoid out of bounds shift
	gpu: host1x: Do not setup DMA for virtual devices
	MIPS: scall: Save thread_info.syscall unconditionally on entry
	selftests: timers: Fix valid-adjtimex signed left-shift undefined behavior
	fs/9p: only translate RWX permissions for plain 9P2000
	fs/9p: translate O_TRUNC into OTRUNC
	9p: explicitly deny setlease attempts
	gpio: wcove: Use -ENOTSUPP consistently
	gpio: crystalcove: Use -ENOTSUPP consistently
	clk: Don't hold prepare_lock when calling kref_put()
	fs/9p: drop inodes immediately on non-.L too
	drm/nouveau/dp: Don't probe eDP ports twice harder
	net:usb:qmi_wwan: support Rolling modules
	xfrm: Preserve vlan tags for transport mode software GRO
	tcp: defer shutdown(SEND_SHUTDOWN) for TCP_SYN_RECV sockets
	tcp: Use refcount_inc_not_zero() in tcp_twsk_unique().
	Bluetooth: Fix use-after-free bugs caused by sco_sock_timeout
	Bluetooth: l2cap: fix null-ptr-deref in l2cap_chan_timeout
	rtnetlink: Correct nested IFLA_VF_VLAN_LIST attribute validation
	hwmon: (corsair-cpro) Use a separate buffer for sending commands
	hwmon: (corsair-cpro) Use complete_all() instead of complete() in ccp_raw_event()
	hwmon: (corsair-cpro) Protect ccp->wait_input_report with a spinlock
	phonet: fix rtm_phonet_notify() skb allocation
	kcov: Remove kcov include from sched.h and move it to its users.
	net: bridge: fix corrupted ethernet header on multicast-to-unicast
	ipv6: fib6_rules: avoid possible NULL dereference in fib6_rule_action()
	net: hns3: use appropriate barrier function after setting a bit value
	btrfs: fix kvcalloc() arguments order in btrfs_ioctl_send()
	firewire: nosy: ensure user_length is taken into account when fetching packet contents
	arm64: dts: qcom: Fix 'interrupt-map' parent address cells
	usb: typec: ucsi: Check for notifications after init
	usb: typec: ucsi: Fix connector check on init
	usb: Fix regression caused by invalid ep0 maxpacket in virtual SuperSpeed device
	usb: ohci: Prevent missed ohci interrupts
	usb: gadget: composite: fix OS descriptors w_value logic
	usb: gadget: f_fs: Fix a race condition when processing setup packets.
	usb: xhci-plat: Don't include xhci.h
	usb: dwc3: core: Prevent phy suspend during init
	ALSA: hda/realtek: Fix mute led of HP Laptop 15-da3001TU
	iio:imu: adis16475: Fix sync mode setting
	iio: accel: mxc4005: Interrupt handling fixes
	tipc: fix UAF in error path
	net: bcmgenet: synchronize use of bcmgenet_set_rx_mode()
	ASoC: tegra: Fix DSPK 16-bit playback
	dyndbg: fix old BUG_ON in >control parser
	mei: me: add lunar lake point M DID
	drm/vmwgfx: Fix invalid reads in fence signaled events
	net: fix out-of-bounds access in ops_init
	hwmon: (pmbus/ucd9000) Increase delay from 250 to 500us
	regulator: core: fix debugfs creation regression
	keys: Fix overwrite of key expiration on instantiation
	md: fix kmemleak of rdev->serial
	Linux 5.10.217

Change-Id: I63eef00187948953d29febc26cc4c2c30166f7aa
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
2024-06-14 13:21:33 +00:00
Greg Kroah-Hartman
be9f128eaf Revert "block: introduce zone_write_granularity limit"
This reverts commit 6b4bb49e34 which is
commit a805a4fa4fa376bbc145762bb8b09caa2fa8af48 upstream.

It breaks the Android kernel abi and can be brought back in the future
in an abi-safe way if it is really needed.

Bug: 161946584
Change-Id: Ib32d4f828dc1ebceb03c73906e7867eaffbdee2f
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
2024-06-01 11:04:36 +00:00
Greg Kroah-Hartman
767bb1b3ae Revert "block: Clear zone limits for a non-zoned stacked queue"
This reverts commit 96661f8c3d which is
commit c8f6f88d25929ad2f290b428efcae3b526f3eab0 upstream.

It breaks the Android kernel abi and can be brought back in the future
in an abi-safe way if it is really needed.

Bug: 161946584
Change-Id: I4de870534a51a42360da6558ea0164c0f66ee7a0
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
2024-06-01 11:04:36 +00:00
Greg Kroah-Hartman
9100d24dfd This is the 5.10.215 stable release
-----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCAAdFiEEZH8oZUiU471FcZm+ONu9yGCSaT4FAmYaZdgACgkQONu9yGCS
 aT4oMxAA0pATFAq8RN5f9CmYlMg5HqHgzZ8lJv8P0/reOINhUa+F5sJb1n+x+Ch4
 WQbmiFeZRzfsKZ2qKhIdNR0Lg+9JOr/DtYXdSBZ6InfSWrTAIrQ9fjl5Warkmcgg
 O4WbgF5BVgU3vGFATgxLvnUZwhR1D7WK93oMDunzrT7+OqyncU3f1Uj53ZAu9030
 z18UNqnTxDLYH/CMGwAeRkaZqBev9gZ1HdgQWA27SVLqWQwZq0al81Cmlo+ECVmk
 5dF6V2pid4qfKGJjDDfx1NS0PVnoP68iK4By1SXyoFV9VBiSwp77nUUyDr7YsHsT
 u8GpZHr9jZvSO5/xtKv20NPLejTPCRKc06CbkwpikDRtGOocBL8em0GuVqlf8hMs
 KwDb6ZEzYhXZGPJHbJM+aRD1tq/KHw9X7TrldOszMQPr6lubBtscPbg1FCg3OlcC
 HUrtub0i275x7TH0dJeRTD8TRE9jRmF+tl7KQytEJM3JRrquFjLyhDj+/VJnZkiB
 lzj3FRf4zshzgz4+CAeqXO/8Lu8b3fGYmcW1acCmk7emjDcXUKojPj/Aig6T4l7P
 oCWDY3+w1E6eiyE8BazxY1KUa/41ld0VJnlW5JWGRaDFTJwrk0h6/rvf9qImSckw
 IGx24UezRyp6NS1op3Qm2iwHLr41pFRfKxNm9ppgH9iBPzOhe38=
 =pkLL
 -----END PGP SIGNATURE-----

Merge 5.10.215 into android12-5.10-lts

Changes in 5.10.215
	amdkfd: use calloc instead of kzalloc to avoid integer overflow
	Documentation/hw-vuln: Update spectre doc
	x86/cpu: Support AMD Automatic IBRS
	x86/bugs: Use sysfs_emit()
	timers: Update kernel-doc for various functions
	timers: Use del_timer_sync() even on UP
	timers: Rename del_timer_sync() to timer_delete_sync()
	wifi: brcmfmac: Fix use-after-free bug in brcmf_cfg80211_detach
	media: staging: ipu3-imgu: Set fields before media_entity_pads_init()
	clk: qcom: gcc-sdm845: Add soft dependency on rpmhpd
	smack: Set SMACK64TRANSMUTE only for dirs in smack_inode_setxattr()
	smack: Handle SMACK64TRANSMUTE in smack_inode_setsecurity()
	arm: dts: marvell: Fix maxium->maxim typo in brownstone dts
	drm/vmwgfx: stop using ttm_bo_create v2
	drm/vmwgfx: switch over to the new pin interface v2
	drm/vmwgfx/vmwgfx_cmdbuf_res: Remove unused variable 'ret'
	drm/vmwgfx: Fix some static checker warnings
	drm/vmwgfx: Fix possible null pointer derefence with invalid contexts
	serial: max310x: fix NULL pointer dereference in I2C instantiation
	media: xc4000: Fix atomicity violation in xc4000_get_frequency
	KVM: Always flush async #PF workqueue when vCPU is being destroyed
	sparc64: NMI watchdog: fix return value of __setup handler
	sparc: vDSO: fix return value of __setup handler
	crypto: qat - fix double free during reset
	crypto: qat - resolve race condition during AER recovery
	selftests/mqueue: Set timeout to 180 seconds
	ext4: correct best extent lstart adjustment logic
	block: introduce zone_write_granularity limit
	block: Clear zone limits for a non-zoned stacked queue
	bounds: support non-power-of-two CONFIG_NR_CPUS
	fat: fix uninitialized field in nostale filehandles
	ubifs: Set page uptodate in the correct place
	ubi: Check for too small LEB size in VTBL code
	ubi: correct the calculation of fastmap size
	mtd: rawnand: meson: fix scrambling mode value in command macro
	parisc: Avoid clobbering the C/B bits in the PSW with tophys and tovirt macros
	parisc: Fix ip_fast_csum
	parisc: Fix csum_ipv6_magic on 32-bit systems
	parisc: Fix csum_ipv6_magic on 64-bit systems
	parisc: Strip upper 32 bit of sum in csum_ipv6_magic for 64-bit builds
	PM: suspend: Set mem_sleep_current during kernel command line setup
	clk: qcom: gcc-ipq6018: fix terminating of frequency table arrays
	clk: qcom: gcc-ipq8074: fix terminating of frequency table arrays
	clk: qcom: mmcc-apq8084: fix terminating of frequency table arrays
	clk: qcom: mmcc-msm8974: fix terminating of frequency table arrays
	powerpc/fsl: Fix mfpmr build errors with newer binutils
	USB: serial: ftdi_sio: add support for GMC Z216C Adapter IR-USB
	USB: serial: add device ID for VeriFone adapter
	USB: serial: cp210x: add ID for MGP Instruments PDS100
	USB: serial: option: add MeiG Smart SLM320 product
	USB: serial: cp210x: add pid/vid for TDK NC0110013M and MM0110113M
	PM: sleep: wakeirq: fix wake irq warning in system suspend
	mmc: tmio: avoid concurrent runs of mmc_request_done()
	fuse: fix root lookup with nonzero generation
	fuse: don't unhash root
	usb: typec: ucsi: Clean up UCSI_CABLE_PROP macros
	printk/console: Split out code that enables default console
	serial: Lock console when calling into driver before registration
	btrfs: fix off-by-one chunk length calculation at contains_pending_extent()
	PCI: Drop pci_device_remove() test of pci_dev->driver
	PCI/PM: Drain runtime-idle callbacks before driver removal
	PCI/ERR: Cache RCEC EA Capability offset in pci_init_capabilities()
	PCI: Cache PCIe Device Capabilities register
	PCI: Work around Intel I210 ROM BAR overlap defect
	PCI/ASPM: Make Intel DG2 L1 acceptable latency unlimited
	PCI/DPC: Quirk PIO log size for certain Intel Root Ports
	PCI/DPC: Quirk PIO log size for Intel Raptor Lake Root Ports
	Revert "Revert "md/raid5: Wait for MD_SB_CHANGE_PENDING in raid5d""
	dm-raid: fix lockdep waring in "pers->hot_add_disk"
	mac802154: fix llsec key resources release in mac802154_llsec_key_del
	mm: swap: fix race between free_swap_and_cache() and swapoff()
	mmc: core: Fix switch on gp3 partition
	drm/etnaviv: Restore some id values
	hwmon: (amc6821) add of_match table
	ext4: fix corruption during on-line resize
	nvmem: meson-efuse: fix function pointer type mismatch
	slimbus: core: Remove usage of the deprecated ida_simple_xx() API
	phy: tegra: xusb: Add API to retrieve the port number of phy
	usb: gadget: tegra-xudc: Use dev_err_probe()
	usb: gadget: tegra-xudc: Fix USB3 PHY retrieval logic
	speakup: Fix 8bit characters from direct synth
	PCI/ERR: Clear AER status only when we control AER
	PCI/AER: Block runtime suspend when handling errors
	nfs: fix UAF in direct writes
	kbuild: Move -Wenum-{compare-conditional,enum-conversion} into W=1
	PCI: dwc: endpoint: Fix advertised resizable BAR size
	vfio/platform: Disable virqfds on cleanup
	ring-buffer: Fix waking up ring buffer readers
	ring-buffer: Do not set shortest_full when full target is hit
	ring-buffer: Fix resetting of shortest_full
	ring-buffer: Fix full_waiters_pending in poll
	soc: fsl: qbman: Always disable interrupts when taking cgr_lock
	soc: fsl: qbman: Add helper for sanity checking cgr ops
	soc: fsl: qbman: Add CGR update function
	soc: fsl: qbman: Use raw spinlock for cgr_lock
	s390/zcrypt: fix reference counting on zcrypt card objects
	drm/panel: do not return negative error codes from drm_panel_get_modes()
	drm/exynos: do not return negative values from .get_modes()
	drm/imx/ipuv3: do not return negative values from .get_modes()
	drm/vc4: hdmi: do not return negative values from .get_modes()
	memtest: use {READ,WRITE}_ONCE in memory scanning
	nilfs2: fix failure to detect DAT corruption in btree and direct mappings
	nilfs2: prevent kernel bug at submit_bh_wbc()
	cpufreq: dt: always allocate zeroed cpumask
	x86/CPU/AMD: Update the Zenbleed microcode revisions
	net: hns3: tracing: fix hclgevf trace event strings
	wireguard: netlink: check for dangling peer via is_dead instead of empty list
	wireguard: netlink: access device through ctx instead of peer
	ahci: asm1064: correct count of reported ports
	ahci: asm1064: asm1166: don't limit reported ports
	drm/amd/display: Return the correct HDCP error code
	drm/amd/display: Fix noise issue on HDMI AV mute
	dm snapshot: fix lockup in dm_exception_table_exit
	vxge: remove unnecessary cast in kfree()
	x86/stackprotector/32: Make the canary into a regular percpu variable
	x86/pm: Work around false positive kmemleak report in msr_build_context()
	scripts: kernel-doc: Fix syntax error due to undeclared args variable
	comedi: comedi_test: Prevent timers rescheduling during deletion
	cpufreq: brcmstb-avs-cpufreq: fix up "add check for cpufreq_cpu_get's return value"
	netfilter: nf_tables: mark set as dead when unbinding anonymous set with timeout
	netfilter: nf_tables: disallow anonymous set with timeout flag
	netfilter: nf_tables: reject constant set with timeout
	Drivers: hv: vmbus: Calculate ring buffer size for more efficient use of memory
	xfrm: Avoid clang fortify warning in copy_to_user_tmpl()
	KVM: SVM: Flush pages under kvm->lock to fix UAF in svm_register_enc_region()
	ALSA: hda/realtek - Fix headset Mic no show at resume back for Lenovo ALC897 platform
	USB: usb-storage: Prevent divide-by-0 error in isd200_ata_command
	usb: gadget: ncm: Fix handling of zero block length packets
	usb: port: Don't try to peer unused USB ports based on location
	tty: serial: fsl_lpuart: avoid idle preamble pending if CTS is enabled
	mei: me: add arrow lake point S DID
	mei: me: add arrow lake point H DID
	vt: fix unicode buffer corruption when deleting characters
	fs/aio: Check IOCB_AIO_RW before the struct aio_kiocb conversion
	tee: optee: Fix kernel panic caused by incorrect error handling
	xen/events: close evtchn after mapping cleanup
	printk: Update @console_may_schedule in console_trylock_spinning()
	btrfs: allocate btrfs_ioctl_defrag_range_args on stack
	x86/asm: Add _ASM_RIP() macro for x86-64 (%rip) suffix
	x86/bugs: Add asm helpers for executing VERW
	x86/entry_64: Add VERW just before userspace transition
	x86/entry_32: Add VERW just before userspace transition
	x86/bugs: Use ALTERNATIVE() instead of mds_user_clear static key
	KVM/VMX: Use BT+JNC, i.e. EFLAGS.CF to select VMRESUME vs. VMLAUNCH
	KVM/VMX: Move VERW closer to VMentry for MDS mitigation
	x86/mmio: Disable KVM mitigation when X86_FEATURE_CLEAR_CPU_BUF is set
	Documentation/hw-vuln: Add documentation for RFDS
	x86/rfds: Mitigate Register File Data Sampling (RFDS)
	KVM/x86: Export RFDS_NO and RFDS_CLEAR to guests
	perf/core: Fix reentry problem in perf_output_read_group()
	efivarfs: Request at most 512 bytes for variable names
	powerpc: xor_vmx: Add '-mhard-float' to CFLAGS
	serial: sc16is7xx: convert from _raw_ to _noinc_ regmap functions for FIFO
	mm/memory-failure: fix an incorrect use of tail pages
	mm/migrate: set swap entry values of THP tail pages properly.
	init: open /initrd.image with O_LARGEFILE
	wifi: mac80211: check/clear fast rx for non-4addr sta VLAN changes
	exec: Fix NOMMU linux_binprm::exec in transfer_args_to_stack()
	hexagon: vmlinux.lds.S: handle attributes section
	mmc: core: Initialize mmc_blk_ioc_data
	mmc: core: Avoid negative index with array access
	net: ll_temac: platform_get_resource replaced by wrong function
	usb: cdc-wdm: close race between read and workqueue
	ALSA: sh: aica: reorder cleanup operations to avoid UAF bugs
	scsi: core: Fix unremoved procfs host directory regression
	staging: vc04_services: changen strncpy() to strscpy_pad()
	staging: vc04_services: fix information leak in create_component()
	USB: core: Add hub_get() and hub_put() routines
	usb: dwc2: host: Fix remote wakeup from hibernation
	usb: dwc2: host: Fix hibernation flow
	usb: dwc2: host: Fix ISOC flow in DDMA mode
	usb: dwc2: gadget: LPM flow fix
	usb: udc: remove warning when queue disabled ep
	usb: typec: ucsi: Ack unsupported commands
	usb: typec: ucsi: Clear UCSI_CCI_RESET_COMPLETE before reset
	scsi: qla2xxx: Split FCE|EFT trace control
	scsi: qla2xxx: Fix command flush on cable pull
	scsi: qla2xxx: Delay I/O Abort on PCI error
	x86/cpu: Enable STIBP on AMD if Automatic IBRS is enabled
	PCI/DPC: Quirk PIO log size for Intel Ice Lake Root Ports
	scsi: lpfc: Correct size for wqe for memset()
	USB: core: Fix deadlock in usb_deauthorize_interface()
	nfc: nci: Fix uninit-value in nci_dev_up and nci_ntf_packet
	ixgbe: avoid sleeping allocation in ixgbe_ipsec_vf_add_sa()
	tcp: properly terminate timers for kernel sockets
	ACPICA: debugger: check status of acpi_evaluate_object() in acpi_db_walk_for_fields()
	bpf: Protect against int overflow for stack access size
	Octeontx2-af: fix pause frame configuration in GMP mode
	dm integrity: fix out-of-range warning
	r8169: fix issue caused by buggy BIOS on certain boards with RTL8168d
	x86/cpufeatures: Add new word for scattered features
	Bluetooth: hci_event: set the conn encrypted before conn establishes
	Bluetooth: Fix TOCTOU in HCI debugfs implementation
	netfilter: nf_tables: disallow timeout for anonymous sets
	net/rds: fix possible cp null dereference
	vfio/pci: Disable auto-enable of exclusive INTx IRQ
	vfio/pci: Lock external INTx masking ops
	vfio: Introduce interface to flush virqfd inject workqueue
	vfio/pci: Create persistent INTx handler
	vfio/platform: Create persistent IRQ handlers
	vfio/fsl-mc: Block calling interrupt handler without trigger
	io_uring: ensure '0' is returned on file registration success
	Revert "x86/mm/ident_map: Use gbpages only where full GB page should be mapped."
	mm, vmscan: prevent infinite loop for costly GFP_NOIO | __GFP_RETRY_MAYFAIL allocations
	x86/srso: Add SRSO mitigation for Hygon processors
	block: add check that partition length needs to be aligned with block size
	netfilter: nf_tables: reject new basechain after table flag update
	netfilter: nf_tables: flush pending destroy work before exit_net release
	netfilter: nf_tables: Fix potential data-race in __nft_flowtable_type_get()
	netfilter: validate user input for expected length
	vboxsf: Avoid an spurious warning if load_nls_xxx() fails
	bpf, sockmap: Prevent lock inversion deadlock in map delete elem
	net/sched: act_skbmod: prevent kernel-infoleak
	net: stmmac: fix rx queue priority assignment
	erspan: make sure erspan_base_hdr is present in skb->head
	selftests: reuseaddr_conflict: add missing new line at the end of the output
	ipv6: Fix infinite recursion in fib6_dump_done().
	udp: do not transition UDP GRO fraglist partial checksums to unnecessary
	octeontx2-pf: check negative error code in otx2_open()
	i40e: fix i40e_count_filters() to count only active/new filters
	i40e: fix vf may be used uninitialized in this function warning
	scsi: qla2xxx: Update manufacturer details
	scsi: qla2xxx: Update manufacturer detail
	Revert "usb: phy: generic: Get the vbus supply"
	udp: do not accept non-tunnel GSO skbs landing in a tunnel
	net: ravb: Always process TX descriptor ring
	arm64: dts: qcom: sc7180: Remove clock for bluetooth on Trogdor
	arm64: dts: qcom: sc7180-trogdor: mark bluetooth address as broken
	ASoC: ops: Fix wraparound for mask in snd_soc_get_volsw
	ata: sata_sx4: fix pdc20621_get_from_dimm() on 64-bit
	scsi: mylex: Fix sysfs buffer lengths
	ata: sata_mv: Fix PCI device ID table declaration compilation warning
	ALSA: hda/realtek: Update Panasonic CF-SZ6 quirk to support headset with microphone
	driver core: Introduce device_link_wait_removal()
	of: dynamic: Synchronize of_changeset_destroy() with the devlink removals
	x86/mce: Make sure to grab mce_sysfs_mutex in set_bank()
	s390/entry: align system call table on 8 bytes
	riscv: Fix spurious errors from __get/put_kernel_nofault
	x86/bugs: Fix the SRSO mitigation on Zen3/4
	x86/retpoline: Do the necessary fixup to the Zen3/4 srso return thunk for !SRSO
	mptcp: don't account accept() of non-MPC client as fallback to TCP
	x86/cpufeatures: Add CPUID_LNX_5 to track recently added Linux-defined word
	objtool: Add asm version of STACK_FRAME_NON_STANDARD
	wifi: ath9k: fix LNA selection in ath_ant_try_scan()
	VMCI: Fix memcpy() run-time warning in dg_dispatch_as_host()
	panic: Flush kernel log buffer at the end
	arm64: dts: rockchip: fix rk3328 hdmi ports node
	arm64: dts: rockchip: fix rk3399 hdmi ports node
	ionic: set adminq irq affinity
	pstore/zone: Add a null pointer check to the psz_kmsg_read
	tools/power x86_energy_perf_policy: Fix file leak in get_pkg_num()
	btrfs: handle chunk tree lookup error in btrfs_relocate_sys_chunks()
	btrfs: export: handle invalid inode or root reference in btrfs_get_parent()
	btrfs: send: handle path ref underflow in header iterate_inode_ref()
	net/smc: reduce rtnl pressure in smc_pnet_create_pnetids_list()
	Bluetooth: btintel: Fix null ptr deref in btintel_read_version
	Input: synaptics-rmi4 - fail probing if memory allocation for "phys" fails
	pinctrl: renesas: checker: Limit cfg reg enum checks to provided IDs
	sysv: don't call sb_bread() with pointers_lock held
	scsi: lpfc: Fix possible memory leak in lpfc_rcv_padisc()
	isofs: handle CDs with bad root inode but good Joliet root directory
	media: sta2x11: fix irq handler cast
	ext4: add a hint for block bitmap corrupt state in mb_groups
	ext4: forbid commit inconsistent quota data when errors=remount-ro
	drm/amd/display: Fix nanosec stat overflow
	SUNRPC: increase size of rpc_wait_queue.qlen from unsigned short to unsigned int
	Revert "ACPI: PM: Block ASUS B1400CEAE from suspend to idle by default"
	libperf evlist: Avoid out-of-bounds access
	block: prevent division by zero in blk_rq_stat_sum()
	RDMA/cm: add timeout to cm_destroy_id wait
	Input: allocate keycode for Display refresh rate toggle
	platform/x86: touchscreen_dmi: Add an extra entry for a variant of the Chuwi Vi8 tablet
	ktest: force $buildonly = 1 for 'make_warnings_file' test type
	ring-buffer: use READ_ONCE() to read cpu_buffer->commit_page in concurrent environment
	tools: iio: replace seekdir() in iio_generic_buffer
	usb: typec: tcpci: add generic tcpci fallback compatible
	usb: sl811-hcd: only defined function checkdone if QUIRK2 is defined
	fbdev: viafb: fix typo in hw_bitblt_1 and hw_bitblt_2
	drivers/nvme: Add quirks for device 126f:2262
	fbmon: prevent division by zero in fb_videomode_from_videomode()
	netfilter: nf_tables: release batch on table validation from abort path
	netfilter: nf_tables: release mutex after nft_gc_seq_end from abort path
	netfilter: nf_tables: discard table flag update with pending basechain deletion
	tty: n_gsm: require CAP_NET_ADMIN to attach N_GSM0710 ldisc
	virtio: reenable config if freezing device failed
	x86/mm/pat: fix VM_PAT handling in COW mappings
	drm/i915/gt: Reset queue_priority_hint on parking
	Bluetooth: btintel: Fixe build regression
	VMCI: Fix possible memcpy() run-time warning in vmci_datagram_invoke_guest_handler()
	kbuild: dummy-tools: adjust to stricter stackprotector check
	scsi: sd: Fix wrong zone_write_granularity value during revalidate
	x86/retpoline: Add NOENDBR annotation to the SRSO dummy return thunk
	x86/head/64: Re-enable stack protection
	Linux 5.10.215

Change-Id: I45a0a9c4a0683ff5ef97315690f1f884f666e1b5
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
2024-06-01 11:03:55 +00:00
Greg Kroah-Hartman
f21d21f05e Revert "block: add a new set_read_only method"
This reverts commit 2a0f8202f7 which is
commit e00adcadf3af7a8335026d71ab9f0e0a922191ac upstream.

It breaks the Android kernel abi and can be brought back in the future
in an abi-safe way if it is really needed.

Bug: 161946584
Change-Id: I20342421827a743bfb159577aa151698b101d17d
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
2024-05-20 10:43:46 +00:00
Rik van Riel
62accf6c1d blk-iocost: avoid out of bounds shift
[ Upstream commit beaa51b36012fad5a4d3c18b88a617aea7a9b96d ]

UBSAN catches undefined behavior in blk-iocost, where sometimes
iocg->delay is shifted right by a number that is too large,
resulting in undefined behavior on some architectures.

[  186.556576] ------------[ cut here ]------------
UBSAN: shift-out-of-bounds in block/blk-iocost.c:1366:23
shift exponent 64 is too large for 64-bit type 'u64' (aka 'unsigned long long')
CPU: 16 PID: 0 Comm: swapper/16 Tainted: G S          E    N 6.9.0-0_fbk700_debug_rc2_kbuilder_0_gc85af715cac0 #1
Hardware name: Quanta Twin Lakes MP/Twin Lakes Passive MP, BIOS F09_3A23 12/08/2020
Call Trace:
 <IRQ>
 dump_stack_lvl+0x8f/0xe0
 __ubsan_handle_shift_out_of_bounds+0x22c/0x280
 iocg_kick_delay+0x30b/0x310
 ioc_timer_fn+0x2fb/0x1f80
 __run_timer_base+0x1b6/0x250
...

Avoid that undefined behavior by simply taking the
"delay = 0" branch if the shift is too large.

I am not sure what the symptoms of an undefined value
delay will be, but I suspect it could be more than a
little annoying to debug.

Signed-off-by: Rik van Riel <riel@surriel.com>
Cc: Tejun Heo <tj@kernel.org>
Cc: Josef Bacik <josef@toxicpanda.com>
Cc: Jens Axboe <axboe@kernel.dk>
Acked-by: Tejun Heo <tj@kernel.org>
Link: https://lore.kernel.org/r/20240404123253.0f58010f@imladris.surriel.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-05-17 11:48:04 +02:00
Greg Kroah-Hartman
dd27b89022 Merge 5.10.214 into android12-5.10-lts
Changes in 5.10.214
	io_uring/unix: drop usage of io_uring socket
	io_uring: drop any code related to SCM_RIGHTS
	rcu-tasks: Provide rcu_trace_implies_rcu_gp()
	bpf: Defer the free of inner map when necessary
	selftests: tls: use exact comparison in recv_partial
	ASoC: rt5645: Make LattePanda board DMI match more precise
	x86/xen: Add some null pointer checking to smp.c
	MIPS: Clear Cause.BD in instruction_pointer_set
	HID: multitouch: Add required quirk for Synaptics 0xcddc device
	gen_compile_commands: fix invalid escape sequence warning
	RDMA/mlx5: Fix fortify source warning while accessing Eth segment
	RDMA/mlx5: Relax DEVX access upon modify commands
	x86/mm: Move is_vsyscall_vaddr() into asm/vsyscall.h
	x86/mm: Disallow vsyscall page read for copy_from_kernel_nofault()
	net/iucv: fix the allocation size of iucv_path_table array
	parisc/ftrace: add missing CONFIG_DYNAMIC_FTRACE check
	block: sed-opal: handle empty atoms when parsing response
	dm-verity, dm-crypt: align "struct bvec_iter" correctly
	scsi: mpt3sas: Prevent sending diag_reset when the controller is ready
	Bluetooth: rfcomm: Fix null-ptr-deref in rfcomm_check_security
	firewire: core: use long bus reset on gap count error
	ASoC: Intel: bytcr_rt5640: Add an extra entry for the Chuwi Vi8 tablet
	Input: gpio_keys_polled - suppress deferred probe error for gpio
	ASoC: wm8962: Enable oscillator if selecting WM8962_FLL_OSC
	ASoC: wm8962: Enable both SPKOUTR_ENA and SPKOUTL_ENA in mono mode
	ASoC: wm8962: Fix up incorrect error message in wm8962_set_fll
	x86/paravirt: Fix build due to __text_gen_insn() backport
	do_sys_name_to_handle(): use kzalloc() to fix kernel-infoleak
	nbd: null check for nla_nest_start
	fs/select: rework stack allocation hack for clang
	block: add a new set_read_only method
	md: implement ->set_read_only to hook into BLKROSET processing
	md: Don't clear MD_CLOSING when the raid is about to stop
	aoe: fix the potential use-after-free problem in aoecmd_cfg_pkts
	timekeeping: Fix cross-timestamp interpolation on counter wrap
	timekeeping: Fix cross-timestamp interpolation corner case decision
	timekeeping: Fix cross-timestamp interpolation for non-x86
	wifi: ath10k: fix NULL pointer dereference in ath10k_wmi_tlv_op_pull_mgmt_tx_compl_ev()
	wifi: b43: Stop/wake correct queue in DMA Tx path when QoS is disabled
	wifi: b43: Stop/wake correct queue in PIO Tx path when QoS is disabled
	wifi: b43: Stop correct queue in DMA worker when QoS is disabled
	wifi: b43: Disable QoS for bcm4331
	wifi: wilc1000: fix declarations ordering
	wifi: wilc1000: fix RCU usage in connect path
	wifi: rtl8xxxu: add cancel_work_sync() for c2hcmd_work
	wifi: wilc1000: fix multi-vif management when deleting a vif
	wifi: mwifiex: debugfs: Drop unnecessary error check for debugfs_create_dir()
	cpufreq: brcmstb-avs-cpufreq: add check for cpufreq_cpu_get's return value
	sock_diag: annotate data-races around sock_diag_handlers[family]
	inet_diag: annotate data-races around inet_diag_table[]
	bpftool: Silence build warning about calloc()
	af_unix: Annotate data-race of gc_in_progress in wait_for_unix_gc().
	wifi: ath9k: delay all of ath9k_wmi_event_tasklet() until init is complete
	wifi: iwlwifi: dbg-tlv: ensure NUL termination
	wifi: iwlwifi: fix EWRD table validity check
	net: blackhole_dev: fix build warning for ethh set but not used
	wifi: libertas: fix some memleaks in lbs_allocate_cmd_buffer()
	arm64: dts: mediatek: mt7622: add missing "device_type" to memory nodes
	bpf: Factor out bpf_spin_lock into helpers.
	bpf: Mark bpf_spin_{lock,unlock}() helpers with notrace correctly
	wireless: Remove redundant 'flush_workqueue()' calls
	wifi: wilc1000: prevent use-after-free on vif when cleaning up all interfaces
	ACPI: processor_idle: Fix memory leak in acpi_processor_power_exit()
	bus: tegra-aconnect: Update dependency to ARCH_TEGRA
	iommu/amd: Mark interrupt as managed
	wifi: brcmsmac: avoid function pointer casts
	net: ena: Remove ena_select_queue
	ARM: dts: arm: realview: Fix development chip ROM compatible value
	ARM: dts: imx6dl-yapp4: Move phy reset into switch node
	ARM: dts: imx6dl-yapp4: Fix typo in the QCA switch register address
	ARM: dts: imx6dl-yapp4: Move the internal switch PHYs under the switch node
	arm64: dts: marvell: reorder crypto interrupts on Armada SoCs
	ACPI: scan: Fix device check notification handling
	x86, relocs: Ignore relocations in .notes section
	SUNRPC: fix some memleaks in gssx_dec_option_array
	mmc: wmt-sdmmc: remove an incorrect release_mem_region() call in the .remove function
	wifi: rtw88: 8821c: Fix false alarm count
	PCI: Make pci_dev_is_disconnected() helper public for other drivers
	iommu/vt-d: Don't issue ATS Invalidation request when device is disconnected
	igb: move PEROUT and EXTTS isr logic to separate functions
	igb: Fix missing time sync events
	Bluetooth: Remove superfluous call to hci_conn_check_pending()
	Bluetooth: hci_core: Fix possible buffer overflow
	sr9800: Add check for usbnet_get_endpoints
	bpf: Eliminate rlimit-based memory accounting for devmap maps
	bpf: Fix DEVMAP_HASH overflow check on 32-bit arches
	bpf: Fix hashtab overflow check on 32-bit arches
	bpf: Fix stackmap overflow check on 32-bit arches
	ipv6: fib6_rules: flush route cache when rule is changed
	net: ip_tunnel: make sure to pull inner header in ip_tunnel_rcv()
	net: phy: fix phy_get_internal_delay accessing an empty array
	net: hns3: fix port duplex configure error in IMP reset
	net: phy: DP83822: enable rgmii mode if phy_interface_is_rgmii
	net: phy: dp83822: Fix RGMII TX delay configuration
	OPP: debugfs: Fix warning around icc_get_name()
	tcp: fix incorrect parameter validation in the do_tcp_getsockopt() function
	net/ipv4: Replace one-element array with flexible-array member
	net/ipv4: Revert use of struct_size() helper
	net/ipv4/ipv6: Replace one-element arraya with flexible-array members
	bpf: net: Change do_ip_getsockopt() to take the sockptr_t argument
	ipmr: fix incorrect parameter validation in the ip_mroute_getsockopt() function
	l2tp: fix incorrect parameter validation in the pppol2tp_getsockopt() function
	udp: fix incorrect parameter validation in the udp_lib_getsockopt() function
	net: kcm: fix incorrect parameter validation in the kcm_getsockopt) function
	net/x25: fix incorrect parameter validation in the x25_getsockopt() function
	nfp: flower: handle acti_netdevs allocation failure
	dm raid: fix false positive for requeue needed during reshape
	dm: call the resume method on internal suspend
	drm/tegra: dsi: Add missing check for of_find_device_by_node
	drm/tegra: dsi: Make use of the helper function dev_err_probe()
	drm/tegra: dsi: Fix some error handling paths in tegra_dsi_probe()
	drm/tegra: dsi: Fix missing pm_runtime_disable() in the error handling path of tegra_dsi_probe()
	drm/tegra: output: Fix missing i2c_put_adapter() in the error handling paths of tegra_output_probe()
	drm/rockchip: inno_hdmi: Fix video timing
	drm: Don't treat 0 as -1 in drm_fixp2int_ceil
	drm/rockchip: lvds: do not overwrite error code
	drm/rockchip: lvds: do not print scary message when probing defer
	drm/lima: fix a memleak in lima_heap_alloc
	dmaengine: tegra210-adma: Update dependency to ARCH_TEGRA
	media: tc358743: register v4l2 async device only after successful setup
	PCI/DPC: Print all TLP Prefixes, not just the first
	perf record: Fix possible incorrect free in record__switch_output()
	HID: lenovo: Add middleclick_workaround sysfs knob for cptkbd
	drm/amd/display: Fix a potential buffer overflow in 'dp_dsc_clock_en_read()'
	drm/amd/display: Fix potential NULL pointer dereferences in 'dcn10_set_output_transfer_func()'
	perf evsel: Fix duplicate initialization of data->id in evsel__parse_sample()
	media: em28xx: annotate unchecked call to media_device_register()
	media: v4l2-tpg: fix some memleaks in tpg_alloc
	media: v4l2-mem2mem: fix a memleak in v4l2_m2m_register_entity
	media: edia: dvbdev: fix a use-after-free
	pinctrl: mediatek: Drop bogus slew rate register range for MT8192
	clk: qcom: reset: Commonize the de/assert functions
	clk: qcom: reset: Ensure write completion on reset de/assertion
	quota: simplify drop_dquot_ref()
	quota: Fix potential NULL pointer dereference
	quota: Fix rcu annotations of inode dquot pointers
	PCI: switchtec: Fix an error handling path in switchtec_pci_probe()
	crypto: xilinx - call finalize with bh disabled
	perf thread_map: Free strlist on normal path in thread_map__new_by_tid_str()
	drm/radeon/ni: Fix wrong firmware size logging in ni_init_microcode()
	ALSA: seq: fix function cast warnings
	perf stat: Avoid metric-only segv
	ASoC: meson: Use dev_err_probe() helper
	ASoC: meson: aiu: fix function pointer type mismatch
	ASoC: meson: t9015: fix function pointer type mismatch
	media: sun8i-di: Fix coefficient writes
	media: sun8i-di: Fix power on/off sequences
	media: sun8i-di: Fix chroma difference threshold
	media: imx: csc/scaler: fix v4l2_ctrl_handler memory leak
	media: go7007: add check of return value of go7007_read_addr()
	media: pvrusb2: remove redundant NULL check
	media: pvrusb2: fix pvr2_stream_callback casts
	clk: qcom: dispcc-sdm845: Adjust internal GDSC wait times
	drm/mediatek: dsi: Fix DSI RGB666 formats and definitions
	PCI: Mark 3ware-9650SE Root Port Extended Tags as broken
	clk: hisilicon: hi3519: Release the correct number of gates in hi3519_clk_unregister()
	drm/tegra: put drm_gem_object ref on error in tegra_fb_create
	mfd: syscon: Call of_node_put() only when of_parse_phandle() takes a ref
	mfd: altera-sysmgr: Call of_node_put() only when of_parse_phandle() takes a ref
	crypto: arm/sha - fix function cast warnings
	drm/tidss: Fix initial plane zpos values
	mtd: maps: physmap-core: fix flash size larger than 32-bit
	mtd: rawnand: lpc32xx_mlc: fix irq handler prototype
	ASoC: meson: axg-tdm-interface: fix mclk setup without mclk-fs
	ASoC: meson: axg-tdm-interface: add frame rate constraint
	drm/amdgpu: Fix missing break in ATOM_ARG_IMM Case of atom_get_src_int()
	media: pvrusb2: fix uaf in pvr2_context_set_notify
	media: dvb-frontends: avoid stack overflow warnings with clang
	media: go7007: fix a memleak in go7007_load_encoder
	media: ttpci: fix two memleaks in budget_av_attach
	media: mediatek: vcodec: avoid -Wcast-function-type-strict warning
	drm/mediatek: Fix a null pointer crash in mtk_drm_crtc_finish_page_flip
	powerpc/hv-gpci: Fix the H_GET_PERF_COUNTER_INFO hcall return value checks
	drm/msm/dpu: add division of drm_display_mode's hskew parameter
	powerpc/embedded6xx: Fix no previous prototype for avr_uart_send() etc.
	leds: aw2013: Unlock mutex before destroying it
	leds: sgm3140: Add missing timer cleanup and flash gpio control
	backlight: lm3630a: Initialize backlight_properties on init
	backlight: lm3630a: Don't set bl->props.brightness in get_brightness
	backlight: da9052: Fully initialize backlight_properties during probe
	backlight: lm3639: Fully initialize backlight_properties during probe
	backlight: lp8788: Fully initialize backlight_properties during probe
	sparc32: Fix section mismatch in leon_pci_grpci
	clk: Fix clk_core_get NULL dereference
	ALSA: hda/realtek: fix ALC285 issues on HP Envy x360 laptops
	ALSA: usb-audio: Stop parsing channels bits when all channels are found.
	RDMA/srpt: Do not register event handler until srpt device is fully setup
	f2fs: compress: fix to check unreleased compressed cluster
	scsi: csiostor: Avoid function pointer casts
	RDMA/device: Fix a race between mad_client and cm_client init
	scsi: bfa: Fix function pointer type mismatch for hcb_qe->cbfn
	net: sunrpc: Fix an off by one in rpc_sockaddr2uaddr()
	NFSv4.2: fix nfs4_listxattr kernel BUG at mm/usercopy.c:102
	NFSv4.2: fix listxattr maximum XDR buffer size
	watchdog: stm32_iwdg: initialize default timeout
	NFS: Fix an off by one in root_nfs_cat()
	afs: Revert "afs: Hide silly-rename files from userspace"
	remoteproc: stm32: Constify st_rproc_ops
	remoteproc: Add new get_loaded_rsc_table() to rproc_ops
	remoteproc: stm32: Move resource table setup to rproc_ops
	remoteproc: stm32: use correct format strings on 64-bit
	remoteproc: stm32: Fix incorrect type in assignment for va
	remoteproc: stm32: Fix incorrect type assignment returned by stm32_rproc_get_loaded_rsc_tablef
	tty: vt: fix 20 vs 0x20 typo in EScsiignore
	serial: max310x: fix syntax error in IRQ error message
	tty: serial: samsung: fix tx_empty() to return TIOCSER_TEMT
	kconfig: fix infinite loop when expanding a macro at the end of file
	rtc: mt6397: select IRQ_DOMAIN instead of depending on it
	serial: 8250_exar: Don't remove GPIO device on suspend
	staging: greybus: fix get_channel_from_mode() failure path
	usb: gadget: net2272: Use irqflags in the call to net2272_probe_fin
	io_uring: don't save/restore iowait state
	octeontx2-af: Use matching wake_up API variant in CGX command interface
	s390/vtime: fix average steal time calculation
	soc: fsl: dpio: fix kcalloc() argument order
	hsr: Fix uninit-value access in hsr_get_node()
	packet: annotate data-races around ignore_outgoing
	net: dsa: mt7530: prevent possible incorrect XTAL frequency selection
	wireguard: receive: annotate data-race around receiving_counter.counter
	rds: introduce acquire/release ordering in acquire/release_in_xmit()
	hsr: Handle failures in module init
	net/bnx2x: Prevent access to a freed page in page_pool
	octeontx2-af: Use separate handlers for interrupts
	netfilter: nft_set_pipapo: release elements in clone only from destroy path
	scsi: fc: Update formal FPIN descriptor definitions
	ARM: dts: sun8i-h2-plus-bananapi-m2-zero: add regulator nodes vcc-dram and vcc1v2
	netfilter: nf_tables: do not compare internal table flags on updates
	rcu: add a helper to report consolidated flavor QS
	bpf: report RCU QS in cpumap kthread
	spi: spi-mt65xx: Fix NULL pointer access in interrupt handler
	regmap: Add missing map->bus check
	remoteproc: stm32: fix phys_addr_t format string
	Linux 5.10.214

Change-Id: Iad0cc6acbf53bac96c0409ce61dc6836d83ed7bc
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
2024-05-15 16:03:24 +00:00
Roman Smirnov
b0cb5564c3 block: prevent division by zero in blk_rq_stat_sum()
[ Upstream commit 93f52fbeaf4b676b21acfe42a5152620e6770d02 ]

The expression dst->nr_samples + src->nr_samples may
have zero value on overflow. It is necessary to add
a check to avoid division by zero.

Found by Linux Verification Center (linuxtesting.org) with Svace.

Signed-off-by: Roman Smirnov <r.smirnov@omp.ru>
Reviewed-by: Sergey Shtylyov <s.shtylyov@omp.ru>
Link: https://lore.kernel.org/r/20240305134509.23108-1-r.smirnov@omp.ru
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-04-13 12:59:49 +02:00
Min Li
8f6dfa1f1e block: add check that partition length needs to be aligned with block size
commit 6f64f866aa1ae6975c95d805ed51d7e9433a0016 upstream.

Before calling add partition or resize partition, there is no check
on whether the length is aligned with the logical block size.
If the logical block size of the disk is larger than 512 bytes,
then the partition size maybe not the multiple of the logical block size,
and when the last sector is read, bio_truncate() will adjust the bio size,
resulting in an IO error if the size of the read command is smaller than
the logical block size.If integrity data is supported, this will also
result in a null pointer dereference when calling bio_integrity_free.

Cc:  <stable@vger.kernel.org>
Signed-off-by: Min Li <min15.li@samsung.com>
Reviewed-by: Damien Le Moal <dlemoal@kernel.org>
Reviewed-by: Chaitanya Kulkarni <kch@nvidia.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Link: https://lore.kernel.org/r/20230629142517.121241-1-min15.li@samsung.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Ashwin Dayanand Kamat <ashwin.kamat@broadcom.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2024-04-13 12:59:23 +02:00
Damien Le Moal
96661f8c3d block: Clear zone limits for a non-zoned stacked queue
[ Upstream commit c8f6f88d25929ad2f290b428efcae3b526f3eab0 ]

Device mapper may create a non-zoned mapped device out of a zoned device
(e.g., the dm-zoned target). In such case, some queue limit such as the
max_zone_append_sectors and zone_write_granularity endup being non zero
values for a block device that is not zoned. Avoid this by clearing
these limits in blk_stack_limits() when the stacked zoned limit is
false.

Fixes: 3093a47972 ("block: inherit the zoned characteristics in blk_stack_limits")
Cc: stable@vger.kernel.org
Signed-off-by: Damien Le Moal <dlemoal@kernel.org>
Link: https://lore.kernel.org/r/20240222131724.1803520-1-dlemoal@kernel.org
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-04-13 12:58:07 +02:00
Damien Le Moal
6b4bb49e34 block: introduce zone_write_granularity limit
[ Upstream commit a805a4fa4fa376bbc145762bb8b09caa2fa8af48 ]

Per ZBC and ZAC specifications, host-managed SMR hard-disks mandate that
all writes into sequential write required zones be aligned to the device
physical block size. However, NVMe ZNS does not have this constraint and
allows write operations into sequential zones to be aligned to the
device logical block size. This inconsistency does not help with
software portability across device types.

To solve this, introduce the zone_write_granularity queue limit to
indicate the alignment constraint, in bytes, of write operations into
zones of a zoned block device. This new limit is exported as a
read-only sysfs queue attribute and the helper
blk_queue_zone_write_granularity() introduced for drivers to set this
limit.

The function blk_queue_set_zoned() is modified to set this new limit to
the device logical block size by default. NVMe ZNS devices as well as
zoned nullb devices use this default value as is. The scsi disk driver
is modified to execute the blk_queue_zone_write_granularity() helper to
set the zone write granularity of host-managed SMR disks to the disk
physical block size.

The accessor functions queue_zone_write_granularity() and
bdev_zone_write_granularity() are also introduced.

Signed-off-by: Damien Le Moal <damien.lemoal@wdc.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Martin K. Petersen <martin.petersen@oracle.com>
Reviewed-by: Chaitanya Kulkarni <chaitanya.kulkarni@wdc.com>
Reviewed-by: Johannes Thumshirn <johannes.thumshirn@edc.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Stable-dep-of: c8f6f88d2592 ("block: Clear zone limits for a non-zoned stacked queue")
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-04-13 12:58:07 +02:00
Greg Kroah-Hartman
66e91da883 This is the 5.10.210 stable release
-----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCAAdFiEEZH8oZUiU471FcZm+ONu9yGCSaT4FAmXYTLkACgkQONu9yGCS
 aT4+fhAAqqR/Cvx53ZKMQ8GZTCudAZnr/Dz6kWYwxhhhIbQjDpCaf9mgsrEDaQS2
 ancSZjzYaOUIXq/IsthXxQIUhiZbuM3iuSEi7+odWgSYdkFyzuUt8MWLBGSaB5Er
 ojn+APtq7vPXTSnp7uMwqMC3/BHCKkeYIjRVevhhHBKG5d3lzkV1xU8NcvMkLaly
 CIRxpWXD3w2b7K0GEbb/zN1GQEHDCQcxjuaJoe/5FKGJkqd3T31eyiJTRumCCMcz
 j8vkGkYmcMJpWf04iLgVA1p13I5/HGrXdEBI/GutN8IABIC3Cp42jW8phHYKW5ZM
 a4R25LZG5buND1Ubpq+EDrYn3EaPek5XRki0w8ZAXfNa3rYc+N6mQjkzNSOzhJ/5
 VNsn3EAE1Dwtar5Z3ASe9ugDbh+0bgx85PbfaADK88V+qWb3DVr1TBWmDNu2vfVP
 rv4I0EKu9r3vOE8aNMEBuhAVkIK3mEQUxwab6RKNrMby/5Uwa+ugrrUtQd8V+T1S
 j6r6v7u7aZ8mhYO7d6WSvAKL85lCWGbs3WRIKCJZmDRyqWrWW9tVWRN9wrZ2QnRr
 iaCQKk8P474P7/j1zwnmih8l4wS1oszveNziWwd0fi1Nn/WQYM+JKYQvpuQijmQ+
 J9jLyWo7a59zffIE6mzJdNwFy9hlw9X+VnJmExk/Q88Z7Bt5wPQ=
 =laYd
 -----END PGP SIGNATURE-----

Merge 5.10.210 into android12-5.10-lts

Changes in 5.10.210
	usb: cdns3: Fixes for sparse warnings
	usb: cdns3: fix uvc failure work since sg support enabled
	usb: cdns3: fix incorrect calculation of ep_buf_size when more than one config
	usb: cdns3: fix iso transfer error when mult is not zero
	usb: cdns3: Fix uvc fail when DMA cross 4k boundery since sg enabled
	PCI: mediatek: Clear interrupt status before dispatching handler
	units: change from 'L' to 'UL'
	units: add the HZ macros
	serial: sc16is7xx: set safe default SPI clock frequency
	spi: introduce SPI_MODE_X_MASK macro
	serial: sc16is7xx: add check for unsupported SPI modes during probe
	iio: adc: ad7091r: Set alert bit in config register
	iio: adc: ad7091r: Allow users to configure device events
	iio: adc: ad7091r: Enable internal vref if external vref is not supplied
	dmaengine: fix NULL pointer in channel unregistration function
	iio:adc:ad7091r: Move exports into IIO_AD7091R namespace.
	ext4: allow for the last group to be marked as trimmed
	crypto: api - Disallow identical driver names
	PM: hibernate: Enforce ordering during image compression/decompression
	hwrng: core - Fix page fault dead lock on mmap-ed hwrng
	crypto: s390/aes - Fix buffer overread in CTR mode
	rpmsg: virtio: Free driver_override when rpmsg_remove()
	bus: mhi: host: Drop chan lock before queuing buffers
	parisc/firmware: Fix F-extend for PDC addresses
	async: Split async_schedule_node_domain()
	async: Introduce async_schedule_dev_nocall()
	arm64: dts: qcom: sdm845: fix USB wakeup interrupt types
	arm64: dts: qcom: sdm845: fix USB DP/DM HS PHY interrupts
	lsm: new security_file_ioctl_compat() hook
	scripts/get_abi: fix source path leak
	mmc: core: Use mrq.sbc in close-ended ffu
	mmc: mmc_spi: remove custom DMA mapped buffers
	rtc: Adjust failure return code for cmos_set_alarm()
	nouveau/vmm: don't set addr on the fail path to avoid warning
	ubifs: ubifs_symlink: Fix memleak of inode->i_link in error path
	rename(): fix the locking of subdirectories
	block: Remove special-casing of compound pages
	stddef: Introduce DECLARE_FLEX_ARRAY() helper
	smb3: Replace smb2pdu 1-element arrays with flex-arrays
	mm: vmalloc: introduce array allocation functions
	KVM: use __vcalloc for very large allocations
	net/smc: fix illegal rmb_desc access in SMC-D connection dump
	tcp: make sure init the accept_queue's spinlocks once
	bnxt_en: Wait for FLR to complete during probe
	vlan: skip nested type that is not IFLA_VLAN_QOS_MAPPING
	llc: make llc_ui_sendmsg() more robust against bonding changes
	llc: Drop support for ETH_P_TR_802_2.
	net/rds: Fix UBSAN: array-index-out-of-bounds in rds_cmsg_recv
	tracing: Ensure visibility when inserting an element into tracing_map
	afs: Hide silly-rename files from userspace
	tcp: Add memory barrier to tcp_push()
	netlink: fix potential sleeping issue in mqueue_flush_file
	ipv6: init the accept_queue's spinlocks in inet6_create
	net/mlx5: DR, Use the right GVMI number for drop action
	net/mlx5e: fix a double-free in arfs_create_groups
	netfilter: nf_tables: restrict anonymous set and map names to 16 bytes
	netfilter: nf_tables: validate NFPROTO_* family
	net: mvpp2: clear BM pool before initialization
	selftests: netdevsim: fix the udp_tunnel_nic test
	fjes: fix memleaks in fjes_hw_setup
	net: fec: fix the unhandled context fault from smmu
	btrfs: ref-verify: free ref cache before clearing mount opt
	btrfs: tree-checker: fix inline ref size in error messages
	btrfs: don't warn if discard range is not aligned to sector
	btrfs: defrag: reject unknown flags of btrfs_ioctl_defrag_range_args
	btrfs: don't abort filesystem when attempting to snapshot deleted subvolume
	rbd: don't move requests to the running list on errors
	exec: Fix error handling in begin_new_exec()
	wifi: iwlwifi: fix a memory corruption
	netfilter: nft_chain_filter: handle NETDEV_UNREGISTER for inet/ingress basechain
	netfilter: nf_tables: reject QUEUE/DROP verdict parameters
	gpiolib: acpi: Ignore touchpad wakeup on GPD G1619-04
	drm: Don't unref the same fb many times by mistake due to deadlock handling
	drm/bridge: nxp-ptn3460: fix i2c_master_send() error checking
	drm/tidss: Fix atomic_flush check
	drm/bridge: nxp-ptn3460: simplify some error checking
	PM: sleep: Use dev_printk() when possible
	PM: sleep: Avoid calling put_device() under dpm_list_mtx
	PM: core: Remove unnecessary (void *) conversions
	PM: sleep: Fix possible deadlocks in core system-wide PM code
	fs/pipe: move check to pipe_has_watch_queue()
	pipe: wakeup wr_wait after setting max_usage
	ARM: dts: samsung: exynos4210-i9100: Unconditionally enable LDO12
	arm64: dts: qcom: sc7180: Use pdc interrupts for USB instead of GIC interrupts
	arm64: dts: qcom: sc7180: fix USB wakeup interrupt types
	media: mtk-jpeg: Fix use after free bug due to error path handling in mtk_jpeg_dec_device_run
	mm: use __pfn_to_section() instead of open coding it
	mm/sparsemem: fix race in accessing memory_section->usage
	btrfs: remove err variable from btrfs_delete_subvolume
	btrfs: avoid copying BTRFS_ROOT_SUBVOL_DEAD flag to snapshot of subvolume being deleted
	drm: panel-simple: add missing bus flags for Tianma tm070jvhg[30/33]
	drm/exynos: fix accidental on-stack copy of exynos_drm_plane
	drm/exynos: gsc: minor fix for loop iteration in gsc_runtime_resume
	gpio: eic-sprd: Clear interrupt after set the interrupt type
	spi: bcm-qspi: fix SFDP BFPT read by usig mspi read
	mips: Call lose_fpu(0) before initializing fcr31 in mips_set_personality_nan
	tick/sched: Preserve number of idle sleeps across CPU hotplug events
	x86/entry/ia32: Ensure s32 is sign extended to s64
	powerpc/mm: Fix null-pointer dereference in pgtable_cache_add
	drivers/perf: pmuv3: don't expose SW_INCR event in sysfs
	powerpc: Fix build error due to is_valid_bugaddr()
	powerpc/mm: Fix build failures due to arch_reserved_kernel_pages()
	x86/boot: Ignore NMIs during very early boot
	powerpc: pmd_move_must_withdraw() is only needed for CONFIG_TRANSPARENT_HUGEPAGE
	powerpc/lib: Validate size for vector operations
	x86/mce: Mark fatal MCE's page as poison to avoid panic in the kdump kernel
	perf/core: Fix narrow startup race when creating the perf nr_addr_filters sysfs file
	debugobjects: Stop accessing objects after releasing hash bucket lock
	regulator: core: Only increment use_count when enable_count changes
	audit: Send netlink ACK before setting connection in auditd_set
	ACPI: video: Add quirk for the Colorful X15 AT 23 Laptop
	PNP: ACPI: fix fortify warning
	ACPI: extlog: fix NULL pointer dereference check
	PM / devfreq: Synchronize devfreq_monitor_[start/stop]
	ACPI: APEI: set memory failure flags as MF_ACTION_REQUIRED on synchronous events
	FS:JFS:UBSAN:array-index-out-of-bounds in dbAdjTree
	UBSAN: array-index-out-of-bounds in dtSplitRoot
	jfs: fix slab-out-of-bounds Read in dtSearch
	jfs: fix array-index-out-of-bounds in dbAdjTree
	jfs: fix uaf in jfs_evict_inode
	pstore/ram: Fix crash when setting number of cpus to an odd number
	crypto: stm32/crc32 - fix parsing list of devices
	afs: fix the usage of read_seqbegin_or_lock() in afs_lookup_volume_rcu()
	afs: fix the usage of read_seqbegin_or_lock() in afs_find_server*()
	rxrpc_find_service_conn_rcu: fix the usage of read_seqbegin_or_lock()
	jfs: fix array-index-out-of-bounds in diNewExt
	s390/ptrace: handle setting of fpc register correctly
	KVM: s390: fix setting of fpc register
	SUNRPC: Fix a suspicious RCU usage warning
	ecryptfs: Reject casefold directory inodes
	ext4: fix inconsistent between segment fstrim and full fstrim
	ext4: unify the type of flexbg_size to unsigned int
	ext4: remove unnecessary check from alloc_flex_gd()
	ext4: avoid online resizing failures due to oversized flex bg
	wifi: rt2x00: restart beacon queue when hardware reset
	selftests/bpf: satisfy compiler by having explicit return in btf test
	selftests/bpf: Fix pyperf180 compilation failure with clang18
	scsi: lpfc: Fix possible file string name overflow when updating firmware
	PCI: Add no PM reset quirk for NVIDIA Spectrum devices
	bonding: return -ENOMEM instead of BUG in alb_upper_dev_walk
	scsi: arcmsr: Support new PCI device IDs 1883 and 1886
	ARM: dts: imx7d: Fix coresight funnel ports
	ARM: dts: imx7s: Fix lcdif compatible
	ARM: dts: imx7s: Fix nand-controller #size-cells
	wifi: ath9k: Fix potential array-index-out-of-bounds read in ath9k_htc_txstatus()
	bpf: Add map and need_defer parameters to .map_fd_put_ptr()
	scsi: libfc: Don't schedule abort twice
	scsi: libfc: Fix up timeout error in fc_fcp_rec_error()
	bpf: Set uattr->batch.count as zero before batched update or deletion
	ARM: dts: rockchip: fix rk3036 hdmi ports node
	ARM: dts: imx25/27-eukrea: Fix RTC node name
	ARM: dts: imx: Use flash@0,0 pattern
	ARM: dts: imx27: Fix sram node
	ARM: dts: imx1: Fix sram node
	ionic: pass opcode to devcmd_wait
	block/rnbd-srv: Check for unlikely string overflow
	ARM: dts: imx25: Fix the iim compatible string
	ARM: dts: imx25/27: Pass timing0
	ARM: dts: imx27-apf27dev: Fix LED name
	ARM: dts: imx23-sansa: Use preferred i2c-gpios properties
	ARM: dts: imx23/28: Fix the DMA controller node name
	net: dsa: mv88e6xxx: Fix mv88e6352_serdes_get_stats error path
	block: prevent an integer overflow in bvec_try_merge_hw_page
	md: Whenassemble the array, consult the superblock of the freshest device
	arm64: dts: qcom: msm8996: Fix 'in-ports' is a required property
	arm64: dts: qcom: msm8998: Fix 'out-ports' is a required property
	wifi: rtl8xxxu: Add additional USB IDs for RTL8192EU devices
	wifi: rtlwifi: rtl8723{be,ae}: using calculate_bit_shift()
	wifi: cfg80211: free beacon_ies when overridden from hidden BSS
	Bluetooth: qca: Set both WIDEBAND_SPEECH and LE_STATES quirks for QCA2066
	Bluetooth: L2CAP: Fix possible multiple reject send
	i40e: Fix VF disable behavior to block all traffic
	f2fs: fix to check return value of f2fs_reserve_new_block()
	ALSA: hda: Refer to correct stream index at loops
	ASoC: doc: Fix undefined SND_SOC_DAPM_NOPM argument
	fast_dput(): handle underflows gracefully
	RDMA/IPoIB: Fix error code return in ipoib_mcast_join
	drm/amd/display: Fix tiled display misalignment
	f2fs: fix write pointers on zoned device after roll forward
	drm/drm_file: fix use of uninitialized variable
	drm/framebuffer: Fix use of uninitialized variable
	drm/mipi-dsi: Fix detach call without attach
	media: stk1160: Fixed high volume of stk1160_dbg messages
	media: rockchip: rga: fix swizzling for RGB formats
	PCI: add INTEL_HDA_ARL to pci_ids.h
	ALSA: hda: Intel: add HDA_ARL PCI ID support
	ALSA: hda: intel-dspcfg: add filters for ARL-S and ARL
	drm/exynos: Call drm_atomic_helper_shutdown() at shutdown/unbind time
	IB/ipoib: Fix mcast list locking
	media: ddbridge: fix an error code problem in ddb_probe
	drm/msm/dpu: Ratelimit framedone timeout msgs
	clk: hi3620: Fix memory leak in hi3620_mmc_clk_init()
	clk: mmp: pxa168: Fix memory leak in pxa168_clk_init()
	watchdog: it87_wdt: Keep WDTCTRL bit 3 unmodified for IT8784/IT8786
	drm/amdgpu: Let KFD sync with VM fences
	drm/amdgpu: Drop 'fence' check in 'to_amdgpu_amdkfd_fence()'
	leds: trigger: panic: Don't register panic notifier if creating the trigger failed
	um: Fix naming clash between UML and scheduler
	um: Don't use vfprintf() for os_info()
	um: net: Fix return type of uml_net_start_xmit()
	i3c: master: cdns: Update maximum prescaler value for i2c clock
	xen/gntdev: Fix the abuse of underlying struct page in DMA-buf import
	mfd: ti_am335x_tscadc: Fix TI SoC dependencies
	PCI: Only override AMD USB controller if required
	PCI: switchtec: Fix stdev_release() crash after surprise hot remove
	usb: hub: Replace hardcoded quirk value with BIT() macro
	tty: allow TIOCSLCKTRMIOS with CAP_CHECKPOINT_RESTORE
	fs/kernfs/dir: obey S_ISGID
	PCI/AER: Decode Requester ID when no error info found
	libsubcmd: Fix memory leak in uniq()
	virtio_net: Fix "‘%d’ directive writing between 1 and 11 bytes into a region of size 10" warnings
	blk-mq: fix IO hang from sbitmap wakeup race
	ceph: fix deadlock or deadcode of misusing dget()
	drm/amd/powerplay: Fix kzalloc parameter 'ATOM_Tonga_PPM_Table' in 'get_platform_power_management_table()'
	drm/amdgpu: Release 'adev->pm.fw' before return in 'amdgpu_device_need_post()'
	perf: Fix the nr_addr_filters fix
	wifi: cfg80211: fix RCU dereference in __cfg80211_bss_update
	drm: using mul_u32_u32() requires linux/math64.h
	scsi: isci: Fix an error code problem in isci_io_request_build()
	scsi: core: Introduce enum scsi_disposition
	scsi: core: Move scsi_host_busy() out of host lock for waking up EH handler
	ip6_tunnel: use dev_sw_netstats_rx_add()
	ip6_tunnel: make sure to pull inner header in __ip6_tnl_rcv()
	net-zerocopy: Refactor frag-is-remappable test.
	tcp: add sanity checks to rx zerocopy
	ixgbe: Remove non-inclusive language
	ixgbe: Refactor returning internal error codes
	ixgbe: Refactor overtemp event handling
	ixgbe: Fix an error handling path in ixgbe_read_iosf_sb_reg_x550()
	ipv6: Ensure natural alignment of const ipv6 loopback and router addresses
	llc: call sock_orphan() at release time
	netfilter: nf_log: replace BUG_ON by WARN_ON_ONCE when putting logger
	netfilter: nft_ct: sanitize layer 3 and 4 protocol number in custom expectations
	net: ipv4: fix a memleak in ip_setup_cork
	af_unix: fix lockdep positive in sk_diag_dump_icons()
	net: sysfs: Fix /sys/class/net/<iface> path
	HID: apple: Add support for the 2021 Magic Keyboard
	HID: apple: Add 2021 magic keyboard FN key mapping
	bonding: remove print in bond_verify_device_path
	uapi: stddef.h: Fix __DECLARE_FLEX_ARRAY for C++
	PM: sleep: Fix error handling in dpm_prepare()
	dmaengine: fsl-dpaa2-qdma: Fix the size of dma pools
	dmaengine: ti: k3-udma: Report short packet errors
	dmaengine: fsl-qdma: Fix a memory leak related to the status queue DMA
	dmaengine: fsl-qdma: Fix a memory leak related to the queue command DMA
	phy: renesas: rcar-gen3-usb2: Fix returning wrong error code
	dmaengine: fix is_slave_direction() return false when DMA_DEV_TO_DEV
	phy: ti: phy-omap-usb2: Fix NULL pointer dereference for SRP
	drm/msm/dp: return correct Colorimetry for DP_TEST_DYNAMIC_RANGE_CEA case
	net: stmmac: xgmac: fix handling of DPP safety error for DMA channels
	selftests: net: avoid just another constant wait
	tunnels: fix out of bounds access when building IPv6 PMTU error
	atm: idt77252: fix a memleak in open_card_ubr0
	hwmon: (aspeed-pwm-tacho) mutex for tach reading
	hwmon: (coretemp) Fix out-of-bounds memory access
	hwmon: (coretemp) Fix bogus core_id to attr name mapping
	inet: read sk->sk_family once in inet_recv_error()
	rxrpc: Fix response to PING RESPONSE ACKs to a dead call
	tipc: Check the bearer type before calling tipc_udp_nl_bearer_add()
	ppp_async: limit MRU to 64K
	netfilter: nft_compat: reject unused compat flag
	netfilter: nft_compat: restrict match/target protocol to u16
	netfilter: nft_ct: reject direction for ct id
	netfilter: nft_set_pipapo: store index in scratch maps
	netfilter: nft_set_pipapo: add helper to release pcpu scratch area
	netfilter: nft_set_pipapo: remove scratch_aligned pointer
	scsi: core: Move scsi_host_busy() out of host lock if it is for per-command
	blk-iocost: Fix an UBSAN shift-out-of-bounds warning
	net/af_iucv: clean up a try_then_request_module()
	USB: serial: qcserial: add new usb-id for Dell Wireless DW5826e
	USB: serial: option: add Fibocom FM101-GL variant
	USB: serial: cp210x: add ID for IMST iM871A-USB
	usb: host: xhci-plat: Add support for XHCI_SG_TRB_CACHE_SIZE_QUIRK
	hrtimer: Report offline hrtimer enqueue
	Input: i8042 - fix strange behavior of touchpad on Clevo NS70PU
	Input: atkbd - skip ATKBD_CMD_SETLEDS when skipping ATKBD_CMD_GETID
	vhost: use kzalloc() instead of kmalloc() followed by memset()
	clocksource: Skip watchdog check for large watchdog intervals
	net: stmmac: xgmac: use #define for string constants
	net: stmmac: xgmac: fix a typo of register name in DPP safety handling
	netfilter: nft_set_rbtree: skip end interval element from gc
	btrfs: forbid creating subvol qgroups
	btrfs: do not ASSERT() if the newly created subvolume already got read
	btrfs: forbid deleting live subvol qgroup
	btrfs: send: return EOPNOTSUPP on unknown flags
	of: unittest: Fix compile in the non-dynamic case
	net: openvswitch: limit the number of recursions from action sets
	spi: ppc4xx: Drop write-only variable
	ASoC: rt5645: Fix deadlock in rt5645_jack_detect_work()
	net: sysfs: Fix /sys/class/net/<iface> path for statistics
	MIPS: Add 'memory' clobber to csum_ipv6_magic() inline assembler
	i40e: Fix waiting for queues of all VSIs to be disabled
	tracing/trigger: Fix to return error if failed to alloc snapshot
	mm/writeback: fix possible divide-by-zero in wb_dirty_limits(), again
	ALSA: hda/realtek: Fix the external mic not being recognised for Acer Swift 1 SF114-32
	ALSA: hda/realtek: Enable Mute LED on HP Laptop 14-fq0xxx
	HID: wacom: generic: Avoid reporting a serial of '0' to userspace
	HID: wacom: Do not register input devices until after hid_hw_start
	usb: ucsi_acpi: Fix command completion handling
	USB: hub: check for alternate port before enabling A_ALT_HNP_SUPPORT
	usb: f_mass_storage: forbid async queue when shutdown happen
	media: ir_toy: fix a memleak in irtoy_tx
	powerpc/kasan: Fix addr error caused by page alignment
	i2c: i801: Remove i801_set_block_buffer_mode
	i2c: i801: Fix block process call transactions
	modpost: trim leading spaces when processing source files list
	scsi: Revert "scsi: fcoe: Fix potential deadlock on &fip->ctlr_lock"
	lsm: fix the logic in security_inode_getsecctx()
	firewire: core: correct documentation of fw_csr_string() kernel API
	kbuild: Fix changing ELF file type for output of gen_btf for big endian
	nfc: nci: free rx_data_reassembly skb on NCI device cleanup
	net: hsr: remove WARN_ONCE() in send_hsr_supervision_frame()
	xen-netback: properly sync TX responses
	ALSA: hda/realtek: Enable headset mic on Vaio VJFE-ADL
	binder: signal epoll threads of self-work
	misc: fastrpc: Mark all sessions as invalid in cb_remove
	ext4: fix double-free of blocks due to wrong extents moved_len
	tracing: Fix wasted memory in saved_cmdlines logic
	staging: iio: ad5933: fix type mismatch regression
	iio: magnetometer: rm3100: add boundary check for the value read from RM3100_REG_TMRC
	iio: accel: bma400: Fix a compilation problem
	media: rc: bpf attach/detach requires write permission
	hv_netvsc: Fix race condition between netvsc_probe and netvsc_remove
	ring-buffer: Clean ring_buffer_poll_wait() error return
	serial: max310x: set default value when reading clock ready bit
	serial: max310x: improve crystal stable clock detection
	x86/Kconfig: Transmeta Crusoe is CPU family 5, not 6
	x86/mm/ident_map: Use gbpages only where full GB page should be mapped.
	mmc: slot-gpio: Allow non-sleeping GPIO ro
	ALSA: hda/conexant: Add quirk for SWS JS201D
	nilfs2: fix data corruption in dsync block recovery for small block sizes
	nilfs2: fix hang in nilfs_lookup_dirty_data_buffers()
	crypto: ccp - Fix null pointer dereference in __sev_platform_shutdown_locked
	nfp: use correct macro for LengthSelect in BAR config
	nfp: flower: prevent re-adding mac index for bonded port
	wifi: mac80211: reload info pointer in ieee80211_tx_dequeue()
	irqchip/irq-brcmstb-l2: Add write memory barrier before exit
	irqchip/gic-v3-its: Fix GICv4.1 VPE affinity update
	s390/qeth: Fix potential loss of L3-IP@ in case of network issues
	ceph: prevent use-after-free in encode_cap_msg()
	of: property: fix typo in io-channels
	can: j1939: Fix UAF in j1939_sk_match_filter during setsockopt(SO_J1939_FILTER)
	pmdomain: core: Move the unused cleanup to a _sync initcall
	tracing: Inform kmemleak of saved_cmdlines allocation
	Revert "md/raid5: Wait for MD_SB_CHANGE_PENDING in raid5d"
	bus: moxtet: Add spi device table
	PCI: dwc: endpoint: Fix dw_pcie_ep_raise_msix_irq() alignment support
	mips: Fix max_mapnr being uninitialized on early stages
	crypto: lib/mpi - Fix unexpected pointer access in mpi_ec_init
	serial: Add rs485_supported to uart_port
	serial: 8250_exar: Fill in rs485_supported
	serial: 8250_exar: Set missing rs485_supported flag
	scripts/decode_stacktrace.sh: silence stderr messages from addr2line/nm
	scripts/decode_stacktrace.sh: support old bash version
	scripts: decode_stacktrace: demangle Rust symbols
	scripts/decode_stacktrace.sh: optionally use LLVM utilities
	netfilter: ipset: fix performance regression in swap operation
	netfilter: ipset: Missing gc cancellations fixed
	hrtimer: Ignore slack time for RT tasks in schedule_hrtimeout_range()
	Revert "arm64: Stash shadow stack pointer in the task struct on interrupt"
	net: prevent mss overflow in skb_segment()
	sched/membarrier: reduce the ability to hammer on sys_membarrier
	nilfs2: fix potential bug in end_buffer_async_write
	nilfs2: replace WARN_ONs for invalid DAT metadata block requests
	dm: limit the number of targets and parameter size area
	PM: runtime: add devm_pm_runtime_enable helper
	PM: runtime: Have devm_pm_runtime_enable() handle pm_runtime_dont_use_autosuspend()
	drm/msm/dsi: Enable runtime PM
	netfilter: nf_tables: fix pointer math issue in nft_byteorder_eval()
	net: bcmgenet: Fix EEE implementation
	PCI: dwc: Fix a 64bit bug in dw_pcie_ep_raise_msix_irq()
	Linux 5.10.210

Change-Id: I5e7327f58dd6abd26ac2b1e328a81c1010d1147c
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
2024-04-10 07:10:03 +00:00
Christoph Hellwig
2a0f8202f7 block: add a new set_read_only method
[ Upstream commit e00adcadf3af7a8335026d71ab9f0e0a922191ac ]

Add a new method to allow for driver-specific processing when setting or
clearing the block device read-only state.  This allows to replace the
cumbersome and error-prone override of the whole ioctl implementation.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Stable-dep-of: 9674f54e41ff ("md: Don't clear MD_CLOSING when the raid is about to stop")
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-03-26 18:21:48 -04:00
Greg Joyce
87221877ed block: sed-opal: handle empty atoms when parsing response
[ Upstream commit 5429c8de56f6b2bd8f537df3a1e04e67b9c04282 ]

The SED Opal response parsing function response_parse() does not
handle the case of an empty atom in the response. This causes
the entry count to be too high and the response fails to be
parsed. Recognizing, but ignoring, empty atoms allows response
handling to succeed.

Signed-off-by: Greg Joyce <gjoyce@linux.ibm.com>
Link: https://lore.kernel.org/r/20240216210417.3526064-2-gjoyce@linux.ibm.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-03-26 18:21:46 -04:00
Zhiguo Niu
f91d081f60 UPSTREAM: block/mq-deadline: use correct way to throttling write requests
The original formula was inaccurate:
dd->async_depth = max(1UL, 3 * q->nr_requests / 4);

For write requests, when we assign a tags from sched_tags,
data->shallow_depth will be passed to sbitmap_find_bit,
see the following code:

nr = sbitmap_find_bit_in_word(&sb->map[index],
			min_t (unsigned int,
			__map_depth(sb, index),
			depth),
			alloc_hint, wrap);

The smaller of data->shallow_depth and __map_depth(sb, index)
will be used as the maximum range when allocating bits.

For a mmc device (one hw queue, deadline I/O scheduler):
q->nr_requests = sched_tags = 128, so according to the previous
calculation method, dd->async_depth = data->shallow_depth = 96,
and the platform is 64bits with 8 cpus, sched_tags.bitmap_tags.sb.shift=5,
sb.maps[]=32/32/32/32, 32 is smaller than 96, whether it is a read or
a write I/O, tags can be allocated to the maximum range each time,
which has not throttling effect.

In addition, refer to the methods of bfg/kyber I/O scheduler,
limit ratiois are calculated base on sched_tags.bitmap_tags.sb.shift.

This patch can throttle write requests really.

Fixes: 07757588e507 ("block/mq-deadline: Reserve 25% of scheduler tags for synchronous requests")

Bug: 254441685
Signed-off-by: Zhiguo Niu <zhiguo.niu@unisoc.com>
Reviewed-by: Bart Van Assche <bvanassche@acm.org>
Link: https://lore.kernel.org/r/1691061162-22898-1-git-send-email-zhiguo.niu@unisoc.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
(cherry picked from commit d47f9717e5cfd0dd8c0ba2ecfa47c38d140f1bb6)
Signed-off-by: Lee Jones <joneslee@google.com>
Change-Id: Ifa79a1b22f7b5c87675525aac81841abd62840a6
2024-03-13 13:35:31 +00:00
hao lv
94b9d8e513 ANDROID: add hooks into blk-mq-sched.c for customized I/O scheduler
android_vh_blk_mq_sched_insert_request: Add judgment on rq. If it is a
customized rq, it needs to be added to the corresponding customized
queue

Bug: 319582497

Change-Id: I2bf8fee37273b3495d60c64bb53e43debceb5614
Signed-off-by: hao lv <hao.lv5@transsion.com>
2024-02-29 08:43:13 +08:00
hao lv
6912e0c8e9 ANDROID: add hooks into blk-ma-tag.c for customized I/O scheduler
android_vh_blk_mq_all_tag_iter: The customized solution adds a new tag
type, so need to use the customized solution for traversal

android_vh_blk_mq_queue_tag_busy_iter: The customized solution adds a
new tag type, so need to use the customized solution for traversal

android_vh_blk_mq_free_tags: Release the customized tag

Bug: 319582497

Change-Id: I648a9a31c11c284a75653405b8f8521d9da34d20
Signed-off-by: hao lv <hao.lv5@transsion.com>
2024-02-29 08:43:05 +08:00
hao lv
f76294a655 ANDROID: add hooks into blk-flush.c for customized I/O scheduler
android_vh_blk_alloc_flush_queue: Expand the flush request size to carry
more customized information

Bug: 319582497

Change-Id: I728852bd29ff7f851545c52fbdeafa7cd3a4addf
Signed-off-by: hao lv <hao.lv5@transsion.com>
2024-02-29 08:42:57 +08:00
hao lv
d269992366 ANDROID: add hooks into blk-core.c for customized I/O scheduler
android_rvh_blk_allocated_queue_init: Allocate specific request_queue
information and save the pointer address in the ANDROID_OEM_DATA field.
The allocation process may be scheduled, so a restricted hook function
is used

android_rvh_blk_flush_plug_list: Flush the customized plug list. During
this process, the scheduled queue_rq will be called to process the
request, so a restricted hook function is used

Bug: 319582497

Change-Id: I0af3915de899b678ffd4f207cac2e35a744936b8
Signed-off-by: hao lv <hao.lv5@transsion.com>
2024-02-29 08:42:49 +08:00
hao lv
ccbc7f8808 ANDROID: add hooks into blk-mq.c for customized I/O scheduler.
Our scheduler uses the ANDROID_OEM_DATA field in the request_queue
structure to customize a set of ops operations for the request queue
applied by the ufs/emmc driver. Adopt fine-grained IO scheduling
strategies based on specific request types and user scenarios

android_rvh_internal_blk_mq_alloc_request: Obtain a new tag.
This process may be scheduled because the tag cannot be allocated
quickly, so a restricted hook is required.

android_vh_internal_blk_mq_free_request: Release individually allocated
tags

android_vh_blk_mq_complete_request: Record the time when the request was
completed

android_vh_blk_mq_add_to_requeue_list: Add requests to a separate
distribution queue

android_rvh_blk_mq_delay_run_hw_queue: The process of calling queue_rq
to handle the request may be scheduled, so restricted hooks need to be
used

android_vh_blk_mq_run_hw_queue: Set need_run to true

android_vh_blk_mq_insert_request: Insert the request into a customized
queue

android_rvh_blk_mq_alloc_rq_map: The process of assigning customized
tags may be scheduled, so restricted hooks need to be used

android_rvh_blk_mq_init_allocated_queue: The customized scheduler is
initialized and needs to allocate some resources. This process may be
scheduled, so restricted hooks need to be used

android_vh_blk_mq_exit_queue: Release resources allocated by the
customized scheduler

android_vh_blk_mq_alloc_tag_set: Get tagset information

Bug: 319582497

Change-Id: I2b16d69a1e7085a4f5f82660b75188c517b01894
Signed-off-by: hao lv <hao.lv5@transsion.com>
2024-02-29 08:42:35 +08:00
hao lv
34338029ab ANDROID: add hooks into bio.c for customized I/O scheduler
android_vh_bio_free: We have added some additional information to
each bio, which needs to be freed simultaneously when the bio is free

Bug: 319582497

Change-Id: I532f98fa0569f2eb8da66cff746349c828e0912c
Signed-off-by: hao lv <hao.lv5@transsion.com>
2024-02-29 08:42:22 +08:00
Tejun Heo
9f56f38331 blk-iocost: Fix an UBSAN shift-out-of-bounds warning
[ Upstream commit 2a427b49d02995ea4a6ff93a1432c40fa4d36821 ]

When iocg_kick_delay() is called from a CPU different than the one which set
the delay, @now may be in the past of @iocg->delay_at leading to the
following warning:

  UBSAN: shift-out-of-bounds in block/blk-iocost.c:1359:23
  shift exponent 18446744073709 is too large for 64-bit type 'u64' (aka 'unsigned long long')
  ...
  Call Trace:
   <TASK>
   dump_stack_lvl+0x79/0xc0
   __ubsan_handle_shift_out_of_bounds+0x2ab/0x300
   iocg_kick_delay+0x222/0x230
   ioc_rqos_merge+0x1d7/0x2c0
   __rq_qos_merge+0x2c/0x80
   bio_attempt_back_merge+0x83/0x190
   blk_attempt_plug_merge+0x101/0x150
   blk_mq_submit_bio+0x2b1/0x720
   submit_bio_noacct_nocheck+0x320/0x3e0
   __swap_writepage+0x2ab/0x9d0

The underflow itself doesn't really affect the behavior in any meaningful
way; however, the past timestamp may exaggerate the delay amount calculated
later in the code, which shouldn't be a material problem given the nature of
the delay mechanism.

If @now is in the past, this CPU is racing another CPU which recently set up
the delay and there's nothing this CPU can contribute w.r.t. the delay.
Let's bail early from iocg_kick_delay() in such cases.

Reported-by: Breno Leitão <leitao@debian.org>
Signed-off-by: Tejun Heo <tj@kernel.org>
Fixes: 5160a5a53c ("blk-iocost: implement delay adjustment hysteresis")
Link: https://lore.kernel.org/r/ZVvc9L_CYk5LO1fT@slm.duckdns.org
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-02-23 08:42:21 +01:00
Ming Lei
7610ba1319 blk-mq: fix IO hang from sbitmap wakeup race
[ Upstream commit 5266caaf5660529e3da53004b8b7174cab6374ed ]

In blk_mq_mark_tag_wait(), __add_wait_queue() may be re-ordered
with the following blk_mq_get_driver_tag() in case of getting driver
tag failure.

Then in __sbitmap_queue_wake_up(), waitqueue_active() may not observe
the added waiter in blk_mq_mark_tag_wait() and wake up nothing, meantime
blk_mq_mark_tag_wait() can't get driver tag successfully.

This issue can be reproduced by running the following test in loop, and
fio hang can be observed in < 30min when running it on my test VM
in laptop.

	modprobe -r scsi_debug
	modprobe scsi_debug delay=0 dev_size_mb=4096 max_queue=1 host_max_queue=1 submit_queues=4
	dev=`ls -d /sys/bus/pseudo/drivers/scsi_debug/adapter*/host*/target*/*/block/* | head -1 | xargs basename`
	fio --filename=/dev/"$dev" --direct=1 --rw=randrw --bs=4k --iodepth=1 \
       		--runtime=100 --numjobs=40 --time_based --name=test \
        	--ioengine=libaio

Fix the issue by adding one explicit barrier in blk_mq_mark_tag_wait(), which
is just fine in case of running out of tag.

Cc: Jan Kara <jack@suse.cz>
Cc: Kemeng Shi <shikemeng@huaweicloud.com>
Reported-by: Changhui Zhong <czhong@redhat.com>
Signed-off-by: Ming Lei <ming.lei@redhat.com>
Link: https://lore.kernel.org/r/20240112122626.4181044-1-ming.lei@redhat.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-02-23 08:42:14 +01:00
Christoph Hellwig
1746cd95a5 block: prevent an integer overflow in bvec_try_merge_hw_page
[ Upstream commit 3f034c374ad55773c12dd8f3c1607328e17c0072 ]

Reordered a check to avoid a possible overflow when adding len to bv_len.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Johannes Thumshirn <johannes.thumshirn@wdc.com>
Link: https://lore.kernel.org/r/20231204173419.782378-2-hch@lst.de
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-02-23 08:42:09 +01:00
Matthew Wilcox (Oracle)
bfc0647791 block: Remove special-casing of compound pages
commit 1b151e2435fc3a9b10c8946c6aebe9f3e1938c55 upstream.

The special casing was originally added in pre-git history; reproducing
the commit log here:

> commit a318a92567d77
> Author: Andrew Morton <akpm@osdl.org>
> Date:   Sun Sep 21 01:42:22 2003 -0700
>
>     [PATCH] Speed up direct-io hugetlbpage handling
>
>     This patch short-circuits all the direct-io page dirtying logic for
>     higher-order pages.  Without this, we pointlessly bounce BIOs up to
>     keventd all the time.

In the last twenty years, compound pages have become used for more than
just hugetlb.  Rewrite these functions to operate on folios instead
of pages and remove the special case for hugetlbfs; I don't think
it's needed any more (and if it is, we can put it back in as a call
to folio_test_hugetlb()).

This was found by inspection; as far as I can tell, this bug can lead
to pages used as the destination of a direct I/O read not being marked
as dirty.  If those pages are then reclaimed by the MM without being
dirtied for some other reason, they won't be written out.  Then when
they're faulted back in, they will not contain the data they should.
It'll take a pretty unusual setup to produce this problem with several
races all going the wrong way.

This problem predates the folio work; it could for example have been
triggered by mmaping a THP in tmpfs and using that as the target of an
O_DIRECT read.

Fixes: 800d8c63b2 ("shmem: add huge pages support")
Cc:  <stable@vger.kernel.org>
Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2024-02-23 08:41:54 +01:00
Greg Kroah-Hartman
b7733bafef This is the 5.10.205 stable release
-----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCAAdFiEEZH8oZUiU471FcZm+ONu9yGCSaT4FAmWC/gkACgkQONu9yGCS
 aT5O2hAA1RcHox8KatosKeBihzJnxqdMyfDIGpWQXQb4U3vjvVe8hboapJJHYidd
 yJgN29rgQUJNxa0hX/kE86QiH6UuellRrz9kkQawDcCt9wKS/8frusjwJPCvK+EC
 2rp08JAl3ZNr7vczO5t/H/uHBsCiP84m8USP7/e/7JX8I3OmSfgRfrMHc/ay0Brk
 JGpMITCGHuy5xFI8Tl8snG5aQ1KY06YcuSC4vutYzpEgCjCWJPhQAMb/t1vpQKRD
 Qt1F6zRTslZjlcabztjrQ71S7iBTW9Lx0wLSCN0VrkgishDl567ttHVO/knT6OLU
 VYsnr2z7i2nwvrooQ+pH7uJTyInEkf9CGNw69me0KrjZtcIWLliEOpCQlBN+fOl5
 zig4VzLQHlSo5mLo2WmLpnDQUXk1/nEb1DjSjYnKalV0tKpDm1HxgzNIAGCmEidD
 81+Q92eMot3rlWxgqL+ytapF1dfgGpt92H31fhQJP6uI/a7SRAUhUJqmP51r9mOJ
 F1LM2kd9lPCTYiJWpRj+6SKvNX5mmZAxV5hZ4JzmH4uIDWsV8DQEJve7TnI5KOm9
 KUuGhRGjQ7mNvtlNZUeS00uqijKBXg61xPKyXJb3Ph1GheLHPyXiVRlgGdItrbme
 TJUBa2b6zGAMqTPA2UMebTtnNtnejkH9CU7ojGoIG8AFvnPyhd0=
 =mybH
 -----END PGP SIGNATURE-----

Merge 5.10.205 into android12-5.10-lts

Changes in 5.10.205
	netfilter: nf_tables: fix 'exist' matching on bigendian arches
	afs: Fix refcount underflow from error handling race
	HID: lenovo: Restrict detection of patched firmware only to USB cptkbd
	net: ipv6: support reporting otherwise unknown prefix flags in RTM_NEWPREFIX
	qca_debug: Prevent crash on TX ring changes
	qca_debug: Fix ethtool -G iface tx behavior
	qca_spi: Fix reset behavior
	atm: solos-pci: Fix potential deadlock on &cli_queue_lock
	atm: solos-pci: Fix potential deadlock on &tx_queue_lock
	net: vlan: introduce skb_vlan_eth_hdr()
	net: fec: correct queue selection
	atm: Fix Use-After-Free in do_vcc_ioctl
	net/rose: Fix Use-After-Free in rose_ioctl
	qed: Fix a potential use-after-free in qed_cxt_tables_alloc
	net: Remove acked SYN flag from packet in the transmit queue correctly
	net: ena: Destroy correct number of xdp queues upon failure
	net: ena: Fix XDP redirection error
	sign-file: Fix incorrect return values check
	vsock/virtio: Fix unsigned integer wrap around in virtio_transport_has_space()
	net: stmmac: use dev_err_probe() for reporting mdio bus registration failure
	net: stmmac: Handle disabled MDIO busses from devicetree
	appletalk: Fix Use-After-Free in atalk_ioctl
	net: atlantic: fix double free in ring reinit logic
	cred: switch to using atomic_long_t
	fuse: dax: set fc->dax to NULL in fuse_dax_conn_free()
	ALSA: hda/hdmi: add force-connect quirks for ASUSTeK Z170 variants
	ALSA: hda/realtek: Apply mute LED quirk for HP15-db
	Revert "PCI: acpiphp: Reassign resources on bridge if necessary"
	PCI: loongson: Limit MRRS to 256
	drm/mediatek: Add spinlock for setting vblank event in atomic_begin
	usb: aqc111: check packet for fixup for true limit
	blk-throttle: fix lockdep warning of "cgroup_mutex or RCU read lock required!"
	bcache: avoid oversize memory allocation by small stripe_size
	bcache: remove redundant assignment to variable cur_idx
	bcache: add code comments for bch_btree_node_get() and __bch_btree_node_alloc()
	bcache: avoid NULL checking to c->root in run_cache_set()
	platform/x86: intel_telemetry: Fix kernel doc descriptions
	HID: glorious: fix Glorious Model I HID report
	HID: add ALWAYS_POLL quirk for Apple kb
	HID: hid-asus: reset the backlight brightness level on resume
	HID: multitouch: Add quirk for HONOR GLO-GXXX touchpad
	asm-generic: qspinlock: fix queued_spin_value_unlocked() implementation
	net: usb: qmi_wwan: claim interface 4 for ZTE MF290
	HID: hid-asus: add const to read-only outgoing usb buffer
	perf: Fix perf_event_validate_size() lockdep splat
	soundwire: stream: fix NULL pointer dereference for multi_link
	ext4: prevent the normalized size from exceeding EXT_MAX_BLOCKS
	arm64: mm: Always make sw-dirty PTEs hw-dirty in pte_modify
	team: Fix use-after-free when an option instance allocation fails
	ring-buffer: Fix memory leak of free page
	tracing: Update snapshot buffer on resize if it is allocated
	ring-buffer: Have saved event hold the entire event
	ring-buffer: Fix writing to the buffer with max_data_size
	ring-buffer: Fix a race in rb_time_cmpxchg() for 32 bit archs
	USB: gadget: core: adjust uevent timing on gadget unbind
	tty: n_gsm: fix tty registration before control channel open
	tty: n_gsm, remove duplicates of parameters
	tty: n_gsm: add sanity check for gsm->receive in gsm_receive_buf()
	powerpc/ftrace: Create a dummy stackframe to fix stack unwind
	powerpc/ftrace: Fix stack teardown in ftrace_no_trace
	Linux 5.10.205

Change-Id: I2471e112e6ed8bd85f0bf2812cb0a5bff2ac1bdd
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
2023-12-21 12:24:50 +00:00
Ming Lei
dbf0cdacdb blk-throttle: fix lockdep warning of "cgroup_mutex or RCU read lock required!"
[ Upstream commit 27b13e209ddca5979847a1b57890e0372c1edcee ]

Inside blkg_for_each_descendant_pre(), both
css_for_each_descendant_pre() and blkg_lookup() requires RCU read lock,
and either cgroup_assert_mutex_or_rcu_locked() or rcu_read_lock_held()
is called.

Fix the warning by adding rcu read lock.

Reported-by: Changhui Zhong <czhong@redhat.com>
Signed-off-by: Ming Lei <ming.lei@redhat.com>
Link: https://lore.kernel.org/r/20231117023527.3188627-2-ming.lei@redhat.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2023-12-20 15:44:31 +01:00
Greg Kroah-Hartman
04c980352b Merge branch 'android12-5.10' into branch 'android12-5.10-lts'
Catch up on a number of bugfixes and abi updates in the android12-5.10
branch.  This merge contains the following commits:

6af2483a2f BACKPORT: ravb: Fix use-after-free issue in ravb_tx_timeout_work()
d43bb6d288 UPSTREAM: ravb: Fix up dma_free_coherent() call in ravb_remove()
e6ddd6b656 UPSTREAM: netfilter: ipset: Fix race between IPSET_CMD_CREATE and IPSET_CMD_SWAP
e39ee80b1a UPSTREAM: net: xfrm: Fix xfrm_address_filter OOB read
40439d12b8 UPSTREAM: igb: set max size RX buffer when store bad packet is enabled
44ddc37b10 UPSTREAM: netfilter: nfnetlink_osf: avoid OOB read
ede2f9b7e5 ANDROID: abi_gki_aarch64_qcom: Add wait_for_device_probe symbol
db2f2cb88d UPSTREAM: netfilter: xt_sctp: validate the flag_info count
cba41df427 UPSTREAM: netfilter: xt_u32: validate user space input
4865c22b17 UPSTREAM: net/sched: Retire rsvp classifier
f8424e6555 UPSTREAM: ipv4: fix null-deref in ipv4_link_failure
cd7744312f UPSTREAM: netfilter: nf_tables: disallow rule removal from chain binding
6cd0cd3893 UPSTREAM: netfilter: nf_tables: report use refcount overflow
99d2841c81 UPSTREAM: usb: gadget: ncm: Handle decoding of multiple NTB's in unwrap call
3cf9365660 Merge tag 'android12-5.10.189_r00' into android12-5.10
785004172f ANDROID: ABI: Update oplus symbol list
d3961f624b ANDROID: vendor_hooks: Add hooks for oem percpu-rwsem optimaton
180ea0f6d4 UPSTREAM: net: sched: sch_qfq: Fix UAF in qfq_dequeue()
6b6202b762 UPSTREAM: net/sched: sch_hfsc: Ensure inner classes have fsc curve
ff86e87c7e FROMGIT: f2fs: split initial and dynamic conditions for extent_cache
e22810eb27 ANDROID: GKI:  Update moto symbols list
3718ea1e77 ANDROID: vendor_hook: Add hook to skip swapcache
909a83a97d ANDROID: GKI: Update symbols to symbol list
6356ed35b9 ANDROID: add vendor hook of add/delete/iterate node for swap_avail_heads
bd34b88730 UPSTREAM: tty: n_gsm: fix the UAF caused by race condition in gsm_cleanup_mux
7ba85ae103 UPSTREAM: netfilter: nf_tables: prevent OOB access in nft_byteorder_eval
9f68d2976a UPSTREAM: net/sched: sch_qfq: account for stab overhead in qfq_enqueue
88525fa7d9 ANDROID: GKI update xiaomi symbols list
1a6995cf14 UPSTREAM: af_unix: Fix null-ptr-deref in unix_stream_sendpage().
37d958fa88 UPSTREAM: USB: dwc3: fix use-after-free on core driver unbind
6388400ba5 UPSTREAM: xhci: Fix incorrect tracking of free space on transfer rings
bc78acae08 UPSTREAM: kfence: avoid passing -g for test
b3bad92280 UPSTREAM: coresight: etm4x: Do not access TRCIDR1 for identification
b155bf3086 UPSTREAM: usb: typec: tcpm: fix warning when handle discover_identity message
72a7bbb4a3 UPSTREAM: f2fs: fix to update age extent in f2fs_do_zero_range()
1e1986dd44 UPSTREAM: f2fs: fix to update age extent correctly during truncation
3e9ba88034 BACKPORT: f2fs: fix to do sanity check on extent cache correctly
e95427763f UPSTREAM: net/sched: sch_qfq: refactor parsing of netlink parameters
216e24b08c BACKPORT: f2fs: don't reset unchangable mount option in f2fs_remount()
a96eb7c2ca ANDROID: arm64: dts: qcom: sdm845-db845c: Do not point MDSS to the boot splash memory region
ad067abfe1 BACKPORT: net: nfc: Fix use-after-free caused by nfc_llcp_find_local
00c7bec87c ANDROID: ABI: Update oplus symbol list  ashmem: is_ashmem_file Export is_ashmem_file function which will be used by the minidump module to get ashmem info.
300d1ff660 ANDROID: GKI: Update abi_gki_aarch64_qcom for page_owner symbols
a9c0f62260 ANDROID: mm: Export page_owner_inited and __set_page_owner
d26e92d681 FROMGIT: pstore/ram: Check start of empty przs during init
966df87a17 UPSTREAM: exfat: check if filename entries exceeds max filename length
dcb17f36f3 BACKPORT: FROMGIT: netfilter: nfnetlink_log: always add a timestamp
a8b58500cb FROMGIT: arm64: dts: qcom: sdm845-db845c: Mark cont splash memory region as reserved
8001debfc1 UPSTREAM: media: usb: siano: Fix warning due to null work_func_t function pointer
8e682bb18a UPSTREAM: Bluetooth: L2CAP: Fix use-after-free in l2cap_sock_ready_cb
14ce45e3c7 ANDROID: ABI: Update oplus symbol list
98a66e87c1 ANDROID: Export symbols to do reverse mapping within memcg in kernel modules.
8af1bc5622 ANDROID: GKI: export symbols to modify lru stats
b019a989a2 UPSTREAM: net: tap_open(): set sk_uid from current_fsuid()
169c9f103f UPSTREAM: net: tun_chr_open(): set sk_uid from current_fsuid()
819a8605da UPSTREAM: netfilter: nf_tables: disallow rule addition to bound chain via NFTA_RULE_CHAIN_ID
f2545eebf0 BACKPORT: UPSTREAM: usb: dwc3: gadget: Execute gadget stop after halting the controller
6d38ae2f4c UPSTREAM: usb: dwc3: gadget: Stall and restart EP0 if host is unresponsive
6f01e099d8 UPSTREAM: net/sched: cls_route: No longer copy tcf_result on update to avoid use-after-free
0ebe76176b UPSTREAM: net/sched: cls_fw: No longer copy tcf_result on update to avoid use-after-free
45edbf4058 UPSTREAM: net/sched: cls_u32: No longer copy tcf_result on update to avoid use-after-free
e172f5cfc0 ANDROID: GKI: update xiaomi symbol list
28b82089b2 UPSTREAM: netfilter: nf_tables: skip bound chain on rule flush
bad8adda41 UPSTREAM: net/sched: cls_fw: Fix improper refcount update leads to use-after-free
84f8556570 UPSTREAM: tty: n_gsm: fix UAF in gsm_cleanup_mux
0fa8d8cd99 UPSTREAM: netfilter: nft_set_pipapo: fix improper element removal
6efa28db9a BACKPORT: FROMGIT: irqchip/gic-v3: Workaround for GIC-700 erratum 2941627
ec3f57af0a ANDROID: vendor_hook: fix the error record position of mutex
028e0fb3a4 FROMGIT: fs: drop_caches: draining pages before dropping caches
67f65c7764 ANDROID: GKI: Update symbols to symbol list
8e164a95fb ANDROID: GKI: Update symbols to symbol list
c4191be802 ANDROID: GKI: add symbol list file for moto
2427afff1e UPSTREAM: gfs2: Don't deref jdesc in evict
e933b7be1c UPSTREAM: media: dvb-core: Fix kernel WARNING for blocking operation in wait_event*()

Change-Id: I7b09cba3db8ae584fd0821bfbecf945e7d0bf9a4
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
2023-10-31 10:10:41 +00:00
Greg Kroah-Hartman
3e7bedcc0e This is the 5.10.198 stable release
-----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCAAdFiEEZH8oZUiU471FcZm+ONu9yGCSaT4FAmUlq8kACgkQONu9yGCS
 aT5GiA//fiURwpUcawIhvgYewMVp+ovJ+mpX5IT+bMbW9Ur0sBhtiiU+WDNYxMru
 34xbSQ/+o2a6N2tmK1JF7o76e2sHw/aRgaoDHkN5oEG+lbRH7TdCv6O0QRFAthcd
 sJL+SX/GclcKW0ZHDjJX9Wt5Lq3gqVYlqJlCsw6gI/1JrQTxStrSQh7yRbrYSqpY
 wGWEq19IrE/ToZFTBuPEEvlBswszGrI88lVtjvRzIdczQVyFLAoEQ2GNPWl3XNBh
 ygGnwiHjk3a+QhZ30evIv2LX+tlGmpLy7gdLDsdZF7RfEkNHQ92IgaHvFDs8JqDg
 QnRE8KCrC2V45OIQRRnA5NVtD3LBYM0bUhbqqLiNvTMiSIBWge4efJwxyYcTTfkX
 MTmbo9z/bIVFdpgCQtneRw3eUyfbRKQ1cUvtmkuXIVLzvZUQaVMpXVZ6pz864E54
 3nJrl2HJtIdJsRX5M4unL+AXNLRoJUbfb4hbzAD0Tg8Wbdgrn7vL/z6JmIzA2ssQ
 +R/52ghimOThGTUbCi2pJx/cpKhegkJEJ7+JwUhS9L9ybA93g/bD0n9zy6JXpd/H
 Cct0JWbiukbDp1CTLQ6Qm9TK5HANW2fXMHoR3H5ltPojNZwN7/pgYqN6ppjtBKVe
 gA3k8KYkZoXjbF6VS1B5Y83wJ+H+39Luk/DSmm1ZNvYPHxmz+q0=
 =2MQy
 -----END PGP SIGNATURE-----

Merge 5.10.198 into android12-5.10-lts

Changes in 5.10.198
	NFS: Use the correct commit info in nfs_join_page_group()
	NFS/pNFS: Report EINVAL errors from connect() to the server
	SUNRPC: Mark the cred for revalidation if the server rejects it
	tracing: Increase trace array ref count on enable and filter files
	ata: ahci: Drop pointless VPRINTK() calls and convert the remaining ones
	ata: libahci: clear pending interrupt status
	ext4: remove the 'group' parameter of ext4_trim_extent
	ext4: add new helper interface ext4_try_to_trim_range()
	ext4: scope ret locally in ext4_try_to_trim_range()
	ext4: change s_last_trim_minblks type to unsigned long
	ext4: mark group as trimmed only if it was fully scanned
	ext4: replace the traditional ternary conditional operator with with max()/min()
	ext4: move setting of trimmed bit into ext4_try_to_trim_range()
	ext4: do not let fstrim block system suspend
	tracing: Have event inject files inc the trace array ref count
	netfilter: nf_tables: integrate pipapo into commit protocol
	netfilter: nf_tables: don't skip expired elements during walk
	netfilter: nf_tables: GC transaction API to avoid race with control plane
	netfilter: nf_tables: adapt set backend to use GC transaction API
	netfilter: nft_set_hash: mark set element as dead when deleting from packet path
	netfilter: nf_tables: remove busy mark and gc batch API
	netfilter: nf_tables: don't fail inserts if duplicate has expired
	netfilter: nf_tables: fix GC transaction races with netns and netlink event exit path
	netfilter: nf_tables: GC transaction race with netns dismantle
	netfilter: nf_tables: GC transaction race with abort path
	netfilter: nf_tables: use correct lock to protect gc_list
	netfilter: nf_tables: defer gc run if previous batch is still pending
	netfilter: nft_set_rbtree: skip sync GC for new elements in this transaction
	netfilter: nft_set_rbtree: use read spinlock to avoid datapath contention
	netfilter: nft_set_pipapo: stop GC iteration if GC transaction allocation fails
	netfilter: nft_set_hash: try later when GC hits EAGAIN on iteration
	netfilter: nf_tables: fix memleak when more than 255 elements expired
	ASoC: meson: spdifin: start hw on dai probe
	netfilter: nf_tables: disallow element removal on anonymous sets
	bpf: Avoid deadlock when using queue and stack maps from NMI
	selftests/tls: Add {} to avoid static checker warning
	selftests: tls: swap the TX and RX sockets in some tests
	ASoC: imx-audmix: Fix return error with devm_clk_get()
	i40e: Fix VF VLAN offloading when port VLAN is configured
	ipv4: fix null-deref in ipv4_link_failure
	powerpc/perf/hv-24x7: Update domain value check
	dccp: fix dccp_v4_err()/dccp_v6_err() again
	platform/x86: intel_scu_ipc: Check status after timeout in busy_loop()
	platform/x86: intel_scu_ipc: Check status upon timeout in ipc_wait_for_interrupt()
	platform/x86: intel_scu_ipc: Don't override scu in intel_scu_ipc_dev_simple_command()
	platform/x86: intel_scu_ipc: Fail IPC send if still busy
	x86/srso: Fix srso_show_state() side effect
	x86/srso: Fix SBPB enablement for spec_rstack_overflow=off
	net: hns3: only enable unicast promisc when mac table full
	net: hns3: add 5ms delay before clear firmware reset irq source
	net: bridge: use DEV_STATS_INC()
	team: fix null-ptr-deref when team device type is changed
	netfilter: ipset: Fix race between IPSET_CMD_CREATE and IPSET_CMD_SWAP
	seqlock: avoid -Wshadow warnings
	seqlock: Rename __seqprop() users
	seqlock: Prefix internal seqcount_t-only macros with a "do_"
	locking/seqlock: Do the lockdep annotation before locking in do_write_seqcount_begin_nested()
	bnxt_en: Flush XDP for bnxt_poll_nitroa0()'s NAPI
	net: rds: Fix possible NULL-pointer dereference
	gpio: tb10x: Fix an error handling path in tb10x_gpio_probe()
	i2c: mux: demux-pinctrl: check the return value of devm_kstrdup()
	netfilter: nf_tables: unregister flowtable hooks on netns exit
	netfilter: nf_tables: double hook unregistration in netns path
	Input: i8042 - rename i8042-x86ia64io.h to i8042-acpipnpio.h
	Input: i8042 - add quirk for TUXEDO Gemini 17 Gen1/Clevo PD70PN
	mmc: renesas_sdhi: probe into TMIO after SCC parameters have been setup
	mmc: renesas_sdhi: populate SCC pointer at the proper place
	mmc: tmio: support custom irq masks
	mmc: renesas_sdhi: register irqs before registering controller
	media: venus: core: Add io base variables for each block
	media: venus: hfi,pm,firmware: Convert to block relative addressing
	media: venus: hfi: Define additional 6xx registers
	media: venus: core: Add differentiator IS_V6(core)
	media: venus: hfi: Add a 6xx boot logic
	media: venus: hfi_venus: Write to VIDC_CTRL_INIT after unmasking interrupts
	netfilter: use actual socket sk for REJECT action
	netfilter: nft_exthdr: Support SCTP chunks
	netfilter: nf_tables: add and use nft_sk helper
	netfilter: nf_tables: add and use nft_thoff helper
	netfilter: nft_exthdr: break evaluation if setting TCP option fails
	netfilter: exthdr: add support for tcp option removal
	netfilter: nft_exthdr: Fix non-linear header modification
	ata: libata: Rename link flag ATA_LFLAG_NO_DB_DELAY
	ata: ahci: Add support for AMD A85 FCH (Hudson D4)
	ata: ahci: Rename board_ahci_mobile
	ata: ahci: Add Elkhart Lake AHCI controller
	btrfs: reset destination buffer when read_extent_buffer() gets invalid range
	MIPS: Alchemy: only build mmc support helpers if au1xmmc is enabled
	bus: ti-sysc: Use fsleep() instead of usleep_range() in sysc_reset()
	bus: ti-sysc: Fix missing AM35xx SoC matching
	clk: tegra: fix error return case for recalc_rate
	ARM: dts: omap: correct indentation
	ARM: dts: ti: omap: Fix bandgap thermal cells addressing for omap3/4
	ARM: dts: motorola-mapphone: Configure lower temperature passive cooling
	ARM: dts: motorola-mapphone: Add 1.2GHz OPP
	ARM: dts: motorola-mapphone: Drop second ti,wlcore compatible value
	ARM: dts: am335x: Guardian: Update beeper label
	ARM: dts: Unify pwm-omap-dmtimer node names
	ARM: dts: ti: omap: motorola-mapphone: Fix abe_clkctrl warning on boot
	bus: ti-sysc: Fix SYSC_QUIRK_SWSUP_SIDLE_ACT handling for uart wake-up
	power: supply: ucs1002: fix error code in ucs1002_get_property()
	xtensa: add default definition for XCHAL_HAVE_DIV32
	xtensa: iss/network: make functions static
	xtensa: boot: don't add include-dirs
	xtensa: boot/lib: fix function prototypes
	gpio: pmic-eic-sprd: Add can_sleep flag for PMIC EIC chip
	i2c: npcm7xx: Fix callback completion ordering
	dma-debug: don't call __dma_entry_alloc_check_leak() under free_entries_lock
	parisc: sba: Fix compile warning wrt list of SBA devices
	parisc: iosapic.c: Fix sparse warnings
	parisc: drivers: Fix sparse warning
	parisc: irq: Make irq_stack_union static to avoid sparse warning
	scsi: qedf: Add synchronization between I/O completions and abort
	selftests/ftrace: Correctly enable event in instance-event.tc
	ring-buffer: Avoid softlockup in ring_buffer_resize()
	selftests: fix dependency checker script
	ring-buffer: Do not attempt to read past "commit"
	platform/mellanox: mlxbf-bootctl: add NET dependency into Kconfig
	scsi: pm80xx: Use phy-specific SAS address when sending PHY_START command
	scsi: pm80xx: Avoid leaking tags when processing OPC_INB_SET_CONTROLLER_CONFIG command
	ata: libata-eh: do not clear ATA_PFLAG_EH_PENDING in ata_eh_reset()
	spi: nxp-fspi: reset the FLSHxCR1 registers
	bpf: Clarify error expectations from bpf_clone_redirect
	media: vb2: frame_vector.c: replace WARN_ONCE with a comment
	powerpc/watchpoints: Disable preemption in thread_change_pc()
	ncsi: Propagate carrier gain/loss events to the NCSI controller
	fbdev/sh7760fb: Depend on FB=y
	perf build: Define YYNOMEM as YYNOABORT for bison < 3.81
	sched/cpuacct: Fix user/system in shown cpuacct.usage*
	sched/cpuacct: Fix charge percpu cpuusage
	sched/cpuacct: Optimize away RCU read lock
	cgroup: Fix suspicious rcu_dereference_check() usage warning
	ACPI: Check StorageD3Enable _DSD property in ACPI code
	nvme-pci: factor the iod mempool creation into a helper
	nvme-pci: factor out a nvme_pci_alloc_dev helper
	nvme-pci: do not set the NUMA node of device if it has none
	watchdog: iTCO_wdt: No need to stop the timer in probe
	watchdog: iTCO_wdt: Set NO_REBOOT if the watchdog is not already running
	netfilter: nft_exthdr: Search chunks in SCTP packets only
	netfilter: nft_exthdr: Fix for unsafe packet data read
	nvme-pci: always return an ERR_PTR from nvme_pci_alloc_dev
	smack: Record transmuting in smk_transmuted
	smack: Retrieve transmuting information in smack_inode_getsecurity()
	Smack:- Use overlay inode label in smack_inode_copy_up()
	Revert "tty: n_gsm: fix UAF in gsm_cleanup_mux"
	serial: 8250_port: Check IRQ data before use
	nilfs2: fix potential use after free in nilfs_gccache_submit_read_data()
	netfilter: nf_tables: disallow rule removal from chain binding
	ALSA: hda: Disable power save for solving pop issue on Lenovo ThinkCentre M70q
	ata: libata-scsi: ignore reserved bits for REPORT SUPPORTED OPERATION CODES
	i2c: i801: unregister tco_pdev in i801_probe() error path
	Revert "SUNRPC dont update timeout value on connection reset"
	proc: nommu: /proc/<pid>/maps: release mmap read lock
	ring-buffer: Update "shortest_full" in polling
	btrfs: properly report 0 avail for very full file systems
	bpf: Fix BTF_ID symbol generation collision
	bpf: Fix BTF_ID symbol generation collision in tools/
	net: thunderbolt: Fix TCPv6 GSO checksum calculation
	ata: libata-core: Fix ata_port_request_pm() locking
	ata: libata-core: Fix port and device removal
	ata: libata-core: Do not register PM operations for SAS ports
	ata: libata-sata: increase PMP SRST timeout to 10s
	fs: binfmt_elf_efpic: fix personality for ELF-FDPIC
	spi: spi-zynqmp-gqspi: Fix runtime PM imbalance in zynqmp_qspi_probe
	spi: zynqmp-gqspi: fix clock imbalance on probe failure
	NFS: Cleanup unused rpc_clnt variable
	NFS: rename nfs_client_kset to nfs_kset
	NFSv4: Fix a state manager thread deadlock regression
	ring-buffer: remove obsolete comment for free_buffer_page()
	ring-buffer: Fix bytes info in per_cpu buffer stats
	drm/mediatek: Fix backport issue in mtk_drm_gem_prime_vmap()
	rbd: move rbd_dev_refresh() definition
	rbd: decouple header read-in from updating rbd_dev->header
	rbd: decouple parent info read-in from updating rbd_dev
	rbd: take header_rwsem in rbd_dev_refresh() only when updating
	block: fix use-after-free of q->q_usage_counter
	Revert "clk: imx: pll14xx: dynamically configure PLL for 393216000/361267200Hz"
	Revert "PCI: qcom: Disable write access to read only registers for IP v2.3.3"
	scsi: zfcp: Fix a double put in zfcp_port_enqueue()
	qed/red_ll2: Fix undefined behavior bug in struct qed_ll2_info
	wifi: mwifiex: Fix tlv_buf_left calculation
	net: replace calls to sock->ops->connect() with kernel_connect()
	net: prevent rewrite of msg_name in sock_sendmsg()
	arm64: Add Cortex-A520 CPU part definition
	ubi: Refuse attaching if mtd's erasesize is 0
	wifi: iwlwifi: dbg_ini: fix structure packing
	wifi: mwifiex: Fix oob check condition in mwifiex_process_rx_packet
	bpf: Fix tr dereferencing
	drivers/net: process the result of hdlc_open() and add call of hdlc_close() in uhdlc_close()
	wifi: mt76: mt76x02: fix MT76x0 external LNA gain handling
	regmap: rbtree: Fix wrong register marked as in-cache when creating new node
	ima: Finish deprecation of IMA_TRUSTED_KEYRING Kconfig
	scsi: target: core: Fix deadlock due to recursive locking
	ima: rework CONFIG_IMA dependency block
	NFSv4: Fix a nfs4_state_manager() race
	modpost: add missing else to the "of" check
	net: fix possible store tearing in neigh_periodic_work()
	ipv4, ipv6: Fix handling of transhdrlen in __ip{,6}_append_data()
	net: dsa: mv88e6xxx: Avoid EEPROM timeout when EEPROM is absent
	net: usb: smsc75xx: Fix uninit-value access in __smsc75xx_read_reg
	net: nfc: llcp: Add lock when modifying device list
	net: ethernet: ti: am65-cpsw: Fix error code in am65_cpsw_nuss_init_tx_chns()
	netfilter: handle the connecting collision properly in nf_conntrack_proto_sctp
	netfilter: nf_tables: nft_set_rbtree: fix spurious insertion failure
	net: stmmac: dwmac-stm32: fix resume on STM32 MCU
	tipc: fix a potential deadlock on &tx->lock
	tcp: fix quick-ack counting to count actual ACKs of new data
	tcp: fix delayed ACKs for MSS boundary condition
	sctp: update transport state when processing a dupcook packet
	sctp: update hb timer immediately after users change hb_interval
	cpupower: add Makefile dependencies for install targets
	dm zoned: free dmz->ddev array in dmz_put_zoned_devices
	RDMA/core: Require admin capabilities to set system parameters
	of: dynamic: Fix potential memory leak in of_changeset_action()
	IB/mlx4: Fix the size of a buffer in add_port_entries()
	gpio: aspeed: fix the GPIO number passed to pinctrl_gpio_set_config()
	gpio: pxa: disable pinctrl calls for MMP_GPIO
	RDMA/cma: Initialize ib_sa_multicast structure to 0 when join
	RDMA/cma: Fix truncation compilation warning in make_cma_ports
	RDMA/uverbs: Fix typo of sizeof argument
	RDMA/siw: Fix connection failure handling
	RDMA/mlx5: Fix NULL string error
	parisc: Restore __ldcw_align for PA-RISC 2.0 processors
	netfilter: nf_tables: fix kdoc warnings after gc rework
	netfilter: nftables: exthdr: fix 4-byte stack OOB write
	mmc: renesas_sdhi: only reset SCC when its pointer is populated
	xen/events: replace evtchn_rwlock with RCU
	Linux 5.10.198

Change-Id: Iabfdf919ae63e41a565e523087d800ebc20e5448
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
2023-10-26 17:54:46 +00:00
Ming Lei
f94471c0cc block: fix use-after-free of q->q_usage_counter
commit d36a9ea5e7766961e753ee38d4c331bbe6ef659b upstream.

For blk-mq, queue release handler is usually called after
blk_mq_freeze_queue_wait() returns. However, the
q_usage_counter->release() handler may not be run yet at that time, so
this can cause a use-after-free.

Fix the issue by moving percpu_ref_exit() into blk_free_queue_rcu().
Since ->release() is called with rcu read lock held, it is agreed that
the race should be covered in caller per discussion from the two links.

Reported-by: Zhang Wensheng <zhangwensheng@huaweicloud.com>
Reported-by: Zhong Jinghua <zhongjinghua@huawei.com>
Link: https://lore.kernel.org/linux-block/Y5prfOjyyjQKUrtH@T590/T/#u
Link: https://lore.kernel.org/lkml/Y4%2FmzMd4evRg9yDi@fedora/
Cc: Hillf Danton <hdanton@sina.com>
Cc: Yu Kuai <yukuai3@huawei.com>
Cc: Dennis Zhou <dennis@kernel.org>
Fixes: 2b0d3d3e4f ("percpu_ref: reduce memory footprint of percpu_ref in fast path")
Signed-off-by: Ming Lei <ming.lei@redhat.com>
Link: https://lore.kernel.org/r/20221215021629.74870-1-ming.lei@redhat.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Saranya Muruganandam <saranyamohan@google.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-10-10 21:53:36 +02:00
Todd Kjos
3cf9365660 Merge tag 'android12-5.10.189_r00' into android12-5.10
This is the merge of 5.10.189 into the android12-5.10 branch.

It contains the following commits:

*   f50fa8d8ce Merge 5.10.189 into android12-5.10-lts
|\
| * de5f63612d Linux 5.10.189
| * 2ae9a73819 x86: fix backwards merge of GDS/SRSO bit
| * f9167a2d6b xen/netback: Fix buffer overrun triggered by unusual packet
| * 8457fb5740 x86/srso: Tie SBPB bit setting to microcode patch detection
| * 4873939c0e x86/srso: Fix return thunks in generated code
| * 384d41bea9 x86/srso: Add IBPB on VMEXIT
| * 4acaea47e3 x86/srso: Add IBPB
| * e47af0c255 x86/srso: Add SRSO_NO support
| * df76a59feb x86/srso: Add IBPB_BRTYPE support
| * 3f9b7101be x86/srso: Add a Speculative RAS Overflow mitigation
| * 34f23ba8a3 x86/cpu, kvm: Add support for CPUID_80000021_EAX
| * 073a28a9b5 x86/bugs: Increase the x86 bugs vector size to two u32s
| * 9b7fe7c6fb tools headers cpufeatures: Sync with the kernel sources
| * 437fa179f2 x86/cpufeatures: Assign dedicated feature word for CPUID_0x8000001F[EAX]
| * baf6d6c39e x86/cpu: Add VM page flush MSR availablility as a CPUID feature
| * 6750468784 Documentation/x86: Fix backwards on/off logic about YMM support
| * 79972c2b95 x86/mm: Initialize text poking earlier
| * 1ff14defdf mm: Move mm_cachep initialization to mm_init()
| * 6ee042fd24 x86/mm: Use mm_alloc() in poking_init()
| * f076d08178 x86/mm: fix poking_init() for Xen PV guests
| * 583016037a x86/xen: Fix secondary processors' FPU initialization
| * eb13cce488 KVM: Add GDS_NO support to KVM
| * 7db4ddcb8d x86/speculation: Add Kconfig option for GDS
| * 363c98f9cf x86/speculation: Add force option to GDS mitigation
| * 288a2f6bc1 x86/speculation: Add Gather Data Sampling mitigation
| * 4ae1cbb730 x86/fpu: Move FPU initialization into arch_cpu_finalize_init()
| * 2462bc3ef0 x86/fpu: Mark init functions __init
| * 7a2f42bce9 x86/fpu: Remove cpuinfo argument from init functions
| * 18fcd72da1 init, x86: Move mem_encrypt_init() into arch_cpu_finalize_init()
| * 09658b81d1 init: Invoke arch_cpu_finalize_init() earlier
| * bf2fa3a9d0 init: Remove check_bugs() leftovers
| * b05031c2bc um/cpu: Switch to arch_cpu_finalize_init()
| * 2edb3b39ca sparc/cpu: Switch to arch_cpu_finalize_init()
| * 3c45134b38 sh/cpu: Switch to arch_cpu_finalize_init()
| * 75bb54c951 mips/cpu: Switch to arch_cpu_finalize_init()
| * 1cd3fc18eb m68k/cpu: Switch to arch_cpu_finalize_init()
| * 12d93c6c98 ia64/cpu: Switch to arch_cpu_finalize_init()
| * c0fff20d4e ARM: cpu: Switch to arch_cpu_finalize_init()
| * e5eb18e164 x86/cpu: Switch to arch_cpu_finalize_init()
| * 6e606e6818 init: Provide arch_cpu_finalize_init()
* | 49c25af89c Revert "bpf: Remove extra lock_sock for TCP_ZEROCOPY_RECEIVE"
* | 117f73f9a7 Revert "sctp: add bpf_bypass_getsockopt proto callback"
* | 64414277da Revert "net: Introduce net.ipv4.tcp_migrate_req."
* | 2afed824a4 Revert "tcp: Fix data-races around sysctl_tcp_syn(ack)?_retries."
* | 08315eedaa Revert "tcp: annotate data-races around icsk->icsk_syn_retries"
* | 938b8658b9 Revert "posix-timers: Ensure timer ID search-loop limit is valid"
* | 986fd89af0 Revert "Revert "8250: add support for ASIX devices with a FIFO bug""
* | 477f5e6b9e Merge 5.10.188 into android12-5.10-lts
|\|
| * 3602dbc57b Linux 5.10.188
| * edce5fba78 ftrace: Fix possible warning on checking all pages used in ftrace_process_locs()
| * 115b19f893 ftrace: Store the order of pages allocated in ftrace_page
| * 1a1e793e02 tracing: Fix memory leak of iter->temp when reading trace_pipe
| * 43e786aa51 tracing/histograms: Return an error if we fail to add histogram to hist_vars list
| * e3da59f428 net: phy: prevent stale pointer dereference in phy_init()
| * e0ac63e194 tcp: annotate data-races around fastopenq.max_qlen
| * d01afbfc2f tcp: annotate data-races around icsk->icsk_user_timeout
| * 3cf0a0f11d tcp: annotate data-races around tp->notsent_lowat
| * 9c786d5faf tcp: annotate data-races around rskq_defer_accept
| * f891375eba tcp: annotate data-races around tp->linger2
| * 9168bd8f54 tcp: annotate data-races around icsk->icsk_syn_retries
| * 7b0084918c tcp: Fix data-races around sysctl_tcp_syn(ack)?_retries.
| * cf6c06ac74 net: Introduce net.ipv4.tcp_migrate_req.
| * a5c30a5187 tcp: annotate data-races around tp->keepalive_probes
| * 93715448f1 tcp: annotate data-races around tp->keepalive_intvl
| * 7b52a78a91 tcp: annotate data-races around tp->keepalive_time
| * 1d4f2c4be1 tcp: annotate data-races around tp->tcp_tx_delay
| * 30e5460d69 netfilter: nf_tables: skip bound chain on rule flush
| * 94c10c0fa5 netfilter: nf_tables: skip bound chain in netns release path
| * 3a91099ecd netfilter: nft_set_pipapo: fix improper element removal
| * 9c2df17e3c netfilter: nf_tables: can't schedule in nft_chain_validate
| * 533193a239 netfilter: nf_tables: fix spurious set element insertion failure
| * a6f1988780 llc: Don't drop packet from non-root netns.
| * 49e435ca02 fbdev: au1200fb: Fix missing IRQ check in au1200fb_drv_probe
| * bc9d4d432f Revert "tcp: avoid the lookup process failing to get sk in ehash table"
| * d06fc7b391 net:ipv6: check return value of pskb_trim()
| * 1a478ad129 net: ipv4: Use kfree_sensitive instead of kfree
| * 937105d2b0 tcp: annotate data-races around tcp_rsk(req)->ts_recent
| * 41b0023869 octeontx2-pf: Dont allocate BPIDs for LBK interfaces
| * 5bc78ba889 security: keys: Modify mismatched function name
| * b92defe4e8 iavf: Fix out-of-bounds when setting channels on remove
| * a4635f190f iavf: Fix use-after-free in free_netdev
| * b37bc3b07e bridge: Add extack warning when enabling STP in netns.
| * f6d311b953 net: ethernet: ti: cpsw_ale: Fix cpsw_ale_get_field()/cpsw_ale_set_field()
| * 54aa4c0386 pinctrl: amd: Use amd_pinconf_set() for all config options
| * 7041605e85 fbdev: imxfb: warn about invalid left/right margin
| * 6e88cc510f spi: bcm63xx: fix max prepend length
| * 994c2ceb70 igb: Fix igb_down hung on surprise removal
| * a956c3af70 wifi: iwlwifi: mvm: avoid baid size integer overflow
| * 85cf0d5f45 wifi: wext-core: Fix -Wstringop-overflow warning in ioctl_standard_iw_point()
| * 2864cc9a1f devlink: report devlink_port_type_warn source device
| * b6d9a4062c bpf: Address KCSAN report on bpf_lru_list
| * 532f8bac60 wifi: ath11k: fix registration of 6Ghz-only phy without the full channel range
| * 6b0c79aa33 sched/fair: Don't balance task to its current running CPU
| * 32020fc2a8 arm64: mm: fix VA-range sanity check
| * c71d6934c6 arm64: set __exception_irq_entry with __irq_entry as a default
| * 71e3f23540 ACPI: video: Add backlight=native DMI quirk for Lenovo ThinkPad X131e (3371 AMD version)
| * 776a72f612 ACPI: video: Add backlight=native DMI quirk for Apple iMac11,3
| * e090f70ae4 ACPI: button: Add lid disable DMI quirk for Nextbook Ares 8A
| * ae51eb90bc btrfs: add xxhash to fast checksum implementations
| * 322377cc90 posix-timers: Ensure timer ID search-loop limit is valid
| * 634daf6b2c md/raid10: prevent soft lockup while flush writes
| * b02939413e md: fix data corruption for raid456 when reshape restart while grow up
| * 4a2c62c8d6 nbd: Add the maximum limit of allocated index in nbd_dev_add
| * 5f84a34b64 debugobjects: Recheck debug_objects_enabled before reporting
| * 5d5aa5b648 ext4: correct inline offset when handling xattrs in inode body
| * 48aa539375 ASoC: fsl_sai: Disable bit clock with transmitter
| * 5f2a12f643 drm/client: Fix memory leak in drm_client_modeset_probe
| * 105275879a drm/client: Fix memory leak in drm_client_target_cloned
| * cf254b4f68 can: bcm: Fix UAF in bcm_proc_show()
| * 3e412b6e2b regmap: Account for register length in SMBus I/O limits
| * 8b3dd8d23f regmap: Drop initial version of maximum transfer length fixes
| * 4935761daa selftests: tc: add 'ct' action kconfig dep
| * 1ab5aa1846 selftests: tc: set timeout to 15 minutes
| * dad97c205a fuse: revalidate: don't invalidate if interrupted
| * d2c667cc18 btrfs: fix warning when putting transaction with qgroups enabled after abort
| * 4410f4a938 perf probe: Add test for regression introduced by switch to die_get_decl_file()
| * 0a6b0ca586 keys: Fix linking a duplicate key to a keyring's assoc_array
| * a26208e184 ALSA: hda/realtek: Enable Mute LED on HP Laptop 15s-eq2xxx
| * ce2a7e7b50 ALSA: hda/realtek - remove 3k pull low procedure
| * f09c0ac142 drm/atomic: Fix potential use-after-free in nonblocking commits
| * 9a085fa9b7 RDMA/cma: Ensure rdma_addr_cancel() happens before issuing more requests
| * 73e72a5380 net/sched: sch_qfq: reintroduce lmax bound check for MTU
| * 0b1ce92fab scsi: qla2xxx: Remove unused nvme_ls_waitq wait queue
| * 5addd62586 scsi: qla2xxx: Pointer may be dereferenced
| * e8de73238d scsi: qla2xxx: Correct the index of array
| * 921d684462 scsi: qla2xxx: Check valid rport returned by fc_bsg_to_rport()
| * 2bea9c1c98 scsi: qla2xxx: Fix potential NULL pointer dereference
| * eecb8a491c scsi: qla2xxx: Fix buffer overrun
| * bcd773969a scsi: qla2xxx: Array index may go out of bound
| * a9fe97fb7b scsi: qla2xxx: Wait for io return on terminate rport
| * 6ea2a408d3 tracing/probes: Fix not to count error code to total length
| * 7060e5aac6 tracing: Fix null pointer dereference in tracing_err_log_open()
| * 81fb8a58d4 xtensa: ISS: fix call to split_if_spec
| * 5e68f1f3a2 ring-buffer: Fix deadloop issue on reading trace_pipe
| * 1e760b2d18 net: ena: fix shift-out-of-bounds in exponential backoff
| * 1f2a8f0835 samples: ftrace: Save required argument registers in sample trampolines
| * 1576f0df7b tracing/histograms: Add histograms to hist_vars if they have referenced variables
| * 07edd294b1 s390/decompressor: fix misaligned symbol build error
| * 5f4a1111ad Revert "8250: add support for ASIX devices with a FIFO bug"
| * 7f2f0e6ec5 meson saradc: fix clock divider mask length
| * 790e4e82c5 xhci: Show ZHAOXIN xHCI root hub speed correctly
| * c52e04c58d xhci: Fix TRB prefetch issue of ZHAOXIN hosts
| * b56a07c2a5 xhci: Fix resume issue of some ZHAOXIN hosts
| * 8e807eadf0 ceph: don't let check_caps skip sending responses for revoke msgs
| * c04ed61ebf firmware: stratix10-svc: Fix a potential resource leak in svc_create_memory_pool()
| * 1962717c46 tty: serial: samsung_tty: Fix a memory leak in s3c24xx_serial_getclk() when iterating clk
| * a49e5a0512 tty: serial: samsung_tty: Fix a memory leak in s3c24xx_serial_getclk() in case of error
| * 08673739ed serial: atmel: don't enable IRQs prematurely
| * 4016d36fec drm/amd/display: Correct `DMUB_FW_VERSION` macro
| * d89bd2ecd3 drm/rockchip: vop: Leave vblank enabled in self-refresh
| * b9ec9372a4 drm/atomic: Allow vblank-enabled + self-refresh "disable"
| * 23d5004ee7 fs: dlm: return positive pid value for F_GETLK
| * 5e9aff5b10 md/raid0: add discard support for the 'original' layout
| * 8e3c777640 misc: pci_endpoint_test: Re-init completion for every test
| * cdf9a7e2cd misc: pci_endpoint_test: Free IRQs before removing the device
| * 8c90c466e3 PCI: rockchip: Set address alignment for endpoint mode
| * f1986416cf PCI: rockchip: Use u32 variable to access 32-bit registers
| * 36eb130312 PCI: rockchip: Fix legacy IRQ generation for RK3399 PCIe endpoint core
| * c417a4c7de PCI: rockchip: Add poll and timeout to wait for PHY PLLs to be locked
| * ddda61419a PCI: rockchip: Write PCI Device ID to correct register
| * bec3e0f7f2 PCI: rockchip: Assert PCI Configuration Enable bit after probe
| * 48e11e7c81 PCI: qcom: Disable write access to read only registers for IP v2.3.3
| * aca71b004a PCI: Add function 1 DMA alias quirk for Marvell 88SE9235
| * d3bab5de91 PCI/PM: Avoid putting EloPOS E2/S2/H2 PCIe Ports in D3cold
| * 5a89a5cc81 hwrng: imx-rngc - fix the timeout for init and self check
| * 47b7eaae08 jfs: jfs_dmap: Validate db_l2nbperpage while mounting
| * 84293af545 ext4: only update i_reserved_data_blocks on successful block allocation
| * 0a5d12e710 ext4: fix wrong unit use in ext4_mb_new_blocks
| * 514220246a ext4: get block from bh in ext4_free_blocks for fast commit replay
| * d054422eb6 ext4: fix wrong unit use in ext4_mb_clear_bb
| * be99faf0c4 ext4: Fix reusing stale buffer heads from last failed mounting
| * 8fbe951d65 MIPS: Loongson: Fix cpu_probe_loongson() again
| * 8c723eef98 erofs: fix compact 4B support for 16k block size
| * 3bd4d316b1 misc: fastrpc: Create fastrpc scalar with correct buffer count
| * 3d1d037f27 powerpc: Fail build if using recordmcount with binutils v2.37
| * fe1ae1fb50 net: bcmgenet: Ensure MDIO unregistration has clocks enabled
| * 21d5d3eb36 mtd: rawnand: meson: fix unaligned DMA buffers handling
| * 9ff7fcb3a2 tpm: tpm_vtpm_proxy: fix a race condition in /dev/vtpmx creation
| * 59490249c2 pinctrl: amd: Only use special debounce behavior for GPIO 0
| * 4f77a87ce9 pinctrl: amd: Detect internal GPIO0 debounce handling
| * 3674b9c056 pinctrl: amd: Fix mistake in handling clearing pins at startup
| * b39ef5b52f f2fs: fix to avoid NULL pointer dereference f2fs_write_end_io()
| * f4ff379812 nvme-pci: fix DMA direction of unmapping integrity data
| * 8359ee85fd net/sched: sch_qfq: account for stab overhead in qfq_enqueue
| * 5bef780e06 net/sched: sch_qfq: refactor parsing of netlink parameters
| * 1d7ae38daa net/sched: make psched_mtu() RTNL-less safe
| * d5ca61b764 netdevsim: fix uninitialized data in nsim_dev_trap_fa_cookie_write()
| * 9b69cdb6e5 net/sched: flower: Ensure both minimum and maximum ports are specified
| * 934c85b8ec wifi: airo: avoid uninitialized warning in airo_get_rate()
| * 4511499138 erofs: avoid infinite loop in z_erofs_do_read_page() when reading beyond EOF
| * bbc500ff3f riscv, bpf: Fix inconsistent JIT image generation
| * a976adc3bc bpf, riscv: Support riscv jit to provide bpf_line_info
| * eb3d1d84f3 riscv: bpf: Avoid breaking W^X
| * 7c61643798 riscv: bpf: Move bpf_jit_alloc_exec() and bpf_jit_free_exec() to core
| * 83579a6261 igc: Fix inserting of empty frame for launchtime
| * c48e8ee81a igc: Fix launchtime before start of cycle
| * cdf5b9af92 platform/x86: wmi: Break possible infinite loop when parsing GUID
| * 7157ee0de5 platform/x86: wmi: move variables
| * 4bb2bb69bd platform/x86: wmi: use guid_t and guid_equal()
| * 88dfb592d2 platform/x86: wmi: remove unnecessary argument
| * 2ad31ce40e ipv6/addrconf: fix a potential refcount underflow for idev
| * 8271145523 NTB: ntb_tool: Add check for devm_kcalloc
| * 41c6d8ff71 NTB: ntb_transport: fix possible memory leak while device_register() fails
| * 03cfa06534 ntb: intel: Fix error handling in intel_ntb_pci_driver_init()
| * 23e09f0a86 NTB: amd: Fix error handling in amd_ntb_pci_driver_init()
| * 0bb2683b0c ntb: idt: Fix error handling in idt_pci_driver_init()
| * 3e8fed805c udp6: fix udp6_ehashfn() typo
| * d30ddd7ff1 icmp6: Fix null-ptr-deref of ip6_null_entry->rt6i_idev in icmp6_dev().
| * bc3ab5d2ab net: prevent skb corruption on frag list segmentation
| * cddd04f341 net: bgmac: postpone turning IRQs off to avoid SoC hangs
| * f8cc4fd99a ionic: remove WARN_ON to prevent panic_on_warn
| * 9085429821 gve: Set default duplex configuration to full
| * 80e0e8d5f5 net/sched: cls_fw: Fix improper refcount update leads to use-after-free
| * d341f24612 net: mvneta: fix txq_map in case of txq_number==1
| * c175603d84 scsi: qla2xxx: Fix error code in qla2x00_start_sp()
| * b687b78361 igc: set TP bit in 'supported' and 'advertising' fields of ethtool_link_ksettings
| * 30c281a77f net/mlx5e: Check for NOT_READY flag state after locking
| * de6e6b0797 net/mlx5e: fix double free in mlx5e_destroy_flow_table
| * 3d4bba694a igc: Remove delay during TX ring configuration
| * 2a587b71c5 drm/panel: simple: Add Powertip PH800480T013 drm_display_mode flags
| * 547ab8ea86 drm/panel: simple: Add connector_type for innolux_at043tn24
| * 13c353dc5c workqueue: clean up WORK_* constant types, clarify masking
| * fc359e5b45 net: lan743x: Don't sleep in atomic context
| * dc4a25fa75 io_uring: add reschedule point to handle_tw_list()
| * 297883bbca io_uring: Use io_schedule* in cqring wait
| * bb2f7e4bfe block/partition: fix signedness issue for Amiga partitions
| * 4f91de9a81 rcu-tasks: Simplify trc_read_check_handler() atomic operations
| * 3a64cd01cd rcu-tasks: Mark ->trc_reader_special.b.need_qs data races
| * 058f077d09 rcu-tasks: Mark ->trc_reader_nesting data races
| * 83be9fd784 tty: serial: fsl_lpuart: add earlycon for imx8ulp platform
| * 999f3b6104 wireguard: netlink: send staged packets when setting initial private key
| * 1b71070405 wireguard: queueing: use saner cpu selection wrapping
| * ea21392224 netfilter: nf_tables: prevent OOB access in nft_byteorder_eval
| * 4ae2e50133 netfilter: nf_tables: do not ignore genmask when looking up chain by id
| * 8289d422f5 netfilter: conntrack: Avoid nf_ct_helper_hash uses after free
| * be6478f5cc netfilter: nf_tables: fix scheduling-while-atomic splat
| * a07e415be3 netfilter: nf_tables: unbind non-anonymous set if rule construction fails
| * a136b7942a netfilter: nf_tables: drop map element references from preparation phase
| * 21cf0d66ef netfilter: nftables: rename set element data activation/deactivation functions
| * 237f37f7b9 netfilter: nf_tables: reject unbound chain set before commit phase
| * 0205dd16ed netfilter: nf_tables: reject unbound anonymous set before commit phase
| * 34d09fe49f netfilter: nf_tables: add NFT_TRANS_PREPARE_ERROR to deal with bound set/chain
| * d53c295c1f netfilter: nf_tables: fix chain binding transaction logic
| * 8180fc2fad netfilter: nf_tables: incorrect error path handling with NFT_MSG_NEWRULE
| * e546e6ebb1 netfilter: nf_tables: add rescheduling points during loop detection walks
| * 3f51f1157f netfilter: nf_tables: use net_generic infra for transaction data
| * 01248dd651 sh: pgtable-3level: Fix cast to pointer from integer of different size
| * 87410743b5 block: add overflow checks for Amiga partition support
| * f0aec6c403 selftests/bpf: Add verifier test for PTR_TO_MEM spill
| * 88bffb61bc tpm, tpm_tis: Claim locality in interrupt handler
| * 5bf73af8b3 fanotify: disallow mount/sb marks on kernel internal pseudo fs
| * 5cb46b80ec fs: no need to check source
| * 66a0647cdc leds: trigger: netdev: Recheck NETDEV_LED_MODE_LINKUP on dev rename
| * 5d6fbb6245 ARM: orion5x: fix d2net gpio initialization
| * 9b0f7940e2 ASoC: mediatek: mt8173: Fix snd_soc_component_initialize error path
| * 1dac8584be ASoC: mediatek: mt8173: Fix irq error path
| * 6819bb0b85 btrfs: fix race when deleting quota root from the dirty cow roots list
| * a3fbd156bd btrfs: add handling for RAID1C23/DUP to btrfs_reduce_alloc_profile
| * 59efb86711 fs: Lock moved directories
| * c5b5e72df1 fs: Establish locking order for unrelated directories
| * 4b03f503b7 Revert "f2fs: fix potential corruption when moving a directory"
| * 2b563acd2d ext4: Remove ext4 locking of moved directory
| * 5e7d18a52c fs: avoid empty option when generating legacy mount string
| * 988a5d7911 jffs2: reduce stack usage in jffs2_build_xattr_subsystem()
| * 5fada37511 shmem: use ramfs_kill_sb() for kill_sb method of ramfs-based tmpfs
| * 79bef379d5 autofs: use flexible array in ioctl structure
| * 8bf91a8d48 integrity: Fix possible multiple allocation in integrity_inode_get()
| * 9658a03f80 um: Use HOST_DIR for mrproper
| * a4405f6ee0 bcache: Fix __bch_btree_node_alloc to make the failure behavior consistent
| * db9439cef0 bcache: Remove unnecessary NULL point check in node allocations
| * bcb295778a bcache: fixup btree_cache_wait list damage
| * dc3287206a mmc: sdhci: fix DMA configure compatibility issue when 64bit DMA mode is used.
| * 191628e2d9 mmc: mmci: Set PROBE_PREFER_ASYNCHRONOUS
| * 02c8c2b5f6 mmc: core: disable TRIM on Micron MTFC4GACAJCN-1M
| * 6f9708e5c1 mmc: core: disable TRIM on Kingston EMMC04G-M627
| * 28e649dc99 io_uring: wait interruptibly for request completions on exit
| * 8482ac2e5a NFSD: add encoding of op_recall flag for write delegation
| * 8d36cb6d1a i2c: qup: Add missing unwind goto in qup_i2c_probe()
| * e41a8e4615 ALSA: jack: Fix mutex call in snd_jack_report()
| * e71714ad24 i2c: xiic: Don't try to handle more interrupt events after error
| * b6eefa7a27 i2c: xiic: Defer xiic_wakeup() and __xiic_start_xfer() in xiic_process()
| * 023bd9dc41 apparmor: fix missing error check for rhashtable_insert_fast
| * d1c946552a sh: dma: Fix DMA channel offset calculation
| * 37750131d2 s390/qeth: Fix vipa deletion
| * 9f5548e421 net: dsa: tag_sja1105: fix MAC DA patching from meta frames
| * 2758fb81bb pptp: Fix fib lookup calls.
| * 0b08ff091f net/sched: act_pedit: Add size check for TCA_PEDIT_PARMS_EX
| * 2434a6715f xsk: Honor SO_BINDTODEVICE on bind
| * b785ba0acc tcp: annotate data races in __tcp_oow_rate_limited()
| * 73f512bedf net: bridge: keep ports without IFF_UNICAST_FLT in BR_PROMISC mode
| * 9a9d468fdc powerpc: allow PPC_EARLY_DEBUG_CPM only when SERIAL_CPM=y
| * f970b05c9b octeontx2-af: Fix mapping for NIX block from CGX connection
| * 5ded9e8aa5 f2fs: fix error path handling in truncate_dnode()
| * 358145cc37 mailbox: ti-msgmgr: Fill non-message tx data fields with 0x0
| * 32b9c8f789 spi: bcm-qspi: return error if neither hif_mspi nor mspi is available
| * 1f3643f9cf net: dsa: vsc73xx: fix MTU configuration
| * c377451012 Add MODULE_FIRMWARE() for FIRMWARE_TG357766.
| * 6d2243ab78 sctp: fix potential deadlock on &net->sctp.addr_wq_lock
| * 620993d5ee media: cec: i2c: ch7322: also select REGMAP
| * f733a7bfe8 rtc: st-lpc: Release some resources in st_rtc_probe() in case of error
| * aa70e5dd72 pwm: sysfs: Do not apply state to already disabled PWMs
| * 8a0413be8a pwm: imx-tpm: force 'real_period' to be zero in suspend
| * e4845cdea7 phy: tegra: xusb: check return value of devm_kzalloc()
| * 442e1a98bd mfd: stmpe: Only disable the regulators if they are enabled
| * 724448d602 KVM: s390: vsie: fix the length of APCB bitmap
| * c5e2f6f2bb mfd: stmfx: Nullify stmfx->vdd in case of error
| * 30ead8b9bf mfd: stmfx: Fix error path in stmfx_chip_init
| * 4d24051473 test_firmware: return ENOMEM instead of ENOSPC on failed memory allocation
| * 5b31ac1d6d serial: 8250_omap: Use force_suspend and resume for system suspend
| * 8e00ae25a3 Revert "usb: common: usb-conn-gpio: Set last role to unknown before initial detection"
| * a81e1f22e1 mfd: intel-lpss: Add missing check for platform_get_resource
| * 1dc07edc01 usb: dwc3-meson-g12a: Fix an error handling path in dwc3_meson_g12a_probe()
| * 7ade555ac5 usb: common: usb-conn-gpio: Set last role to unknown before initial detection
| * 0e9e127835 usb: dwc3: qcom: Fix an error handling path in dwc3_qcom_probe()
| * a617145208 usb: dwc3: qcom: Release the correct resources in dwc3_qcom_remove()
| * 96898fb476 KVM: s390: fix KVM_S390_GET_CMMA_BITS for GFNs in memslot holes
| * 4e8e838fce media: atomisp: gmin_platform: fix out_len in gmin_get_config_dsm_var()
| * b754ea60e6 media: venus: helpers: Fix ALIGN() of non power of two
| * 02b2266023 mfd: rt5033: Drop rt5033-battery sub-device
| * e52019c095 coresight: Fix loss of connection info when a module is unloaded
| * 018eddcb6b kernfs: fix missing kernfs_idr_lock to remove an ID from the IDR
| * a59f64a835 serial: 8250: lock port for UART_IER access in omap8250_irq()
| * 8d65d0a2bf serial: 8250: lock port for stop_rx() in omap8250_irq()
| * d66ddb61fa usb: hide unused usbfs_notify_suspend/resume functions
| * 56901de563 usb: phy: phy-tahvo: fix memory leak in tahvo_usb_probe()
| * 6538e5d9f7 extcon: Fix kernel doc of property capability fields to avoid warnings
| * dac7d7efcb extcon: Fix kernel doc of property fields to avoid warnings
| * 2788a3553f usb: gadget: u_serial: Add null pointer check in gserial_suspend
| * 74f8606ddf usb: dwc3: qcom: Fix potential memory leak
| * bdce16c1e6 clk: qcom: ipq6018: fix networking resets
| * ee3f494cfc clk: qcom: reset: support resetting multiple bits
| * 35fd1a213f clk: qcom: reset: Allow specifying custom reset delay
| * d87ef4e857 media: usb: siano: Fix warning due to null work_func_t function pointer
| * 300388887c media: videodev2.h: Fix struct v4l2_input tuner index comment
| * 5f3f4aa673 media: usb: Check az6007_read() return value
| * 32809afb60 clk: qcom: gcc-ipq6018: Use floor ops for sdcc clocks
| * bb81ca33ac serial: 8250: omap: Fix freeing of resources on failed register
| * ed68e8e22e sh: j2: Use ioremap() to translate device tree address into kernel memory
| * a7890637b3 w1: fix loop in w1_fini()
| * a27aeae714 w1: w1_therm: fix locking behavior in convert_t
| * cd5ec3ee52 SUNRPC: Fix UAF in svc_tcp_listen_data_ready()
| * e4a9b3333e block: change all __u32 annotations to __be32 in affs_hardblocks.h
| * 54da6c4c14 block: fix signed int overflow in Amiga partition support
| * b6a107c520 phy: tegra: xusb: Clear the driver reference in usb-phy dev
| * fac7be49f1 usb: dwc3: gadget: Propagate core init errors to UDC during pullup
| * 8b0a55b592 USB: serial: option: add LARA-R6 01B PIDs
| * 810e401b34 io_uring: ensure IOPOLL locks around deferred work
| * cd5837564f hwrng: st - keep clock enabled while hwrng is registered
| * 557e528255 dax: Introduce alloc_dev_dax_id()
| * 94a85474f5 dax: Fix dax_mapping_release() use after free
| * 7c9f5a14d9 NFSv4.1: freeze the session table upon receiving NFS4ERR_BADSESSION
| * bab0bf5677 ARC: define ASM_NL and __ALIGN(_STR) outside #ifdef __ASSEMBLY__ guard
| * cb0cdca5c9 modpost: fix off by one in is_executable_section()
| * f0350516b9 crypto: marvell/cesa - Fix type mismatch warning
| * b540694455 modpost: fix section mismatch message for R_ARM_{PC24,CALL,JUMP24}
| * 88978ef7fd modpost: fix section mismatch message for R_ARM_ABS32
| * 31195ee328 crypto: nx - fix build warnings when DEBUG_FS is not enabled
| * 77471e4912 hwrng: virtio - Fix race on data_avail and actual data
| * e8f51401d6 hwrng: virtio - always add a pending request
| * ffc5ce9c27 hwrng: virtio - don't waste entropy
| * d13ea82bfe hwrng: virtio - don't wait on cleanup
| * 5f23dae018 hwrng: virtio - add an internal buffer
| * aba192bb31 powerpc/mm/dax: Fix the condition when checking if altmap vmemap can cross-boundary
| * 7afd0de0cc powerpc/book3s64/mm: Fix DirectMap stats in /proc/meminfo
| * 7289ca7a51 mm: rename p4d_page_vaddr to p4d_pgtable and make it return pud_t *
| * bfad110188 mm: rename pud_page_vaddr to pud_pgtable and make it return pmd_t *
| * 07c19c0ad4 powerpc/powernv/sriov: perform null check on iov before dereferencing iov
| * f3c7b95c99 pinctrl: at91-pio4: check return value of devm_kasprintf()
| * b7a38fc3f3 perf dwarf-aux: Fix off-by-one in die_get_varname()
| * 75a3cb1e23 perf script: Fix allocation of evsel->priv related to per-event dump files
| * 647c6d35cc perf script: Fixup 'struct evsel_script' method prefix
| * 958acb479e kcsan: Don't expect 64 bits atomic builtins from 32 bits architectures
| * 5533f0eb0a pinctrl: cherryview: Return correct value if pin in push-pull mode
| * 4b63caf86e perf bench: Add missing setlocale() call to allow usage of %'d style formatting
| * 345ee85216 perf bench: Use unbuffered output when pipe/tee'ing to a file
| * f0d2310f6b PCI: Add pci_clear_master() stub for non-CONFIG_PCI
| * b65fe59b2d PCI: ftpci100: Release the clock resources
| * cb389e8edf PCI: pciehp: Cancel bringup sequence if card is not present
| * b9895a4c95 scsi: 3w-xxxx: Add error handling for initialization failure in tw_probe()
| * 7badf4d6f4 PCI/ASPM: Disable ASPM on MFD function removal to avoid use-after-free
| * d27238fc83 pinctrl: bcm2835: Handle gpiochip_add_pin_range() errors
| * ac64019e4d scsi: qedf: Fix NULL dereference in error handling
| * 8e9907e921 PCI: cadence: Fix Gen2 Link Retraining process
| * 07be8e60f2 ASoC: imx-audmix: check return value of devm_kasprintf()
| * 714ba10a6d ovl: update of dentry revalidate flags after copy up
| * 47f4d875aa drivers: meson: secure-pwrc: always enable DMA domain
| * 5f149d0538 clk: ti: clkctrl: check return value of kasprintf()
| * fd9324fa4d clk: keystone: sci-clk: check return value of kasprintf()
| * 0b754f9cfd clk: si5341: free unused memory on probe failure
| * dc8d0178d5 clk: si5341: check return value of {devm_}kasprintf()
| * dc3eef6480 clk: si5341: return error if one synth clock registration fails
| * 0401139800 clk: si5341: Add sysfs properties to allow checking/resetting device faults
| * fc813d0573 clk: si5341: Allow different output VDD_SEL values
| * f64fcd3acf clk: cdce925: check return value of kasprintf()
| * 866d4340c6 clk: vc5: check memory returned by kasprintf()
| * c67a55f7cc drm/msm/dp: Free resources after unregistering them
| * c3b63584d8 drm/msm/dpu: do not enable color-management if DSPPs are not available
| * f923a58221 ALSA: ac97: Fix possible NULL dereference in snd_ac97_mixer
| * 404e9f741a clk: tegra: tegra124-emc: Fix potential memory leak
| * cb047c13bb clk: imx: clk-imx8mp: improve error handling in imx8mp_clocks_probe()
| * 294321349b clk: imx: clk-imx8mn: fix memory leak in imx8mn_clocks_probe
| * e749bc5a90 RDMA/bnxt_re: Avoid calling wake_up threads from spin_lock context
| * 9341501e2f RDMA/bnxt_re: wraparound mbox producer index
| * 968e27fd03 amdgpu: validate offset_in_bo of drm_amdgpu_gem_va
| * e070120e6d drm/radeon: fix possible division-by-zero errors
| * a77b80825b drm/amdkfd: Fix potential deallocation of previously deallocated memory.
| * 245aa7c023 ARM: dts: BCM5301X: fix duplex-full => full-duplex
| * 7e2edb84fe hwmon: (pmbus/adm1275) Fix problems with temperature monitoring on ADM1272
| * 580e9b987b hwmon: (adm1275) Allow setting sample averaging
| * a3c5d148b7 hwmon: (adm1275) enable adm1272 temperature reporting
| * 4610efa404 hwmon: (gsc-hwmon) fix fan pwm temperature scaling
| * 6e12311dce ARM: dts: stm32: fix i2s endpoint format property for stm32mp15xx-dkx
| * badeb7fe24 ARM: dts: stm32: Fix audio routing on STM32MP15xx DHCOM PDK2
| * 17cd31487d arm64: dts: ti: k3-j7200: Fix physical address of pin
| * ce6e0434e5 fbdev: omapfb: lcd_mipid: Fix an error handling path in mipid_spi_probe()
| * 34e1e2f3cf arm64: dts: renesas: ulcb-kf: Remove flow control for SCIF1
| * 6817914c67 ARM: dts: iwg20d-q7-common: Fix backlight pwm specifier
| * 220f86cc19 RDMA/hns: Fix hns_roce_table_get return value
| * 9196f44239 RDMA/hns: Clean the hardware related code for HEM
| * aa495b927f RDMA/hns: Use refcount_t APIs for HEM
| * de1049dd18 RDMA/hns: Fix coding style issues
| * cc1b04b699 RDMA: Remove uverbs_ex_cmd_mask values that are linked to functions
| * 7dcb9ea3ee IB/hfi1: Fix wrong mmu_node used for user SDMA packet after invalidate
| * 6cf8f3d690 IB/hfi1: Fix sdma.h tx->num_descs off-by-one errors
| * 2d38866a99 IB/hfi1: Use bitmap_zalloc() when applicable
| * 42b6865bf5 soc/fsl/qe: fix usb.c build errors
| * 9c14d14066 ARM: dts: meson8: correct uart_B and uart_C clock references
| * 684a2f180e ASoC: es8316: Do not set rate constraints for unsupported MCLKs
| * d883e16c7f ASoC: es8316: Increment max value for ALC Capture Target Volume control
| * 105af71974 memory: brcmstb_dpfe: fix testing array offset after use
| * ddc74d6ea3 ARM: dts: stm32: Shorten the AV96 HDMI sound card name
| * 392ee3cc99 arm64: dts: qcom: apq8096: fix fixed regulator name property
| * c85a076215 ARM: omap2: fix missing tick_broadcast() prototype
| * aec18da741 ARM: ep93xx: fix missing-prototype warnings
| * b574cd7e4d drm/panel: simple: fix active size for Ampire AM-480272H3TMQW-T01H
| * 02d8b008ff arm64: dts: qcom: msm8996: correct camss unit address
| * 6d103b1cc1 arm64: dts: qcom: msm8994: correct SPMI unit address
| * 160ac75a5a arm64: dts: qcom: msm8916: correct camss unit address
| * e8b131d216 ARM: dts: gta04: Move model property out of pinctrl node
| * b0b180a712 RDMA/bnxt_re: Fix to remove an unnecessary log
| * 446092f136 RDMA/bnxt_re: Remove a redundant check inside bnxt_re_update_gid
| * b54b26ac50 RDMA/bnxt_re: Use unique names while registering interrupts
| * 11bd3882c3 RDMA/bnxt_re: Fix to remove unnecessary return labels
| * 7080ef46ad RDMA/bnxt_re: Disable/kill tasklet only if it is enabled
| * 2a9895df80 arm64: dts: microchip: sparx5: do not use PSCI on reference boards
| * 726fdf47c1 bus: ti-sysc: Fix dispc quirk masking bool variables
| * 8ee24ddf45 ARM: dts: stm32: Move ethernet MAC EEPROM from SoM to carrier boards
| * 617a4da09d drm/panel: sharp-ls043t1le01: adjust mode settings
| * 3c87c98225 drm: sun4i_tcon: use devm_clk_get_enabled in `sun4i_tcon_init_clocks`
| * 39305592dc Input: adxl34x - do not hardcode interrupt trigger type
| * e629efc6d6 ARM: dts: meson8b: correct uart_B and uart_C clock references
| * bd46ade714 ARM: dts: BCM5301X: Drop "clock-names" from the SPI node
| * 20ecae1af5 drm/vram-helper: fix function names in vram helper doc
| * 46a34e1459 drm/bridge: tc358768: fix THS_TRAILCNT computation
| * f2f7d0a4a2 drm/bridge: tc358768: fix TXTAGOCNT computation
| * 8e47328fe0 drm/bridge: tc358768: fix THS_ZEROCNT computation
| * 6b9450723b drm/bridge: tc358768: fix TCLK_TRAILCNT computation
| * 33abcfbb17 drm/bridge: tc358768: Add atomic_get_input_bus_fmts() implementation
| * 43b2d11ccf drm/bridge: tc358768: fix TCLK_ZEROCNT computation
| * 46b7417189 drm/bridge: tc358768: fix PLL target frequency
| * 825b00c685 drm/bridge: tc358768: fix PLL parameters computation
| * 1b4f23fdf2 drm/bridge: tc358768: always enable HS video mode
| * 4e0fd4f54b Input: drv260x - sleep between polling GO bit
| * 2780d58448 drm/amd/display: Explicitly specify update type per plane info change
| * b2213fc60b radeon: avoid double free in ci_dpm_init()
| * 472a615e66 netlink: Add __sock_i_ino() for __netlink_diag_dump().
| * d10b380369 ipvlan: Fix return value of ipvlan_queue_xmit()
| * 5215c00968 netfilter: nf_conntrack_sip: fix the ct_sip_parse_numerical_param() return value.
| * 9bdcda7aba netfilter: conntrack: dccp: copy entire header to stack buffer, not just basic one
| * 36e07e8acf lib/ts_bm: reset initial match offset for every block of text
| * 96f2c6f272 net: nfc: Fix use-after-free caused by nfc_llcp_find_local
| * a3a1550c4d nfc: llcp: simplify llcp_sock_connect() error paths
| * cb1aa7cc56 sfc: fix crash when reading stats while NIC is resetting
| * 6ccfec84f0 net: axienet: Move reset before 64-bit DMA detection
| * bccc7ace12 gtp: Fix use-after-free in __gtp_encap_destroy().
| * 4d9cd4b330 selftests: rtnetlink: remove netdevsim device after ipsec offload test
| * 44db85c6e1 netlink: do not hard code device address lenth in fdb dumps
| * cde7b90e05 netlink: fix potential deadlock in netlink_set_err()
| * 0c9e48428f net: stmmac: fix double serdes powerdown
| * 1ba91ffa1a igc: Fix race condition in PTP tx code
| * 660d4e73ef wifi: ath9k: convert msecs to jiffies where needed
| * 150ca0768b wifi: cfg80211: rewrite merging of inherited elements
| * 4e321c18ef wifi: iwlwifi: pull from TXQs with softirqs disabled
| * 2715617c2a rtnetlink: extend RTEXT_FILTER_SKIP_STATS to IFLA_VF_INFO
| * 581401cd3c wifi: ath9k: Fix possible stall on ath9k_txq_list_has_key()
| * 6b22c2c649 memstick r592: make memstick_debug_get_tpc_name() static
| * 6cb477e722 kexec: fix a memory leak in crash_shrink_memory()
| * fdb07728d8 watchdog/perf: more properly prevent false positives with turbo modes
| * ac23d7f414 watchdog/perf: define dummy watchdog_update_hrtimer_threshold() on correct config
| * 22da8363e3 wifi: rsi: Do not set MMC_PM_KEEP_POWER in shutdown
| * b2aeb97fd4 wifi: rsi: Do not configure WoWlan in shutdown hook if not enabled
| * 1044187e72 wifi: ath9k: don't allow to overwrite ENDPOINT0 attributes
| * c10c6ea9b3 wifi: ray_cs: Fix an error handling path in ray_probe()
| * 8825991838 wifi: ray_cs: Drop useless status variable in parse_addr()
| * a66e3fd380 wifi: ray_cs: Utilize strnlen() in parse_addr()
| * 18d71562f7 wifi: wl3501_cs: Fix an error handling path in wl3501_probe()
| * b6f793de61 wl3501_cs: use eth_hw_addr_set()
| * cbd44a9e1c net: create netdev->dev_addr assignment helpers
| * 13cf0e3894 wl3501_cs: Fix misspelling and provide missing documentation
| * 5512db9bd4 wifi: atmel: Fix an error handling path in atmel_probe()
| * 86ebbcbdc7 wifi: orinoco: Fix an error handling path in orinoco_cs_probe()
| * fb7d78feb5 wifi: orinoco: Fix an error handling path in spectrum_cs_probe()
| * 8782dc2504 regulator: core: Streamline debugfs operations
| * 92bcd84941 regulator: core: Fix more error checking for debugfs_create_dir()
| * 78f390aa0e bpftool: JIT limited misreported as negative value on aarch64
| * 107e849f3c nfc: llcp: fix possible use of uninitialized variable in nfc_llcp_send_connect()
| * 0be9de2ea0 nfc: constify several pointers to u8, char and sk_buff
| * ef7fe1b5c4 libbpf: fix offsetof() and container_of() to work with CO-RE
| * b190ced50a sctp: add bpf_bypass_getsockopt proto callback
| * 08f61a3491 bpf: Remove extra lock_sock for TCP_ZEROCOPY_RECEIVE
| * c62e2ac02e wifi: mwifiex: Fix the size of a memory allocation in mwifiex_ret_802_11_scan()
| * 3ae910a375 wifi: wilc1000: fix for absent RSN capabilities WFA testcase
| * 795ef55030 spi: spi-geni-qcom: Correct CS_TOGGLE bit in SPI_TRANS_CFG
| * bd3e880dce samples/bpf: Fix buffer overflow in tcp_basertt
| * 250efb4d3f wifi: ath9k: avoid referencing uninit memory in ath9k_wmi_ctrl_rx
| * 0f3f41b475 wifi: ath9k: fix AR9003 mac hardware hang check register offset calculation
| * cbd0f41a53 igc: Enable and fix RX hash usage by netstack
| * a14cb30726 pstore/ram: Add check for kstrdup
| * 628709a057 ima: Fix build warnings
| * 16ec59c03a evm: Complete description of evm_inode_setattr()
| * cba85e1cb7 x86/mm: Fix __swp_entry_to_pte() for Xen PV guests
| * 365f546de5 perf/ibs: Fix interface via core pmu events
| * 604d6a5ff7 rcu/rcuscale: Stop kfree_scale_thread thread(s) after unloading rcuscale
| * d414e24d15 rcu/rcuscale: Move rcu_scale_*() after kfree_scale_cleanup()
| * ecc5e6dbc2 rcuscale: Move shutdown from wait_event() to wait_event_idle()
| * b62c816bdb rcuscale: Always log error message
| * 8cd9917c13 rcuscale: Console output claims too few grace periods
| * 456f783b83 thermal/drivers/sun8i: Fix some error handling paths in sun8i_ths_probe()
| * bacc49b2d5 cpufreq: intel_pstate: Fix energy_performance_preference for passive
| * a8bfe52755 ARM: 9303/1: kprobes: avoid missing-declaration warnings
| * a50b75c13d powercap: RAPL: Fix CONFIG_IOSF_MBI dependency
| * 23f6efd226 perf/arm-cmn: Fix DTC reset
| * b69868d50d PM: domains: fix integer overflow issues in genpd_parse_state()
| * ebdff09865 clocksource/drivers/cadence-ttc: Fix memory leak in ttc_timer_probe
| * a2f83a4c7c tracing/timer: Add missing hrtimer modes to decode_hrtimer_mode().
| * f1be1ed32d posix-timers: Prevent RT livelock in itimer_delete()
| * b315d57da4 irqchip/jcore-aic: Fix missing allocation of IRQ descriptors
| * 495cee0e14 irqchip/jcore-aic: Kill use of irq_create_strict_mappings()
| * 9d1cccdad0 md/raid10: fix io loss while replacement replace rdev
| * 2990e2ece1 md/raid10: fix null-ptr-deref of mreplace in raid10_sync_request
| * b1d8f38310 md/raid10: fix wrong setting of max_corr_read_errors
| * b3a0bc4a01 md/raid10: fix overflow of md/safe_mode_delay
| * 39fa14e824 md/raid10: check slab-out-of-bounds in md_bitmap_get_counter
| * 8563b58a43 blk-iocost: use spin_lock_irqsave in adjust_inuse_and_calc_cost
| * 3db97cc79b x86/resctrl: Only show tasks' pid in current pid namespace
| * 1a82005f3f fs: pipe: reveal missing function protoypes
| * f70407e8e0 nubus: Partially revert proc_create_single_data() conversion
| * 0336c8f072 drm/amdgpu: Validate VM ioctl flags.
| * c484b65f93 scripts/tags.sh: Resolve gtags empty index generation
| * 649104c834 Revert "thermal/drivers/mediatek: Use devm_of_iomap to avoid resource leak in mtk_thermal_probe"
| * 02a4c4e225 HID: logitech-hidpp: add HIDPP_QUIRK_DELAYED_INIT for the T651.
| * 9598a647ec HID: wacom: Use ktime_t rather than int when dealing with timestamps
| * 2bf70b88cc fbdev: imsttfb: Fix use after free bug in imsttfb_probe
| * 5b813734a0 video: imsttfb: check for ioremap() failures
| * 02fbf62df9 can: isotp: isotp_sendmsg(): fix return error fix on TX path
| * 8667f71131 x86/smp: Use dedicated cache-line for mwait_play_dead()
| * 1d0fe3fb5d media: atomisp: fix "variable dereferenced before check 'asd'"
* | 9710ae86ef Merge branch 'android12-5.10' into branch 'android12-5.10-lts'
* | db023c4bb0 Merge 5.10.187 into android12-5.10-lts
|\|
| * 140d69b4e4 Linux 5.10.187
| * 93df00f9d4 x86/cpu/amd: Add a Zenbleed fix
| * 191b8f9b0e x86/cpu/amd: Move the errata checking functionality up
| * 113ce5ed59 x86/microcode/AMD: Load late on both threads too
* | 44da38b39c ANDROID: GKI: fix up sysctl_vals ABI change.
* | c9606079a5 Revert "gpio: Allow per-parent interrupt data"
* | fc3985cbee Revert "gpiolib: Fix GPIO chip IRQ initialization restriction"
* | 02a1b32243 Merge 5.10.186 into android12-5.10-lts
|/
* 381518b4a9 Linux 5.10.186
* 29917a20be bpf/btf: Accept function names that contain dots
* 8b7454dd98 netfilter: nf_tables: hold mutex on netns pre_exit path
* 9e8d927cfa netfilter: nf_tables: validate registers coming from userspace.
* f19a4818a9 netfilter: nftables: statify nft_parse_register()
* 42997367cb i2c: imx-lpi2c: fix type char overflow issue when calculating the clock cycle
* 5a257f3553 x86/apic: Fix kernel panic when booting with intremap=off and x2apic_phys
* d8efc77f23 drm/radeon: fix race condition UAF in radeon_gem_set_domain_ioctl
* 485fe16508 drm/exynos: fix race condition UAF in exynos_g2d_exec_ioctl
* 0b0fdc43b2 drm/exynos: vidi: fix a wrong error return
* 32134e7a0f ARM: dts: Fix erroneous ADS touchscreen polarities
* 79cf5657be s390/purgatory: disable branch profiling
* a819de62ec ASoC: nau8824: Add quirk to active-high jack-detect
* fa08753c2d ASoC: simple-card: Add missing of_node_put() in case of error
* 9138ed7e2b spi: lpspi: disable lpspi module irq in DMA mode
* 97b6c4c1d1 s390/cio: unregister device when the only path is gone
* fe949c1662 Input: soc_button_array - add invalid acpi_index DMI quirk handling
* eaf1fa9452 usb: gadget: udc: fix NULL dereference in remove()
* 7d1a0733a5 nfcsim.c: Fix error checking for debugfs_create_dir
* dc357c0787 media: cec: core: don't set last_initiator if tx in progress
* c13573032b arm64: Add missing Set/Way CMO encodings
* 49a2b18f49 HID: wacom: Add error check to wacom_parse_and_register()
* 2b43198de0 scsi: target: iscsi: Prevent login threads from racing between each other
* 75aa3f255c gpiolib: Fix GPIO chip IRQ initialization restriction
* 304802e5b0 gpio: Allow per-parent interrupt data
* bc75968b49 sch_netem: acquire qdisc lock in netem_change()
* caddeadd0d Revert "net: phy: dp83867: perform soft reset and retain established link"
* 5702afa2c3 netfilter: nfnetlink_osf: fix module autoload
* 3d5c09c782 netfilter: nf_tables: disallow element updates of bound anonymous sets
* 2a90da8e0d netfilter: nft_set_pipapo: .walk does not deal with generations
* 792bfe26a6 be2net: Extend xmit workaround to BE3 chip
* cebb5cee09 net: dsa: mt7530: fix trapping frames on non-MT7621 SoC MT7530 switch
* 7a1ae00005 ipvs: align inner_mac_header for encapsulation
* f2547bc716 mmc: usdhi60rol0: fix deferred probing
* 4a99e35c5a mmc: sh_mmcif: fix deferred probing
* c2278de138 mmc: sdhci-acpi: fix deferred probing
* f6e176ef89 mmc: owl: fix deferred probing
* f29d0ab0e6 mmc: omap_hsmmc: fix deferred probing
* 65d9318e3d mmc: omap: fix deferred probing
* 9ad3c21fb6 mmc: mvsdio: fix deferred probing
* 9b0417fd40 mmc: mtk-sd: fix deferred probing
* ced13bc50e net: qca_spi: Avoid high load if QCA7000 is not available
* b1b9c81e29 xfrm: Linearize the skb after offloading if needed.
* 31cd0d4a44 selftests: net: fcnal-test: check if FIPS mode is enabled
* 2af75a36af selftests: net: vrf-xfrm-tests: change authentication and encryption algos
* 07fbbddae5 xfrm: fix inbound ipv4/udp/esp packets to UDPv6 dualstack sockets
* 562800447f bpf: Fix verifier id tracking of scalars on spill
* 3b0a96db67 bpf: track immediate values written to stack by BPF_ST instruction
* bff7824db6 xfrm: Ensure policies always checked on XFRM-I input path
* 01af67ed83 xfrm: interface: rename xfrm_interface.c to xfrm_interface_core.c
* cdaa6e1105 xfrm: Treat already-verified secpath entries as optional
* 47be2931c4 ieee802154: hwsim: Fix possible memory leaks
* 051d642133 memfd: check for non-NULL file_seals in memfd_create() syscall
* 1ac6e9ee84 sysctl: move some boundary constants from sysctl.c to sysctl_vals
* e1aa3fe3e2 mm/pagealloc: sysctl: change watermark_scale_factor max limit to 30%
* ad10dd2113 x86/mm: Avoid using set_pgd() outside of real PGD pages
* 4de2093674 nilfs2: prevent general protection fault in nilfs_clear_dirty_page()
* 3845c38417 io_uring/net: disable partial retries for recvmsg with cmsg
* 826ee9fa36 io_uring/net: clear msg_controllen on partial sendmsg retry
* 5fdea4468f io_uring/net: save msghdr->msg_control for retries
* 5a7101d8fa writeback: fix dereferencing NULL mapping->host on writeback_page_template
* f00cd687c2 regmap: spi-avmm: Fix regmap_bus max_raw_write
* bc35f93e4b regulator: pca9450: Fix LDO3OUT and LDO4OUT MASK
* 5938470f9c ip_tunnels: allow VXLAN/GENEVE to inherit TOS/TTL from VLAN
* 2e454015ca mmc: mmci: stm32: fix max busy timeout calculation
* 1be288fd3b mmc: meson-gx: remove redundant mmc_request_done() call from irq context
* 1b97630cd9 mmc: sdhci-msm: Disable broken 64-bit DMA on MSM8916
* 63608437a8 cgroup: Do not corrupt task iteration when rebinding subsystem
* 988d06f5eb PCI: hv: Fix a race condition in hv_irq_unmask() that can cause panic
* 8f2d5ebdfe PCI: hv: Remove the useless hv_pcichild_state from struct hv_pci_dev
* 8b74846769 Revert "PCI: hv: Fix a timing issue which causes kdump to fail occasionally"
* 79ceb758e3 PCI: hv: Fix a race condition bug in hv_pci_query_relations()
* 8b8c9812c0 Drivers: hv: vmbus: Fix vmbus_wait_for_unload() to scan present CPUs
* b435298349 nilfs2: fix buffer corruption due to concurrent device reads
* 524a2c0bcf selftests: mptcp: join: skip check if MIB counter not supported
* e508d9cef8 selftests: mptcp: pm nl: remove hardcoded default limits
* 4c4ca42418 selftests: mptcp: lib: skip if not below kernel version
* 6d20cfbc57 selftests: mptcp: lib: skip if missing symbol
* 3cc7935d32 tick/common: Align tick period during sched_timer setup
* db4ab0c97a tracing: Add tracing_reset_all_online_cpus_unlocked() function
* 9ced730490 net/sched: Refactor qdisc_graft() for ingress and clsact Qdiscs
* b1b42fff8a drm/amd/display: fix the system hang while disable PSR

Change-Id: I0c8675eb9b259cf7631e968dd66c31d3e16d31e9
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Signed-off-by: Todd Kjos <tkjos@google.com>
2023-09-27 19:46:11 +00:00
Lincheng Yang
6356ed35b9 ANDROID: add vendor hook of add/delete/iterate node for swap_avail_heads
Our Android phones occur Panic as follows:

[77522.303024][ T9734] Call trace:
[77522.303039][ T9734] dump_backtrace.cfi_jt+0x0/0x8
[77522.303052][ T9734] dump_stack_lvl+0xc4/0x140
[77522.303061][ T9734] dump_stack+0x1c/0x2c
[77522.303123][ T9734] mrdump_common_die+0x3a8/0x544 [mrdump]
[77522.303177][ T9734] ipanic_die+0x24/0x38 [mrdump]
[77522.303189][ T9734] die+0x340/0x698
[77522.303199][ T9734] bug_handler+0x48/0x108
[77522.303210][ T9734] brk_handler+0xac/0x1a8
[77522.303221][ T9734] do_debug_exception+0xe0/0x1e0
[77522.303233][ T9734] el1_dbg+0x38/0x54
[77522.303242][ T9734] el1_sync_handler+0x40/0x88
[77522.303255][ T9734] el1_sync+0x8c/0x140
[77522.303264][ T9734] plist_requeue+0xd4/0x110
[77522.303297][ T9734] tran_get_swap_pages+0xc8/0x364 [memfusion]
[77522.303329][ T9734] probe_android_vh_get_swap_page+0x1b4/0x220 [memfusion]
[77522.303342][ T9734] get_swap_page+0x258/0x304
[77522.303352][ T9734] shrink_page_list+0xe00/0x1e0c
[77522.303361][ T9734] shrink_inactive_list+0x2f4/0xac8
[77522.303373][ T9734] shrink_lruvec+0x1a4/0x34c
[77522.303383][ T9734] shrink_node_memcgs+0x84/0x3b0
[77522.303391][ T9734] shrink_node+0x2c4/0x6e4
[77522.303400][ T9734] shrink_zones+0x16c/0x29c
[77522.303410][ T9734] do_try_to_free_pages+0xe4/0x2bc
[77522.303418][ T9734] try_to_free_pages+0x388/0x7b4
[77522.303429][ T9734] __alloc_pages_direct_reclaim+0x88/0x278
[77522.303438][ T9734] __alloc_pages_slowpath+0x464/0xb24
[77522.303447][ T9734] __alloc_pages_nodemask+0x1f4/0x3dc
[77522.303458][ T9734] do_anonymous_page+0x164/0x914
[77522.303466][ T9734] handle_pte_fault+0x15c/0x9f8
[77522.303476][ T9734] ___handle_speculative_fault+0x234/0xe18
[77522.303485][ T9734] __handle_speculative_fault+0x78/0x21c
[77522.303497][ T9734] do_page_fault+0x36c/0x754
[77522.303506][ T9734] do_translation_fault+0x48/0x64
[77522.303514][ T9734] do_mem_abort+0x6c/0x164
[77522.303522][ T9734] el0_da+0x24/0x34
[77522.303531][ T9734] el0_sync_handler+0xc8/0xf0
[77522.303539][ T9734] el0_sync+0x1b4/0x1c0

The analysis shows that when we iterate the swap_avail_heads list, we get
node A, but before we access node A, node A is maybe deleted, and by the time
we actually access node A, it no longer exists, as follows:

            CPU1 thread1                                 CPU2 thread2
plist_for_each_entry_safe()
get si->avail_lists[node] from swap_avail_heads
                                             remove si->avail_lists[node] from swap_avail_heads
plist_requeue(&si->avail_lists[node])
BUG_ON(plist_node_empty(node)); // trigger

Due to when we use vendor hook of get_swap_page, the get_swap_pages() function
is overridden, use our own spin_lock to protect when iterate swap_avail_heads
list, but now use native swap_avail_lock spin_lock protect when the
swap_avail_heads list to add and delete nodes, so there will be concurrent
access.

So add vendor hook of add/delete/iterate node for avail_list, in this way, we
can use our own spin_lock to protect the swap_avail_heads list to add, delete
and iterate node.

Due to enable_swap_info function to call vendor hook of add_to_avail_list,
need first init swap_avail_heads, so also add vendor hook of
swap_avail_heads_init.

Due to the vendor hook of __cgroup_throttle_swaprate need to call
blkcg_schedule_throttle function, so export it also.

Bug: 225795494
Change-Id: I03107cbda6310fa7ae85e41b8cf1fa8225cafe78
Signed-off-by: Lincheng Yang <lincheng.yang@transsion.com>
Suggested-by: Bing Han <bing.han@transsion.com>
2023-09-15 19:58:39 +00:00
Greg Kroah-Hartman
477f5e6b9e This is the 5.10.188 stable release
-----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCAAdFiEEZH8oZUiU471FcZm+ONu9yGCSaT4FAmTCEmYACgkQONu9yGCS
 aT5ETA/+MGhe+GasO74Gvx1MaSVJrPZgPzInUg5UoYIkf+N3BfNqH9KVrY/zFKfU
 mKNQSQDsli+WG8agHVzoa4lh3ZFHbiUrNx14n+3A8lZ0X5s31fqTLXRvKy9BCu4t
 8OQW6nuMv22SVDd40F5ciroNmAbDquDfUQK4KbETNRPU2Yzvd5VEZiCY9aQAGFbc
 YnqBbx1Qc5EQKmzoBmEiup2j04SWXwMPQERKdFVZ1jrjC3hC8MFmL62YwfbCH4gY
 faDSZPj++/V5c++bP6oG8QhfrQS+WYGwFmEJpf4GUJ8dxxJC9Ao9CwcXbd2jOjfz
 Tk0gNQ9YPs+a2gexAnaHsJqKXn+dcRvkIMzmArApZv73PET0LgMv8N7s3OB5E9ei
 K2ft+nfXs5NCLRjPFCqL9nAeclj8ZX92B4d4mrpbqHZ+fFBiHMb0H/aGxfCAR0MJ
 BuW1dWQJykR2crhzQ1PJr3OthnL9O4Nl+bBAAuOu6NwqiALFW57uKXQ/2xfhPPbI
 qi0cTyXNYYY28kRdprERyV1w4K8W8V6L2YUt3N8LWuPNsI9pHSSQQDKru2JIR1T5
 rHeC41JSR6iw8rBXtkCj1YhGbH5P8CP3fxlikuKo3Q4PHCjVJo8ZpzYU/Ci8FFCL
 g/g6DLb9/AHtIhJ8WgcRcxbRNkdyGUc2w9uh6c3rBVS4gwFm/44=
 =2pvu
 -----END PGP SIGNATURE-----

Merge 5.10.188 into android12-5.10-lts

Changes in 5.10.188
	media: atomisp: fix "variable dereferenced before check 'asd'"
	x86/smp: Use dedicated cache-line for mwait_play_dead()
	can: isotp: isotp_sendmsg(): fix return error fix on TX path
	video: imsttfb: check for ioremap() failures
	fbdev: imsttfb: Fix use after free bug in imsttfb_probe
	HID: wacom: Use ktime_t rather than int when dealing with timestamps
	HID: logitech-hidpp: add HIDPP_QUIRK_DELAYED_INIT for the T651.
	Revert "thermal/drivers/mediatek: Use devm_of_iomap to avoid resource leak in mtk_thermal_probe"
	scripts/tags.sh: Resolve gtags empty index generation
	drm/amdgpu: Validate VM ioctl flags.
	nubus: Partially revert proc_create_single_data() conversion
	fs: pipe: reveal missing function protoypes
	x86/resctrl: Only show tasks' pid in current pid namespace
	blk-iocost: use spin_lock_irqsave in adjust_inuse_and_calc_cost
	md/raid10: check slab-out-of-bounds in md_bitmap_get_counter
	md/raid10: fix overflow of md/safe_mode_delay
	md/raid10: fix wrong setting of max_corr_read_errors
	md/raid10: fix null-ptr-deref of mreplace in raid10_sync_request
	md/raid10: fix io loss while replacement replace rdev
	irqchip/jcore-aic: Kill use of irq_create_strict_mappings()
	irqchip/jcore-aic: Fix missing allocation of IRQ descriptors
	posix-timers: Prevent RT livelock in itimer_delete()
	tracing/timer: Add missing hrtimer modes to decode_hrtimer_mode().
	clocksource/drivers/cadence-ttc: Fix memory leak in ttc_timer_probe
	PM: domains: fix integer overflow issues in genpd_parse_state()
	perf/arm-cmn: Fix DTC reset
	powercap: RAPL: Fix CONFIG_IOSF_MBI dependency
	ARM: 9303/1: kprobes: avoid missing-declaration warnings
	cpufreq: intel_pstate: Fix energy_performance_preference for passive
	thermal/drivers/sun8i: Fix some error handling paths in sun8i_ths_probe()
	rcuscale: Console output claims too few grace periods
	rcuscale: Always log error message
	rcuscale: Move shutdown from wait_event() to wait_event_idle()
	rcu/rcuscale: Move rcu_scale_*() after kfree_scale_cleanup()
	rcu/rcuscale: Stop kfree_scale_thread thread(s) after unloading rcuscale
	perf/ibs: Fix interface via core pmu events
	x86/mm: Fix __swp_entry_to_pte() for Xen PV guests
	evm: Complete description of evm_inode_setattr()
	ima: Fix build warnings
	pstore/ram: Add check for kstrdup
	igc: Enable and fix RX hash usage by netstack
	wifi: ath9k: fix AR9003 mac hardware hang check register offset calculation
	wifi: ath9k: avoid referencing uninit memory in ath9k_wmi_ctrl_rx
	samples/bpf: Fix buffer overflow in tcp_basertt
	spi: spi-geni-qcom: Correct CS_TOGGLE bit in SPI_TRANS_CFG
	wifi: wilc1000: fix for absent RSN capabilities WFA testcase
	wifi: mwifiex: Fix the size of a memory allocation in mwifiex_ret_802_11_scan()
	bpf: Remove extra lock_sock for TCP_ZEROCOPY_RECEIVE
	sctp: add bpf_bypass_getsockopt proto callback
	libbpf: fix offsetof() and container_of() to work with CO-RE
	nfc: constify several pointers to u8, char and sk_buff
	nfc: llcp: fix possible use of uninitialized variable in nfc_llcp_send_connect()
	bpftool: JIT limited misreported as negative value on aarch64
	regulator: core: Fix more error checking for debugfs_create_dir()
	regulator: core: Streamline debugfs operations
	wifi: orinoco: Fix an error handling path in spectrum_cs_probe()
	wifi: orinoco: Fix an error handling path in orinoco_cs_probe()
	wifi: atmel: Fix an error handling path in atmel_probe()
	wl3501_cs: Fix misspelling and provide missing documentation
	net: create netdev->dev_addr assignment helpers
	wl3501_cs: use eth_hw_addr_set()
	wifi: wl3501_cs: Fix an error handling path in wl3501_probe()
	wifi: ray_cs: Utilize strnlen() in parse_addr()
	wifi: ray_cs: Drop useless status variable in parse_addr()
	wifi: ray_cs: Fix an error handling path in ray_probe()
	wifi: ath9k: don't allow to overwrite ENDPOINT0 attributes
	wifi: rsi: Do not configure WoWlan in shutdown hook if not enabled
	wifi: rsi: Do not set MMC_PM_KEEP_POWER in shutdown
	watchdog/perf: define dummy watchdog_update_hrtimer_threshold() on correct config
	watchdog/perf: more properly prevent false positives with turbo modes
	kexec: fix a memory leak in crash_shrink_memory()
	memstick r592: make memstick_debug_get_tpc_name() static
	wifi: ath9k: Fix possible stall on ath9k_txq_list_has_key()
	rtnetlink: extend RTEXT_FILTER_SKIP_STATS to IFLA_VF_INFO
	wifi: iwlwifi: pull from TXQs with softirqs disabled
	wifi: cfg80211: rewrite merging of inherited elements
	wifi: ath9k: convert msecs to jiffies where needed
	igc: Fix race condition in PTP tx code
	net: stmmac: fix double serdes powerdown
	netlink: fix potential deadlock in netlink_set_err()
	netlink: do not hard code device address lenth in fdb dumps
	selftests: rtnetlink: remove netdevsim device after ipsec offload test
	gtp: Fix use-after-free in __gtp_encap_destroy().
	net: axienet: Move reset before 64-bit DMA detection
	sfc: fix crash when reading stats while NIC is resetting
	nfc: llcp: simplify llcp_sock_connect() error paths
	net: nfc: Fix use-after-free caused by nfc_llcp_find_local
	lib/ts_bm: reset initial match offset for every block of text
	netfilter: conntrack: dccp: copy entire header to stack buffer, not just basic one
	netfilter: nf_conntrack_sip: fix the ct_sip_parse_numerical_param() return value.
	ipvlan: Fix return value of ipvlan_queue_xmit()
	netlink: Add __sock_i_ino() for __netlink_diag_dump().
	radeon: avoid double free in ci_dpm_init()
	drm/amd/display: Explicitly specify update type per plane info change
	Input: drv260x - sleep between polling GO bit
	drm/bridge: tc358768: always enable HS video mode
	drm/bridge: tc358768: fix PLL parameters computation
	drm/bridge: tc358768: fix PLL target frequency
	drm/bridge: tc358768: fix TCLK_ZEROCNT computation
	drm/bridge: tc358768: Add atomic_get_input_bus_fmts() implementation
	drm/bridge: tc358768: fix TCLK_TRAILCNT computation
	drm/bridge: tc358768: fix THS_ZEROCNT computation
	drm/bridge: tc358768: fix TXTAGOCNT computation
	drm/bridge: tc358768: fix THS_TRAILCNT computation
	drm/vram-helper: fix function names in vram helper doc
	ARM: dts: BCM5301X: Drop "clock-names" from the SPI node
	ARM: dts: meson8b: correct uart_B and uart_C clock references
	Input: adxl34x - do not hardcode interrupt trigger type
	drm: sun4i_tcon: use devm_clk_get_enabled in `sun4i_tcon_init_clocks`
	drm/panel: sharp-ls043t1le01: adjust mode settings
	ARM: dts: stm32: Move ethernet MAC EEPROM from SoM to carrier boards
	bus: ti-sysc: Fix dispc quirk masking bool variables
	arm64: dts: microchip: sparx5: do not use PSCI on reference boards
	RDMA/bnxt_re: Disable/kill tasklet only if it is enabled
	RDMA/bnxt_re: Fix to remove unnecessary return labels
	RDMA/bnxt_re: Use unique names while registering interrupts
	RDMA/bnxt_re: Remove a redundant check inside bnxt_re_update_gid
	RDMA/bnxt_re: Fix to remove an unnecessary log
	ARM: dts: gta04: Move model property out of pinctrl node
	arm64: dts: qcom: msm8916: correct camss unit address
	arm64: dts: qcom: msm8994: correct SPMI unit address
	arm64: dts: qcom: msm8996: correct camss unit address
	drm/panel: simple: fix active size for Ampire AM-480272H3TMQW-T01H
	ARM: ep93xx: fix missing-prototype warnings
	ARM: omap2: fix missing tick_broadcast() prototype
	arm64: dts: qcom: apq8096: fix fixed regulator name property
	ARM: dts: stm32: Shorten the AV96 HDMI sound card name
	memory: brcmstb_dpfe: fix testing array offset after use
	ASoC: es8316: Increment max value for ALC Capture Target Volume control
	ASoC: es8316: Do not set rate constraints for unsupported MCLKs
	ARM: dts: meson8: correct uart_B and uart_C clock references
	soc/fsl/qe: fix usb.c build errors
	IB/hfi1: Use bitmap_zalloc() when applicable
	IB/hfi1: Fix sdma.h tx->num_descs off-by-one errors
	IB/hfi1: Fix wrong mmu_node used for user SDMA packet after invalidate
	RDMA: Remove uverbs_ex_cmd_mask values that are linked to functions
	RDMA/hns: Fix coding style issues
	RDMA/hns: Use refcount_t APIs for HEM
	RDMA/hns: Clean the hardware related code for HEM
	RDMA/hns: Fix hns_roce_table_get return value
	ARM: dts: iwg20d-q7-common: Fix backlight pwm specifier
	arm64: dts: renesas: ulcb-kf: Remove flow control for SCIF1
	fbdev: omapfb: lcd_mipid: Fix an error handling path in mipid_spi_probe()
	arm64: dts: ti: k3-j7200: Fix physical address of pin
	ARM: dts: stm32: Fix audio routing on STM32MP15xx DHCOM PDK2
	ARM: dts: stm32: fix i2s endpoint format property for stm32mp15xx-dkx
	hwmon: (gsc-hwmon) fix fan pwm temperature scaling
	hwmon: (adm1275) enable adm1272 temperature reporting
	hwmon: (adm1275) Allow setting sample averaging
	hwmon: (pmbus/adm1275) Fix problems with temperature monitoring on ADM1272
	ARM: dts: BCM5301X: fix duplex-full => full-duplex
	drm/amdkfd: Fix potential deallocation of previously deallocated memory.
	drm/radeon: fix possible division-by-zero errors
	amdgpu: validate offset_in_bo of drm_amdgpu_gem_va
	RDMA/bnxt_re: wraparound mbox producer index
	RDMA/bnxt_re: Avoid calling wake_up threads from spin_lock context
	clk: imx: clk-imx8mn: fix memory leak in imx8mn_clocks_probe
	clk: imx: clk-imx8mp: improve error handling in imx8mp_clocks_probe()
	clk: tegra: tegra124-emc: Fix potential memory leak
	ALSA: ac97: Fix possible NULL dereference in snd_ac97_mixer
	drm/msm/dpu: do not enable color-management if DSPPs are not available
	drm/msm/dp: Free resources after unregistering them
	clk: vc5: check memory returned by kasprintf()
	clk: cdce925: check return value of kasprintf()
	clk: si5341: Allow different output VDD_SEL values
	clk: si5341: Add sysfs properties to allow checking/resetting device faults
	clk: si5341: return error if one synth clock registration fails
	clk: si5341: check return value of {devm_}kasprintf()
	clk: si5341: free unused memory on probe failure
	clk: keystone: sci-clk: check return value of kasprintf()
	clk: ti: clkctrl: check return value of kasprintf()
	drivers: meson: secure-pwrc: always enable DMA domain
	ovl: update of dentry revalidate flags after copy up
	ASoC: imx-audmix: check return value of devm_kasprintf()
	PCI: cadence: Fix Gen2 Link Retraining process
	scsi: qedf: Fix NULL dereference in error handling
	pinctrl: bcm2835: Handle gpiochip_add_pin_range() errors
	PCI/ASPM: Disable ASPM on MFD function removal to avoid use-after-free
	scsi: 3w-xxxx: Add error handling for initialization failure in tw_probe()
	PCI: pciehp: Cancel bringup sequence if card is not present
	PCI: ftpci100: Release the clock resources
	PCI: Add pci_clear_master() stub for non-CONFIG_PCI
	perf bench: Use unbuffered output when pipe/tee'ing to a file
	perf bench: Add missing setlocale() call to allow usage of %'d style formatting
	pinctrl: cherryview: Return correct value if pin in push-pull mode
	kcsan: Don't expect 64 bits atomic builtins from 32 bits architectures
	perf script: Fixup 'struct evsel_script' method prefix
	perf script: Fix allocation of evsel->priv related to per-event dump files
	perf dwarf-aux: Fix off-by-one in die_get_varname()
	pinctrl: at91-pio4: check return value of devm_kasprintf()
	powerpc/powernv/sriov: perform null check on iov before dereferencing iov
	mm: rename pud_page_vaddr to pud_pgtable and make it return pmd_t *
	mm: rename p4d_page_vaddr to p4d_pgtable and make it return pud_t *
	powerpc/book3s64/mm: Fix DirectMap stats in /proc/meminfo
	powerpc/mm/dax: Fix the condition when checking if altmap vmemap can cross-boundary
	hwrng: virtio - add an internal buffer
	hwrng: virtio - don't wait on cleanup
	hwrng: virtio - don't waste entropy
	hwrng: virtio - always add a pending request
	hwrng: virtio - Fix race on data_avail and actual data
	crypto: nx - fix build warnings when DEBUG_FS is not enabled
	modpost: fix section mismatch message for R_ARM_ABS32
	modpost: fix section mismatch message for R_ARM_{PC24,CALL,JUMP24}
	crypto: marvell/cesa - Fix type mismatch warning
	modpost: fix off by one in is_executable_section()
	ARC: define ASM_NL and __ALIGN(_STR) outside #ifdef __ASSEMBLY__ guard
	NFSv4.1: freeze the session table upon receiving NFS4ERR_BADSESSION
	dax: Fix dax_mapping_release() use after free
	dax: Introduce alloc_dev_dax_id()
	hwrng: st - keep clock enabled while hwrng is registered
	io_uring: ensure IOPOLL locks around deferred work
	USB: serial: option: add LARA-R6 01B PIDs
	usb: dwc3: gadget: Propagate core init errors to UDC during pullup
	phy: tegra: xusb: Clear the driver reference in usb-phy dev
	block: fix signed int overflow in Amiga partition support
	block: change all __u32 annotations to __be32 in affs_hardblocks.h
	SUNRPC: Fix UAF in svc_tcp_listen_data_ready()
	w1: w1_therm: fix locking behavior in convert_t
	w1: fix loop in w1_fini()
	sh: j2: Use ioremap() to translate device tree address into kernel memory
	serial: 8250: omap: Fix freeing of resources on failed register
	clk: qcom: gcc-ipq6018: Use floor ops for sdcc clocks
	media: usb: Check az6007_read() return value
	media: videodev2.h: Fix struct v4l2_input tuner index comment
	media: usb: siano: Fix warning due to null work_func_t function pointer
	clk: qcom: reset: Allow specifying custom reset delay
	clk: qcom: reset: support resetting multiple bits
	clk: qcom: ipq6018: fix networking resets
	usb: dwc3: qcom: Fix potential memory leak
	usb: gadget: u_serial: Add null pointer check in gserial_suspend
	extcon: Fix kernel doc of property fields to avoid warnings
	extcon: Fix kernel doc of property capability fields to avoid warnings
	usb: phy: phy-tahvo: fix memory leak in tahvo_usb_probe()
	usb: hide unused usbfs_notify_suspend/resume functions
	serial: 8250: lock port for stop_rx() in omap8250_irq()
	serial: 8250: lock port for UART_IER access in omap8250_irq()
	kernfs: fix missing kernfs_idr_lock to remove an ID from the IDR
	coresight: Fix loss of connection info when a module is unloaded
	mfd: rt5033: Drop rt5033-battery sub-device
	media: venus: helpers: Fix ALIGN() of non power of two
	media: atomisp: gmin_platform: fix out_len in gmin_get_config_dsm_var()
	KVM: s390: fix KVM_S390_GET_CMMA_BITS for GFNs in memslot holes
	usb: dwc3: qcom: Release the correct resources in dwc3_qcom_remove()
	usb: dwc3: qcom: Fix an error handling path in dwc3_qcom_probe()
	usb: common: usb-conn-gpio: Set last role to unknown before initial detection
	usb: dwc3-meson-g12a: Fix an error handling path in dwc3_meson_g12a_probe()
	mfd: intel-lpss: Add missing check for platform_get_resource
	Revert "usb: common: usb-conn-gpio: Set last role to unknown before initial detection"
	serial: 8250_omap: Use force_suspend and resume for system suspend
	test_firmware: return ENOMEM instead of ENOSPC on failed memory allocation
	mfd: stmfx: Fix error path in stmfx_chip_init
	mfd: stmfx: Nullify stmfx->vdd in case of error
	KVM: s390: vsie: fix the length of APCB bitmap
	mfd: stmpe: Only disable the regulators if they are enabled
	phy: tegra: xusb: check return value of devm_kzalloc()
	pwm: imx-tpm: force 'real_period' to be zero in suspend
	pwm: sysfs: Do not apply state to already disabled PWMs
	rtc: st-lpc: Release some resources in st_rtc_probe() in case of error
	media: cec: i2c: ch7322: also select REGMAP
	sctp: fix potential deadlock on &net->sctp.addr_wq_lock
	Add MODULE_FIRMWARE() for FIRMWARE_TG357766.
	net: dsa: vsc73xx: fix MTU configuration
	spi: bcm-qspi: return error if neither hif_mspi nor mspi is available
	mailbox: ti-msgmgr: Fill non-message tx data fields with 0x0
	f2fs: fix error path handling in truncate_dnode()
	octeontx2-af: Fix mapping for NIX block from CGX connection
	powerpc: allow PPC_EARLY_DEBUG_CPM only when SERIAL_CPM=y
	net: bridge: keep ports without IFF_UNICAST_FLT in BR_PROMISC mode
	tcp: annotate data races in __tcp_oow_rate_limited()
	xsk: Honor SO_BINDTODEVICE on bind
	net/sched: act_pedit: Add size check for TCA_PEDIT_PARMS_EX
	pptp: Fix fib lookup calls.
	net: dsa: tag_sja1105: fix MAC DA patching from meta frames
	s390/qeth: Fix vipa deletion
	sh: dma: Fix DMA channel offset calculation
	apparmor: fix missing error check for rhashtable_insert_fast
	i2c: xiic: Defer xiic_wakeup() and __xiic_start_xfer() in xiic_process()
	i2c: xiic: Don't try to handle more interrupt events after error
	ALSA: jack: Fix mutex call in snd_jack_report()
	i2c: qup: Add missing unwind goto in qup_i2c_probe()
	NFSD: add encoding of op_recall flag for write delegation
	io_uring: wait interruptibly for request completions on exit
	mmc: core: disable TRIM on Kingston EMMC04G-M627
	mmc: core: disable TRIM on Micron MTFC4GACAJCN-1M
	mmc: mmci: Set PROBE_PREFER_ASYNCHRONOUS
	mmc: sdhci: fix DMA configure compatibility issue when 64bit DMA mode is used.
	bcache: fixup btree_cache_wait list damage
	bcache: Remove unnecessary NULL point check in node allocations
	bcache: Fix __bch_btree_node_alloc to make the failure behavior consistent
	um: Use HOST_DIR for mrproper
	integrity: Fix possible multiple allocation in integrity_inode_get()
	autofs: use flexible array in ioctl structure
	shmem: use ramfs_kill_sb() for kill_sb method of ramfs-based tmpfs
	jffs2: reduce stack usage in jffs2_build_xattr_subsystem()
	fs: avoid empty option when generating legacy mount string
	ext4: Remove ext4 locking of moved directory
	Revert "f2fs: fix potential corruption when moving a directory"
	fs: Establish locking order for unrelated directories
	fs: Lock moved directories
	btrfs: add handling for RAID1C23/DUP to btrfs_reduce_alloc_profile
	btrfs: fix race when deleting quota root from the dirty cow roots list
	ASoC: mediatek: mt8173: Fix irq error path
	ASoC: mediatek: mt8173: Fix snd_soc_component_initialize error path
	ARM: orion5x: fix d2net gpio initialization
	leds: trigger: netdev: Recheck NETDEV_LED_MODE_LINKUP on dev rename
	fs: no need to check source
	fanotify: disallow mount/sb marks on kernel internal pseudo fs
	tpm, tpm_tis: Claim locality in interrupt handler
	selftests/bpf: Add verifier test for PTR_TO_MEM spill
	block: add overflow checks for Amiga partition support
	sh: pgtable-3level: Fix cast to pointer from integer of different size
	netfilter: nf_tables: use net_generic infra for transaction data
	netfilter: nf_tables: add rescheduling points during loop detection walks
	netfilter: nf_tables: incorrect error path handling with NFT_MSG_NEWRULE
	netfilter: nf_tables: fix chain binding transaction logic
	netfilter: nf_tables: add NFT_TRANS_PREPARE_ERROR to deal with bound set/chain
	netfilter: nf_tables: reject unbound anonymous set before commit phase
	netfilter: nf_tables: reject unbound chain set before commit phase
	netfilter: nftables: rename set element data activation/deactivation functions
	netfilter: nf_tables: drop map element references from preparation phase
	netfilter: nf_tables: unbind non-anonymous set if rule construction fails
	netfilter: nf_tables: fix scheduling-while-atomic splat
	netfilter: conntrack: Avoid nf_ct_helper_hash uses after free
	netfilter: nf_tables: do not ignore genmask when looking up chain by id
	netfilter: nf_tables: prevent OOB access in nft_byteorder_eval
	wireguard: queueing: use saner cpu selection wrapping
	wireguard: netlink: send staged packets when setting initial private key
	tty: serial: fsl_lpuart: add earlycon for imx8ulp platform
	rcu-tasks: Mark ->trc_reader_nesting data races
	rcu-tasks: Mark ->trc_reader_special.b.need_qs data races
	rcu-tasks: Simplify trc_read_check_handler() atomic operations
	block/partition: fix signedness issue for Amiga partitions
	io_uring: Use io_schedule* in cqring wait
	io_uring: add reschedule point to handle_tw_list()
	net: lan743x: Don't sleep in atomic context
	workqueue: clean up WORK_* constant types, clarify masking
	drm/panel: simple: Add connector_type for innolux_at043tn24
	drm/panel: simple: Add Powertip PH800480T013 drm_display_mode flags
	igc: Remove delay during TX ring configuration
	net/mlx5e: fix double free in mlx5e_destroy_flow_table
	net/mlx5e: Check for NOT_READY flag state after locking
	igc: set TP bit in 'supported' and 'advertising' fields of ethtool_link_ksettings
	scsi: qla2xxx: Fix error code in qla2x00_start_sp()
	net: mvneta: fix txq_map in case of txq_number==1
	net/sched: cls_fw: Fix improper refcount update leads to use-after-free
	gve: Set default duplex configuration to full
	ionic: remove WARN_ON to prevent panic_on_warn
	net: bgmac: postpone turning IRQs off to avoid SoC hangs
	net: prevent skb corruption on frag list segmentation
	icmp6: Fix null-ptr-deref of ip6_null_entry->rt6i_idev in icmp6_dev().
	udp6: fix udp6_ehashfn() typo
	ntb: idt: Fix error handling in idt_pci_driver_init()
	NTB: amd: Fix error handling in amd_ntb_pci_driver_init()
	ntb: intel: Fix error handling in intel_ntb_pci_driver_init()
	NTB: ntb_transport: fix possible memory leak while device_register() fails
	NTB: ntb_tool: Add check for devm_kcalloc
	ipv6/addrconf: fix a potential refcount underflow for idev
	platform/x86: wmi: remove unnecessary argument
	platform/x86: wmi: use guid_t and guid_equal()
	platform/x86: wmi: move variables
	platform/x86: wmi: Break possible infinite loop when parsing GUID
	igc: Fix launchtime before start of cycle
	igc: Fix inserting of empty frame for launchtime
	riscv: bpf: Move bpf_jit_alloc_exec() and bpf_jit_free_exec() to core
	riscv: bpf: Avoid breaking W^X
	bpf, riscv: Support riscv jit to provide bpf_line_info
	riscv, bpf: Fix inconsistent JIT image generation
	erofs: avoid infinite loop in z_erofs_do_read_page() when reading beyond EOF
	wifi: airo: avoid uninitialized warning in airo_get_rate()
	net/sched: flower: Ensure both minimum and maximum ports are specified
	netdevsim: fix uninitialized data in nsim_dev_trap_fa_cookie_write()
	net/sched: make psched_mtu() RTNL-less safe
	net/sched: sch_qfq: refactor parsing of netlink parameters
	net/sched: sch_qfq: account for stab overhead in qfq_enqueue
	nvme-pci: fix DMA direction of unmapping integrity data
	f2fs: fix to avoid NULL pointer dereference f2fs_write_end_io()
	pinctrl: amd: Fix mistake in handling clearing pins at startup
	pinctrl: amd: Detect internal GPIO0 debounce handling
	pinctrl: amd: Only use special debounce behavior for GPIO 0
	tpm: tpm_vtpm_proxy: fix a race condition in /dev/vtpmx creation
	mtd: rawnand: meson: fix unaligned DMA buffers handling
	net: bcmgenet: Ensure MDIO unregistration has clocks enabled
	powerpc: Fail build if using recordmcount with binutils v2.37
	misc: fastrpc: Create fastrpc scalar with correct buffer count
	erofs: fix compact 4B support for 16k block size
	MIPS: Loongson: Fix cpu_probe_loongson() again
	ext4: Fix reusing stale buffer heads from last failed mounting
	ext4: fix wrong unit use in ext4_mb_clear_bb
	ext4: get block from bh in ext4_free_blocks for fast commit replay
	ext4: fix wrong unit use in ext4_mb_new_blocks
	ext4: only update i_reserved_data_blocks on successful block allocation
	jfs: jfs_dmap: Validate db_l2nbperpage while mounting
	hwrng: imx-rngc - fix the timeout for init and self check
	PCI/PM: Avoid putting EloPOS E2/S2/H2 PCIe Ports in D3cold
	PCI: Add function 1 DMA alias quirk for Marvell 88SE9235
	PCI: qcom: Disable write access to read only registers for IP v2.3.3
	PCI: rockchip: Assert PCI Configuration Enable bit after probe
	PCI: rockchip: Write PCI Device ID to correct register
	PCI: rockchip: Add poll and timeout to wait for PHY PLLs to be locked
	PCI: rockchip: Fix legacy IRQ generation for RK3399 PCIe endpoint core
	PCI: rockchip: Use u32 variable to access 32-bit registers
	PCI: rockchip: Set address alignment for endpoint mode
	misc: pci_endpoint_test: Free IRQs before removing the device
	misc: pci_endpoint_test: Re-init completion for every test
	md/raid0: add discard support for the 'original' layout
	fs: dlm: return positive pid value for F_GETLK
	drm/atomic: Allow vblank-enabled + self-refresh "disable"
	drm/rockchip: vop: Leave vblank enabled in self-refresh
	drm/amd/display: Correct `DMUB_FW_VERSION` macro
	serial: atmel: don't enable IRQs prematurely
	tty: serial: samsung_tty: Fix a memory leak in s3c24xx_serial_getclk() in case of error
	tty: serial: samsung_tty: Fix a memory leak in s3c24xx_serial_getclk() when iterating clk
	firmware: stratix10-svc: Fix a potential resource leak in svc_create_memory_pool()
	ceph: don't let check_caps skip sending responses for revoke msgs
	xhci: Fix resume issue of some ZHAOXIN hosts
	xhci: Fix TRB prefetch issue of ZHAOXIN hosts
	xhci: Show ZHAOXIN xHCI root hub speed correctly
	meson saradc: fix clock divider mask length
	Revert "8250: add support for ASIX devices with a FIFO bug"
	s390/decompressor: fix misaligned symbol build error
	tracing/histograms: Add histograms to hist_vars if they have referenced variables
	samples: ftrace: Save required argument registers in sample trampolines
	net: ena: fix shift-out-of-bounds in exponential backoff
	ring-buffer: Fix deadloop issue on reading trace_pipe
	xtensa: ISS: fix call to split_if_spec
	tracing: Fix null pointer dereference in tracing_err_log_open()
	tracing/probes: Fix not to count error code to total length
	scsi: qla2xxx: Wait for io return on terminate rport
	scsi: qla2xxx: Array index may go out of bound
	scsi: qla2xxx: Fix buffer overrun
	scsi: qla2xxx: Fix potential NULL pointer dereference
	scsi: qla2xxx: Check valid rport returned by fc_bsg_to_rport()
	scsi: qla2xxx: Correct the index of array
	scsi: qla2xxx: Pointer may be dereferenced
	scsi: qla2xxx: Remove unused nvme_ls_waitq wait queue
	net/sched: sch_qfq: reintroduce lmax bound check for MTU
	RDMA/cma: Ensure rdma_addr_cancel() happens before issuing more requests
	drm/atomic: Fix potential use-after-free in nonblocking commits
	ALSA: hda/realtek - remove 3k pull low procedure
	ALSA: hda/realtek: Enable Mute LED on HP Laptop 15s-eq2xxx
	keys: Fix linking a duplicate key to a keyring's assoc_array
	perf probe: Add test for regression introduced by switch to die_get_decl_file()
	btrfs: fix warning when putting transaction with qgroups enabled after abort
	fuse: revalidate: don't invalidate if interrupted
	selftests: tc: set timeout to 15 minutes
	selftests: tc: add 'ct' action kconfig dep
	regmap: Drop initial version of maximum transfer length fixes
	regmap: Account for register length in SMBus I/O limits
	can: bcm: Fix UAF in bcm_proc_show()
	drm/client: Fix memory leak in drm_client_target_cloned
	drm/client: Fix memory leak in drm_client_modeset_probe
	ASoC: fsl_sai: Disable bit clock with transmitter
	ext4: correct inline offset when handling xattrs in inode body
	debugobjects: Recheck debug_objects_enabled before reporting
	nbd: Add the maximum limit of allocated index in nbd_dev_add
	md: fix data corruption for raid456 when reshape restart while grow up
	md/raid10: prevent soft lockup while flush writes
	posix-timers: Ensure timer ID search-loop limit is valid
	btrfs: add xxhash to fast checksum implementations
	ACPI: button: Add lid disable DMI quirk for Nextbook Ares 8A
	ACPI: video: Add backlight=native DMI quirk for Apple iMac11,3
	ACPI: video: Add backlight=native DMI quirk for Lenovo ThinkPad X131e (3371 AMD version)
	arm64: set __exception_irq_entry with __irq_entry as a default
	arm64: mm: fix VA-range sanity check
	sched/fair: Don't balance task to its current running CPU
	wifi: ath11k: fix registration of 6Ghz-only phy without the full channel range
	bpf: Address KCSAN report on bpf_lru_list
	devlink: report devlink_port_type_warn source device
	wifi: wext-core: Fix -Wstringop-overflow warning in ioctl_standard_iw_point()
	wifi: iwlwifi: mvm: avoid baid size integer overflow
	igb: Fix igb_down hung on surprise removal
	spi: bcm63xx: fix max prepend length
	fbdev: imxfb: warn about invalid left/right margin
	pinctrl: amd: Use amd_pinconf_set() for all config options
	net: ethernet: ti: cpsw_ale: Fix cpsw_ale_get_field()/cpsw_ale_set_field()
	bridge: Add extack warning when enabling STP in netns.
	iavf: Fix use-after-free in free_netdev
	iavf: Fix out-of-bounds when setting channels on remove
	security: keys: Modify mismatched function name
	octeontx2-pf: Dont allocate BPIDs for LBK interfaces
	tcp: annotate data-races around tcp_rsk(req)->ts_recent
	net: ipv4: Use kfree_sensitive instead of kfree
	net:ipv6: check return value of pskb_trim()
	Revert "tcp: avoid the lookup process failing to get sk in ehash table"
	fbdev: au1200fb: Fix missing IRQ check in au1200fb_drv_probe
	llc: Don't drop packet from non-root netns.
	netfilter: nf_tables: fix spurious set element insertion failure
	netfilter: nf_tables: can't schedule in nft_chain_validate
	netfilter: nft_set_pipapo: fix improper element removal
	netfilter: nf_tables: skip bound chain in netns release path
	netfilter: nf_tables: skip bound chain on rule flush
	tcp: annotate data-races around tp->tcp_tx_delay
	tcp: annotate data-races around tp->keepalive_time
	tcp: annotate data-races around tp->keepalive_intvl
	tcp: annotate data-races around tp->keepalive_probes
	net: Introduce net.ipv4.tcp_migrate_req.
	tcp: Fix data-races around sysctl_tcp_syn(ack)?_retries.
	tcp: annotate data-races around icsk->icsk_syn_retries
	tcp: annotate data-races around tp->linger2
	tcp: annotate data-races around rskq_defer_accept
	tcp: annotate data-races around tp->notsent_lowat
	tcp: annotate data-races around icsk->icsk_user_timeout
	tcp: annotate data-races around fastopenq.max_qlen
	net: phy: prevent stale pointer dereference in phy_init()
	tracing/histograms: Return an error if we fail to add histogram to hist_vars list
	tracing: Fix memory leak of iter->temp when reading trace_pipe
	ftrace: Store the order of pages allocated in ftrace_page
	ftrace: Fix possible warning on checking all pages used in ftrace_process_locs()
	Linux 5.10.188

Change-Id: Ibcc1adc43df5b8f649b12078eedd5d4f57de4578
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
2023-08-03 11:23:27 +00:00