[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20070425125214.GB94@tv-sign.ru>
Date: Wed, 25 Apr 2007 16:52:14 +0400
From: Oleg Nesterov <oleg@...sign.ru>
To: Jarek Poplawski <jarkao2@...pl>
Cc: Andrew Morton <akpm@...ux-foundation.org>,
David Howells <dhowells@...hat.com>,
David Miller <davem@...emloft.net>,
Ingo Molnar <mingo@...e.hu>, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] cancel_delayed_work: use del_timer() instead of del_timer_sync()
On 04/25, Jarek Poplawski wrote:
>
> On Wed, Apr 25, 2007 at 01:50:34AM +0400, Oleg Nesterov wrote:
> > del_timer_sync() buys nothing for cancel_delayed_work(), but it is less
> > efficient since it locks the timer unconditionally, and may wait for the
> > completion of the delayed_work_timer_fn().
>
> I'm not sure what is the main aim of this patch.
optimization
> It seems this
> change cannot do any harm, but anyway it could change a few
> things, e.g. with current version of cancel_rearming_delayed_work
> some flush_workqueue could be done needlessly, before the work
> is queued from timer.
I don't think so... Could you clarify?
> It's not a big deal here, but if anybody
> did something like this without loop - it could matter.
>
> So, probably a lot of current code should be checked, before
> applying and I doubt the gain is worth of this. Maybe, for
> safety, make this with new name as an alternative and
> deprecate the current version?
This change should not make any visible difference for the callers,
otherwise it is buggy.
Oleg.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists