Function report |
Source Code:arch\x86\kernel\tsc.c |
Create Date:2022-07-28 07:46:10 |
Last Modify:2020-03-12 14:18:49 | Copyright©Brick |
home page | Tree |
Annotation kernel can get tool activity | Download SCCT | Chinese |
Name:__set_cyc2ns_scale
Proto:static void __set_cyc2ns_scale(unsigned long khz, int cpu, unsigned long long tsc_now)
Type:void
Parameter:
Type | Parameter | Name |
---|---|---|
unsigned long | khz | |
int | cpu | |
unsigned long long | tsc_now |
136 | clocks_calc_mult_shift( & cyc2ns_mul, & cyc2ns_shift, khz, NSEC_PER_MSEC, 0) |
145 | If cyc2ns_shift == 32 Then |
146 | cyc2ns_shift = 31 |
147 | cyc2ns_mul >>= 1 |
150 | cyc2ns_offset = ns_now - mul_u64_u32_shr(tsc_now, cyc2ns_mul, cyc2ns_shift) |
153 | c2n = per_cpu_ptr( & cyc2ns, cpu) |
156 | 0 + 2*16 = 32 [0] = data |
158 | 0 + 2*16 = 32 [1] = data |
Name | Describe |
---|---|
set_cyc2ns_scale | |
cyc2ns_init_boot_cpu | Initialize cyc2ns for boot cpu |
Source code conversion tool public plug-in interface | X |
---|---|
Support c/c++/esqlc/java Oracle/Informix/Mysql Plug-in can realize: logical Report Code generation and batch code conversion |