This is a note to let you know that I've just added the patch titled fs: dlm: be sure to call dlm_send_queue_flush() to the 6.2-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the patch is: fs-dlm-be-sure-to-call-dlm_send_queue_flush.patch and it can be found in the queue-6.2 subdirectory. If you, or anyone else, feels it should not be added to the stable tree, please let <stable@xxxxxxxxxxxxxxx> know about it. >From 7354fa4ef697191effedc2ae9a8293427708bbf5 Mon Sep 17 00:00:00 2001 From: Alexander Aring <aahringo@xxxxxxxxxx> Date: Thu, 12 Jan 2023 17:10:33 -0500 Subject: fs: dlm: be sure to call dlm_send_queue_flush() From: Alexander Aring <aahringo@xxxxxxxxxx> commit 7354fa4ef697191effedc2ae9a8293427708bbf5 upstream. If we release a midcomms node structure, there should be nothing left inside the dlm midcomms send queue. However, sometimes this is not true because I believe some DLM_FIN message was not acked... if we run into a shutdown timeout, then we should be sure there is no pending send dlm message inside this queue when releasing midcomms node structure. Cc: stable@xxxxxxxxxxxxxxx Fixes: 489d8e559c65 ("fs: dlm: add reliable connection if reconnect") Signed-off-by: Alexander Aring <aahringo@xxxxxxxxxx> Signed-off-by: David Teigland <teigland@xxxxxxxxxx> Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx> --- fs/dlm/midcomms.c | 1 + 1 file changed, 1 insertion(+) --- a/fs/dlm/midcomms.c +++ b/fs/dlm/midcomms.c @@ -1402,6 +1402,7 @@ static void midcomms_node_release(struct struct midcomms_node *node = container_of(rcu, struct midcomms_node, rcu); WARN_ON_ONCE(atomic_read(&node->send_queue_cnt)); + dlm_send_queue_flush(node); kfree(node); } Patches currently in stable-queue which might be from aahringo@xxxxxxxxxx are queue-6.2/fs-dlm-fix-race-setting-stop-tx-flag.patch queue-6.2/fs-dlm-send-fin-ack-back-in-right-cases.patch queue-6.2/fs-dlm-start-midcomms-before-scand.patch queue-6.2/fs-dlm-move-sending-fin-message-into-state-change-handling.patch queue-6.2/fs-dlm-fix-use-after-free-in-midcomms-commit.patch queue-6.2/fs-dlm-be-sure-to-call-dlm_send_queue_flush.patch queue-6.2/fs-dlm-don-t-set-stop-rx-flag-after-node-reset.patch