[S390] vdso: compile fix
authorHeiko Carstens <heiko.carstens@de.ibm.com>
Fri, 9 Jan 2009 11:14:54 +0000 (12:14 +0100)
committerMartin Schwidefsky <schwidefsky@de.ibm.com>
Fri, 9 Jan 2009 11:15:06 +0000 (12:15 +0100)
!CONFIG_SMP:

arch/s390/kernel/vdso.c: In function 'vdso_init':
arch/s390/kernel/vdso.c:325: error: incompatible type for argument 2 of 'vdso_alloc_per_cpu'

Also move the code out of the BUG_ON statement since it won't be
executed on !CONFIG_BUG. And that would be a bug.

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

index 9c0ccb532a4564fa5457a97e64bffbaf41ea4a79..2d337cbb9329c33e07f9dfccb2f51daa94269e30 100644 (file)
@@ -685,7 +685,8 @@ void __init smp_prepare_cpus(unsigned int max_cpus)
        if (MACHINE_HAS_IEEE)
                lowcore->extended_save_area_addr = (u32) save_area;
 #else
-       BUG_ON(vdso_alloc_per_cpu(smp_processor_id(), lowcore));
+       if (vdso_alloc_per_cpu(smp_processor_id(), lowcore))
+               BUG();
 #endif
        set_prefix((u32)(unsigned long) lowcore);
        local_mcck_enable();
index 25a6a82f1c02309e8258553435112e44d9ec4b64..690e17819686534c9061b03e5408354bdb00f5d8 100644 (file)
@@ -322,7 +322,8 @@ static int __init vdso_init(void)
        vdso64_pagelist[vdso64_pages - 1] = virt_to_page(vdso_data);
        vdso64_pagelist[vdso64_pages] = NULL;
 #ifndef CONFIG_SMP
-       BUG_ON(vdso_alloc_per_cpu(0, S390_lowcore));
+       if (vdso_alloc_per_cpu(0, &S390_lowcore))
+               BUG();
 #endif
        vdso_init_cr5();
 #endif /* CONFIG_64BIT */