Lines Matching refs:handles
290 handle_attr_t *handles;
944 /* convert disk handles into disk object ids; */
1335 ptr = realloc(raid_handle_sys.handles,
1339 raid_handle_sys.handles = ptr;
1341 /* Clean up the new allocated handles */
1344 bzero(&raid_handle_sys.handles[i], sizeof (handle_attr_t));
1345 raid_handle_sys.handles[i].type = OBJ_TYPE_ALL;
1346 raid_handle_sys.handles[i].next = i + 1;
1351 raid_handle_sys.handles[0].type = OBJ_TYPE_SYSTEM;
1352 raid_handle_sys.handles[0].next = 0;
1368 if ((raid_handle_sys.handles[i].type == OBJ_TYPE_CONTROLLER) &&
1369 (raid_handle_sys.handles[i].fd != 0) &&
1370 (raid_handle_sys.handles[i].raid_lib != NULL))
1371 raid_handle_sys.handles[i].raid_lib->close_controller(
1372 raid_handle_sys.handles[i].controller_id, NULL);
1373 i = raid_handle_sys.handles[i].next;
1380 free(raid_handle_sys.handles);
1381 raid_handle_sys.handles = NULL;
1396 raid_handle_sys.unused = raid_handle_sys.handles[ret].next;
1398 raid_handle_sys.handles[ret].next = raid_handle_sys.used;
1400 raid_handle_sys.handles[ret].type = type;
1415 i = raid_handle_sys.handles[i].next;
1420 raid_handle_sys.handles[j].next =
1421 raid_handle_sys.handles[i].next;
1424 raid_handle_sys.handles[i].next;
1426 raid_handle_sys.handles[i].type = OBJ_TYPE_ALL;
1427 raid_handle_sys.handles[i].next =
1440 i = raid_handle_sys.handles[i].next;
1441 if ((raid_handle_sys.handles[j].controller_id ==
1443 (raid_handle_sys.handles[j].type !=
1458 handle_attr = raid_handle_sys.handles + handle;
1535 /* Search for existing handles */
1537 handle = raid_handle_sys.handles[handle].next)
1548 raid_handle_sys.handles[handle].type = type;
1555 raid_handle_sys.handles[handle].controller_id =
1560 raid_handle_sys.handles[handle].array_id = array_attr->array_id;
1563 raid_handle_sys.handles[handle].controller_id =
1568 raid_handle_sys.handles[handle].array_id =
1572 raid_handle_sys.handles[handle].disk_id = disk_attr->disk_id;
1575 raid_handle_sys.handles[handle].controller_id =
1580 raid_handle_sys.handles[handle].disk_id = disk_attr->disk_id;
1583 raid_handle_sys.handles[handle].controller_id =
1588 raid_handle_sys.handles[handle].disk_id =
1592 raid_handle_sys.handles[handle].array_id =
1596 raid_handle_sys.handles[handle].controller_id =
1601 raid_handle_sys.handles[handle].seq_id = diskseg_attr->seq_no;
1604 raid_handle_sys.handles[handle].disk_id =
1608 raid_handle_sys.handles[handle].controller_id =
1613 raid_handle_sys.handles[handle].task_id = task_attr->task_id;
1616 raid_handle_sys.handles[handle].controller_id =
1621 raid_handle_sys.handles[handle].prop_id =
1625 raid_handle_sys.handles[handle].disk_id = disk_attr->disk_id;
1628 raid_handle_sys.handles[handle].controller_id =
1650 while (raid_handle_sys.handles[handle].type != OBJ_TYPE_CONTROLLER ||
1651 raid_handle_sys.handles[handle].controller_id !=
1653 handle = raid_handle_sys.handles[handle].next;
1658 return (raid_handle_sys.handles[handle].raid_lib);
1673 while (raid_handle_sys.handles[handle].type != OBJ_TYPE_CONTROLLER ||
1674 raid_handle_sys.handles[handle].controller_id !=
1676 handle = raid_handle_sys.handles[handle].next;
1681 raid_handle_sys.handles[handle].raid_lib = raid_lib;
1696 while (raid_handle_sys.handles[handle].type != OBJ_TYPE_CONTROLLER ||
1697 raid_handle_sys.handles[handle].controller_id !=
1699 handle = raid_handle_sys.handles[handle].next;
1704 return (raid_handle_sys.handles[handle].fd);
1718 while (raid_handle_sys.handles[handle].type != OBJ_TYPE_CONTROLLER ||
1719 raid_handle_sys.handles[handle].controller_id !=
1721 handle = raid_handle_sys.handles[handle].next;
1726 raid_handle_sys.handles[handle].fd = fd;
4607 if (raid_handle_sys.handles[handle].raid_lib != NULL)
4608 return (raid_handle_sys.handles[handle].raid_lib);