Lines Matching refs:item

303 static int getdevid(struct cam_devitem *item);
7651 getdevid(struct cam_devitem *item)
7658 dev = cam_open_btl(item->dev_match.path_id,
7659 item->dev_match.target_id,
7660 item->dev_match.target_lun, O_RDWR, NULL);
7668 item->device_id_len = 0;
7688 ccb->cdai.bufsiz = item->device_id_len;
7689 if (item->device_id_len != 0)
7690 ccb->cdai.buf = (uint8_t *)item->device_id;
7704 if (item->device_id_len == 0) {
7715 item->device_id_len = ccb->cdai.provsiz;
7716 item->device_id = malloc(item->device_id_len);
7717 if (item->device_id == NULL) {
7719 item->device_id_len);
7746 struct cam_devitem *item = NULL;
7829 item = malloc(sizeof(*item));
7830 if (item == NULL) {
7832 __func__, sizeof(*item));
7836 bzero(item, sizeof(*item));
7837 bcopy(dev_result, &item->dev_match,
7839 STAILQ_INSERT_TAIL(&devlist->dev_queue, item,
7842 if (getdevid(item) != 0) {
7856 item->num_periphs++;
7857 item->periph_matches = realloc(
7858 item->periph_matches,
7859 item->num_periphs *
7861 if (item->periph_matches == NULL) {
7867 bcopy(periph_result, &item->periph_matches[
7868 item->num_periphs - 1],
7901 struct cam_devitem *item, *item2;
7903 STAILQ_FOREACH_SAFE(item, &devlist->dev_queue, links, item2) {
7904 STAILQ_REMOVE(&devlist->dev_queue, item, cam_devitem,
7906 free(item->device_id);
7907 free(item->periph_matches);
7908 free(item);
7915 struct cam_devitem *item;
7917 STAILQ_FOREACH(item, &devlist->dev_queue, links) {
7923 idd = scsi_get_devid(item->device_id,
7924 item->device_id_len,
7930 return (item);
8060 struct cam_devitem *item;
8108 item = NULL;
8110 item = findsasdevice(&devlist,
8115 || (item != NULL)) {
8119 if (item == NULL) {
8126 dev_match = &item->dev_match;
8157 if (item->num_periphs == 0) {
8163 for (j = 0; j < item->num_periphs; j++) {
8168 item->periph_matches[j].periph_name,
8169 item->periph_matches[j].unit_number);