glx: Remove usage of pipe_tsd_set and pipe_tsd_get
Signed-off-by: Yonggang Luo <luoyonggang@gmail.com> Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17213>
This commit is contained in:
parent
6af5cadef9
commit
af1fe5c2c8
|
@ -103,21 +103,20 @@ struct __GLXcontextRec
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
thread_local GLXContext ContextTSD;
|
||||||
static pipe_tsd ContextTSD;
|
|
||||||
|
|
||||||
/** Set current context for calling thread */
|
/** Set current context for calling thread */
|
||||||
static void
|
static void
|
||||||
SetCurrentContext(GLXContext c)
|
SetCurrentContext(GLXContext c)
|
||||||
{
|
{
|
||||||
pipe_tsd_set(&ContextTSD, c);
|
ContextTSD = c;
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Get current context for calling thread */
|
/** Get current context for calling thread */
|
||||||
static GLXContext
|
static GLXContext
|
||||||
GetCurrentContext(void)
|
GetCurrentContext(void)
|
||||||
{
|
{
|
||||||
return pipe_tsd_get(&ContextTSD);
|
return ContextTSD;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue