Mandatory Performance Attributes

General

Refer to Table 35-4 on page 1025 and Table 35-3 on page 1024. As indicated earlier in this chapter, the following attributes are mandatory and must be implemented on each port:

  • ClassPortInfo. See Table 28-7 on page 794 and the description of ClassPortInfo in Table 35-4 on page 1025.

  • PortCounters. This attribute contains a standard set of required event counters that are always running on each port.

  • PortSamplesControl. A PerfSet(PortSamplesControl) is used to simultaneously:

    - Select a port on which to take samples.

    - Select one or more optional operational events on the selected port to be sampled.

    - Trigger a sampling session of the selected optional events on the selected port.

    An initial execution of a PerfGet(PortSamplesControl) returns the number and width of the available counters, the events that can be sampled, and the sampling time interval (called the “tick”. Using this information, the performance application can compute the maximum sample interval that will not cause a counter overflow.

  • PortSamplesResult. Once a sampling session is triggered via the PerfSet(PortSamplesControl), a PerfGet(PortSamplesResult) returns the status of the sampling session (Sampling complete, SampleStart timer running, or Sampling underway). If the status indicates that the sampling session is complete, the PerfGet(PortSamplesResult) also returns the contents of the sample counters.

Initiating a Sampling Session

To initiate a sampling session, the application takes the following actions:

  1. Select a random value for PortSamplesControl.SampleStart that defines how soon after the PerfSet(PortSamplesControl) is executed the sampling session begins. The SampleStart timer allows a performance application to randomize the sample start time and ensure decoupling from node or network events. Values used will typically be tens of milliseconds.

  2. Select a random PortSamplesControl.Tag value that uniquely identifies this sampling session. This value is used to detect collisions when multiple independent performance applications start sampling sessions on the same port.

  3. Select a PortSamplesControl.SampleInterval value, the events to be sampled, and the counter assigned to count each event type.

  4. When the PerfSet(PortSamplesControl) is performed, if the value of Tag returned in the PerfGetResp(PortSamplesControl) does not match the selected Tag value, another application is using the sampling mechanism. In this case, the first application must wait awhile and retry the PerfSet(PortSamplesControl).

  5. Once the sample is successfully started, the application waits long enough for the SampleStart and SampleInterval timers to have expired and then repeats a PerfGet (PortSamplesResult) until SampleStatus = 0 (sampling session complete). If the returned Tag value no longer matches the application's chosen value (regardless of the SampleStatus), it means another application has gained control of the sampling mechanism. In this case, the first application must restart the sampling process (after the other application relinquishes control of it).

PortSamplesControl.SampleMechanisms indicates whether more than one set of sampling mechanisms is implemented (see the description of SampleMechanism in Table 35-5 on page 1027). If so, the additional mechanisms are addressed using non-zero AttributeModifier values.

Table 35-3. Method/Mandatory Attribute Implementation Map
Method ==>PerformanceGet()PerformanceSet()
Attribute
ClassPortInfoxx
PortSamplesControlxx
PortSamplesResultx 
PortCountersxx

Table 35-4. Mandatory PM Attributes
AttributeIDAttribute ModifierDescription
PortSamplesControl0010hSelects one of n independent sampling mechanisms, only one of which is required.Port Performance Data Sampling Control attribute. This attribute consists of a number of attribute elements detailed in Table 35-5 on page 1027.
PortSamplesResult0011hSelects one of n independent sampling mechanisms, all of which are optional.Port Performance Data Sampling Results attribute. This attribute consists of a number of attribute elements detailed in Table 35-7 on page 1040.
ClassPortInfo0001h00000000hSee Table 28-7 on page 794. The only class-specific CapabilityMask bit defined is Bit 8, the AllPortSelect bit:
  • If 1, indicates that all attributes containing the PortSelect element support setting it to FFh to gather data from all ports at once.

  • If 0, using FFh in PortSelect results in undefined behavior.

Note that the PortSamplesControl and PortCounters attributes contain the PortSelect attribute element (see the next two rows in this table).
PortCounters0012h00000000hPort Basic Performance and Error Counters attribute. This attribute consists of a number of attribute elements detailed in Table 35-8 on page 1043.
Reserved0013h

0014h
00000000h FFFFFFFFhReserved

PortSamplesControl Mandatory Attribute

Refer to Table 35-5 on page 1027. A PerfSet(PortSamplesControl) is used to simultaneously:

  • Select a port on which to take samples.

  • Select one or more optional operational events on the selected port to be sampled.

  • Trigger a sampling session of the selected optional events on the selected port.

An initial execution of a PerfGet(PortSamplesControl) returns the number and width of the available counters, the events that can be sampled, and the sampling time interval (called the “tick”). Using this information, the performance application can compute the maximum sample interval that will not cause a counter overflow.

The complete list of events that can be sampled using this mechanism is given in Table 35-6 on page 1035.

Sampling status and results are obtained by means of a PerfGet(PortSamplesResult).

PortSamplesControl.SampleMechanisms indicates the number of independent sample mechanisms implemented (i.e., sets of PortSamplesControl and PortSamplesResult), minus one:

  • 0 = 1 mechanism available, addressed by AttributeModifier = 00000000h.

  • 1 = 2 mechanisms available, addressed by AttributeModifiers 00000000h and 00000001h.

  • ...

  • 255 = 256 mechanisms available addressed by AttributeModifiers 00000000h-000000FFh.

Only one sample mechanism is required (the one addressed with an AddressModifier of 00000000h). N sample mechanisms permits N independent samples to be run simultaneously. Attribute Modifier FFFFFFFFh allows all sample mechanisms to be started with a single PerfSet(), sampling the same events during the same interval on N ports.

For each sampling mechanism, at least one and up to 15 counters must be implemented.

Table 35-5. PortSamplesControl Attribute Structure
ElementAccessLength (in bits)Description
OpcodeRW8Used to select a specific packet opcode (as found in BTH) when sampling optional events that are opcode-specific.
  • If Opcode is FFh, all opcodes are sampled.

  • Otherwise, only one opcode is sampled at a time (although multiple events can be sampled for the same opcode).

PortSelectRW8Selects port to be sampled. For a switch, PortSelect refers to a switch port. The valid values are from 1 to the number of device ports; the switch management port is not included. If the value is invalid, the sample timers run normally but the resulting sample values are undefined. If gathering data from all ports at once is supported (as indicated by ClassPortInfo.CapabilityMask.AllPortSelect), setting PortSelect to FFh causes samples from all valid ports to be accumulated.
TickRO8Indicates the node's sampling clock interval as a multiple of 10x the link transfer period. For a 2.5 Gb/s link, the transfer period is 400 picoseconds. The encoding is:
  • 00h = 10 X link transfer period (period is 4ns for a 2.5Gb/s link).

  • 01h = 20 X link transfer period.

  • 02h = 30 X link transfer period.

  • ...

  • FFh = 2,560 X link transfer period.

To maximize the utility of the performance attributes, implementers are encouraged to choose the smallest practical tick size.
CounterWidthRO3Indicates the actual bit width of the following elements (in the PortSamplesControl attribute):
  • SampleStart.

  • SampleInterval.

  • PortSamplesResult.Counter0 to 14.

The encoding is:

  • 0 = 16 bits.

  • 1 = 20 bits.

  • 2 = 24 bits.

  • 3 = 28 bits.

  • 4 = 32 bits.

  • 5–7 = reserved.

Counters smaller than 32 bits are implemented as the lsbs of the corresponding 32-bit attribute element, with the unimplemented upper element bits returning zeroes for Get and ignored on a Set.
ReservedRO2Reserved, shall be zero.
Counter0MaskRO3A bit mask that determines the capabilities of PortSamplesResult.Counter0.
  • Bit 0 is always 1, indicating support of all mandatory events.

  • Bit 1 = supports optional events.

  • Bit 2 = supports vendor-defined events.

CounterMasks1to9RO27Array of nine, 3-bit bitmasks, each of which indicates the capabilities of an optional counter in PortSamplesResult. The most-significant 3-bit field corresponds to PortSamplesResult.Counter1, while the least-significant field corresponds to PortSamplesResult.Counter9.

Encoding:

  • Bit 0 = supports all mandatory events.

  • Bit 1 = supports optional events.

  • Bit 2 = supports vendor-defined events.

All zeros means the counter is not implemented. Also see the description of CounterMasks10to14 in this table.
ReservedRO1Reserved, shall be zero.
CounterMasks10to14RO15Array of five, 3-bit bitmasks, each of which indicates the capabilities of an optional counter in PortSamplesResult. The most-significant 3-bit field corresponds to PortSamplesResult.Counter10, while the least-significant field corresponds to PortSamplesResult.Counter14.

Encoding:

  • Bit 0 = supports all mandatory events.

  • Bit 1 = supports optional events.

  • Bit 2 = supports vendor-defined events.

All zeros means the counter is not implemented.
Sample MechanismsRO8Number of independent sample mechanisms implemented (i.e., sets of PortSamplesControl and PortSamplesResult), minus one:
  • 0 = 1 mechanism available, addressed by Attribute Modifier = 00000000h.

  • 1 = 2 mechanisms available, addressed by Attribute Modifiers 00000000h and 00000001h.

  • ...

  • 255 = 256 mechanisms available, addressed by Attribute Modifiers 00000000h–000000FFh.

Only one sample mechanism is required. N sample mechanisms permits N independent samples to be run simultaneously. Attribute Modifier FFFFFFFFh allows all sample mechanisms to be started with a single PerfSet(), sampling the same events during the same interval on N ports.
ReservedRO6Reserved, shall be zero.
SampleStatusRO2Indicates sampling status:
  • 0 = Sampling complete. Results available from PortSamplesResult attribute.

  • 1 = SampleStart timer running. All sample counter values in PortSamplesResult are undefined.

  • 2 = Sampling underway. All sample counter values in PortSamplesResult are undefined.

  • 3 = Reserved.

While SampleStatus ≠ 0, a PerformanceSet(PortSamplesControl) doesn't affect PortSamplesControl and returns the existing values of all elements.
OptionMaskRO64Bit mask indicating which optional performance events are implemented, if any:
  • Bit 0 = reserved = zero.

  • Bit 1 = PortXmitQueue[n].

  • Bit 2 = PortXmitDataVL[n].

  • Bit 3 = PortRcvDataVL[n].

  • Bit 4 = PortXmitPktVL[n].

  • Bit 5 = PortRcvPktVL[n].

  • Bit 6 = PortRcvErrorDetails.PortLocalPhysicalErrors

  • Bit 7 = PortRcvErrorDetails.PortMalformedPacket Errors

  • Bit 8 = PortRcvErrorDetails.PortBufferOverrun Errors

  • Bit 9 = PortRcvErrorDetails.PortDLIDMapping Errors

  • Bit 10 = PortRcvErrorDetails.PortVLMappingErrors

  • Bit 11 = PortRcvErrorDetails.PortLoopingErrors

  • Bit 12 = PortXmitDiscardDetails.PortInactive Discards

  • Bit 13 = PortXmitDiscardDetails.PortNeighborMTU Discards

  • Bit 14 = PortXmitDiscardDetails.PortSwLifetime LimitDiscards

  • Bit 15 = PortXmitDiscardDetails.PortSwHOQ LifetimeLimitDiscards

  • Bit 16 = PortOpRcvCounters.PortOpRcvPkts

  • Bit 17 = PortOpRcvCounters.PortOpRcvData

  • Bit 18 = PortFlowCtlCounters.PortXmitFlowPkts

  • Bit 19 = PortFlowCtlCounters.PortRcvFlowPkts

  • Bit 20 = PortVLOpPackets.PortVLOpPackets[n]

  • Bit 21 = PortVLOpData.PortVLOpData[n]

  • Bit 22 = PortVLXmitFlowCtlUpdateErrors.Port VLXmitFlowCtlUpdateErrors[n]

  • Bit 23 = PortVLXmitWaitCounters.PortVLXmit Wait[n]

  • Bits 24 - 47 Reserved = 0.

  • Bit 48 = SwPortVLUnkDests.PortVLUnkDests[n].

  • Bits 49 -63 Reserved = 0.

Performance events that are counted per VL are limited to actual number of VLs implemented. Result of selecting unimplemented event = 0.
VendorMaskRO64Bitmask indicating implemented vendor-specific counters. Must = 0 if the node doesn't support any vendor-specific counters; otherwise, its use is vendor-defined.
SampleStartRW32Determines when sampling interval starts. When written to with a Set operation, the value is loaded into a timer and the following events occur:
  • SampleStatus is set to 1.

  • Counters in PortSamplesResult are set to zero.

  • The timer decrements once per tick.

When the timer reaches zero, the following events occur:

  • If selected, PortXmitQueue events are latched.

  • PortSamplesResult sampling counters are started.

  • SampleStatus is set to 2 (sampling underway).

  • SampleInterval timer is started.

The SampleStart timer allows a performance application to randomize the sample start time and ensure decoupling from node or network events. Values used will typically be 10's of milliseconds. The fine granularity of the interval with respect to the link rate makes decoupling possible.
SampleIntervalRW32Determines the sampling interval length. When written with a Set operation, the value is loaded into a timer. When the SampleStart counter reaches zero, this timer starts decrementing once per tick. When = 0, the following events occur:
  • PortSamplesResult sampling counters are stopped and the resulting values are made available.

  • SampleStatus is set to zero.

TagRW16Set by a performance application when it does a PerfSet(PortSamplesControl) to uniquely identify its sample run (in case of a collision with another performance application). When starting a sample run, software should pick a random Tag value. If the returned Tag doesn't match the selected value, another application is using the sampling mechanism. In this case, the first application must wait awhile and retry its sample.
CounterSelect0RW16Selects event to be sampled by PortSamplesResult.Counter0 as defined in “PortSampleControls.CounterSelect Values” on page 1034. If an unimplemented event is selected, a PerfGet(PortSamplesResult.Counter0) returns 0.
CounterSelect1RW16Counter 1 event select. See CounterSelect0 description.
CounterSelect2RW16Counter 2 event select. See CounterSelect0 description.
CounterSelect3RW16Counter 3 event select. See CounterSelect0 description.
CounterSelect4RW16Counter 4 event select. See CounterSelect0 description.
CounterSelect5RW16Counter 5 event select. See CounterSelect0 description.
CounterSelect6RW16Counter 6 event select. See CounterSelect0 description.
CounterSelect7RW16Counter 7 event select. See CounterSelect0 description.
CounterSelect8RW16Counter 8 event select. See CounterSelect0 description.
CounterSelect9RW16Counter 9 event select. See CounterSelect0 description.
CounterSelect10RW16Counter 10 event select. See CounterSelect0 description.
CounterSelect11RW16Counter 11 event select. See CounterSelect0 description.
CounterSelect12RW16Counter 12 event select. See CounterSelect0 description.
CounterSelect13RW16Counter 13 event select. See CounterSelect0 description.
CounterSelect14RW16Counter 14 event select. See CounterSelect0 description.

PortSampleControls.CounterSelect Values

Table 35-6 on page 1035 lists the values that can be written to the PortSamplesControl.CounterSelect[n] attribute elements to select a particular event to sample. Events that can be sampled are divided into three ranges:

  • Mandatory events (0000h–3FFFh). Must be implemented on all ports of all devices.

  • Optional events (4000h–BFFFh). The OptionMask attribute element (see Table 35-5 on page 1027) indicates which of the optional performance events can be measured.

  • Vendor events (C000h–FFFFf). The VendorMask attribute element (see Table 35-5 on page 1027) indicates which vendor-specific performance events can be measured.

Table 35-6. PortSampleControls.CounterSelect Attribute Element Values
ValueNameDescription
The events listed below are Mandatory Events.
0000hReservedReserved
0001hPortXmitDataTotal number of data bytes ÷ 4 transmitted on all VLs during the sampling interval by the port selected by PortSelect (in the PortCounters attribute or in one of the optional PM attributes). Includes all bytes between (but not including) start of packet delimiter and VCRC. Excludes all link packets (i.e., FCPs). Implementers may choose to count data bytes in groups larger than four but are encouraged to choose the smallest group possible. Results are always reported in units of four bytes.
0002hPortRcvDataTotal number of data bytes ÷ 4 received on all VLs during the sampling interval on the port selected by PortSelect. Includes all bytes between (but not including) start of packet delimiter and VCRC. Excludes all link packets (i.e., FCPs). Implementers may choose to count data bytes in groups larger than four but are encouraged to choose the smallest group possible. Results are always reported in units of four bytes.
0003hPortXmitPktsTotal number of packets, excluding link packets, transmitted on all VLs during the sampling interval by the port selected by PortSelect.
0004hPortRcvPktsTotal number of packets, including packets containing errors and excluding link packets (i.e., FCPs), received on all VLs during the sampling interval on the port selected by PortSelect.
0005hPortXmitWaitNumber of ticks during which selected port had data to transmit but none was sent during the entire tick either because of insufficient credits or due to arbitration.
0007h-3FFFhReservedReserved. Result of sampling is all zeroes.
The events listed below are Optional InfiniBand Events. All events available in optional attributes as running counters are also optionally available for sampling over a given period. Each sampling counter corresponding to an optional running counter is reset to zero for each sample and increments along with the selected running counter during the sampling interval. For certain events, such as PortXmitQueue[n], there are no corresponding optional attributes. All values between 4000h and BFFFh not listed here are reserved, and the result of sampling is all zeroes.
4n00hPortXmitQueue[n] Transmit queue depth in bytes on VLn of selected port when the SampleStart timer expired (the author assumes that the specification is referring to the available VL transmit buffer space). Measuring queue depths enables software to compute the average time data waits for transmission inside a node. Ideally, a node should increment a counter upon arrival of each byte destined for a given output port and should decrement the counter upon departure of each byte from the output port. In practice, this is impossible to implement precisely. Implementers are encouraged to measure queue depths as accurately as possible and to document any systematic measurement errors. An implementation can compensate for an inherent delay in accounting for arriving bytes by introducing an equal delay in accounting for departing bytes.
4n01hPortXmit DataVL[n] Total number of data bytes ÷ 4 transmitted on VLn from the selected port. Includes all bytes between start of packet and end of packet delimiters. Excludes all control characters and VCRCs. Implementers may choose to count data bytes in groups larger than four, but are encouraged to choose the smallest group possible. Results are always reported as a multiple of four bytes.
4n02hPortRcv DataVL[n] Total number of data bytes ÷ 4 received on input VLn on selected port. Includes all bytes between start of packet and end of packet delimiters. Excludes all control characters and VCRCs. Implementers may choose to count data bytes in groups larger than four, but are encouraged to choose the smallest group possible. Results are always reported as a multiple of four bytes.
4n03hPortXmit PktVL[n] Total packets transmitted on VLn from selected port with or without errors.
4n04hPortRcv PktVL[n] Total packets received on input VL n on selected port with or without errors.
4005hPortRcvErrorDetails.Port LocalPhysicalErrorsSee Table 35-11 on page 1050.
4006hPortRcvErrorDetails.PortMalformed PacketErrorsSee Table 35-11 on page 1050.
4007hPortRcvErrorDetails.PortBufferOverrunErrorsSee Table 35-11 on page 1050.
4008hPortRcvErrorDetails.PortDLIDMappingErrorsSee Table 35-11 on page 1050.
4009hPortRcvErrorDetails.Port VLMapping ErrorsSee Table 35-11 on page 1050.
400AhPortRcvErrorDetails.PortLoopingErrorsSee Table 35-11 on page 1050.
400BhPortXmit Discard Details.Port Inactive DiscardsSee Table 35-12 on page 1051.
400ChPortXmit Discard Details.PortNeighbor MTUDiscardsSee Table 35-12 on page 1051.
400DhPortXmit Discard Details.Port SwLifetimeLimitDiscardsSee Table 35-12 on page 1051.
400EhPortXmit Discard Details.Port SwHOQLimitDiscardsSee Table 35-12 on page 1051.
400FhPortOpRcvCounters.Port OpRcvPktsThe BTH:Opcode to be sampled is selected by PortSamplesControl.Opcode. See the description of the PortOpRcvPkts attribute element in Table 35-13 on page 1053.
4010hPortOpRcvCounters.Port OpRcvDataThe opcode to be sampled is selected by PortSamples- Control.Opcode. See the description of the PortOpRcvData attribute element in Table 35-13 on page 1053.
4011hPortFlowCtlCounters.PortXmitFlowPktsSee Table 35-14 on page 1054.
4012hPortFlowCtlCounters.Port RcvFlowPktsSee Table 35-14 on page 1054.
4n13hPortVLOpPackets.Port VLOp Packets[n]The BTH:Opcode to be sampled is selected by PortSamplesControl.Opcode. See Table 35-15 on page 1054.
4n14hPortVLOpData.Port VLOpData [n]The BTH:Opcode to be sampled is selected by PortSamplesControl.Opcode. See Table 35-16 on page 1057.
4n15hPortVLXmitFlowCtlUp dateErrors. PortVLXmitFlowCtlUp dateErrors[n]See Table 35-17 on page 1059.
4n16hPortVLXmitWaitCounters. PortVLXmitWait[n]See Table 35-18 on page 1062.
4n30hSwPortVL UnkDests. PortVL UnkDests[n]See Table 35-19 on page 1065.
Vendor-Defined Events
C000h-FFFFhReservedReserved for vendor-specific counters.

PortSamplesResults Mandatory Attribute

Refer to Table 35-7 on this page. Once a sampling session is triggered via a PerfSet(PortSamplesControl), a PerfGet(PortSamplesResult) returns the status of the sampling session (Sampling complete, session not yet started because SampleStart timer still running, or Sampling underway). If the status indicates that the sampling session is complete, the PerfGet(PortSamplesResult) also returns the contents of the event counters (in addition to the session status).

Table 35-7. PortSamplesResults Attribute Structure
ElementAccessLength (in bits)Description
TagRO16Copy of PortSamplesControl.Tag. Set by a performance application when it does a PerfSet(PortSamplesControl), it uniquely identifies this sample run (in case of a collision with another performance application). When starting a sample run, software should pick a random Tag value. If the returned Tag doesn't match the selected value, another application is using the sampling mechanism. In this case, the first application must wait for a suitable time and retry its sample.
ReservedRO14Reserved, shall be zero.
SampleStatusRO2Copy of PortSamplesControl.SampleStatus. Provided here to minimize traffic while the performance application is polling for sample completion.
Counter0RO32Mandatory counter. When PortSamplesControl.SampleStatus = 0, contains the event sampling result selected by PortSamplesControl.CounterSelect0. Undefined when PortSamplesControl.SampleStatus ≠ 0. Number of valid (least significant) bits in the counter is defined by PortSamplesControl.CounterWidth.
Counter1RO32Optional counter (= 0 if not implemented). Contains the event sampling result selected by PortSamplesControl.Counter1Select. See description of Counter0 in this table.
Counter2RO32Optional counter (= 0 if not implemented). Contains the result of sampling the event selected by PortSamplesControl.Counter2Select. See description of Counter0 in this table.
Counter3RO32Optional counter (= 0 if not implemented). Contains the event sampling result selected by PortSamplesControl.Counter3Select. See description of Counter0 in this table.
Counter4RO32Optional counter (= 0 if not implemented). Contains the event sampling result selected by PortSamplesControl.Counter4Select. See description of Counter0 in this table.
Counter5RO32Optional counter (= 0 if not implemented). Contains the event sampling result selected by PortSamplesControl.Counter5Select. See description of Counter0 in this table.
Counter6RO32Optional counter (= 0 if not implemented). Contains the event sampling result selected by PortSamplesControl.Counter6Select. See description of Counter0 in this table.
Counter7RO32Optional counter (= 0 if not implemented). Contains the event sampling result selected by PortSamplesControl.Counter7Select. See description of Counter0 in this table.
Counter8RO32Optional counter (= 0 if not implemented). Contains the event sampling result selected by PortSamplesControl.Counter8Select. See description of Counter0 in this table.
Counter9RO32Optional counter (= 0 if not implemented). Contains the event sampling result selected by PortSamplesControl.Counter9Select. See description of Counter0 in this table.
Counter10RO32Optional counter (= 0 if not implemented). Contains the event sampling result selected by PortSamplesControl.Counter10Select. See description of Counter0 in this table.
Counter11RO32Optional counter (= 0 if not implemented). Contains the event sampling result selected by PortSamplesControl.Counter11Select. See description of Counter0 in this table.
Counter12RO32Optional counter (= 0 if not implemented). Contains the event sampling result selected by PortSamplesControl.Counter12Select. See description of Counter0 in this table.
Counter13RO32Optional counter (= 0 if not implemented). Contains the event sampling result selected by PortSamplesControl.Counter13Select. See description of Counter0 in this table.
Counter14RO32Optional counter (= 0 if not implemented). Contains the event sampling result selected by PortSamplesControl.Counter14Select. See description of Counter0 in this table.

PortCounters Mandatory Attribute

Refer to Table 35-8 on page 1043. This attribute provides basic performance and exception statistics for a port. When initially powered-up or reset, the value of all counters (in the PortCounters attribute) on all ports of a device are set to zero. These event counters clamp when they reach all ones. A counter is reset to zero by writing zero into it [via a PerfSet(PortCounters)]. Writing anything other than zero into a counter results in undefined behavior. Note that four of the event counters in PortCounters are optional.

Table 35-8. PortCounters Attribute Structure
ElementAccessLength (in bits)Description
ReservedRO8Reserved, shall be zero.
PortSelectRW8On an attribute read, selects the port for which the data is reported. Valid values are from 1 to the number of device ports (switch management port not included). If value is invalid, counter data returned is undefined. If gathering data from all ports at once is supported (see description of ClassPortInfo in Table 35-4 on page 1025), setting PortSelect to FFh causes:
  • A PerfSet(PortCounters) to update the content of the counters selected by PortCounters.CounterSelect (see description of CounterSelect in this table) for all valid ports.

  • A PerfGetResp(PortCounters) returned in response to a PerfGet(PortCounters) or a PerfSet(PortCounters) fills each counter component value with the sum of the respective counter values for all the valid ports.

CounterSelectRW16When written to, selects the counters affected by the operation. Ignored on a read:
  • Bit 0 - SymbolErrorCounter

  • Bit 1 - LinkErrorRecoveryCounter

  • Bit 2 - LinkDownedCounter

  • Bit 3 - PortRcvErrors

  • Bit 4 - PortRcvRemotePhysicalErrors

  • Bit 5 - PortRcvSwitchRelayErrors

  • Bit 6 - PortXmitDiscards

  • Bit 7 - PortXmitConstraintErrors

  • Bit 8 - PortRcvConstraintErrors

  • Bit 9 - LocalLinkIntegrityErrors

  • Bit 10 - ExcessiveBufferOverrunErrors

  • Bit 11 - VL15Dropped

  • Bit 12 - PortXmitData (optional counter)

  • Bit 13 - PortRcvData (optional counter)

  • Bit 14 - PortXmitPkts (optional counter)

  • Bit 15 - PortRcvPkts (optional counter)

SymbolErrorCounterRW16

Required counter. Total symbol errors detected on one or more lanes. See “Minor Error Handling” on page 753.

LinkErrorRecoveryCounterRW8

Required counter. Total times the Port Training state machine has successfully completed the link error recovery process. See “Major Error Handling” on page 753.

LinkDownedCounterRW8

Required counter. Total times the Port Training state machine has failed the link error recovery process and downed the link. See “Recovery State” on page 744 and “Major Error Handling” on page 753.

PortRcvErrorsRW16

Required counter. Total error packets received on the port. Errors include:

  • Local physical errors (ICRC, VCRC, FCCRC, and all physical errors that cause entry into the Bad Packet or Bad Packet Discard states of the packet receiver state machine; refer to “Packet Receive State Machine” on page 653).

  • Malformed data packet errors (LVer, length, VL).

  • Malformed link packet (FCP) errors (operand, length, VL).

  • Packets discarded due to buffer overrun.

PortRcvRemotePhysicalErrorsRW16

Required counter. Total packets with EBP delimiter received on the port.

PortRcvSwitchRelayErrorsRW16

Required counter. Total packets received on port discarded because they could not be forwarded by the switch. Reasons for this include:

  • DLID error on Forwarding Table lookup.

  • Packet's LRH:SL SLtoVL map lookup resulted in invalid VL.

  • Looping error. Forwarding Table lookup selected the same port that packet arrived on.

PortXmitDiscardsRW16

Required counter. Total outbound packets discarded by the port due to port down or congestion. Reasons for this include:

  • Output port in inactive state (see “Link State Machine” on page 602).

  • Packet length exceeded neighbor MTU.

  • Switch lifetime limit exceeded.

  • Switch HOQ limit exceeded.

PortXmitConstraintErrorsRW8

Required counter. Total packets not transmitted by port due to:

  • FilterRawOutbound true and packet is raw (see Table 29-5 on page 825).

  • PartitionEnforcementOutbound (see “Inbound and Outbound P_Key Checking” on page 838) true and packet fails partition P_Key check, IP version check, or transport header version check.

PortRcvConstraintErrorsRW8

Required counter. Total packets received on port discarded due to:

  • FilterRawInbound true and packet is raw (see Table 29-5 on page 825).

  • PartitionEnforcementInbound (see “Inbound and Outbound P_Key Checking” on page 838) true and packet fails partition key check, IP version check, or transport header version check.

Reserved1RO8Reserved
LocalLinkIntegrityErrorsRW4

Required counter. Number of times the frequency of packets containing local physical errors exceeded local_phy_errors (see description of LocalPhyErrors in Table 29-5 on page 825).

ExcessiveBufferOverrunErrorsRW4

Required counter. Number of times that overrun_errors in consecutive flow control update periods occurred with at least one overrun error in each period (see description of OverrunErrors in Table 29-5 on page 825).

Reserved2RO16Reserved.
VL15DroppedRW16

Required counter. Number of incoming VL15 packets (SMPs) dropped due to VL15 receive buffer full condition on port selected by PortCounters.PortSelect.

PortXmitDataRW32

Optional counter (= 0 if not implemented). Total number of data bytes ÷ 4 transmitted on all VLs from port selected by PortCounters.PortSelect. Includes all bytes between (but not including) start of packet delimiter and VCRC. Excludes all link packets (i.e., FCPs). Implementers may count data bytes in groups larger than four, but are encouraged to choose the smallest group possible. Results are always reported as a multiple of four bytes.

PortRcvDataRW32

Optional counter (= 0 if not implemented). Total number of data bytes ÷ 4 received on all VLs on port selected by PortCounters.PortSelect. Includes all bytes between (but not including) start of packet delimiter and VCRC. Excludes all link packets (i.e., FCPs). Implementers may count data bytes in groups larger than four, but are encouraged to choose the smallest group possible. Results are always reported as a multiple of four bytes.

PortXmitPktsRW32

Optional counter (= 0 if not implemented). Total number of packets, excluding link packets (i.e., FCPs), transmitted on all VLs from the port.

PortRcvPktsRW32

Optional counter (= 0 if not implemented). Total number of packets, including packets containing errors and excluding link packets (i.e., FCPs), received on all of port's VLs.


..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.145.46.109