DPDK patches and discussions
 help / color / mirror / Atom feed
From: Jerin Jacob <jerin.jacob@caviumnetworks.com>
To: Stephen Hemminger <stephen@networkplumber.org>
Cc: dev@dpdk.org
Subject: Re: [dpdk-dev] [PATCH] net/octeneontx: fix warnings
Date: Fri, 6 Apr 2018 12:25:40 +0530	[thread overview]
Message-ID: <20180406065539.GA16663@jerin> (raw)
In-Reply-To: <20180405151228.16595-1-stephen@networkplumber.org>

-----Original Message-----
> Date: Thu,  5 Apr 2018 08:12:28 -0700
> From: Stephen Hemminger <stephen@networkplumber.org>
> To: jerin.jacob@caviumnetworks.com
> Cc: dev@dpdk.org, Stephen Hemminger <stephen@networkplumber.org>
> Subject: [PATCH] net/octeneontx: fix warnings
> X-Mailer: git-send-email 2.16.3
> 
> This is fix for Coverity Devect 268319 about uninitialized speed

s/Devect/defect

> in an error case. Also drop unnecessary assignment.

Coverity issue: 268319
Fixes: 4fac7c0a147e ("net/octeontx: add link update")

CC: stable@dpdk.org

with above changes in the commit log:
Acked-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>

> 
> Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
> ---
>  drivers/net/octeontx/octeontx_ethdev.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/net/octeontx/octeontx_ethdev.c b/drivers/net/octeontx/octeontx_ethdev.c
> index 90dd249a6b84..ec3438cb1941 100644
> --- a/drivers/net/octeontx/octeontx_ethdev.c
> +++ b/drivers/net/octeontx/octeontx_ethdev.c
> @@ -518,7 +518,6 @@ octeontx_dev_link_update(struct rte_eth_dev *dev,
>  	struct rte_eth_link link;
>  	int res;
>  
> -	res = 0;
>  	PMD_INIT_FUNC_TRACE();
>  
>  	res = octeontx_port_link_status(nic);
> @@ -552,6 +551,7 @@ octeontx_dev_link_update(struct rte_eth_dev *dev,
>  	case OCTEONTX_LINK_SPEED_RESERVE1:
>  	case OCTEONTX_LINK_SPEED_RESERVE2:
>  	default:
> +		link.link_speed = ETH_SPEED_NUM_NONE;
>  		octeontx_log_err("incorrect link speed %d", nic->speed);
>  		break;
>  	}
> -- 
> 2.16.3
> 

  reply	other threads:[~2018-04-06  6:56 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-04-05 15:12 Stephen Hemminger
2018-04-06  6:55 ` Jerin Jacob [this message]
2018-04-06  9:42   ` Ferruh Yigit

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20180406065539.GA16663@jerin \
    --to=jerin.jacob@caviumnetworks.com \
    --cc=dev@dpdk.org \
    --cc=stephen@networkplumber.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).