]> git.kernelconcepts.de Git - karo-tx-linux.git/blobdiff - mm/mlock.c
scsi: scsi_lib: Add #include <scsi/scsi_transport.h>
[karo-tx-linux.git] / mm / mlock.c
index 0dd9ca18e19ed7ddb499a480c5831c312791b10a..c483c5c20b4bd12bcca50972c9f74a0dbd3a713e 100644 (file)
@@ -123,17 +123,15 @@ static bool __munlock_isolate_lru_page(struct page *page, bool getpage)
  */
 static void __munlock_isolated_page(struct page *page)
 {
-       int ret = SWAP_AGAIN;
-
        /*
         * Optimization: if the page was mapped just once, that's our mapping
         * and we don't need to check all the other vmas.
         */
        if (page_mapcount(page) > 1)
-               ret = try_to_munlock(page);
+               try_to_munlock(page);
 
        /* Did try_to_unlock() succeed or punt? */
-       if (ret != SWAP_MLOCK)
+       if (!PageMlocked(page))
                count_vm_event(UNEVICTABLE_PGMUNLOCKED);
 
        putback_lru_page(page);