kernel-fxtec-pro1x/include/trace/events
Paul E. McKenney 9b2e4f1880 rcu: Track idleness independent of idle tasks
Earlier versions of RCU used the scheduling-clock tick to detect idleness
by checking for the idle task, but handled idleness differently for
CONFIG_NO_HZ=y.  But there are now a number of uses of RCU read-side
critical sections in the idle task, for example, for tracing.  A more
fine-grained detection of idleness is therefore required.

This commit presses the old dyntick-idle code into full-time service,
so that rcu_idle_enter(), previously known as rcu_enter_nohz(), is
always invoked at the beginning of an idle loop iteration.  Similarly,
rcu_idle_exit(), previously known as rcu_exit_nohz(), is always invoked
at the end of an idle-loop iteration.  This allows the idle task to
use RCU everywhere except between consecutive rcu_idle_enter() and
rcu_idle_exit() calls, in turn allowing architecture maintainers to
specify exactly where in the idle loop that RCU may be used.

Because some of the userspace upcall uses can result in what looks
to RCU like half of an interrupt, it is not possible to expect that
the irq_enter() and irq_exit() hooks will give exact counts.  This
patch therefore expands the ->dynticks_nesting counter to 64 bits
and uses two separate bitfields to count process/idle transitions
and interrupt entry/exit transitions.  It is presumed that userspace
upcalls do not happen in the idle loop or from usermode execution
(though usermode might do a system call that results in an upcall).
The counter is hard-reset on each process/idle transition, which
avoids the interrupt entry/exit error from accumulating.  Overflow
is avoided by the 64-bitness of the ->dyntick_nesting counter.

This commit also adds warnings if a non-idle task asks RCU to enter
idle state (and these checks will need some adjustment before applying
Frederic's OS-jitter patches (http://lkml.org/lkml/2011/10/7/246).
In addition, validation of ->dynticks and ->dynticks_nesting is added.

Signed-off-by: Paul E. McKenney <paul.mckenney@linaro.org>
Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
Reviewed-by: Josh Triplett <josh@joshtriplett.org>
2011-12-11 10:31:24 -08:00
..
9p.h net/9p: Convert net/9p protocol dumps to tracepoints 2011-10-24 11:13:12 -05:00
asoc.h ASoC: Add another DAPM stat for neighbour checks 2011-09-22 17:24:40 +01:00
block.h blktrace: add FLUSH/FUA support 2011-08-11 10:36:05 +02:00
btrfs.h writeback: remove .nonblocking and .encountered_congestion 2011-06-08 08:25:23 +08:00
compaction.h mm: compaction: add trace events for memory compaction activity 2011-01-13 17:32:33 -08:00
ext3.h ext3: Add fixed tracepoints 2011-06-25 17:29:51 +02:00
ext4.h ext4: optimize ext4_ext_convert_to_initialized() 2011-10-27 11:43:23 -04:00
gfpflags.h mm: tracing: add missing GFP flags to tracing 2011-05-11 18:50:45 -07:00
gpio.h gpio: add trace events for setting direction and value 2011-05-20 00:40:19 -06:00
irq.h rcu: Use softirq to address performance regression 2011-06-14 15:25:39 -07:00
jbd.h jbd: Add fixed tracepoints 2011-06-25 17:29:51 +02:00
jbd2.h jbd2: remove jbd2_dev_to_name() from jbd2 tracepoints 2011-07-10 22:05:08 -04:00
kmem.h vmscan: tracing: add trace events for kswapd wakeup, sleeping and direct reclaim 2010-08-09 20:44:59 -07:00
kvm.h KVM: cleanup async_pf tracepoints 2011-01-12 11:28:57 +02:00
lock.h tracing: Factorize lock events in a lock class 2010-05-09 13:45:35 +02:00
mce.h tracing: Fix event alignment: mce:mce_record 2011-03-10 10:34:28 -05:00
module.h include: replace linux/module.h with "struct module" wherever possible 2011-10-31 19:32:32 -04:00
napi.h napi: Convert trace_napi_poll to TRACE_EVENT 2010-09-07 17:51:01 +02:00
net.h net: tracepoint of net_dev_xmit sees freed skb and causes panic 2011-06-02 14:06:31 -07:00
power.h perf: Clean up power events by introducing new, more generic ones 2011-01-04 08:16:54 +01:00
rcu.h rcu: Track idleness independent of idle tasks 2011-12-11 10:31:24 -08:00
regmap.h regmap: Add the regcache_sync trace event 2011-09-19 19:06:34 +01:00
regulator.h regulator: Add basic trace facilities 2011-01-12 14:33:00 +00:00
rpm.h PM / Runtime: Introduce trace points for tracing rpm_* functions 2011-09-27 22:53:27 +02:00
sched.h sched, tracing: Show PREEMPT_ACTIVE state in trace_sched_switch 2011-09-26 13:25:54 +02:00
scsi.h [SCSI] Include protection operation in SCSI command trace 2011-03-14 18:36:02 -05:00
signal.h tracing: Fix null pointer deref with SEND_SIG_FORCED 2010-06-08 23:51:32 +02:00
skb.h tracing: Fix event alignment: skb:kfree_skb 2011-03-10 10:34:31 -05:00
sock.h core: add tracepoints for queueing skb to rcvbuf 2011-06-21 16:06:10 -07:00
syscalls.h tracing: Allow raw syscall trace events for non privileged users 2010-11-18 14:37:43 +01:00
timer.h tracing: Fix timer tracing 2010-08-19 13:00:41 +02:00
udp.h udp: add tracepoints for queueing skb to rcvbuf 2011-06-21 16:06:10 -07:00
vmscan.h mm: change isolate mode from #define to bitwise type 2011-10-31 17:30:44 -07:00
workqueue.h workqueue: add queue_work and activate_work trace points 2010-10-05 10:49:55 +02:00
writeback.h writeback: Add a 'reason' to wb_writeback_work 2011-10-31 00:33:36 +08:00
xen.h xen/tracing: fix compile errors when tracing is disabled. 2011-07-25 15:51:02 -07:00