r323389 breaks the kernel build when WITHOUT_ZFS is defined in src.conf

Need to add #ifdef EFI_ZFS_BOOT guard into efi/loader/main.c

PR:		222215
Reported by:	Sylvain Garrigues
This commit is contained in:
Toomas Soome 2017-09-11 07:38:53 +00:00
parent 3c5ac992c7
commit 4f152c5b8a

View File

@ -872,16 +872,20 @@ command_chain(int argc, char *argv[])
}
if (efi_getdev((void **)&dev, name, (const char **)&path) == 0) {
#ifdef EFI_ZFS_BOOT
struct zfs_devdesc *z_dev;
#endif
struct disk_devdesc *d_dev;
pdinfo_t *hd, *pd;
switch (dev->d_type) {
#ifdef EFI_ZFS_BOOT
case DEVT_ZFS:
z_dev = (struct zfs_devdesc *)dev;
loaded_image->DeviceHandle =
efizfs_get_handle_by_guid(z_dev->pool_guid);
break;
#endif
case DEVT_NET:
loaded_image->DeviceHandle =
efi_find_handle(dev->d_dev, dev->d_unit);