schedule_timeout(HZ - elapsed); 
schedule_timeout_interruptible(HZ - elapsed); 
static int main_control_loop(void *x){	daemonize("kfand");	DBG("main_control_loop started\n");	down(&driver_lock);	if (start_fcu() < 0) {		printk(KERN_ERR "kfand: failed to start FCU\n");		up(&driver_lock);		goto out;	}	/* Set the PCI fan once for now */	set_pwm_fan(SLOTS_FAN_PWM_INDEX, SLOTS_FAN_DEFAULT_PWM);	/* Initialize ADCs */	initialize_adc(&cpu_state[0]);	if (cpu_state[1].monitor != NULL)		initialize_adc(&cpu_state[1]);	up(&driver_lock);	while (state == state_attached) {		unsigned long elapsed, start;		start = jiffies;		down(&driver_lock);		/* First, we always calculate the new DIMMs state on an Xserve */		if (rackmac)			do_monitor_dimms(&dimms_state);		/* Then, the CPUs */		if (cpu_pid_type == CPU_PID_TYPE_COMBINED)			do_monitor_cpu_combined();		else if (cpu_pid_type == CPU_PID_TYPE_RACKMAC) {			do_monitor_cpu_rack(&cpu_state[0]);			if (cpu_state[1].monitor != NULL)				do_monitor_cpu_rack(&cpu_state[1]);			// better deal with UP		} else {			do_monitor_cpu_split(&cpu_state[0]);			if (cpu_state[1].monitor != NULL)				do_monitor_cpu_split(&cpu_state[1]);			// better deal with UP		}		/* Then, the rest */		do_monitor_backside(&backside_state);		if (!rackmac)			do_monitor_drives(&drives_state);		up(&driver_lock);		if (critical_state == 1) {			printk(KERN_WARNING "Temperature control detected a critical condition\n");			printk(KERN_WARNING "Attempting to shut down...\n");			if (call_critical_overtemp()) {				printk(KERN_WARNING "Can't call %s, power off now!\n",				       critical_overtemp_path);				machine_power_off();			}		}		if (critical_state > 0)			critical_state++;		if (critical_state > MAX_CRITICAL_STATE) {			printk(KERN_WARNING "Shutdown timed out, power off now !\n");			machine_power_off();		}		// FIXME: Deal with signals		set_current_state(TASK_INTERRUPTIBLE);		elapsed = jiffies - start;		if (elapsed < HZ)			schedule_timeout(HZ - elapsed);	} out:	DBG("main_control_loop ended\n");	ctrl_task = 0;	complete_and_exit(&ctrl_complete, 0);}
10457	/local/tlutelli/issta_data/temp/c/2005_temp/2005/10457/12621a163b78d775a95dea60357bc90e58e1a3aa/therm_pm72.c/clean/drivers/macintosh/therm_pm72.c