Commit d5ca24f
committed
binfmt_elf: Use elf_load() for library
While load_elf_library() is a libc5-ism, we can still replace most of
its contents with elf_load() as well, further simplifying the code.
Some historical context:
- libc4 was a.out and used uselib (a.out support has been removed)
- libc5 was ELF and used uselib (there may still be users)
- libc6 is ELF and has never used uselib
Cc: Alexander Viro <viro@zeniv.linux.org.uk>
Cc: Christian Brauner <brauner@kernel.org>
Cc: linux-fsdevel@vger.kernel.org
Cc: linux-mm@kvack.org
Suggested-by: Eric Biederman <ebiederm@xmission.com>
Tested-by: Pedro Falcato <pedro.falcato@gmail.com>
Signed-off-by: Sebastian Ott <sebott@redhat.com>
Link: https://lore.kernel.org/r/20230929032435.2391507-4-keescook@chromium.org
Signed-off-by: Kees Cook <keescook@chromium.org>1 parent 8b04d32 commit d5ca24f
1 file changed
Lines changed: 4 additions & 20 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1306 | 1306 | | |
1307 | 1307 | | |
1308 | 1308 | | |
1309 | | - | |
1310 | 1309 | | |
1311 | 1310 | | |
1312 | 1311 | | |
| |||
1351 | 1350 | | |
1352 | 1351 | | |
1353 | 1352 | | |
1354 | | - | |
1355 | | - | |
1356 | | - | |
1357 | | - | |
| 1353 | + | |
| 1354 | + | |
1358 | 1355 | | |
1359 | 1356 | | |
1360 | | - | |
1361 | | - | |
1362 | | - | |
1363 | | - | |
| 1357 | + | |
1364 | 1358 | | |
1365 | | - | |
1366 | | - | |
1367 | | - | |
| 1359 | + | |
1368 | 1360 | | |
1369 | | - | |
1370 | 1361 | | |
1371 | | - | |
1372 | | - | |
1373 | | - | |
1374 | | - | |
1375 | | - | |
1376 | | - | |
1377 | | - | |
1378 | 1362 | | |
1379 | 1363 | | |
1380 | 1364 | | |
| |||
0 commit comments