Lines Matching defs:hd
614 efipart_hdinfo_add_node(pdinfo_t *hd, EFI_DEVICE_PATH *node)
621 parent = hd->pd_parent;
630 hd->pd_unit = ptr->pd_unit + 1;
632 hd->pd_unit = 0;
634 hd->pd_unit = ((HARDDRIVE_DEVICE_PATH *)node)->PartitionNumber;
637 hd->pd_devsw = &efipart_hddev;
638 STAILQ_INSERT_TAIL(&parent->pd_part, hd, pd_link);
648 efipart_hdinfo_add_filepath(pdinfo_t *hd, FILEPATH_DEVICE_PATH *node)
656 hd->pd_unit = last->pd_unit + 1;
658 hd->pd_unit = 0;
664 free(hd);
676 hd->pd_devsw = &efipart_hddev;
677 STAILQ_INSERT_TAIL(&hdinfo, hd, pd_link);
683 hd->pd_unit = (int)strtol(p, NULL, 0);
687 free(hd);
700 free(hd);
704 hd->pd_parent = last;
705 hd->pd_devsw = &efipart_hddev;
706 STAILQ_INSERT_TAIL(&last->pd_part, hd, pd_link);
711 efipart_hdinfo_add(pdinfo_t *hd)
716 if (hd == NULL)
719 parent = hd->pd_parent;
724 if (efi_devpath_match(pd->pd_devpath, hd->pd_devpath)) {
725 STAILQ_REMOVE(&pdinfo, hd, pdinfo, pd_link);
734 if ((node = efi_devpath_last_node(hd->pd_devpath)) == NULL)
739 efipart_hdinfo_add_filepath(hd,
745 efipart_hdinfo_add_node(hd, node);
751 hd->pd_unit = last->pd_unit + 1;
753 hd->pd_unit = 0;
756 hd->pd_devsw = &efipart_hddev;
757 STAILQ_INSERT_TAIL(&hdinfo, hd, pd_link);
761 efipart_testhd(pdinfo_t *hd, pdinfo_t *data __unused)
763 if (efipart_testfd(hd, NULL))
766 if (efipart_testcd(hd, NULL))
776 pdinfo_t *hd;
778 while ((hd = efipart_get_pd(&pdinfo, efipart_testhd, NULL)) != NULL)
779 efipart_hdinfo_add(hd);