On 12/06/26 13:11, Shivang Upadhyay wrote:
On Wed, 2026-06-10 at 14:32 +0530, Aditya Gupta wrote:
+            '#', self.panic_message)
+        exec_command_and_wait_for_pattern(self,
+             "CTL_IRQ=$(grep 'eth0$' /proc/interrupts | awk '{print
$1}' | tr -d ':')",
+            '#', self.panic_message)
+        exec_command_and_wait_for_pattern(self,
+            "echo 1 > /proc/irq/$RX_IRQ/smp_affinity_list",
+            '#', self.panic_message)
+        exec_command_and_wait_for_pattern(self,
+            "echo 2 > /proc/irq/$TX_IRQ/smp_affinity_list",
+            '#', self.panic_message)
+        exec_command_and_wait_for_pattern(self,
+            "echo 3 > /proc/irq/$CTL_IRQ/smp_affinity_list",
+            '#', self.panic_message)
+
+        # Generate network traffic to trigger remote interrupts
+        # Ping QEMU's user-mode network gateway (10.0.2.2)
+        exec_command_and_wait_for_pattern(self,
+            "ping -W2 -c5 10.0.2.2",
+            '#', self.panic_message)
Hi Aditya,

Thanks for this amazing test. But when I was tinkering with this test
case, Even if i changed command to "asdf" it seemed to pass. Also, in
the logs, sometime ping sometime it might fail.
The testcase wasn't that good, I had explicitly written it to just see if qemu keeps running, and doesn't crash on remote interrupts, as has been seen in the past. But yes, it's better if we actually check if ping caused any remote interrupts at all, since it wasn't checking that hence the testcase was passing.
Planning to have a check in v2.
pasta:review-aditya-qtests$ ./build/run python3
./tests/functional/ppc64/test_powernv.py
PowernvMachine.test_linux_remote_interrupts -v
TAP version 13
ok 1 test_powernv.PowernvMachine.test_linux_remote_interrupts
1..1
pasta:review-aditya-qtests$ cat
build/tests/functional/ppc64/test_powernv.PowernvMachine.test_linux_rem
ote_interrupts/console.log | grep -C5 "ping"
...
2026-06-12 12:59:26,316: ping -W2 -c5 10.0.2.2
2026-06-12 12:59:26,340: PING 10.0.2.2 (10.0.2.2): 56 data bytes
2026-06-12 12:59:26,343: ping: sendto: Network is unreachable
...
pasta:review-aditya-qtests$
This can happen if eth0 is not up yet, will handle it.

Also the interrupt counters, I think we need to verify the cpu where
the intrrupt is actually triggering.
Sure, will add it in v2.

Thanks for reviewing shivang !


- Aditya G

~Shivang.

Reply via email to