RE: [Intel-wired-lan] [PATCH intel-net] ice: fix NULL pointer dereference in ice_update_vsi_tx_ring_stats()

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

 




> -----Original Message-----
> From: Intel-wired-lan <intel-wired-lan-bounces@xxxxxxxxxx> On Behalf Of
> Maciej Fijalkowski
> Sent: Monday, March 7, 2022 11:18 PM
> To: intel-wired-lan@xxxxxxxxxxxxxxxx
> Cc: netdev@xxxxxxxxxxxxxxx; dan.carpenter@xxxxxxxxxx; kuba@xxxxxxxxxx;
> bpf@xxxxxxxxxxxxxxx; davem@xxxxxxxxxxxxx; Karlsson, Magnus
> <magnus.karlsson@xxxxxxxxx>
> Subject: [Intel-wired-lan] [PATCH intel-net] ice: fix NULL pointer dereference
> in ice_update_vsi_tx_ring_stats()
> 
> It is possible to do NULL pointer dereference in routine that updates Tx ring
> stats. Currently only stats and bytes are updated when ring pointer is valid,
> but later on ring is accessed to propagate gathered Tx stats onto VSI stats.
> 
> Change the existing logic to move to next ring when ring is NULL.
> 
> Fixes: e72bba21355d ("ice: split ice_ring onto Tx/Rx separate structs")
> Reported-by: kernel test robot <lkp@xxxxxxxxx>
> Reported-by: Dan Carpenter <dan.carpenter@xxxxxxxxxx>
> Signed-off-by: Maciej Fijalkowski <maciej.fijalkowski@xxxxxxxxx>
> ---
>  drivers/net/ethernet/intel/ice/ice_main.c | 5 +++--
>  1 file changed, 3 insertions(+), 2 deletions(-)
> 

Tested-by: Gurucharan <gurucharanx.g@xxxxxxxxx> (A Contingent worker at Intel)




[Index of Archives]     [Linux Samsung SoC]     [Linux Rockchip SoC]     [Linux Actions SoC]     [Linux for Synopsys ARC Processors]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]


  Powered by Linux