summaryrefslogtreecommitdiffstats
path: root/src/gallium/auxiliary
diff options
context:
space:
mode:
authorTimothy Arceri <[email protected]>2017-03-06 10:41:39 +1100
committerTimothy Arceri <[email protected]>2017-03-07 09:07:33 +1100
commite92293a601bbc141bb85f88f962264fa0b1da916 (patch)
tree6a1be68109f4098b9755c0ad3b08cecd83562b7e /src/gallium/auxiliary
parente5375ba028c8ca48b11b86068efb65c4e03153eb (diff)
gallium/util: replace pipe_condvar with cnd_t
pipe_condvar was made unnecessary with fd33a6bcd7f12. Reviewed-by: Marek Olšák <[email protected]>
Diffstat (limited to 'src/gallium/auxiliary')
-rw-r--r--src/gallium/auxiliary/os/os_thread.h8
-rw-r--r--src/gallium/auxiliary/pipebuffer/pb_bufmgr_slab.c2
-rw-r--r--src/gallium/auxiliary/util/u_queue.h6
-rw-r--r--src/gallium/auxiliary/util/u_ringbuffer.c2
4 files changed, 7 insertions, 11 deletions
diff --git a/src/gallium/auxiliary/os/os_thread.h b/src/gallium/auxiliary/os/os_thread.h
index ad2cda431d1..b15dd053c3d 100644
--- a/src/gallium/auxiliary/os/os_thread.h
+++ b/src/gallium/auxiliary/os/os_thread.h
@@ -121,10 +121,6 @@ __pipe_mutex_assert_locked(mtx_t *mutex)
#endif
}
-/* pipe_condvar
- */
-typedef cnd_t pipe_condvar;
-
/*
* pipe_barrier
@@ -157,7 +153,7 @@ typedef struct {
unsigned waiters;
uint64_t sequence;
mtx_t mutex;
- pipe_condvar condvar;
+ cnd_t condvar;
} pipe_barrier;
static inline void pipe_barrier_init(pipe_barrier *barrier, unsigned count)
@@ -209,7 +205,7 @@ static inline void pipe_barrier_wait(pipe_barrier *barrier)
typedef struct
{
mtx_t mutex;
- pipe_condvar cond;
+ cnd_t cond;
int counter;
} pipe_semaphore;
diff --git a/src/gallium/auxiliary/pipebuffer/pb_bufmgr_slab.c b/src/gallium/auxiliary/pipebuffer/pb_bufmgr_slab.c
index a89236ed7c1..96c0683a1bd 100644
--- a/src/gallium/auxiliary/pipebuffer/pb_bufmgr_slab.c
+++ b/src/gallium/auxiliary/pipebuffer/pb_bufmgr_slab.c
@@ -71,7 +71,7 @@ struct pb_slab_buffer
/** Use when validating, to signal that all mappings are finished */
/* TODO: Actually validation does not reach this stage yet */
- pipe_condvar event;
+ cnd_t event;
};
diff --git a/src/gallium/auxiliary/util/u_queue.h b/src/gallium/auxiliary/util/u_queue.h
index 635545f3a65..d62d87d14d7 100644
--- a/src/gallium/auxiliary/util/u_queue.h
+++ b/src/gallium/auxiliary/util/u_queue.h
@@ -41,7 +41,7 @@
*/
struct util_queue_fence {
mtx_t mutex;
- pipe_condvar cond;
+ cnd_t cond;
int signalled;
};
@@ -58,8 +58,8 @@ struct util_queue_job {
struct util_queue {
const char *name;
mtx_t lock;
- pipe_condvar has_queued_cond;
- pipe_condvar has_space_cond;
+ cnd_t has_queued_cond;
+ cnd_t has_space_cond;
thrd_t *threads;
int num_queued;
unsigned num_threads;
diff --git a/src/gallium/auxiliary/util/u_ringbuffer.c b/src/gallium/auxiliary/util/u_ringbuffer.c
index fd51f266425..4d6166833e4 100644
--- a/src/gallium/auxiliary/util/u_ringbuffer.c
+++ b/src/gallium/auxiliary/util/u_ringbuffer.c
@@ -16,7 +16,7 @@ struct util_ringbuffer
*/
unsigned head;
unsigned tail;
- pipe_condvar change;
+ cnd_t change;
mtx_t mutex;
};