Linux RDMA and InfiniBand development
 help / color / mirror / Atom feed
From: Jason Gunthorpe <jgg@nvidia.com>
To: Michael Margolin <mrgolin@amazon.com>
Cc: Yonatan Nachum <ynachum@amazon.com>,
	leon@kernel.org, linux-rdma@vger.kernel.org, sleybo@amazon.com,
	matua@amazon.com, gal.pressman@linux.dev,
	Yehuda Yitschak <yehuday@amazon.com>
Subject: Re: [PATCH for-next] RDMA/efa: Expose device P2P DMA support via device query
Date: Wed, 23 Sep 2026 14:17:41 -0300	[thread overview]
Message-ID: <20260923171741.GH2545495@nvidia.com> (raw)
In-Reply-To: <20260923163830.GA6954@dev-dsk-mrgolin-1c-b2091117.eu-west-1.amazon.com>

On Wed, Sep 23, 2026 at 04:38:30PM +0000, Michael Margolin wrote:

> I'm reviving this conversation since it is becoming an
> increasing need to reduce the long startup times. The major
> part of this time is related to CUDA device initialization
> needed only to allocate GPU memory, export a dmabuf, and
> test accessibility via MR registration. Since obtaining a
> dmabuf fd requires CUDA initialization, which is exactly
> the cost we are trying to avoid, we are looking for a
> solution that doesn't require dmabuf.

You have to use dmabuf. Go complain to the cuda people their stuff is
too slow if that is the actual problem.

Precompute it and put it in a topology file like everyone else does :\

> I have two options in mind:
> 
> 1. Introduce a new (common or EFA-specific) verb that takes
>    a peer device BDF and queries the p2p subsystem,
>    returning something like:

No way. No BDFs in uapis.

> 2. Expose EFA_DEV_CAP(dev, PCIE_PEER_ACCESS_ENABLED)
>    directly to userspace. As you already stated, this is a
>    bit awkward as a device isn't expected to be aware of
>    system topology, but since EFA lives in the cloud it is
>    partially aware of the platform configuration and in
>    particular the ability to access peer devices over PCIe.

If you already know your VMs are always safe what is even the issue?
What are you probing for?

Lets please not hack around bad userspace with even worse kernel uAPI.

Jason

  reply	other threads:[~2026-09-23 17:17 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-05-03 15:02 [PATCH for-next] RDMA/efa: Expose device P2P DMA support via device query Yonatan Nachum
2026-05-04  7:34 ` Jason Gunthorpe
2026-05-05  8:15   ` Yonatan Nachum
2026-05-05 15:40     ` Jason Gunthorpe
2026-09-23 16:38       ` Michael Margolin
2026-09-23 17:17         ` Jason Gunthorpe [this message]
2026-09-24 15:29           ` Michael Margolin
2026-09-24 18:22             ` Jason Gunthorpe
2026-09-24 19:30               ` Michael Margolin
2026-09-25 12:55                 ` Jason Gunthorpe
2026-09-30 13:26                   ` Michael Margolin
2026-10-01 15:53                     ` Leon Romanovsky
2026-10-02 14:52                       ` Jason Gunthorpe
2026-10-07  9:01                         ` Michael Margolin

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=20260923171741.GH2545495@nvidia.com \
    --to=jgg@nvidia.com \
    --cc=gal.pressman@linux.dev \
    --cc=leon@kernel.org \
    --cc=linux-rdma@vger.kernel.org \
    --cc=matua@amazon.com \
    --cc=mrgolin@amazon.com \
    --cc=sleybo@amazon.com \
    --cc=yehuday@amazon.com \
    --cc=ynachum@amazon.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