We have introduced the implementation principles of low-resolution timer and high-precision timer in the previous chapters. In order to facilitate other subsystems, the kernel provides some APIs for delay or scheduling in the time subsystem, for
We have introduced the implementation principle of low-resolution timers and high-precision timers in the previous chapters, and the kernel has provided some APIs for delay or scheduling in the time subsystem to facilitate other subsystems, such as
Time Unit:Milliseconds (ms), microseconds (μs), nanosecond (ns), Picosecond (PS), femtosecond (FS), seconds, and seconds1 s = 10^3 ms = 10^6 US = 10^9 NS = 10^12 PS = 10^15 fs=10^18 PST =10^21 parsecs =10^43 Planck constantIn the development of
In Linux driver development, delay functions are often used: Msleep,mdelay/udelay.
Although both Msleep and Mdelay have a delaying effect, they are different.
1.) for the module itself
Mdelay is a busy wait function and cannot run other tasks during
In the development of Linux driver, the delay function is often used: Msleep,mdelay/udelay.Although both Msleep and mdelay have delayed effects, they are different.1.) for the module itselfMdelay is a busy wait function and cannot run other tasks
Incompatible use of msleep or schedule_timeout in tasklet? -- Linux general technology-Linux technology and application information. For details, refer to the following section. In ARM + Linux drivers, tasklet is used for interruption, msleep or
The first class of delay function prototypes are: (Busy, etc.)void Ndelay (unsigned long nsecs);void Udelay (unsigned long usecs);void Mdelay (unsigned long msecs);Description: Kernel functions ndelay, Udelay, and mdelay are useful for short delays,
Linux Kernel Timer
I. Definition
/Include/Linux/Timer. h
struct timer_list {struct list_head entry;unsigned long expires;void (*function)(unsigned long);unsigned long data;struct tvec_t_base_s *base;#ifdef CONFIG_TIMER_STATSvoid *start_site;char
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.