summaryrefslogtreecommitdiffstats
path: root/Documentation/ntb.txt
diff options
context:
space:
mode:
authorAllen Hubbe <Allen.Hubbe@emc.com>2015-05-21 02:51:39 -0400
committerJon Mason <jdmason@kudzu.us>2015-07-04 14:08:17 -0400
commit578b881ba9c4b253482903bf8fae438318f5629b (patch)
treeecbe76c342d3bd0c1725fa141503393b4825cd3a /Documentation/ntb.txt
parent963de4739fb4f8fa8d5cd87969109a7d3282ed13 (diff)
NTB: Add tool test client
This is a simple debugging driver that enables the doorbell and scratch pad registers to be read and written from the debugfs. This tool enables more complicated debugging to be scripted from user space. This driver may be used to test that your ntb hardware and drivers are functioning at a basic level. Signed-off-by: Allen Hubbe <Allen.Hubbe@emc.com> Signed-off-by: Jon Mason <jdmason@kudzu.us>
Diffstat (limited to 'Documentation/ntb.txt')
-rw-r--r--Documentation/ntb.txt32
1 files changed, 32 insertions, 0 deletions
diff --git a/Documentation/ntb.txt b/Documentation/ntb.txt
index e5d1591478ca..b48249a7b607 100644
--- a/Documentation/ntb.txt
+++ b/Documentation/ntb.txt
@@ -64,6 +64,38 @@ Module Parameters:
64* dyndbg - It is suggested to specify dyndbg=+p when loading this module, and 64* dyndbg - It is suggested to specify dyndbg=+p when loading this module, and
65 then to observe debugging output on the console. 65 then to observe debugging output on the console.
66 66
67### NTB Tool Test Client (ntb\_tool)
68
69The Tool test client serves for debugging, primarily, ntb hardware and drivers.
70The Tool provides access through debugfs for reading, setting, and clearing the
71NTB doorbell, and reading and writing scratchpads.
72
73The Tool does not currently have any module parameters.
74
75Debugfs Files:
76
77* *debugfs*/ntb\_tool/*hw*/ - A directory in debugfs will be created for each
78 NTB device probed by the tool. This directory is shortened to *hw*
79 below.
80* *hw*/db - This file is used to read, set, and clear the local doorbell. Not
81 all operations may be supported by all hardware. To read the doorbell,
82 read the file. To set the doorbell, write `s` followed by the bits to
83 set (eg: `echo 's 0x0101' > db`). To clear the doorbell, write `c`
84 followed by the bits to clear.
85* *hw*/mask - This file is used to read, set, and clear the local doorbell mask.
86 See *db* for details.
87* *hw*/peer\_db - This file is used to read, set, and clear the peer doorbell.
88 See *db* for details.
89* *hw*/peer\_mask - This file is used to read, set, and clear the peer doorbell
90 mask. See *db* for details.
91* *hw*/spad - This file is used to read and write local scratchpads. To read
92 the values of all scratchpads, read the file. To write values, write a
93 series of pairs of scratchpad number and value
94 (eg: `echo '4 0x123 7 0xabc' > spad`
95 # to set scratchpads `4` and `7` to `0x123` and `0xabc`, respectively).
96* *hw*/peer\_spad - This file is used to read and write peer scratchpads. See
97 *spad* for details.
98
67## NTB Hardware Drivers 99## NTB Hardware Drivers
68 100
69NTB hardware drivers should register devices with the NTB core driver. After 101NTB hardware drivers should register devices with the NTB core driver. After