I got this bug today in Ubuntu 22.04
root@ceph1:~# uname -a Linux ceph1 5.15.0-58-generic #64-Ubuntu SMP Thu Jan 5 11:43:13 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux root@ceph1:~# cat /etc/lsb-release DISTRIB_ID=Ubuntu DISTRIB_RELEASE=22.04 DISTRIB_CODENAME=jammy DISTRIB_DESCRIPTION="Ubuntu 22.04.1 LTS"
[ 17.317308] ================================================================================ [ 17.317310] UBSAN: array-index-out-of-bounds in /build/linux-oKJrrr/linux-5.15.0/drivers/scsi/megaraid/megaraid_sas_fp.c:103:32 [ 17.317312] index 1 is out of range for type 'MR_LD_SPAN_MAP [1]' [ 17.317314] CPU: 16 PID: 116 Comm: kworker/16:0H Not tainted 5.15.0-58-generic #64-Ubuntu [ 17.317317] Hardware name: Dell Inc. PowerEdge R620/0VV3F2, BIOS 2.9.0 12/06/2019 [ 17.317319] Workqueue: kblockd blk_mq_run_work_fn [ 17.317326] Call Trace: [ 17.317329] <TASK> [ 17.317332] show_stack+0x52/0x5c [ 17.317337] dump_stack_lvl+0x4a/0x63 [ 17.317343] dump_stack+0x10/0x16 [ 17.317345] ubsan_epilogue+0x9/0x49 [ 17.317357] __ubsan_handle_out_of_bounds.cold+0x44/0x49 [ 17.317361] MR_BuildRaidContext+0xa5e/0xb50 [megaraid_sas] [ 17.317375] megasas_build_ldio_fusion+0x5b9/0x9a0 [megaraid_sas] [ 17.317384] megasas_build_io_fusion+0x412/0x450 [megaraid_sas] [ 17.317391] megasas_build_and_issue_cmd_fusion+0xa5/0x380 [megaraid_sas] [ 17.317398] megasas_queue_command+0x1c1/0x200 [megaraid_sas] [ 17.317405] ? ktime_get+0x46/0xc0 [ 17.317409] scsi_dispatch_cmd+0x96/0x200 [ 17.317412] scsi_queue_rq+0x2d5/0x690 [ 17.317415] blk_mq_dispatch_rq_list+0x13f/0x680 [ 17.317418] ? sbitmap_get+0x1/0xe0 [ 17.317422] __blk_mq_do_dispatch_sched+0xba/0x2e0 [ 17.317424] blk_mq_do_dispatch_sched+0x40/0x70 [ 17.317426] __blk_mq_sched_dispatch_requests+0x105/0x150 [ 17.317428] blk_mq_sched_dispatch_requests+0x35/0x70 [ 17.317429] __blk_mq_run_hw_queue+0x34/0xc0 [ 17.317432] blk_mq_run_work_fn+0x1f/0x30 [ 17.317434] process_one_work+0x22b/0x3d0 [ 17.317436] worker_thread+0x53/0x420 [ 17.317438] ? process_one_work+0x3d0/0x3d0 [ 17.317439] kthread+0x12a/0x150 [ 17.317441] ? set_kthread_struct+0x50/0x50 [ 17.317444] ret_from_fork+0x22/0x30 [ 17.317448] </TASK> [ 17.317449] ================================================================================ [ 17.317450] ================================================================================
I got this bug today in Ubuntu 22.04
root@ceph1:~# uname -a RELEASE= 22.04 CODENAME= jammy DESCRIPTION= "Ubuntu 22.04.1 LTS"
Linux ceph1 5.15.0-58-generic #64-Ubuntu SMP Thu Jan 5 11:43:13 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux
root@ceph1:~# cat /etc/lsb-release
DISTRIB_ID=Ubuntu
DISTRIB_
DISTRIB_
DISTRIB_
[ 17.317308] ======= ======= ======= ======= ======= ======= ======= ======= ======= ======= ======= === out-of- bounds in /build/ linux-oKJrrr/ linux-5. 15.0/drivers/ scsi/megaraid/ megaraid_ sas_fp. c:103:32 0x52/0x5c lvl+0x4a/ 0x63 0x10/0x16 0x9/0x49 handle_ out_of_ bounds. cold+0x44/ 0x49 text+0xa5e/ 0xb50 [megaraid_sas] build_ldio_ fusion+ 0x5b9/0x9a0 [megaraid_sas] build_io_ fusion+ 0x412/0x450 [megaraid_sas] build_and_ issue_cmd_ fusion+ 0xa5/0x380 [megaraid_sas] queue_command+ 0x1c1/0x200 [megaraid_sas] cmd+0x96/ 0x200 rq+0x2d5/ 0x690 dispatch_ rq_list+ 0x13f/0x680 get+0x1/ 0xe0 do_dispatch_ sched+0xba/ 0x2e0 do_dispatch_ sched+0x40/ 0x70 sched_dispatch_ requests+ 0x105/0x150 sched_dispatch_ requests+ 0x35/0x70 run_hw_ queue+0x34/ 0xc0 run_work_ fn+0x1f/ 0x30 one_work+ 0x22b/0x3d0 thread+ 0x53/0x420 one_work+ 0x3d0/0x3d0 struct+ 0x50/0x50 fork+0x22/ 0x30 ======= ======= ======= ======= ======= ======= ======= ======= ======= ======= === ======= ======= ======= ======= ======= ======= ======= ======= ======= ======= ===
[ 17.317310] UBSAN: array-index-
[ 17.317312] index 1 is out of range for type 'MR_LD_SPAN_MAP [1]'
[ 17.317314] CPU: 16 PID: 116 Comm: kworker/16:0H Not tainted 5.15.0-58-generic #64-Ubuntu
[ 17.317317] Hardware name: Dell Inc. PowerEdge R620/0VV3F2, BIOS 2.9.0 12/06/2019
[ 17.317319] Workqueue: kblockd blk_mq_run_work_fn
[ 17.317326] Call Trace:
[ 17.317329] <TASK>
[ 17.317332] show_stack+
[ 17.317337] dump_stack_
[ 17.317343] dump_stack+
[ 17.317345] ubsan_epilogue+
[ 17.317357] __ubsan_
[ 17.317361] MR_BuildRaidCon
[ 17.317375] megasas_
[ 17.317384] megasas_
[ 17.317391] megasas_
[ 17.317398] megasas_
[ 17.317405] ? ktime_get+0x46/0xc0
[ 17.317409] scsi_dispatch_
[ 17.317412] scsi_queue_
[ 17.317415] blk_mq_
[ 17.317418] ? sbitmap_
[ 17.317422] __blk_mq_
[ 17.317424] blk_mq_
[ 17.317426] __blk_mq_
[ 17.317428] blk_mq_
[ 17.317429] __blk_mq_
[ 17.317432] blk_mq_
[ 17.317434] process_
[ 17.317436] worker_
[ 17.317438] ? process_
[ 17.317439] kthread+0x12a/0x150
[ 17.317441] ? set_kthread_
[ 17.317444] ret_from_
[ 17.317448] </TASK>
[ 17.317449] =======
[ 17.317450] =======