Writing Device Drivers
Previous Next

Time-Related Functions

The time-related functions are:

ddi_get_lbolt()

Return the number of clock ticks since reboot

ddi_get_time()

Return the current time in seconds

ddi_periodic_add()

Issue nanosecond periodic timeout requests

ddi_periodic_delete()

Cancel nanosecond periodic timeout requests

delay()

Delay execution for a specified number of clock ticks

drv_hztousec()

Convert clock ticks to microseconds

drv_usectohz()

Convert microseconds to clock ticks

drv_usecwait()

Busy-wait for specified interval

gethrtime()

Get high-resolution time

gethrvtime()

Get high-resolution LWP virtual time

timeout()

Execute a function after a specified length of time

untimeout()

Cancel the previous time out function call

drv_getparm()

ddi_get_lbolt(), ddi_get_time()

Table B-9 Deprecated Time-Related Functions

Deprecated Function

Replacement

drv_getparm()

ddi_get_lbolt(), ddi_get_time()

Previous Next