From: Peter Hurley <peter@hurleysoftware.com>
To: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: One Thousand Gnomes <gnomes@lxorguk.ukuu.org.uk>,
linux-kernel@vger.kernel.org, linux-serial@vger.kernel.org,
Peter Hurley <peter@hurleysoftware.com>
Subject: [PATCH v2] fix serial console resume-from-suspend
Date: Wed, 9 Jul 2014 09:21:13 -0400 [thread overview]
Message-ID: <1404912074-9729-1-git-send-email-peter@hurleysoftware.com> (raw)
Greg,
This v2 respin removes the dependency on the patch to which Alan objected
(regarding not hanging up remote serial console modems).
This patch fixes bugzilla #69751, where the serial console is garbled
after resume from suspend.
Although this was originally reported as a regression, this bug is
actually caused when a user-space process (such as setserial or stty)
opens and then closes the associated tty. The resultant tty port shutdown
caused the console termios settings to be lost, and thus uninitialized when
the console was subsequently suspended and then resumed (and there was not
an associated open tty).
This patch preserves the cflag settings from the associated tty as the
console cflags (which reflect the current line settings anyway). The
console cflags are already used to restore the console line settings if
there is not an associated open tty.
The side-effect of this patch is that the serial console line settings
are persistent. Originally, only the first-time initialization of the
associated port inherited the console line settings; now, each time the
associated port is initialized to the most recent line settings.
Peter Hurley (1):
serial: core: Preserve termios c_cflag for console resume
drivers/tty/serial/serial_core.c | 3 +++
1 file changed, 3 insertions(+)
--
2.0.0
next reply other threads:[~2014-07-09 13:21 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-07-09 13:21 Peter Hurley [this message]
2014-07-09 13:21 ` [PATCH v2] serial: core: Preserve termios c_cflag for console resume Peter Hurley
2014-07-09 13:28 ` One Thousand Gnomes
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=1404912074-9729-1-git-send-email-peter@hurleysoftware.com \
--to=peter@hurleysoftware.com \
--cc=gnomes@lxorguk.ukuu.org.uk \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-serial@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;
as well as URLs for NNTP newsgroup(s).