From mboxrd@z Thu Jan 1 00:00:00 1970 From: pratyushpatel.1995@gmail.com (Pratyush Patel) Date: Tue, 22 Mar 2016 13:08:21 +0530 Subject: hrtimer_clock_base and hrtimer_cpu_base Message-ID: To: kernelnewbies@lists.kernelnewbies.org List-Id: kernelnewbies.lists.kernelnewbies.org Hello, I am unable to understand what exactly "clock_base" and "cpu_base", or simply "base" means (I am seeking an intuitive idea). I understand that hrtimer subsystem stores its timers in a red-black tree data structure, and the node for each timer can be found in struct hrtimer. And if I understand correctly, these red-black trees are stored per-CPU, each of which is processed differently, leading to a "hrtimer_cpu_base"? However, as mentioned in a comment in the hrtimer.h, the "active" attribute in "hrtimer_clock_base" stores the root node of the red-black tree. Does this mean that each CPU has multiple clock_bases, and hence multiple red-black trees? Also, could someone please let me know, or perhaps point to a relevant resource, which explains what a "timer_base" means? Relevant files: 1) http://lxr.free-electrons.com/source/include/linux/hrtimer.h 2) http://lxr.free-electrons.com/source/kernel/time/hrtimer.c Thank you, Pratyush