All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Ananyev, Konstantin" <konstantin.ananyev@intel.com>
To: Feifei Wang <feifei.wang2@arm.com>,
	Honnappa Nagarahalli <honnappa.nagarahalli@arm.com>
Cc: "dev@dpdk.org" <dev@dpdk.org>, "nd@arm.com" <nd@arm.com>,
	"stable@dpdk.org" <stable@dpdk.org>
Subject: Re: [dpdk-dev] [PATCH] ring: fix error vlaue of tail in the peek API for ST mode
Date: Sun, 28 Jun 2020 13:05:01 +0000	[thread overview]
Message-ID: <BYAPR11MB3301031883DB52185E9807EA9A910@BYAPR11MB3301.namprd11.prod.outlook.com> (raw)
In-Reply-To: <20200628062348.23063-1-feifei.wang2@arm.com>



> -----Original Message-----
> From: Feifei Wang <feifei.wang2@arm.com>
> Sent: Sunday, June 28, 2020 7:24 AM
> To: Honnappa Nagarahalli <honnappa.nagarahalli@arm.com>; Ananyev, Konstantin <konstantin.ananyev@intel.com>
> Cc: dev@dpdk.org; nd@arm.com; Feifei Wang <feifei.wang2@arm.com>; stable@dpdk.org
> Subject: [PATCH] ring: fix error vlaue of tail in the peek API for ST mode
> 
> The value of *tail should be the prod->tail not prod->head. After
> modification, it can record 'tail' so head/tail can be updated
> accordingly.
> 
> Fixes: 664ff4b1729b ("ring: introduce peek style API")
> Cc: stable@dpdk.org
> 
> Signed-off-by: Feifei Wang <feifei.wang2@arm.com>
> Reviewed-by: Ruifeng Wang <ruifeng.wang@arm.com>
> ---
>  lib/librte_ring/rte_ring_peek_c11_mem.h | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/lib/librte_ring/rte_ring_peek_c11_mem.h b/lib/librte_ring/rte_ring_peek_c11_mem.h
> index 99321f124..283c7e70b 100644
> --- a/lib/librte_ring/rte_ring_peek_c11_mem.h
> +++ b/lib/librte_ring/rte_ring_peek_c11_mem.h
> @@ -40,7 +40,7 @@ __rte_ring_st_get_tail(struct rte_ring_headtail *ht, uint32_t *tail,
>  	RTE_ASSERT(n >= num);
>  	num = (n >= num) ? num : 0;
> 
> -	*tail = h;
> +	*tail = t;
>  	return num;
>  }
> 
> --

Thanks for the fix.
Acked-by: Konstantin Ananyev <konstantin.ananyev@intel.com>

> 2.17.1


  reply	other threads:[~2020-06-28 13:05 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-06-28  6:23 [dpdk-dev] [PATCH] ring: fix error vlaue of tail in the peek API for ST mode Feifei Wang
2020-06-28 13:05 ` Ananyev, Konstantin [this message]
2020-07-01  8:44   ` David Marchand

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=BYAPR11MB3301031883DB52185E9807EA9A910@BYAPR11MB3301.namprd11.prod.outlook.com \
    --to=konstantin.ananyev@intel.com \
    --cc=dev@dpdk.org \
    --cc=feifei.wang2@arm.com \
    --cc=honnappa.nagarahalli@arm.com \
    --cc=nd@arm.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
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.