Merge branch 'sh/for-2.6.27' of git://git.kernel.org/pub/scm/linux/kernel/git/lethal...
[cascardo/linux.git] / arch / x86 / mm / pgtable.c
index 557b2ab..d503027 100644 (file)
@@ -207,6 +207,9 @@ static void pgd_prepopulate_pmd(struct mm_struct *mm, pgd_t *pgd, pmd_t *pmds[])
        unsigned long addr;
        int i;
 
+       if (PREALLOCATED_PMDS == 0) /* Work around gcc-3.4.x bug */
+               return;
+
        pud = pud_offset(pgd, 0);
 
        for (addr = i = 0; i < PREALLOCATED_PMDS;