vdev_geom.c (168404) | vdev_geom.c (169087) |
---|---|
1/* 2 * CDDL HEADER START 3 * 4 * The contents of this file are subject to the terms of the 5 * Common Development and Distribution License (the "License"). 6 * You may not use this file except in compliance with the License. 7 * 8 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE --- 70 unchanged lines hidden (view full) --- 79 g_topology_assert(); 80 81 vd = cp->private; 82 gp = cp->geom; 83 error = cp->provider->error; 84 85 ZFS_LOG(1, "Closing access to %s.", cp->provider->name); 86 g_access(cp, -cp->acr, -cp->acw, -cp->ace); | 1/* 2 * CDDL HEADER START 3 * 4 * The contents of this file are subject to the terms of the 5 * Common Development and Distribution License (the "License"). 6 * You may not use this file except in compliance with the License. 7 * 8 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE --- 70 unchanged lines hidden (view full) --- 79 g_topology_assert(); 80 81 vd = cp->private; 82 gp = cp->geom; 83 error = cp->provider->error; 84 85 ZFS_LOG(1, "Closing access to %s.", cp->provider->name); 86 g_access(cp, -cp->acr, -cp->acw, -cp->ace); |
87 g_detach(cp); | |
88 ZFS_LOG(1, "Destroyed consumer to %s.", cp->provider->name); | 87 ZFS_LOG(1, "Destroyed consumer to %s.", cp->provider->name); |
88 g_detach(cp); |
|
89 g_destroy_consumer(cp); 90 /* Destroy geom if there are no consumers left. */ 91 if (LIST_EMPTY(&gp->consumer)) { 92 ZFS_LOG(1, "Destroyed geom %s.", gp->name); | 89 g_destroy_consumer(cp); 90 /* Destroy geom if there are no consumers left. */ 91 if (LIST_EMPTY(&gp->consumer)) { 92 ZFS_LOG(1, "Destroyed geom %s.", gp->name); |
93 g_wither_geom(cp->geom, error); | 93 g_wither_geom(gp, error); |
94 } 95 vdev_geom_release(vd); 96 /* Both methods below work, but in a bit different way. */ 97#if 0 98 vd->vdev_reopen_wanted = 1; 99#else 100 vd->vdev_stat.vs_aux = VDEV_AUX_OPEN_FAILED; 101 vdev_set_state(vd, B_TRUE, VDEV_STATE_CANT_OPEN, vd->vdev_stat.vs_aux); --- 331 unchanged lines hidden --- | 94 } 95 vdev_geom_release(vd); 96 /* Both methods below work, but in a bit different way. */ 97#if 0 98 vd->vdev_reopen_wanted = 1; 99#else 100 vd->vdev_stat.vs_aux = VDEV_AUX_OPEN_FAILED; 101 vdev_set_state(vd, B_TRUE, VDEV_STATE_CANT_OPEN, vd->vdev_stat.vs_aux); --- 331 unchanged lines hidden --- |