Commit 2f38fd9
scsi: ufs: core: Fix shift out of bounds when MAXQ=32
According to JESD223F, the maximum number of queues (MAXQ) is 32. When MCQ
is enabled and ESI is disabled, nr_hw_queues=32 causes a shift overflow
problem.
Fix this by using 64-bit intermediate values to handle the nr_hw_queues=32
case safely.
Signed-off-by: wangshuaiwei <wangshuaiwei1@xiaomi.com>
Reviewed-by: Bart Van Assche <bvanassche@acm.org>
Link: https://patch.msgid.link/20260224063228.50112-1-wangshuaiwei1@xiaomi.com
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>1 parent 62c0153 commit 2f38fd9
1 file changed
+1
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7110 | 7110 | | |
7111 | 7111 | | |
7112 | 7112 | | |
7113 | | - | |
| 7113 | + | |
7114 | 7114 | | |
7115 | 7115 | | |
7116 | 7116 | | |
| |||
0 commit comments