Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S261289AbVBZWwU (ORCPT ); Sat, 26 Feb 2005 17:52:20 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S261291AbVBZWwT (ORCPT ); Sat, 26 Feb 2005 17:52:19 -0500 Received: from hera.cwi.nl ([192.16.191.8]:63939 "EHLO hera.cwi.nl") by vger.kernel.org with ESMTP id S261289AbVBZWwN (ORCPT ); Sat, 26 Feb 2005 17:52:13 -0500 Date: Sat, 26 Feb 2005 23:52:03 +0100 From: Andries Brouwer To: Linus Torvalds Cc: Uwe Bonnes , Andries Brouwer , akpm@osdl.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] partitions/msdos.c Message-ID: <20050226225203.GA25217@apps.cwi.nl> References: <20050226213459.GA21137@apps.cwi.nl> <16928.62091.346922.744462@hertz.ikp.physik.tu-darmstadt.de> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4i Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1135 Lines: 27 On Sat, Feb 26, 2005 at 02:28:45PM -0800, Linus Torvalds wrote: > Would it not make more sense to just sanity-check the size itself, and > throw it out if the partition size (plus start) is bigger than the disk > size? I don't mind. > There might well be people use use partition type 0, just because they > just never _set_ the partition type.. I don't think Linux has ever cared > about any type except for the "extended partition" type, so checking for > zero doesn't seem very safe.. The default fdisk will assign type 83 to a newly created partition. One has to change it by hand to 0. So, I do not think testing against 0 is so bad. A heuristic, You give another heuristic. Probably there will be a point in time where we need both. (About type 0: DOS has used type 0 as definition of unused. It is not bad if Linux uses DOS-conventions for a DOS-type partition table.) Andries - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/