From: Honnappa Nagarahalli <Honnappa.Nagarahalli@arm.com>
To: "Boyer, Andrew" <Andrew.Boyer@amd.com>
Cc: Ruifeng Wang <Ruifeng.Wang@arm.com>,
"dev@dpdk.org" <dev@dpdk.org>,
"Yigit, Ferruh" <Ferruh.Yigit@amd.com>,
Srikanth Yalavarthi <syalavarthi@marvell.com>, nd <nd@arm.com>,
Wathsala Wathawana Vithanage <wathsala.vithanage@arm.com>,
Dhruv Tripathi <Dhruv.Tripathi@arm.com>
Subject: Re: Adding helper function for ARM "dsb st"
Date: Wed, 7 Feb 2024 03:50:12 +0000 [thread overview]
Message-ID: <6640D2A4-873F-450B-B1D9-263B1C7400F1@arm.com> (raw)
In-Reply-To: <73E1496A-FA0A-46FB-8E72-FD24B56BEBFD@amd.com>
Hi Andrew,
On Feb 5, 2024, at 8:11 AM, Boyer, Andrew <Andrew.Boyer@amd.com> wrote:
>
> I see that cnxk has added inline assembly for the ARM "dsb st" barrier. We, too, would like to add a use of this instruction. Can a helper function be added to the atomics headers?
>
>> drivers/ml/cnxk/cn10k_ml_dev.h:#define dsb_st ({ asm volatile("dsb st" : : : "memory"); })
This is not being used. I have submitted a patch to remove the unused code [1]
We have removed the use of ‘dsb *’ as architecture definition does not need it for DPDK use cases. rte_wmb() should be enough to guarantee the memory ordering while interacting with the devices in DPDK context. I can comment more if you can explain your use case.
[1] https://patchwork.dpdk.org/project/dpdk/list/?series=31032
>
> What would the helper be named, rte_wsb()? I suppose it would be a NOP on all other platforms.
>
> Maybe we could add something for "dmb st" at the same time and get rid of that assembly, too.
>
> Thanks,
> Andrew
prev parent reply other threads:[~2024-02-07 3:50 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-02-05 14:11 Boyer, Andrew
2024-02-07 3:50 ` Honnappa Nagarahalli [this message]
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=6640D2A4-873F-450B-B1D9-263B1C7400F1@arm.com \
--to=honnappa.nagarahalli@arm.com \
--cc=Andrew.Boyer@amd.com \
--cc=Dhruv.Tripathi@arm.com \
--cc=Ferruh.Yigit@amd.com \
--cc=Ruifeng.Wang@arm.com \
--cc=dev@dpdk.org \
--cc=nd@arm.com \
--cc=syalavarthi@marvell.com \
--cc=wathsala.vithanage@arm.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).