sembuf
struct sembuf op;
struct sembuf s;
#define SEMOP_MAX (MALLOC_MAX / sizeof(struct sembuf))
syscallarg(struct sembuf *) sops;
struct sembuf sopbuf[NSOPS];
struct sembuf *sops;
struct sembuf *sopptr = NULL;
sops = mallocarray(nsops, sizeof(struct sembuf), M_SEM, M_WAITOK);
error = copyin(SCARG(uap, sops), sops, nsops * sizeof(struct sembuf));
SCARG(uap, sops), &sops, nsops * sizeof(struct sembuf)));
free(sops, M_SEM, nsops * sizeof(struct sembuf));
int semop(int, struct sembuf *, size_t);
syscallarg(struct sembuf *) sops;