Commit 9ed20baf authored by Andrew Halaney's avatar Andrew Halaney Committed by Peter Zijlstra

preempt/dynamic: Fix setup_preempt_mode() return value

__setup() callbacks expect 1 for success and 0 for failure. Correct the
usage here to reflect that.

Fixes: 826bfeb3 ("preempt/dynamic: Support dynamic preempt with preempt= boot option")
Reported-by: default avatarMark Rutland <mark.rutland@arm.com>
Signed-off-by: default avatarAndrew Halaney <ahalaney@redhat.com>
Signed-off-by: default avatarPeter Zijlstra (Intel) <peterz@infradead.org>
Link: https://lkml.kernel.org/r/20211203233203.133581-1-ahalaney@redhat.com
parent e7f2be11
......@@ -6617,11 +6617,11 @@ static int __init setup_preempt_mode(char *str)
int mode = sched_dynamic_mode(str);
if (mode < 0) {
pr_warn("Dynamic Preempt: unsupported mode: %s\n", str);
return 1;
return 0;
}
sched_dynamic_update(mode);
return 0;
return 1;
}
__setup("preempt=", setup_preempt_mode);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment