Date: Fri, 3 Aug 2012 09:49:41 -0700 From: Jim Harris <jimharris@freebsd.org> To: Marcelo Gondim <gondim@bsdinfo.com.br> Cc: freebsd-stable@freebsd.org Subject: Re: geom_virstor with kernel panic in FreeBSD 9.x Message-ID: <CAJP=Hc-r0zE6tDPQozEbmoSqD%2BHnxzqRzG=mummE7jWzQOsZEQ@mail.gmail.com> In-Reply-To: <501BBEBB.5010106@bsdinfo.com.br> References: <1977769407.20120322151934@tkachuk.name> <4F6B4030.5090907@FreeBSD.org> <4F6B4631.8020006@gmail.com> <4F6B4B93.7020309@FreeBSD.org> <4F6B4FAB.1020202@gmail.com> <1332434072.8403.79.camel@revolution.hippie.lan> <E1SGoVX-000EYm-90@kabab.cs.huji.ac.il> <501B8004.1000503@ateamsystems.com> <501BBEBB.5010106@bsdinfo.com.br>
next in thread | previous in thread | raw e-mail | index | archive | help
On Fri, Aug 3, 2012 at 5:06 AM, Marcelo Gondim <gondim@bsdinfo.com.br> wrote: > Hi all, > > I sent a PR [1] but I decided to also send the problem here. > If you try to destroy a geom_virstor that does not exist, this causes a > kernel panic immediately. > > Just try: > > gvirstor load > gvirstor destroy tatata > > # uname -a > FreeBSD zeus.xxxx.xxx.br 9.1-PRERELEASE FreeBSD 9.1-PRERELEASE #27: Mon Jul > 16 01:41:24 BRT 2012 root@zeus.xxxx.xxx.br:/usr/obj/usr/src/sys/GONDIM > amd64 > > [1] http://www.freebsd.org/cgi/query-pr.cgi?pr=170199 > > Best regards, > Gondim > Hi Gondim, Can you test the following patch? Index: sys/geom/virstor/g_virstor.c =================================================================== --- sys/geom/virstor/g_virstor.c (revision 238909) +++ sys/geom/virstor/g_virstor.c (working copy) @@ -235,6 +235,12 @@ return; } sc = virstor_find_geom(cp, name); + if (sc == NULL) { + gctl_error(req, "Don't know anything about '%s'", name); + g_topology_unlock(); + return; + } + LOG_MSG(LVL_INFO, "Stopping %s by the userland command", sc->geom->name); update_metadata(sc); Thanks, -Jim > > > _______________________________________________ > freebsd-stable@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-stable > To unsubscribe, send any mail to "freebsd-stable-unsubscribe@freebsd.org"
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAJP=Hc-r0zE6tDPQozEbmoSqD%2BHnxzqRzG=mummE7jWzQOsZEQ>