The branch main has been updated by kbowling: URL: https://cgit.FreeBSD.org/src/commit/?id=b3bdffd7a428e43934772850966a3f80638c666f
commit b3bdffd7a428e43934772850966a3f80638c666f Author: Lukasz Czapnik <[email protected]> AuthorDate: 2026-05-20 12:52:40 +0000 Commit: Kevin Bowling <[email protected]> CommitDate: 2026-08-11 18:47:58 +0000 e1000: fix possible variable overflow DPDK commit message net/e1000/base: fix possible variable overflow Bits can be lost as temporary math is done on signed variables and the result is assigned to an unsigned variable. Cast to u32 to force the compiler to do operations on unsigned temporary variables. Fixes: af75078fece3 ("first public release") Cc: [email protected] Signed-off-by: Lukasz Czapnik <[email protected]> Signed-off-by: Ciara Loftus <[email protected]> Acked-by: Bruce Richardson <[email protected]> Obtained from: DPDK (214cb0d7f1) MFC after: 2 weeks --- sys/dev/e1000/e1000_mac.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/dev/e1000/e1000_mac.c b/sys/dev/e1000/e1000_mac.c index 13e25f9944fb..dcebd9cf1eb9 100644 --- a/sys/dev/e1000/e1000_mac.c +++ b/sys/dev/e1000/e1000_mac.c @@ -1915,7 +1915,7 @@ s32 e1000_blink_led_generic(struct e1000_hw *hw) (mode == E1000_LEDCTL_MODE_LED_OFF))) { ledctl_blink &= ~(E1000_LEDCTL_LED0_MODE_MASK << i); - ledctl_blink |= (E1000_LEDCTL_LED0_BLINK | + ledctl_blink |= (u32)(E1000_LEDCTL_LED0_BLINK | E1000_LEDCTL_MODE_LED_ON) << i; } }
