Author: mm Date: Mon Aug 9 06:36:11 2010 New Revision: 211091 URL: http://svn.freebsd.org/changeset/base/211091
Log: Return EIO if vdev->v_phys_read is NULL. This fixes booting from a ZFS mirror with a unavailable primary device. PR: kern/148655 Reviewed by: avg Approved by: delphij (mentor) MFC after: 3 days Modified: head/sys/boot/zfs/zfsimpl.c Modified: head/sys/boot/zfs/zfsimpl.c ============================================================================== --- head/sys/boot/zfs/zfsimpl.c Mon Aug 9 06:02:23 2010 (r211090) +++ head/sys/boot/zfs/zfsimpl.c Mon Aug 9 06:36:11 2010 (r211091) @@ -328,6 +328,9 @@ vdev_read_phys(vdev_t *vdev, const blkpt size_t psize; int rc; + if (!vdev->v_phys_read) + return (EIO); + if (bp) { psize = BP_GET_PSIZE(bp); } else { _______________________________________________ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"