summaryrefslogtreecommitdiffstats
path: root/sys/i386
diff options
context:
space:
mode:
authored <ed@FreeBSD.org>2017-04-06 15:10:36 +0000
committered <ed@FreeBSD.org>2017-04-06 15:10:36 +0000
commit9a92d335245044a13a361c9927ac09113ff68488 (patch)
tree12314ff4954fa44cc6fd589d1373fc79e7f5cd64 /sys/i386
parent8575dbd2dd357f966f2adfcda71f98f1f8992fe1 (diff)
downloadFreeBSD-src-9a92d335245044a13a361c9927ac09113ff68488.zip
FreeBSD-src-9a92d335245044a13a361c9927ac09113ff68488.tar.gz
Bring kernel space CloudABI code in sync with HEAD.
MFC r312353, r312354 and r312355: Sync in the latest CloudABI generated source files. Languages like C++17 and Go provide direct support for slice types: pointer/length pairs. The CloudABI generator now has more complete for this, meaning that for the C binding, pointer/length pairs now use an automatic naming scheme of ${name} and ${name}_len. Apart from this change and some reformatting, the ABI definitions are identical. Binary compatibility is preserved entirely. MFC r315700: Make file descriptor passing work for CloudABI's sendmsg(). Reduce the potential amount of code duplication between cloudabi32 and cloudabi64 by creating a cloudabi_sock_recv() utility function. The cloudabi32 and cloudabi64 modules will then only contain code to convert the iovecs to the native pointer size. In cloudabi_sock_recv(), we can now construct an SCM_RIGHTS cmsghdr in an mbuf and pass that on to kern_sendit(). MFC r315736: Make file descriptor passing for CloudABI's recvmsg() work. Similar to the change for sendmsg(), create a pointer size independent implementation of recvmsg() and let cloudabi32 and cloudabi64 call into it. In case userspace requests one or more file descriptors, call kern_recvit() in such a way that we get the control message headers in an mbuf. Iterate over all of the headers and copy the file descriptors to userspace.
Diffstat (limited to 'sys/i386')
-rw-r--r--sys/i386/cloudabi32/cloudabi32_sysvec.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/i386/cloudabi32/cloudabi32_sysvec.c b/sys/i386/cloudabi32/cloudabi32_sysvec.c
index 118b80e..45b9e5c 100644
--- a/sys/i386/cloudabi32/cloudabi32_sysvec.c
+++ b/sys/i386/cloudabi32/cloudabi32_sysvec.c
@@ -156,7 +156,7 @@ cloudabi32_thread_setregs(struct thread *td,
/* Perform standard register initialization. */
stack.ss_sp = TO_PTR(attr->stack);
- stack.ss_size = attr->stack_size - sizeof(args);
+ stack.ss_size = attr->stack_len - sizeof(args);
cpu_set_upcall(td, TO_PTR(attr->entry_point), NULL, &stack);
/*
OpenPOWER on IntegriCloud