linux-serial.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Lukas Wunner <lukas-JFq808J9C/izQB+pC5nmwQ@public.gmane.org>
To: Greg Kroah-Hartman
	<gregkh-hQyY1W1yCW8ekmWlsbkhG0B+6BGkLq7r@public.gmane.org>
Cc: Jiri Slaby <jslaby-IBi9RG/b67k@public.gmane.org>,
	Sascha Hauer <s.hauer-bIcnvbaLZ9MEGnE8C9+IrQ@public.gmane.org>,
	Uwe Kleine-Koenig
	<u.kleine-koenig-bIcnvbaLZ9MEGnE8C9+IrQ@public.gmane.org>,
	Mark Jackson <mpfj-2FZW7xY0fHgqdlJmJB21zg@public.gmane.org>,
	Michal Oleszczyk
	<oleszczyk.m-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>,
	linux-serial-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	Rob Herring <robh+dt-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>,
	Mark Rutland <mark.rutland-5wv7dgnIgG8@public.gmane.org>,
	devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	Jan Kiszka <jan.kiszka-kv7WeFo6aLtBDgjK7y7TUQ@public.gmane.org>,
	Richard Genoud
	<richard.genoud-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
Subject: [PATCH 0/5] rs485 properties: platform agnosticism + RTS polarity
Date: Wed, 8 Nov 2017 11:32:34 +0100	[thread overview]
Message-ID: <cover.1510134353.git.lukas@wunner.de> (raw)

Rework the common helper function for retrieving rs485 properties
to be platform agnostic (patch [1/5]) and to allow specifying the
RTS polarity (patch [2/5] and [3/5]).

Amend the fsl_lpuart and imx drivers to take advantage of this
and fix a bunch of bugs while at it (patch [4/5] and [5/5]).

Note that Michal Oleszczyk posted a patch yesterday which documents
the "rs485-rts-active-high" property supported by omap-serial in a
way which suggests that *all* drivers default to active low, which
is not the case (all other drivers default to active high).
I think the present series is a better approach, but let's have a
technical discussion about that.

I posted an earlier version of patch [1/5] a while back but withdrew
it because I wanted to change uart_get_rs485_mode() to take a
struct dev and a struct serial_rs485, instead of a struct uart_port
(which seemed too fragile on second thought).  That change has been
made now.

Thanks,

Lukas


Lukas Wunner (5):
  serial: Make retrieval of rs485 properties platform-agnostic
  dt-bindings: serial: Add common rs485 binding for RTS polarity
  serial: core: Support common rs485 binding for RTS polarity
  serial: fsl_lpuart: Support common rs485 binding for RTS polarity
  serial: imx: Support common rs485 binding for RTS polarity

 .../devicetree/bindings/serial/fsl-imx-uart.txt    |  3 ++-
 .../devicetree/bindings/serial/fsl-lpuart.txt      |  3 ++-
 .../devicetree/bindings/serial/omap_serial.txt     |  1 +
 Documentation/devicetree/bindings/serial/rs485.txt |  1 +
 drivers/tty/serial/atmel_serial.c                  |  2 +-
 drivers/tty/serial/fsl_lpuart.c                    | 15 ++++----------
 drivers/tty/serial/imx.c                           | 11 ++++++++---
 drivers/tty/serial/omap-serial.c                   | 11 +++++++----
 drivers/tty/serial/serial_core.c                   | 23 +++++++++++++++-------
 include/linux/serial_core.h                        |  3 +--
 10 files changed, 43 insertions(+), 30 deletions(-)

-- 
2.11.0

--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

             reply	other threads:[~2017-11-08 10:32 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-11-08 10:32 Lukas Wunner [this message]
     [not found] ` <cover.1510134353.git.lukas-JFq808J9C/izQB+pC5nmwQ@public.gmane.org>
2017-11-08 10:32   ` [PATCH 3/5] serial: core: Support common rs485 binding for RTS polarity Lukas Wunner
     [not found]     ` <e85e3d02a45e79e410b6606d8fdec347f03053f4.1510134353.git.lukas-JFq808J9C/izQB+pC5nmwQ@public.gmane.org>
2017-11-08 11:13       ` Uwe Kleine-König
     [not found]         ` <20171108111355.pzcrvdgqqeleinss-bIcnvbaLZ9MEGnE8C9+IrQ@public.gmane.org>
2017-11-08 17:33           ` Lukas Wunner
2017-11-08 10:32   ` [PATCH 5/5] serial: imx: " Lukas Wunner
2017-11-08 10:32   ` [PATCH 4/5] serial: fsl_lpuart: " Lukas Wunner
2017-11-08 10:32   ` [PATCH 2/5] dt-bindings: serial: Add " Lukas Wunner
     [not found]     ` <60d6ef2cf6c599d2d8717250fe52a0ccb1272be8.1510134353.git.lukas-JFq808J9C/izQB+pC5nmwQ@public.gmane.org>
2017-11-10 21:58       ` Rob Herring

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=cover.1510134353.git.lukas@wunner.de \
    --to=lukas-jfq808j9c/izqb+pc5nmwq@public.gmane.org \
    --cc=devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=gregkh-hQyY1W1yCW8ekmWlsbkhG0B+6BGkLq7r@public.gmane.org \
    --cc=jan.kiszka-kv7WeFo6aLtBDgjK7y7TUQ@public.gmane.org \
    --cc=jslaby-IBi9RG/b67k@public.gmane.org \
    --cc=linux-serial-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=mark.rutland-5wv7dgnIgG8@public.gmane.org \
    --cc=mpfj-2FZW7xY0fHgqdlJmJB21zg@public.gmane.org \
    --cc=oleszczyk.m-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
    --cc=richard.genoud-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
    --cc=robh+dt-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org \
    --cc=s.hauer-bIcnvbaLZ9MEGnE8C9+IrQ@public.gmane.org \
    --cc=u.kleine-koenig-bIcnvbaLZ9MEGnE8C9+IrQ@public.gmane.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).