diff options
author | Sam Ravnborg <sam@ravnborg.org> | 2014-05-17 01:25:40 +0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2014-05-19 06:01:26 +0400 |
commit | f977ea49ae24c3bf0595725465b9ca25385de307 (patch) | |
tree | ac9fe9b7a1b2060f4ffe7cac7e50285dbd37c4fc /arch/sparc/include/asm/iommu_32.h | |
parent | 178f0ffa63475cd2fb69280900a71339292363bc (diff) | |
download | linux-f977ea49ae24c3bf0595725465b9ca25385de307.tar.xz |
sparc32: fix sparse warning in iommu.c
Fix following warning:
iommu.c:69:21: warning: incorrect type in assignment (different address spaces)
iommu_struct.regs is __iomem - fix up all users.
Introduce sbus operations for all read/write operations.
Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'arch/sparc/include/asm/iommu_32.h')
-rw-r--r-- | arch/sparc/include/asm/iommu_32.h | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/arch/sparc/include/asm/iommu_32.h b/arch/sparc/include/asm/iommu_32.h index 70c589c05a10..f6c066b52fd6 100644 --- a/arch/sparc/include/asm/iommu_32.h +++ b/arch/sparc/include/asm/iommu_32.h @@ -99,7 +99,7 @@ struct iommu_regs { #define IOPTE_WAZ 0x00000001 /* Write as zeros */ struct iommu_struct { - struct iommu_regs *regs; + struct iommu_regs __iomem *regs; iopte_t *page_table; /* For convenience */ unsigned long start; /* First managed virtual address */ @@ -108,14 +108,14 @@ struct iommu_struct { struct bit_map usemap; }; -static inline void iommu_invalidate(struct iommu_regs *regs) +static inline void iommu_invalidate(struct iommu_regs __iomem *regs) { - regs->tlbflush = 0; + sbus_writel(0, ®s->tlbflush); } -static inline void iommu_invalidate_page(struct iommu_regs *regs, unsigned long ba) +static inline void iommu_invalidate_page(struct iommu_regs __iomem *regs, unsigned long ba) { - regs->pageflush = (ba & PAGE_MASK); + sbus_writel(ba & PAGE_MASK, ®s->pageflush); } #endif /* !(_SPARC_IOMMU_H) */ |