From: Jerin Jacob <jerinjacobk@gmail.com>
To: Harman Kalra <hkalra@marvell.com>
Cc: Pavan Nikhilesh <pbhagavatula@marvell.com>,
Jerin Jacob <jerinj@marvell.com>,
Nithin Dabilpuram <ndabilpuram@marvell.com>,
Kiran Kumar K <kirankumark@marvell.com>, dpdk-dev <dev@dpdk.org>
Subject: Re: [dpdk-dev] [PATCH 2/4] event/octeontx2: improve single flow performance
Date: Mon, 5 Oct 2020 14:59:31 +0530 [thread overview]
Message-ID: <CALBAE1OcrUKLzqS5T8Jd27w_rdFRXtmLacprrpYte_hN_iGxCQ@mail.gmail.com> (raw)
In-Reply-To: <1600196207-31258-2-git-send-email-hkalra@marvell.com>
On Wed, Sep 16, 2020 at 12:27 AM Harman Kalra <hkalra@marvell.com> wrote:
>
> From: Pavan Nikhilesh <pbhagavatula@marvell.com>
>
> Improve single flow performance by moving the point of coherence
> to the end of transmit sequence.
>
> Signed-off-by: Pavan Nikhilesh <pbhagavatula@marvell.com>
> ---
> drivers/event/octeontx2/otx2_worker.h | 35 +++++++++++++++++----------
> drivers/net/octeontx2/otx2_tx.h | 18 ++++++++++++++
> 2 files changed, 40 insertions(+), 13 deletions(-)
Failed[1] to apply this patch on dpdk-next-eventdev
Could you rebase this patch to dpdk-next-eventdev tree and send an
update version?
[1]
[for-main][dpdk-next-eventdev] $ git am -3
/tmp/r/2-4-event-octeontx2-improve-single-flow-performance
Applying: event/octeontx2: improve single flow performance
error: sha1 information is lacking or useless
(drivers/event/octeontx2/otx2_worker.h).
error: could not build fake ancestor
Patch failed at 0001 event/octeontx2: improve single flow performance
hint: Use 'git am --show-current-patch=diff' to see the failed patch
When you have resolved this problem, run "git am --continue".
If you prefer to skip this patch, run "git am --skip" instead.
To restore the original branch and stop patching, run "git am --abort"
>
> diff --git a/drivers/event/octeontx2/otx2_worker.h b/drivers/event/octeontx2/otx2_worker.h
> index 1bf8afedf..32d611458 100644
> --- a/drivers/event/octeontx2/otx2_worker.h
> +++ b/drivers/event/octeontx2/otx2_worker.h
> @@ -247,15 +247,6 @@ otx2_ssogws_head_wait(struct otx2_ssogws *ws)
> #endif
> }
>
> -static __rte_always_inline void
> -otx2_ssogws_order(struct otx2_ssogws *ws, const uint8_t wait_flag)
> -{
> - if (wait_flag)
> - otx2_ssogws_head_wait(ws);
> -
> - rte_cio_wmb();
> -}
> -
> static __rte_always_inline const struct otx2_eth_txq *
> otx2_ssogws_xtract_meta(struct rte_mbuf *m,
> const uint64_t txq_data[][RTE_MAX_QUEUES_PER_PORT])
> @@ -287,10 +278,9 @@ otx2_ssogws_event_tx(struct otx2_ssogws *ws, struct rte_event ev[],
> return otx2_sec_event_tx(ws, ev, m, txq, flags);
> }
>
> - rte_prefetch_non_temporal(&txq_data[m->port][0]);
> /* Perform header writes before barrier for TSO */
> otx2_nix_xmit_prepare_tso(m, flags);
> - otx2_ssogws_order(ws, !ev->sched_type);
> + rte_cio_wmb();
> txq = otx2_ssogws_xtract_meta(m, txq_data);
> otx2_ssogws_prepare_pkt(txq, m, cmd, flags);
>
> @@ -298,12 +288,31 @@ otx2_ssogws_event_tx(struct otx2_ssogws *ws, struct rte_event ev[],
> const uint16_t segdw = otx2_nix_prepare_mseg(m, cmd, flags);
> otx2_nix_xmit_prepare_tstamp(cmd, &txq->cmd[0],
> m->ol_flags, segdw, flags);
> - otx2_nix_xmit_mseg_one(cmd, txq->lmt_addr, txq->io_addr, segdw);
> + if (!ev->sched_type) {
> + otx2_nix_xmit_mseg_prep_lmt(cmd, txq->lmt_addr, segdw);
> + otx2_ssogws_head_wait(ws);
> + if (otx2_nix_xmit_submit_lmt(txq->io_addr) == 0)
> + otx2_nix_xmit_mseg_one(cmd, txq->lmt_addr,
> + txq->io_addr, segdw);
> + } else {
> + otx2_nix_xmit_mseg_one(cmd, txq->lmt_addr, txq->io_addr,
> + segdw);
> + }
> } else {
> /* Passing no of segdw as 4: HDR + EXT + SG + SMEM */
> otx2_nix_xmit_prepare_tstamp(cmd, &txq->cmd[0],
> m->ol_flags, 4, flags);
> - otx2_nix_xmit_one(cmd, txq->lmt_addr, txq->io_addr, flags);
> +
> + if (!ev->sched_type) {
> + otx2_nix_xmit_prep_lmt(cmd, txq->lmt_addr, flags);
> + otx2_ssogws_head_wait(ws);
> + if (otx2_nix_xmit_submit_lmt(txq->io_addr) == 0)
> + otx2_nix_xmit_one(cmd, txq->lmt_addr,
> + txq->io_addr, flags);
> + } else {
> + otx2_nix_xmit_one(cmd, txq->lmt_addr, txq->io_addr,
> + flags);
> + }
> }
>
> otx2_write64(0, ws->swtag_flush_op);
> diff --git a/drivers/net/octeontx2/otx2_tx.h b/drivers/net/octeontx2/otx2_tx.h
> index 3c4317092..caf170fd1 100644
> --- a/drivers/net/octeontx2/otx2_tx.h
> +++ b/drivers/net/octeontx2/otx2_tx.h
> @@ -383,6 +383,18 @@ otx2_nix_xmit_one(uint64_t *cmd, void *lmt_addr,
> } while (lmt_status == 0);
> }
>
> +static __rte_always_inline void
> +otx2_nix_xmit_prep_lmt(uint64_t *cmd, void *lmt_addr, const uint32_t flags)
> +{
> + otx2_lmt_mov(lmt_addr, cmd, otx2_nix_tx_ext_subs(flags));
> +}
> +
> +static __rte_always_inline uint64_t
> +otx2_nix_xmit_submit_lmt(const rte_iova_t io_addr)
> +{
> + return otx2_lmt_submit(io_addr);
> +}
> +
> static __rte_always_inline uint16_t
> otx2_nix_prepare_mseg(struct rte_mbuf *m, uint64_t *cmd, const uint16_t flags)
> {
> @@ -453,6 +465,12 @@ otx2_nix_prepare_mseg(struct rte_mbuf *m, uint64_t *cmd, const uint16_t flags)
> return segdw;
> }
>
> +static __rte_always_inline void
> +otx2_nix_xmit_mseg_prep_lmt(uint64_t *cmd, void *lmt_addr, uint16_t segdw)
> +{
> + otx2_lmt_mov_seg(lmt_addr, (const void *)cmd, segdw);
> +}
> +
> static __rte_always_inline void
> otx2_nix_xmit_mseg_one(uint64_t *cmd, void *lmt_addr,
> rte_iova_t io_addr, uint16_t segdw)
> --
> 2.18.0
>
next prev parent reply other threads:[~2020-10-05 9:29 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-09-15 18:56 [dpdk-dev] [PATCH 1/4] event/octeontx2: add switch tag flush op Harman Kalra
2020-09-15 18:56 ` [dpdk-dev] [PATCH 2/4] event/octeontx2: improve single flow performance Harman Kalra
2020-10-05 9:29 ` Jerin Jacob [this message]
2020-10-08 18:48 ` [dpdk-dev] [PATCH v2 1/4] event/octeontx2: add switch tag flush op Harman Kalra
2020-10-08 18:48 ` [dpdk-dev] [PATCH v2 2/4] event/octeontx2: improve single flow performance Harman Kalra
2020-10-08 18:48 ` [dpdk-dev] [PATCH v2 3/4] net/octeontx2: fix jumbo frame crash Harman Kalra
2020-10-16 4:04 ` [dpdk-dev] [dpdk-stable] " Thomas Monjalon
2020-10-08 18:48 ` [dpdk-dev] [PATCH v2 4/4] app/eventdev: enable fast free offload Harman Kalra
2020-10-11 10:33 ` Jerin Jacob
2020-10-13 19:06 ` Jerin Jacob
2020-10-11 10:40 ` [dpdk-dev] [PATCH v2 1/4] event/octeontx2: add switch tag flush op Jerin Jacob
2020-09-15 18:56 ` [dpdk-dev] [PATCH 3/4] net/octeontx2: fix jumbo frame crash Harman Kalra
2020-09-15 18:56 ` [dpdk-dev] [PATCH 4/4] app/eventdev: enable fast free offload Harman Kalra
2020-10-05 9:26 ` 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=CALBAE1OcrUKLzqS5T8Jd27w_rdFRXtmLacprrpYte_hN_iGxCQ@mail.gmail.com \
--to=jerinjacobk@gmail.com \
--cc=dev@dpdk.org \
--cc=hkalra@marvell.com \
--cc=jerinj@marvell.com \
--cc=kirankumark@marvell.com \
--cc=ndabilpuram@marvell.com \
--cc=pbhagavatula@marvell.com \
/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).