Hi, Consider the following lines of code from mlock.c asmlinkage long sys_mlockall(int flags) { unsigned long lock_limit; ... lock_limit = current->rlim[RLIMIT_MEMLOCK].rlim_cur; lock_limit >>= PAGE_SHIFT; ... if (current->mm->total_vm > lock_limit) goto out; ... My question is about "lock_limit >>= PAGE_SHIFT;". I dont understand why this line is needed. Why we cannot just compare rlim_cur with current->mm->total_vm? Thanks -- Kernelnewbies: Help each other learn about the Linux kernel. Archive: http://mail.nl.linux.org/kernelnewbies/ FAQ: http://kernelnewbies.org/faq/