mirror of
https://github.com/rdmsr/zag.git
synced 2026-10-29 22:48:20 +00:00
all: refactor coding style
This commit is contained in:
+9
-2
@@ -123,12 +123,19 @@ pub const Thread = struct {
|
||||
smr_sections: rtl.List,
|
||||
|
||||
/// Initialize a thread.
|
||||
/// - `stack`: Address of the **base** of the stack on which the initial context for the thread is built
|
||||
/// - `stack`: Address of the base of the stack used by the thread.
|
||||
/// - `stack_size`: Size of the stack
|
||||
/// - `prio`: Base priority of the thread
|
||||
/// - `entry`: Entry point of the thread
|
||||
/// - `arg`: Extraneous argument to be passed to `entry`
|
||||
pub fn init(thread: *Thread, stack: r.VAddr, stack_size: usize, prio: u8, entry: *const fn (?*anyopaque) void, arg: ?*anyopaque) void {
|
||||
pub fn init(
|
||||
thread: *Thread,
|
||||
stack: r.VAddr,
|
||||
stack_size: usize,
|
||||
prio: u8,
|
||||
entry: *const fn (?*anyopaque) void,
|
||||
arg: ?*anyopaque,
|
||||
) void {
|
||||
thread.* = .{
|
||||
.context = .init(stack, stack_size, entry, arg),
|
||||
.lock = .init(),
|
||||
|
||||
Reference in New Issue
Block a user