| Server IP : 138.197.107.151 / Your IP : 216.73.217.120 Web Server : Apache/2.4.58 (Ubuntu) System : Linux BloxBy-Builder 6.8.0-71-generic #71-Ubuntu SMP PREEMPT_DYNAMIC Tue Jul 22 16:52:38 UTC 2025 x86_64 User : wpbetasites_mrakzqskir ( 1022) PHP Version : 8.3.6 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : OFF Directory : /usr/lib/python3/dist-packages/sos/report/plugins/__pycache__/ |
Upload File : |
�
G%@i� � �, � d dl mZmZ G d� dee� Zy)� )�Plugin�IndependentPluginc �2 � e Zd ZdZdZdZdZed� � Zd� Z y)�Spyreu� Spyre chip is IBM’s AI accelerator, designed to handle AI inferencing
and workloads.
The Spyre plugin collects data about the Spyre card’s VFIO device node
tree, configuration files, and more.
z!IBM Spyre Accelerator Information�spyre)zppc.*c �� � g }| sy| j � D ]� }|j � s� |j d�� \ }}}}|j � j d� \ }}|dk( s�T|dv s�Y|j d� dk( rd|z } |j d� \ } }
}|j d � \ }}
|j
| |
||
f� �� |S # t $ r Y ��w xY w# t $ r Y ��w xY w)
a� Extract PCI domain, bus, device, function for devices that match:
- Vendor ID = 0x1014 (IBM)
- Device ID = 0x06a7 or 0x06a8
Parameters
----------
lspci_out : str
The output string from `lspci -n`.
Returns
-------
list of tuples
A list of (domain, bus, device, function) tuples for each matching
card.
N� )�maxsplit�:�1014)�06a7�06a8� z0000:�.)�
splitlines�strip�split�lower�
ValueError�count�append)�lspci_output�spyre_cards�line�pci_addr�_class�ids�_rest�vendor�device�domain�bus�dev_func�
pci_device�functions �:/usr/lib/python3/dist-packages/sos/report/plugins/spyre.py�get_ibm_spyre_deviceszSpyre.get_ibm_spyre_devices s � �$ ���� �+�+�-� H�D��:�:�<��
�/3�z�z�1�z�/E�,��&�#�u�!$����!2�!2�3�!7���� ���F�.>�$>��>�>�#�&�!�+�&��1�H��,4�N�N�3�,?�)�F�C��+3�>�>�#�+>�(�J�� �"�"�F�C��X�#F�G�' H�* ��� �
��
�� "� ���s# �9C� )C� C�C� C&�%C&c � � | j d� }|d dk7 ry | j |d � }|sy |D ]3 \ }}}}|� d|� d|� d|� �}d|� d|� d|� d �}| j |d
�� �5 | j g d�� y )
Nzlspci -n�statusr �outputr r z/sys/devices/pci�/z /vfio-devT)�tree)z/etc/modprobe.d/vfio-pci.confz!/etc/udev/rules.d/95-vfio-3.rulesz#/etc/security/limits.d/memlock.conf)�exec_cmdr'