Lines Matching refs:msqbuf
482 struct msqid_ds msqbuf; in sys_msgctl() local
487 (error = copyin(uap->buf, &msqbuf, sizeof(msqbuf))) != 0) in sys_msgctl()
489 error = kern_msgctl(td, msqid, cmd, &msqbuf); in sys_msgctl()
491 error = copyout(&msqbuf, uap->buf, sizeof(struct msqid_ds)); in sys_msgctl()
496 kern_msgctl(struct thread *td, int msqid, int cmd, struct msqid_ds *msqbuf) in kern_msgctl() argument
578 AUDIT_ARG_SVIPC_PERM(&msqbuf->msg_perm); in kern_msgctl()
581 if (msqbuf->msg_qbytes > msqkptr->u.msg_qbytes) { in kern_msgctl()
586 if (msqbuf->msg_qbytes > msginfo.msgmnb) { in kern_msgctl()
589 msqbuf->msg_qbytes = msginfo.msgmnb; /* silently restrict qbytes to system limit */ in kern_msgctl()
591 if (msqbuf->msg_qbytes == 0) { in kern_msgctl()
596 msqkptr->u.msg_perm.uid = msqbuf->msg_perm.uid; /* change the owner */ in kern_msgctl()
597 msqkptr->u.msg_perm.gid = msqbuf->msg_perm.gid; /* change the owner */ in kern_msgctl()
599 (msqbuf->msg_perm.mode & 0777); in kern_msgctl()
600 msqkptr->u.msg_qbytes = msqbuf->msg_qbytes; in kern_msgctl()
609 *msqbuf = msqkptr->u; in kern_msgctl()
611 msqbuf->msg_perm.key = IPC_PRIVATE; in kern_msgctl()
618 msqbuf->__msg_first = msqbuf->__msg_last = NULL; in kern_msgctl()
1737 struct msqid_ds msqbuf; in freebsd7_freebsd32_msgctl() local
1745 freebsd32_ipcperm_old_in(&msqbuf32.msg_perm, &msqbuf.msg_perm); in freebsd7_freebsd32_msgctl()
1746 PTRIN_CP(msqbuf32, msqbuf, __msg_first); in freebsd7_freebsd32_msgctl()
1747 PTRIN_CP(msqbuf32, msqbuf, __msg_last); in freebsd7_freebsd32_msgctl()
1748 CP(msqbuf32, msqbuf, msg_cbytes); in freebsd7_freebsd32_msgctl()
1749 CP(msqbuf32, msqbuf, msg_qnum); in freebsd7_freebsd32_msgctl()
1750 CP(msqbuf32, msqbuf, msg_qbytes); in freebsd7_freebsd32_msgctl()
1751 CP(msqbuf32, msqbuf, msg_lspid); in freebsd7_freebsd32_msgctl()
1752 CP(msqbuf32, msqbuf, msg_lrpid); in freebsd7_freebsd32_msgctl()
1753 CP(msqbuf32, msqbuf, msg_stime); in freebsd7_freebsd32_msgctl()
1754 CP(msqbuf32, msqbuf, msg_rtime); in freebsd7_freebsd32_msgctl()
1755 CP(msqbuf32, msqbuf, msg_ctime); in freebsd7_freebsd32_msgctl()
1757 error = kern_msgctl(td, uap->msqid, uap->cmd, &msqbuf); in freebsd7_freebsd32_msgctl()
1762 freebsd32_ipcperm_old_out(&msqbuf.msg_perm, &msqbuf32.msg_perm); in freebsd7_freebsd32_msgctl()
1763 PTROUT_CP(msqbuf, msqbuf32, __msg_first); in freebsd7_freebsd32_msgctl()
1764 PTROUT_CP(msqbuf, msqbuf32, __msg_last); in freebsd7_freebsd32_msgctl()
1765 CP(msqbuf, msqbuf32, msg_cbytes); in freebsd7_freebsd32_msgctl()
1766 CP(msqbuf, msqbuf32, msg_qnum); in freebsd7_freebsd32_msgctl()
1767 CP(msqbuf, msqbuf32, msg_qbytes); in freebsd7_freebsd32_msgctl()
1768 CP(msqbuf, msqbuf32, msg_lspid); in freebsd7_freebsd32_msgctl()
1769 CP(msqbuf, msqbuf32, msg_lrpid); in freebsd7_freebsd32_msgctl()
1770 CP(msqbuf, msqbuf32, msg_stime); in freebsd7_freebsd32_msgctl()
1771 CP(msqbuf, msqbuf32, msg_rtime); in freebsd7_freebsd32_msgctl()
1772 CP(msqbuf, msqbuf32, msg_ctime); in freebsd7_freebsd32_msgctl()
1782 struct msqid_ds msqbuf; in freebsd32_msgctl() local
1790 freebsd32_ipcperm_in(&msqbuf32.msg_perm, &msqbuf.msg_perm); in freebsd32_msgctl()
1791 PTRIN_CP(msqbuf32, msqbuf, __msg_first); in freebsd32_msgctl()
1792 PTRIN_CP(msqbuf32, msqbuf, __msg_last); in freebsd32_msgctl()
1793 CP(msqbuf32, msqbuf, msg_cbytes); in freebsd32_msgctl()
1794 CP(msqbuf32, msqbuf, msg_qnum); in freebsd32_msgctl()
1795 CP(msqbuf32, msqbuf, msg_qbytes); in freebsd32_msgctl()
1796 CP(msqbuf32, msqbuf, msg_lspid); in freebsd32_msgctl()
1797 CP(msqbuf32, msqbuf, msg_lrpid); in freebsd32_msgctl()
1798 CP(msqbuf32, msqbuf, msg_stime); in freebsd32_msgctl()
1799 CP(msqbuf32, msqbuf, msg_rtime); in freebsd32_msgctl()
1800 CP(msqbuf32, msqbuf, msg_ctime); in freebsd32_msgctl()
1802 error = kern_msgctl(td, uap->msqid, uap->cmd, &msqbuf); in freebsd32_msgctl()
1806 freebsd32_ipcperm_out(&msqbuf.msg_perm, &msqbuf32.msg_perm); in freebsd32_msgctl()
1807 PTROUT_CP(msqbuf, msqbuf32, __msg_first); in freebsd32_msgctl()
1808 PTROUT_CP(msqbuf, msqbuf32, __msg_last); in freebsd32_msgctl()
1809 CP(msqbuf, msqbuf32, msg_cbytes); in freebsd32_msgctl()
1810 CP(msqbuf, msqbuf32, msg_qnum); in freebsd32_msgctl()
1811 CP(msqbuf, msqbuf32, msg_qbytes); in freebsd32_msgctl()
1812 CP(msqbuf, msqbuf32, msg_lspid); in freebsd32_msgctl()
1813 CP(msqbuf, msqbuf32, msg_lrpid); in freebsd32_msgctl()
1814 CP(msqbuf, msqbuf32, msg_stime); in freebsd32_msgctl()
1815 CP(msqbuf, msqbuf32, msg_rtime); in freebsd32_msgctl()
1816 CP(msqbuf, msqbuf32, msg_ctime); in freebsd32_msgctl()
1906 struct msqid_ds msqbuf; in freebsd7_msgctl() local
1915 ipcperm_old2new(&msqold.msg_perm, &msqbuf.msg_perm); in freebsd7_msgctl()
1916 CP(msqold, msqbuf, __msg_first); in freebsd7_msgctl()
1917 CP(msqold, msqbuf, __msg_last); in freebsd7_msgctl()
1918 CP(msqold, msqbuf, msg_cbytes); in freebsd7_msgctl()
1919 CP(msqold, msqbuf, msg_qnum); in freebsd7_msgctl()
1920 CP(msqold, msqbuf, msg_qbytes); in freebsd7_msgctl()
1921 CP(msqold, msqbuf, msg_lspid); in freebsd7_msgctl()
1922 CP(msqold, msqbuf, msg_lrpid); in freebsd7_msgctl()
1923 CP(msqold, msqbuf, msg_stime); in freebsd7_msgctl()
1924 CP(msqold, msqbuf, msg_rtime); in freebsd7_msgctl()
1925 CP(msqold, msqbuf, msg_ctime); in freebsd7_msgctl()
1927 error = kern_msgctl(td, uap->msqid, uap->cmd, &msqbuf); in freebsd7_msgctl()
1932 ipcperm_new2old(&msqbuf.msg_perm, &msqold.msg_perm); in freebsd7_msgctl()
1933 CP(msqbuf, msqold, __msg_first); in freebsd7_msgctl()
1934 CP(msqbuf, msqold, __msg_last); in freebsd7_msgctl()
1935 CP(msqbuf, msqold, msg_cbytes); in freebsd7_msgctl()
1936 CP(msqbuf, msqold, msg_qnum); in freebsd7_msgctl()
1937 CP(msqbuf, msqold, msg_qbytes); in freebsd7_msgctl()
1938 CP(msqbuf, msqold, msg_lspid); in freebsd7_msgctl()
1939 CP(msqbuf, msqold, msg_lrpid); in freebsd7_msgctl()
1940 CP(msqbuf, msqold, msg_stime); in freebsd7_msgctl()
1941 CP(msqbuf, msqold, msg_rtime); in freebsd7_msgctl()
1942 CP(msqbuf, msqold, msg_ctime); in freebsd7_msgctl()