mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
To: Fan Wu <12321260@zju.edu.cn>
Cc: Jiri Slaby <jirislaby@kernel.org>, Fan Wu <fanwu01@zju.edu.cn>,
	Frank Li <Frank.Li@nxp.com>,
	Sascha Hauer <s.hauer@pengutronix.de>,
	Pengutronix Kernel Team <kernel@pengutronix.de>,
	Fabio Estevam <festevam@gmail.com>,
	linux-serial@vger.kernel.org, linux-kernel@vger.kernel.org,
	imx@lists.linux.dev, linux-arm-kernel@lists.infradead.org,
	stable@vger.kernel.org
Subject: Re: [PATCH] serial: imx: cancel RS485 trigger hrtimers in shutdown and remove
Date: Thu, 1 Oct 2026 10:57:56 +0200	[thread overview]
Message-ID: <2026100149-constrict-frail-4f4e@gregkh> (raw)
In-Reply-To: <C6A3233A-A352-45AC-A498-0DED1EC57147@zju.edu.cn>

On Wed, Aug 19, 2026 at 02:39:45PM +0800, Fan Wu wrote:
> 
> > On Aug 19, 2026, at 12:26, Jiri Slaby <jirislaby@kernel.org> wrote:
> > 
> >> serial core does not call the
> >> driver shutdown on every path that reaches remove().
> > 
> > Could you be more specific on what path it does not?
> > 
> > thanks,
> > -- 
> > js
> > suse labs
> 
> Hi Jiri
> 
> Yes. The relevant path is a console port whose last TTY user closes it
> before the device is unbound.
> 
> tty_port_shutdown() skips port->ops->shutdown() for console ports. The
> last close then clears the active state and dissociates the TTY, so the
> later tty_port_tty_vhangup() in the remove path has no TTY to hang up
> and cannot invoke the driver shutdown.  That is the path the cancel in
> imx_uart_remove() covers.
> 
> trigger_stop_tx can already be pending at that point: after TXDC,
> imx_uart_stop_tx() starts it for delay_rts_after_send, whereas the close
> path only waits for TXDC.
> 
> I can add this to the changelog if you would prefer the rationale to be
> spelled out there.

Yes, please do so.

thanks,

greg k-h

  reply	other threads:[~2026-10-01  8:58 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-08-19  2:19 Fan Wu
2026-08-19  4:26 ` Jiri Slaby
2026-08-19  6:39   ` Fan Wu
2026-10-01  8:57     ` Greg Kroah-Hartman [this message]
2026-09-23 10:17 ` Greg Kroah-Hartman
2026-09-27 14:35   ` Fan Wu
2026-09-27 16:28     ` Greg Kroah-Hartman
2026-09-28  1:21       ` Fan Wu

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=2026100149-constrict-frail-4f4e@gregkh \
    --to=gregkh@linuxfoundation.org \
    --cc=12321260@zju.edu.cn \
    --cc=Frank.Li@nxp.com \
    --cc=fanwu01@zju.edu.cn \
    --cc=festevam@gmail.com \
    --cc=imx@lists.linux.dev \
    --cc=jirislaby@kernel.org \
    --cc=kernel@pengutronix.de \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-serial@vger.kernel.org \
    --cc=s.hauer@pengutronix.de \
    --cc=stable@vger.kernel.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

all inboxes | Powered by JetHome®