diff options
Diffstat (limited to 'arch/arm/mm/dma-mapping.c')
-rw-r--r-- | arch/arm/mm/dma-mapping.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/arch/arm/mm/dma-mapping.c b/arch/arm/mm/dma-mapping.c index 4771dba61448..82a093cee09a 100644 --- a/arch/arm/mm/dma-mapping.c +++ b/arch/arm/mm/dma-mapping.c | |||
@@ -149,6 +149,7 @@ static int __init consistent_init(void) | |||
149 | { | 149 | { |
150 | int ret = 0; | 150 | int ret = 0; |
151 | pgd_t *pgd; | 151 | pgd_t *pgd; |
152 | pud_t *pud; | ||
152 | pmd_t *pmd; | 153 | pmd_t *pmd; |
153 | pte_t *pte; | 154 | pte_t *pte; |
154 | int i = 0; | 155 | int i = 0; |
@@ -156,7 +157,15 @@ static int __init consistent_init(void) | |||
156 | 157 | ||
157 | do { | 158 | do { |
158 | pgd = pgd_offset(&init_mm, base); | 159 | pgd = pgd_offset(&init_mm, base); |
159 | pmd = pmd_alloc(&init_mm, pgd, base); | 160 | |
161 | pud = pud_alloc(&init_mm, pgd, base); | ||
162 | if (!pud) { | ||
163 | printk(KERN_ERR "%s: no pud tables\n", __func__); | ||
164 | ret = -ENOMEM; | ||
165 | break; | ||
166 | } | ||
167 | |||
168 | pmd = pmd_alloc(&init_mm, pud, base); | ||
160 | if (!pmd) { | 169 | if (!pmd) { |
161 | printk(KERN_ERR "%s: no pmd tables\n", __func__); | 170 | printk(KERN_ERR "%s: no pmd tables\n", __func__); |
162 | ret = -ENOMEM; | 171 | ret = -ENOMEM; |