mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-02-05 01:50:25 +01:00
util/simple_mtx: fix duplicate definition
botched #ifdef in the cited commit caused simple_mtx_t to be defined
twice in certain cases, which broke the docs build.
Fixes: cb31b5a958 ("clc,libcl: Clean up CL includes")
Reported-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Marek Olšák <maraeo@gmail.com>
Tested-by: Vinson Lee <vlee@freedesktop.org>
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/34504>
This commit is contained in:
parent
75214c599c
commit
d31db877e2
1 changed files with 8 additions and 4 deletions
|
|
@ -50,10 +50,6 @@
|
|||
* condition variables.
|
||||
*/
|
||||
|
||||
typedef struct {
|
||||
uint32_t val;
|
||||
} simple_mtx_t;
|
||||
|
||||
#ifndef __OPENCL_VERSION__
|
||||
|
||||
#include "util/futex.h"
|
||||
|
|
@ -78,6 +74,9 @@ extern "C" {
|
|||
#endif
|
||||
|
||||
#if UTIL_FUTEX_SUPPORTED
|
||||
typedef struct {
|
||||
uint32_t val;
|
||||
} simple_mtx_t;
|
||||
|
||||
#define SIMPLE_MTX_INITIALIZER { 0 }
|
||||
|
||||
|
|
@ -209,6 +208,11 @@ simple_mtx_assert_locked(simple_mtx_t *mtx)
|
|||
|
||||
#else
|
||||
|
||||
/* Dummy implementation to let more headers compile with OpenCL */
|
||||
typedef struct {
|
||||
uint32_t _;
|
||||
} simple_mtx_t;
|
||||
|
||||
#endif
|
||||
|
||||
#endif /* _SIMPLE_MTX_H */
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue