From: Thomas Gleixner <tglx@linutronix.de>
To: Song Liu <songliubraving@meta.com>
Cc: Song Liu <song@kernel.org>,
"linux-modules@vger.kernel.org" <linux-modules@vger.kernel.org>,
LKML <linux-kernel@vger.kernel.org>,
Christoph Hellwig <hch@lst.de>,
Kernel Team <kernel-team@meta.com>,
Luis Chamberlain <mcgrof@kernel.org>,
Peter Zijlstra <peterz@infradead.org>,
Guenter Roeck <linux@roeck-us.net>,
Christophe Leroy <christophe.leroy@csgroup.eu>
Subject: Re: [PATCH v9] module: replace module_layout with module_memory
Date: Tue, 07 Feb 2023 11:13:32 +0100 [thread overview]
Message-ID: <87edr1wzoz.ffs@tglx> (raw)
In-Reply-To: <09C6F0A2-5AE5-4D8D-87DE-BFEC2C642A49@fb.com>
On Mon, Feb 06 2023 at 23:27, Song Liu wrote:
>> On Feb 6, 2023, at 1:45 PM, Thomas Gleixner <tglx@linutronix.de> wrote:
>>> +static void free_mod_mem(struct module *mod)
>>> +{
>>> + /* free the memory in the right order to avoid use-after-free */
>>
>> How do we end up with a UAF when the ordering is different?
>
> IIUC, we need remove MOD_DATA at last, which hosts "mod".
Oh. Please add a comment to that effect.
Thanks,
tglx
next prev parent reply other threads:[~2023-02-07 10:13 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-02-03 21:45 [PATCH v9] module: replace module_layout with module_memory Song Liu
2023-02-06 17:55 ` Song Liu
2023-02-06 21:45 ` Thomas Gleixner
2023-02-06 23:27 ` Song Liu
2023-02-07 10:13 ` Thomas Gleixner [this message]
2023-02-07 22:15 ` Song Liu
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=87edr1wzoz.ffs@tglx \
--to=tglx@linutronix.de \
--cc=christophe.leroy@csgroup.eu \
--cc=hch@lst.de \
--cc=kernel-team@meta.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-modules@vger.kernel.org \
--cc=linux@roeck-us.net \
--cc=mcgrof@kernel.org \
--cc=peterz@infradead.org \
--cc=song@kernel.org \
--cc=songliubraving@meta.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).