forked from Imagelibrary/rtems
Use libcpu/byteorder.h for i386.
This commit is contained in:
@@ -61,6 +61,10 @@
|
|||||||
#include <libcpu/io.h>
|
#include <libcpu/io.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#if defined(__i386__)
|
||||||
|
#include <libcpu/byteorder.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
@@ -233,17 +237,6 @@ extern void Wait_X_ms( unsigned int timeToWait );
|
|||||||
#define bus_to_phys(address) ((unsigned int) ((address)))
|
#define bus_to_phys(address) ((unsigned int) ((address)))
|
||||||
#define rtems_bsp_delay_in_bus_cycles(cycle) Wait_X_ms( cycle/100 )
|
#define rtems_bsp_delay_in_bus_cycles(cycle) Wait_X_ms( cycle/100 )
|
||||||
#define CPU_CACHE_ALIGNMENT_FOR_BUFFER PG_SIZE
|
#define CPU_CACHE_ALIGNMENT_FOR_BUFFER PG_SIZE
|
||||||
|
|
||||||
static inline void st_le32(volatile uint32_t *addr, uint32_t value)
|
|
||||||
{
|
|
||||||
*(addr)=value ;
|
|
||||||
}
|
|
||||||
|
|
||||||
static inline uint32_t ld_le32(volatile uint32_t *addr)
|
|
||||||
{
|
|
||||||
return(*addr);
|
|
||||||
}
|
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if (MCLBYTES < RBUF_SIZE)
|
#if (MCLBYTES < RBUF_SIZE)
|
||||||
|
|||||||
@@ -90,6 +90,10 @@
|
|||||||
#include <libcpu/io.h>
|
#include <libcpu/io.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#if defined(__i386__)
|
||||||
|
#include <libcpu/byteorder.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
@@ -197,16 +201,6 @@ extern void Wait_X_ms( unsigned int timeToWait );
|
|||||||
#define bus_to_phys(address) ((unsigned int) ((address)))
|
#define bus_to_phys(address) ((unsigned int) ((address)))
|
||||||
#define rtems_bsp_delay_in_bus_cycles(cycle) Wait_X_ms( cycle/100 )
|
#define rtems_bsp_delay_in_bus_cycles(cycle) Wait_X_ms( cycle/100 )
|
||||||
#define CPU_CACHE_ALIGNMENT_FOR_BUFFER PG_SIZE
|
#define CPU_CACHE_ALIGNMENT_FOR_BUFFER PG_SIZE
|
||||||
|
|
||||||
static inline void st_le32(volatile uint32_t *addr, uint32_t value)
|
|
||||||
{
|
|
||||||
*(addr)=value ;
|
|
||||||
}
|
|
||||||
|
|
||||||
static inline uint32_t ld_le32(volatile uint32_t *addr)
|
|
||||||
{
|
|
||||||
return(*addr);
|
|
||||||
}
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* the actual duration waited in DELAY is not especially predictable,
|
/* the actual duration waited in DELAY is not especially predictable,
|
||||||
|
|||||||
Reference in New Issue
Block a user