lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <36a08c1a-b675-84ec-ce08-2ada7223bd33@kernel.org>
Date:   Mon, 31 Oct 2022 09:34:46 +0100
From:   Jiri Slaby <jirislaby@...nel.org>
To:     Steven Rostedt <rostedt@...dmis.org>, linux-kernel@...r.kernel.org
Cc:     Linus Torvalds <torvalds@...ux-foundation.org>,
        Thomas Gleixner <tglx@...utronix.de>,
        Stephen Boyd <sboyd@...nel.org>,
        Guenter Roeck <linux@...ck-us.net>,
        Greg Kroah-Hartman <gregkh@...uxfoundation.org>
Subject: Re: [RFC][PATCH v2 26/31] timers: tty: Use del_timer_shutdown()
 before freeing timer

On 27. 10. 22, 17:05, Steven Rostedt wrote:
> From: "Steven Rostedt (Google)" <rostedt@...dmis.org>
> 
> Before a timer is freed, del_timer_shutdown() must be called.
> 
> Link: https://lore.kernel.org/all/20220407161745.7d6754b3@gandalf.local.home/
> 
> Cc: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
> Cc: Jiri Slaby <jirislaby@...nel.org>
> Signed-off-by: Steven Rostedt (Google) <rostedt@...dmis.org>

Reviewed-by: Jiri Slaby <jirislaby@...nel.org>

> ---
>   drivers/tty/n_gsm.c | 2 +-
>   drivers/tty/sysrq.c | 2 +-
>   2 files changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/tty/n_gsm.c b/drivers/tty/n_gsm.c
> index 5e516f5cac5a..1d167469a700 100644
> --- a/drivers/tty/n_gsm.c
> +++ b/drivers/tty/n_gsm.c
> @@ -2098,7 +2098,7 @@ static void gsm_dlci_free(struct tty_port *port)
>   {
>   	struct gsm_dlci *dlci = container_of(port, struct gsm_dlci, port);
>   
> -	del_timer_sync(&dlci->t1);
> +	del_timer_shutdown(&dlci->t1);
>   	dlci->gsm->dlci[dlci->addr] = NULL;
>   	kfifo_free(&dlci->fifo);
>   	while ((dlci->skb = skb_dequeue(&dlci->skb_list)))
> diff --git a/drivers/tty/sysrq.c b/drivers/tty/sysrq.c
> index d2b2720db6ca..20b1c9802506 100644
> --- a/drivers/tty/sysrq.c
> +++ b/drivers/tty/sysrq.c
> @@ -1003,7 +1003,7 @@ static void sysrq_disconnect(struct input_handle *handle)
>   
>   	input_close_device(handle);
>   	cancel_work_sync(&sysrq->reinject_work);
> -	del_timer_sync(&sysrq->keyreset_timer);
> +	del_timer_shutdown(&sysrq->keyreset_timer);
>   	input_unregister_handle(handle);
>   	kfree(sysrq);
>   }

thanks,
-- 
js
suse labs

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