[PATCH v2 1/2] score: Remove CPU_PARTITION_ALIGNMENT

Sebastian Huber sebastian.huber at embedded-brains.de
Thu Aug 2 13:24:31 UTC 2018


Use the CPU_SIZEOF_POINTER alignment instead.  The internal alignment
requirement is defined by the use of Chain_Node (consisting of two
pointers) to manage the free chain of partitions.

It seems that previously the condition

  CPU_PARTITION_ALIGNMENT >= sizeof(Chain_Node)

was true on all CPU ports.  Now, we need an additional check.

Update #3482.
---
 cpukit/include/rtems/rtems/partimpl.h               | 20 ++++++++++----------
 cpukit/rtems/src/partcreate.c                       | 15 +++++++++++++--
 cpukit/score/cpu/arm/include/rtems/score/cpu.h      |  3 ---
 cpukit/score/cpu/bfin/include/rtems/score/cpu.h     | 18 ------------------
 cpukit/score/cpu/epiphany/include/rtems/score/cpu.h | 15 ---------------
 cpukit/score/cpu/i386/include/rtems/score/cpu.h     |  1 -
 cpukit/score/cpu/lm32/include/rtems/score/cpu.h     | 18 ------------------
 cpukit/score/cpu/m32c/include/rtems/score/cpu.h     | 18 ------------------
 cpukit/score/cpu/m68k/include/rtems/score/cpu.h     |  1 -
 cpukit/score/cpu/mips/include/rtems/score/cpu.h     | 14 --------------
 cpukit/score/cpu/moxie/include/rtems/score/cpu.h    | 17 -----------------
 cpukit/score/cpu/nios2/include/rtems/score/cpu.h    |  2 --
 cpukit/score/cpu/no_cpu/include/rtems/score/cpu.h   | 18 ------------------
 cpukit/score/cpu/or1k/include/rtems/score/cpu.h     | 15 ---------------
 cpukit/score/cpu/powerpc/include/rtems/score/cpu.h  | 14 --------------
 cpukit/score/cpu/riscv/include/rtems/score/cpu.h    |  2 --
 cpukit/score/cpu/sh/include/rtems/score/cpu.h       | 14 --------------
 cpukit/score/cpu/sparc/include/rtems/score/cpu.h    | 13 -------------
 cpukit/score/cpu/sparc64/include/rtems/score/cpu.h  | 14 --------------
 cpukit/score/cpu/v850/include/rtems/score/cpu.h     | 18 ------------------
 cpukit/score/cpu/x86_64/include/rtems/score/cpu.h   |  1 -
 21 files changed, 23 insertions(+), 228 deletions(-)

diff --git a/cpukit/include/rtems/rtems/partimpl.h b/cpukit/include/rtems/rtems/partimpl.h
index 13ee86b4c2..ff857708f0 100644
--- a/cpukit/include/rtems/rtems/partimpl.h
+++ b/cpukit/include/rtems/rtems/partimpl.h
@@ -110,18 +110,18 @@ RTEMS_INLINE_ROUTINE bool _Partition_Is_buffer_valid (
   );
 }
 
