Hi Sam ,
I get this warnings with a randconfig ( http://194.231.229.228/git-current/randconfig-auto-36 ) :
...
WARNING: vmlinux.o(.text+0xeaf7): Section mismatch: reference to .init.text:init_gdt (between 'voyager_smp_prepare_boot_cpu' and 'smp_vic_cmn_interrupt')
WARNING: vmlinux.o(.text+0x104e3): Section mismatch: reference to .init.data:eprom_buf (between 'voyager_cat_init' and 'twofish_enc_blk')
WARNING: vmlinux.o(.text+0x1050a): Section mismatch: reference to .init.data: (between 'voyager_cat_init' and 'twofish_enc_blk')
WARNING: vmlinux.o(.text+0x10510): Section mismatch: reference to .init.data: (between 'voyager_cat_init' and 'twofish_enc_blk')
WARNING: vmlinux.o(.text+0x10517): Section mismatch: reference to .init.data: (between 'voyager_cat_init' and 'twofish_enc_blk')
WARNING: vmlinux.o(.text+0x1054a): Section mismatch: reference to .init.data: (between 'voyager_cat_init' and 'twofish_enc_blk')
WARNING: vmlinux.o(.text+0x1055b): Section mismatch: reference to .init.data: (between 'voyager_cat_init' and 'twofish_enc_blk')
WARNING: vmlinux.o(.text+0x10765): Section mismatch: reference to .init.data: (between 'voyager_cat_init' and 'twofish_enc_blk')
WARNING: vmlinux.o(.text+0x10778): Section mismatch: reference to .init.data: (between 'voyager_cat_init' and 'twofish_enc_blk')
WARNING: vmlinux.o(.text+0x107b6): Section mismatch: reference to .init.data: (between 'voyager_cat_init' and 'twofish_enc_blk')
WARNING: vmlinux.o(.text+0x107c9): Section mismatch: reference to .init.data: (between 'voyager_cat_init' and 'twofish_enc_blk')
WARNING: vmlinux.o(.text+0x1090e): Section mismatch: reference to .init.data:eprom_buf (between 'voyager_cat_init' and 'twofish_enc_blk')
WARNING: vmlinux.o(.text+0x10935): Section mismatch: reference to .init.data: (between 'voyager_cat_init' and 'twofish_enc_blk')
WARNING: vmlinux.o(.text+0x10944): Section mismatch: reference to .init.data: (between 'voyager_cat_init' and 'twofish_enc_blk')
WARNING: vmlinux.o(.text+0x10951): Section mismatch: reference ...
I only looked at the Section mismatch warnings.
They are fixed by following patch.James - I assume you will take this forward?
Sam
voyager_smp_prepare_boot_cpu is marked __devinit and calls init_gdt.
init_gdt is marked __cpuinitFix seems to make voyager_smp_prepare_boot_cpu __init since I cannot see that
voyager_cat_init is used only by smp_boot_cpus that is marked __init.
So fix is to mark voyager_cat_init as __initSigned-off-by: Sam Ravnborg <sam@ravnborg.org>
---
diff --git a/arch/i386/mach-voyager/voyager_cat.c b/arch/i386/mach-voyager/voyager_cat.c
index 26a2d4c..f5acf06 100644
--- a/arch/i386/mach-voyager/voyager_cat.c
+++ b/arch/i386/mach-voyager/voyager_cat.c
@@ -568,8 +568,7 @@ static voyager_module_t *voyager_initial_module;
* boot cpu *after* all memory initialisation has been done (so we can
* use kmalloc) but before smp initialisation, so we can probe the SMP
* configuration and pick up necessary information. */
-void
-voyager_cat_init(void)
+void __init voyager_cat_init(void)
{
voyager_module_t **modpp = &voyager_initial_module;
voyager_asic_t **asicpp;
diff --git a/arch/i386/mach-voyager/voyager_smp.c b/arch/i386/mach-voyager/voyager_smp.c
index b87f854..ac06a1c 100644
--- a/arch/i386/mach-voyager/voyager_smp.c
+++ b/arch/i386/mach-voyager/voyager_smp.c
@@ -1899,7 +1899,7 @@ voyager_smp_prepare_cpus(unsigned int max_cpus)
smp_boot_cpus();
}-static void __devinit voyager_smp_prepare_boot_cpu(void)
+static void __init voyager_smp_prepare_boot_cpu(void)
{
init_gdt(smp_processor_id());
switch_to_new_gdt();
-
Wow you are fast :)
Yes all warnings are fixed.
Gabriel
-
Hi Sam ,
me again. I got some more mismatch warnings with a randconfig ( http://194.231.229.228/git-current/randconfig-auto-14 )
...
MODPOST vmlinux.o
WARNING: vmlinux.o(.text+0x8adb): Section mismatch: reference to .init.text:register_cpu (between 'arch_register_cpu' and 'text_poke')
WARNING: vmlinux.o(.text+0xb790c): Section mismatch: reference to .init.text:pcibios_fixup_bus (between 'pci_scan_child_bus' and 'pci_scan_bus_parented')
WARNING: vmlinux.o(.text+0x12f01e): Section mismatch: reference to .init.text:mlx4_init_one (between 'mlx4_restart_one' and 'mlx4_cleanup_mcg_table')
WARNING: vmlinux.o(.text+0x1dd831): Section mismatch: reference to .init.text:setup_TeleInt (between 'checkcard' and 'hisax_init_pcmcia')
WARNING: vmlinux.o(.text+0x1dd9e7): Section mismatch: reference to .init.text:setup_elsa (between 'checkcard' and 'hisax_init_pcmcia')
WARNING: vmlinux.o(.text+0x1dd9f8): Section mismatch: reference to .init.text:setup_avm_a1 (between 'checkcard' and 'hisax_init_pcmcia')
WARNING: vmlinux.o(.text+0x1dda08): Section mismatch: reference to .init.text:setup_teles0 (between 'checkcard' and 'hisax_init_pcmcia')
WARNING: vmlinux.o(.text+0x1dda18): Section mismatch: reference to .init.text:setup_netjet_u (between 'checkcard' and 'hisax_init_pcmcia')
WARNING: vmlinux.o(.text+0x1dda28): Section mismatch: reference to .init.text:setup_hfcpci (between 'checkcard' and 'hisax_init_pcmcia')
WARNING: vmlinux.o(.text+0x1dda38): Section mismatch: reference to .init.text:setup_saphir (between 'checkcard' and 'hisax_init_pcmcia')
WARNING: vmlinux.o(.text+0x1dda48): Section mismatch: reference to .init.text:setup_avm_pcipnp (between 'checkcard' and 'hisax_init_pcmcia')
WARNING: vmlinux.o(.text+0x1dda58): Section mismatch: reference to .init.text:setup_s0box (between 'checkcard' and 'hisax_init_pcmcia')
WARNING: vmlinux.o(.text+0x1dda68): Section mismatch: reference to .init.text:setup_telespci (between 'checkcard' and 'hisax_init_pcmcia')
WARNING: vmlinux.o(.text+0x1dda78): Section mismatch:...
ISDN stuff can wait until Karsten and Jeff has finished the ongoing transition to the
All the hda_preset stuff should be marked __devinit as far as I can see.
When a function is marked __exit and used from an init function then the safe choice
is to just remove the __exit marking. Usually this is small functions used
only in error situations.
Should be trivial too.Sorry - no patch this time. Could you try to look at it yorself then I will review.
Sam
-
Yes.
Gabriel
-
The warnings gone with this patch but I'm not really sure it is correct.
drivers/mmc/host/wbsd.c | 10 +++++-----
1 files changed, 5 insertions(+), 5 deletions(-)diff --git a/drivers/mmc/host/wbsd.c b/drivers/mmc/host/wbsd.c
index e0c9808..9bf2a87 100644
--- a/drivers/mmc/host/wbsd.c
+++ b/drivers/mmc/host/wbsd.c
@@ -1266,7 +1266,7 @@ static int __devinit wbsd_alloc_mmc(struct device *dev)
return 0;
}-static void __devexit wbsd_free_mmc(struct device *dev)
+static void wbsd_free_mmc(struct device *dev)
{
struct mmc_host *mmc;
struct wbsd_host *host;
@@ -1358,7 +1358,7 @@ static int __devinit wbsd_request_region(struct wbsd_host *host, int base)
return 0;
}-static void __devexit wbsd_release_regions(struct wbsd_host *host)
+static void wbsd_release_regions(struct wbsd_host *host)
{
if (host->base)
release_region(host->base, 8);
@@ -1434,7 +1434,7 @@ err:
"Falling back on FIFO.\n", dma);
}-static void __devexit wbsd_release_dma(struct wbsd_host *host)
+static void wbsd_release_dma(struct wbsd_host *host)
{
if (host->dma_addr) {
dma_unmap_single(mmc_dev(host->mmc), host->dma_addr,
@@ -1484,7 +1484,7 @@ static int __devinit wbsd_request_irq(struct wbsd_host *host, int irq)
return 0;
}-static void __devexit wbsd_release_irq(struct wbsd_host *host)
+static void wbsd_release_irq(struct wbsd_host *host)
{
if (!host->irq)
return;
@@ -1535,7 +1535,7 @@ static int __devinit wbsd_request_resources(struct wbsd_host *host,
* Release all resources for the host.
*/-static void __devexit wbsd_release_resources(struct wbsd_host *host)
+static void wbsd_release_resources(struct wbsd_host *host)
{
wbsd_release_dma(host);
wbsd_release_irq(host);
-
Looks correct to me.
You drop the __devexit marking for functions used outside __exit.
Acked-by: Sam Ravnborg <sam@ravnborg.org>-
-
Please forward it to akpm.
I usually do not carry non-kbuild patches in my tree to keep 'noise' level down.Sam
-
Ok done.
Thank you very much for your help on this.
Gabriel
-
This patch fixes the following section mismatch warnings in sound/pci/hda/*
...
WARNING: vmlinux.o(.text+0x2d6a77): Section mismatch: reference to .init.text:snd_hda_add_new_ctls (between 'alc_build_controls' and 'alc662_auto_set_output_and_unmute')
WARNING: vmlinux.o(.text+0x2d6aa1): Section mismatch: reference to .init.text:snd_hda_create_spdif_in_ctls (between 'alc_build_controls' and 'alc662_auto_set_output_and_unmute')
WARNING: vmlinux.o(.text+0x2d6abd): Section mismatch: reference to .init.text:snd_hda_create_spdif_out_ctls (between 'alc_build_controls' and 'alc662_auto_set_output_and_unmute')
WARNING: vmlinux.o(.text+0x2d994a): Section mismatch: reference to .init.text:snd_hda_parse_pin_def_config (between 'alc880_parse_auto_config' and 'alc882_gpio_mute')
WARNING: vmlinux.o(.text+0x2da2fe): Section mismatch: reference to .init.text:snd_hda_check_board_config (between 'patch_alc268' and 'patch_alc662')
WARNING: vmlinux.o(.text+0x2da31c): Section mismatch: reference to .init.text:snd_hda_parse_pin_def_config (between 'patch_alc268' and 'patch_alc662')
WARNING: vmlinux.o(.text+0x2da6e8): Section mismatch: reference to .init.text:snd_hda_check_board_config (between 'patch_alc662' and 'alc_mux_enum_info')
WARNING: vmlinux.o(.text+0x2da7b5): Section mismatch: reference to .init.text:snd_hda_parse_pin_def_config (between 'patch_alc662' and 'alc_mux_enum_info')
WARNING: vmlinux.o(.text+0x2dae6a): Section mismatch: reference to .init.text:snd_hda_check_board_config (between 'patch_alc880' and 'patch_alc260')
WARNING: vmlinux.o(.text+0x2db036): Section mismatch: reference to .init.text:snd_hda_check_board_config (between 'patch_alc260' and 'patch_alc882')
WARNING: vmlinux.o(.text+0x2db0cc): Section mismatch: reference to .init.text:snd_hda_parse_pin_def_config (between 'patch_alc260' and 'patch_alc882')
WARNING: vmlinux.o(.text+0x2db4b0): Section mismatch: reference to .init.text:snd_hda_check_board_config (between 'patch_alc882' and 'patch_alc883')
WARNING: vmlinux.o(.text+0x2db77a): Section mi...
| Benjamin Herrenschmidt | Re: [PATCH] Remove process freezer from suspend to RAM pathway |
| Greg KH | [GIT PATCH] driver core patches against 2.6.24 |
| Mariusz Kozlowski | [PATCH 03] drivers/sbus/char/bbc_envctrl.c: kmalloc + memset conversion to kzalloc |
| Yinghai Lu | [PATCH 02/16] x86: introduce nr_irqs for 64bit v3 |
git: | |
| Gerrit Renker | [PATCH 13/37] dccp: Deprecate Ack Ratio sysctl |
| James Morris | Re: [GIT]: Networking |
| Jeff Garzik | Re: [bug?] tg3: Failed to load firmware "tigon/tg3_tso.bin" |
