mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Joseph Qi <joseph.qi@linux.alibaba.com>
To: lihongweizz <lihongweizz@inspur.com>,
	mark@fasheh.com, jlbec@evilplan.org
Cc: ocfs2-devel@oss.oracle.com, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] ocfs2: properly clean task pointer before o2hb thread exits abnormally
Date: Fri, 25 Nov 2022 17:28:56 +0800	[thread overview]
Message-ID: <03a60f60-6408-b67c-6e66-d4ff1d24089c@linux.alibaba.com> (raw)
In-Reply-To: <20221125031522.339-1-lihongweizz@inspur.com>



On 11/25/22 11:15 AM, lihongweizz wrote:
> 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.
> 
Could you please describe the scenario in detail?

Thanks,
Joseph 

> 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;

      reply	other threads:[~2022-11-25  9:29 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-11-25  3:15 lihongweizz
2022-11-25  9:28 ` Joseph Qi [this message]

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=03a60f60-6408-b67c-6e66-d4ff1d24089c@linux.alibaba.com \
    --to=joseph.qi@linux.alibaba.com \
    --cc=jlbec@evilplan.org \
    --cc=lihongweizz@inspur.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®