On 2026/8/20 03:16, Peter Xu wrote:
On Mon, Aug 17, 2026 at 06:51:16PM +0800, Yanfei Xu wrote:
The source return-path thread can send READY before the destination has
posted its initial receive. Since RNR retries default to zero, the send
can fail and abort migration.
Post the initial receive before rdma_accept() to close this window.
Fixes: 55cc1b5937a8 ("migration: create a dedicated connection for rdma return
path")
Signed-off-by: Yanfei Xu<[email protected]>
This one looks correct to me,
Reviewed-by: Peter Xu<[email protected]>
Do you have way to reproduce it, or is this theory (or can be reproduced by
adding delays)?
Yes, adding delays can reproduce it.
For example with sleep(1) and related traces, log at source side:
2026-08-20T05:55:11.471421Z qemu_rdma_exchange_get_response_start
CONTROL: READY receiving...
2026-08-20T05:55:11.471422Z qemu_rdma_post_send_control CONTROL: sending
QEMU FILE..
2026-08-20T05:55:11.471447Z qemu_rdma_poll_other other completion 2000
received left 0
2026-08-20T05:55:11.471589Z qemu_rdma_poll_recv completion 0 received
(4000) left 0
2026-08-20T05:55:11.471592Z qemu_rdma_poll_other other completion 4000
received left 0
2026-08-20T05:55:11.471594Z qemu_rdma_exchange_get_response_start
CONTROL: READY receiving...
2026-08-20T05:55:11.471596Z qemu_rdma_post_send_control CONTROL: sending
QEMU FILE..
2026-08-20T05:55:11.471617Z qemu_rdma_poll_other other completion 2000
received left 0
2026-08-20T05:55:11.705561Z qemu_rdma_close
2026-08-20T05:55:11.705587Z qemu_rdma_close
2026-08-20T05:55:11.705626Z qemu-system-x86_64: rdma migration: send
polling control error
2026-08-20T05:55:11.707001Z qemu-system-x86_64: warning: Early error.
Sending error.
2026-08-20T05:55:11.707031Z qemu_rdma_post_send_control CONTROL: sending
ERROR..
2026-08-20T05:55:11.707038Z qemu-system-x86_64: warning: rdma migration:
send polling control error
2026-08-20T05:55:11.707301Z qemu_rdma_cleanup_disconnect
2026-08-20T05:55:11.710569Z qemu_rdma_cleanup_disconnect
Regards,
Yanfei