tech-kern archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: New line discipline flag to prevent userland open/close of the device



On Sun, 29 Oct 2017, Martin Husemann wrote:

> Now for those devices we definitively do not want userland access to the com
> device. This would be pretty easy if we add another flag to the tty
> line disciplines t_state member, like TS_NO_USER_OPEN. Then we could
> modify comclose like:

> Does that sound good? Other suggestions?

One other idea we did on sunos, but I don't know if it'll work on netbsd, 
is to have the keyboard/mouse driver do an exclusive open on the serial 
device that way everyone else who tries to open it will get an EBUSY.  
That should work with all the different serial drivers without having to 
modify each one's open routine.

Eduardo


Home | Main Index | Thread Index | Old Index