Skip to content

module: Merge same-name module load requests

Petr Pavlu linux-modules lkml 3 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v3 Latest4 patches 12 repliesIn review
  2. v22 patches 40 repliesSuperseded
  3. v11 patch 2 repliesSuperseded

Patches in v3 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/4module: Correct wake up of module_wqkernel/module/main.c+4 -41 reply
2/4module: Update a comment describing what is protected by module_mutexkernel/module/main.c+4 -32 replies
3/4module: Merge same-name module load requestskernel/module/main.c+155 -624 replies
4/4selftests: kmod: Add tests for merging same-name module load requeststools/testing/selftests/kmod/.gitignore tools/testing/selftests/kmod/Makefile tools/testing/selftests/kmod/init_module.c +3 more+244 -55 replies

Reviews trailers per patch

3 of 4 patches have a Reviewed-by or Acked-by.

PatchPetr MladekDavid Hildenbrand
1/4R-b R-b
2/4R-b R-b
3/4R-b
4/4

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v3 thread

Cover letter [PATCH v3 0/4] module: Merge same-name module load requests

Changes since v2 [1]:
- Add kselftests to verify the expected behavior.
- Split a clean-up change to the module_mutex comment into a separate patch.
- Clarify a description of the main patch and mention that it fixes also a recently reported problem with module vmap space allocation errors.
- Improve some code comments.

Changes since v1 [2]:
- Change the error returned by a duplicate load when the main insert fails from -ENODEV to -EBUSY.
- Change the error returned by a duplicate load when a same-name module is going from -EAGAIN to -EBUSY.
- Use a per-shared_load_info completion object to inform waiting loads when the main one is done.
- Add a patch to correct wake up of module_wq.

[1] https://lore.kernel.org/linux-modules/[email protected]/
[2] https://lore.kernel.org/linux-modules/[email protected]/

Petr Pavlu (4):
module: Correct wake up of module_wq
module: Update a comment describing what is protected by module_mutex
module: Merge same-name module load requests
selftests: kmod: Add tests for merging same-name module load requests

 kernel/module/main.c                          | 222 +++++++++++++-----
 tools/testing/selftests/kmod/.gitignore       |   1 +
 tools/testing/selftests/kmod/Makefile         |  17 +-
 tools/testing/selftests/kmod/init_module.c    |  49 ++++
 tools/testing/selftests/kmod/kmod.sh          | 139 +++++++++++
 .../selftests/kmod/kmod_test_0014/Makefile    |  14 ++
 .../kmod/kmod_test_0014/kmod_test_0014.c      |  29 +++
 7 files changed, 402 insertions(+), 69 deletions(-)
 create mode 100644 tools/testing/selftests/kmod/.gitignore
 create mode 100644 tools/testing/selftests/kmod/init_module.c
 create mode 100644 tools/testing/selftests/kmod/kmod_test_0014/Makefile
 create mode 100644 tools/testing/selftests/kmod/kmod_test_0014/kmod_test_0014.c
Signature · 1 line
2.35.3