forked from mirrors/qmk_userspace
[Core] Use a mutex guard for split shared memory (#16647)
This commit is contained in:
parent
176ab14649
commit
7712a286dc
6 changed files with 82 additions and 20 deletions
14
platforms/synchronization_util.h
Normal file
14
platforms/synchronization_util.h
Normal file
|
@ -0,0 +1,14 @@
|
|||
// Copyright 2022 Stefan Kerkmann
|
||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||
|
||||
#pragma once
|
||||
|
||||
#if defined(PLATFORM_SUPPORTS_SYNCHRONIZATION)
|
||||
# if defined(SPLIT_KEYBOARD)
|
||||
void split_shared_memory_lock(void);
|
||||
void split_shared_memory_unlock(void);
|
||||
# endif
|
||||
#else
|
||||
inline void split_shared_memory_lock(void){};
|
||||
inline void split_shared_memory_unlock(void){};
|
||||
#endif
|
Loading…
Add table
Add a link
Reference in a new issue