2015-03-12 04:45:16 +08:00
|
|
|
/*
|
2017-03-29 13:16:44 +08:00
|
|
|
* Licensed under the GNU General Public License version 2 with exceptions. See
|
|
|
|
* LICENSE file in the project root for full license information
|
2014-11-25 23:10:29 +08:00
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef _osal_defs_
|
|
|
|
#define _osal_defs_
|
|
|
|
|
2016-02-16 20:35:19 +08:00
|
|
|
#ifdef __cplusplus
|
|
|
|
extern "C"
|
|
|
|
{
|
|
|
|
#endif
|
|
|
|
|
2019-01-29 18:58:16 +08:00
|
|
|
// define if debug printf is needed
|
|
|
|
//#define EC_DEBUG
|
|
|
|
|
|
|
|
#ifdef EC_DEBUG
|
|
|
|
#define EC_PRINT printf
|
|
|
|
#else
|
|
|
|
#define EC_PRINT(...) do {} while (0)
|
|
|
|
#endif
|
|
|
|
|
2014-11-25 23:10:29 +08:00
|
|
|
#ifndef PACKED
|
|
|
|
#define PACKED_BEGIN
|
|
|
|
#define PACKED __attribute__((__packed__))
|
|
|
|
#define PACKED_END
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#include <pthread.h>
|
|
|
|
#define OSAL_THREAD_HANDLE pthread_t *
|
|
|
|
#define OSAL_THREAD_FUNC void
|
|
|
|
#define OSAL_THREAD_FUNC_RT void
|
|
|
|
|
2016-02-16 20:35:19 +08:00
|
|
|
#ifdef __cplusplus
|
|
|
|
}
|
|
|
|
#endif
|
|
|
|
|
2014-11-25 23:10:29 +08:00
|
|
|
#endif
|