Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 296425
b: refs/heads/master
c: 10c890c
h: refs/heads/master
i:
  296423: 0107752
v: v3
  • Loading branch information
Al Viro authored and Richard Weinberger committed Mar 24, 2012
1 parent 0eeafb0 commit 6a0be69
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 10 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: 0fcd719934cd3521ae4a977f454e75e2be60b7ff
refs/heads/master: 10c890c0a303070652f5374ea31a0b29350d14d9
2 changes: 1 addition & 1 deletion trunk/arch/um/drivers/chan.h
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ extern void deactivate_chan(struct chan *chan, int irq);
extern void reactivate_chan(struct chan *chan, int irq);
extern void chan_enable_winch(struct chan *chan, struct tty_struct *tty);
extern int enable_chan(struct line *line);
extern void close_chan(struct list_head *chans, int delay_free_irq);
extern void close_chan(struct line *line);
extern int chan_window_size(struct line *line,
unsigned short *rows_out,
unsigned short *cols_out);
Expand Down
16 changes: 9 additions & 7 deletions trunk/arch/um/drivers/chan_kern.c
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@ int enable_chan(struct line *line)
return 0;

out_close:
close_chan(&line->chan_list, 0);
close_chan(line);
return err;
}

Expand Down Expand Up @@ -246,7 +246,7 @@ static void close_one_chan(struct chan *chan, int delay_free_irq)
chan->fd = -1;
}

void close_chan(struct list_head *chans, int delay_free_irq)
void close_chan(struct line *line)
{
struct chan *chan;

Expand All @@ -255,8 +255,8 @@ void close_chan(struct list_head *chans, int delay_free_irq)
* state. Then, the first one opened will have the original state,
* so it must be the last closed.
*/
list_for_each_entry_reverse(chan, chans, list) {
close_one_chan(chan, delay_free_irq);
list_for_each_entry_reverse(chan, &line->chan_list, list) {
close_one_chan(chan, 0);
}
}

Expand Down Expand Up @@ -587,10 +587,12 @@ void chan_interrupt(struct line *line, struct tty_struct *tty, int irq)
if (chan->primary) {
if (tty != NULL)
tty_hangup(tty);
close_chan(&line->chan_list, 1);
return;
if (line->chan_out != chan)
close_one_chan(line->chan_out, 1);
}
else close_one_chan(chan, 1);
close_one_chan(chan, 1);
if (chan->primary)
return;
}
out:
if (tty)
Expand Down
2 changes: 1 addition & 1 deletion trunk/arch/um/drivers/line.c
Original file line number Diff line number Diff line change
Expand Up @@ -465,7 +465,7 @@ void close_lines(struct line *lines, int nlines)
int i;

for(i = 0; i < nlines; i++)
close_chan(&lines[i].chan_list, 0);
close_chan(&lines[i]);
}

int setup_one_line(struct line *lines, int n, char *init,
Expand Down

0 comments on commit 6a0be69

Please sign in to comment.