Enabling the port split on Mellanox MQM8790 InfiniBand switch as example.
From a computer with installed Mellanox InfiniBand drivers and tools (mst, mlxconfig and mstflint) run these commands:
mst start
mst ib add
mst status
Output from last command will list InfiniBand clients and switches. These looks like switches:
. . .
/dev/mst/SW_MT53000_SwitchIB_Mellanox_Technologies_lid-0x0002
/dev/mst/SW_MT54000_Quantum_Mellanox_Technologies_lid-0x0049
/dev/mst/SW_MT54000_Quantum_Mellanox_Technologies_lid-0x00e2
/dev/mst/SW_MT54000_Quantum_Mellanox_Technologies_lid-0x0137
/dev/mst/SW_MT54000_switch-2073c0_lid-0x000e
. . .
Some guess work to find switch that I want to configure.
# mlxconfig -d /dev/mst/SW_MT54000_Quantum_Mellanox_Technologies_lid-0x0049 q
Device #1:
----------
Device type: Quantum
Name: MQM8790-HS2X_Ax
Description: Mellanox Quantum(TM) HDR InfiniBand Switch; 40 QSFP56 ports; 2 Power Supplies (AC); unmanaged; standard depth; P2C airflow; Rail Kit; RoHS6
Device: /dev/mst/SW_MT54000_Quantum_Mellanox_Technologies_lid-0x0049
Configurations: Next Boot
RO SPLIT_NUM_OF_PORTS 40
RO SPLIT_CAP SPLIT_2X(1)
SPLIT_MODE NO_SPLIT_SUPPORT(0)
DISABLE_AUTO_SPLIT ENABLE_AUTO_SPLIT(0)
SPLIT_PORT Array[1..64]
GB_VECTOR_LENGTH 0
GB_UPDATE_MODE ALL(0)
GB_VECTOR Array[0..7]
The 'RO' shows parameters which are for read only and cannot be changed
Set the Split Mode:
mlxconfig -d /dev/mst/SW_MT54000_Quantum_Mellanox_Technologies_lid-0x0049 set ENABLE_AUTO_SPLIT=1
Split selected ports:
mlxconfig -d /dev/mst/SW_MT54000_Quantum_Mellanox_Technologies_lid-0x0049 set SPLIT_PORT[3..40]=1
Reboot switch:
mstflint -d /dev/mst/SW_MT54000_Quantum_Mellanox_Technologies_lid-0x0049 swreset
Check status after reboot:
# mlxconfig -d /dev/mst/SW_MT54000_Quantum_Mellanox_Technologies_lid-0x0049 q SPLIT_MODE
. . .
Configurations: Next Boot
SPLIT_MODE SPLIT_2X(1)
Port statuses:
# mlxconfig -d /dev/mst/SW_MT54000_Quantum_Mellanox_Technologies_lid-0x0049 q SPLIT_PORT[1..40]
. . .
Configurations: Next Boot
SPLIT_PORT[1] NO_SPLIT(0)
SPLIT_PORT[2] NO_SPLIT(0)
SPLIT_PORT[3] SPLIT_2X(1)
SPLIT_PORT[4] SPLIT_2X(1)
SPLIT_PORT[5] SPLIT_2X(1)
SPLIT_PORT[6] SPLIT_2X(1)
. . .