From: Vinicius Costa Gomes <vinicius.gomes@intel.com>
To: Guangshuo Li <lgs201920130244@gmail.com>
Cc: Dave Jiang <dave.jiang@intel.com>, Vinod Koul <vkoul@kernel.org>,
Fenghua Yu <fenghuay@nvidia.com>,
Shuai Xue <xueshuai@linux.alibaba.com>,
dmaengine@vger.kernel.org, linux-kernel@vger.kernel.org,
stable@vger.kernel.org
Subject: Re: [PATCH v2] dmaengine: idxd: fix double free in idxd_alloc() error path
Date: Wed, 29 Apr 2026 14:10:52 -0700 [thread overview]
Message-ID: <87lde5wjz7.fsf@intel.com> (raw)
In-Reply-To: <CANUHTR_UiN8V6wWkb2d=9p2FpxH79Fvv-mXCG9217h-aeak6bQ@mail.gmail.com>
Guangshuo Li <lgs201920130244@gmail.com> writes:
> Hi Vinicius,
>
> Thanks for reviewing.
>
> On Thu, 23 Apr 2026 at 05:56, Vinicius Costa Gomes
> <vinicius.gomes@intel.com> wrote:
>>
>> On the review of 'v1', you agreed to the comments I made, but they are
>> neither reflected in the code nor in the series organization.
>>
>
> You're right — my v2 did not incorporate the broader issues you pointed out.
>
> At the moment I don't have a good fix for the similar patterns in
> idxd_clean_wqs(), idxd_clean_engines(), idxd_clean_groups(), and
> idxd_free(). Do you have any suggestion on the preferred way to
> restructure those cleanup paths?
>
The idea is that the explicit free's
(kfree()/bitmap_free()/ida_free()/etc) should be removed and instead
rely on device_put() doing the right thing on the _release() path.
Just not sure if we need to check that the workqueue was already created
before calling destroy_workqueue().
Cheers,
--
Vinicius
prev parent reply other threads:[~2026-04-29 21:10 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-04-13 11:31 [PATCH v2] dmaengine: idxd: fix double free in idxd_alloc() error path Guangshuo Li
2026-04-22 21:56 ` Vinicius Costa Gomes
2026-04-23 3:13 ` Guangshuo Li
2026-04-29 21:10 ` Vinicius Costa Gomes [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=87lde5wjz7.fsf@intel.com \
--to=vinicius.gomes@intel.com \
--cc=dave.jiang@intel.com \
--cc=dmaengine@vger.kernel.org \
--cc=fenghuay@nvidia.com \
--cc=lgs201920130244@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=stable@vger.kernel.org \
--cc=vkoul@kernel.org \
--cc=xueshuai@linux.alibaba.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.