Skip to content

Commit 56bb4b6

Browse files
committed
zephyr: StaticThread must be Sync
This is needed to initialize this value into a static. Signed-off-by: David Brown <[email protected]>
1 parent 6085e87 commit 56bb4b6

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

zephyr/src/sys/thread.rs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -135,6 +135,11 @@ pub struct Thread {
135135
options: u32,
136136
}
137137

138+
/// A statically defined thread.
139+
pub type StaticThread = StaticKernelObject<k_thread>;
140+
141+
unsafe impl Sync for StaticThread {}
142+
138143
impl Wrapped for StaticKernelObject<k_thread> {
139144
type T = Thread;
140145
type I = ThreadStack;

0 commit comments

Comments
 (0)