event/octeontx: prefetch mbuf instead of wqe

Message ID 20180717143345.5491-1-pbhagavatula@caviumnetworks.com (mailing list archive)
State Accepted, archived
Delegated to: Jerin Jacob
Headers
Series event/octeontx: prefetch mbuf instead of wqe |

Checks

Context Check Description
ci/checkpatch success coding style OK
ci/Intel-compilation success Compilation OK

Commit Message

Pavan Nikhilesh July 17, 2018, 2:33 p.m. UTC
  Prefetch mbuf pointer instead of wqe when SSO receives pkt from PKI.

Signed-off-by: Pavan Nikhilesh <pbhagavatula@caviumnetworks.com>
---
 drivers/event/octeontx/ssovf_worker.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
  

Comments

Santosh Shukla July 17, 2018, 4:38 p.m. UTC | #1
On Tuesday 17 July 2018 08:03 PM, Pavan Nikhilesh wrote:
> Prefetch mbuf pointer instead of wqe when SSO receives pkt from PKI.
>
> Signed-off-by: Pavan Nikhilesh <pbhagavatula@caviumnetworks.com>
> ---

Acked-by: Santosh Shukla <santosh.shukla@caviumnetworks.com>
  
Jerin Jacob July 25, 2018, 1:32 p.m. UTC | #2
-----Original Message-----
> Date: Tue, 17 Jul 2018 22:08:30 +0530
> From: santosh <santosh.shukla@caviumnetworks.com>
> To: Pavan Nikhilesh <pbhagavatula@caviumnetworks.com>,
>  jerin.jacob@caviumnetworks.com
> Cc: dev@dpdk.org
> Subject: Re: [dpdk-dev] [PATCH] event/octeontx: prefetch mbuf instead of wqe
> User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101
>  Thunderbird/52.8.0
> 
> 
> On Tuesday 17 July 2018 08:03 PM, Pavan Nikhilesh wrote:
> > Prefetch mbuf pointer instead of wqe when SSO receives pkt from PKI.
> >
> > Signed-off-by: Pavan Nikhilesh <pbhagavatula@caviumnetworks.com>
> > ---
> 
> Acked-by: Santosh Shukla <santosh.shukla@caviumnetworks.com>

Applied to dpdk-next-eventdev/master. Thanks.

>
  

Patch

diff --git a/drivers/event/octeontx/ssovf_worker.h b/drivers/event/octeontx/ssovf_worker.h
index d55018a9c..7c7306b51 100644
--- a/drivers/event/octeontx/ssovf_worker.h
+++ b/drivers/event/octeontx/ssovf_worker.h
@@ -28,11 +28,11 @@  ssovf_octeontx_wqe_to_pkt(uint64_t work, uint16_t port_info)
 {
 	struct rte_mbuf *mbuf;
 	octtx_wqe_t *wqe = (octtx_wqe_t *)(uintptr_t)work;
-	rte_prefetch_non_temporal(wqe);
 
 	/* Get mbuf from wqe */
 	mbuf = (struct rte_mbuf *)((uintptr_t)wqe -
 			OCTTX_PACKET_WQE_SKIP);
+	rte_prefetch_non_temporal(mbuf);
 	mbuf->packet_type =
 		ptype_table[wqe->s.w2.lcty][wqe->s.w2.lety][wqe->s.w2.lfty];
 	mbuf->data_off = RTE_PTR_DIFF(wqe->s.w3.addr, mbuf->buf_addr);