Subject: Re: new kpi proposal, sysdisk(9)
To: David Laight <david@l8s.co.uk>
From: Jason Thorpe <thorpej@shagadelic.org>
List: tech-kern
Date: 01/02/2007 19:16:53
On Jan 2, 2007, at 3:06 PM, David Laight wrote:
> The MBR extended partition is a linked list, not a tree, and is
> (IMHO as
> well) treated if it were just a method of splitting a large chunk of
> disk into pieces.
Well, it's a tree in the sense that each partition itself can have
nested partitions, so you can think of the top-level MBR the
"trunk" (with 4 leaves/branches), and the first MBR sector as being
the "root". That is, unless I fundamentally misunderstand how it
works :-)
> However I think you need to worry about restricting write access to
> ranges of disk blocks, and not to partitions (maybe unless the secure
> level has been raised). In particular:
>
> 1) You need to be able to read and write boot information from
> 'partitions'
> that have mounted filesystems, and (probably) be directly
> accesing the
> relevant offsets from the 'entire disk' device.
> (This means that a ufs mount must release the first 8k...)
This might be done using an ioctl designed for this purpose, as well,
that the file systems participate in.
> 2) You needs to be able to dump directly into disk space occupied by
> the
> 'swap' partition of a raid volume.
And this is a problem how?
> You also don't want to be able to move the base sector of a mounted
> filesystem!
> (I've managed that one!) Nor be able (easily) to write to the disk
> area
> underlying a mounted filesystem.
And this is a problem how?
-- thorpej