linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Tejun Heo <tj@kernel.org>
To: Jeff Layton <jlayton@poochiereds.net>
Cc: linux-kernel@vger.kernel.org, bfields@fieldses.org,
	Michael Skralivetsky <michael.skralivetsky@primarydata.com>,
	Chris Worley <chris.worley@primarydata.com>,
	Trond Myklebust <trond.myklebust@primarydata.com>,
	Lai Jiangshan <laijs@cn.fujitsu.com>
Subject: Re: timer code oops when calling mod_delayed_work
Date: Sat, 31 Oct 2015 17:31:07 -0400	[thread overview]
Message-ID: <20151031213107.GA23841@mtj.duckdns.org> (raw)
In-Reply-To: <20151031073400.2cf05d77@tlielax.poochiereds.net>

Hello, Jeff.

On Sat, Oct 31, 2015 at 07:34:00AM -0400, Jeff Layton wrote:
> > Heh, this one is tricky.  Yeah, try_to_grab_pending() missing PENDING
> > would explain the failure but I can't see how it'd leak at the moment.
> 
> Thanks Tejun. Yeah, I realized that after sending the response above.
> 
> If you successfully delete the timer the timer then the PENDING bit
> should already be set. Might be worth throwing in something like this,
> just before the return 1:
> 
>     WARN_ON(!test_bit(WORK_STRUCT_PENDING_BIT, work_data_bits(work)))
>
> ...but I doubt it would fire. I think it's likely that the bug is
> elsewhere.

I doubt that'd trigger either but it'd still be a good idea to throw
that in just in case.

> The other thing is that we've had this code in place for a couple of
> years now, and this is the first time I've seen an oops like this. I
> suspect that this may be a recent regression, but I don't know that for
> sure.

I can't think of any recent changes which could affect this.  This
part of code has remained unchanged for years at least from the
workqueue side.

> I have asked Chris and Michael to see if they can bisect it down, but
> it may be a bit before they can get that done. Any insight you might
> have in the meantime would helpful.

Yeah, I'd love to find out how reproducible the issue is.  If the
problem is rarely reproducible, it might make sense to try
instrumentation before trying bisection as it *could* be a latent bug
which has been there all along and bisecting to the commit introducing
the code wouldn't help us too much.

Thanks.

-- 
tejun

  reply	other threads:[~2015-10-31 21:31 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-10-29 14:31 timer code oops when calling mod_delayed_work Jeff Layton
2015-10-29 17:58 ` Jeff Layton
2015-10-31  2:00   ` Tejun Heo
2015-10-31 11:34     ` Jeff Layton
2015-10-31 21:31       ` Tejun Heo [this message]
2015-10-31 21:54         ` Jeff Layton
2015-11-02 19:48           ` Chris Worley
2015-11-02 19:56             ` Jeff Layton
2015-11-03  1:33               ` Jeff Layton
2015-11-03 17:55                 ` Jeff Layton
2015-11-03 22:54                   ` Tejun Heo
2015-11-04  0:06                     ` Tejun Heo
2015-11-04 11:48                       ` Jeff Layton
2015-11-04 17:15                         ` [PATCH] timer: add_timer_on() should perform proper migration Tejun Heo
2015-11-04 19:27                           ` [tip:timers/urgent] timers: Use proper base migration in add_timer_on() tip-bot for Tejun Heo
2015-11-04 19:35                           ` [PATCH] timer: add_timer_on() should perform proper migration Thomas Gleixner
2015-11-04 19:43                             ` Tejun Heo

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=20151031213107.GA23841@mtj.duckdns.org \
    --to=tj@kernel.org \
    --cc=bfields@fieldses.org \
    --cc=chris.worley@primarydata.com \
    --cc=jlayton@poochiereds.net \
    --cc=laijs@cn.fujitsu.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=michael.skralivetsky@primarydata.com \
    --cc=trond.myklebust@primarydata.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;
as well as URLs for NNTP newsgroup(s).