goto Unlock; }   if (num_online_cpus() != 1) { error = -EPERM;
static int enter_state(suspend_state_t state){	int error;	if (down_trylock(&pm_sem))		return -EBUSY;	if (state == PM_SUSPEND_DISK) {		error = pm_suspend_disk();		goto Unlock;	}	/* Suspend is hard to get right on SMP. */	if (num_online_cpus() != 1) {		error = -EPERM;		goto Unlock;	}	pr_debug("PM: Preparing system for %s sleep\n", pm_states[state]);	if ((error = suspend_prepare(state)))		goto Unlock;	pr_debug("PM: Entering %s sleep\n", pm_states[state]);	error = suspend_enter(state);	pr_debug("PM: Finishing wakeup.\n");	suspend_finish(state); Unlock:	up(&pm_sem);	return error;}