mm: account pud page tables
[sfrench/cifs-2.6.git] / arch / s390 / include / asm / mmu_context.h
index 43607bb12cc2b303e7e9f87d391f053ad0aae2d2..cf4c1cb17dcd35ab9a18197e9dbeed41d1a0b376 100644 (file)
@@ -44,6 +44,8 @@ static inline int init_new_context(struct task_struct *tsk,
                mm->context.asce_limit = STACK_TOP_MAX;
                mm->context.asce = __pa(mm->pgd) | _ASCE_TABLE_LENGTH |
                                   _ASCE_USER_BITS | _ASCE_TYPE_REGION3;
+               /* pgd_alloc() did not account this pud */
+               mm_inc_nr_puds(mm);
                break;
        case -PAGE_SIZE:
                /* forked 5-level task, set new asce with new_mm->pgd */
@@ -59,7 +61,7 @@ static inline int init_new_context(struct task_struct *tsk,
                /* forked 2-level compat task, set new asce with new mm->pgd */
                mm->context.asce = __pa(mm->pgd) | _ASCE_TABLE_LENGTH |
                                   _ASCE_USER_BITS | _ASCE_TYPE_SEGMENT;
-               /* pgd_alloc() did not increase mm->nr_pmds */
+               /* pgd_alloc() did not account this pmd */
                mm_inc_nr_pmds(mm);
        }
        crst_table_init((unsigned long *) mm->pgd, pgd_entry_type(mm));