From owner-cvs-src@FreeBSD.ORG Thu Feb 28 22:30:41 2008 Return-Path: Delivered-To: cvs-src@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B80121065675; Thu, 28 Feb 2008 22:30:41 +0000 (UTC) (envelope-from marcel@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [IPv6:2001:4f8:fff6::29]) by mx1.freebsd.org (Postfix) with ESMTP id 837588FC27; Thu, 28 Feb 2008 22:30:41 +0000 (UTC) (envelope-from marcel@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.14.1/8.14.1) with ESMTP id m1SMUfZR009577; Thu, 28 Feb 2008 22:30:41 GMT (envelope-from marcel@repoman.freebsd.org) Received: (from marcel@localhost) by repoman.freebsd.org (8.14.1/8.14.1/Submit) id m1SMUf7R009576; Thu, 28 Feb 2008 22:30:41 GMT (envelope-from marcel) Message-Id: <200802282230.m1SMUf7R009576@repoman.freebsd.org> From: Marcel Moolenaar Date: Thu, 28 Feb 2008 22:30:41 +0000 (UTC) To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org X-FreeBSD-CVS-Branch: HEAD Cc: Subject: cvs commit: src/sys/geom/part g_part_mbr.c X-BeenThere: cvs-src@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 28 Feb 2008 22:30:42 -0000 marcel 2008-02-28 22:30:41 UTC FreeBSD src repository Modified files: sys/geom/part g_part_mbr.c Log: Better handle false positives. The MBR differs from the boot sector only because there's a partition table where the boot sector has boot code. Boot sectors without boot code look like a MBR for all practical purposes. This change adds a check for the partition table and fails the probe when it's obvously invalid. The assumption being that the sector contains a boot sector and not a MBR. More checks are needed to distinguish a boot secto without boot code from a (empty) MBR. Revision Changes Path 1.3 +24 -6 src/sys/geom/part/g_part_mbr.c