forked from Imagelibrary/rtems
2009-09-25 Joel Sherrill <joel.sherrill@oarcorp.com>
* shared/include/io.h, shared/include/mmu.h: Change extern inline to static inline.
This commit is contained in:
@@ -1,3 +1,8 @@
|
|||||||
|
2009-09-25 Joel Sherrill <joel.sherrill@oarcorp.com>
|
||||||
|
|
||||||
|
* shared/include/io.h, shared/include/mmu.h: Change extern inline to
|
||||||
|
static inline.
|
||||||
|
|
||||||
2009-08-27 Joel Sherrill <joel.sherrill@OARcorp.com>
|
2009-08-27 Joel Sherrill <joel.sherrill@OARcorp.com>
|
||||||
|
|
||||||
* mpc6xx/mmu/bat.c, mpc6xx/mmu/bat.h: Fix spelling.
|
* mpc6xx/mmu/bat.c, mpc6xx/mmu/bat.h: Fix spelling.
|
||||||
|
|||||||
@@ -51,7 +51,7 @@
|
|||||||
* Acts as a barrier to ensure all previous I/O accesses have
|
* Acts as a barrier to ensure all previous I/O accesses have
|
||||||
* completed before any further ones are issued.
|
* completed before any further ones are issued.
|
||||||
*/
|
*/
|
||||||
extern inline void eieio(void)
|
static inline void eieio(void)
|
||||||
{
|
{
|
||||||
__asm__ __volatile__ ("eieio");
|
__asm__ __volatile__ ("eieio");
|
||||||
}
|
}
|
||||||
@@ -67,7 +67,7 @@ extern inline void eieio(void)
|
|||||||
/*
|
/*
|
||||||
* 8, 16 and 32 bit, big and little endian I/O operations, with barrier.
|
* 8, 16 and 32 bit, big and little endian I/O operations, with barrier.
|
||||||
*/
|
*/
|
||||||
extern inline int in_8(volatile unsigned char *addr)
|
static inline int in_8(volatile unsigned char *addr)
|
||||||
{
|
{
|
||||||
int ret;
|
int ret;
|
||||||
|
|
||||||
@@ -75,12 +75,12 @@ extern inline int in_8(volatile unsigned char *addr)
|
|||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
extern inline void out_8(volatile unsigned char *addr, int val)
|
static inline void out_8(volatile unsigned char *addr, int val)
|
||||||
{
|
{
|
||||||
__asm__ __volatile__("stb%U0%X0 %1,%0; eieio" : "=m" (*addr) : "r" (val));
|
__asm__ __volatile__("stb%U0%X0 %1,%0; eieio" : "=m" (*addr) : "r" (val));
|
||||||
}
|
}
|
||||||
|
|
||||||
extern inline int in_le16(volatile unsigned short *addr)
|
static inline int in_le16(volatile unsigned short *addr)
|
||||||
{
|
{
|
||||||
int ret;
|
int ret;
|
||||||
|
|
||||||
@@ -89,7 +89,7 @@ extern inline int in_le16(volatile unsigned short *addr)
|
|||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
extern inline int in_be16(volatile unsigned short *addr)
|
static inline int in_be16(volatile unsigned short *addr)
|
||||||
{
|
{
|
||||||
int ret;
|
int ret;
|
||||||
|
|
||||||
@@ -97,18 +97,18 @@ extern inline int in_be16(volatile unsigned short *addr)
|
|||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
extern inline void out_le16(volatile unsigned short *addr, int val)
|
static inline void out_le16(volatile unsigned short *addr, int val)
|
||||||
{
|
{
|
||||||
__asm__ __volatile__("sthbrx %1,0,%2; eieio" : "=m" (*addr) :
|
__asm__ __volatile__("sthbrx %1,0,%2; eieio" : "=m" (*addr) :
|
||||||
"r" (val), "r" (addr));
|
"r" (val), "r" (addr));
|
||||||
}
|
}
|
||||||
|
|
||||||
extern inline void out_be16(volatile unsigned short *addr, int val)
|
static inline void out_be16(volatile unsigned short *addr, int val)
|
||||||
{
|
{
|
||||||
__asm__ __volatile__("sth%U0%X0 %1,%0; eieio" : "=m" (*addr) : "r" (val));
|
__asm__ __volatile__("sth%U0%X0 %1,%0; eieio" : "=m" (*addr) : "r" (val));
|
||||||
}
|
}
|
||||||
|
|
||||||
extern inline unsigned in_le32(volatile unsigned *addr)
|
static inline unsigned in_le32(volatile unsigned *addr)
|
||||||
{
|
{
|
||||||
unsigned ret;
|
unsigned ret;
|
||||||
|
|
||||||
@@ -117,7 +117,7 @@ extern inline unsigned in_le32(volatile unsigned *addr)
|
|||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
extern inline unsigned in_be32(volatile unsigned *addr)
|
static inline unsigned in_be32(volatile unsigned *addr)
|
||||||
{
|
{
|
||||||
unsigned ret;
|
unsigned ret;
|
||||||
|
|
||||||
@@ -125,13 +125,13 @@ extern inline unsigned in_be32(volatile unsigned *addr)
|
|||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
extern inline void out_le32(volatile unsigned *addr, int val)
|
static inline void out_le32(volatile unsigned *addr, int val)
|
||||||
{
|
{
|
||||||
__asm__ __volatile__("stwbrx %1,0,%2; eieio" : "=m" (*addr) :
|
__asm__ __volatile__("stwbrx %1,0,%2; eieio" : "=m" (*addr) :
|
||||||
"r" (val), "r" (addr));
|
"r" (val), "r" (addr));
|
||||||
}
|
}
|
||||||
|
|
||||||
extern inline void out_be32(volatile unsigned *addr, int val)
|
static inline void out_be32(volatile unsigned *addr, int val)
|
||||||
{
|
{
|
||||||
__asm__ __volatile__("stw%U0%X0 %1,%0; eieio" : "=m" (*addr) : "r" (val));
|
__asm__ __volatile__("stw%U0%X0 %1,%0; eieio" : "=m" (*addr) : "r" (val));
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -165,7 +165,7 @@ typedef struct _MMU_context {
|
|||||||
#define HASH_TABLE_MASK_4M 0x03F
|
#define HASH_TABLE_MASK_4M 0x03F
|
||||||
|
|
||||||
/* invalidate a TLB entry */
|
/* invalidate a TLB entry */
|
||||||
extern inline void _tlbie(unsigned long va)
|
static inline void _tlbie(unsigned long va)
|
||||||
{
|
{
|
||||||
asm volatile ("tlbie %0" : : "r"(va));
|
asm volatile ("tlbie %0" : : "r"(va));
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user