Thread (53 messages) 53 messages, 10 authors, 2023-06-29

Re: [PATCH 2/2] module: add support to avoid duplicates early on load

From: Dan Williams <hidden>
Date: 2023-05-30 22:45:39
Also in: linux-mm, linux-patches, lkml

Linus Torvalds wrote:
On Mon, May 29, 2023 at 11:18 AM Johan Hovold [off-list ref] wrote:
quoted
I took a closer look at some of the modules that failed to load and
noticed a pattern in that they have dependencies that are needed by more
than one device.
Ok, this is a "maybe something like this" RFC series of two patches -
one trivial one to re-organize things a bit so that we can then do the
real one which uses a filter based on the inode pointer to return an
"idempotent return value" for module loads that share the same inode.

It's entirely untested, and since I'm on the road I'm going to not
really be able to test it. It compiles for me, and the code looks
fairly straightforward, but it's probably buggy.
At least for me, these 2 patches, plus Johan's spinlock fixup, are:

Tested-by: Dan Williams <redacted>

...on the test that was previously broken on plain v6.4-rc4. I have
these cherry picked on top of v6.4-rc4:

 Revert "module: error out early on concurrent load of the same module file"
 module: split up 'finit_module()' into init_module_from_file() helper
 modules: catch concurrent module loads, take two
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help