You've already forked linux-apfs
mirror of
https://github.com/linux-apfs/linux-apfs.git
synced 2026-05-01 15:00:59 -07:00
[PATCH] new tty buffering locking fix
Change locking in the new tty buffering facility from using tty->read_lock, which is currently ignored by drivers and thus ineffective. New locking uses a new tty buffering specific lock enforced centrally in the tty buffering code. Two drivers (esp and cyclades) are updated to use the tty buffering functions instead of accessing tty buffering internals directly. This is required for the new locking to work. Minor checks for NULL buffers added to tty_prepare_flip_string/tty_prepare_flip_string_flags Signed-off-by: Paul Fulghum <paulkf@microgate.com> Cc: Alan Cox <alan@lxorguk.ukuu.org.uk> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
This commit is contained in:
committed by
Linus Torvalds
parent
546cfdf47f
commit
808249ceba
@@ -1233,7 +1233,7 @@ cyy_interrupt(int irq, void *dev_id, struct pt_regs *regs)
|
||||
}
|
||||
info->idle_stats.recv_idle = jiffies;
|
||||
}
|
||||
schedule_delayed_work(&tty->buf.work, 1);
|
||||
tty_schedule_flip(tty);
|
||||
}
|
||||
/* end of service */
|
||||
cy_writeb(base_addr+(CyRIR<<index), (save_xir & 0x3f));
|
||||
@@ -1606,7 +1606,7 @@ cyz_handle_rx(struct cyclades_port *info,
|
||||
}
|
||||
#endif
|
||||
info->idle_stats.recv_idle = jiffies;
|
||||
schedule_delayed_work(&tty->buf.work, 1);
|
||||
tty_schedule_flip(tty);
|
||||
}
|
||||
/* Update rx_get */
|
||||
cy_writel(&buf_ctrl->rx_get, new_rx_get);
|
||||
@@ -1809,7 +1809,7 @@ cyz_handle_cmd(struct cyclades_card *cinfo)
|
||||
if(delta_count)
|
||||
cy_sched_event(info, Cy_EVENT_DELTA_WAKEUP);
|
||||
if(special_count)
|
||||
schedule_delayed_work(&tty->buf.work, 1);
|
||||
tty_schedule_flip(tty);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user