Re: [PATCH 31/73] module: relocate module_init from init.h to module.h
From: Rusty Russell
Date: Tue Jan 21 2014 - 19:27:10 EST
Paul Gortmaker <paul.gortmaker@xxxxxxxxxxxxx> writes:
> Modular users will always be users of init functionality, but
> users of init functionality are not necessarily always modules.
>
> Hence any functionality like module_init and module_exit would
> be more at home in the module.h file. And module.h should
> explicitly include init.h to make the dependency clear.
>
> We've already done all the legwork needed to ensure that this
> move does not cause any build regressions due to implicit
> header file include assumptions about where module_init lives.
>
> Cc: Rusty Russell <rusty@xxxxxxxxxxxxxxx>
> Signed-off-by: Paul Gortmaker <paul.gortmaker@xxxxxxxxxxxxx>
Acked-by: Rusty Russell <rusty@xxxxxxxxxxxxxxx>
Want to delete the extraneous semicolons, for bonus points? :)
> +#define module_init(x) __initcall(x);
...
> +#define module_exit(x) __exitcall(x);
Cheers,
Rusty.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/