pub fn sys_socket(abi: &mut LinuxRiscv64Abi, trapframe: &mut Trapframe) -> usizeExpand description
Linux sys_socket implementation
Creates a socket endpoint for communication. Now properly integrated with NetworkManager and VFS for Unix domain socket support.
Arguments:
- abi: LinuxRiscv64Abi context
- trapframe: Trapframe containing syscall arguments
- arg0: domain (communication domain, e.g., AF_UNIX, AF_INET)
- arg1: type (socket type, e.g., SOCK_STREAM, SOCK_DGRAM)
- arg2: protocol (protocol to use, usually 0)
Returns:
- file descriptor on success
- usize::MAX (Linux -1) on error