Skip to content

Commit deb0e11

Browse files
a-r-ncopybara-github
authored andcommitted
set_multiqueue: set a4x-max ring len before irq affinity
PiperOrigin-RevId: 859268025
1 parent 62a5233 commit deb0e11

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

src/usr/bin/google_set_multiqueue

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -508,14 +508,17 @@ for ((node=0; node<num_numa_nodes; node++)); do
508508
continue
509509
fi
510510

511+
# For IDPF at least, we need to reconfigure ring size before setting IRQ affinity,
512+
# since adjusting the ring size destroys the IRQ affinity settings.
513+
if [[ $machine_type == *"a4x-maxgpu-"* ]]; then
514+
ethtool -G "$nic_name" rx "$A4X_RX_RING_LENGTH" tx "$A4X_TX_RING_LENGTH"
515+
fi
516+
511517
# For non-gvnic/idpf devices (e.g. mlx5), the IRQ bindings will be handled by the device's driver.
512518
if is_gvnic "$nic_name"; then
513519
bind_cores_index=$(set_irq_range_gve "$nic_name" "$bind_cores_index" "${node_irq_ranges[@]}")
514520
elif is_idpf "$nic_name"; then
515521
bind_cores_index=$(set_irq_range_idpf "$nic_name" "$bind_cores_index" "${node_irq_ranges[@]}")
516-
if [[ $machine_type == *"a4x-maxgpu-"* ]]; then
517-
ethtool -G "$nic_name" rx "$A4X_RX_RING_LENGTH" tx "$A4X_TX_RING_LENGTH"
518-
fi
519522
else
520523
echo "$nic_name is not a gvnic/idpf device, not setting irq affinity on this device"
521524
fi

0 commit comments

Comments
 (0)