From: One Thousand Gnomes <gnomes@lxorguk.ukuu.org.uk>
To: Rob Herring <robh@kernel.org>
Cc: Alan Cox <alan@linux.intel.com>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
Jiri Slaby <jslaby@suse.com>,
linux-serial@vger.kernel.org, linux-kernel@vger.kernel.org,
Peter Hurley <peter@hurleysoftware.com>
Subject: Re: [PATCH 1/2] tty: serial_core: convert uart_open to use tty_port_open
Date: Wed, 24 Aug 2016 14:46:44 +0100 [thread overview]
Message-ID: <20160824144644.43543830@lxorguk.ukuu.org.uk> (raw)
In-Reply-To: <20160822223910.24453-1-robh@kernel.org>
On Mon, 22 Aug 2016 17:39:09 -0500
Rob Herring <robh@kernel.org> wrote:
> tty_port_open handles much of the common parts of tty opening. Convert
> uart_open to use it and move the serial_core specific parts into
> tty_port.activate function. This will be needed to use tty_port functions
> directly from in kernel clients.
>
> The tricky part is uart_port_startup can return positive values to allow
> setserial to configure the port. We now return the positive value to
> tty_port_open so that the tty is not marked as initialized and then set the
> return value in uart_open to 0.
>
> Cc: Alan Cox <alan@linux.intel.com>
> Cc: Peter Hurley <peter@hurleysoftware.com>
> Signed-off-by: Rob Herring <robh@kernel.org>
> ---
> In looking at using tty_port for uart slaves, this is the first thing I
> hit. serial_core doesn't even use the 2 functions that already exist for
> tty_port and are needed.
>
> I've tested this on QEMU with pl011 and 8250 UARTs using setserial, but
> I'm not sure what are all the tricky cases to handle.
>
> Greg, Don't apply these without comment from Alan and Peter.
Originally I didn't convert them because the lockign was incompatible.
That looks to have been fixed by other changes. This is definitely the
right direction irrespective of the uart slave discussion.
Acked-by: Alan Cox <alan@linux.intel.com>
prev parent reply other threads:[~2016-08-24 13:49 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-08-22 22:39 Rob Herring
2016-08-22 22:39 ` [PATCH 2/2] tty: serial_core: convert uart_close to use tty_port_close Rob Herring
2016-08-24 13:46 ` One Thousand Gnomes [this message]
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=20160824144644.43543830@lxorguk.ukuu.org.uk \
--to=gnomes@lxorguk.ukuu.org.uk \
--cc=alan@linux.intel.com \
--cc=gregkh@linuxfoundation.org \
--cc=jslaby@suse.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-serial@vger.kernel.org \
--cc=peter@hurleysoftware.com \
--cc=robh@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
Powered by JetHome