]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
s390/smp: convert cpuhp_setup_state() return code to zero on success
authorHeiko Carstens <heiko.carstens@de.ibm.com>
Mon, 14 Aug 2017 05:54:32 +0000 (07:54 +0200)
committerMartin Schwidefsky <schwidefsky@de.ibm.com>
Wed, 23 Aug 2017 11:31:49 +0000 (13:31 +0200)
cpuhp_setup_state() returns a state number on CPUHP_AP_ONLINE_DYN if
no error occurred. Therefore convert the return code to zero before
using it as exit code for s390_smp_init().

Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
arch/s390/kernel/smp.c

index 1020a11a24e50ea8dd629876fda04ef3480058a1..1cee6753d47a5cba115730cb73cef4324e8d3ed1 100644 (file)
@@ -1181,6 +1181,7 @@ static int __init s390_smp_init(void)
 
        rc = cpuhp_setup_state(CPUHP_AP_ONLINE_DYN, "s390/smp:online",
                               smp_cpu_online, smp_cpu_pre_down);
+       rc = rc <= 0 ? rc : 0;
 out:
        return rc;
 }