/haiku/src/system/kernel/arch/arm/ |
H A D | arch_timer.cpp | 40 HardwareTimer *timer = HardwareTimer::Get(); in arch_timer_set_hardware_timer() local 41 if (timer != NULL) in arch_timer_set_hardware_timer() 42 timer->SetTimeout(timeout); in arch_timer_set_hardware_timer() 49 HardwareTimer *timer = HardwareTimer::Get(); in arch_timer_clear_hardware_timer() local 50 if (timer != NULL) in arch_timer_clear_hardware_timer() 51 timer->Clear(); in arch_timer_clear_hardware_timer() 62 } else if (strncmp(args->arch_args.timer.kind, TIMER_KIND_OMAP3, in arch_init_timer() 63 sizeof(args->arch_args.timer.kind)) == 0) { in arch_init_timer() 64 OMAP3Timer::Init(args->arch_args.timer.regs.start, in arch_init_timer() 65 args->arch_args.timer.interrupt); in arch_init_timer() [all …]
|
/haiku/src/add-ons/kernel/network/stack/ |
H A D | utility.cpp | 336 struct net_timer* timer = NULL; in timer_thread() local 338 timer = (net_timer*)list_get_next_item(&sTimers, timer); in timer_thread() 339 if (timer == NULL) in timer_thread() 342 if (timer->due < system_time()) { in timer_thread() 344 list_remove_item(&sTimers, timer); in timer_thread() 345 timer->due = -1; in timer_thread() 346 sCurrentTimer = timer; in timer_thread() 349 timer->hook(timer, timer->data); in timer_thread() 355 timer = NULL; in timer_thread() 359 if (timer->due < timeout) in timer_thread() [all …]
|
H A D | utility.h | 65 void init_timer(net_timer* timer, net_timer_func hook, void* data); 66 void set_timer(net_timer* timer, bigtime_t delay); 67 bool cancel_timer(struct net_timer* timer); 68 status_t wait_for_timer(struct net_timer* timer); 69 bool is_timer_active(net_timer* timer); 70 bool is_timer_running(net_timer* timer);
|
/haiku/src/add-ons/kernel/drivers/timer/ |
H A D | hpet.cpp | 42 hpet_timer* timer; member 97 hpet_set_hardware_timer(bigtime_t relativeTimeout, hpet_timer *timer) in hpet_set_hardware_timer() argument 108 timer->u0.comparator64 = timerValue; in hpet_set_hardware_timer() 110 timer->u0.comparator32 = timerValue; in hpet_set_hardware_timer() 114 timer->config |= HPET_CONF_TIMER_INT_ENABLE; in hpet_set_hardware_timer() 121 hpet_clear_hardware_timer(hpet_timer *timer) in hpet_clear_hardware_timer() argument 124 timer->config &= ~HPET_CONF_TIMER_INT_ENABLE; in hpet_clear_hardware_timer() 134 hpet_timer* timer = &sHPETRegs->timer[hpetCookie->number]; in hpet_timer_interrupt() local 137 if (!HPET_GET_CONF_TIMER_INT_IS_LEVEL(timer) in hpet_timer_interrupt() 141 hpet_clear_hardware_timer(timer); in hpet_timer_interrupt() [all …]
|
H A D | hpet.h | 43 #define HPET_GET_CAP_TIMER_ROUTE(timer) (((timer)->config & HPET_CAP_TIMER_MASK) >> 32) argument 53 #define HPET_GET_CONF_TIMER_INT_ROUTE(timer) (((timer)->config & HPET_CONF_TIMER_INT_ROUTE_MASK) >>… argument 54 #define HPET_GET_CONF_TIMER_INT_IS_LEVEL(timer) (((timer)->config & HPET_CONF_TIMER_INT_TYPE)) argument 96 struct hpet_timer timer[1]; member
|
/haiku/src/system/libroot/posix/time/ |
H A D | timer_support.cpp | 90 __timer_t* timer = new(std::nothrow) __timer_t; in timer_create() local 91 if (timer == NULL) in timer_create() 93 ObjectDeleter<__timer_t> timerDeleter(timer); in timer_create() 117 timer->SetTo(timerID, -1); in timer_create() 125 timer_delete(timer_t timer) in timer_delete() argument 127 status_t error = _kern_delete_timer(timer->id, timer->thread); in timer_delete() 131 delete timer; in timer_delete() 137 timer_gettime(timer_t timer, struct itimerspec* value) in timer_gettime() argument 140 status_t error = _kern_get_timer(timer->id, timer->thread, &info); in timer_gettime() 151 timer_settime(timer_t timer, int flags, const struct itimerspec* value, in timer_settime() argument [all …]
|
H A D | time.c | 12 time(time_t* timer) in time() argument 16 if (timer) in time() 17 *timer = secs; in time()
|
/haiku/src/system/boot/platform/efi/arch/arm/ |
H A D | arch_dtb.cpp | 87 boot_timer_info &timer = gKernelArgs.arch_args.timer; in arch_handle_fdt() local 88 if (timer.kind[0] == 0) { in arch_handle_fdt() 93 memcpy(timer.kind, kSupportedTimers[i].kind, in arch_handle_fdt() 94 sizeof(timer.kind)); in arch_handle_fdt() 96 dtb_get_reg(fdt, node, 0, timer.regs); in arch_handle_fdt() 97 timer.interrupt = dtb_get_interrupt(fdt, node); in arch_handle_fdt() 121 boot_timer_info &timer = gKernelArgs.arch_args.timer; in arch_dtb_set_kernel_args() local 123 if (timer.kind[0] == 0) { in arch_dtb_set_kernel_args() 126 dprintf(" kind: %s\n", timer.kind); in arch_dtb_set_kernel_args() 128 timer.regs.start, in arch_dtb_set_kernel_args() [all …]
|
/haiku/src/system/libroot/posix/sys/ |
H A D | itimer.cpp | 41 prepare_timer(__timer_t& timer, int which) in prepare_timer() argument 45 timer.SetTo(USER_TIMER_REAL_TIME_ID, -1); in prepare_timer() 48 timer.SetTo(USER_TIMER_TEAM_USER_TIME_ID, -1); in prepare_timer() 51 timer.SetTo(USER_TIMER_TEAM_TOTAL_TIME_ID, -1); in prepare_timer() 66 __timer_t timer; in getitimer() local 67 if (!prepare_timer(timer, which)) in getitimer() 72 if (timer_gettime(&timer, &valueSpec) != 0) in getitimer() 86 __timer_t timer; in setitimer() local 87 if (!prepare_timer(timer, which)) in setitimer() 97 if (timer_settime(&timer, 0, &valueSpec, in setitimer()
|
/haiku/src/system/kernel/arch/x86/timers/ |
H A D | x86_hpet.cpp | 142 hpet_dump_timer(volatile struct hpet_timer *timer) in hpet_dump_timer() argument 144 dprintf("HPET Timer %ld:\n", (timer - sHPETRegs->timer)); in hpet_dump_timer() 147 uint32 interrupts = (uint32)HPET_GET_CAP_TIMER_ROUTE(timer); in hpet_dump_timer() 153 dprintf("\tconfiguration: 0x%" B_PRIx64 "\n", timer->config); in hpet_dump_timer() 155 timer->config & HPET_CONF_TIMER_FSB_ENABLE ? "Yes" : "No"); in hpet_dump_timer() 157 timer->config & HPET_CONF_TIMER_INT_ENABLE ? "Yes" : "No"); in hpet_dump_timer() 159 timer->config & HPET_CONF_TIMER_TYPE ? "Periodic" : "OneShot"); in hpet_dump_timer() 161 timer->config & HPET_CONF_TIMER_INT_TYPE ? "Level" : "Edge"); in hpet_dump_timer() 164 HPET_GET_CONF_TIMER_INT_ROUTE(timer)); in hpet_dump_timer() 166 if (timer->config & HPET_CONF_TIMER_FSB_ENABLE) { in hpet_dump_timer() [all …]
|
/haiku/src/system/libnetwork/netresolv/isc/ |
H A D | ev_timers.c | 67 evTimer * timer; member 252 ctx->cur->u.timer.this == del) { in evClearTimer() 284 evTimer *timer = id.opaque; in evConfigTimer() local 289 if (heap_element(ctx->timers, timer->index) != timer) in evConfigTimer() 293 timer->mode |= EV_TMR_RATE; in evConfigTimer() 295 timer->mode &= ~EV_TMR_RATE; in evConfigTimer() 311 evTimer *timer = id.opaque; in evResetTimer() local 315 if (heap_element(ctx->timers, timer->index) != timer) in evResetTimer() 335 old_due = timer->due; in evResetTimer() 337 timer->func = func; in evResetTimer() [all …]
|
/haiku/headers/private/fs_shell/ |
H A D | fssh_time.h | 65 extern fssh_time_t fssh_time(fssh_time_t *timer); 69 extern char *fssh_ctime(const fssh_time_t *timer); 70 extern char *fssh_ctime_r(const fssh_time_t *timer, char *buffer); 71 extern struct fssh_tm *fssh_gmtime(const fssh_time_t *timer); 72 extern struct fssh_tm *fssh_gmtime_r(const fssh_time_t *timer, 74 extern struct fssh_tm *fssh_localtime(const fssh_time_t *timer); 75 extern struct fssh_tm *fssh_localtime_r(const fssh_time_t *timer,
|
/haiku/src/system/kernel/ |
H A D | UserTimer.cpp | 87 UserTimer* timer = thread != NULL in LockAndGetTimer() local 89 if (timer == NULL) in LockAndGetTimer() 92 _timer = timer; in LockAndGetTimer() 191 UserTimer::HandleTimerHook(struct timer* timer) in HandleTimerHook() argument 193 UserTimer* userTimer = reinterpret_cast<UserTimer*>(timer->user_data); in HandleTimerHook() 1145 UserTimer* timer = it.Next();) { in TimerFor() 1146 if (timer->ID() == id) in TimerFor() 1147 return timer; in TimerFor() 1159 UserTimerList::AddTimer(UserTimer* timer) in AddTimer() argument 1161 int32 id = timer->ID(); in AddTimer() [all …]
|
H A D | timer.cpp | 30 timer* events; 31 timer* current_event; 72 add_event_to_list(timer* event, timer** list) in add_event_to_list() 74 timer* next; in add_event_to_list() 75 timer* previous = NULL; in add_event_to_list() 105 timer* affectedTimers = NULL; in per_cpu_real_time_clock_changed() 106 timer** it = &cpuData.events; in per_cpu_real_time_clock_changed() 107 timer* firstEvent = *it; in per_cpu_real_time_clock_changed() 108 while (timer* event = *it) { in per_cpu_real_time_clock_changed() 129 timer* event = affectedTimers; in per_cpu_real_time_clock_changed() [all …]
|
/haiku/headers/posix/ |
H A D | time.h | 84 extern time_t time(time_t *timer); 87 extern char *ctime(const time_t *timer); 88 extern char *ctime_r(const time_t *timer, char *buffer); 89 extern struct tm *gmtime(const time_t *timer); 90 extern struct tm *gmtime_r(const time_t *timer, struct tm *tm); 91 extern struct tm *localtime(const time_t *timer); 92 extern struct tm *localtime_r(const time_t *timer, struct tm *tm);
|
/haiku/docs/user/support/ |
H A D | StopWatch.dox | 33 To use this class first create a BStopWatch object, this starts the timer 35 watch. Call ElapsedTime() to get the current timer count at any time. You 37 Reset() to reset the timer back to 0 clearing all lap info. When the 47 \brief Constructs a BStopWatch object and starts the timer. 50 created the timer starts ticking away. 67 \brief Destroys the object stopping the timer. 78 \brief Resume the timer from a suspended state. 88 \brief Suspend the timer. 98 \brief Starts a new timer lap. 106 is the time that has passed since the timer was last started (not [all …]
|
/haiku/headers/private/kernel/arch/x86/ |
H A D | arch_hpet.h | 51 #define HPET_GET_CAP_TIMER_ROUTE(timer) (((timer)->config & HPET_CAP_TIMER_MASK) >> 32) argument 52 #define HPET_GET_CONF_TIMER_INT_ROUTE(timer) (((timer)->config & HPET_CONF_TIMER_INT_ROUTE_MASK) >>… argument 94 volatile struct hpet_timer timer[1]; member
|
/haiku/src/tools/fs_shell/ |
H A D | time.cpp | 67 fssh_time(fssh_time_t *timer) in fssh_time() argument 70 if (timer) in fssh_time() 71 *timer = result; in fssh_time()
|
/haiku/src/system/kernel/arch/x86/ |
H A D | arch_timer.cpp | 99 timer_info *timer = NULL; in arch_init_timer() local 102 for (int i = 0; (timer = sTimers[i]) != NULL; i++) { in arch_init_timer() 103 if (timer->init(args) == B_OK) in arch_init_timer() 107 sTimer = timer; in arch_init_timer()
|
/haiku/headers/private/net/ |
H A D | net_stack.h | 40 typedef void (*net_timer_func)(struct net_timer* timer, void* data); 157 void (*init_timer)(net_timer* timer, net_timer_func hook, 159 void (*set_timer)(net_timer* timer, bigtime_t delay); 160 bool (*cancel_timer)(net_timer* timer); 161 status_t (*wait_for_timer)(net_timer* timer); 162 bool (*is_timer_active)(net_timer* timer); 163 bool (*is_timer_running)(net_timer* timer);
|
/haiku/src/add-ons/kernel/busses/random/virtio/ |
H A D | VirtioRNGPrivate.h | 39 static int32 HandleTimerHook(struct timer* timer); 59 timer fTimer;
|
/haiku/headers/private/kernel/ |
H A D | thread_types.h | 375 status_t AddUserTimer(UserTimer* timer); 376 void RemoveUserTimer(UserTimer* timer); 382 void UserTimerActivated(TeamTimeUserTimer* timer) in UserTimerActivated() 383 { fCPUTimeUserTimers.Add(timer); } in UserTimerActivated() 384 void UserTimerActivated(TeamUserTimeUserTimer* timer) in UserTimerActivated() 385 { fUserTimeUserTimers.Add(timer); } in UserTimerActivated() 386 void UserTimerDeactivated(TeamTimeUserTimer* timer) in UserTimerDeactivated() 387 { fCPUTimeUserTimers.Remove(timer); } in UserTimerDeactivated() 389 TeamUserTimeUserTimer* timer) in UserTimerDeactivated() 390 { fUserTimeUserTimers.Remove(timer); } in UserTimerDeactivated() [all …]
|
/haiku/headers/os/drivers/ |
H A D | KernelExport.h | 86 typedef struct timer timer; typedef 87 typedef int32 (*timer_hook)(timer *); 89 struct timer { struct 90 struct timer *next; argument 175 extern status_t add_timer(timer *t, timer_hook hook, bigtime_t period, 177 extern bool cancel_timer(timer *t);
|
/haiku/src/libs/glut/ |
H A D | glutEvent.cpp | 53 GLUTtimer *timer, *other; in glutTimerFunc() local 60 timer = freeTimerList; in glutTimerFunc() 61 freeTimerList = timer->next; in glutTimerFunc() 63 timer = new GLUTtimer(); in glutTimerFunc() 64 if (!timer) in glutTimerFunc() 68 timer->func = timerFunc; in glutTimerFunc() 69 timer->value = value; in glutTimerFunc() 70 timer->next = NULL; in glutTimerFunc() 71 timer->timeout = system_time() + (interval*1000); // 1000 ticks in a millisecond in glutTimerFunc() 74 while (other && (other->timeout < timer->timeout)) { in glutTimerFunc() [all …]
|
/haiku/src/preferences/bluetooth/ |
H A D | InquiryPanel.cpp | 171 static float timer = 0; // expected time of the inquiry process in MessageReceived() local 181 timer = BT_BASE_INQUIRY_TIME * GetInquiryTime() + 1; in MessageReceived() 183 fScanProgress->SetMaxValue(timer); in MessageReceived() 226 BMessageRunner::StartSending(fMessenger, fSecondsMessage, 1000000, timer); in MessageReceived() 247 if (fScanning && scanningTime < timer) { in MessageReceived() 251 fScanProgress->SetTo(scanningTime * 100 / timer); in MessageReceived() 255 seconds << (int)(timer - scanningTime); in MessageReceived()
|