]> asedeno.scripts.mit.edu Git - linux.git/blobdiff - mm/swapfile.c
Merge tag 'gfs2-for-5.6' of git://git.kernel.org/pub/scm/linux/kernel/git/gfs2/linux-gfs2
[linux.git] / mm / swapfile.c
index bb3261d45b6a3ea6af720bee1abd0bc9a7a3e34e..6febae9ad3cd14424cc147134c848a996807a5d2 100644 (file)
@@ -2737,10 +2737,10 @@ static void *swap_next(struct seq_file *swap, void *v, loff_t *pos)
        else
                type = si->type + 1;
 
+       ++(*pos);
        for (; (si = swap_type_to_swap_info(type)); type++) {
                if (!(si->flags & SWP_USED) || !si->swap_map)
                        continue;
-               ++*pos;
                return si;
        }