2015/07/01

How jiffies Updated

On gdb
  watch jiffies
  c

Linux will stops when jiffies is written, then
  bt

We can get the call stack like:

#0  calc_global_load (ticks=1) at kernel/sched/proc.c:344
#1  0xc00552e8 in do_timer (ticks=) at kernel/time/timekeeping.c:1766
#2  0xc0058ec0 in tick_periodic (cpu=) at kernel/time/tick-common.c:86
#3  0xc0058efc in tick_handle_periodic (dev=0xc03e1440 ) at kernel/time/tick-common.c:103
#4  0xc001e194 in sp804_timer_interrupt (irq=, dev_id=) at arch/arm/common/timer-sp.c:125
#5  0xc0048010 in handle_irq_event_percpu (desc=0xc03e6a58 , action=0xc03e14c0 ) at kernel/irq/handle.c:143
#6  0xc0048150 in handle_irq_event (desc=0xc03e6a58 ) at kernel/irq/handle.c:192
#7  0xc004a668 in handle_level_irq (irq=, desc=0xc03ee730 ) at kernel/irq/chip.c:457
#8  0xc0047a6c in generic_handle_irq_desc (desc=, irq=) at include/linux/irqdesc.h:129
#9  generic_handle_irq (irq=) at kernel/irq/irqdesc.c:351
#10 __handle_domain_irq (domain=0xc7806020, hwirq=5, lookup=true, regs=) at kernel/irq/irqdesc.c:388
#11 0xc00087c8 in handle_domain_irq (hwirq=, domain=, regs=) at include/linux/irqdesc.h:147
#12 handle_one_vic (regs=, vic=) at drivers/irqchip/irq-vic.c:222
#13 vic_handle_irq (regs=0x1 <__vectors_start>) at drivers/irqchip/irq-vic.c:255
#14 0xc0017640 in __irq_svc () at arch/arm/kernel/entry-armv.S:206

No comments:

Post a Comment

Post Code on Blogger

Simplest way to post code to blogger for me: <pre style="background: #f0f0f0; border: 1px dashed #CCCCCC; color: black;overflow-x:...