]> git.karo-electronics.de Git - mv-sheeva.git/blobdiff - mm/migrate.c
sunrpc: Propagate errors from xs_bind() through xs_create_sock()
[mv-sheeva.git] / mm / migrate.c
index 155a2e9a8059c13249d93437589342349432e875..352de555626c4434471a53e29bee7a02516adfe3 100644 (file)
@@ -980,10 +980,6 @@ int migrate_huge_pages(struct list_head *from,
        }
        rc = 0;
 out:
-
-       list_for_each_entry_safe(page, page2, from, lru)
-               put_page(page);
-
        if (rc)
                return rc;
 
@@ -1291,14 +1287,14 @@ SYSCALL_DEFINE6(move_pages, pid_t, pid, unsigned long, nr_pages,
                return -EPERM;
 
        /* Find the mm_struct */
-       read_lock(&tasklist_lock);
+       rcu_read_lock();
        task = pid ? find_task_by_vpid(pid) : current;
        if (!task) {
-               read_unlock(&tasklist_lock);
+               rcu_read_unlock();
                return -ESRCH;
        }
        mm = get_task_mm(task);
-       read_unlock(&tasklist_lock);
+       rcu_read_unlock();
 
        if (!mm)
                return -EINVAL;