• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /macosx-10.10/xnu-2782.1.97/osfmk/ipc/

Lines Matching refs:space

102  *		Finds an entry in a space, given the name.
104 * Nothing locked. If successful, the space is write-locked.
107 * KERN_INVALID_TASK The space is dead.
108 * KERN_INVALID_NAME Name doesn't exist in space.
113 ipc_space_t space,
119 assert(space != IS_NULL);
121 is_write_lock(space);
123 if (!is_active(space)) {
124 is_write_unlock(space);
128 if ((entry = ipc_entry_lookup(space, name)) == IE_NULL) {
129 is_write_unlock(space);
142 * up under the same space lock.
144 * Nothing locked. If successful, the space is write-locked.
146 * KERN_INVALID_TASK The space is dead.
147 * KERN_INVALID_NAME Name doesn't exist in space.
152 ipc_space_t space,
161 assert(space != IS_NULL);
163 is_write_lock(space);
165 if (!is_active(space)) {
166 is_write_unlock(space);
170 if ((entry1 = ipc_entry_lookup(space, name1)) == IE_NULL) {
171 is_write_unlock(space);
174 if ((entry2 = ipc_entry_lookup(space, name2)) == IE_NULL) {
175 is_write_unlock(space);
186 * Translate (space, object) -> (name, entry).
191 * The space must be locked (read or write) and active.
197 ipc_space_t space,
208 assert(is_active(space));
220 if (port->ip_receiver == space) {
224 entry = ipc_entry_lookup(space, name);
235 if (ipc_hash_lookup(space, (ipc_object_t) port, namep, entryp)) {
259 * KERN_INVALID_TASK The space is dead.
260 * KERN_INVALID_NAME Name doesn't exist in space.
271 ipc_space_t space,
290 kr = ipc_right_lookup_write(space, name, &entry);
294 /* space is write-locked and active */
300 is_write_unlock(space);
312 if (!ipc_right_check(space, port, name, entry)) {
321 ipc_entry_modified(space, name, entry);
322 is_write_unlock(space);
337 ipc_entry_modified(space, name, entry);
338 is_write_unlock(space);
362 is_write_unlock(space);
376 ipc_entry_modified(space, name, entry);
377 is_write_unlock(space);
401 is_write_unlock(space);
408 ipc_entry_modified(space, name, entry);
409 is_write_unlock(space);
419 is_write_unlock(space);
440 * The space must be write-locked; the port must be locked.
441 * The port must be active; the space doesn't have to be.
446 __unused ipc_space_t space,
461 ipc_entry_modified(space, name, entry);
471 * The space is write-locked and active.
477 ipc_space_t space,
482 is_write_unlock(space);
494 * The space is write-locked; the port is not locked.
504 ipc_space_t space,
511 assert(is_active(space));
542 ipc_hash_delete(space, (ipc_object_t)port, name, entry);
555 * because the latter doesn't have a space reference and
573 ipc_entry_modified(space, name, entry);
580 * Cleans up an entry in a terminated space.
584 * The space is dead and unlocked.
589 ipc_space_t space,
599 assert(!is_active(space));
605 * would still work, but dead space refs would accumulate
646 request = ipc_right_request_cancel_macro(space, port,
667 assert(port->ip_receiver == space);
683 assert(port->ip_receiver != space);
705 * Destroys an entry in a space.
707 * The space is write-locked (returns unlocked).
708 * The space must be active.
715 ipc_space_t space,
728 assert(is_active(space));
735 ipc_entry_dealloc(space, name, entry);
736 is_write_unlock(space);
746 ipc_entry_dealloc(space, name, entry);
749 is_write_unlock(space);
768 ipc_hash_delete(space, (ipc_object_t) port,
778 ipc_entry_dealloc(space, name, entry);
779 is_write_unlock(space);
791 is_write_unlock(space);
798 request = ipc_right_request_cancel_macro(space, port, name, entry);
801 ipc_entry_dealloc(space, name, entry);
802 is_write_unlock(space);
821 assert(port->ip_receiver == space);
839 assert(port->ip_receiver != space);
869 * The space is write-locked, and is unlocked upon return.
870 * The space must be active.
878 ipc_space_t space,
890 assert(is_active(space));
901 ipc_entry_dealloc(space, name, entry);
904 ipc_entry_modified(space, name, entry);
906 is_write_unlock(space);
922 if (ipc_right_check(space, port, name, entry)) {
932 request = ipc_right_request_cancel_macro(space, port, name, entry);
936 ipc_entry_dealloc(space, name, entry);
938 is_write_unlock(space);
958 if (ipc_right_check(space, port, name, entry)) {
976 request = ipc_right_request_cancel_macro(space, port,
978 ipc_hash_delete(space, (ipc_object_t) port,
983 ipc_entry_dealloc(space, name, entry);
984 is_write_unlock(space);
990 ipc_entry_modified(space, name, entry);
991 is_write_unlock(space);
1015 assert(port->ip_receiver == space);
1034 ipc_entry_modified(space, name, entry);
1035 is_write_unlock(space);
1043 is_write_unlock(space);
1056 * The space is write-locked, and is unlocked upon return.
1057 * The space must be active.
1067 ipc_space_t space,
1084 * we postpone doing so when we are holding the space lock.
1087 assert(is_active(space));
1113 ipc_entry_dealloc(space, name, entry);
1117 is_write_unlock(space);
1144 * until just before dropping the space lock.
1150 assert(port->ip_receiver == space);
1156 is_write_unlock(space);
1180 ipc_entry_modified(space, name, entry);
1182 ipc_hash_insert(space, (ipc_object_t) port,
1201 ipc_entry_modified(space, name, entry);
1207 request = ipc_right_request_cancel_macro(space, port,
1210 ipc_entry_dealloc(space, name, entry);
1212 is_write_unlock(space);
1240 if (ipc_right_check(space, port, name, entry)) {
1258 request = ipc_right_request_cancel_macro(space, port, name, entry);
1262 ipc_entry_dealloc(space, name, entry);
1264 is_write_unlock(space);
1282 if (!ipc_right_check(space, port, name, entry)) {
1306 ipc_entry_dealloc(space, name, entry);
1309 ipc_entry_modified(space, name, entry);
1311 is_write_unlock(space);
1333 if (ipc_right_check(space, port, name, entry)) {
1362 assert(port->ip_receiver == space);
1369 ipc_entry_modified(space, name, entry);
1374 request = ipc_right_request_cancel_macro(space, port,
1376 ipc_hash_delete(space, (ipc_object_t) port,
1383 ipc_entry_dealloc(space, name, entry);
1388 ipc_entry_modified(space, name, entry);
1391 is_write_unlock(space);
1408 is_write_unlock(space);
1412 is_write_unlock(space);
1418 is_write_unlock(space);
1422 is_write_unlock(space);
1435 * The space is write-locked, and is unlocked upon return.
1436 * The space must be active.
1445 ipc_space_t space,
1465 assert(is_active(space));
1469 is_write_unlock(space);
1482 assert(port->ip_receiver == space);
1488 is_write_unlock(space);
1530 * Now destroy the receive right. Update space and
1550 ipc_entry_modified(space, name, entry);
1552 ipc_hash_insert(space, (ipc_object_t) port,
1571 ipc_entry_modified(space, name, entry);
1576 request = ipc_right_request_cancel_macro(space, port,
1579 ipc_entry_dealloc(space, name, entry);
1582 /* Unlock space */
1583 is_write_unlock(space);
1603 is_write_unlock(space);
1614 * The space is active and write-locked.
1615 * The space is unlocked upon return.
1622 ipc_space_t space,
1646 is_write_unlock(space);
1654 if (!ipc_right_check(space, port, name, entry)) {
1658 is_write_unlock(space);
1662 is_write_unlock(space);
1666 is_write_unlock(space);
1681 * The space is locked (read or write) and active.
1686 __assert_only ipc_space_t space,
1695 assert(is_active(space));
1756 * Copyin a capability from a space.
1770 * The space is write-locked and active.
1778 ipc_space_t space,
1802 assert(is_active(space));
1816 assert(port->ip_receiver == space);
1839 assert(port->ip_receiver == space);
1862 assert(port->ip_receiver == space);
1870 ipc_hash_insert(space, (ipc_object_t) port,
1877 request = ipc_right_request_cancel_macro(space, port,
1882 ipc_entry_modified(space, name, entry);
1929 if (ipc_right_check(space, port, name, entry)) {
1971 if (ipc_right_check(space, port, name, entry)) {
1991 assert(port->ip_receiver == space);
2000 request = ipc_right_request_cancel_macro(space, port,
2002 ipc_hash_delete(space, (ipc_object_t) port,
2013 ipc_entry_modified(space, name, entry);
2037 if (ipc_right_check(space, port, name, entry)) {
2055 request = ipc_right_request_cancel_macro(space, port, name, entry);
2061 ipc_entry_modified(space, name, entry);
2100 ipc_entry_modified(space, name, entry);
2114 * The space is write-locked and active.
2119 ipc_space_t space,
2130 assert(is_active(space));
2177 (void) ipc_right_check(space, (ipc_port_t) object,
2181 ipc_entry_modified(space, name, entry);
2195 * The space is write-locked and active.
2204 ipc_space_t space,
2218 assert(is_active(space));
2232 if (ipc_right_check(space, port, name, entry)) {
2243 assert(port->ip_receiver == space);
2253 request = ipc_right_request_cancel_macro(space, port,
2258 ipc_hash_delete(space, (ipc_object_t) port,
2269 ipc_entry_modified(space, name, entry);
2289 * The space is write-locked and active.
2298 ipc_space_t space,
2324 if (!ipc_right_copyin_check(space, name, entry, msgt_two)) {
2359 kr = ipc_right_copyin(space, name, entry,
2365 kr = ipc_right_copyin(space, name, entry,
2385 kr = ipc_right_copyin(space, name, entry,
2391 kr = ipc_right_copyin(space, name, entry,
2409 kr = ipc_right_copyin_two_move_sends(space, name, entry,
2434 kr = ipc_right_copyin(space, name, entry,
2440 kr = ipc_right_copyin(space, name, entry,
2466 * Copyout a capability to a space.
2477 * The space is write-locked and active.
2479 * The object is unlocked; the space isn't.
2489 ipc_space_t space,
2518 ipc_entry_modified(space, name, entry);
2565 ipc_hash_insert(space, (ipc_object_t) port,
2570 ipc_entry_modified(space, name, entry);
2585 port->ip_receiver = space;
2599 ipc_hash_delete(space, (ipc_object_t) port,
2609 ipc_entry_modified(space, name, entry);
2640 * The space is write-locked and active.
2642 * the space is unlocked.
2649 ipc_space_t space,
2660 assert(is_active(space));
2677 if (ipc_right_check(space, port, oname, oentry)) {
2710 ipc_hash_delete(space, (ipc_object_t) port, oname, oentry);
2711 ipc_hash_insert(space, (ipc_object_t) port, nname, nentry);
2725 assert(port->ip_receiver == space);
2757 ipc_entry_dealloc(space, oname, oentry);
2758 ipc_entry_modified(space, nname, nentry);
2759 is_write_unlock(space);