Commit 637c4f6
octeontx2-af: Fix potential integer overflows on integer shifts
The left shift int 32 bit integer constants 1 is evaluated using 32 bit
arithmetic and then assigned to a 64 bit unsigned integer. In the case
where the shift is 32 or more this can lead to an overflow. Avoid this
by shifting using the BIT_ULL macro instead.
Fixes: 019aba0 ("octeontx2-af: Modify SMQ flush sequence to drop packets")
Signed-off-by: Colin Ian King <[email protected]>
Reviewed-by: Dan Carpenter <[email protected]>
Link: https://patch.msgid.link/[email protected]
Signed-off-by: Paolo Abeni <[email protected]>1 parent 1cff6ff commit 637c4f6
1 file changed
+2
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2411 | 2411 | | |
2412 | 2412 | | |
2413 | 2413 | | |
2414 | | - | |
| 2414 | + | |
2415 | 2415 | | |
2416 | 2416 | | |
2417 | 2417 | | |
| |||
2432 | 2432 | | |
2433 | 2433 | | |
2434 | 2434 | | |
2435 | | - | |
| 2435 | + | |
2436 | 2436 | | |
2437 | 2437 | | |
2438 | 2438 | | |
| |||
0 commit comments