Lines Matching refs:space
192 * Retrieves a list of the rights present in the space,
196 * are an accurate snapshot of the space.
201 * KERN_INVALID_TASK The space is null.
202 * KERN_INVALID_TASK The space is dead.
208 ipc_space_t space,
233 if (space == IS_NULL)
242 is_read_lock(space);
243 if (!space->is_active) {
244 is_read_unlock(space);
252 /* upper bound on number of names in the space */
254 bound = space->is_table_size + space->is_tree_total;
260 is_read_unlock(space);
299 /* space is read-locked and active */
307 table = space->is_table;
308 tsize = space->is_table_size;
323 for (tentry = ipc_splay_traverse_start(&space->is_tree);
325 tentry = ipc_splay_traverse_next(&space->is_tree, FALSE)) {
333 ipc_splay_traverse_finish(&space->is_tree);
334 is_read_unlock(space);
390 * Retrieves the type of a right in the space.
405 * KERN_INVALID_TASK The space is null.
406 * KERN_INVALID_TASK The space is dead.
412 ipc_space_t space,
420 if (space == IS_NULL)
431 kr = ipc_right_lookup_write(space, name, &entry);
434 /* space is write-locked and active */
436 kr = ipc_right_info(space, name, entry, typep, &urefs);
438 is_write_unlock(space);
439 /* space is unlocked */
452 * KERN_INVALID_TASK The space is null.
453 * KERN_INVALID_TASK The space is dead.
462 ipc_space_t space,
466 if (space == IS_NULL)
475 return ipc_object_rename(space, oname, nname);
481 * Allocates a right in a space, using a specific name
501 * KERN_INVALID_TASK The space is null.
502 * KERN_INVALID_TASK The space is dead.
515 ipc_space_t space,
527 kr = mach_port_allocate_full (space, right, MACH_PORT_NULL,
535 * Allocates a right in a space. Like mach_port_allocate_name,
537 * The name may be any legal name in the space that doesn't
543 * KERN_INVALID_TASK The space is null.
544 * KERN_INVALID_TASK The space is dead.
547 * KERN_NO_SPACE No room in space for another right.
552 ipc_space_t space,
559 kr = mach_port_allocate_full (space, right, MACH_PORT_NULL,
567 * Allocates a right, with qos options, in a space. Like
570 * in the space that doesn't currently denote a right.
575 * KERN_INVALID_TASK The space is null.
576 * KERN_INVALID_TASK The space is dead.
580 * KERN_NO_SPACE No room in space for another right.
585 ipc_space_t space,
594 kr = mach_port_allocate_full (space, right, MACH_PORT_NULL,
602 * Allocates a right in a space. Supports all of the
605 * The name may be any legal name in the space that doesn't
611 * KERN_INVALID_TASK The space is null.
612 * KERN_INVALID_TASK The space is dead.
615 * KERN_NO_SPACE No room in space for another right.
620 ipc_space_t space,
629 if (space == IS_NULL)
638 if (is_fast_space (space))
661 kr = ipc_port_alloc_name(space, *namep, &port);
663 kr = ipc_port_alloc(space, namep, &port);
680 kr = ipc_pset_alloc_name(space, *namep, &pset);
682 kr = ipc_pset_alloc(space, namep, &pset);
689 kr = ipc_object_alloc_dead(space, namep);
704 * in a space. The destruction of a receive right
712 * KERN_INVALID_TASK The space is null.
713 * KERN_INVALID_TASK The space is dead.
719 ipc_space_t space,
725 if (space == IS_NULL)
731 kr = ipc_right_lookup_write(space, name, &entry);
734 /* space is write-locked and active */
736 kr = ipc_right_destroy(space, name, entry);
737 is_write_unlock(space);
753 * KERN_INVALID_TASK The space is null.
754 * KERN_INVALID_TASK The space is dead.
761 ipc_space_t space,
767 if (space == IS_NULL)
773 kr = ipc_right_lookup_write(space, name, &entry);
776 /* space is write-locked */
778 kr = ipc_right_dealloc(space, name, entry); /* unlocks space */
793 * KERN_INVALID_TASK The space is null.
794 * KERN_INVALID_TASK The space is dead.
801 ipc_space_t space,
811 if (space == IS_NULL)
826 kr = ipc_right_lookup_write(space, name, &entry);
829 /* space is write-locked and active */
831 kr = ipc_right_info(space, name, entry, &type, &urefs); /* unlocks */
833 return kr; /* space is unlocked */
834 is_write_unlock(space);
873 * KERN_INVALID_TASK The space is null.
874 * KERN_INVALID_TASK The space is dead.
884 ipc_space_t space,
892 if (space == IS_NULL)
905 kr = ipc_right_lookup_write(space, name, &entry);
908 /* space is write-locked and active */
910 kr = ipc_right_delta(space, name, entry, right, delta); /* unlocks */
923 * KERN_INVALID_TASK The space is null.
924 * KERN_INVALID_TASK The space is dead.
931 ipc_space_t space,
938 if (space == IS_NULL)
944 kr = ipc_port_translate_receive(space, name, &port);
963 * KERN_INVALID_TASK The space is null.
964 * KERN_INVALID_TASK The space is dead.
971 ipc_space_t space,
978 if (space == IS_NULL)
984 kr = ipc_port_translate_receive(space, name, &port);
1035 * Returns the space's name for each receive right member.
1040 * KERN_INVALID_TASK The space is null.
1041 * KERN_INVALID_TASK The space is dead.
1049 ipc_space_t space,
1055 ipc_entry_num_t maxnames; /* space for this many members */
1062 if (space == IS_NULL)
1088 kr = ipc_right_lookup_read(space, name, &entry);
1093 /* space is read-locked and active */
1096 is_read_unlock(space);
1109 table = space->is_table;
1110 tsize = space->is_table_size;
1124 for (tentry = ipc_splay_traverse_start(&space->is_tree);
1126 tentry = ipc_splay_traverse_next(&space->is_tree,FALSE)) {
1138 ipc_splay_traverse_finish(&space->is_tree);
1139 is_read_unlock(space);
1195 * KERN_INVALID_TASK The space is null.
1196 * KERN_INVALID_TASK The space is dead.
1207 ipc_space_t space,
1216 if (space == IS_NULL)
1225 kr = ipc_right_lookup_read(space, member, &entry);
1228 /* space is read-locked and active */
1231 is_read_unlock(space);
1241 entry = ipc_entry_lookup(space, after);
1243 is_read_unlock(space);
1248 is_read_unlock(space);
1264 is_read_unlock(space);
1296 * KERN_INVALID_TASK The space is null.
1297 * KERN_INVALID_TASK The space is dead.
1314 ipc_space_t space,
1323 if (space == IS_NULL)
1337 kr = ipc_right_lookup_write(space, name, &entry);
1344 is_write_unlock(space);
1348 is_write_unlock(space);
1363 kr = ipc_port_translate_receive(space, name, &port);
1381 kr = ipc_port_translate_receive(space, name, &port);
1402 kr = ipc_right_dnrequest(space, name, sync != 0,
1418 * Inserts a right into a space, as if the space
1425 * KERN_INVALID_TASK The space is null.
1426 * KERN_INVALID_TASK The space is dead.
1438 ipc_space_t space,
1443 if (space == IS_NULL)
1453 return ipc_object_copyout_name(space, (ipc_object_t) poly,
1460 * Extracts a right from a space, as if the space
1466 * KERN_INVALID_TASK The space is null.
1467 * KERN_INVALID_TASK The space is dead.
1475 ipc_space_t space,
1483 if (space == IS_NULL)
1498 kr = ipc_object_copyin(space, name, msgt_name, (ipc_object_t *) poly);
1508 ipc_space_t space,
1517 if (space == IS_NULL)
1532 kr = ipc_port_translate_receive(space, name, &port);
1553 kr = ipc_port_translate_receive(space, name, &port);
1591 kr = ipc_port_translate_receive(space, name, &port);
1616 ipc_space_t space,
1625 if (space == IS_NULL)
1642 kr = ipc_port_translate_receive(space, name, &port);
1658 kr = ipc_port_translate_receive(space, name, &port);
1685 * KERN_INVALID_TASK The space is null.
1686 * KERN_INVALID_TASK The space is dead.
1696 ipc_space_t space,
1704 if (space == IS_NULL)
1710 kr = ipc_object_translate_two(space,
1734 * KERN_INVALID_TASK The space is null.
1735 * KERN_INVALID_TASK The space is dead.
1746 ipc_space_t space,
1754 if (space == IS_NULL)
1760 kr = ipc_object_translate_two(space,
1779 * Set port name space of task to specified size.
1783 ipc_space_t space,
1788 is_write_lock(space);
1789 kr = ipc_entry_grow_table(space, table_entries);
1791 is_write_unlock(space);
1801 ipc_space_t space,
1814 /* Lookup the port name in the task's space. */
1815 kr = ipc_right_lookup_write(space, name, &entry);
1820 dead = ipc_right_check(space, port, name, entry);
1822 is_write_unlock(space);
1827 is_write_unlock(space);
1838 kr = labelh_new_user(space, &outl, outlabel);
1846 __unused ipc_space_t space,
1860 ipc_space_t space,
1870 if (space == IS_NULL || space->is_task == NULL)
1876 kr = ipc_right_lookup_write(space, name, &entry);
1880 dead = ipc_right_check(space, (ipc_port_t) entry->ie_object, name,
1883 is_write_unlock(space);
1888 is_write_unlock (space);
1900 __unused ipc_space_t space,
1913 ipc_space_t space,
1923 if (space == IS_NULL || space->is_task == NULL)
1934 kr = ipc_right_lookup_write(space, name, &entry);
1939 is_write_unlock(space);
1946 tasklabel_lock(space->is_task);
1947 rc = mac_port_check_label_update(&space->is_task->maclabel,
1949 tasklabel_unlock(space->is_task);
1956 is_write_unlock(space);
1962 ipc_space_t space __unused,