[PATCH] drbd: Fix the seq_num conversion error in got_OVResult()

zhengbing.huang zhengbing.huang at easystack.cn
Tue Aug 19 07:49:59 CEST 2025


In the got_OVResult function, seq_num was converted twice by the be32_to_cpu,
which led to an abnormal value of peer_device->peer_seq.
Any subsequent use peer_device->peer_seq would result in an error.

For example, we encounter the follow error:
xxx: Timed out waiting for missing ack packets; disconnecting

So, we remove the second erroneous be32_to_cpu conversion.

Signed-off-by: zhengbing.huang <zhengbing.huang at easystack.cn>
---
 drbd/drbd_receiver.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drbd/drbd_receiver.c b/drbd/drbd_receiver.c
index fdb6eb458..21bc84c5b 100644
--- a/drbd/drbd_receiver.c
+++ b/drbd/drbd_receiver.c
@@ -10743,7 +10743,7 @@ static int got_OVResult(struct drbd_connection *connection, struct packet_info *
 		result = be32_to_cpu(p->result);
 	}
 
-	update_peer_seq(peer_device, be32_to_cpu(seq_num));
+	update_peer_seq(peer_device, seq_num);
 
 	peer_req = find_resync_request(peer_device, INTERVAL_TYPE_MASK(INTERVAL_OV_READ_TARGET),
 			sector, size, block_id);
-- 
2.43.0



More information about the drbd-dev mailing list