summaryrefslogtreecommitdiffstats
path: root/sys/geom/part
diff options
context:
space:
mode:
authormarcel <marcel@FreeBSD.org>2008-09-29 02:48:22 +0000
committermarcel <marcel@FreeBSD.org>2008-09-29 02:48:22 +0000
commit1fe9adfff0df06eb3b50066d40218df2a484acd0 (patch)
tree2edb94d65dae0f5bce83042d0bb2f2cf2da8063d /sys/geom/part
parent8e1dbe3531a0768c9786845e79e78d58841ebc52 (diff)
downloadFreeBSD-src-1fe9adfff0df06eb3b50066d40218df2a484acd0.zip
FreeBSD-src-1fe9adfff0df06eb3b50066d40218df2a484acd0.tar.gz
Return G_PART_PROBE_PRI_HIGH instead of G_PART_PROBE_PRI_NORM
if the probe succeeds. This guarantees that the BSD scheme wins over the MBR scheme when MBR gets to probe first. Build- or link-time conditions can cause schemes to end up in the linker set in a different order. Normally BSD is before MBR in the linker set and as such get to probe first. But typically when the kernel gets rebuild or relinked, this can change.
Diffstat (limited to 'sys/geom/part')
-rw-r--r--sys/geom/part/g_part_bsd.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/geom/part/g_part_bsd.c b/sys/geom/part/g_part_bsd.c
index 1854dcc..f7213e3 100644
--- a/sys/geom/part/g_part_bsd.c
+++ b/sys/geom/part/g_part_bsd.c
@@ -293,7 +293,7 @@ g_part_bsd_probe(struct g_part_table *table, struct g_consumer *cp)
magic2 = le32dec(buf + 132);
g_free(buf);
return ((magic1 == DISKMAGIC && magic2 == DISKMAGIC)
- ? G_PART_PROBE_PRI_NORM : ENXIO);
+ ? G_PART_PROBE_PRI_HIGH : ENXIO);
}
static int
OpenPOWER on IntegriCloud