From: lihongweizz <lihongweizz@inspur.com>
To: <mark@fasheh.com>, <jlbec@evilplan.org>, <joseph.qi@linux.alibaba.com>
Cc: <ocfs2-devel@oss.oracle.com>, <linux-kernel@vger.kernel.org>,
Rock Li <lihongweizz@inspur.com>
Subject: [PATCH] ocfs2: properly clean task pointer before o2hb thread exits abnormally
Date: Fri, 25 Nov 2022 11:15:22 +0800 [thread overview]
Message-ID: <20221125031522.339-1-lihongweizz@inspur.com> (raw)
From: Rock Li <lihongweizz@inspur.com>
in case o2hb thread exits abnormally before stop o2cb service,
heartbeat_drop_group_item will try to stop a noexit thread cause
ret->hb_task was not clear properly.
Signed-off-by: Rock Li <lihongweizz@inspur.com>
---
fs/ocfs2/cluster/heartbeat.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/fs/ocfs2/cluster/heartbeat.c b/fs/ocfs2/cluster/heartbeat.c
index b13d344..9db448d 100644
--- a/fs/ocfs2/cluster/heartbeat.c
+++ b/fs/ocfs2/cluster/heartbeat.c
@@ -1258,6 +1258,8 @@ static int o2hb_thread(void *data)
/* Unpin node */
o2nm_undepend_this_node();
+ reg->hr_task = NULL;
+
mlog(ML_HEARTBEAT|ML_KTHREAD, "o2hb thread exiting\n");
return 0;
--
1.8.3.1
next reply other threads:[~2022-11-25 3:15 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-11-25 3:15 lihongweizz [this message]
2022-11-25 9:28 ` Joseph Qi
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20221125031522.339-1-lihongweizz@inspur.com \
--to=lihongweizz@inspur.com \
--cc=jlbec@evilplan.org \
--cc=joseph.qi@linux.alibaba.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mark@fasheh.com \
--cc=ocfs2-devel@oss.oracle.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®