Lines Matching defs:kmsg
142 ipc_kmsg_t kmsg,
193 ipc_kmsg_t kmsg;
206 kmsg = ipc_kmsg_alloc(msg_and_trailer_size);
208 if (kmsg == IKM_NULL)
211 (void) memcpy((void *) kmsg->ikm_header, (const void *) msg, send_size);
213 kmsg->ikm_header->msgh_size = send_size;
221 trailer = (mach_msg_max_trailer_t *) ((vm_offset_t)kmsg->ikm_header + send_size);
231 mr = ipc_kmsg_copyin(kmsg, space, map, notify);
233 mr = ipc_kmsg_copyin(kmsg, space, map, MACH_PORT_NULL);
235 ipc_kmsg_free(kmsg);
239 mr = ipc_kmsg_send(kmsg, option & MACH_SEND_TIMEOUT, send_timeout);
242 mr |= ipc_kmsg_copyout_pseudo(kmsg, space, map, MACH_MSG_BODY_NULL);
243 (void) memcpy((void *) msg, (const void *) kmsg->ikm_header,
244 kmsg->ikm_header->msgh_size);
245 ipc_kmsg_free(kmsg);
283 ipc_kmsg_t kmsg = self->ith_kmsg;
307 if (msg_receive_error(kmsg, msg_addr, option, seqno, space)
315 ((vm_offset_t)kmsg->ikm_header +
316 round_msg(kmsg->ikm_header->msgh_size));
324 if (kmsg->ikm_sender != NULL &&
325 IP_VALID(kmsg->ikm_header->msgh_remote_port) &&
326 mac_port_check_method(kmsg->ikm_sender,
327 &kmsg->ikm_sender->maclabel,
328 &((ipc_port_t)kmsg->ikm_header->msgh_remote_port)->ip_label,
329 kmsg->ikm_header->msgh_id) == 0)
344 if (kmsg->ikm_sender != NULL) {
345 ipc_labelh_t lh = kmsg->ikm_sender->label;
383 slist = ipc_kmsg_get_scatter(msg_addr, slist_size, kmsg);
384 mr = ipc_kmsg_copyout(kmsg, space, map, MACH_PORT_NULL, slist);
387 mr = ipc_kmsg_copyout(kmsg, space, map,
393 if (ipc_kmsg_put(msg_addr, kmsg, kmsg->ikm_header->msgh_size +
398 if (msg_receive_error(kmsg, msg_addr, option, seqno, space)
405 kmsg,
406 kmsg->ikm_header->msgh_size +
671 ipc_kmsg_t kmsg;
715 mr = ipc_kmsg_get(msg_addr, send_size, &kmsg);
719 hdr = kmsg->ikm_header;
728 * We have the request message data in kmsg.
1143 * Finished get/copyin of kmsg and copyin of rcv_name.
1145 * we can queue kmsg to dest_port,
1198 ipc_kmsg_copyout_size(kmsg, receiver->map) +
1201 receiver->ith_msize = kmsg->ikm_header->msgh_size;
1219 * Store the kmsg and seqno where the receiver can pick it up.
1222 receiver->ith_kmsg = kmsg;
1276 * we have kmsg with msgh_seqno filled in. Must
1478 mr = ipc_kmsg_copyout_body(kmsg, space,
1483 if (ipc_kmsg_put(msg_addr, kmsg,
1484 kmsg->ikm_header->msgh_size +
1503 kmsg,
1504 kmsg->ikm_header->msgh_size +
1527 * We have the message data in kmsg, but
1532 mr = ipc_kmsg_copyin(kmsg, space, current_map(),
1535 ipc_kmsg_free(kmsg);
1544 hdr = kmsg->ikm_header;
1609 * kmsg. Nothing is locked.
1623 kmsg = ipc_kobject_server(kmsg);
1624 if (kmsg == IKM_NULL) {
1643 hdr = kmsg->ikm_header;
1657 mr = ipc_kmsg_send(kmsg, MACH_SEND_TIMEOUT, 0);
1659 ipc_kmsg_destroy(kmsg);
1684 mr = ipc_kmsg_send(kmsg, MACH_SEND_TIMEOUT, 0);
1686 ipc_kmsg_destroy(kmsg);
1721 * Nothing is locked. We have acquired kmsg, but
1725 mr = ipc_kmsg_send(kmsg, MACH_MSG_OPTION_NONE,
1728 mr |= ipc_kmsg_copyout_pseudo(kmsg, space,
1732 (void) ipc_kmsg_put(msg_addr, kmsg,
1733 kmsg->ikm_header->msgh_size);
1772 kmsg = self->ith_kmsg;
1773 hdr = kmsg->ikm_header;
1788 * we have kmsg with msgh_seqno filled in. Must
1794 reply_size = ipc_kmsg_copyout_size(kmsg, current_map()) +
1798 if (msg_receive_error(kmsg, msg_addr, option, temp_seqno,
1809 mr = ipc_kmsg_copyout(kmsg, space, current_map(),
1813 if (ipc_kmsg_put(msg_addr, kmsg, reply_size) ==
1818 if (msg_receive_error(kmsg, msg_addr, option,
1838 ipc_kmsg_t kmsg;
1840 mr = ipc_kmsg_get(msg_addr, send_size, &kmsg);
1849 mr = ipc_kmsg_copyin(kmsg, space, map, notify);
1851 mr = ipc_kmsg_copyin(kmsg, space, map, MACH_PORT_NULL);
1853 ipc_kmsg_free(kmsg);
1857 mr = ipc_kmsg_send(kmsg, option & MACH_SEND_TIMEOUT, msg_timeout);
1860 mr |= ipc_kmsg_copyout_pseudo(kmsg, space, map, MACH_MSG_BODY_NULL);
1861 (void) ipc_kmsg_put(msg_addr, kmsg, kmsg->ikm_header->msgh_size);
1943 ipc_kmsg_t kmsg,
1955 ipc_kmsg_copyout_dest(kmsg, space);
1961 ((vm_offset_t)kmsg->ikm_header +
1963 kmsg->ikm_header->msgh_size = sizeof(mach_msg_header_t);
1975 if (ipc_kmsg_put(msg_addr, kmsg, kmsg->ikm_header->msgh_size +