lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20070718223613.143bb3b6@the-village.bc.nu>
Date:	Wed, 18 Jul 2007 22:36:13 +0100
From:	Alan Cox <alan@...rguk.ukuu.org.uk>
To:	Linus Torvalds <torvalds@...ux-foundation.org>
Cc:	Paul Fulghum <paulkf@...rogate.com>,
	James Simmons <jsimmons@...radead.org>,
	Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
	Linux console project <linuxconsole-dev@...ts.sourceforge.net>
Subject: Re: [PATCH] Use tty_schedule in VT code.

> If a tty driver has marked itself low-latency, it's still wrong to do the 
> flush_to_ldisc() from interrupt context if a console event happens in 
> interrupt context.

It should be ok nowdays. Calling ld->receive() paths directly from an IRQ
is verboted however.

> I thought that was the whole *point* of the difference between 
> "tty_schedule_flip()" and "con_schedule_flip()", as far as I know. The 
> "con_schedule_flip()" can be called from any context (console messages), 
> while "tty_schedule_flip()" is only called from well-behaved tty layer.

I have no idea of the history of con_schedule_flip and I leave it alone 8)
> 
> But I really don't know. I used to be involved with the tty layer, these 
> days I'd rather avoid it. This "simple" patch seems to be anything but, 
> and I'd like somebody to just make sure that all the issues are taken care 
> of.
> 
> Alan?

For tty it is ok to call tty_flip_buffer_push from an IRQ. It is also ok
for this to do stuff based on the low latency flag. Any private internal
knowledge of that happens is at the drivers peril and may change.

We *need* low latency to do MIDI, Digitrax DCC and a few other things.

A driver which sets ->low_latency must allow its own write() method to be
called back as a result of calling tty_flip_buffer_push, and that
requires care on driver coding. (Arguably we should have a ->echo()
method for this but that opens other cans of worms)

Alan

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