Messages in this thread | | | From | Li Tuo <> | Subject | [BUG] iwlegacy: 3945-rs: possible null-pointer dereference in il3945_rs_get_rate() | Date | Sat, 31 Jul 2021 11:39:53 +0800 |
| |
Hello,
Our static analysis tool finds a possible null-pointer dereference in the iwlegacy driver in Linux 5.14.0-rc3:
The variable rs_sta is checked in: 629: if (rs_sta && !rs_sta->il)
This indicates that rs_sta can be NULL. If so, some null-pointer dereferences will occur in some statements such as: 643: idx = min(rs_sta->last_txrate_idx & 0xffff, RATE_COUNT_3945 - 1); 653: if (rs_sta->start_rate != RATE_INVALID)
I am not quite sure whether this possible null-pointer dereference is real and how to fix it if it is real. Any feedback would be appreciated, thanks!
Reported-by: TOTE Robot <oslab@tsinghua.edu.cn>
Best wishes, Tuo Li
| |