diff options
author | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2020-10-14 10:12:56 +0200 |
---|---|---|
committer | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2020-10-14 11:34:25 +0200 |
commit | 75f7e628ca82e3dee211f3fe599b784d401f8e5c (patch) | |
tree | c81cb2794302fafc168d435886bba85d7812c915 | |
parent | 38ed682d5ebd74c497f9af69fcca4153e1ff807d (diff) |
rtems: Move _Partition_Allocate_buffer()
It is only used by rtems_partition_get_buffer().
-rw-r--r-- | cpukit/include/rtems/rtems/partimpl.h | 14 | ||||
-rw-r--r-- | cpukit/rtems/src/partgetbuffer.c | 6 |
2 files changed, 6 insertions, 14 deletions
diff --git a/cpukit/include/rtems/rtems/partimpl.h b/cpukit/include/rtems/rtems/partimpl.h index fde8a9cf97..1852b9438c 100644 --- a/cpukit/include/rtems/rtems/partimpl.h +++ b/cpukit/include/rtems/rtems/partimpl.h @@ -36,20 +36,6 @@ extern "C" { */ /** - * @brief Allocate a buffer from the_partition. - * - * This function attempts to allocate a buffer from the_partition. - * If successful, it returns the address of the allocated buffer. - * Otherwise, it returns NULL. - */ -RTEMS_INLINE_ROUTINE void *_Partition_Allocate_buffer ( - Partition_Control *the_partition -) -{ - return _Chain_Get_unprotected( &the_partition->Memory ); -} - -/** * @brief Frees the_buffer to the_partition. * * This routine frees the_buffer to the_partition. diff --git a/cpukit/rtems/src/partgetbuffer.c b/cpukit/rtems/src/partgetbuffer.c index 1791ddefc3..a5d30e41d9 100644 --- a/cpukit/rtems/src/partgetbuffer.c +++ b/cpukit/rtems/src/partgetbuffer.c @@ -21,6 +21,12 @@ #endif #include <rtems/rtems/partimpl.h> +#include <rtems/score/chainimpl.h> + +static void *_Partition_Allocate_buffer( Partition_Control *the_partition ) +{ + return _Chain_Get_unprotected( &the_partition->Memory ); +} rtems_status_code rtems_partition_get_buffer( rtems_id id, |