diff options
author | Srikant Patnaik | 2015-01-11 12:28:04 +0530 |
---|---|---|
committer | Srikant Patnaik | 2015-01-11 12:28:04 +0530 |
commit | 871480933a1c28f8a9fed4c4d34d06c439a7a422 (patch) | |
tree | 8718f573808810c2a1e8cb8fb6ac469093ca2784 /ANDROID_3.4.5/include/linux/semaphore.h | |
parent | 9d40ac5867b9aefe0722bc1f110b965ff294d30d (diff) | |
download | FOSSEE-netbook-kernel-source-871480933a1c28f8a9fed4c4d34d06c439a7a422.tar.gz FOSSEE-netbook-kernel-source-871480933a1c28f8a9fed4c4d34d06c439a7a422.tar.bz2 FOSSEE-netbook-kernel-source-871480933a1c28f8a9fed4c4d34d06c439a7a422.zip |
Moved, renamed, and deleted files
The original directory structure was scattered and unorganized.
Changes are basically to make it look like kernel structure.
Diffstat (limited to 'ANDROID_3.4.5/include/linux/semaphore.h')
-rw-r--r-- | ANDROID_3.4.5/include/linux/semaphore.h | 46 |
1 files changed, 0 insertions, 46 deletions
diff --git a/ANDROID_3.4.5/include/linux/semaphore.h b/ANDROID_3.4.5/include/linux/semaphore.h deleted file mode 100644 index dc368b8c..00000000 --- a/ANDROID_3.4.5/include/linux/semaphore.h +++ /dev/null @@ -1,46 +0,0 @@ -/* - * Copyright (c) 2008 Intel Corporation - * Author: Matthew Wilcox <willy@linux.intel.com> - * - * Distributed under the terms of the GNU GPL, version 2 - * - * Please see kernel/semaphore.c for documentation of these functions - */ -#ifndef __LINUX_SEMAPHORE_H -#define __LINUX_SEMAPHORE_H - -#include <linux/list.h> -#include <linux/spinlock.h> - -/* Please don't access any members of this structure directly */ -struct semaphore { - raw_spinlock_t lock; - unsigned int count; - struct list_head wait_list; -}; - -#define __SEMAPHORE_INITIALIZER(name, n) \ -{ \ - .lock = __RAW_SPIN_LOCK_UNLOCKED((name).lock), \ - .count = n, \ - .wait_list = LIST_HEAD_INIT((name).wait_list), \ -} - -#define DEFINE_SEMAPHORE(name) \ - struct semaphore name = __SEMAPHORE_INITIALIZER(name, 1) - -static inline void sema_init(struct semaphore *sem, int val) -{ - static struct lock_class_key __key; - *sem = (struct semaphore) __SEMAPHORE_INITIALIZER(*sem, val); - lockdep_init_map(&sem->lock.dep_map, "semaphore->lock", &__key, 0); -} - -extern void down(struct semaphore *sem); -extern int __must_check down_interruptible(struct semaphore *sem); -extern int __must_check down_killable(struct semaphore *sem); -extern int __must_check down_trylock(struct semaphore *sem); -extern int __must_check down_timeout(struct semaphore *sem, long jiffies); -extern void up(struct semaphore *sem); - -#endif /* __LINUX_SEMAPHORE_H */ |