Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 95225
b: refs/heads/master
c: a5b08c6
h: refs/heads/master
i:
  95223: 2460769
v: v3
  • Loading branch information
Alan Cox authored and Linus Torvalds committed Apr 30, 2008
1 parent 359f6bb commit 34cf5e9
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: bbbbb96f5ea84971545ecae5a9ec50387cd9c6a3
refs/heads/master: a5b08c66194fba02a865b397579b7204688bcb1e
7 changes: 4 additions & 3 deletions trunk/drivers/char/serial167.c
Original file line number Diff line number Diff line change
Expand Up @@ -1060,7 +1060,7 @@ static void config_setup(struct cyclades_port *info)

} /* config_setup */

static void cy_put_char(struct tty_struct *tty, unsigned char ch)
static int cy_put_char(struct tty_struct *tty, unsigned char ch)
{
struct cyclades_port *info = (struct cyclades_port *)tty->driver_data;
unsigned long flags;
Expand All @@ -1070,21 +1070,22 @@ static void cy_put_char(struct tty_struct *tty, unsigned char ch)
#endif

if (serial_paranoia_check(info, tty->name, "cy_put_char"))
return;
return 0;

if (!info->xmit_buf)
return;

local_irq_save(flags);
if (info->xmit_cnt >= PAGE_SIZE - 1) {
local_irq_restore(flags);
return;
return 0;
}

info->xmit_buf[info->xmit_head++] = ch;
info->xmit_head &= PAGE_SIZE - 1;
info->xmit_cnt++;
local_irq_restore(flags);
return 1;
} /* cy_put_char */

static void cy_flush_chars(struct tty_struct *tty)
Expand Down

0 comments on commit 34cf5e9

Please sign in to comment.