Changeset View
Changeset View
Standalone View
Standalone View
stand/efi/libefi/devicename.c
Show First 20 Lines • Show All 105 Lines • ▼ Show 20 Lines | efi_parsedev(struct devdesc **dev, const char *devspec, const char **path) | ||||
idev = NULL; | idev = NULL; | ||||
err = 0; | err = 0; | ||||
switch (dv->dv_type) { | switch (dv->dv_type) { | ||||
case DEVT_NONE: | case DEVT_NONE: | ||||
break; | break; | ||||
case DEVT_DISK: | case DEVT_DISK: | ||||
idev = malloc(sizeof(struct disk_devdesc)); | err = disk_parsedev(&idev, np, path); | ||||
if (idev == NULL) | |||||
return (ENOMEM); | |||||
err = disk_parsedev((struct disk_devdesc *)idev, np, path); | |||||
if (err != 0) | if (err != 0) | ||||
goto fail; | goto fail; | ||||
break; | break; | ||||
#ifdef EFI_ZFS_BOOT | #ifdef EFI_ZFS_BOOT | ||||
case DEVT_ZFS: | case DEVT_ZFS: | ||||
idev = malloc(sizeof(struct zfs_devdesc)); | idev = malloc(sizeof(struct zfs_devdesc)); | ||||
if (idev == NULL) | if (idev == NULL) | ||||
▲ Show 20 Lines • Show All 63 Lines • Show Last 20 Lines |