Commit 083cfcf3 authored by Jiri Slaby (SUSE)'s avatar Jiri Slaby (SUSE) Committed by Greg Kroah-Hartman
Browse files

tty: tty_buffer: use bool for 'restart' in tty_buffer_unlock_exclusive()

parent c38f45ef
Loading
Loading
Loading
Loading
+2 −3
Original line number Diff line number Diff line
@@ -69,12 +69,11 @@ EXPORT_SYMBOL_GPL(tty_buffer_lock_exclusive);
void tty_buffer_unlock_exclusive(struct tty_port *port)
{
	struct tty_bufhead *buf = &port->buf;
	int restart;

	restart = buf->head->commit != buf->head->read;
	bool restart = buf->head->commit != buf->head->read;

	atomic_dec(&buf->priority);
	mutex_unlock(&buf->lock);

	if (restart)
		queue_work(system_unbound_wq, &buf->work);
}