init_MUTEX被废除(解决rror: implicit declaration of function ‘init_MUTEX’)--http://blog.csdn.net/gatieme/article/details/71598127

This commit is contained in:
gatieme
2017-05-10 22:56:36 +08:00
parent c4f1ad5d41
commit 40377d669a
+1 -1
View File
@@ -56,7 +56,7 @@ static inline void sema_init(struct semaphore *sem, int val)
```cpp
#if LINUX_VERSION_CODE > KERNEL_VERSION(2, 6, 36) && !defined(init_MUTEX)
sema_init(&sem);
sema_init(&sem, 1);
#else
init_MUTEX(&sem);
#endif