Message ID | 20241203082753.4831-2-przemyslaw.kitszel@intel.com (mailing list archive) |
---|---|
State | Awaiting Upstream |
Delegated to: | Netdev Maintainers |
Headers | show |
Series | [iwl-next] fixup! ice: dump ethtool stats and skb by Tx hang devlink health reporter | expand |
Context | Check | Description |
---|---|---|
netdev/tree_selection | success | Guessing tree name failed - patch did not apply |
diff --git a/drivers/net/ethernet/intel/ice/devlink/health.c b/drivers/net/ethernet/intel/ice/devlink/health.c index c7a8b8c9e1ca..d9b852ccf99e 100644 --- a/drivers/net/ethernet/intel/ice/devlink/health.c +++ b/drivers/net/ethernet/intel/ice/devlink/health.c @@ -163,11 +163,10 @@ static int ice_tx_hang_reporter_dump(struct devlink_health_reporter *reporter, struct ice_tx_hang_event *event = priv_ctx; struct sk_buff *skb; - skb = event->tx_ring->tx_buf->skb; - if (!event) return 0; + skb = event->tx_ring->tx_buf->skb; devlink_fmsg_obj_nest_start(fmsg); ICE_DEVLINK_FMSG_PUT_FIELD(fmsg, event, head); ICE_DEVLINK_FMSG_PUT_FIELD(fmsg, event, intr);
Dan has reported [1] than @event variable is dereferenced before the check against NULL, fix that. [1]: https://lore.kernel.org/intel-wired-lan/b1453276-9043-49c4-a603-9b6bb41306c7@stanley.mountain Tony please squash this into my devlink-health series (no need to amend commit message) that is in your dev-queue. The last version of the whole series was send here: https://lore.kernel.org/netdev/20240930133724.610512-1-przemyslaw.kitszel@intel.com CC: Dan Carpenter <dan.carpenter@linaro.org> Signed-off-by: Przemek Kitszel <przemyslaw.kitszel@intel.com> --- drivers/net/ethernet/intel/ice/devlink/health.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) base-commit: 9e11d56a825f5e927039c285df38c22c20dcb757