mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2026-05-22 10:37:35 +03:00
Minor spa portability fixes
- FreeBSD's rootpool import code uses spa_config_parse - Move the zvol_create_minors call out from under the spa_namespace_lock in spa_import. It isn't needed and it causes a lock order reversal on FreeBSD. Reviewed-by: Igor Kozhukhov <igor@dilos.org> Reviewed-by: Jorgen Lundman <lundman@lundman.net> Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: Matt Macy <mmacy@FreeBSD.org> Closes #9499
This commit is contained in:
committed by
Brian Behlendorf
parent
7125a109dc
commit
4a22ba5be0
+3
-3
@@ -1406,7 +1406,7 @@ spa_deactivate(spa_t *spa)
|
||||
* in the CLOSED state. This will prep the pool before open/creation/import.
|
||||
* All vdev validation is done by the vdev_alloc() routine.
|
||||
*/
|
||||
static int
|
||||
int
|
||||
spa_config_parse(spa_t *spa, vdev_t **vdp, nvlist_t *nv, vdev_t *parent,
|
||||
uint_t id, int atype)
|
||||
{
|
||||
@@ -6081,10 +6081,10 @@ spa_import(char *pool, nvlist_t *config, nvlist_t *props, uint64_t flags)
|
||||
|
||||
spa_event_notify(spa, NULL, NULL, ESC_ZFS_POOL_IMPORT);
|
||||
|
||||
zvol_create_minors(spa, pool, B_TRUE);
|
||||
|
||||
mutex_exit(&spa_namespace_lock);
|
||||
|
||||
zvol_create_minors(spa, pool, B_TRUE);
|
||||
|
||||
return (0);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user