DPDK patches and discussions
 help / color / mirror / Atom feed
From: Li Feng <fengli@smartx.com>
To: Dmitry Kozlyuk <dmitry.kozliuk@gmail.com>
Cc: "Burakov, Anatoly" <anatoly.burakov@intel.com>,
	 Bruce Richardson <bruce.richardson@intel.com>,
	lifeng1519@gmail.com, dev@dpdk.org, Kyle Zhang <kyle@smartx.com>,
	Yang Fan <fanyang@smartx.com>
Subject: Re: [dpdk-dev] [PATCH] librte_eal: add APIs to speedup virt2iova/phys
Date: Mon, 20 Apr 2020 22:13:01 +0800	[thread overview]
Message-ID: <CAHckoCzaS53yvADugZYK8BuyE26Rpp4yrzFiMa4FeFu5VZSLbA@mail.gmail.com> (raw)
In-Reply-To: <20200420160705.1652aeae@Sovereign>

Cool, thank you, Anatoly and Kozlyuk.

I haven't found how Windows implements the rte_mem_virt2phy.

Using an opaque structure pointer as the first argument is a good idea.

Thanks,

Feng Li

Dmitry Kozlyuk <dmitry.kozliuk@gmail.com> 于2020年4月20日周一 下午9:07写道:
>
> > On 20-Apr-20 12:09 PM, Li Feng wrote:
> > > Using pread to replace lseek + read.
> > > And add new APIs to reduce open/close/lseek system call frequency when the
> > > user needs to convert a large range of virtual address space.
> > >      - rte_mem_virt2iova_with_fd
> > >      - rte_mem_virt2phy_with_fd
> > >
> > > Currently it will be used by spdk in spdk_mem_register.
> > >
> > > Signed-off-by: Li Feng <fengli@smartx.com>
> > > ---
> >
> > These API's are IMO already on the verge of what's acceptable because of
> > the differences between PA, DPDK IOVA and external memory IOVA. I'm not
> > sure building on top of them is a good idea. It's also quite platform
> > specific - rte_mem_virt2phy could potentially work with Windows (and in
> > fact there was an RFC for it), but would this API work with Windows,
> > given that Windows doesn't have fd's? Should we perhaps replace fd's
> > with an opaque structure pointer, so that each platform-specific
> > implementation could dereference it the way it needs to, without
> > exposing internal details of the platform?
>
> These new APIs are, in fact, Linux-specific. Doubtfully will Windows ever
> benefit from it even with fd abstracted, though I can't say for FreeBSD. Given
> the linked suggestion to move rte_vfio_container_dma_map/unmap to some
> include/linux header, maybe these APIs could land there too?
>
>         http://mails.dpdk.org/archives/dev/2020-April/164404.html
>
> --
> Dmitry Kozlyuk

-- 
The SmartX email address is only for business purpose. Any sent message 
that is not related to the business is not authorized or permitted by 
SmartX.
本邮箱为北京志凌海纳科技有限公司(SmartX)工作邮箱. 如本邮箱发出的邮件与工作无关,该邮件未得到本公司任何的明示或默示的授权.



  reply	other threads:[~2020-04-20 14:13 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-04-20 11:09 Li Feng
2020-04-20 12:16 ` Burakov, Anatoly
2020-04-20 13:07   ` Dmitry Kozlyuk
2020-04-20 14:13     ` Li Feng [this message]
2021-03-25 13:32       ` David Marchand
2021-03-29  6:26         ` Li Feng
2021-04-01 10:38         ` Burakov, Anatoly
2021-04-06 10:40           ` Feng Li
2021-04-06 11:23             ` David Marchand

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=CAHckoCzaS53yvADugZYK8BuyE26Rpp4yrzFiMa4FeFu5VZSLbA@mail.gmail.com \
    --to=fengli@smartx.com \
    --cc=anatoly.burakov@intel.com \
    --cc=bruce.richardson@intel.com \
    --cc=dev@dpdk.org \
    --cc=dmitry.kozliuk@gmail.com \
    --cc=fanyang@smartx.com \
    --cc=kyle@smartx.com \
    --cc=lifeng1519@gmail.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).