From: Jun Yang <jun.yang@nxp.com>
To: Stephen Hemminger <stephen@networkplumber.org>,
Vanshika Shukla <vanshika.shukla@nxp.com>
Cc: "dev@dpdk.org" <dev@dpdk.org>,
Hemant Agrawal <hemant.agrawal@nxp.com>,
Sachin Saxena <sachin.saxena@nxp.com>
Subject: RE: [EXT] Re: [v1 04/10] bus/dpaa: optimize bman acquire/release
Date: Wed, 28 May 2025 14:50:20 +0000 [thread overview]
Message-ID: <DU2PR04MB8838C15A7C6E780C14FE10E19D67A@DU2PR04MB8838.eurprd04.prod.outlook.com> (raw)
In-Reply-To: <20250528073041.242f48ab@hermes.local>
Hi,
> + rte_memcpy(bm_bufs, mcr->acquire.bufs,
> + sizeof(struct bm_buffer) * rst);
"mcr->acquire.bufs" is located in register space, it is supposed to improve performance to copy it to DDR(bm_bufs) to parse and read.
BR
Jun
-----Original Message-----
From: Stephen Hemminger <stephen@networkplumber.org>
Sent: Wednesday, May 28, 2025 10:31 PM
To: Vanshika Shukla <vanshika.shukla@nxp.com>
Cc: dev@dpdk.org; Hemant Agrawal <hemant.agrawal@nxp.com>; Sachin Saxena <sachin.saxena@nxp.com>; Jun Yang <jun.yang@nxp.com>
Subject: [EXT] Re: [v1 04/10] bus/dpaa: optimize bman acquire/release
Caution: This is an external email. Please take care when clicking links or opening attachments. When in doubt, report the message using the 'Report this email' button
On Wed, 28 May 2025 16:09:28 +0530
vanshika.shukla@nxp.com wrote:
> +RTE_EXPORT_INTERNAL_SYMBOL(bman_acquire_fast)
> +int
> +bman_acquire_fast(struct bman_pool *pool, uint64_t *bufs, uint8_t
> +num) {
> + struct bman_portal *p = get_affine_portal();
> + struct bm_mc_command *mcc;
> + struct bm_mc_result *mcr;
> + uint8_t i, rst;
> + struct bm_hw_buf_desc bm_bufs[FSL_BM_BURST_MAX];
> +
> +#ifdef RTE_LIBRTE_DPAA_HWDEBUG
> + if (!num || (num > FSL_BM_BURST_MAX))
> + return -EINVAL;
> + if (pool->params.flags & BMAN_POOL_FLAG_ONLY_RELEASE)
> + return -EINVAL;
> +#endif
> +
> + mcc = bm_mc_start(&p->p);
> + mcc->acquire.bpid = pool->params.bpid;
> + bm_mc_commit(&p->p, BM_MCC_VERB_CMD_ACQUIRE |
> + (num & BM_MCC_VERB_ACQUIRE_BUFCOUNT));
> + while (!(mcr = bm_mc_result(&p->p)))
> + ;
> + rst = mcr->verb & BM_MCR_VERB_ACQUIRE_BUFCOUNT;
> + if (unlikely(!rst))
> + return 0;
> +
> + rte_memcpy(bm_bufs, mcr->acquire.bufs,
> + sizeof(struct bm_buffer) * rst);
> +
> + for (i = 0; i < rst; i++)
> + bufs[i] = bman_hw_extract_addr(&bm_bufs[i]);
> +
Why do you need multiple the local copy?
Does hw_extract_addr modify the buffers?
next prev parent reply other threads:[~2025-05-29 9:56 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-05-28 10:39 [v1 00/10] DPAA specific fixes vanshika.shukla
2025-05-28 10:39 ` [v1 01/10] bus/dpaa: avoid using same structure and variable name vanshika.shukla
2025-05-28 10:39 ` [v1 02/10] bus/dpaa: add FMan node vanshika.shukla
2025-05-28 10:39 ` [v1 03/10] bus/dpaa: enhance DPAA SoC version vanshika.shukla
2025-05-28 14:28 ` Stephen Hemminger
2025-05-28 10:39 ` [v1 04/10] bus/dpaa: optimize bman acquire/release vanshika.shukla
2025-05-28 14:30 ` Stephen Hemminger
2025-05-28 14:50 ` Jun Yang [this message]
2025-05-28 10:39 ` [v1 05/10] mempool/dpaa: fast acquire and release vanshika.shukla
2025-05-28 10:39 ` [v1 06/10] mempool/dpaa: adjust pool element for LS1043A errata vanshika.shukla
2025-05-28 10:39 ` [v1 07/10] net/dpaa: add Tx rate limiting DPAA PMD API vanshika.shukla
2025-05-28 10:39 ` [v1 08/10] net/dpaa: add devargs for enabling err packets on main queue vanshika.shukla
2025-05-28 10:39 ` [v1 09/10] bus/dpaa: improve DPAA cleanup vanshika.shukla
2025-05-28 10:39 ` [v1 10/10] bus/dpaa: optimize qman enqueue check vanshika.shukla
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=DU2PR04MB8838C15A7C6E780C14FE10E19D67A@DU2PR04MB8838.eurprd04.prod.outlook.com \
--to=jun.yang@nxp.com \
--cc=dev@dpdk.org \
--cc=hemant.agrawal@nxp.com \
--cc=sachin.saxena@nxp.com \
--cc=stephen@networkplumber.org \
--cc=vanshika.shukla@nxp.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).