Commit 83d5e64b authored by Aneesh Kumar K.V's avatar Aneesh Kumar K.V Committed by Benjamin Herrenschmidt

powerpc: Fix build errors STRICT_MM_TYPECHECKS

Signed-off-by: default avatarAneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
Signed-off-by: default avatarBenjamin Herrenschmidt <benh@kernel.crashing.org>
parent 613e60a6
...@@ -47,7 +47,7 @@ ...@@ -47,7 +47,7 @@
* generic accessors and iterators here * generic accessors and iterators here
*/ */
#define __real_pte(e,p) ((real_pte_t) { \ #define __real_pte(e,p) ((real_pte_t) { \
(e), ((e) & _PAGE_COMBO) ? \ (e), (pte_val(e) & _PAGE_COMBO) ? \
(pte_val(*((p) + PTRS_PER_PTE))) : 0 }) (pte_val(*((p) + PTRS_PER_PTE))) : 0 })
#define __rpte_to_hidx(r,index) ((pte_val((r).pte) & _PAGE_COMBO) ? \ #define __rpte_to_hidx(r,index) ((pte_val((r).pte) & _PAGE_COMBO) ? \
(((r).hidx >> ((index)<<2)) & 0xf) : ((pte_val((r).pte) >> 12) & 0xf)) (((r).hidx >> ((index)<<2)) & 0xf) : ((pte_val((r).pte) >> 12) & 0xf))
......
...@@ -359,7 +359,6 @@ static pgprot_t __pci_mmap_set_pgprot(struct pci_dev *dev, struct resource *rp, ...@@ -359,7 +359,6 @@ static pgprot_t __pci_mmap_set_pgprot(struct pci_dev *dev, struct resource *rp,
enum pci_mmap_state mmap_state, enum pci_mmap_state mmap_state,
int write_combine) int write_combine)
{ {
unsigned long prot = pgprot_val(protection);
/* Write combine is always 0 on non-memory space mappings. On /* Write combine is always 0 on non-memory space mappings. On
* memory space, if the user didn't pass 1, we check for a * memory space, if the user didn't pass 1, we check for a
...@@ -376,9 +375,9 @@ static pgprot_t __pci_mmap_set_pgprot(struct pci_dev *dev, struct resource *rp, ...@@ -376,9 +375,9 @@ static pgprot_t __pci_mmap_set_pgprot(struct pci_dev *dev, struct resource *rp,
/* XXX would be nice to have a way to ask for write-through */ /* XXX would be nice to have a way to ask for write-through */
if (write_combine) if (write_combine)
return pgprot_noncached_wc(prot); return pgprot_noncached_wc(protection);
else else
return pgprot_noncached(prot); return pgprot_noncached(protection);
} }
/* /*
......
...@@ -215,7 +215,8 @@ static void __meminit vmemmap_create_mapping(unsigned long start, ...@@ -215,7 +215,8 @@ static void __meminit vmemmap_create_mapping(unsigned long start,
unsigned long phys) unsigned long phys)
{ {
int mapped = htab_bolt_mapping(start, start + page_size, phys, int mapped = htab_bolt_mapping(start, start + page_size, phys,
PAGE_KERNEL, mmu_vmemmap_psize, pgprot_val(PAGE_KERNEL),
mmu_vmemmap_psize,
mmu_kernel_ssize); mmu_kernel_ssize);
BUG_ON(mapped < 0); BUG_ON(mapped < 0);
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment