mirror of
https://github.com/torvalds/linux.git
synced 2026-04-18 14:53:58 -04:00
usb: gadget: Use kstrtobool() instead of strtobool()
strtobool() is the same as kstrtobool(). However, the latter is more used within the kernel. In order to remove strtobool() and slightly simplify kstrtox.h, switch to the other function name. While at it, include the corresponding header file (<linux/kstrtox.h>) Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr> Link: https://lore.kernel.org/r/09bc980d8432a4b5f7d88388ec0df5b085583139.1667336095.git.christophe.jaillet@wanadoo.fr Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
372488c693
commit
a8bc8cc193
@@ -176,6 +176,7 @@
|
||||
#include <linux/fcntl.h>
|
||||
#include <linux/file.h>
|
||||
#include <linux/fs.h>
|
||||
#include <linux/kstrtox.h>
|
||||
#include <linux/kthread.h>
|
||||
#include <linux/sched/signal.h>
|
||||
#include <linux/limits.h>
|
||||
@@ -3387,7 +3388,7 @@ static ssize_t fsg_opts_stall_store(struct config_item *item, const char *page,
|
||||
return -EBUSY;
|
||||
}
|
||||
|
||||
ret = strtobool(page, &stall);
|
||||
ret = kstrtobool(page, &stall);
|
||||
if (!ret) {
|
||||
opts->common->can_stall = stall;
|
||||
ret = len;
|
||||
|
||||
Reference in New Issue
Block a user