mirror of
https://github.com/SCST-project/scst.git
synced 2026-05-18 11:11:27 +00:00
qla2x00t: Fix an out of bounds access
Avoid that KASAN reports the following: BUG: KASAN: stack-out-of-bounds in q2t_async_event+0x27c/0x3a0 [qla2x00tgt] Read of size 2 at addr ffff8880db407db0 by task swapper/0/0 CPU: 0 PID: 0 Comm: swapper/0 Tainted: G O 4.19.19-dbg+ #1 Hardware name: Bochs Bochs, BIOS Bochs 01/01/2011 Call Trace: <IRQ> dump_stack+0xa4/0xfa print_address_description+0x71/0x239 kasan_report.cold.6+0x242/0x301 __asan_load2+0x51/0x80 q2t_async_event+0x27c/0x3a0 [qla2x00tgt] qla2x00_async_event+0x34f/0x2390 [qla2xxx_scst] qla24xx_msix_default+0x2b8/0x300 [qla2xxx_scst] __handle_irq_event_percpu+0x77/0x3c0 handle_irq_event_percpu+0x68/0xe0 handle_irq_event+0x5a/0x8b handle_edge_irq+0x114/0x2f0 handle_irq+0x18d/0x205 do_IRQ+0x73/0x150 common_interrupt+0xf/0xf git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7917 d57e44dd-8a1f-0410-8b47-8ef2f437770f
This commit is contained in:
@@ -5752,10 +5752,10 @@ static void q2t_async_event(uint16_t code, scsi_qla_host_t *vha,
|
||||
|
||||
default:
|
||||
TRACE(TRACE_MGMT, "qla2x00t(%ld): Async event %#x occurred: "
|
||||
"ignoring (m[1]=%x, m[2]=%x, m[3]=%x, m[4]=%x)",
|
||||
"ignoring (m[0]=%x, m[1]=%x, m[2]=%x, m[3]=%x)",
|
||||
vha->host_no, code,
|
||||
le16_to_cpu(mailbox[1]), le16_to_cpu(mailbox[2]),
|
||||
le16_to_cpu(mailbox[3]), le16_to_cpu(mailbox[4]));
|
||||
le16_to_cpu(mailbox[0]), le16_to_cpu(mailbox[1]),
|
||||
le16_to_cpu(mailbox[2]), le16_to_cpu(mailbox[3]));
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user