Lines Matching refs:addr
92 __EXTERN_INLINE void jensen_set_hae(unsigned long addr)
95 addr >>= 25;
96 if (addr != alpha_mv.hae_cache)
97 set_hae(addr);
114 static inline unsigned int jensen_local_inb(unsigned long addr)
116 return 0xff & *(vuip)((addr << 9) + EISA_VL82C106);
119 static inline void jensen_local_outb(u8 b, unsigned long addr)
121 *(vuip)((addr << 9) + EISA_VL82C106) = b;
125 static inline unsigned int jensen_bus_inb(unsigned long addr)
130 result = *(volatile int *)((addr << 7) + EISA_IO + 0x00);
131 return __kernel_extbl(result, addr & 3);
134 static inline void jensen_bus_outb(u8 b, unsigned long addr)
137 *(vuip)((addr << 7) + EISA_IO + 0x00) = b * 0x01010101;
147 #define jensen_is_local(addr) ( \
148 /* keyboard */ (addr == 0x60 || addr == 0x64) || \
149 /* RTC */ (addr == 0x170 || addr == 0x171) || \
150 /* mb COM2 */ (addr >= 0x2f8 && addr <= 0x2ff) || \
151 /* mb LPT1 */ (addr >= 0x3bc && addr <= 0x3be) || \
152 /* mb COM2 */ (addr >= 0x3f8 && addr <= 0x3ff))
154 __EXTERN_INLINE u8 jensen_inb(unsigned long addr)
156 if (jensen_is_local(addr))
157 return jensen_local_inb(addr);
159 return jensen_bus_inb(addr);
162 __EXTERN_INLINE void jensen_outb(u8 b, unsigned long addr)
164 if (jensen_is_local(addr))
165 jensen_local_outb(b, addr);
167 jensen_bus_outb(b, addr);
170 __EXTERN_INLINE u16 jensen_inw(unsigned long addr)
175 result = *(volatile int *) ((addr << 7) + EISA_IO + 0x20);
176 result >>= (addr & 3) * 8;
180 __EXTERN_INLINE u32 jensen_inl(unsigned long addr)
183 return *(vuip) ((addr << 7) + EISA_IO + 0x60);
186 __EXTERN_INLINE void jensen_outw(u16 b, unsigned long addr)
189 *(vuip) ((addr << 7) + EISA_IO + 0x20) = b * 0x00010001;
193 __EXTERN_INLINE void jensen_outl(u32 b, unsigned long addr)
196 *(vuip) ((addr << 7) + EISA_IO + 0x60) = b;
206 unsigned long addr = (unsigned long) xaddr;
209 jensen_set_hae(addr);
210 addr &= JENSEN_HAE_MASK;
211 result = *(volatile int *) ((addr << 7) + EISA_MEM + 0x00);
212 result >>= (addr & 3) * 8;
218 unsigned long addr = (unsigned long) xaddr;
221 jensen_set_hae(addr);
222 addr &= JENSEN_HAE_MASK;
223 result = *(volatile int *) ((addr << 7) + EISA_MEM + 0x20);
224 result >>= (addr & 3) * 8;
230 unsigned long addr = (unsigned long) xaddr;
231 jensen_set_hae(addr);
232 addr &= JENSEN_HAE_MASK;
233 return *(vuip) ((addr << 7) + EISA_MEM + 0x60);
238 unsigned long addr = (unsigned long) xaddr;
241 jensen_set_hae(addr);
242 addr &= JENSEN_HAE_MASK;
243 addr = (addr << 7) + EISA_MEM + 0x60;
244 r0 = *(vuip) (addr);
245 r1 = *(vuip) (addr + (4 << 7));
251 unsigned long addr = (unsigned long) xaddr;
252 jensen_set_hae(addr);
253 addr &= JENSEN_HAE_MASK;
254 *(vuip) ((addr << 7) + EISA_MEM + 0x00) = b * 0x01010101;
259 unsigned long addr = (unsigned long) xaddr;
260 jensen_set_hae(addr);
261 addr &= JENSEN_HAE_MASK;
262 *(vuip) ((addr << 7) + EISA_MEM + 0x20) = b * 0x00010001;
267 unsigned long addr = (unsigned long) xaddr;
268 jensen_set_hae(addr);
269 addr &= JENSEN_HAE_MASK;
270 *(vuip) ((addr << 7) + EISA_MEM + 0x60) = b;
275 unsigned long addr = (unsigned long) xaddr;
276 jensen_set_hae(addr);
277 addr &= JENSEN_HAE_MASK;
278 addr = (addr << 7) + EISA_MEM + 0x60;
279 *(vuip) (addr) = b;
280 *(vuip) (addr + (4 << 7)) = b >> 32;
283 __EXTERN_INLINE void __iomem *jensen_ioportmap(unsigned long addr)
285 return (void __iomem *)addr;
288 __EXTERN_INLINE void __iomem *jensen_ioremap(unsigned long addr,
291 return (void __iomem *)(addr + 0x100000000ul);
294 __EXTERN_INLINE int jensen_is_ioaddr(unsigned long addr)
296 return (long)addr >= 0;
299 __EXTERN_INLINE int jensen_is_mmio(const volatile void __iomem *addr)
301 return (unsigned long)addr >= 0x100000000ul;