class EndpointInspect
Defined at line 35 of file ../../src/devices/usb/lib/usb-inspect/include/usb-inspect/usb-inspect.h
Class to manage common USB endpoint diagnostics using a lazy inspect node.
Hot-path counters are atomic and VMO writes are completely eliminated from
the driver runtime (only populated on-demand upon query).
Public Members
static const size_t kDefaultEventCapacity
static const size_t kDefaultTransferCapacity
Public Methods
void Init (inspect::Node &parent,const std::string &name,size_tevent_capacity,size_ttransfer_snapshot_capacity)
============================================================================
EndpointInspect Implementation
============================================================================
Defined at line 38 of file ../../src/devices/usb/lib/usb-inspect/usb-inspect.cc
void EndpointInspect ()
Defined at line 54 of file ../../src/devices/usb/lib/usb-inspect/include/usb-inspect/usb-inspect.h
void UpdateTxQueue (size_t pending_requests)
Update TX pending requests count.
Defined at line 60 of file ../../src/devices/usb/lib/usb-inspect/include/usb-inspect/usb-inspect.h
void UpdateRxQueue (size_t pending_requests)
Update RX pending requests count.
Defined at line 65 of file ../../src/devices/usb/lib/usb-inspect/include/usb-inspect/usb-inspect.h
void UpdateRxPendingProcessing (size_t pending_requests)
Defined at line 69 of file ../../src/devices/usb/lib/usb-inspect/include/usb-inspect/usb-inspect.h
void AddTxBytes (size_t bytes)
Defined at line 73 of file ../../src/devices/usb/lib/usb-inspect/include/usb-inspect/usb-inspect.h
void AddRxBytes (size_t bytes)
Defined at line 75 of file ../../src/devices/usb/lib/usb-inspect/include/usb-inspect/usb-inspect.h
void AddFailedTxBytes (size_t bytes)
Defined at line 77 of file ../../src/devices/usb/lib/usb-inspect/include/usb-inspect/usb-inspect.h
void AddFailedRxBytes (size_t bytes)
Defined at line 81 of file ../../src/devices/usb/lib/usb-inspect/include/usb-inspect/usb-inspect.h
void SetMaxByteRate (uint64_t max_rate)
Defined at line 85 of file ../../src/devices/usb/lib/usb-inspect/include/usb-inspect/usb-inspect.h
uint64_t total_bytes_tx_val ()
Defined at line 99 of file ../../src/devices/usb/lib/usb-inspect/include/usb-inspect/usb-inspect.h
uint64_t total_bytes_rx_val ()
Defined at line 100 of file ../../src/devices/usb/lib/usb-inspect/include/usb-inspect/usb-inspect.h
uint64_t failed_bytes_tx_val ()
Defined at line 102 of file ../../src/devices/usb/lib/usb-inspect/include/usb-inspect/usb-inspect.h
uint64_t failed_bytes_rx_val ()
Defined at line 104 of file ../../src/devices/usb/lib/usb-inspect/include/usb-inspect/usb-inspect.h
void MeasureThroughput (zx::duration elapsed)
Defined at line 121 of file ../../src/devices/usb/lib/usb-inspect/usb-inspect.cc
void RecordEvent (const std::string & event_name)
Defined at line 169 of file ../../src/devices/usb/lib/usb-inspect/usb-inspect.cc
void SnapshotTransferStats ()
Captures an independent cumulative transfer stats snapshot at current boot time.
Note: These values represent the totals and max rate since boot, not the
incremental traffic and max rate since the last snapshot.
Called automatically by RecordEvent(), or directly by drivers at any point.
Defined at line 161 of file ../../src/devices/usb/lib/usb-inspect/usb-inspect.cc