This is the mail archive of the
ecos-patches@sources.redhat.com
mailing list for the eCos project.
ARM hal_io tweak
- From: Mark Salter <msalter at redhat dot com>
- To: ecos-patches at sources dot redhat dot com
- Date: Wed, 11 Dec 2002 09:46:50 -0500 (EST)
- Subject: ARM hal_io tweak
Index: hal/arm/arch/current/ChangeLog
===================================================================
RCS file: /cvs/ecos/ecos/packages/hal/arm/arch/current/ChangeLog,v
retrieving revision 1.78
diff -u -p -5 -r1.78 ChangeLog
--- hal/arm/arch/current/ChangeLog 12 Nov 2002 21:45:47 -0000 1.78
+++ hal/arm/arch/current/ChangeLog 11 Dec 2002 14:37:10 -0000
@@ -1,5 +1,10 @@
+2002-12-11 Mark Salter <msalter@redhat.com>
+
+ * include/hal_io.h: Allow variant or platform HALs to override
+ default IO macros.
+
2002-11-12 Mark Salter <msalter@redhat.com>
* src/arm_stub.c (target_ins): Account for PC prefetch when PC is
source register in data processing insns.
Index: hal/arm/arch/current/include/hal_io.h
===================================================================
RCS file: /cvs/ecos/ecos/packages/hal/arm/arch/current/include/hal_io.h,v
retrieving revision 1.11
diff -u -p -5 -r1.11 hal_io.h
--- hal/arm/arch/current/include/hal_io.h 23 May 2002 23:01:42 -0000 1.11
+++ hal/arm/arch/current/include/hal_io.h 11 Dec 2002 14:37:10 -0000
@@ -77,10 +77,13 @@
// IO Register address.
// This type is for recording the address of an IO register.
typedef volatile CYG_ADDRWORD HAL_IO_REGISTER;
+//-----------------------------------------------------------------------------
+// HAL IO macros.
+#ifndef HAL_IO_MACROS_DEFINED
//-----------------------------------------------------------------------------
// BYTE Register access.
// Individual and vectorized access to 8 bit registers.
@@ -285,10 +288,15 @@ typedef volatile CYG_ADDRWORD HAL_IO_REG
CYG_MACRO_START \
cyg_count32 _i_; \
for( _i_ = 0; _i_ < (_count_); _i_++) \
((volatile CYG_WORD32 *)(_register_))[_i_] = (_buf_)[_i_]; \
CYG_MACRO_END
+
+
+#define HAL_IO_MACROS_DEFINED
+
+#endif // !HAL_IO_MACROS_DEFINED
// Enforce a flow "barrier" to prevent optimizing compiler from reordering
// operations.
#define HAL_IO_BARRIER()