[PATCH] cpukit: add and use CPU_Uint32ptr type

Gedare Bloom gedare at rtems.org
Mon Mar 16 20:16:01 UTC 2015


---
 cpukit/score/cpu/arm/rtems/score/types.h     | 3 +++
 cpukit/score/cpu/avr/rtems/score/types.h     | 3 +++
 cpukit/score/cpu/bfin/rtems/score/types.h    | 3 +++
 cpukit/score/cpu/h8300/rtems/score/types.h   | 3 +++
 cpukit/score/cpu/i386/rtems/score/types.h    | 3 +++
 cpukit/score/cpu/lm32/rtems/score/types.h    | 3 +++
 cpukit/score/cpu/m32c/rtems/score/types.h    | 3 +++
 cpukit/score/cpu/m32r/rtems/score/types.h    | 3 +++
 cpukit/score/cpu/m68k/rtems/score/types.h    | 3 +++
 cpukit/score/cpu/mips/rtems/score/types.h    | 3 +++
 cpukit/score/cpu/moxie/rtems/score/types.h   | 4 ++++
 cpukit/score/cpu/nios2/rtems/score/types.h   | 3 +++
 cpukit/score/cpu/no_cpu/rtems/score/types.h  | 3 +++
 cpukit/score/cpu/or1k/rtems/score/types.h    | 3 +++
 cpukit/score/cpu/powerpc/rtems/score/types.h | 4 ++++
 cpukit/score/cpu/sh/rtems/score/types.h      | 3 +++
 cpukit/score/cpu/sparc/rtems/score/types.h   | 3 +++
 cpukit/score/cpu/sparc64/rtems/score/types.h | 3 +++
 cpukit/score/cpu/v850/rtems/score/types.h    | 3 +++
 cpukit/score/include/rtems/score/interr.h    | 2 +-
 cpukit/score/include/rtems/score/thread.h    | 2 +-
 21 files changed, 61 insertions(+), 2 deletions(-)

