git://scm.lunaixsky.com
/
lunaix-os.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
feat: gfxm: a layer provides user space access to low level interfacing of graphic...
[lunaix-os.git]
/
lunaix-os
/
hal
/
timer
/
hwtimer.c
diff --git
a/lunaix-os/hal/timer/hwtimer.c
b/lunaix-os/hal/timer/hwtimer.c
index 4da156895fb3de77384edb9e0ac5dc5a75f058e5..91dca07459d8e9caf450ecbaab8c9cddd78d8f6d 100644
(file)
--- a/
lunaix-os/hal/timer/hwtimer.c
+++ b/
lunaix-os/hal/timer/hwtimer.c
@@
-58,8
+58,9
@@
hwtimer_init(u32_t hertz, void* tick_callback)
current_timer = hwt_ctx;
current_timer = hwt_ctx;
- struct device* timerdev =
- device_addsys(NULL, &hwt_ctx->class, hwt_ctx, hwt_ctx->name);
+ struct device* timerdev = device_allocsys(NULL, hwt_ctx);
timerdev->ops.exec_cmd = __hwtimer_ioctl;
timerdev->ops.exec_cmd = __hwtimer_ioctl;
+
+ device_register(timerdev, &hwt_ctx->class, hwt_ctx->name);
}
\ No newline at end of file
}
\ No newline at end of file