Fix panic by creating zfsdev_state_lock before /dev/zfs

zfsdev_open() uses zfsdev_state_lock, so zfsdev_state_lock
needs to have been initialized before we can call
devfs_make_node() to make /dev/zfs.

Added the functions zfs_attach() and zfs_detach(), and refactored
zfs_ioctl_osx_init() and zfs_ioctl_osx_fini() to use them.

Call zvol_fini() and spa_fini() if there are errors during
zfs_ioctl_osx_init().

Do not use list_create()/list_destroy() for zfsdev_state_list,
since these were replaced in zfsonlinux/zfs@3937ab20f32fc7b79cacfd91c0891f4e1b4ab2de.
Merge branch 'master' into issue116