[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20221121150833.61ab3b01@gandalf.local.home>
Date: Mon, 21 Nov 2022 15:08:33 -0500
From: Steven Rostedt <rostedt@...dmis.org>
To: Thomas Gleixner <tglx@...utronix.de>
Cc: LKML <linux-kernel@...r.kernel.org>,
Linus Torvalds <torvalds@...uxfoundation.org>,
Anna-Maria Behnsen <anna-maria@...utronix.de>,
Peter Zijlstra <peterz@...radead.org>,
Stephen Boyd <sboyd@...nel.org>,
Guenter Roeck <linux@...ck-us.net>,
Andrew Morton <akpm@...ux-foundation.org>,
Julia Lawall <Julia.Lawall@...ia.fr>,
Arnd Bergmann <arnd@...db.de>,
Viresh Kumar <viresh.kumar@...aro.org>,
Marc Zyngier <maz@...nel.org>,
Marcel Holtmann <marcel@...tmann.org>,
Johan Hedberg <johan.hedberg@...il.com>,
Luiz Augusto von Dentz <luiz.dentz@...il.com>,
linux-bluetooth@...r.kernel.org,
"David S. Miller" <davem@...emloft.net>,
Eric Dumazet <edumazet@...gle.com>,
Jakub Kicinski <kuba@...nel.org>,
Paolo Abeni <pabeni@...hat.com>, netdev@...r.kernel.org
Subject: Re: [patch 04/15] timers: Get rid of del_singleshot_timer_sync()
On Tue, 15 Nov 2022 21:28:39 +0100 (CET)
Thomas Gleixner <tglx@...utronix.de> wrote:
> del_singleshot_timer_sync() used to be an optimization for deleting timers
> which are not rearmed from the timer callback function.
>
> This optimization turned out to be broken and got mapped to
> del_timer_sync() about 17 years ago.
>
> Get rid of the undocumented indirection and use del_timer_sync() directly.
>
> No functional change.
>
> Signed-off-by: Thomas Gleixner <tglx@...utronix.de>
>
> --- a/net/sunrpc/xprt.c
> +++ b/net/sunrpc/xprt.c
> @@ -1164,7 +1164,7 @@ xprt_request_enqueue_receive(struct rpc_
> spin_unlock(&xprt->queue_lock);
>
> /* Turn off autodisconnect */
> - del_singleshot_timer_sync(&xprt->timer);
> + del_timer_sync(&xprt->timer);
And this was not even a single shot timer. It used the
del_singleshot_timer_sync() function because of incorrect assumptions.
Link: https://lore.kernel.org/all/20221105060155.047357452@goodmis.org/
0f9dc2b16884b ("RPC: Clean up socket autodisconnect")
55c888d6d09a0 ("timers fixes/improvements")
Reviewed-by: Steven Rostedt (Google) <rostedt@...dmis.org>
-- Steve
> return 0;
> }
>
Powered by blists - more mailing lists