* [Intel-wired-lan] [bug report] ice: split ice_ring onto Tx/Rx separate structs
@ 2021-11-16 11:36 Dan Carpenter
0 siblings, 0 replies; only message in thread
From: Dan Carpenter @ 2021-11-16 11:36 UTC (permalink / raw)
To: intel-wired-lan
Hello Maciej Fijalkowski,
This is a semi-automatic email about new static checker warnings.
The patch e72bba21355d: "ice: split ice_ring onto Tx/Rx separate
structs" from Aug 19, 2021, leads to the following Smatch complaint:
drivers/net/ethernet/intel/ice/ice_main.c:5933 ice_update_vsi_tx_ring_stats()
error: we previously assumed 'ring' could be null (see line 5929)
drivers/net/ethernet/intel/ice/ice_main.c
5928 ring = READ_ONCE(rings[i]);
5929 if (ring)
^^^^
The patch adds a new check for NULL but presumably it can be removed
5930 ice_fetch_u64_stats_per_ring(&ring->syncp, ring->stats, &pkts, &bytes);
5931 vsi_stats->tx_packets += pkts;
5932 vsi_stats->tx_bytes += bytes;
5933 vsi->tx_restart += ring->tx_stats.restart_q;
^^^^^^^^^^^^^^^^^^^^^^^^
5934 vsi->tx_busy += ring->tx_stats.tx_busy;
^^^^^^^^^^^^^^^^^^^^^^
5935 vsi->tx_linearize += ring->tx_stats.tx_linearize;
^^^^^^^^^^^^^^^^^^^^^^^^^^^
Because the previous code didn' check
regards,
dan carpenter
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2021-11-16 11:36 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-11-16 11:36 [Intel-wired-lan] [bug report] ice: split ice_ring onto Tx/Rx separate structs Dan Carpenter
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox