vm_region_alloc(struct vm_region *head, size_t size, int gfp) 
vm_region_alloc(struct vm_region *head, size_t size, gfp_t gfp) 
vm_region_alloc(struct vm_region *head, size_t size, int gfp){	unsigned long addr = head->vm_start, end = head->vm_end - size;	unsigned long flags;	struct vm_region *c, *new;	new = kmalloc(sizeof(struct vm_region), gfp);	if (!new)		goto out;	spin_lock_irqsave(&consistent_lock, flags);	list_for_each_entry(c, &head->vm_list, vm_list) {		if ((addr + size) < addr)			goto nospc;		if ((addr + size) <= c->vm_start)			goto found;		addr = c->vm_end;		if (addr > end)			goto nospc;	} found:	/*	 * Insert this entry _before_ the one we found.	 */	list_add_tail(&new->vm_list, &c->vm_list);	new->vm_start = addr;	new->vm_end = addr + size;	spin_unlock_irqrestore(&consistent_lock, flags);	return new; nospc:	spin_unlock_irqrestore(&consistent_lock, flags);	kfree(new); out:	return NULL;}
4520	/local/tlutelli/issta_data/temp/c/2005_temp/2005/4520/f9e3214a7964f523e12b4f30b6bd6396794818bd/consistent.c/buggy/arch/arm/mm/consistent.c