Skip to content

Commit 243f22f

Browse files
author
Maciej Falkowski
committed
rust: clk: implement Send trait for Clk type
Signed-off-by: Maciej Falkowski <m.falkowski@samsung.com>
1 parent 60f0f3c commit 243f22f

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

rust/kernel/clk.rs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,10 @@ impl Drop for Clk {
4747
}
4848
}
4949

50+
// SAFETY: `Clk` is not restricted to a single thread so it it safe
51+
// to move it between threads.
52+
unsafe impl Send for Clk {}
53+
5054
/// A clock variant that is prepared and enabled.
5155
pub struct EnabledClk(Clk);
5256

0 commit comments

Comments
 (0)