From 1ccbd63a6ac437f3d7abf16324c8bb2070d71fbd Mon Sep 17 00:00:00 2001 From: Joel Sherrill Date: Mon, 7 Jan 2008 15:29:14 +0000 Subject: 2008-01-07 Joel Sherrill * score/inline/rtems/score/object.inl: Add _Objects_Is_api_valid. --- cpukit/score/inline/rtems/score/object.inl | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) (limited to 'cpukit/score/inline') diff --git a/cpukit/score/inline/rtems/score/object.inl b/cpukit/score/inline/rtems/score/object.inl index 891f968d86..32105ddba2 100644 --- a/cpukit/score/inline/rtems/score/object.inl +++ b/cpukit/score/inline/rtems/score/object.inl @@ -100,6 +100,23 @@ RTEMS_INLINE_ROUTINE uint32_t _Objects_Get_index( return (id >> OBJECTS_INDEX_START_BIT) & OBJECTS_INDEX_VALID_BITS; } +/** + * This function returns TRUE if the api is valid. + * + * @param[in] the_api is the api portion of an object ID. + * + * @return This method returns TRUE if the specified api value is valid + * and FALSE otherwise. + */ +RTEMS_INLINE_ROUTINE boolean _Objects_Is_api_valid( + uint32_t the_api +) +{ + if ( !the_api || the_api > OBJECTS_APIS_LAST ) + return FALSE; + return TRUE; +} + /** * This function returns TRUE if the class is valid. * -- cgit v1.2.3