summaryrefslogtreecommitdiff
path: root/include/utils/AndroidThreads.h
diff options
context:
space:
mode:
author Jeff Brown <jeffbrown@google.com> 2012-03-16 22:18:39 -0700
committer Jeff Brown <jeffbrown@google.com> 2012-03-17 14:28:38 -0700
commit0818b0921ef6cda07f41b56d2ef19b2849dfefd1 (patch)
tree03045f51fb101a838e3ccfa28c9ba8686f7558ce /include/utils/AndroidThreads.h
parente6d77c593d1a25b45c23bf9292ec7ee09fc14b6e (diff)
Add a simple work queue abstraction.
Makes it easy to schedule a bunch of work to happen in parallel. Change-Id: Id9c0e52fc8b6d78d2b9ed4c2ee47abce0a01775c
Diffstat (limited to 'include/utils/AndroidThreads.h')
-rw-r--r--include/utils/AndroidThreads.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/utils/AndroidThreads.h b/include/utils/AndroidThreads.h
index f9f7aa41a0..5bda0fd63a 100644
--- a/include/utils/AndroidThreads.h
+++ b/include/utils/AndroidThreads.h
@@ -73,6 +73,7 @@ extern void androidSetCreateThreadFunc(android_create_thread_fn func);
// Get pid for the current thread.
extern pid_t androidGetTid();
+#ifdef HAVE_ANDROID_OS
// Change the scheduling group of a particular thread. The group
// should be one of the ANDROID_TGROUP constants. Returns BAD_VALUE if
// grp is out of range, else another non-zero value with errno set if
@@ -95,6 +96,7 @@ extern int androidGetThreadPriority(pid_t tid);
// scheduling groups are disabled. Returns INVALID_OPERATION if unexpected error.
// Thread ID zero means current thread.
extern int androidGetThreadSchedulingGroup(pid_t tid);
+#endif
#ifdef __cplusplus
} // extern "C"