Re: [PATCH] partitions/msdos.c

2005-03-19 Thread Grzegorz Kulewski
On Sat, 19 Mar 2005, Werner Almesberger wrote: Andries Brouwer wrote: The two variants are: (i) partition tells the kernel to do the partition table reading, and (ii) partition uses partx to read the partition table and tells the kernel one-by-one about the partitions found this way. I guess, once

Re: [PATCH] partitions/msdos.c

2005-03-19 Thread Werner Almesberger
Andries Brouwer wrote: > In other words, we need the user space command `partition', > where "partition -t dos /dev/sda" reads a DOS-type partition > table. So if you e.g. hotplug a new device, its partitions won't be accessible before you (or some hotplug manager, etc.) run "partition" ? > The t

Re: [PATCH] partitions/msdos.c

2005-02-28 Thread Rogier Wolff
On Sun, Feb 27, 2005 at 12:40:53AM +0100, Andries Brouwer wrote: > (Concerning the "size" version: it occurred to me that there is one > very minor objection: For extended partitions so far the size did > not normally play a role. Only the starting sector was significant. > If, at some moment we de

Re: [PATCH] partitions/msdos.c

2005-02-27 Thread Uwe Bonnes
> "Linus" == Linus Torvalds <[EMAIL PROTECTED]> writes: Linus> On Sun, 27 Feb 2005, Uwe Bonnes wrote: >> on a Suse 9.2 System with Suse Hotplug, the phantom partition was >> somehow recognized as Reiserfs, and then the Hotplug mechanism trying >> to mount the bogus partition a

Re: [PATCH] partitions/msdos.c

2005-02-26 Thread Andries Brouwer
On Sun, Feb 27, 2005 at 01:47:43AM +0100, Uwe Bonnes wrote: > on a Suse 9.2 System with Suse Hotplug, the phantom partition was somehow > recognized as Reiserfs, and then the Hotplug mechanism trying to mount the > bogus partition as a Reiser Filesystem ended in an Oops... Always report the oops

Re: [PATCH] partitions/msdos.c

2005-02-26 Thread Linus Torvalds
On Sun, 27 Feb 2005, Uwe Bonnes wrote: > > on a Suse 9.2 System with Suse Hotplug, the phantom partition was somehow > recognized as Reiserfs, and then the Hotplug mechanism trying to mount the > bogus partition as a Reiser Filesystem ended in an Oops... Heh. That oops would be interesting in

Re: [PATCH] partitions/msdos.c

2005-02-26 Thread Uwe Bonnes
> "Linus" == Linus Torvalds <[EMAIL PROTECTED]> writes: Linus> On Sun, 27 Feb 2005, Andries Brouwer wrote: >> (Concerning the "size" version: it occurred to me that there is one >> very minor objection: For extended partitions so far the size did not >> normally play a role. O

Re: [PATCH] partitions/msdos.c

2005-02-26 Thread Andries Brouwer
On Sat, Feb 26, 2005 at 03:46:03PM -0800, Linus Torvalds wrote: > We should probably do the same for the > extended partition case, just to be consistent. True. diff -uprN -X /linux/dontdiff a/fs/partitions/msdos.c b/fs/partitions/msdos.c --- a/fs/partitions/msdos.c 2004-12-29 03:39:55.

Re: [PATCH] partitions/msdos.c

2005-02-26 Thread Linus Torvalds
On Sun, 27 Feb 2005, Andries Brouwer wrote: > > (Concerning the "size" version: it occurred to me that there is one > very minor objection: For extended partitions so far the size did > not normally play a role. Only the starting sector was significant. > If, at some moment we decide also to che

Re: [PATCH] partitions/msdos.c

2005-02-26 Thread Linus Torvalds
On Sun, 27 Feb 2005, Uwe Bonnes wrote: > > /dev/sda4 3512348 6003585 698791990+ 0 Empty > Partition 4 has different physical/logical beginnings (non-Linux?): > phys=(0, 0, 0) logical=(3512347, 6, 16) > Partition 4 has different physical/logical endings: > phys=(0, 0, 0)

Re: [PATCH] partitions/msdos.c

2005-02-26 Thread Andries Brouwer
On Sat, Feb 26, 2005 at 03:12:28PM -0800, Linus Torvalds wrote: > > The default fdisk will assign type 83 to a newly created partition. > > Ok. Is that a "it has done so for the last 5 years" thing? The last twelve years. > > (About type 0: DOS has used type 0 as definition of unused. It is no

Re: [PATCH] partitions/msdos.c

2005-02-26 Thread Uwe Bonnes
> "Linus" == Linus Torvalds <[EMAIL PROTECTED]> writes: Linus> On Sat, 26 Feb 2005, 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? Linus> S

Re: [PATCH] partitions/msdos.c

2005-02-26 Thread Linus Torvalds
On Sat, 26 Feb 2005, Andries Brouwer wrote: > > The default fdisk will assign type 83 to a newly created partition. Ok. Is that a "it has done so for the last 5 years" thing? > (About type 0: DOS has used type 0 as definition of unused. It is not > bad if Linux uses DOS-conventions for a DOS-

Re: [PATCH] partitions/msdos.c

2005-02-26 Thread Andries Brouwer
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 bec

Re: [PATCH] partitions/msdos.c

2005-02-26 Thread Linus Torvalds
On Sat, 26 Feb 2005, 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? Something like this (TOTALLY UNTESTED AS USUAL!)? What does fdisk and other tools do on that d

Re: [PATCH] partitions/msdos.c

2005-02-26 Thread Linus Torvalds
On Sat, 26 Feb 2005, Uwe Bonnes wrote: > > Andrew, > > Andries> I think nobody uses such partitions seriously, but nevertheless > Andries> this should probably live in -mm for a while to see if anybody > Andries> complains. > > the partition table of the USB stick in question is va

Re: [PATCH] partitions/msdos.c

2005-02-26 Thread Uwe Bonnes
> "Andries" == Andries Brouwer <[EMAIL PROTECTED]> writes: Andrew, Andries> I think nobody uses such partitions seriously, but nevertheless Andries> this should probably live in -mm for a while to see if anybody Andries> complains. the partition table of the USB stick in question

[PATCH] partitions/msdos.c

2005-02-26 Thread Andries Brouwer
A well-known kernel bug is that it guesses at the partition type and the partitions on any disk it encounters. This is bad because needless I/O is done, slowing down the boot, sometimes quite a lot, especially when I/O errors occur. And it is bad because sometimes we guess wrong. In other words, w