blob: cd866f87b889ecdbc958ce73c6ba373ad968d74d (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
|
/* SPDX-License-Identifier: BSD-3-Clause
* Copyright(c) 2015 Intel Corporation
*/
#ifndef LTHREAD_MUTEX_H_
#define LTHREAD_MUTEX_H_
#ifdef __cplusplus
extern "C" {
#endif
#include "lthread_queue.h"
#define MAX_MUTEX_NAME_SIZE 64
struct lthread_mutex {
struct lthread *owner;
rte_atomic64_t count;
struct lthread_queue *blocked __rte_cache_aligned;
struct lthread_sched *root_sched;
char name[MAX_MUTEX_NAME_SIZE];
uint64_t diag_ref; /* optional ref to user diag data */
} __rte_cache_aligned;
#ifdef __cplusplus
}
#endif
#endif /* LTHREAD_MUTEX_H_ */
|