issues
search
oscourse-tsinghua
/
rcore_plus
Rust version of THU uCore OS. Linux compatible.
MIT License
172
stars
26
forks
source link
Discussion of socket implementation
#10
Closed
wangrunji0408
closed
5 years ago
wangrunji0408
commented
5 years ago
Is it possible to treat a socket as a file directly?
sockfs
:
impl INode for Socket
If we can, what should be added to the current VFS?
If not, can we design a socket trait to isolate syscall and network stack?
@jiegec Orz
jiegec
commented
5 years ago
Is it possible to treat a socket as a file directly?
It let me think of Plan9 OS.
Hard, the syscalls needed to support have different semantics, but easy if we just throw then away.
If we can, what should be added to the current VFS?
/dev/tcp/addr/port? (as in bash)
Use ioctl for specific operations other than writing and reading?
If not, can we design a socket trait to isolate syscall and network stack?
Yes. I think we can delegate syscall to each type of socket struct.
wangrunji0408
commented
5 years ago
👍Nice!
sockfs
:impl INode for Socket
@jiegec Orz