Skip to content

Commit a3966a6

Browse files
shawn1221Mani-Sadhasivam
authored andcommitted
Documentation: tracing: Add PCI controller event documentation
The PCI controller tracepoint, pcie_ltssm_state_transition, monitors the LTSSM state transition and data rate changes for debugging purposes. Add documentation for it. Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com> [mani: added MAINTAINERS entry] Signed-off-by: Manivannan Sadhasivam <mani@kernel.org> Reviewed-by: Steven Rostedt (Google) <rostedt@goodmis.org> Link: https://patch.msgid.link/1774403912-210670-3-git-send-email-shawn.lin@rock-chips.com
1 parent d1b7add commit a3966a6

3 files changed

Lines changed: 44 additions & 0 deletions

File tree

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
.. SPDX-License-Identifier: GPL-2.0
2+
3+
======================================
4+
Subsystem Trace Points: PCI Controller
5+
======================================
6+
7+
Overview
8+
========
9+
The PCI controller tracing system provides tracepoints to monitor controller
10+
level information for debugging purpose. The events normally show up here:
11+
12+
/sys/kernel/tracing/events/pci_controller
13+
14+
Cf. include/trace/events/pci_controller.h for the events definitions.
15+
16+
Available Tracepoints
17+
=====================
18+
19+
pcie_ltssm_state_transition
20+
---------------------------
21+
22+
Monitors PCIe LTSSM state transition including state and rate information
23+
::
24+
25+
pcie_ltssm_state_transition "dev: %s state: %s rate: %s\n"
26+
27+
**Parameters**:
28+
29+
* ``dev`` - PCIe controller instance
30+
* ``state`` - PCIe LTSSM state
31+
* ``rate`` - PCIe date rate
32+
33+
**Example Usage**:
34+
35+
.. code-block:: shell
36+
37+
# Enable the tracepoint
38+
echo 1 > /sys/kernel/debug/tracing/events/pci_controller/pcie_ltssm_state_transition/enable
39+
40+
# Monitor events (the following output is generated when a device is linking)
41+
cat /sys/kernel/debug/tracing/trace_pipe
42+
kworker/0:0-9 [000] ..... 5.600221: pcie_ltssm_state_transition: dev: a40000000.pcie state: RCVRY_EQ2 rate: 8.0 GT/s

Documentation/trace/index.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,7 @@ applications.
5555
events-nmi
5656
events-msr
5757
events-pci
58+
events-pci-controller
5859
boottime-trace
5960
histogram
6061
histogram-design

MAINTAINERS

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20396,6 +20396,7 @@ C: irc://irc.oftc.net/linux-pci
2039620396
T: git git://git.kernel.org/pub/scm/linux/kernel/git/pci/pci.git
2039720397
F: Documentation/ABI/testing/debugfs-pcie-ptm
2039820398
F: Documentation/devicetree/bindings/pci/
20399+
F: Documentation/trace/events-pci-controller.rst
2039920400
F: drivers/pci/controller/
2040020401
F: drivers/pci/pci-bridge-emul.c
2040120402
F: drivers/pci/pci-bridge-emul.h

0 commit comments

Comments
 (0)