aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/char/moxa.c
diff options
context:
space:
mode:
authorAlan Cox <alan@redhat.com>2008-07-22 06:18:03 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2008-07-22 16:03:28 -0400
commit9e98966c7bb94355689478bc84cc3e0c190f977e (patch)
tree928aebbfee524a48aa94a3d3def5249c8846a79a /drivers/char/moxa.c
parentabbe629ae4011d2020047f41bea9f9e4b0ec4361 (diff)
tty: rework break handling
Some hardware needs to do break handling itself and may have partial support only. Make break_ctl return an error code. Add a tty driver flag so you can indicate driver hardware side break support. Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/char/moxa.c')
-rw-r--r--drivers/char/moxa.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/char/moxa.c b/drivers/char/moxa.c
index 2bba250ffc8e..d3d7864e0c1e 100644
--- a/drivers/char/moxa.c
+++ b/drivers/char/moxa.c
@@ -374,12 +374,13 @@ copy:
374 return ret; 374 return ret;
375} 375}
376 376
377static void moxa_break_ctl(struct tty_struct *tty, int state) 377static int moxa_break_ctl(struct tty_struct *tty, int state)
378{ 378{
379 struct moxa_port *port = tty->driver_data; 379 struct moxa_port *port = tty->driver_data;
380 380
381 moxafunc(port->tableAddr, state ? FC_SendBreak : FC_StopBreak, 381 moxafunc(port->tableAddr, state ? FC_SendBreak : FC_StopBreak,
382 Magic_code); 382 Magic_code);
383 return 0;
383} 384}
384 385
385static const struct tty_operations moxa_ops = { 386static const struct tty_operations moxa_ops = {