Merge tag 'ecryptfs-5.6-rc3-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git...
[linux-2.6-microblaze.git] / mm / sparse.c
index 3822ecb..c184b69 100644 (file)
@@ -198,16 +198,6 @@ static void section_mark_present(struct mem_section *ms)
        ms->section_mem_map |= SECTION_MARKED_PRESENT;
 }
 
-static inline unsigned long next_present_section_nr(unsigned long section_nr)
-{
-       do {
-               section_nr++;
-               if (present_section_nr(section_nr))
-                       return section_nr;
-       } while ((section_nr <= __highest_present_section_nr));
-
-       return -1;
-}
 #define for_each_present_section_nr(start, section_nr)         \
        for (section_nr = next_present_section_nr(start-1);     \
             ((section_nr != -1) &&                             \
@@ -789,7 +779,7 @@ static void section_deactivate(unsigned long pfn, unsigned long nr_pages,
                        ms->usage = NULL;
                }
                memmap = sparse_decode_mem_map(ms->section_mem_map, section_nr);
-               ms->section_mem_map = sparse_encode_mem_map(NULL, section_nr);
+               ms->section_mem_map = (unsigned long)NULL;
        }
 
        if (section_is_early && memmap)