diff options
Diffstat (limited to 'arch/s390/lib')
-rw-r--r-- | arch/s390/lib/uaccess_pt.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/arch/s390/lib/uaccess_pt.c b/arch/s390/lib/uaccess_pt.c index dc37ea827f4e..7e8efaade2ea 100644 --- a/arch/s390/lib/uaccess_pt.c +++ b/arch/s390/lib/uaccess_pt.c | |||
@@ -18,13 +18,18 @@ | |||
18 | static inline pte_t *follow_table(struct mm_struct *mm, unsigned long addr) | 18 | static inline pte_t *follow_table(struct mm_struct *mm, unsigned long addr) |
19 | { | 19 | { |
20 | pgd_t *pgd; | 20 | pgd_t *pgd; |
21 | pud_t *pud; | ||
21 | pmd_t *pmd; | 22 | pmd_t *pmd; |
22 | 23 | ||
23 | pgd = pgd_offset(mm, addr); | 24 | pgd = pgd_offset(mm, addr); |
24 | if (pgd_none(*pgd) || unlikely(pgd_bad(*pgd))) | 25 | if (pgd_none(*pgd) || unlikely(pgd_bad(*pgd))) |
25 | return NULL; | 26 | return NULL; |
26 | 27 | ||
27 | pmd = pmd_offset(pgd, addr); | 28 | pud = pud_offset(pgd, addr); |
29 | if (pud_none(*pud) || unlikely(pud_bad(*pud))) | ||
30 | return NULL; | ||
31 | |||
32 | pmd = pmd_offset(pud, addr); | ||
28 | if (pmd_none(*pmd) || unlikely(pmd_bad(*pmd))) | 33 | if (pmd_none(*pmd) || unlikely(pmd_bad(*pmd))) |
29 | return NULL; | 34 | return NULL; |
30 | 35 | ||