[PATCH] m32r: NONCACHE_OFFSET in _port2addr
Change _port2addr() not to add NONCACHE_OFFSET. Adding NONCACHE_OFFSET requires needless address adjusting by a driver using ioremap() like a SMC91x driver. Signed-off-by: Hayato Fujiwara <fujiwara@linux-m32r.org> Signed-off-by: Hirokazu Takata <takata@linux-m32r.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
This commit is contained in:
parent
c978b0179b
commit
1343f776c5
5 changed files with 5 additions and 5 deletions
|
@ -31,7 +31,7 @@ extern void pcc_iowrite(int, unsigned long, void *, size_t, size_t, int);
|
|||
|
||||
static inline void *_port2addr(unsigned long port)
|
||||
{
|
||||
return (void *)(port + NONCACHE_OFFSET);
|
||||
return (void *)(port | (NONCACHE_OFFSET));
|
||||
}
|
||||
|
||||
static inline void *_port2addr_ne(unsigned long port)
|
||||
|
|
|
@ -33,7 +33,7 @@ extern void pcc_iowrite_word(int, unsigned long, void *, size_t, size_t, int);
|
|||
|
||||
static inline void *_port2addr(unsigned long port)
|
||||
{
|
||||
return (void *)(port + NONCACHE_OFFSET);
|
||||
return (void *)(port | (NONCACHE_OFFSET));
|
||||
}
|
||||
|
||||
#define LAN_IOSTART 0x300
|
||||
|
|
|
@ -16,7 +16,7 @@
|
|||
|
||||
static inline void *_port2addr(unsigned long port)
|
||||
{
|
||||
return (void *)(port + NONCACHE_OFFSET);
|
||||
return (void *)(port | (NONCACHE_OFFSET));
|
||||
}
|
||||
|
||||
static inline void *_port2addr_ne(unsigned long port)
|
||||
|
|
|
@ -36,7 +36,7 @@ extern void pcc_iowrite_word(int, unsigned long, void *, size_t, size_t, int);
|
|||
|
||||
static inline void *_port2addr(unsigned long port)
|
||||
{
|
||||
return (void *)(port + NONCACHE_OFFSET);
|
||||
return (void *)(port | (NONCACHE_OFFSET));
|
||||
}
|
||||
|
||||
/*
|
||||
|
|
|
@ -47,7 +47,7 @@ static inline void *_port2addr(unsigned long port)
|
|||
else if (port >= UART1_IOSTART && port <= UART1_IOEND)
|
||||
port = ((port - UART1_IOSTART) << 1) + UART1_REGSTART;
|
||||
#endif /* CONFIG_SERIAL_8250 || CONFIG_SERIAL_8250_MODULE */
|
||||
return (void *)(port + NONCACHE_OFFSET);
|
||||
return (void *)(port | (NONCACHE_OFFSET));
|
||||
}
|
||||
|
||||
static inline void delay(void)
|
||||
|
|
Loading…
Reference in a new issue