Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 940010c5 authored by Ingo Molnar's avatar Ingo Molnar
Browse files

Merge branch 'linus' into perfcounters/core

Conflicts:
	arch/x86/kernel/irqinit.c
	arch/x86/kernel/irqinit_64.c
	arch/x86/kernel/traps.c
	arch/x86/mm/fault.c
	include/linux/sched.h
	kernel/exit.c
parents 8dc8e5e8 991ec02c
Loading
Loading
Loading
Loading
+18 −0
Original line number Original line Diff line number Diff line
What:      /sys/devices/system/cpu/cpu*/cache/index*/cache_disable_X
Date:      August 2008
KernelVersion:	2.6.27
Contact:	mark.langsdorf@amd.com
Description:	These files exist in every cpu's cache index directories.
		There are currently 2 cache_disable_# files in each
		directory.  Reading from these files on a supported
		processor will return that cache disable index value
		for that processor and node.  Writing to one of these
		files will cause the specificed cache index to be disabled.

		Currently, only AMD Family 10h Processors support cache index
		disable, and only for their L3 caches.  See the BIOS and
		Kernel Developer's Guide at
		http://www.amd.com/us-en/assets/content_type/white_papers_and_tech_docs/31116-Public-GH-BKDG_3.20_2-4-09.pdf
		for formatting information and other details on the
		cache index disable.
Users:    joachim.deguara@amd.com
+12 −0
Original line number Original line Diff line number Diff line
@@ -704,12 +704,24 @@ this directory the following files can currently be found:
				The current number of free dma_debug_entries
				The current number of free dma_debug_entries
				in the allocator.
				in the allocator.


	dma-api/driver-filter
				You can write a name of a driver into this file
				to limit the debug output to requests from that
				particular driver. Write an empty string to
				that file to disable the filter and see
				all errors again.

If you have this code compiled into your kernel it will be enabled by default.
If you have this code compiled into your kernel it will be enabled by default.
If you want to boot without the bookkeeping anyway you can provide
If you want to boot without the bookkeeping anyway you can provide
'dma_debug=off' as a boot parameter. This will disable DMA-API debugging.
'dma_debug=off' as a boot parameter. This will disable DMA-API debugging.
Notice that you can not enable it again at runtime. You have to reboot to do
Notice that you can not enable it again at runtime. You have to reboot to do
so.
so.


If you want to see debug messages only for a special device driver you can
specify the dma_debug_driver=<drivername> parameter. This will enable the
driver filter at boot time. The debug code will only print errors for that
driver afterwards. This filter can be disabled or changed later using debugfs.

When the code disables itself at runtime this is most likely because it ran
When the code disables itself at runtime this is most likely because it ran
out of dma_debug_entries. These entries are preallocated at boot. The number
out of dma_debug_entries. These entries are preallocated at boot. The number
of preallocated entries is defined per architecture. If it is too low for you
of preallocated entries is defined per architecture. If it is too low for you
+2 −1
Original line number Original line Diff line number Diff line
@@ -13,7 +13,8 @@ DOCBOOKS := z8530book.xml mcabook.xml device-drivers.xml \
	    gadget.xml libata.xml mtdnand.xml librs.xml rapidio.xml \
	    gadget.xml libata.xml mtdnand.xml librs.xml rapidio.xml \
	    genericirq.xml s390-drivers.xml uio-howto.xml scsi.xml \
	    genericirq.xml s390-drivers.xml uio-howto.xml scsi.xml \
	    mac80211.xml debugobjects.xml sh.xml regulator.xml \
	    mac80211.xml debugobjects.xml sh.xml regulator.xml \
	    alsa-driver-api.xml writing-an-alsa-driver.xml
	    alsa-driver-api.xml writing-an-alsa-driver.xml \
	    tracepoint.xml


###
###
# The build process is as follows (targets):
# The build process is as follows (targets):
+89 −0
Original line number Original line Diff line number Diff line
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN"
	"http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd" []>

