Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

Documentation/ABI: update infiniband sysfs interfaces

Add documentation for core and hardware specific infiniband interfaces.
The descriptions have been collected from git commit logs, reading
through code and data sheets. Some drivers have incomplete doc and are
annotated with the comment '[to be documented]'.

Signed-off-by: Aishwarya Pant <aishpant@gmail.com>
Reviewed-by: Hal Rosenstock <hal@mellanox.com>
Signed-off-by: Jonathan Corbet <corbet@lwn.net>

authored by

Aishwarya Pant and committed by
Jonathan Corbet
3bd640b7 017ac5ca

+820 -143
+818
Documentation/ABI/stable/sysfs-class-infiniband
··· 1 + sysfs interface common for all infiniband devices 2 + ------------------------------------------------- 3 + 4 + What: /sys/class/infiniband/<device>/node_type 5 + What: /sys/class/infiniband/<device>/node_guid 6 + What: /sys/class/infiniband/<device>/sys_image_guid 7 + Date: Apr, 2005 8 + KernelVersion: v2.6.12 9 + Contact: linux-rdma@vger.kernel.org 10 + Description: 11 + node_type: (RO) Node type (CA, RNIC, usNIC, usNIC UDP, 12 + switch or router) 13 + 14 + node_guid: (RO) Node GUID 15 + 16 + sys_image_guid: (RO) System image GUID 17 + 18 + 19 + What: /sys/class/infiniband/<device>/node_desc 20 + Date: Feb, 2006 21 + KernelVersion: v2.6.17 22 + Contact: linux-rdma@vger.kernel.org 23 + Description: 24 + (RW) Update the node description with information such as the 25 + node's hostname, so that IB network management software can tie 26 + its view to the real world. 27 + 28 + 29 + What: /sys/class/infiniband/<device>/fw_ver 30 + Date: Jun, 2016 31 + KernelVersion: v4.10 32 + Contact: linux-rdma@vger.kernel.org 33 + Description: 34 + (RO) Display firmware version 35 + 36 + 37 + What: /sys/class/infiniband/<device>/ports/<port-num>/lid 38 + What: /sys/class/infiniband/<device>/ports/<port-num>/rate 39 + What: /sys/class/infiniband/<device>/ports/<port-num>/lid_mask_count 40 + What: /sys/class/infiniband/<device>/ports/<port-num>/sm_sl 41 + What: /sys/class/infiniband/<device>/ports/<port-num>/sm_lid 42 + What: /sys/class/infiniband/<device>/ports/<port-num>/state 43 + What: /sys/class/infiniband/<device>/ports/<port-num>/phys_state 44 + What: /sys/class/infiniband/<device>/ports/<port-num>/cap_mask 45 + Date: Apr, 2005 46 + KernelVersion: v2.6.12 47 + Contact: linux-rdma@vger.kernel.org 48 + Description: 49 + 50 + lid: (RO) Port LID 51 + 52 + rate: (RO) Port data rate (active width * active 53 + speed) 54 + 55 + lid_mask_count: (RO) Port LID mask count 56 + 57 + sm_sl: (RO) Subnet manager SL for port's subnet 58 + 59 + sm_lid: (RO) Subnet manager LID for port's subnet 60 + 61 + state: (RO) Port state (DOWN, INIT, ARMED, ACTIVE or 62 + ACTIVE_DEFER) 63 + 64 + phys_state: (RO) Port physical state (Sleep, Polling, 65 + LinkUp, etc) 66 + 67 + cap_mask: (RO) Port capability mask. 2 bits here are 68 + settable- IsCommunicationManagementSupported 69 + (set when CM module is loaded) and IsSM (set via 70 + open of issmN file). 71 + 72 + 73 + What: /sys/class/infiniband/<device>/ports/<port-num>/link_layer 74 + Date: Oct, 2010 75 + KernelVersion: v2.6.37 76 + Contact: linux-rdma@vger.kernel.org 77 + Description: 78 + (RO) Link layer type information (Infiniband or Ethernet type) 79 + 80 + 81 + What: /sys/class/infiniband/<device>/ports/<port-num>/counters/symbol_error 82 + What: /sys/class/infiniband/<device>/ports/<port-num>/counters/port_rcv_errors 83 + What: /sys/class/infiniband/<device>/ports/<port-num>/counters/port_rcv_remote_physical_errors 84 + What: /sys/class/infiniband/<device>/ports/<port-num>/counters/port_rcv_switch_relay_errors 85 + What: /sys/class/infiniband/<device>/ports/<port-num>/counters/link_error_recovery 86 + What: /sys/class/infiniband/<device>/ports/<port-num>/counters/port_xmit_constraint_errors 87 + What: /sys/class/infiniband/<device>/ports/<port-num>/counters/port_rcv_contraint_errors 88 + What: /sys/class/infiniband/<device>/ports/<port-num>/counters/local_link_integrity_errors 89 + What: /sys/class/infiniband/<device>/ports/<port-num>/counters/excessive_buffer_overrun_errors 90 + What: /sys/class/infiniband/<device>/ports/<port-num>/counters/port_xmit_data 91 + What: /sys/class/infiniband/<device>/ports/<port-num>/counters/port_rcv_data 92 + What: /sys/class/infiniband/<device>/ports/<port-num>/counters/port_xmit_packets 93 + What: /sys/class/infiniband/<device>/ports/<port-num>/counters/port_rcv_packets 94 + What: /sys/class/infiniband/<device>/ports/<port-num>/counters/unicast_rcv_packets 95 + What: /sys/class/infiniband/<device>/ports/<port-num>/counters/unicast_xmit_packets 96 + What: /sys/class/infiniband/<device>/ports/<port-num>/counters/multicast_rcv_packets 97 + What: /sys/class/infiniband/<device>/ports/<port-num>/counters/multicast_xmit_packets 98 + What: /sys/class/infiniband/<device>/ports/<port-num>/counters/link_downed 99 + What: /sys/class/infiniband/<device>/ports/<port-num>/counters/port_xmit_discards 100 + What: /sys/class/infiniband/<device>/ports/<port-num>/counters/VL15_dropped 101 + What: /sys/class/infiniband/<device>/ports/<port-num>/counters/port_xmit_wait 102 + Date: Apr, 2005 103 + KernelVersion: v2.6.12 104 + Contact: linux-rdma@vger.kernel.org 105 + Description: 106 + Errors info: 107 + ----------- 108 + 109 + symbol_error: (RO) Total number of minor link errors detected on 110 + one or more physical lanes. 111 + 112 + port_rcv_errors : (RO) Total number of packets containing an 113 + error that were received on the port. 114 + 115 + port_rcv_remote_physical_errors : (RO) Total number of packets 116 + marked with the EBP delimiter received on the port. 117 + 118 + port_rcv_switch_relay_errors : (RO) Total number of packets 119 + received on the port that were discarded because they could not 120 + be forwarded by the switch relay. 121 + 122 + link_error_recovery: (RO) Total number of times the Port 123 + Training state machine has successfully completed the link error 124 + recovery process. 125 + 126 + port_xmit_constraint_errors: (RO) Total number of packets not 127 + transmitted from the switch physical port due to outbound raw 128 + filtering or failing outbound partition or IP version check. 129 + 130 + port_rcv_constraint_errors: (RO) Total number of packets 131 + received on the switch physical port that are discarded due to 132 + inbound raw filtering or failing inbound partition or IP version 133 + check. 134 + 135 + local_link_integrity_errors: (RO) The number of times that the 136 + count of local physical errors exceeded the threshold specified 137 + by LocalPhyErrors 138 + 139 + excessive_buffer_overrun_errors: (RO) This counter, indicates an 140 + input buffer overrun. It indicates possible misconfiguration of 141 + a port, either by the Subnet Manager (SM) or by user 142 + intervention. It can also indicate hardware issues or extremely 143 + poor link signal integrity 144 + 145 + Data info: 146 + --------- 147 + 148 + port_xmit_data: (RO) Total number of data octets, divided by 4 149 + (lanes), transmitted on all VLs. This is 64 bit counter 150 + 151 + port_rcv_data: (RO) Total number of data octets, divided by 4 152 + (lanes), received on all VLs. This is 64 bit counter. 153 + 154 + port_xmit_packets: (RO) Total number of packets transmitted on 155 + all VLs from this port. This may include packets with errors. 156 + This is 64 bit counter. 157 + 158 + port_rcv_packets: (RO) Total number of packets (this may include 159 + packets containing Errors. This is 64 bit counter. 160 + 161 + link_downed: (RO) Total number of times the Port Training state 162 + machine has failed the link error recovery process and downed 163 + the link. 164 + 165 + unicast_rcv_packets: (RO) Total number of unicast packets, 166 + including unicast packets containing errors. 167 + 168 + unicast_xmit_packets: (RO) Total number of unicast packets 169 + transmitted on all VLs from the port. This may include unicast 170 + packets with errors. 171 + 172 + multicast_rcv_packets: (RO) Total number of multicast packets, 173 + including multicast packets containing errors. 174 + 175 + multicast_xmit_packets: (RO) Total number of multicast packets 176 + transmitted on all VLs from the port. This may include multicast 177 + packets with errors. 178 + 179 + Misc info: 180 + --------- 181 + 182 + port_xmit_discards: (RO) Total number of outbound packets 183 + discarded by the port because the port is down or congested. 184 + 185 + VL15_dropped: (RO) Number of incoming VL15 packets dropped due 186 + to resource limitations (e.g., lack of buffers) of the port. 187 + 188 + port_xmit_wait: (RO) The number of ticks during which the port 189 + had data to transmit but no data was sent during the entire tick 190 + (either because of insufficient credits or because of lack of 191 + arbitration). 192 + 193 + Each of these files contains the corresponding value from the 194 + port's Performance Management PortCounters attribute, as 195 + described in the InfiniBand Architecture Specification. 196 + 197 + 198 + What: /sys/class/infiniband/<device-name>/hw_counters/lifespan 199 + What: /sys/class/infiniband/<device-name>/ports/<port-num>/hw_counters/lifespan 200 + Date: May, 2016 201 + KernelVersion: 4.6 202 + Contact: linux-rdma@vger.kernel.org 203 + Description: 204 + The optional "hw_counters" subdirectory can be under either the 205 + parent device or the port subdirectories or both. If present, 206 + there are a list of counters provided by the hardware. They may 207 + match some of the counters in the counters directory, but they 208 + often include many other counters. In addition to the various 209 + counters, there will be a file named "lifespan" that configures 210 + how frequently the core should update the counters when they are 211 + being accessed (counters are not updated if they are not being 212 + accessed). The lifespan is in milliseconds and defaults to 10 213 + unless set to something else by the driver. Users may echo a 214 + value between 0-10000 to the lifespan file to set the length 215 + of time between updates in milliseconds. 216 + 217 + 218 + What: /sys/class/infiniband/<hca>/ports/<port-number>/gid_attrs/ndevs/<gid-index> 219 + Date: November 29, 2015 220 + KernelVersion: 4.4.0 221 + Contact: linux-rdma@vger.kernel.org 222 + Description: The net-device's name associated with the GID resides 223 + at index <gid-index>. 224 + 225 + What: /sys/class/infiniband/<hca>/ports/<port-number>/gid_attrs/types/<gid-index> 226 + Date: November 29, 2015 227 + KernelVersion: 4.4.0 228 + Contact: linux-rdma@vger.kernel.org 229 + Description: The RoCE type of the associated GID resides at index <gid-index>. 230 + This could either be "IB/RoCE v1" for IB and RoCE v1 based GIDs 231 + or "RoCE v2" for RoCE v2 based GIDs. 232 + 233 + 234 + What: /sys/class/infiniband_mad/umadN/ibdev 235 + What: /sys/class/infiniband_mad/umadN/port 236 + What: /sys/class/infiniband_mad/issmN/ibdev 237 + What: /sys/class/infiniband_mad/issmN/port 238 + Date: Apr, 2005 239 + KernelVersion: v2.6.12 240 + Contact: linux-rdma@vger.kernel.org 241 + Description: 242 + Each port of each InfiniBand device has a "umad" device and an 243 + "issm" device attached. For example, a two-port HCA will have 244 + two umad devices and two issm devices, while a switch will have 245 + one device of each type (for switch port 0). 246 + 247 + ibdev: (RO) Show Infiniband (IB) device name 248 + 249 + port: (RO) Display port number 250 + 251 + 252 + What: /sys/class/infiniband_mad/abi_version 253 + Date: Apr, 2005 254 + KernelVersion: v2.6.12 255 + Contact: linux-rdma@vger.kernel.org 256 + Description: 257 + (RO) Value is incremented if any changes are made that break 258 + userspace ABI compatibility of umad & issm devices. 259 + 260 + 261 + What: /sys/class/infiniband_cm/ucmN/ibdev 262 + Date: Oct, 2005 263 + KernelVersion: v2.6.14 264 + Contact: linux-rdma@vger.kernel.org 265 + Description: 266 + (RO) Display Infiniband (IB) device name 267 + 268 + 269 + What: /sys/class/infiniband_cm/abi_version 270 + Date: Oct, 2005 271 + KernelVersion: v2.6.14 272 + Contact: linux-rdma@vger.kernel.org 273 + Description: 274 + (RO) Value is incremented if any changes are made that break 275 + userspace ABI compatibility of ucm devices. 276 + 277 + 278 + What: /sys/class/infiniband_verbs/uverbsN/ibdev 279 + What: /sys/class/infiniband_verbs/uverbsN/abi_version 280 + Date: Sept, 2005 281 + KernelVersion: v2.6.14 282 + Contact: linux-rdma@vger.kernel.org 283 + Description: 284 + ibdev: (RO) Display Infiniband (IB) device name 285 + 286 + abi_version: (RO) Show ABI version of IB device specific 287 + interfaces. 288 + 289 + 290 + What: /sys/class/infiniband_verbs/abi_version 291 + Date: Sep, 2005 292 + KernelVersion: v2.6.14 293 + Contact: linux-rdma@vger.kernel.org 294 + Description: 295 + (RO) Value is incremented if any changes are made that break 296 + userspace ABI compatibility of uverbs devices. 297 + 298 + 299 + sysfs interface for Mellanox IB HCA low-level driver (mthca) 300 + ------------------------------------------------------------ 301 + 302 + What: /sys/class/infiniband/mthcaX/hw_rev 303 + What: /sys/class/infiniband/mthcaX/hca_type 304 + What: /sys/class/infiniband/mthcaX/board_id 305 + Date: Apr, 2005 306 + KernelVersion: v2.6.12 307 + Contact: linux-rdma@vger.kernel.org 308 + Description: 309 + hw_rev: (RO) Hardware revision number 310 + 311 + hca_type: (RO) Host Channel Adapter type: MT23108, MT25208 312 + (MT23108 compat mode), MT25208 or MT25204 313 + 314 + board_id: (RO) Manufacturing board ID 315 + 316 + 317 + sysfs interface for Chelsio T3 RDMA Driver (cxgb3) 318 + -------------------------------------------------- 319 + 320 + What: /sys/class/infiniband/cxgb3_X/hw_rev 321 + What: /sys/class/infiniband/cxgb3_X/hca_type 322 + What: /sys/class/infiniband/cxgb3_X/board_id 323 + Date: Feb, 2007 324 + KernelVersion: v2.6.21 325 + Contact: linux-rdma@vger.kernel.org 326 + Description: 327 + hw_rev: (RO) Hardware revision number 328 + 329 + hca_type: (RO) HCA type. Here it is a driver short name. 330 + It should normally match the name in its bus 331 + driver structure (e.g. pci_driver::name). 332 + 333 + board_id: (RO) Manufacturing board id 334 + 335 + 336 + sysfs interface for Mellanox ConnectX HCA IB driver (mlx4) 337 + ---------------------------------------------------------- 338 + 339 + What: /sys/class/infiniband/mlx4_X/hw_rev 340 + What: /sys/class/infiniband/mlx4_X/hca_type 341 + What: /sys/class/infiniband/mlx4_X/board_id 342 + Date: Sep, 2007 343 + KernelVersion: v2.6.24 344 + Contact: linux-rdma@vger.kernel.org 345 + Description: 346 + hw_rev: (RO) Hardware revision number 347 + 348 + hca_type: (RO) Host channel adapter type 349 + 350 + board_id: (RO) Manufacturing board ID 351 + 352 + 353 + What: /sys/class/infiniband/mlx4_X/iov/ports/<port-num>/gids/<n> 354 + What: /sys/class/infiniband/mlx4_X/iov/ports/<port-num>/admin_guids/<n> 355 + What: /sys/class/infiniband/mlx4_X/iov/ports/<port-num>/pkeys/<n> 356 + What: /sys/class/infiniband/mlx4_X/iov/ports/<port-num>/mcgs/ 357 + What: /sys/class/infiniband/mlx4_X/iov/ports/<pci-slot-num>/ports/<m>/gid_idx/0 358 + What: /sys/class/infiniband/mlx4_X/iov/ports/<pci-slot-num>/ports/<m>/pkey_idx/<n> 359 + Date: Aug, 2012 360 + KernelVersion: v3.6.15 361 + Contact: linux-rdma@vger.kernel.org 362 + Description: 363 + The sysfs iov directory is used to manage and examine the port 364 + P_Key and guid paravirtualization. This directory is added only 365 + for the master -- slaves do not have it. 366 + 367 + Under iov/ports, the administrator may examine the gid and P_Key 368 + tables as they are present in the device (and as are seen in the 369 + "network view" presented to the SM). 370 + 371 + The "pkeys" and "gids" subdirectories contain one file for each 372 + entry in the port's P_Key or GID table respectively. For 373 + example, ports/1/pkeys/10 contains the value at index 10 in port 374 + 1's P_Key table. 375 + 376 + gids/<n>: (RO) The physical port gids n = 0..127 377 + 378 + admin_guids/<n>: (RW) Allows examining or changing the 379 + administrative state of a given GUID 380 + n = 0..127 381 + 382 + pkeys/<n>: (RO) Displays the contents of the physical 383 + key table n = 0..126 384 + 385 + mcgs/: (RO) Muticast group table 386 + 387 + <m>/gid_idx/0: (RO) Display the GID mapping m = 1..2 388 + 389 + <m>/pkey_idx/<n>: (RW) Writable except for RoCE pkeys. 390 + m = 1..2, n = 0..126 391 + 392 + Under the iov/<pci slot number> 393 + directories, the admin may map the index 394 + numbers in the physical tables (as under 395 + iov/ports) to the paravirtualized index 396 + numbers that guests see. 397 + 398 + For example, if the administrator, for 399 + port 1 on guest 2 maps physical pkey 400 + index 10 to virtual index 1, then that 401 + guest, whenever it uses its pkey index 402 + 1, will actually be using the real pkey 403 + index 10. 404 + 405 + 406 + What: /sys/class/infiniband/mlx4_X/iov/<pci-slot-num>/ports/<m>/smi_enabled 407 + What: /sys/class/infiniband/mlx4_X/iov/<pci-slot-num>/ports/<m>/enable_smi_admin 408 + Date: May, 2014 409 + KernelVersion: v3.15.7 410 + Contact: linux-rdma@vger.kernel.org 411 + Description: 412 + Enabling QP0 on VFs for selected VF/port. By default, no VFs are 413 + enabled for QP0 operation. 414 + 415 + smi_enabled: (RO) Indicates whether smi is currently enabled 416 + for the indicated VF/port 417 + 418 + enable_smi_admin:(RW) Used by the admin to request that smi 419 + capability be enabled or disabled for the 420 + indicated VF/port. 0 = disable, 1 = enable. 421 + 422 + The requested enablement will occur at the next reset of the VF 423 + (e.g. driver restart on the VM which owns the VF). 424 + 425 + 426 + sysfs interface for NetEffect RNIC Low-Level iWARP driver (nes) 427 + --------------------------------------------------------------- 428 + 429 + What: /sys/class/infiniband/nesX/hw_rev 430 + What: /sys/class/infiniband/nesX/hca_type 431 + What: /sys/class/infiniband/nesX/board_id 432 + Date: Feb, 2008 433 + KernelVersion: v2.6.25 434 + Contact: linux-rdma@vger.kernel.org 435 + Description: 436 + hw_rev: (RO) Hardware revision number 437 + 438 + hca_type: (RO) Host Channel Adapter type (NEX020) 439 + 440 + board_id: (RO) Manufacturing board id 441 + 442 + 443 + sysfs interface for Chelsio T4/T5 RDMA driver (cxgb4) 444 + ----------------------------------------------------- 445 + 446 + What: /sys/class/infiniband/cxgb4_X/hw_rev 447 + What: /sys/class/infiniband/cxgb4_X/hca_type 448 + What: /sys/class/infiniband/cxgb4_X/board_id 449 + Date: Apr, 2010 450 + KernelVersion: v2.6.35 451 + Contact: linux-rdma@vger.kernel.org 452 + Description: 453 + 454 + hw_rev: (RO) Hardware revision number 455 + 456 + hca_type: (RO) Driver short name. Should normally match 457 + the name in its bus driver structure (e.g. 458 + pci_driver::name) 459 + 460 + board_id: (RO) Manufacturing board id. (Vendor + device 461 + information) 462 + 463 + 464 + sysfs interface for Intel IB driver qib 465 + --------------------------------------- 466 + 467 + What: /sys/class/infiniband/qibX/version 468 + What: /sys/class/infiniband/qibX/hw_rev 469 + What: /sys/class/infiniband/qibX/hca_type 470 + What: /sys/class/infiniband/qibX/board_id 471 + What: /sys/class/infiniband/qibX/boardversion 472 + What: /sys/class/infiniband/qibX/nctxts 473 + What: /sys/class/infiniband/qibX/localbus_info 474 + What: /sys/class/infiniband/qibX/tempsense 475 + What: /sys/class/infiniband/qibX/serial 476 + What: /sys/class/infiniband/qibX/nfreectxts 477 + What: /sys/class/infiniband/qibX/chip_reset 478 + Date: May, 2010 479 + KernelVersion: v2.6.35 480 + Contact: linux-rdma@vger.kernel.org 481 + Description: 482 + version: (RO) Display version information of installed software 483 + and drivers. 484 + 485 + hw_rev: (RO) Hardware revision number 486 + 487 + hca_type: (RO) Host channel adapter type 488 + 489 + board_id: (RO) Manufacturing board id 490 + 491 + boardversion: (RO) Current version of the chip architecture 492 + 493 + nctxts: (RO) Return the number of user ports (contexts) 494 + available 495 + 496 + localbus_info: (RO) Human readable localbus info 497 + 498 + tempsense: (RO) Display temp sense registers in decimal 499 + 500 + serial: (RO) Serial number of the HCA 501 + 502 + nfreectxts: (RO) The number of free user ports (contexts) 503 + available. 504 + 505 + chip_reset: (WO) Reset the chip if possible by writing 506 + "reset" to this file. Only allowed if no user 507 + contexts are open that use chip resources. 508 + 509 + 510 + What: /sys/class/infiniband/qibX/ports/N/sl2vl/[0-15] 511 + Date: May, 2010 512 + KernelVersion: v2.6.35 513 + Contact: linux-rdma@vger.kernel.org 514 + Description: 515 + (RO) The directory contains 16 files numbered 0-15 that specify 516 + the Service Level (SL). Listing the SL files returns the Virtual 517 + Lane (VL) as programmed by the SL. 518 + 519 + What: /sys/class/infiniband/qibX/ports/N/CCMgtA/cc_settings_bin 520 + What: /sys/class/infiniband/qibX/ports/N/CCMgtA/cc_table_bin 521 + Date: May, 2010 522 + KernelVersion: v2.6.35 523 + Contact: linux-rdma@vger.kernel.org 524 + Description: 525 + Per-port congestion control. Both are binary attributes. 526 + 527 + cc_table_bin: (RO) Congestion control table size followed by 528 + table entries. 529 + 530 + cc_settings_bin:(RO) Congestion settings: port control, control 531 + map and an array of 16 entries for the 532 + congestion entries - increase, timer, event log 533 + trigger threshold and the minimum injection rate 534 + delay. 535 + 536 + What: /sys/class/infiniband/qibX/ports/N/linkstate/loopback 537 + What: /sys/class/infiniband/qibX/ports/N/linkstate/led_override 538 + What: /sys/class/infiniband/qibX/ports/N/linkstate/hrtbt_enable 539 + What: /sys/class/infiniband/qibX/ports/N/linkstate/status 540 + What: /sys/class/infiniband/qibX/ports/N/linkstate/status_str 541 + Date: May, 2010 542 + KernelVersion: v2.6.35 543 + Contact: linux-rdma@vger.kernel.org 544 + Description: 545 + [to be documented] 546 + 547 + loopback: (WO) 548 + led_override: (WO) 549 + hrtbt_enable: (RW) 550 + status: (RO) 551 + 552 + status_str: (RO) Displays information about the link state, 553 + possible cable/switch problems, and hardware 554 + errors. Possible states are- "Initted", 555 + "Present", "IB_link_up", "IB_configured" or 556 + "Fatal_Hardware_Error". 557 + 558 + What: /sys/class/infiniband/qibX/ports/N/diag_counters/rc_resends 559 + What: /sys/class/infiniband/qibX/ports/N/diag_counters/seq_naks 560 + What: /sys/class/infiniband/qibX/ports/N/diag_counters/rdma_seq 561 + What: /sys/class/infiniband/qibX/ports/N/diag_counters/rnr_naks 562 + What: /sys/class/infiniband/qibX/ports/N/diag_counters/other_naks 563 + What: /sys/class/infiniband/qibX/ports/N/diag_counters/rc_timeouts 564 + What: /sys/class/infiniband/qibX/ports/N/diag_counters/look_pkts 565 + What: /sys/class/infiniband/qibX/ports/N/diag_counters/pkt_drops 566 + What: /sys/class/infiniband/qibX/ports/N/diag_counters/dma_wait 567 + What: /sys/class/infiniband/qibX/ports/N/diag_counters/unaligned 568 + Date: May, 2010 569 + KernelVersion: v2.6.35 570 + Contact: linux-rdma@vger.kernel.org 571 + Description: 572 + [to be documented] 573 + 574 + 575 + sysfs interface for Mellanox Connect-IB HCA driver mlx5 576 + ------------------------------------------------------- 577 + 578 + What: /sys/class/infiniband/mlx5_X/hw_rev 579 + What: /sys/class/infiniband/mlx5_X/hca_type 580 + What: /sys/class/infiniband/mlx5_X/reg_pages 581 + What: /sys/class/infiniband/mlx5_X/fw_pages 582 + Date: Jul, 2013 583 + KernelVersion: v3.11 584 + Contact: linux-rdma@vger.kernel.org 585 + Description: 586 + [to be documented] 587 + 588 + 589 + sysfs interface for Cisco VIC (usNIC) Verbs Driver 590 + -------------------------------------------------- 591 + 592 + What: /sys/class/infiniband/usnic_X/board_id 593 + What: /sys/class/infiniband/usnic_X/config 594 + What: /sys/class/infiniband/usnic_X/qp_per_vf 595 + What: /sys/class/infiniband/usnic_X/max_vf 596 + What: /sys/class/infiniband/usnic_X/cq_per_vf 597 + What: /sys/class/infiniband/usnic_X/iface 598 + Date: Sep, 2013 599 + KernelVersion: v3.14 600 + Contact: Christian Benvenuti <benve@cisco.com>, 601 + Dave Goodell <dgoodell@cisco.com>, 602 + linux-rdma@vger.kernel.org 603 + Description: 604 + 605 + board_id: (RO) Manufacturing board id 606 + 607 + config: (RO) Report the configuration for this PF 608 + 609 + qp_per_vf: (RO) Queue pairs per virtual function. 610 + 611 + max_vf: (RO) Max virtual functions 612 + 613 + cq_per_vf: (RO) Completion queue per virtual function 614 + 615 + iface: (RO) Shows which network interface this usNIC 616 + entry is associated to (visible with ifconfig). 617 + 618 + What: /sys/class/infiniband/usnic_X/qpn/summary 619 + What: /sys/class/infiniband/usnic_X/qpn/context 620 + Date: Sep, 2013 621 + KernelVersion: v3.14 622 + Contact: Christian Benvenuti <benve@cisco.com>, 623 + Dave Goodell <dgoodell@cisco.com>, 624 + linux-rdma@vger.kernel.org 625 + Description: 626 + [to be documented] 627 + 628 + 629 + sysfs interface for Emulex RoCE HCA Driver 630 + ------------------------------------------ 631 + 632 + What: /sys/class/infiniband/ocrdmaX/hw_rev 633 + Date: Feb, 2014 634 + KernelVersion: v3.14 635 + Description: 636 + hw_rev: (RO) Hardware revision number 637 + 638 + What: /sys/class/infiniband/ocrdmaX/hca_type 639 + Date: Jun, 2014 640 + KernelVersion: v3.16 641 + Contact: linux-rdma@vger.kernel.org 642 + Description: 643 + hca_type: (RO) Display FW version 644 + 645 + 646 + sysfs interface for Intel Omni-Path driver (HFI1) 647 + ------------------------------------------------- 648 + 649 + What: /sys/class/infiniband/hfi1_X/hw_rev 650 + What: /sys/class/infiniband/hfi1_X/board_id 651 + What: /sys/class/infiniband/hfi1_X/nctxts 652 + What: /sys/class/infiniband/hfi1_X/serial 653 + What: /sys/class/infiniband/hfi1_X/chip_reset 654 + What: /sys/class/infiniband/hfi1_X/boardversion 655 + What: /sys/class/infiniband/hfi1_X/nfreectxts 656 + What: /sys/class/infiniband/hfi1_X/tempsense 657 + Date: May, 2016 658 + KernelVersion: v4.6 659 + Contact: linux-rdma@vger.kernel.org 660 + Description: 661 + hw_rev: (RO) Hardware revision number 662 + 663 + board_id: (RO) Manufacturing board id 664 + 665 + nctxts: (RO) Total contexts available. 666 + 667 + serial: (RO) Board serial number 668 + 669 + chip_reset: (WO) Write "reset" to this file to reset the 670 + chip if possible. Only allowed if no user 671 + contexts are open that use chip resources. 672 + 673 + boardversion: (RO) Human readable board info 674 + 675 + nfreectxts: (RO) The number of free user ports (contexts) 676 + available. 677 + 678 + tempsense: (RO) Thermal sense information 679 + 680 + 681 + What: /sys/class/infiniband/hfi1_X/ports/N/CCMgtA/cc_settings_bin 682 + What: /sys/class/infiniband/hfi1_X/ports/N/CCMgtA/cc_table_bin 683 + What: /sys/class/infiniband/hfi1_X/ports/N/CCMgtA/cc_prescan 684 + Date: May, 2016 685 + KernelVersion: v4.6 686 + Contact: linux-rdma@vger.kernel.org 687 + Description: 688 + Per-port congestion control. 689 + 690 + cc_table_bin: (RO) CCA tables used by PSM2 Congestion control 691 + table size followed by table entries. Binary 692 + attribute. 693 + 694 + cc_settings_bin:(RO) Congestion settings: port control, control 695 + map and an array of 16 entries for the 696 + congestion entries - increase, timer, event log 697 + trigger threshold and the minimum injection rate 698 + delay. Binary attribute. 699 + 700 + cc_prescan: (RW) enable prescanning for faster BECN 701 + response. Write "on" to enable and "off" to 702 + disable. 703 + 704 + What: /sys/class/infiniband/hfi1_X/ports/N/sc2vl/[0-31] 705 + What: /sys/class/infiniband/hfi1_X/ports/N/sl2sc/[0-31] 706 + What: /sys/class/infiniband/hfi1_X/ports/N/vl2mtu/[0-15] 707 + Date: May, 2016 708 + KernelVersion: v4.6 709 + Contact: linux-rdma@vger.kernel.org 710 + Description: 711 + sc2vl/: (RO) 32 files (0 - 31) used to translate sl->vl 712 + 713 + sl2sc/: (RO) 32 files (0 - 31) used to translate sl->sc 714 + 715 + vl2mtu/: (RO) 16 files (0 - 15) used to determine MTU for vl 716 + 717 + 718 + What: /sys/class/infiniband/hfi1_X/sdma_N/cpu_list 719 + What: /sys/class/infiniband/hfi1_X/sdma_N/vl 720 + Date: Sept, 2016 721 + KernelVersion: v4.8 722 + Contact: linux-rdma@vger.kernel.org 723 + Description: 724 + sdma<N>/ contains one directory per sdma engine (0 - 15) 725 + 726 + cpu_list: (RW) List of cpus for user-process to sdma 727 + engine assignment. 728 + 729 + vl: (RO) Displays the virtual lane (vl) the sdma 730 + engine maps to. 731 + 732 + This interface gives the user control on the affinity settings 733 + for the device. As an example, to set an sdma engine irq 734 + affinity and thread affinity of a user processes to use the 735 + sdma engine, which is "near" in terms of NUMA configuration, or 736 + physical cpu location, the user will do: 737 + 738 + echo "3" > /proc/irq/<N>/smp_affinity_list 739 + echo "4-7" > /sys/devices/.../sdma3/cpu_list 740 + cat /sys/devices/.../sdma3/vl 741 + 0 742 + echo "8" > /proc/irq/<M>/smp_affinity_list 743 + echo "9-12" > /sys/devices/.../sdma4/cpu_list 744 + cat /sys/devices/.../sdma4/vl 745 + 1 746 + 747 + to make sure that when a process runs on cpus 4,5,6, or 7, and 748 + uses vl=0, then sdma engine 3 is selected by the driver, and 749 + also the interrupt of the sdma engine 3 is steered to cpu 3. 750 + Similarly, when a process runs on cpus 9,10,11, or 12 and sets 751 + vl=1, then engine 4 will be selected and the irq of the sdma 752 + engine 4 is steered to cpu 8. This assumes that in the above N 753 + is the irq number of "sdma3", and M is irq number of "sdma4" in 754 + the /proc/interrupts file. 755 + 756 + 757 + sysfs interface for Intel(R) X722 iWARP i40iw driver 758 + ---------------------------------------------------- 759 + 760 + What: /sys/class/infiniband/i40iwX/hw_rev 761 + What: /sys/class/infiniband/i40iwX/hca_type 762 + What: /sys/class/infiniband/i40iwX/board_id 763 + Date: Jan, 2016 764 + KernelVersion: v4.10 765 + Contact: linux-rdma@vger.kernel.org 766 + Description: 767 + hw_rev: (RO) Hardware revision number 768 + 769 + hca_type: (RO) Show HCA type (I40IW) 770 + 771 + board_id: (RO) I40IW board ID 772 + 773 + 774 + sysfs interface for QLogic qedr NIC Driver 775 + ------------------------------------------ 776 + 777 + What: /sys/class/infiniband/qedrX/hw_rev 778 + What: /sys/class/infiniband/qedrX/hca_type 779 + Date: Oct, 2016 780 + KernelVersion: v4.10 781 + Contact: linux-rdma@vger.kernel.org 782 + Description: 783 + 784 + hw_rev: (RO) Hardware revision number 785 + 786 + hca_type: (RO) Display HCA type 787 + 788 + 789 + sysfs interface for VMware Paravirtual RDMA driver 790 + -------------------------------------------------- 791 + 792 + What: /sys/class/infiniband/vmw_pvrdmaX/hw_rev 793 + What: /sys/class/infiniband/vmw_pvrdmaX/hca_type 794 + What: /sys/class/infiniband/vmw_pvrdmaX/board_id 795 + Date: Oct, 2016 796 + KernelVersion: v4.10 797 + Contact: linux-rdma@vger.kernel.org 798 + Description: 799 + 800 + hw_rev: (RO) Hardware revision number 801 + 802 + hca_type: (RO) Host channel adapter type 803 + 804 + board_id: (RO) Display PVRDMA manufacturing board ID 805 + 806 + 807 + sysfs interface for Broadcom NetXtreme-E RoCE driver 808 + ---------------------------------------------------- 809 + 810 + What: /sys/class/infiniband/bnxt_reX/hw_rev 811 + What: /sys/class/infiniband/bnxt_reX/hca_type 812 + Date: Feb, 2017 813 + KernelVersion: v4.11 814 + Contact: linux-rdma@vger.kernel.org 815 + Description: 816 + hw_rev: (RO) Hardware revision number 817 + 818 + hca_type: (RO) Host channel adapter type
-16
Documentation/ABI/testing/sysfs-class-infiniband
··· 1 - What: /sys/class/infiniband/<hca>/ports/<port-number>/gid_attrs/ndevs/<gid-index> 2 - Date: November 29, 2015 3 - KernelVersion: 4.4.0 4 - Contact: linux-rdma@vger.kernel.org 5 - Description: The net-device's name associated with the GID resides 6 - at index <gid-index>. 7 - 8 - What: /sys/class/infiniband/<hca>/ports/<port-number>/gid_attrs/types/<gid-index> 9 - Date: November 29, 2015 10 - KernelVersion: 4.4.0 11 - Contact: linux-rdma@vger.kernel.org 12 - Description: The RoCE type of the associated GID resides at index <gid-index>. 13 - This could either be "IB/RoCE v1" for IB and RoCE v1 based GODs 14 - or "RoCE v2" for RoCE v2 based GIDs. 15 - 16 -
+2 -127
Documentation/infiniband/sysfs.txt
··· 1 1 SYSFS FILES 2 2 3 - For each InfiniBand device, the InfiniBand drivers create the 4 - following files under /sys/class/infiniband/<device name>: 5 - 6 - node_type - Node type (CA, switch or router) 7 - node_guid - Node GUID 8 - sys_image_guid - System image GUID 9 - 10 - In addition, there is a "ports" subdirectory, with one subdirectory 11 - for each port. For example, if mthca0 is a 2-port HCA, there will 12 - be two directories: 13 - 14 - /sys/class/infiniband/mthca0/ports/1 15 - /sys/class/infiniband/mthca0/ports/2 16 - 17 - (A switch will only have a single "0" subdirectory for switch port 18 - 0; no subdirectory is created for normal switch ports) 19 - 20 - In each port subdirectory, the following files are created: 21 - 22 - cap_mask - Port capability mask 23 - lid - Port LID 24 - lid_mask_count - Port LID mask count 25 - rate - Port data rate (active width * active speed) 26 - sm_lid - Subnet manager LID for port's subnet 27 - sm_sl - Subnet manager SL for port's subnet 28 - state - Port state (DOWN, INIT, ARMED, ACTIVE or ACTIVE_DEFER) 29 - phys_state - Port physical state (Sleep, Polling, LinkUp, etc) 30 - 31 - There is also a "counters" subdirectory, with files 32 - 33 - VL15_dropped 34 - excessive_buffer_overrun_errors 35 - link_downed 36 - link_error_recovery 37 - local_link_integrity_errors 38 - port_rcv_constraint_errors 39 - port_rcv_data 40 - port_rcv_errors 41 - port_rcv_packets 42 - port_rcv_remote_physical_errors 43 - port_rcv_switch_relay_errors 44 - port_xmit_constraint_errors 45 - port_xmit_data 46 - port_xmit_discards 47 - port_xmit_packets 48 - symbol_error 49 - 50 - Each of these files contains the corresponding value from the port's 51 - Performance Management PortCounters attribute, as described in 52 - section 16.1.3.5 of the InfiniBand Architecture Specification. 53 - 54 - The "pkeys" and "gids" subdirectories contain one file for each 55 - entry in the port's P_Key or GID table respectively. For example, 56 - ports/1/pkeys/10 contains the value at index 10 in port 1's P_Key 57 - table. 58 - 59 - There is an optional "hw_counters" subdirectory that may be under either 60 - the parent device or the port subdirectories or both. If present, 61 - there are a list of counters provided by the hardware. They may match 62 - some of the counters in the counters directory, but they often include 63 - many other counters. In addition to the various counters, there will 64 - be a file named "lifespan" that configures how frequently the core 65 - should update the counters when they are being accessed (counters are 66 - not updated if they are not being accessed). The lifespan is in milli- 67 - seconds and defaults to 10 unless set to something else by the driver. 68 - Users may echo a value between 0 - 10000 to the lifespan file to set 69 - the length of time between updates in milliseconds. 70 - 71 - MTHCA 72 - 73 - The Mellanox HCA driver also creates the files: 74 - 75 - hw_rev - Hardware revision number 76 - fw_ver - Firmware version 77 - hca_type - HCA type: "MT23108", "MT25208 (MT23108 compat mode)", 78 - or "MT25208" 79 - 80 - HFI1 81 - 82 - The hfi1 driver also creates these additional files: 83 - 84 - hw_rev - hardware revision 85 - board_id - manufacturing board id 86 - tempsense - thermal sense information 87 - serial - board serial number 88 - nfreectxts - number of free user contexts 89 - nctxts - number of allowed contexts (PSM2) 90 - chip_reset - diagnostic (root only) 91 - boardversion - board version 92 - 93 - sdma<N>/ - one directory per sdma engine (0 - 15) 94 - sdma<N>/cpu_list - read-write, list of cpus for user-process to sdma 95 - engine assignment. 96 - sdma<N>/vl - read-only, vl the sdma engine maps to. 97 - 98 - The new interface will give the user control on the affinity settings 99 - for the hfi1 device. 100 - As an example, to set an sdma engine irq affinity and thread affinity 101 - of a user processes to use the sdma engine, which is "near" in terms 102 - of NUMA configuration, or physical cpu location, the user will do: 103 - 104 - echo "3" > /proc/irq/<N>/smp_affinity_list 105 - echo "4-7" > /sys/devices/.../sdma3/cpu_list 106 - cat /sys/devices/.../sdma3/vl 107 - 0 108 - echo "8" > /proc/irq/<M>/smp_affinity_list 109 - echo "9-12" > /sys/devices/.../sdma4/cpu_list 110 - cat /sys/devices/.../sdma4/vl 111 - 1 112 - 113 - to make sure that when a process runs on cpus 4,5,6, or 7, 114 - and uses vl=0, then sdma engine 3 is selected by the driver, 115 - and also the interrupt of the sdma engine 3 is steered to cpu 3. 116 - Similarly, when a process runs on cpus 9,10,11, or 12 and sets vl=1, 117 - then engine 4 will be selected and the irq of the sdma engine 4 is 118 - steered to cpu 8. 119 - This assumes that in the above N is the irq number of "sdma3", 120 - and M is irq number of "sdma4" in the /proc/interrupts file. 121 - 122 - ports/1/ 123 - CCMgtA/ 124 - cc_settings_bin - CCA tables used by PSM2 125 - cc_table_bin 126 - cc_prescan - enable prescaning for faster BECN response 127 - sc2v/ - 32 files (0 - 31) used to translate sl->vl 128 - sl2sc/ - 32 files (0 - 31) used to translate sl->sc 129 - vl2mtu/ - 16 (0 - 15) files used to determine MTU for vl 3 + The sysfs interface has moved to 4 + Documentation/ABI/stable/sysfs-class-infiniband.