mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* block/floppy: fix section mismatch warnings
@ 2006-02-26 11:09 Sam Ravnborg
  0 siblings, 0 replies; only message in thread
From: Sam Ravnborg @ 2006-02-26 11:09 UTC (permalink / raw)
  To: Andrew Morton, LKML; +Cc: Sam Ravnborg

In latest -mm a number of section mismatch warnings are generated for
floppy.o like the following:
WARNING: drivers/block/floppy.o - Section mismatch: reference to    \
.init.data: from .text between 'init_module' (at offset 0x6976) and \
'cleanup_module'

The warning are caused by a reference to floppy_init() which is __init
from init_module() which is not declared __init.
Declaring init_module() _init fixes this.

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
---

diff --git a/drivers/block/floppy.c b/drivers/block/floppy.c
index 65dbc5b..bedb689 100644
--- a/drivers/block/floppy.c
+++ b/drivers/block/floppy.c
@@ -4614,7 +4614,7 @@ static void __init parse_floppy_cfg_stri
 	}
 }
 
-int init_module(void)
+int __init init_module(void)
 {
 	if (floppy)
 		parse_floppy_cfg_string(floppy);

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2006-02-26 11:09 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-02-26 11:09 block/floppy: fix section mismatch warnings Sam Ravnborg

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®