kernels/linux-2.4.0/arch/ia64/mm/fault.c
/*
 * This routine is analogous to expand_stack() but instead grows the
 * register backing store (which grows towards higher addresses).
 * Since the register backing store is access sequentially, we
 * disallow growing the RBS by more than a page at a time.  Note that
 * the VM_GROWSUP flag can be set on any VM area but that's fine
 * because the total process size is still limited by RLIMIT_STACK and
 * RLIMIT_AS.
 */
This routine is analogous to expand_stack() but instead grows the
register backing store (which grows towards higher addresses).
Since the register backing store is access sequentially, we
disallow growing the RBS by more than a page at a time.  Note that
the VM_GROWSUP flag can be set on any VM area but that's fine
because the total process size is still limited by RLIMIT_STACK and
RLIMIT_AS.
This routine is analogous to expand_stack () but instead grows the register backing store ( which grows towards higher addresses ) . Since the register backing store is access sequentially we disallow growing the RBS by more than a page at a time . Note that the VM_GROWSUP flag can be set on any VM area but that ' s fine because the total process size is still limited by RLIMIT_STACK and RLIMIT_AS .
static inline long
expand_backing_store (struct vm_area_struct *vma, unsigned long address)
{
	unsigned long grow;
	grow = PAGE_SIZE >> PAGE_SHIFT;
	if (address - vma->vm_start > current->rlim[RLIMIT_STACK].rlim_cur
	    || (((vma->vm_mm->total_vm + grow) << PAGE_SHIFT) > current->rlim[RLIMIT_AS].rlim_cur))
		return -ENOMEM;
	vma->vm_end += PAGE_SIZE;
	vma->vm_mm->total_vm += grow;
	if (vma->vm_flags & VM_LOCKED)
		vma->vm_mm->locked_vm += grow;
	return 0;
}
static inline long expand_backing_store ( struct vm_area_struct * vma , unsigned long address ) { unsigned long grow ; grow = PAGE_SIZE >> PAGE_SHIFT ; if ( address - vma -> vm_start > current -> rlim [ RLIMIT_STACK ] . rlim_cur || ( ( ( vma -> vm_mm -> total_vm + grow ) << PAGE_SHIFT ) > current -> rlim [ RLIMIT_AS ] . rlim_cur ) ) return - ENOMEM ; vma -> vm_end += PAGE_SIZE ; vma -> vm_mm -> total_vm += grow ; if ( vma -> vm_flags & VM_LOCKED ) vma -> vm_mm -> locked_vm += grow ; return 0 ; }
This routine is analogous to expand_stack() but instead grows the
 register backing store (which grows towards higher addresses).
This routine is analogous to expand_stack () but instead grows the register backing store ( which grows towards higher addresses ) .