svn commit: r226006 - projects/geom-events/sys/geom/shsec
Lev A. Serebryakov
lev at FreeBSD.org
Tue Oct 4 17:03:02 UTC 2011
Author: lev (ports committer)
Date: Tue Oct 4 17:03:01 2011
New Revision: 226006
URL: http://svn.freebsd.org/changeset/base/226006
Log:
Add g_notify_*() calls to geom_shsec
Modified:
projects/geom-events/sys/geom/shsec/g_shsec.c
Modified: projects/geom-events/sys/geom/shsec/g_shsec.c
==============================================================================
--- projects/geom-events/sys/geom/shsec/g_shsec.c Tue Oct 4 17:02:49 2011 (r226005)
+++ projects/geom-events/sys/geom/shsec/g_shsec.c Tue Oct 4 17:03:01 2011 (r226006)
@@ -180,10 +180,17 @@ g_shsec_orphan(struct g_consumer *cp)
if (sc == NULL)
return;
+ g_notify_disconnect(sc->sc_provider, cp,
+ ((g_shsec_nvalid(sc) > 1)?
+ G_NOTIFY_DISCONNECT_ALIVE:
+ G_NOTIFY_DISCONNECT_DEAD));
+
g_shsec_remove_disk(cp);
/* If there are no valid disks anymore, remove device. */
- if (g_shsec_nvalid(sc) == 0)
+ if (g_shsec_nvalid(sc) == 0) {
+ g_notify_destroyed(sc->sc_provider);
g_shsec_destroy(sc, 1);
+ }
}
static int
More information about the svn-src-projects
mailing list