Linux-ARM-Kernel Archive on
 help / color / Atom feed
From: Linus Walleij <>
To: Ladislav Michl <>
Cc:, Arnd Bergmann <>,
	Robert Schwebel <>,
	Pengutronix Kernel Team <>,
	Olof Johansson <>,,
	Linux ARM <>
Subject: Re: Hilscher NetX mach-netx refactorings
Date: Sun, 13 Jan 2019 23:39:42 +0100
Message-ID: <> (raw)
In-Reply-To: <20190113155047.GA12829@lenoch>

On Sun, Jan 13, 2019 at 4:50 PM Ladislav Michl <> wrote:
> On Sun, Jan 13, 2019 at 01:14:36PM +0100, Linus Walleij wrote:

> > > On a related note, there does appear to be active work on
> > > newer netx machines that were never upstreamed, see
> > >
> >
> > That RS485 addition to PL011 using GPIOs is a bit hacky but
> > looks like very useful for industrial applications.
> > Ladislav, have you been in contact with Hilscher?
> I guess I appeared on Cc list because of commit 797537a45450 ("amba-pl011:
> Add RS485 support (ioctl and devicetree)") from above github repo which
> is based on my hack originaly done for rPi3 as I got tired of all those
> experts implementing 'drive enable' in userspace. That's broken by design
> and works only by accident.

I suppose it is one of those GPIO hacks in userspace. Yeah that makes
the GPIO maintainer very unhappy I can tell you that :/

> But as I'm also considering every single
> device running from SD card broken by design - it was perfect match ;-)

Ha ha ;)

> But seriously, it is indeed needed for industrial applications and
> should be done a bit better - I mean regarding those delays in interrupt
> context.

I suppose this thing is a bit of an oddity since the PL011
does have an RTS signal, but in this case (for reasons such
as hardware doesn't do the right thing, or the hardware engineer
didn't care do make it possible to get the RTS line out of the
chip, or the board engineer didn't think of it) a GPIO is used
for RTS instead. So what the patch does is add that as an

There are DT bindings for RTS (etc):

I think that GPIO support code could be implemented using
the library in:

This makes it possible to handle any extra "modem control"
pins using GPIO. I think it is fine to just look for RTS if that is all
that's needed. Possibly those extra delay settings could be
added in mctrl and added as generic DT bindings as well.
(I'm not smart enough to tell if that is possible.)

Sorry for the sidetrack.

Linus Walleij

linux-arm-kernel mailing list

  reply index

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-01-12  8:35 Linus Walleij
2019-01-12 12:03 ` Arnd Bergmann
2019-01-13 12:14   ` Linus Walleij
2019-01-13 15:50     ` Ladislav Michl
2019-01-13 22:39       ` Linus Walleij [this message]
2019-01-14 11:26     ` Michael Trensch
2019-01-14 14:22       ` Linus Walleij
2019-01-15  7:05         ` Michael Trensch
2019-01-15 10:11           ` Arnd Bergmann
2019-01-15 10:14         ` Arnd Bergmann
2019-01-14 10:35 ` Sascha Hauer

Reply instructions:

You may reply publically 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:

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='' \ \ \ \ \ \ \ \ \ \

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

Linux-ARM-Kernel Archive on

Archives are clonable:
	git clone --mirror linux-arm-kernel/git/0.git
	git clone --mirror linux-arm-kernel/git/1.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 linux-arm-kernel linux-arm-kernel/ \
	public-inbox-index linux-arm-kernel

Newsgroup available over NNTP:

AGPL code for this site: git clone public-inbox