X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=mm%2Fshmem.c;h=a9c09e0ba709b774943edf8cab655176f5f82210;hb=598736c55622f7ea65b98f93c825ff95c433877c;hp=ea64c07cbe72b036c4e58bc37bad35cce892213b;hpb=3aa590c6b7c89d844f81c2e96f295cf2c6967773;p=linux-2.6 diff --git a/mm/shmem.c b/mm/shmem.c index ea64c07cbe..a9c09e0ba7 100644 --- a/mm/shmem.c +++ b/mm/shmem.c @@ -26,7 +26,6 @@ #include #include #include -#include #include #include #include @@ -1046,12 +1045,12 @@ repeat: swappage = lookup_swap_cache(swap); if (!swappage) { shmem_swp_unmap(entry); - spin_unlock(&info->lock); /* here we actually do the io */ if (type && *type == VM_FAULT_MINOR) { - inc_page_state(pgmajfault); + __count_vm_event(PGMAJFAULT); *type = VM_FAULT_MAJOR; } + spin_unlock(&info->lock); swappage = shmem_swapin(info, swap, idx); if (!swappage) { spin_lock(&info->lock); @@ -2252,9 +2251,7 @@ static int __init init_tmpfs(void) printk(KERN_ERR "Could not register tmpfs\n"); goto out2; } -#ifdef CONFIG_TMPFS - devfs_mk_dir("shm"); -#endif + shm_mnt = vfs_kern_mount(&tmpfs_fs_type, MS_NOUSER, tmpfs_fs_type.name, NULL); if (IS_ERR(shm_mnt)) {