Date: Sun, 6 May 2012 08:31:57 +0000 (UTC) From: Doug Barton <dougb@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org Subject: svn commit: r235074 - stable/8/sys/geom/part Message-ID: <201205060831.q468Vv2v004268@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: dougb Date: Sun May 6 08:31:57 2012 New Revision: 235074 URL: http://svn.freebsd.org/changeset/base/235074 Log: MFC r231929: If nested scheme allows dump kernel to its partition, we may allow dump for the parent partition too. Modified: stable/8/sys/geom/part/g_part.c Directory Properties: stable/8/sys/ (props changed) Modified: stable/8/sys/geom/part/g_part.c ============================================================================== --- stable/8/sys/geom/part/g_part.c Sun May 6 08:28:08 2012 (r235073) +++ stable/8/sys/geom/part/g_part.c Sun May 6 08:31:57 2012 (r235074) @@ -2048,9 +2048,12 @@ g_part_start(struct bio *bp) /* * Check that the partition is suitable for kernel * dumps. Typically only swap partitions should be - * used. + * used. If the request comes from the nested scheme + * we allow dumping there as well. */ - if (!G_PART_DUMPTO(table, entry)) { + if ((bp->bio_from == NULL || + bp->bio_from->geom->class != &g_part_class) && + G_PART_DUMPTO(table, entry) == 0) { g_io_deliver(bp, ENODEV); printf("GEOM_PART: Partition '%s' not suitable" " for kernel dumps (wrong type?)\n",
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201205060831.q468Vv2v004268>