Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

linux/init: remove __memexit* annotations

We have never used __memexit, __memexitdata, or __memexitconst.

These were unneeded.

Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
Acked-by: Arnd Bergmann <arnd@arndb.de>

+3 -21
-6
include/asm-generic/vmlinux.lds.h
··· 356 356 *(.ref.data) \ 357 357 *(.data..shared_aligned) /* percpu related */ \ 358 358 MEM_KEEP(init.data*) \ 359 - MEM_KEEP(exit.data*) \ 360 359 *(.data.unlikely) \ 361 360 __start_once = .; \ 362 361 *(.data.once) \ ··· 520 521 __init_rodata : AT(ADDR(__init_rodata) - LOAD_OFFSET) { \ 521 522 *(.ref.rodata) \ 522 523 MEM_KEEP(init.rodata) \ 523 - MEM_KEEP(exit.rodata) \ 524 524 } \ 525 525 \ 526 526 /* Built-in module parameters. */ \ ··· 572 574 *(.ref.text) \ 573 575 *(.text.asan.* .text.tsan.*) \ 574 576 MEM_KEEP(init.text*) \ 575 - MEM_KEEP(exit.text*) \ 576 577 577 578 578 579 /* sched.text is aling to function alignment to secure we have same ··· 711 714 *(.exit.data .exit.data.*) \ 712 715 *(.fini_array .fini_array.*) \ 713 716 *(.dtors .dtors.*) \ 714 - MEM_DISCARD(exit.data*) \ 715 - MEM_DISCARD(exit.rodata*) 716 717 717 718 #define EXIT_TEXT \ 718 719 *(.exit.text) \ 719 720 *(.text.exit) \ 720 - MEM_DISCARD(exit.text) 721 721 722 722 #define EXIT_CALL \ 723 723 *(.exitcall.exit)
-3
include/linux/init.h
··· 89 89 __latent_entropy 90 90 #define __meminitdata __section(".meminit.data") 91 91 #define __meminitconst __section(".meminit.rodata") 92 - #define __memexit __section(".memexit.text") __exitused __cold notrace 93 - #define __memexitdata __section(".memexit.data") 94 - #define __memexitconst __section(".memexit.rodata") 95 92 96 93 /* For assembly routines */ 97 94 #define __HEAD .section ".head.text","ax"
+3 -12
scripts/mod/modpost.c
··· 798 798 #define ALL_INIT_TEXT_SECTIONS \ 799 799 ".init.text", ".meminit.text" 800 800 #define ALL_EXIT_TEXT_SECTIONS \ 801 - ".exit.text", ".memexit.text" 801 + ".exit.text" 802 802 803 803 #define ALL_PCI_INIT_SECTIONS \ 804 804 ".pci_fixup_early", ".pci_fixup_header", ".pci_fixup_final", \ ··· 806 806 ".pci_fixup_resume_early", ".pci_fixup_suspend" 807 807 808 808 #define ALL_XXXINIT_SECTIONS MEM_INIT_SECTIONS 809 - #define ALL_XXXEXIT_SECTIONS MEM_EXIT_SECTIONS 810 809 811 810 #define ALL_INIT_SECTIONS INIT_SECTIONS, ALL_XXXINIT_SECTIONS 812 - #define ALL_EXIT_SECTIONS EXIT_SECTIONS, ALL_XXXEXIT_SECTIONS 811 + #define ALL_EXIT_SECTIONS EXIT_SECTIONS 813 812 814 813 #define DATA_SECTIONS ".data", ".data.rel" 815 814 #define TEXT_SECTIONS ".text", ".text.*", ".sched.text", \ ··· 821 822 #define MEM_INIT_SECTIONS ".meminit.*" 822 823 823 824 #define EXIT_SECTIONS ".exit.*" 824 - #define MEM_EXIT_SECTIONS ".memexit.*" 825 825 826 826 #define ALL_TEXT_SECTIONS ALL_INIT_TEXT_SECTIONS, ALL_EXIT_TEXT_SECTIONS, \ 827 827 TEXT_SECTIONS, OTHER_TEXT_SECTIONS ··· 830 832 DATA_TO_ANY_INIT, 831 833 TEXTDATA_TO_ANY_EXIT, 832 834 XXXINIT_TO_SOME_INIT, 833 - XXXEXIT_TO_SOME_EXIT, 834 835 ANY_INIT_TO_ANY_EXIT, 835 836 ANY_EXIT_TO_ANY_INIT, 836 837 EXTABLE_TO_NON_TEXT, ··· 879 882 .fromsec = { ALL_XXXINIT_SECTIONS, NULL }, 880 883 .bad_tosec = { INIT_SECTIONS, NULL }, 881 884 .mismatch = XXXINIT_TO_SOME_INIT, 882 - }, 883 - /* Do not reference exit code/data from memexit code/data */ 884 - { 885 - .fromsec = { ALL_XXXEXIT_SECTIONS, NULL }, 886 - .bad_tosec = { EXIT_SECTIONS, NULL }, 887 - .mismatch = XXXEXIT_TO_SOME_EXIT, 888 885 }, 889 886 /* Do not use exit code/data from init code */ 890 887 { ··· 1008 1017 1009 1018 /* symbols in data sections that may refer to meminit sections */ 1010 1019 if (match(fromsec, PATTERNS(DATA_SECTIONS)) && 1011 - match(tosec, PATTERNS(ALL_XXXINIT_SECTIONS, ALL_XXXEXIT_SECTIONS)) && 1020 + match(tosec, PATTERNS(ALL_XXXINIT_SECTIONS)) && 1012 1021 match(fromsym, PATTERNS("*driver"))) 1013 1022 return 0; 1014 1023