[lvc-project] [PATCH v3] ethtool: avoiding integer overflow in ethtool_phys_id()
    Jakub Kicinski 
    kuba at kernel.org
       
    Thu Nov 24 07:11:36 MSK 2022
    
    
  
On Tue, 22 Nov 2022 15:29:01 +0300 Maxim Korotkov wrote:
> The value of an arithmetic expression "n * id.data" is subject
> to possible overflow due to a failure to cast operands to a larger data
> type before performing arithmetic. Used macro for multiplication instead
> operator for avoiding overflow.
> 
> Found by Linux Verification Center (linuxtesting.org) with SVACE.
> 
> Signed-off-by: Maxim Korotkov <korotkov.maxim.s at gmail.com>
Applying to net-next, pretty sure nobody expects us to support blinking
an LED 4 billion times, at a rate low enough for a human eye to see...
But let's watch the stable bots pick it up anyway.
    
    
More information about the lvc-project
mailing list