FreeBSD/src 3c2db0e (r355786)stand/libsa/zfs zfsimpl.c, sys/cddl/boot/zfs zfsimpl.h zfssubr.c

loader: rewrite zfs vdev initialization

In some cases the pool discovery will get stuck in infinite loop while setting
up the vdev children.

To fix, we split the vdev setup into two parts, first we create vdevs based on
configuration we do get from pool label, then, we process pool config from MOS
and update the pool config if needed.

Testing done: confirm previously hung loader is not hung any more.

MFC after:      1 week
DeltaFile
+438-261stand/libsa/zfs/zfsimpl.c
+6-4sys/cddl/boot/zfs/zfsimpl.h
+7-3sys/cddl/boot/zfs/zfssubr.c
+451-2683 files

UnifiedSplitRaw

FreeBSD/src 3557869 (r335148)stand/libsa open.c

libsa: open() should use NULL instead of typecasted 0
DeltaFile
+5-5stand/libsa/open.c
+5-51 files

UnifiedSplitRaw