[EMAIL PROTECTED] wrote: > > (hermes.c) > static int __init init_hermes(void) > { > return 0; > } > > static void __exit exit_hermes(void) > { > } > > module_init(init_hermes); > module_exit(exit_hermes); > > That's it. As far as I can tell, gcc 4.0 semi-correctly determined they > were both > static functions with no side effect, threw them away, and then the > module_init > and module_exit threw undefined symbols for them. > > My totally incorrect workaround was to stick a printk(KERN_DEBUG) in the body > of the 3 trimmed functions so they had side effects. > > Anybody got a *better* solution?
uh, maybe static int __init init_hermes(void) { asm(""); return 0; } then raise a gcc bug report? - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/