Skip to content

Commit

Permalink
ethdev: remove unnecessary null check
Browse files Browse the repository at this point in the history
[ upstream commit 8b8dd44 ]

This NULL check is unnecessary, 'eth_dev' is never NULL.

Fixes: 58b43c1 ("ethdev: add telemetry endpoint for device info")

Signed-off-by: Yunjian Wang <wangyunjian@huawei.com>
Acked-by: Stephen Hemminger <stephen@networkplumber.org>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
  • Loading branch information
wyjwang authored and kevintraynor committed Feb 21, 2022
1 parent 851b597 commit 6fdd195
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions lib/ethdev/rte_ethdev.c
Expand Up @@ -6323,8 +6323,6 @@ eth_dev_handle_port_info(const char *cmd __rte_unused,
return -EINVAL;

eth_dev = &rte_eth_devices[port_id];
if (!eth_dev)
return -EINVAL;

rxq_state = rte_tel_data_alloc();
if (!rxq_state)
Expand Down

0 comments on commit 6fdd195

Please sign in to comment.