unlock_cpu_hotplug(); 
int mtrr_add_page(unsigned long base, unsigned long size, 		  unsigned int type, char increment){	int i;	mtrr_type ltype;	unsigned long lbase;	unsigned int lsize;	int error;	if (!mtrr_if)		return -ENXIO;			if ((error = mtrr_if->validate_add_page(base,size,type)))		return error;	if (type >= MTRR_NUM_TYPES) {		printk(KERN_WARNING "mtrr: type: %u invalid\n", type);		return -EINVAL;	}	/*  If the type is WC, check that this processor supports it  */	if ((type == MTRR_TYPE_WRCOMB) && !have_wrcomb()) {		printk(KERN_WARNING		       "mtrr: your processor doesn't support write-combining\n");		return -ENOSYS;	}	if (base & size_or_mask || size & size_or_mask) {		printk(KERN_WARNING "mtrr: base or size exceeds the MTRR width\n");		return -EINVAL;	}	error = -EINVAL;	/*  Search for existing MTRR  */	down(&main_lock);	for (i = 0; i < num_var_ranges; ++i) {		mtrr_if->get(i, &lbase, &lsize, &ltype);		if (base >= lbase + lsize)			continue;		if ((base < lbase) && (base + size <= lbase))			continue;		/*  At this point we know there is some kind of overlap/enclosure  */		if ((base < lbase) || (base + size > lbase + lsize)) {			printk(KERN_WARNING			       "mtrr: 0x%lx000,0x%lx000 overlaps existing"			       " 0x%lx000,0x%x000\n", base, size, lbase,			       lsize);			goto out;		}		/*  New region is enclosed by an existing region  */		if (ltype != type) {			if (type == MTRR_TYPE_UNCACHABLE)				continue;			printk (KERN_WARNING "mtrr: type mismatch for %lx000,%lx000 old: %s new: %s\n",			     base, size, mtrr_attrib_to_str(ltype),			     mtrr_attrib_to_str(type));			goto out;		}		if (increment)			++usage_table[i];		error = i;		goto out;	}	/*  Search for an empty MTRR  */	i = mtrr_if->get_free_region(base, size);	if (i >= 0) {		set_mtrr(i, base, size, type);		usage_table[i] = 1;	} else		printk(KERN_INFO "mtrr: no more MTRRs available\n");	error = i; out:	up(&main_lock);	return error;}
10457	/local/tlutelli/issta_data/temp/c/2005_temp/2005/10457/3b520b238e018ef0e9d11c9115d5e7d9419c4ef9/main.c/clean/arch/i386/kernel/cpu/mtrr/main.c