From: NeilBrown Date: Wed, 9 Sep 2015 22:38:10 +0000 (-0700) Subject: kmod: correct documentation of return status of request_module X-Git-Tag: v4.14-rc1~4703^2~34 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=60b61a6f42f36e4fbfbc0139b7e86ce1494d2d9b;p=platform%2Fkernel%2Flinux-rpi.git kmod: correct documentation of return status of request_module If request_module() successfully runs modprobe, but modprobe exits with a non-zero status, then the return value from request_module() will be that (positive) error status. So the return from request_module can be: negative errno zero for success positive exit code. Signed-off-by: NeilBrown Cc: Goldwyn Rodrigues Cc: Oleg Nesterov Cc: Tejun Heo Cc: Rusty Russell Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/kernel/kmod.c b/kernel/kmod.c index 2777f40..1734ba6 100644 --- a/kernel/kmod.c +++ b/kernel/kmod.c @@ -114,10 +114,11 @@ out: * @...: arguments as specified in the format string * * Load a module using the user mode module loader. The function returns - * zero on success or a negative errno code on failure. Note that a - * successful module load does not mean the module did not then unload - * and exit on an error of its own. Callers must check that the service - * they requested is now available not blindly invoke it. + * zero on success or a negative errno code or positive exit code from + * "modprobe" on failure. Note that a successful module load does not mean + * the module did not then unload and exit on an error of its own. Callers + * must check that the service they requested is now available not blindly + * invoke it. * * If module auto-loading support is disabled then this function * becomes a no-operation.