mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Jason Gunthorpe <jgg@ziepe.ca>
To: Leon Romanovsky <leon@kernel.org>
Cc: Jaeyeong Lee <lee@jaeyeong.cc>,
	Artemy Kovalyov <artemyko@mellanox.com>,
	Yishai Hadas <yishaih@mellanox.com>,
	linux-rdma@vger.kernel.org, linux-kernel@vger.kernel.org,
	stable@vger.kernel.org
Subject: Re: [PATCH v2] RDMA/mlx5: Preserve DEVX objects after failed output copy
Date: Wed, 25 Nov 2026 10:56:13 -0400	[thread overview]
Message-ID: <20261125145613.GJ246011@ziepe.ca> (raw)
In-Reply-To: <20261125131244.GB14811@unreal>

On Wed, Nov 25, 2026 at 03:12:44PM +0200, Leon Romanovsky wrote:
> On Sun, Nov 22, 2026 at 10:39:01AM +0000, Jaeyeong Lee wrote:
> > As requested, below is the full dmesg from the reproducer run.
> 
> <...>
> 
> > [   13.847526] mlx5_dct_repro: loading out-of-tree module taints kernel.
>
> What value does this change provide if it is based on an AI-generated sequence?

More importantly you are not allowed to call
uobj_finalize_uobj_create() from new style methods, it is only for the
old write interface. I guess it is in the wrong header.

It should be uverbs_finalize_uobj_create() if you want to use this
sequence.

And it should probably cover devx_handle_mkey_indirect() as well.

The idea itself seems reasonable, once we have done the actual create
command to FW it should use the normal destroy sequence. That is
exactly why we have the finalize helper in the first place.

But to do that right the entire obj_destroy should be removed.

IDK about the claim that DRAIN_DCT can fail, but I suppose it is
possible for a hostile userspace to immediately refcount any kind of
object and cause its destruction to fail and that does seem like a
legitimate problem to me, so this is worth adjusting.

Please send a v3.

Jason

      reply	other threads:[~2026-11-25 14:56 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-11 10:53 [PATCH] RDMA/mlx5: Fix UAF after DEVX DCT create failure Jaeyeong Lee
2026-11-15 13:51 ` Leon Romanovsky
2026-11-22 10:37   ` [PATCH v2] RDMA/mlx5: Preserve DEVX objects after failed output copy Jaeyeong Lee
2026-11-22 10:39     ` Jaeyeong Lee
2026-11-25 13:12       ` Leon Romanovsky
2026-11-25 14:56         ` Jason Gunthorpe [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=20261125145613.GJ246011@ziepe.ca \
    --to=jgg@ziepe.ca \
    --cc=artemyko@mellanox.com \
    --cc=lee@jaeyeong.cc \
    --cc=leon@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-rdma@vger.kernel.org \
    --cc=stable@vger.kernel.org \
    --cc=yishaih@mellanox.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

all inboxes | Powered by JetHome®