patches for DPDK stable branches
 help / color / mirror / Atom feed
From: "Jayatheerthan, Jay" <jay.jayatheerthan@intel.com>
To: David Marchand <david.marchand@redhat.com>,
	"dev@dpdk.org" <dev@dpdk.org>
Cc: "stable@dpdk.org" <stable@dpdk.org>,
	Jerin Jacob <jerinj@marvell.com>,
	"Naga Harish K, S V" <s.v.naga.harish.k@intel.com>,
	"Kundapura, Ganapati" <ganapati.kundapura@intel.com>
Subject: RE: [PATCH] eventdev: fix telemetry Rx adapters stats reset
Date: Fri, 25 Mar 2022 09:32:25 +0000
Message-ID: <DM6PR11MB4348A27C8D432BF697307214FD1A9@DM6PR11MB4348.namprd11.prod.outlook.com> (raw)
In-Reply-To: <20220324152830.28155-1-david.marchand@redhat.com>

Looks good, thanks for posting this change.

Acked-by: Jay Jayatheerthan <jay.jayatheerthan@intel.com>

-Jay



> -----Original Message-----
> From: David Marchand <david.marchand@redhat.com>
> Sent: Thursday, March 24, 2022 8:59 PM
> To: dev@dpdk.org
> Cc: stable@dpdk.org; Jayatheerthan, Jay <jay.jayatheerthan@intel.com>; Jerin Jacob <jerinj@marvell.com>; Naga Harish K, S V
> <s.v.naga.harish.k@intel.com>; Kundapura, Ganapati <ganapati.kundapura@intel.com>
> Subject: [PATCH] eventdev: fix telemetry Rx adapters stats reset
> 
> Caught by covscan:
> 
> 1. dpdk-21.11/lib/eventdev/rte_event_eth_rx_adapter.c:3279:
> logical_vs_bitwise: "~(*__ctype_b_loc()[(int)*params] & 2048 /*
> (unsigned short)_ISdigit */)" is always 1/true regardless of the values
> of its operand. This occurs as the logical second operand of "||".
> 2. dpdk-21.11/lib/eventdev/rte_event_eth_rx_adapter.c:3279: remediation:
> Did you intend to use "!" rather than "~"?
> 
> While isdigit return value should be compared as an int to 0,
> prefer ! since all of this file uses this convention.
> 
> Fixes: 814d01709328 ("eventdev/eth_rx: support telemetry")
> Cc: stable@dpdk.org
> 
> Signed-off-by: David Marchand <david.marchand@redhat.com>
> ---
>  lib/eventdev/rte_event_eth_rx_adapter.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/lib/eventdev/rte_event_eth_rx_adapter.c b/lib/eventdev/rte_event_eth_rx_adapter.c
> index ff83ce8b67..bf8741d2ea 100644
> --- a/lib/eventdev/rte_event_eth_rx_adapter.c
> +++ b/lib/eventdev/rte_event_eth_rx_adapter.c
> @@ -3334,7 +3334,7 @@ handle_rxa_stats_reset(const char *cmd __rte_unused,
>  {
>  	uint8_t rx_adapter_id;
> 
> -	if (params == NULL || strlen(params) == 0 || ~isdigit(*params))
> +	if (params == NULL || strlen(params) == 0 || !isdigit(*params))
>  		return -1;
> 
>  	/* Get Rx adapter ID from parameter string */
> --
> 2.23.0


  reply	other threads:[~2022-03-25  9:32 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-03-24 15:28 David Marchand
2022-03-25  9:32 ` Jayatheerthan, Jay [this message]
2022-05-10 14:35   ` Jerin Jacob

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=DM6PR11MB4348A27C8D432BF697307214FD1A9@DM6PR11MB4348.namprd11.prod.outlook.com \
    --to=jay.jayatheerthan@intel.com \
    --cc=david.marchand@redhat.com \
    --cc=dev@dpdk.org \
    --cc=ganapati.kundapura@intel.com \
    --cc=jerinj@marvell.com \
    --cc=s.v.naga.harish.k@intel.com \
    --cc=stable@dpdk.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

patches for DPDK stable branches

This inbox may be cloned and mirrored by anyone:

	git clone --mirror http://inbox.dpdk.org/stable/0 stable/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 stable stable/ http://inbox.dpdk.org/stable \
		stable@dpdk.org
	public-inbox-index stable

Example config snippet for mirrors.
Newsgroup available over NNTP:
	nntp://inbox.dpdk.org/inbox.dpdk.stable


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git