summaryrefslogtreecommitdiffstats
path: root/init
diff options
context:
space:
mode:
authorYaowei Bai <baiyaowei@cmss.chinamobile.com>2016-01-20 14:59:27 -0800
committerLinus Torvalds <torvalds@linux-foundation.org>2016-01-20 17:09:18 -0800
commit31c025b5fece8d0fdc88920065fbc1ff7e4a78b1 (patch)
tree4e64188cd07974bc61d7a47326f8618e54e5e155 /init
parentdf0108c5da561c66c333bb46bfe3c1fc65905898 (diff)
downloadop-kernel-dev-31c025b5fece8d0fdc88920065fbc1ff7e4a78b1.zip
op-kernel-dev-31c025b5fece8d0fdc88920065fbc1ff7e4a78b1.tar.gz
init/main.c: obsolete_checksetup can be boolean
Make obsolete_checksetup() return bool due to this particular function only using either one or zero as its return value. No functional change. Signed-off-by: Yaowei Bai <baiyaowei@cmss.chinamobile.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'init')
-rw-r--r--init/main.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/init/main.c b/init/main.c
index c6ebefa..58c9e37 100644
--- a/init/main.c
+++ b/init/main.c
@@ -164,10 +164,10 @@ static const char *panic_later, *panic_param;
extern const struct obs_kernel_param __setup_start[], __setup_end[];
-static int __init obsolete_checksetup(char *line)
+static bool __init obsolete_checksetup(char *line)
{
const struct obs_kernel_param *p;
- int had_early_param = 0;
+ bool had_early_param = false;
p = __setup_start;
do {
@@ -179,13 +179,13 @@ static int __init obsolete_checksetup(char *line)
* Keep iterating, as we can have early
* params and __setups of same names 8( */
if (line[n] == '\0' || line[n] == '=')
- had_early_param = 1;
+ had_early_param = true;
} else if (!p->setup_func) {
pr_warn("Parameter %s is obsolete, ignored\n",
p->str);
- return 1;
+ return true;
} else if (p->setup_func(line + n))
- return 1;
+ return true;
}
p++;
} while (p < __setup_end);
OpenPOWER on IntegriCloud