module: fix noreturn attribute for __module_put_and_exit()

__module_put_and_exit() is makred noreturn in module.h declaration, but is
lacking the attribute in the definition, which makes some tools (such as
sparse) unhappy. Amend the definition with the attribute as well (and
reformat the declaration so that it uses more common format).

Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
Jiri Kosina
2016-04-12 05:02:09 +09:30
committed by Rusty Russell
부모 3fc9d69093
커밋 bf262dcec6
2개의 변경된 파일3개의 추가작업 그리고 3개의 파일을 삭제

파일 보기

@@ -336,7 +336,7 @@ static inline void add_taint_module(struct module *mod, unsigned flag,
* A thread that wants to hold a reference to a module only while it
* is running can call this to safely exit. nfsd and lockd use this.
*/
void __module_put_and_exit(struct module *mod, long code)
void __noreturn __module_put_and_exit(struct module *mod, long code)
{
module_put(mod);
do_exit(code);