From: Tejun Heo <tj@kernel.org>
To: Maxim Patlasov <MPatlasov@parallels.com>
Cc: linux-mm@kvack.org, akpm@linux-foundation.org,
fengguang.wu@intel.com, jack@suse.cz,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] writeback: fix delayed sync(2)
Date: Fri, 20 Sep 2013 18:02:56 -0500 [thread overview]
Message-ID: <20130920230256.GB8763@mtj.dyndns.org> (raw)
In-Reply-To: <20130920125029.17356.66782.stgit@dhcp-10-30-17-2.sw.ru>
Hello,
On Fri, Sep 20, 2013 at 04:52:26PM +0400, Maxim Patlasov wrote:
> @@ -294,7 +294,7 @@ void bdi_wakeup_thread_delayed(struct backing_dev_info *bdi)
> unsigned long timeout;
>
> timeout = msecs_to_jiffies(dirty_writeback_interval * 10);
> - mod_delayed_work(bdi_wq, &bdi->wb.dwork, timeout);
> + queue_delayed_work(bdi_wq, &bdi->wb.dwork, timeout);
Hmmm... this at least requires comment explaining why
mod_delayed_work() doesn't work here. Also, I wonder whether what we
need is a function which either queues if !pending and shortens timer
if pending. This is a relatively common pattern and the suggested fix
is subtle and fragile.
Thanks.
--
tejun
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
prev parent reply other threads:[~2013-09-20 23:03 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-09-20 12:52 [PATCH] writeback: fix delayed sync(2) Maxim Patlasov
2013-09-20 23:02 ` Tejun Heo [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=20130920230256.GB8763@mtj.dyndns.org \
--to=tj@kernel.org \
--cc=MPatlasov@parallels.com \
--cc=akpm@linux-foundation.org \
--cc=fengguang.wu@intel.com \
--cc=jack@suse.cz \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
/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).