Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- static inline unsigned ccnt_read(void) {
- unsigned cc;
- __asm__ volatile ("mrc p15, 0, %0, c15, c12, 1" : "=r"(cc));
- return cc;
- }
- unsigned int lastx = 0;
- void poke(unsigned long arg) {
- unsigned x = ccnt_read();
- printk(KERN_ALERT "tick %u %d\n",x,(x - lastx));
- lastx = x;
- timer.expires = jiffies + (HZ/FREQ);
- add_timer(&timer);
- }
- [ 875.070623] tick 49848138 49848138
- [ 876.070637] tick 97284866 47436728
- [ 877.070660] tick 141050351 43765485
- [ 878.070671] tick 346197125 205146774
- [ 879.070687] tick 389887770 43690645
- [ 880.070702] tick 433868979 43981209
- [ 881.070717] tick 479485250 45616271
- [ 882.070734] tick 526325449 46840199
- [ 883.070750] tick 652657918 126332469
- [ 884.070768] tick 780097755 127439837
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement