From: Qi Zhang Date: Tue, 8 Oct 2019 01:50:12 +0000 (+0800) Subject: net/ice/base: remove dead error condition X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=65d934d5b10470b3e0e1d19dcd02d488dd4a7cf9;p=dpdk.git net/ice/base: remove dead error condition The pointer cmd is set to an address of a structure, which can never be NULL. Remove the check-for-NULL lines since it's dead code anyway. Signed-off-by: Jeb Cramer Signed-off-by: Paul M Stillwell Jr Signed-off-by: Qi Zhang Acked-by: Qiming Yang --- diff --git a/drivers/net/ice/base/ice_common.c b/drivers/net/ice/base/ice_common.c index 48ba160f7a..4ba3ab2028 100644 --- a/drivers/net/ice/base/ice_common.c +++ b/drivers/net/ice/base/ice_common.c @@ -176,9 +176,6 @@ ice_aq_get_link_topo_handle(struct ice_port_info *pi, u8 node_type, cmd = &desc.params.get_link_topo; - if (!cmd) - return ICE_ERR_PARAM; - ice_fill_dflt_direct_cmd_desc(&desc, ice_aqc_opc_get_link_topo); cmd->addr.node_type_ctx = (ICE_AQC_LINK_TOPO_NODE_CTX_PORT <<