Skip to content

Commit

Permalink
[S390] s390,oprofile: fix compile error for !CONFIG_SMP
Browse files Browse the repository at this point in the history
Use ctl_set_bit instead of the smp_ctl_set_bit (likewise for clear bit)
to prevent the following build error for !CONFIG_SMP:

  CC      arch/s390/oprofile/hwsampler.o
arch/s390/oprofile/hwsampler.c: In function ‘hwsampler_deallocate’:
arch/s390/oprofile/hwsampler.c:1012: error: implicit declaration of function ‘smp_ctl_clear_bit’
arch/s390/oprofile/hwsampler.c: In function ‘hwsampler_start_all’:
arch/s390/oprofile/hwsampler.c:1201: error: implicit declaration of function ‘smp_ctl_set_bit’
  CC      kernel/seccomp.o
make[1]: *** [arch/s390/oprofile/hwsampler.o] Error 1
make: *** [arch/s390/oprofile] Error 2

Signed-off-by: Jan Glauber <jang@linux.vnet.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
  • Loading branch information
Jan Glauber authored and Martin Schwidefsky committed May 23, 2011
1 parent 9529cdc commit 43a679d
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions arch/s390/oprofile/hwsampler.c
Original file line number Diff line number Diff line change
Expand Up @@ -1009,7 +1009,7 @@ int hwsampler_deallocate()
if (hws_state != HWS_STOPPED)
goto deallocate_exit;

smp_ctl_clear_bit(0, 5); /* set bit 58 CR0 off */
ctl_clear_bit(0, 5); /* set bit 58 CR0 off */
deallocate_sdbt();

hws_state = HWS_DEALLOCATED;
Expand Down Expand Up @@ -1123,7 +1123,7 @@ int hwsampler_shutdown()
mutex_lock(&hws_sem);

if (hws_state == HWS_STOPPED) {
smp_ctl_clear_bit(0, 5); /* set bit 58 CR0 off */
ctl_clear_bit(0, 5); /* set bit 58 CR0 off */
deallocate_sdbt();
}
if (hws_wq) {
Expand Down Expand Up @@ -1198,7 +1198,7 @@ int hwsampler_start_all(unsigned long rate)
hws_oom = 1;
hws_flush_all = 0;
/* now let them in, 1407 CPUMF external interrupts */
smp_ctl_set_bit(0, 5); /* set CR0 bit 58 */
ctl_set_bit(0, 5); /* set CR0 bit 58 */

return 0;
}
Expand Down

0 comments on commit 43a679d

Please sign in to comment.