Pull kmalloc into release branch
[pandora-kernel.git] / arch / powerpc / mm / pgtable_32.c
index d296eb6..8fcacb0 100644 (file)
@@ -20,7 +20,6 @@
  *
  */
 
-#include <linux/config.h>
 #include <linux/kernel.h>
 #include <linux/module.h>
 #include <linux/types.h>
@@ -372,7 +371,7 @@ void __init io_block_mapping(unsigned long virt, phys_addr_t phys,
  * the PTE pointer is unmodified if PTE is not found.
  */
 int
-get_pteptr(struct mm_struct *mm, unsigned long addr, pte_t **ptep)
+get_pteptr(struct mm_struct *mm, unsigned long addr, pte_t **ptep, pmd_t **pmdp)
 {
         pgd_t  *pgd;
         pmd_t  *pmd;
@@ -387,6 +386,8 @@ get_pteptr(struct mm_struct *mm, unsigned long addr, pte_t **ptep)
                         if (pte) {
                                retval = 1;
                                *ptep = pte;
+                               if (pmdp)
+                                       *pmdp = pmd;
                                /* XXX caller needs to do pte_unmap, yuck */
                         }
                 }
@@ -424,7 +425,7 @@ unsigned long iopa(unsigned long addr)
                mm = &init_mm;
 
        pa = 0;
-       if (get_pteptr(mm, addr, &pte)) {
+       if (get_pteptr(mm, addr, &pte, NULL)) {
                pa = (pte_val(*pte) & PAGE_MASK) | (addr & ~PAGE_MASK);
                pte_unmap(pte);
        }