Search Linux Wireless

Re: [PATCH][next] iwlegacy: ensure loop counter addr does not wrap and cause an infinite loop

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello!

On 26.01.2020 3:09, Colin King wrote:

From: Colin Ian King <colin.king@xxxxxxxxxxxxx>

The loop counter addr is a u16 where as the upper limit of the loop
is a an int. In the unlikely event that the il->cfg->eeprom_size is
     ^^^^
   Double article? :-)

greater than 64K then we end up with an infinite loop since addr will
wrap around an never reach upper loop limit. Fix this by making addr
an int.

Addresses-Coverity: ("Infinite loop")
Fixes: be663ab67077 ("iwlwifi: split the drivers for agn and legacy devices 3945/4965")
Signed-off-by: Colin Ian King <colin.king@xxxxxxxxxxxxx>
[...]

MBR< Sergei



[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Wireless Personal Area Network]     [Linux Bluetooth]     [Wireless Regulations]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux