From: Andrew Morton <akpm@linux-foundation.org>
To: Michael Westermann <michael@dvmwest.de>
Cc: linux-kernel@vger.kernel.org, Russell King <rmk@arm.linux.org.uk>
Subject: Re: DTR/DSR Patch
Date: Wed, 12 Sep 2007 17:38:17 -0700 [thread overview]
Message-ID: <20070912173817.7ca5c3dc.akpm@linux-foundation.org> (raw)
In-Reply-To: <20070831131741.GA14569@dvmwest.dvmwest.de>
On Fri, 31 Aug 2007 15:17:41 +0200
Michael Westermann <michael@dvmwest.de> wrote:
> Hello,
>
> I make driver for Point of Sale Printer, a wide range of Printer use
> only a DTR/DSR hardware-handshaking. When I use a handshaking in the
> userspace, the Printr has a overrun problem and our customer has a
> problem with the tax office.
>
> my Patch relaize a simple DTR/DSR handhake with a small change of the
> code. The change auf the userspace is very simple. e.g.
>
>
> cflags |= CDTRDSR;
>
> The change of the stty tool at 2 lines.
>
googling for CDTRDSR is useful. I see from
http://lkml.org/lkml/2006/12/10/49 that Russell was generally supportive,
but requested changes which afaict you have implemented here?
> --- linux-2.6/include/asm-i386/termbits.h 2007-05-21 10:37:10.000000000 +0200
> +++ linux-2.6.dsr_test/include/asm-i386/termbits.h 2007-08-28 11:58:43.000000000 +0200
> @@ -157,6 +157,7 @@
> #define B3500000 0010016
> #define B4000000 0010017
> #define CIBAUD 002003600000
> +#define CDTRDSR 004000000000 /* dtrdsr flow control */
> #define CMSPAR 010000000000 /* mark or space (stick) parity */
> #define CRTSCTS 020000000000 /* flow control */
>
This will break all architectures except for i386. So for now I guess we
can do this:
--- a/include/linux/termios.h~serial-8250-implement-dtr-dsr-handshaking-fix
+++ a/include/linux/termios.h
@@ -4,4 +4,8 @@
#include <linux/types.h>
#include <asm/termios.h>
+#ifndef CDTRDSR
+#define CDTRDSR 0 /* remove this when all architectures have a definition */
+#endif
+
#endif
_
but that's temporary. If we decide to proceed with this change then we
should add CDTRDSR to each arch's termbits.h. That'll be pretty
straightforward to arrange.
Actually, let's spam them ...
--- a/include/linux/termios.h~serial-8250-implement-dtr-dsr-handshaking-fix
+++ a/include/linux/termios.h
@@ -4,4 +4,9 @@
#include <linux/types.h>
#include <asm/termios.h>
+#ifndef CDTRDSR
+#warning This architecture should implement CDTRDSR
+#define CDTRDSR 0 /* remove this when all architectures have a definition */
+#endif
+
#endif
_
next prev parent reply other threads:[~2007-09-13 0:39 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-08-31 13:17 DTR/DSR Patch Michael Westermann
2007-09-13 0:38 ` Andrew Morton [this message]
2007-09-13 7:47 ` Russell King
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=20070912173817.7ca5c3dc.akpm@linux-foundation.org \
--to=akpm@linux-foundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=michael@dvmwest.de \
--cc=rmk@arm.linux.org.uk \
/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