tt_ioctl
Poul-Henning Kamp
phk at phk.freebsd.dk
Tue Apr 8 16:16:36 UTC 2008
In message <18427.36758.266944.74378 at gromit.timing.com>, John E Hein writes:
>Back in 2005-10, phk added the tt_{open,ioctl,etc.} inline calls in
>sys/tty.h allowing drivers that hook into the tty layer a way to
>override or supplement the basic tty functions with their own
>flavoring.
>
>They were also connected up in kern/tty.c - well most of them.
>
>tt_ioctl remains unused.
>
>What about the following:
That was sort of deliberate, based on a theory that our ttys should
behave as much the same as possible, no matter what driver was behind
them, and therefore all ioctls should be handled as linedisc.
If a driver needs a special ioctl to do something like load firmware,
that should, IMO, not happen on a tty but on a special control device
which is not used for login-sessions.
If for no other reason, then for purely security reasons.
As always, I'm prepared to be persuaded by good examples :-)
--
Poul-Henning Kamp | UNIX since Zilog Zeus 3.20
phk at FreeBSD.ORG | TCP/IP since RFC 956
FreeBSD committer | BSD since 4.3-tahoe
Never attribute to malice what can adequately be explained by incompetence.
More information about the freebsd-arch
mailing list