ring: fix tail in peek API for ST mode
authorFeifei Wang <feifei.wang2@arm.com>
Sun, 28 Jun 2020 06:23:47 +0000 (14:23 +0800)
committerDavid Marchand <david.marchand@redhat.com>
Wed, 1 Jul 2020 08:41:19 +0000 (10:41 +0200)
commit708d904451c8f8e431cd783753812e1ffe7a92fc
treeb13ef235a8f5bd1947cf2d9c19fdcc821dc00c39
parentc8d909aeb754e737f603023e66152f87bbec6dbc
ring: fix tail in 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")

Signed-off-by: Feifei Wang <feifei.wang2@arm.com>
Reviewed-by: Ruifeng Wang <ruifeng.wang@arm.com>
Acked-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
lib/librte_ring/rte_ring_peek_c11_mem.h