Skip to content

Commit

Permalink
Merge branch 'main' into fix-1420
Browse files Browse the repository at this point in the history
  • Loading branch information
dzbaker committed Jan 17, 2024
2 parents 089bf8d + 06e028c commit 9de67c9
Show file tree
Hide file tree
Showing 15 changed files with 352 additions and 786 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Changelog

## Development Build: v6.0.0-rc4+dev251
- RTEMS semaphore return bugs and functional test update
- See <https://github.com/nasa/osal/pull/1438>

## Development Build: v6.0.0-rc4+dev247
- adjust pthread stack to account for TCB+TLS
- See <https://github.com/nasa/osal/pull/1430>
Expand Down
1 change: 1 addition & 0 deletions src/os/inc/osapi-binsem.h
Original file line number Diff line number Diff line change
Expand Up @@ -193,6 +193,7 @@ int32 OS_BinSemGetIdByName(osal_id_t *sem_id, const char *sem_name);
* @retval #OS_SUCCESS @copybrief OS_SUCCESS
* @retval #OS_ERR_INVALID_ID if the id passed in is not a valid semaphore
* @retval #OS_INVALID_POINTER if the bin_prop pointer is null
* @retval #OS_ERR_NOT_IMPLEMENTED @copybrief OS_ERR_NOT_IMPLEMENTED
*/
int32 OS_BinSemGetInfo(osal_id_t sem_id, OS_bin_sem_prop_t *bin_prop);

Expand Down
1 change: 1 addition & 0 deletions src/os/inc/osapi-countsem.h
Original file line number Diff line number Diff line change
Expand Up @@ -176,6 +176,7 @@ int32 OS_CountSemGetIdByName(osal_id_t *sem_id, const char *sem_name);
* @retval #OS_SUCCESS @copybrief OS_SUCCESS
* @retval #OS_ERR_INVALID_ID if the id passed in is not a valid semaphore
* @retval #OS_INVALID_POINTER if the count_prop pointer is null
* @retval #OS_ERR_NOT_IMPLEMENTED @copybrief OS_ERR_NOT_IMPLEMENTED
*/
int32 OS_CountSemGetInfo(osal_id_t sem_id, OS_count_sem_prop_t *count_prop);

Expand Down
2 changes: 1 addition & 1 deletion src/os/inc/osapi-version.h
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
/*
* Development Build Macro Definitions
*/
#define OS_BUILD_NUMBER 247
#define OS_BUILD_NUMBER 251
#define OS_BUILD_BASELINE "equuleus-rc1"
#define OS_BUILD_DEV_CYCLE "equuleus-rc2" /**< @brief Development: Release name for current development cycle */
#define OS_BUILD_CODENAME "Equuleus" /**< @brief: Development: Code name for the current build */
Expand Down
4 changes: 2 additions & 2 deletions src/os/rtems/src/os-impl-binsem.c
Original file line number Diff line number Diff line change
Expand Up @@ -251,7 +251,7 @@ int32 OS_BinSemTimedWait_Impl(const OS_object_token_t *token, uint32 msecs)

status = rtems_semaphore_obtain(impl->id, option_set, TimeInTicks);

if (status == RTEMS_TIMEOUT)
if (status == RTEMS_TIMEOUT || (option_set == RTEMS_NO_WAIT && status == RTEMS_UNSATISFIED))
{
return OS_SEM_TIMEOUT;
}
Expand All @@ -275,5 +275,5 @@ int32 OS_BinSemTimedWait_Impl(const OS_object_token_t *token, uint32 msecs)
int32 OS_BinSemGetInfo_Impl(const OS_object_token_t *token, OS_bin_sem_prop_t *bin_prop)
{
/* RTEMS has no API for obtaining the current value of a semaphore */
return OS_SUCCESS;
return OS_ERR_NOT_IMPLEMENTED;
}
4 changes: 2 additions & 2 deletions src/os/rtems/src/os-impl-countsem.c
Original file line number Diff line number Diff line change
Expand Up @@ -216,7 +216,7 @@ int32 OS_CountSemTimedWait_Impl(const OS_object_token_t *token, uint32 msecs)

status = rtems_semaphore_obtain(impl->id, option_set, TimeInTicks);

if (status == RTEMS_TIMEOUT)
if (status == RTEMS_TIMEOUT || (option_set == RTEMS_NO_WAIT && status == RTEMS_UNSATISFIED))
{
return OS_SEM_TIMEOUT;
}
Expand All @@ -239,5 +239,5 @@ int32 OS_CountSemTimedWait_Impl(const OS_object_token_t *token, uint32 msecs)
int32 OS_CountSemGetInfo_Impl(const OS_object_token_t *token, OS_count_sem_prop_t *count_prop)
{
/* RTEMS does not provide an API to get the value */
return OS_SUCCESS;
return OS_ERR_NOT_IMPLEMENTED;
}
2 changes: 1 addition & 1 deletion src/os/shared/src/osapi-version.c
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ const char *OS_GetVersionString(void)
*-----------------------------------------------------------------*/
const char *OS_GetVersionCodeName(void)
{
return OS_VERSION_CODENAME;
return OS_BUILD_CODENAME;
}

/*----------------------------------------------------------------
Expand Down
291 changes: 0 additions & 291 deletions src/tests/bin-sem-flush-test/bin-sem-flush-test.c

This file was deleted.

Loading

0 comments on commit 9de67c9

Please sign in to comment.