Andreas Kling
e9b948103d
Add a /dev/pts filesystem and make PTY allocation dynamic.
...
You can now open as many PTY pairs as you like. Well, it's actually capped
at 8 for now, but it's just a constant and trivial to change.
Unregistering a PTY pair is untested because I didn't want to start
mucking with that in Terminal right now.
2019-01-30 00:49:20 +01:00
Andreas Kling
b896d4b237
PTY: Disallow infinite writing to slaves.
...
This way we don't buffer ungodly amounts of output in the kernel when doing
e.g "cat /dev/random" on a PTY.
2019-01-25 00:13:54 +01:00
Andreas Kling
310a5f4199
Let each MasterPTY create its slave.
2019-01-16 02:11:50 +01:00
Andreas Kling
e452303c66
Allow character devices to block write attempts until there is more space.
2019-01-15 09:17:22 +01:00
Andreas Kling
49b63281a0
Make it possible for a process to switch controlling terminals.
...
Via the TIOCSCTTY and TIOCNOTTY ioctls.
2019-01-15 08:49:24 +01:00
Andreas Kling
2f74c2f430
Add basic PTY support.
...
For now, there are four hard-coded PTYs: /dev/pt{m,s}[0123]
Use this in the Terminal to open a pty pair and spawn a shell.
2019-01-15 06:30:19 +01:00