 /* Update all the fid/vids of our siblings */ for_each_cpu_mask(i, cpu_core_map[pol->cpu]) { powernow_data[i]->currvid = data->currvid; powernow_data[i]->currfid = data->currfid; } up(&fidvid_sem); 
static int powernowk8_target(struct cpufreq_policy *pol, unsigned targfreq, unsigned relation){	cpumask_t oldmask = CPU_MASK_ALL;	struct powernow_k8_data *data = powernow_data[pol->cpu];	u32 checkfid = data->currfid;	u32 checkvid = data->currvid;	unsigned int newstate;	int ret = -EIO;	/* only run on specific CPU from here on */	oldmask = current->cpus_allowed;	set_cpus_allowed(current, cpumask_of_cpu(pol->cpu));	schedule();	if (smp_processor_id() != pol->cpu) {		printk(KERN_ERR "limiting to cpu %u failed\n", pol->cpu);		goto err_out;	}	if (pending_bit_stuck()) {		printk(KERN_ERR PFX "failing targ, change pending bit set\n");		goto err_out;	}	dprintk("targ: cpu %d, %d kHz, min %d, max %d, relation %d\n",		pol->cpu, targfreq, pol->min, pol->max, relation);	if (query_current_values_with_pending_wait(data)) {		ret = -EIO;		goto err_out;	}	dprintk("targ: curr fid 0x%x, vid 0x%x\n",		data->currfid, data->currvid);	if ((checkvid != data->currvid) || (checkfid != data->currfid)) {		printk(KERN_ERR PFX		       "error - out of sync, fid 0x%x 0x%x, vid 0x%x 0x%x\n",		       checkfid, data->currfid, checkvid, data->currvid);	}	if (cpufreq_frequency_table_target(pol, data->powernow_table, targfreq, relation, &newstate))		goto err_out;	powernow_k8_acpi_pst_values(data, newstate);	if (transition_frequency(data, newstate)) {		printk(KERN_ERR PFX "transition frequency failed\n");		ret = 1;		goto err_out;	}	pol->cur = find_khz_freq_from_fid(data->currfid);	ret = 0;err_out:	set_cpus_allowed(current, oldmask);	schedule();	return ret;}
10457	/local/tlutelli/issta_data/temp/c/2005_temp/2005/10457/065b807ca1f5bdbeb081e3cf75ac8de9be8ac212/powernow-k8.c/clean/arch/i386/kernel/cpu/cpufreq/powernow-k8.c