diff options
author | Alan Cox <alan@lxorguk.ukuu.org.uk> | 2009-06-11 07:24:17 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2009-06-11 11:50:56 -0400 |
commit | fcc8ac1825d3d0fb81f73bc1a80ebc863168bb56 (patch) | |
tree | 737f7209430fd319ca257df62c9b1e64587d5a8b /drivers/char/epca.c | |
parent | 65a29f60e121ae5116ac1736b50a237bf2db3225 (diff) |
tty: Add carrier processing on close to the tty_port core
Some drivers implement this internally, others miss it out. Push the
behaviour into the core code as that way everyone will do it consistently.
Update the dtr rts method to raise or lower depending upon flags. Having a
single method in this style fits most of the implementations more cleanly than
two funtions.
We need this in place before we tackle the USB side
Signed-off-by: Alan Cox <alan@lxorguk.ukuu.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/char/epca.c')
-rw-r--r-- | drivers/char/epca.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/char/epca.c b/drivers/char/epca.c index af7c13ca9493..8797b7742350 100644 --- a/drivers/char/epca.c +++ b/drivers/char/epca.c | |||
@@ -745,7 +745,7 @@ static int epca_carrier_raised(struct tty_port *port) | |||
745 | return 0; | 745 | return 0; |
746 | } | 746 | } |
747 | 747 | ||
748 | static void epca_raise_dtr_rts(struct tty_port *port) | 748 | static void epca_dtr_rts(struct tty_port *port, int onoff) |
749 | { | 749 | { |
750 | } | 750 | } |
751 | 751 | ||
@@ -925,7 +925,7 @@ static const struct tty_operations pc_ops = { | |||
925 | 925 | ||
926 | static const struct tty_port_operations epca_port_ops = { | 926 | static const struct tty_port_operations epca_port_ops = { |
927 | .carrier_raised = epca_carrier_raised, | 927 | .carrier_raised = epca_carrier_raised, |
928 | .raise_dtr_rts = epca_raise_dtr_rts, | 928 | .dtr_rts = epca_dtr_rts, |
929 | }; | 929 | }; |
930 | 930 | ||
931 | static int info_open(struct tty_struct *tty, struct file *filp) | 931 | static int info_open(struct tty_struct *tty, struct file *filp) |