-/**
- *  @brief Checks if partition is buffer size aligned.
- *
- *  This function returns TRUE if the use of the specified buffer_size
- *  will result in the allocation of buffers whose first byte is
- *  properly aligned, and FALSE otherwise.
- */
-RTEMS_INLINE_ROUTINE bool _Partition_Is_buffer_size_aligned (
-   uint32_t   buffer_size
+RTEMS_INLINE_ROUTINE bool _Partition_Is_buffer_size_aligned(
+  uint32_t buffer_size
+)
+{
+  return (buffer_size % CPU_SIZEOF_POINTER) == 0;
+}
+
+RTEMS_INLINE_ROUTINE bool _Partition_Is_buffer_area_aligned(
+  const void *starting_address
 )
 {
-  return ((buffer_size % CPU_PARTITION_ALIGNMENT) == 0);
+  return (((uintptr_t) starting_address) % CPU_SIZEOF_POINTER) == 0;
 }
 
 /**
diff --git a/cpukit/rtems/src/partcreate.c b/cpukit/rtems/src/partcreate.c
index c058adff1f..2facb42e3a 100644
--- a/cpukit/rtems/src/partcreate.c
+++ b/cpukit/rtems/src/partcreate.c
@@ -64,8 +64,19 @@ rtems_status_code rtems_partition_create(
   if ( !id )
     return RTEMS_INVALID_ADDRESS;
 
-  if ( length == 0 || buffer_size == 0 || length < buffer_size ||
-         !_Partition_Is_buffer_size_aligned( buffer_size ) )
+  if ( length == 0 )
+    return RTEMS_INVALID_SIZE;
+
+  if ( buffer_size == 0 )
+    return RTEMS_INVALID_SIZE;
+
+  if ( length < buffer_size )
+    return RTEMS_INVALID_SIZE;
+
+  if ( !_Partition_Is_buffer_size_aligned( buffer_size ) )
+    return RTEMS_INVALID_SIZE;
+
+  if ( buffer_size < sizeof( Chain_Node ) )
     return RTEMS_INVALID_SIZE;
 
   if ( !_Addresses_Is_aligned( starting_address ) )
diff --git a/cpukit/score/cpu/arm/include/rtems/score/cpu.h b/cpukit/score/cpu/arm/include/rtems/score/cpu.h
index ef2bbf6bfb..3343b40297 100644
--- a/cpukit/score/cpu/arm/include/rtems/score/cpu.h
+++ b/cpukit/score/cpu/arm/include/rtems/score/cpu.h
@@ -153,9 +153,6 @@
 
 #define CPU_HEAP_ALIGNMENT CPU_ALIGNMENT
 
-/* AAPCS, section 4.3.1, Aggregates */
-#define CPU_PARTITION_ALIGNMENT 4
-
 /* AAPCS, section 5.2.1.2, Stack constraints at a public interface */
 #define CPU_STACK_ALIGNMENT 8
 
diff --git a/cpukit/score/cpu/bfin/include/rtems/score/cpu.h b/cpukit/score/cpu/bfin/include/rtems/score/cpu.h
index bca3c81418..af68905edf 100644
--- a/cpukit/score/cpu/bfin/include/rtems/score/cpu.h
+++ b/cpukit/score/cpu/bfin/include/rtems/score/cpu.h
@@ -453,24 +453,6 @@ typedef struct {
 #define CPU_HEAP_ALIGNMENT         CPU_ALIGNMENT
 
 /**
- * This number corresponds to the byte alignment requirement for memory
- * buffers allocated by the partition manager.  This alignment requirement
- * may be stricter than that for the data types alignment specified by
- * @ref CPU_ALIGNMENT.  It is common for the partition to follow the same
- * alignment requirement as @ref CPU_ALIGNMENT.  If the @ref CPU_ALIGNMENT is
- * strict enough for the partition, then this should be set to
- * @ref CPU_ALIGNMENT.
- *
- * @note  This does not have to be a power of 2.  It does have to
- *        be greater or equal to than @ref CPU_ALIGNMENT.
- *
- * Port Specific Information:
- *
- * XXX document implementation including references if appropriate
- */
-#define CPU_PARTITION_ALIGNMENT    CPU_ALIGNMENT
-
-/**
  * This number corresponds to the byte alignment requirement for the
  * stack.  This alignment requirement may be stricter than that for the
  * data types alignment specified by @ref CPU_ALIGNMENT.  If the
diff --git a/cpukit/score/cpu/epiphany/include/rtems/score/cpu.h b/cpukit/score/cpu/epiphany/include/rtems/score/cpu.h
index 413c6aa33b..46213ff262 100644
--- a/cpukit/score/cpu/epiphany/include/rtems/score/cpu.h
+++ b/cpukit/score/cpu/epiphany/include/rtems/score/cpu.h
@@ -363,21 +363,6 @@ typedef Context_Control CPU_Interrupt_frame;
 #define CPU_HEAP_ALIGNMENT         CPU_ALIGNMENT
 
 /*
- *  This number corresponds to the byte alignment requirement for memory
- *  buffers allocated by the partition manager.  This alignment requirement
- *  may be stricter than that for the data types alignment specified by
- *  CPU_ALIGNMENT.  It is common for the partition to follow the same
- *  alignment requirement as CPU_ALIGNMENT.  If the CPU_ALIGNMENT is strict
- *  enough for the partition, then this should be set to CPU_ALIGNMENT.
- *
- *  NOTE:  This does not have to be a power of 2.  It does have to
- *         be greater or equal to than CPU_ALIGNMENT.
- *
- */
-
-#define CPU_PARTITION_ALIGNMENT    CPU_ALIGNMENT
-
-/*
  *  This number corresponds to the byte alignment requirement for the
  *  stack.  This alignment requirement may be stricter than that for the
  *  data types alignment specified by CPU_ALIGNMENT.  If the CPU_ALIGNMENT
diff --git a/cpukit/score/cpu/i386/include/rtems/score/cpu.h b/cpukit/score/cpu/i386/include/rtems/score/cpu.h
index 563a088f2e..2007426843 100644
--- a/cpukit/score/cpu/i386/include/rtems/score/cpu.h
+++ b/cpukit/score/cpu/i386/include/rtems/score/cpu.h
@@ -362,7 +362,6 @@ extern Context_Control_fp _CPU_Null_fp_context;
 
 #define CPU_ALIGNMENT                    4
 #define CPU_HEAP_ALIGNMENT               CPU_ALIGNMENT
-#define CPU_PARTITION_ALIGNMENT          CPU_ALIGNMENT
 
 /*
  *  On i386 thread stacks require no further alignment after allocation
diff --git a/cpukit/score/cpu/lm32/include/rtems/score/cpu.h b/cpukit/score/cpu/lm32/include/rtems/score/cpu.h
index 01c22b23a9..782412f7d5 100644
--- a/cpukit/score/cpu/lm32/include/rtems/score/cpu.h
+++ b/cpukit/score/cpu/lm32/include/rtems/score/cpu.h
@@ -474,24 +474,6 @@ extern Context_Control_fp _CPU_Null_fp_context;
 #define CPU_HEAP_ALIGNMENT         CPU_ALIGNMENT
 
 /**
- * This number corresponds to the byte alignment requirement for memory
- * buffers allocated by the partition manager.  This alignment requirement
- * may be stricter than that for the data types alignment specified by
- * @ref CPU_ALIGNMENT.  It is common for the partition to follow the same
- * alignment requirement as @ref CPU_ALIGNMENT.  If the @ref CPU_ALIGNMENT is
- * strict enough for the partition, then this should be set to
- * @ref CPU_ALIGNMENT.
- *
- * NOTE:  This does not have to be a power of 2.  It does have to
- *        be greater or equal to than @ref CPU_ALIGNMENT.
- *
- * Port Specific Information:
- *
- * XXX document implementation including references if appropriate
- */
-#define CPU_PARTITION_ALIGNMENT    CPU_ALIGNMENT
-
-/**
  * This number corresponds to the byte alignment requirement for the
  * stack.  This alignment requirement may be stricter than that for the
  * data types alignment specified by @ref CPU_ALIGNMENT.
diff --git a/cpukit/score/cpu/m32c/include/rtems/score/cpu.h b/cpukit/score/cpu/m32c/include/rtems/score/cpu.h
index 122bc42986..7eb3ab326e 100644
--- a/cpukit/score/cpu/m32c/include/rtems/score/cpu.h
+++ b/cpukit/score/cpu/m32c/include/rtems/score/cpu.h
@@ -445,24 +445,6 @@ typedef struct {
 #define CPU_HEAP_ALIGNMENT         4
 
 /**
- * This number corresponds to the byte alignment requirement for memory
- * buffers allocated by the partition manager.  This alignment requirement
- * may be stricter than that for the data types alignment specified by
- * @ref CPU_ALIGNMENT.  It is common for the partition to follow the same
- * alignment requirement as @ref CPU_ALIGNMENT.  If the @ref CPU_ALIGNMENT is
- * strict enough for the partition, then this should be set to
- * @ref CPU_ALIGNMENT.
- *
- * NOTE:  This does not have to be a power of 2.  It does have to
- *        be greater or equal to than @ref CPU_ALIGNMENT.
- *
- * Port Specific Information:
- *
- * XXX document implementation including references if appropriate
- */
-#define CPU_PARTITION_ALIGNMENT    CPU_ALIGNMENT
-
-/**
  * This number corresponds to the byte alignment requirement for the
  * stack.  This alignment requirement may be stricter than that for the
  * data types alignment specified by @ref CPU_ALIGNMENT.  If the
diff --git a/cpukit/score/cpu/m68k/include/rtems/score/cpu.h b/cpukit/score/cpu/m68k/include/rtems/score/cpu.h
index 8b44347642..b7ab352cad 100644
--- a/cpukit/score/cpu/m68k/include/rtems/score/cpu.h
+++ b/cpukit/score/cpu/m68k/include/rtems/score/cpu.h
@@ -331,7 +331,6 @@ extern void*                     _VBR;
 
 #define CPU_ALIGNMENT                    4
 #define CPU_HEAP_ALIGNMENT               CPU_ALIGNMENT
-#define CPU_PARTITION_ALIGNMENT          CPU_ALIGNMENT
 
 /*
  *  On m68k thread stacks require no further alignment after allocation
diff --git a/cpukit/score/cpu/mips/include/rtems/score/cpu.h b/cpukit/score/cpu/mips/include/rtems/score/cpu.h
index bedb79c53a..42eae73b0a 100644
--- a/cpukit/score/cpu/mips/include/rtems/score/cpu.h
+++ b/cpukit/score/cpu/mips/include/rtems/score/cpu.h
@@ -553,20 +553,6 @@ extern Context_Control_fp _CPU_Null_fp_context;
 #define CPU_HEAP_ALIGNMENT         CPU_ALIGNMENT
 
 /*
- *  This number corresponds to the byte alignment requirement for memory
- *  buffers allocated by the partition manager.  This alignment requirement
- *  may be stricter than that for the data types alignment specified by
- *  CPU_ALIGNMENT.  It is common for the partition to follow the same
- *  alignment requirement as CPU_ALIGNMENT.  If the CPU_ALIGNMENT is strict
- *  enough for the partition, then this should be set to CPU_ALIGNMENT.
- *
- *  NOTE:  This does not have to be a power of 2.  It does have to
- *         be greater or equal to than CPU_ALIGNMENT.
- */
-
-#define CPU_PARTITION_ALIGNMENT    CPU_ALIGNMENT
-
-/*
  *  This number corresponds to the byte alignment requirement for the
  *  stack.  This alignment requirement may be stricter than that for the
  *  data types alignment specified by CPU_ALIGNMENT.  If the CPU_ALIGNMENT
diff --git a/cpukit/score/cpu/moxie/include/rtems/score/cpu.h b/cpukit/score/cpu/moxie/include/rtems/score/cpu.h
index ea9595da22..79c5a61c0c 100644
--- a/cpukit/score/cpu/moxie/include/rtems/score/cpu.h
+++ b/cpukit/score/cpu/moxie/include/rtems/score/cpu.h
@@ -372,23 +372,6 @@ typedef struct {
 #define CPU_HEAP_ALIGNMENT         CPU_ALIGNMENT
 
 /*
- *  This number corresponds to the byte alignment requirement for memory
- *  buffers allocated by the partition manager.  This alignment requirement
- *  may be stricter than that for the data types alignment specified by
- *  CPU_ALIGNMENT.  It is common for the partition to follow the same
- *  alignment requirement as CPU_ALIGNMENT.  If the CPU_ALIGNMENT is strict
- *  enough for the partition, then this should be set to CPU_ALIGNMENT.
- *
- *  NOTE:  This does not have to be a power of 2.  It does have to
- *         be greater or equal to than CPU_ALIGNMENT.
- *
- *  MOXIE Specific Information:
- *
- *  XXX
- */
-#define CPU_PARTITION_ALIGNMENT    CPU_ALIGNMENT
-
-/*
  *  This number corresponds to the byte alignment requirement for the
  *  stack.  This alignment requirement may be stricter than that for the
  *  data types alignment specified by CPU_ALIGNMENT.  If the CPU_ALIGNMENT
diff --git a/cpukit/score/cpu/nios2/include/rtems/score/cpu.h b/cpukit/score/cpu/nios2/include/rtems/score/cpu.h
index 0a1b957dc4..fa052842c8 100644
--- a/cpukit/score/cpu/nios2/include/rtems/score/cpu.h
+++ b/cpukit/score/cpu/nios2/include/rtems/score/cpu.h
@@ -73,8 +73,6 @@ extern "C" {
 
 #define CPU_HEAP_ALIGNMENT CPU_ALIGNMENT
 
-#define CPU_PARTITION_ALIGNMENT CPU_ALIGNMENT
-
 /*
  * Alignment value according to "Nios II Processor Reference" chapter 7
  * "Application Binary Interface" section "Stacks".
diff --git a/cpukit/score/cpu/no_cpu/include/rtems/score/cpu.h b/cpukit/score/cpu/no_cpu/include/rtems/score/cpu.h
index 7327dff610..427e381582 100644
--- a/cpukit/score/cpu/no_cpu/include/rtems/score/cpu.h
+++ b/cpukit/score/cpu/no_cpu/include/rtems/score/cpu.h
@@ -597,24 +597,6 @@ extern Context_Control_fp _CPU_Null_fp_context;
 #define CPU_HEAP_ALIGNMENT         CPU_ALIGNMENT
 
 /**
- * This number corresponds to the byte alignment requirement for memory
- * buffers allocated by the partition manager.  This alignment requirement
- * may be stricter than that for the data types alignment specified by
- * @ref CPU_ALIGNMENT.  It is common for the partition to follow the same
- * alignment requirement as @ref CPU_ALIGNMENT.  If the @ref CPU_ALIGNMENT is
- * strict enough for the partition, then this should be set to
- * @ref CPU_ALIGNMENT.
- *
- * NOTE:  This does not have to be a power of 2.  It does have to
- *        be greater or equal to than @ref CPU_ALIGNMENT.
- *
- * Port Specific Information:
- *
- * XXX document implementation including references if appropriate
- */
-#define CPU_PARTITION_ALIGNMENT    CPU_ALIGNMENT
-
-/**
  * This number corresponds to the byte alignment requirement for the
  * stack.  This alignment requirement may be stricter than that for the
  * data types alignment specified by @ref CPU_ALIGNMENT.  If the
diff --git a/cpukit/score/cpu/or1k/include/rtems/score/cpu.h b/cpukit/score/cpu/or1k/include/rtems/score/cpu.h
index 0c8358bfb9..1989417a3f 100644
--- a/cpukit/score/cpu/or1k/include/rtems/score/cpu.h
+++ b/cpukit/score/cpu/or1k/include/rtems/score/cpu.h
@@ -360,21 +360,6 @@ typedef Context_Control CPU_Interrupt_frame;
 #define CPU_HEAP_ALIGNMENT         CPU_ALIGNMENT
 
 /*
- *  This number corresponds to the byte alignment requirement for memory
- *  buffers allocated by the partition manager.  This alignment requirement
- *  may be stricter than that for the data types alignment specified by
- *  CPU_ALIGNMENT.  It is common for the partition to follow the same
- *  alignment requirement as CPU_ALIGNMENT.  If the CPU_ALIGNMENT is strict
- *  enough for the partition, then this should be set to CPU_ALIGNMENT.
- *
- *  NOTE:  This does not have to be a power of 2.  It does have to
- *         be greater or equal to than CPU_ALIGNMENT.
- *
- */
-
-#define CPU_PARTITION_ALIGNMENT    CPU_ALIGNMENT
-
-/*
  *  This number corresponds to the byte alignment requirement for the
  *  stack.  This alignment requirement may be stricter than that for the
  *  data types alignment specified by CPU_ALIGNMENT.  If the CPU_ALIGNMENT
diff --git a/cpukit/score/cpu/powerpc/include/rtems/score/cpu.h b/cpukit/score/cpu/powerpc/include/rtems/score/cpu.h
index 1b766f83cf..a2a1135363 100644
--- a/cpukit/score/cpu/powerpc/include/rtems/score/cpu.h
+++ b/cpukit/score/cpu/powerpc/include/rtems/score/cpu.h
@@ -683,20 +683,6 @@ void ppc_set_interrupt_level( uint32_t level );
 #define CPU_HEAP_ALIGNMENT         (PPC_ALIGNMENT)
 
 /*
- *  This number corresponds to the byte alignment requirement for memory
- *  buffers allocated by the partition manager.  This alignment requirement
- *  may be stricter than that for the data types alignment specified by
- *  CPU_ALIGNMENT.  It is common for the partition to follow the same
- *  alignment requirement as CPU_ALIGNMENT.  If the CPU_ALIGNMENT is strict
- *  enough for the partition, then this should be set to CPU_ALIGNMENT.
- *
- *  NOTE:  This does not have to be a power of 2.  It does have to
- *         be greater or equal to than CPU_ALIGNMENT.
- */
-
-#define CPU_PARTITION_ALIGNMENT    (PPC_ALIGNMENT)
-
-/*
  *  This number corresponds to the byte alignment requirement for the
  *  stack.  This alignment requirement may be stricter than that for the
  *  data types alignment specified by CPU_ALIGNMENT.  If the CPU_ALIGNMENT
diff --git a/cpukit/score/cpu/riscv/include/rtems/score/cpu.h b/cpukit/score/cpu/riscv/include/rtems/score/cpu.h
index 64a915e8ee..e836ac0919 100644
--- a/cpukit/score/cpu/riscv/include/rtems/score/cpu.h
+++ b/cpukit/score/cpu/riscv/include/rtems/score/cpu.h
@@ -81,8 +81,6 @@ extern "C" {
 
 #define CPU_HEAP_ALIGNMENT CPU_ALIGNMENT
 
-#define CPU_PARTITION_ALIGNMENT CPU_ALIGNMENT
-
 /* RISC-V ELF psABI specification */
 #define CPU_STACK_ALIGNMENT 16
 
diff --git a/cpukit/score/cpu/sh/include/rtems/score/cpu.h b/cpukit/score/cpu/sh/include/rtems/score/cpu.h
index 4822c280aa..a61355d858 100644
--- a/cpukit/score/cpu/sh/include/rtems/score/cpu.h
+++ b/cpukit/score/cpu/sh/include/rtems/score/cpu.h
@@ -382,20 +382,6 @@ void CPU_delay( uint32_t   microseconds );
 #define CPU_HEAP_ALIGNMENT         CPU_ALIGNMENT
 
 /*
- *  This number corresponds to the byte alignment requirement for memory
- *  buffers allocated by the partition manager.  This alignment requirement
- *  may be stricter than that for the data types alignment specified by
- *  CPU_ALIGNMENT.  It is common for the partition to follow the same
- *  alignment requirement as CPU_ALIGNMENT.  If the CPU_ALIGNMENT is strict
- *  enough for the partition, then this should be set to CPU_ALIGNMENT.
- *
- *  NOTE:  This does not have to be a power of 2.  It does have to
- *         be greater or equal to than CPU_ALIGNMENT.
- */
-
-#define CPU_PARTITION_ALIGNMENT    CPU_ALIGNMENT
-
-/*
  *  This number corresponds to the byte alignment requirement for the
  *  stack.  This alignment requirement may be stricter than that for the
  *  data types alignment specified by CPU_ALIGNMENT.  If the CPU_ALIGNMENT
diff --git a/cpukit/score/cpu/sparc/include/rtems/score/cpu.h b/cpukit/score/cpu/sparc/include/rtems/score/cpu.h
index 9aaa46052f..a53791ce3f 100644
--- a/cpukit/score/cpu/sparc/include/rtems/score/cpu.h
+++ b/cpukit/score/cpu/sparc/include/rtems/score/cpu.h
@@ -771,19 +771,6 @@ extern const CPU_Trap_table_entry _CPU_Trap_slot_template;
 #define CPU_HEAP_ALIGNMENT         CPU_ALIGNMENT
 
 /**
- * This number corresponds to the byte alignment requirement for memory
- * buffers allocated by the partition manager.  This alignment requirement
- * may be stricter than that for the data types alignment specified by
- * CPU_ALIGNMENT.  It is common for the partition to follow the same
- * alignment requirement as CPU_ALIGNMENT.  If the CPU_ALIGNMENT is strict
- * enough for the partition, then this should be set to CPU_ALIGNMENT.
- *
- * NOTE:  This does not have to be a power of 2.  It does have to
- *        be greater or equal to than CPU_ALIGNMENT.
- */
-#define CPU_PARTITION_ALIGNMENT    CPU_ALIGNMENT
-
-/**
  * Stack frames must be doubleword aligned according to the System V ABI for
  * SPARC.
  */
diff --git a/cpukit/score/cpu/sparc64/include/rtems/score/cpu.h b/cpukit/score/cpu/sparc64/include/rtems/score/cpu.h
index e1773ee4cd..9175a2c888 100644
--- a/cpukit/score/cpu/sparc64/include/rtems/score/cpu.h
+++ b/cpukit/score/cpu/sparc64/include/rtems/score/cpu.h
@@ -648,20 +648,6 @@ extern const CPU_Trap_table_entry _CPU_Trap_slot_template;
 #define CPU_HEAP_ALIGNMENT         CPU_ALIGNMENT
 
 /*
- *  This number corresponds to the byte alignment requirement for memory
- *  buffers allocated by the partition manager.  This alignment requirement
- *  may be stricter than that for the data types alignment specified by
- *  CPU_ALIGNMENT.  It is common for the partition to follow the same
- *  alignment requirement as CPU_ALIGNMENT.  If the CPU_ALIGNMENT is strict
- *  enough for the partition, then this should be set to CPU_ALIGNMENT.
- *
- *  NOTE:  This does not have to be a power of 2.  It does have to
- *         be greater or equal to than CPU_ALIGNMENT.
- */
-
-#define CPU_PARTITION_ALIGNMENT    CPU_ALIGNMENT
-
-/*
  *  This number corresponds to the byte alignment requirement for the
  *  stack.  This alignment requirement may be stricter than that for the
  *  data types alignment specified by CPU_ALIGNMENT.  If the CPU_ALIGNMENT
diff --git a/cpukit/score/cpu/v850/include/rtems/score/cpu.h b/cpukit/score/cpu/v850/include/rtems/score/cpu.h
index 8efc8ba1c6..46e7bca754 100644
--- a/cpukit/score/cpu/v850/include/rtems/score/cpu.h
+++ b/cpukit/score/cpu/v850/include/rtems/score/cpu.h
@@ -413,24 +413,6 @@ typedef struct {
 #define CPU_HEAP_ALIGNMENT         CPU_ALIGNMENT
 
 /**
- * This number corresponds to the byte alignment requirement for memory
- * buffers allocated by the partition manager.  This alignment requirement
- * may be stricter than that for the data types alignment specified by
- * @ref CPU_ALIGNMENT.  It is common for the partition to follow the same
- * alignment requirement as @ref CPU_ALIGNMENT.  If the @ref CPU_ALIGNMENT is
- * strict enough for the partition, then this should be set to
- * @ref CPU_ALIGNMENT.
- *
- * @note  This does not have to be a power of 2.  It does have to
- *        be greater or equal to than @ref CPU_ALIGNMENT.
- *
- * Port Specific Information:
- *
- * There is no apparent reason why this should be larger than CPU_ALIGNMENT.
- */
-#define CPU_PARTITION_ALIGNMENT    CPU_ALIGNMENT
-
-/**
  * This number corresponds to the byte alignment requirement for the
  * stack.  This alignment requirement may be stricter than that for the
  * data types alignment specified by @ref CPU_ALIGNMENT.  If the
diff --git a/cpukit/score/cpu/x86_64/include/rtems/score/cpu.h b/cpukit/score/cpu/x86_64/include/rtems/score/cpu.h
index a0f690fc47..5c40af7647 100644
--- a/cpukit/score/cpu/x86_64/include/rtems/score/cpu.h
+++ b/cpukit/score/cpu/x86_64/include/rtems/score/cpu.h
@@ -114,7 +114,6 @@ typedef struct {
 #define CPU_SIZEOF_POINTER         8
 #define CPU_ALIGNMENT              8
 #define CPU_HEAP_ALIGNMENT         CPU_ALIGNMENT
-#define CPU_PARTITION_ALIGNMENT    CPU_ALIGNMENT
 #define CPU_STACK_ALIGNMENT        16
 #define CPU_INTERRUPT_STACK_ALIGNMENT CPU_CACHE_LINE_BYTES
 
-- 
2.13.7



More information about the devel mailing list