<book id="Tracepoints">
 <bookinfo>
  <title>The Linux Kernel Tracepoint API</title>

  <authorgroup>
   <author>
    <firstname>Jason</firstname>
    <surname>Baron</surname>
    <affiliation>
     <address>
      <email>jbaron@redhat.com</email>
     </address>
    </affiliation>
   </author>
  </authorgroup>

  <legalnotice>
   <para>
     This documentation is free software; you can redistribute
     it and/or modify it under the terms of the GNU General Public
     License as published by the Free Software Foundation; either
     version 2 of the License, or (at your option) any later
     version.
   </para>

   <para>
     This program is distributed in the hope that it will be
     useful, but WITHOUT ANY WARRANTY; without even the implied
     warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
     See the GNU General Public License for more details.
   </para>

   <para>
     You should have received a copy of the GNU General Public
     License along with this program; if not, write to the Free
     Software Foundation, Inc., 59 Temple Place, Suite 330, Boston,
     MA 02111-1307 USA
   </para>

   <para>
     For more details see the file COPYING in the source
     distribution of Linux.
   </para>
  </legalnotice>
 </bookinfo>

 <toc></toc>
  <chapter id="intro">
   <title>Introduction</title>
   <para>
     Tracepoints are static probe points that are located in strategic points
     throughout the kernel. 'Probes' register/unregister with tracepoints
     via a callback mechanism. The 'probes' are strictly typed functions that
     are passed a unique set of parameters defined by each tracepoint.
   </para>

   <para>
     From this simple callback mechanism, 'probes' can be used to profile, debug,
     and understand kernel behavior. There are a number of tools that provide a
     framework for using 'probes'. These tools include Systemtap, ftrace, and
     LTTng.
   </para>

   <para>
     Tracepoints are defined in a number of header files via various macros. Thus,
     the purpose of this document is to provide a clear accounting of the available
     tracepoints. The intention is to understand not only what tracepoints are
     available but also to understand where future tracepoints might be added.
   </para>

   <para>
     The API presented has functions of the form:
     <function>trace_tracepointname(function parameters)</function>. These are the
     tracepoints callbacks that are found throughout the code. Registering and
     unregistering probes with these callback sites is covered in the
     <filename>Documentation/trace/*</filename> directory.
   </para>
  </chapter>

  <chapter id="irq">
   <title>IRQ</title>
!Iinclude/trace/events/irq.h
  </chapter>

</book>
+80 −22
Original line number Original line Diff line number Diff line
@@ -192,23 +192,24 @@ rcu/rcuhier (which displays the struct rcu_node hierarchy).
The output of "cat rcu/rcudata" looks as follows:
The output of "cat rcu/rcudata" looks as follows:


rcu:
rcu:
  0 c=4011 g=4012 pq=1 pqc=4011 qp=0 rpfq=1 rp=3c2a dt=23301/73 dn=2 df=1882 of=0 ri=2126 ql=2 b=10
rcu:
  1 c=4011 g=4012 pq=1 pqc=4011 qp=0 rpfq=3 rp=39a6 dt=78073/1 dn=2 df=1402 of=0 ri=1875 ql=46 b=10
  0 c=17829 g=17829 pq=1 pqc=17829 qp=0 dt=10951/1 dn=0 df=1101 of=0 ri=36 ql=0 b=10
  2 c=4010 g=4010 pq=1 pqc=4010 qp=0 rpfq=-5 rp=1d12 dt=16646/0 dn=2 df=3140 of=0 ri=2080 ql=0 b=10
  1 c=17829 g=17829 pq=1 pqc=17829 qp=0 dt=16117/1 dn=0 df=1015 of=0 ri=0 ql=0 b=10
  3 c=4012 g=4013 pq=1 pqc=4012 qp=1 rpfq=3 rp=2b50 dt=21159/1 dn=2 df=2230 of=0 ri=1923 ql=72 b=10
  2 c=17829 g=17829 pq=1 pqc=17829 qp=0 dt=1445/1 dn=0 df=1839 of=0 ri=0 ql=0 b=10
  4 c=4012 g=4013 pq=1 pqc=4012 qp=1 rpfq=3 rp=1644 dt=5783/1 dn=2 df=3348 of=0 ri=2805 ql=7 b=10
  3 c=17829 g=17829 pq=1 pqc=17829 qp=0 dt=6681/1 dn=0 df=1545 of=0 ri=0 ql=0 b=10
  5 c=4012 g=4013 pq=0 pqc=4011 qp=1 rpfq=3 rp=1aac dt=5879/1 dn=2 df=3140 of=0 ri=2066 ql=10 b=10
  4 c=17829 g=17829 pq=1 pqc=17829 qp=0 dt=1003/1 dn=0 df=1992 of=0 ri=0 ql=0 b=10
  6 c=4012 g=4013 pq=1 pqc=4012 qp=1 rpfq=3 rp=ed8 dt=5847/1 dn=2 df=3797 of=0 ri=1266 ql=10 b=10
  5 c=17829 g=17830 pq=1 pqc=17829 qp=1 dt=3887/1 dn=0 df=3331 of=0 ri=4 ql=2 b=10
  7 c=4012 g=4013 pq=1 pqc=4012 qp=1 rpfq=3 rp=1fa2 dt=6199/1 dn=2 df=2795 of=0 ri=2162 ql=28 b=10
  6 c=17829 g=17829 pq=1 pqc=17829 qp=0 dt=859/1 dn=0 df=3224 of=0 ri=0 ql=0 b=10
  7 c=17829 g=17830 pq=0 pqc=17829 qp=1 dt=3761/1 dn=0 df=1818 of=0 ri=0 ql=2 b=10
rcu_bh:
rcu_bh:
  0 c=-268 g=-268 pq=1 pqc=-268 qp=0 rpfq=-145 rp=21d6 dt=23301/73 dn=2 df=0 of=0 ri=0 ql=0 b=10
  0 c=-275 g=-275 pq=1 pqc=-275 qp=0 dt=10951/1 dn=0 df=0 of=0 ri=0 ql=0 b=10
  1 c=-268 g=-268 pq=1 pqc=-268 qp=1 rpfq=-170 rp=20ce dt=78073/1 dn=2 df=26 of=0 ri=5 ql=0 b=10
  1 c=-275 g=-275 pq=1 pqc=-275 qp=0 dt=16117/1 dn=0 df=13 of=0 ri=0 ql=0 b=10
  2 c=-268 g=-268 pq=1 pqc=-268 qp=1 rpfq=-83 rp=fbd dt=16646/0 dn=2 df=28 of=0 ri=4 ql=0 b=10
  2 c=-275 g=-275 pq=1 pqc=-275 qp=0 dt=1445/1 dn=0 df=15 of=0 ri=0 ql=0 b=10
  3 c=-268 g=-268 pq=1 pqc=-268 qp=0 rpfq=-105 rp=178c dt=21159/1 dn=2 df=28 of=0 ri=2 ql=0 b=10
  3 c=-275 g=-275 pq=1 pqc=-275 qp=0 dt=6681/1 dn=0 df=9 of=0 ri=0 ql=0 b=10
  4 c=-268 g=-268 pq=1 pqc=-268 qp=1 rpfq=-30 rp=b54 dt=5783/1 dn=2 df=32 of=0 ri=0 ql=0 b=10
  4 c=-275 g=-275 pq=1 pqc=-275 qp=0 dt=1003/1 dn=0 df=15 of=0 ri=0 ql=0 b=10
  5 c=-268 g=-268 pq=1 pqc=-268 qp=1 rpfq=-29 rp=df5 dt=5879/1 dn=2 df=30 of=0 ri=3 ql=0 b=10
  5 c=-275 g=-275 pq=1 pqc=-275 qp=0 dt=3887/1 dn=0 df=15 of=0 ri=0 ql=0 b=10
  6 c=-268 g=-268 pq=1 pqc=-268 qp=1 rpfq=-28 rp=788 dt=5847/1 dn=2 df=32 of=0 ri=0 ql=0 b=10
  6 c=-275 g=-275 pq=1 pqc=-275 qp=0 dt=859/1 dn=0 df=15 of=0 ri=0 ql=0 b=10
  7 c=-268 g=-268 pq=1 pqc=-268 qp=1 rpfq=-53 rp=1098 dt=6199/1 dn=2 df=30 of=0 ri=3 ql=0 b=10
  7 c=-275 g=-275 pq=1 pqc=-275 qp=0 dt=3761/1 dn=0 df=15 of=0 ri=0 ql=0 b=10


The first section lists the rcu_data structures for rcu, the second for
The first section lists the rcu_data structures for rcu, the second for
rcu_bh.  Each section has one line per CPU, or eight for this 8-CPU system.
rcu_bh.  Each section has one line per CPU, or eight for this 8-CPU system.
@@ -253,12 +254,6 @@ o "pqc" indicates which grace period the last-observed quiescent
o	"qp" indicates that RCU still expects a quiescent state from
o	"qp" indicates that RCU still expects a quiescent state from
	this CPU.
	this CPU.


o	"rpfq" is the number of rcu_pending() calls on this CPU required
	to induce this CPU to invoke force_quiescent_state().

o	"rp" is low-order four hex digits of the count of how many times
	rcu_pending() has been invoked on this CPU.

o	"dt" is the current value of the dyntick counter that is incremented
o	"dt" is the current value of the dyntick counter that is incremented
	when entering or leaving dynticks idle state, either by the
	when entering or leaving dynticks idle state, either by the
	scheduler or by irq.  The number after the "/" is the interrupt
	scheduler or by irq.  The number after the "/" is the interrupt
@@ -305,6 +300,9 @@ o "b" is the batch limit for this CPU. If more than this number
	of RCU callbacks is ready to invoke, then the remainder will
	of RCU callbacks is ready to invoke, then the remainder will
	be deferred.
	be deferred.


There is also an rcu/rcudata.csv file with the same information in
comma-separated-variable spreadsheet format.



The output of "cat rcu/rcugp" looks as follows:
The output of "cat rcu/rcugp" looks as follows:


@@ -411,3 +409,63 @@ o Each element of the form "1/1 0:127 ^0" represents one struct
		For example, the first entry at the lowest level shows
		For example, the first entry at the lowest level shows
		"^0", indicating that it corresponds to bit zero in
		"^0", indicating that it corresponds to bit zero in
		the first entry at the middle level.
		the first entry at the middle level.


The output of "cat rcu/rcu_pending" looks as follows:

rcu:
  0 np=255892 qsp=53936 cbr=0 cng=14417 gpc=10033 gps=24320 nf=6445 nn=146741
  1 np=261224 qsp=54638 cbr=0 cng=25723 gpc=16310 gps=2849 nf=5912 nn=155792
  2 np=237496 qsp=49664 cbr=0 cng=2762 gpc=45478 gps=1762 nf=1201 nn=136629
  3 np=236249 qsp=48766 cbr=0 cng=286 gpc=48049 gps=1218 nf=207 nn=137723
  4 np=221310 qsp=46850 cbr=0 cng=26 gpc=43161 gps=4634 nf=3529 nn=123110
  5 np=237332 qsp=48449 cbr=0 cng=54 gpc=47920 gps=3252 nf=201 nn=137456
  6 np=219995 qsp=46718 cbr=0 cng=50 gpc=42098 gps=6093 nf=4202 nn=120834
  7 np=249893 qsp=49390 cbr=0 cng=72 gpc=38400 gps=17102 nf=41 nn=144888
rcu_bh:
  0 np=146741 qsp=1419 cbr=0 cng=6 gpc=0 gps=0 nf=2 nn=145314
  1 np=155792 qsp=12597 cbr=0 cng=0 gpc=4 gps=8 nf=3 nn=143180
  2 np=136629 qsp=18680 cbr=0 cng=0 gpc=7 gps=6 nf=0 nn=117936
  3 np=137723 qsp=2843 cbr=0 cng=0 gpc=10 gps=7 nf=0 nn=134863
  4 np=123110 qsp=12433 cbr=0 cng=0 gpc=4 gps=2 nf=0 nn=110671
  5 np=137456 qsp=4210 cbr=0 cng=0 gpc=6 gps=5 nf=0 nn=133235
  6 np=120834 qsp=9902 cbr=0 cng=0 gpc=6 gps=3 nf=2 nn=110921
  7 np=144888 qsp=26336 cbr=0 cng=0 gpc=8 gps=2 nf=0 nn=118542

As always, this is once again split into "rcu" and "rcu_bh" portions.
The fields are as follows:

o	"np" is the number of times that __rcu_pending() has been invoked
	for the corresponding flavor of RCU.

o	"qsp" is the number of times that the RCU was waiting for a
	quiescent state from this CPU.

o	"cbr" is the number of times that this CPU had RCU callbacks
	that had passed through a grace period, and were thus ready
	to be invoked.

o	"cng" is the number of times that this CPU needed another
	grace period while RCU was idle.

o	"gpc" is the number of times that an old grace period had
	completed, but this CPU was not yet aware of it.

o	"gps" is the number of times that a new grace period had started,
	but this CPU was not yet aware of it.

o	"nf" is the number of times that this CPU suspected that the
	current grace period had run for too long, and thus needed to
	be forced.

	Please note that "forcing" consists of sending resched IPIs
	to holdout CPUs.  If that CPU really still is in an old RCU
	read-side critical section, then we really do have to wait for it.
	The assumption behing "forcing" is that the CPU is not still in
	an old RCU read-side critical section, but has not yet responded
	for some other reason.

o	"nn" is the number of times that this CPU needed nothing.  Alert
	readers will note that the rcu "nn" number for a given CPU very
	closely matches the rcu_bh "np" number for that same CPU.  This
	is due to short-circuit evaluation in rcu_pending().
Loading