diff --git a/cpukit/score/cpu/arm/rtems/score/types.h b/cpukit/score/cpu/arm/rtems/score/types.h
index 6910e18..deefd54 100644
--- a/cpukit/score/cpu/arm/rtems/score/types.h
+++ b/cpukit/score/cpu/arm/rtems/score/types.h
@@ -37,6 +37,9 @@ extern "C" {
  *  This section defines the basic types for this processor.
  */
 
+/** Type that can store a 32-bit integer or a pointer. */
+typedef uintptr_t CPU_Uint32ptr;
+
 typedef uint16_t         Priority_bit_map_Word;
 
 /** @} */
diff --git a/cpukit/score/cpu/avr/rtems/score/types.h b/cpukit/score/cpu/avr/rtems/score/types.h
index 0de6ba2..f63f5d5 100644
--- a/cpukit/score/cpu/avr/rtems/score/types.h
+++ b/cpukit/score/cpu/avr/rtems/score/types.h
@@ -31,6 +31,9 @@ extern "C" {
  *  This section defines the basic types for this processor.
  */
 
+/** Type that can store a 32-bit integer or a pointer. */
+typedef unsigned long CPU_Uint32ptr;
+
 typedef uint16_t     Priority_bit_map_Word;
 typedef void avr_isr;
 typedef void ( *avr_isr_entry )( void );
diff --git a/cpukit/score/cpu/bfin/rtems/score/types.h b/cpukit/score/cpu/bfin/rtems/score/types.h
index ff120b9..eaa8de6 100644
--- a/cpukit/score/cpu/bfin/rtems/score/types.h
+++ b/cpukit/score/cpu/bfin/rtems/score/types.h
@@ -31,6 +31,9 @@ extern "C" {
  *  This section defines the basic types for this processor.
  */
 
+/** Type that can store a 32-bit integer or a pointer. */
+typedef uintptr_t CPU_Uint32ptr;
+
 /** This defines the type for a priority bit map entry. */
 typedef uint16_t Priority_bit_map_Word;
 
diff --git a/cpukit/score/cpu/h8300/rtems/score/types.h b/cpukit/score/cpu/h8300/rtems/score/types.h
index 7ac2b18..7fcac8b 100644
--- a/cpukit/score/cpu/h8300/rtems/score/types.h
+++ b/cpukit/score/cpu/h8300/rtems/score/types.h
@@ -31,6 +31,9 @@ extern "C" {
  *  This section defines the basic types for this processor.
  */
 
+/** Type that can store a 32-bit integer or a pointer. */
+typedef unsigned long CPU_Uint32ptr;
+
 typedef uint16_t     Priority_bit_map_Word;
 typedef void h8300_isr;
 typedef void ( *h8300_isr_entry )( void );
diff --git a/cpukit/score/cpu/i386/rtems/score/types.h b/cpukit/score/cpu/i386/rtems/score/types.h
index 72461fb..40ccecb 100644
--- a/cpukit/score/cpu/i386/rtems/score/types.h
+++ b/cpukit/score/cpu/i386/rtems/score/types.h
@@ -31,6 +31,9 @@ extern "C" {
  *  This section defines the basic types for this processor.
  */
 
+/** Type that can store a 32-bit integer or a pointer. */
+typedef uintptr_t CPU_Uint32ptr;
+
 typedef uint16_t Priority_bit_map_Word;
 typedef void i386_isr;
 typedef i386_isr ( *i386_isr_entry )( void );
diff --git a/cpukit/score/cpu/lm32/rtems/score/types.h b/cpukit/score/cpu/lm32/rtems/score/types.h
index ab9dcbd..c0fc8a8 100644
--- a/cpukit/score/cpu/lm32/rtems/score/types.h
+++ b/cpukit/score/cpu/lm32/rtems/score/types.h
@@ -34,6 +34,9 @@ extern "C" {
  *  This section defines the basic types for this processor.
  */
 
+/** Type that can store a 32-bit integer or a pointer. */
+typedef uintptr_t CPU_Uint32ptr;
+
 /** This defines the type for a priority bit map entry. */
 typedef uint16_t Priority_bit_map_Word;
 
diff --git a/cpukit/score/cpu/m32c/rtems/score/types.h b/cpukit/score/cpu/m32c/rtems/score/types.h
index 5c476c6..11e0a0c 100644
--- a/cpukit/score/cpu/m32c/rtems/score/types.h
+++ b/cpukit/score/cpu/m32c/rtems/score/types.h
@@ -31,6 +31,9 @@ extern "C" {
  *  This section defines the basic types for this processor.
  */
 
+/** Type that can store a 32-bit integer or a pointer. */
+typedef unsigned long CPU_Uint32ptr;
+
 /** This defines the type for a priority bit map entry. */
 typedef uint16_t Priority_bit_map_Word;
 
diff --git a/cpukit/score/cpu/m32r/rtems/score/types.h b/cpukit/score/cpu/m32r/rtems/score/types.h
index 2439fb5..3ee57f2 100644
--- a/cpukit/score/cpu/m32r/rtems/score/types.h
+++ b/cpukit/score/cpu/m32r/rtems/score/types.h
@@ -31,6 +31,9 @@ extern "C" {
  *  This section defines the basic types for this processor.
  */
 
+/** Type that can store a 32-bit integer or a pointer. */
+typedef uintptr_t CPU_Uint32ptr;
+
 /** This defines the type for a priority bit map entry. */
 typedef uint16_t Priority_bit_map_Word;
 
diff --git a/cpukit/score/cpu/m68k/rtems/score/types.h b/cpukit/score/cpu/m68k/rtems/score/types.h
index b5af1c8..96f9a4c 100644
--- a/cpukit/score/cpu/m68k/rtems/score/types.h
+++ b/cpukit/score/cpu/m68k/rtems/score/types.h
@@ -31,6 +31,9 @@ extern "C" {
  *  This section defines the basic types for this processor.
  */
 
+/** Type that can store a 32-bit integer or a pointer. */
+typedef uintptr_t CPU_Uint32ptr;
+
 typedef uint16_t     Priority_bit_map_Word;
 
 #ifdef __cplusplus
diff --git a/cpukit/score/cpu/mips/rtems/score/types.h b/cpukit/score/cpu/mips/rtems/score/types.h
index 3f9429b..01950ce 100644
--- a/cpukit/score/cpu/mips/rtems/score/types.h
+++ b/cpukit/score/cpu/mips/rtems/score/types.h
@@ -40,6 +40,9 @@ extern "C" {
  *  This section defines the basic types for this processor.
  */
 
+/** Type that can store a 32-bit integer or a pointer. */
+typedef uintptr_t CPU_Uint32ptr;
+
 typedef uint16_t     Priority_bit_map_Word;
 typedef void mips_isr;
 typedef void ( *mips_isr_entry )( void );
diff --git a/cpukit/score/cpu/moxie/rtems/score/types.h b/cpukit/score/cpu/moxie/rtems/score/types.h
index 9cabd15..64427a8 100644
--- a/cpukit/score/cpu/moxie/rtems/score/types.h
+++ b/cpukit/score/cpu/moxie/rtems/score/types.h
@@ -34,6 +34,10 @@ extern "C" {
 /*
  *  This section defines the basic types for this processor.
  */
+
+/** Type that can store a 32-bit integer or a pointer. */
+typedef uintptr_t CPU_Uint32ptr;
+
 typedef uint16_t     Priority_bit_map_Word;
 typedef void moxie_isr;
 typedef void ( *moxie_isr_entry )( void );
diff --git a/cpukit/score/cpu/nios2/rtems/score/types.h b/cpukit/score/cpu/nios2/rtems/score/types.h
index d81d19a..6eaee5c 100644
--- a/cpukit/score/cpu/nios2/rtems/score/types.h
+++ b/cpukit/score/cpu/nios2/rtems/score/types.h
@@ -31,6 +31,9 @@ extern "C" {
  *  This section defines the basic types for this processor.
  */
 
+/** Type that can store a 32-bit integer or a pointer. */
+typedef uintptr_t CPU_Uint32ptr;
+
 typedef uint16_t Priority_bit_map_Word;
 typedef void nios2_isr;
 typedef void ( *nios2_isr_entry )( void );
diff --git a/cpukit/score/cpu/no_cpu/rtems/score/types.h b/cpukit/score/cpu/no_cpu/rtems/score/types.h
index edf9277..94a93c2 100644
--- a/cpukit/score/cpu/no_cpu/rtems/score/types.h
+++ b/cpukit/score/cpu/no_cpu/rtems/score/types.h
@@ -31,6 +31,9 @@ extern "C" {
  *  This section defines the basic types for this processor.
  */
 
+/** Type that can store a 32-bit integer or a pointer. */
+typedef uintptr_t CPU_Uint32ptr;
+
 /** This defines the type for a priority bit map entry. */
 typedef uint16_t Priority_bit_map_Word;
 
diff --git a/cpukit/score/cpu/or1k/rtems/score/types.h b/cpukit/score/cpu/or1k/rtems/score/types.h
index 843a10f..b3beb83 100644
--- a/cpukit/score/cpu/or1k/rtems/score/types.h
+++ b/cpukit/score/cpu/or1k/rtems/score/types.h
@@ -36,6 +36,9 @@ extern "C" {
  *  This section defines the basic types for this processor.
  */
 
+/** Type that can store a 32-bit integer or a pointer. */
+typedef uintptr_t CPU_Uint32ptr;
+
 typedef uint16_t Priority_bit_map_Word;
 typedef void or1k_isr;
 typedef void ( *or1k_isr_entry )( void );
diff --git a/cpukit/score/cpu/powerpc/rtems/score/types.h b/cpukit/score/cpu/powerpc/rtems/score/types.h
index 0679f40..f36038f 100644
--- a/cpukit/score/cpu/powerpc/rtems/score/types.h
+++ b/cpukit/score/cpu/powerpc/rtems/score/types.h
@@ -47,6 +47,10 @@ extern "C" {
 /*
  *  This section defines the basic types for this processor.
  */
+
+/** Type that can store a 32-bit integer or a pointer. */
+typedef uintptr_t CPU_Uint32ptr;
+
 typedef uint32_t     Priority_bit_map_Word;
 typedef void ppc_isr;
 
diff --git a/cpukit/score/cpu/sh/rtems/score/types.h b/cpukit/score/cpu/sh/rtems/score/types.h
index 0734d1b..d740b2f 100644
--- a/cpukit/score/cpu/sh/rtems/score/types.h
+++ b/cpukit/score/cpu/sh/rtems/score/types.h
@@ -41,6 +41,9 @@ extern "C" {
  *  This section defines the basic types for this processor.
  */
 
+/** Type that can store a 32-bit integer or a pointer. */
+typedef uintptr_t CPU_Uint32ptr;
+
 typedef uint16_t     Priority_bit_map_Word;
 
 typedef void sh_isr;
diff --git a/cpukit/score/cpu/sparc/rtems/score/types.h b/cpukit/score/cpu/sparc/rtems/score/types.h
index 71a401c..4186012 100644
--- a/cpukit/score/cpu/sparc/rtems/score/types.h
+++ b/cpukit/score/cpu/sparc/rtems/score/types.h
@@ -27,6 +27,9 @@
 extern "C" {
 #endif
 
+/** Type that can store a 32-bit integer or a pointer. */
+typedef uintptr_t CPU_Uint32ptr;
+
 /**
  * @brief Priority bit map type.
  *
diff --git a/cpukit/score/cpu/sparc64/rtems/score/types.h b/cpukit/score/cpu/sparc64/rtems/score/types.h
index 8f2c7e3..c4d1c7f 100644
--- a/cpukit/score/cpu/sparc64/rtems/score/types.h
+++ b/cpukit/score/cpu/sparc64/rtems/score/types.h
@@ -30,6 +30,9 @@ extern "C" {
  *  This section defines the basic types for this processor.
  */
 
+/** Type that can store a 32-bit integer or a pointer. */
+typedef uintptr_t CPU_Uint32ptr;
+
 typedef uint16_t         Priority_bit_map_Word;
 typedef void sparc_isr;
 typedef void ( *sparc_isr_entry )( void );
diff --git a/cpukit/score/cpu/v850/rtems/score/types.h b/cpukit/score/cpu/v850/rtems/score/types.h
index 7645f5b..a209d09 100644
--- a/cpukit/score/cpu/v850/rtems/score/types.h
+++ b/cpukit/score/cpu/v850/rtems/score/types.h
@@ -31,6 +31,9 @@ extern "C" {
  *  This section defines the basic types for this processor.
  */
 
+/** Type that can store a 32-bit integer or a pointer. */
+typedef uintptr_t CPU_Uint32ptr;
+
 /** This defines the type for a priority bit map entry. */
 typedef uint16_t Priority_bit_map_Word;
 
diff --git a/cpukit/score/include/rtems/score/interr.h b/cpukit/score/include/rtems/score/interr.h
index 7c2a604..dcf2f2f 100644
--- a/cpukit/score/include/rtems/score/interr.h
+++ b/cpukit/score/include/rtems/score/interr.h
@@ -164,7 +164,7 @@ typedef enum {
   INTERNAL_ERROR_RESOURCE_IN_USE
 } Internal_errors_Core_list;
 
-typedef uintptr_t Internal_errors_t;
+typedef CPU_Uint32ptr Internal_errors_t;
 
 /**
  *  This type holds the fatal error information.
diff --git a/cpukit/score/include/rtems/score/thread.h b/cpukit/score/include/rtems/score/thread.h
index 4984949..cea88f4 100644
--- a/cpukit/score/include/rtems/score/thread.h
+++ b/cpukit/score/include/rtems/score/thread.h
@@ -109,7 +109,7 @@ typedef void *Thread;
  *  then converted back to a pointer to void.  The result will compare equal to
  *  the original pointer.
  */
-typedef uintptr_t Thread_Entry_numeric_type;
+typedef CPU_Uint32ptr Thread_Entry_numeric_type;
 
 /**
  *  The following defines the ways in which the entry point for a
-- 
1.9.1



More information about the devel mailing list