mirror of https://github.com/thesofproject/sof.git
include:fix zephyr conflicting types and function
The atomic code is implemented in zephyr. When sof is used as a zephyr module, there is no need to reimplement atomic. The modification here is to solve the problem of repeated definition of atomic related content. Signed-off-by: Yang XiaoHua <yangxiaohuamail@gmail.com>
This commit is contained in:
parent
b500999477
commit
3500d0efef
|
@ -5,6 +5,9 @@
|
|||
* Author: Liam Girdwood <liam.r.girdwood@linux.intel.com>
|
||||
*/
|
||||
|
||||
#ifdef __ZEPHYR__
|
||||
#include <sys/atomic.h>
|
||||
#else
|
||||
#ifndef __SOF_ATOMIC_H__
|
||||
#define __SOF_ATOMIC_H__
|
||||
|
||||
|
@ -37,3 +40,5 @@ static inline int32_t atomic_sub(atomic_t *a, int32_t value)
|
|||
}
|
||||
|
||||
#endif /* __SOF_ATOMIC_H__ */
|
||||
|
||||
#endif /*__ZEPHYR__ */
|
||||
|
|
Loading…
Reference in New Issue