From: phcoder <phcoder@gmail.com>
To: The development of GRUB 2 <grub-devel@gnu.org>
Subject: Design: partitions in partitions
Date: Sat, 14 Feb 2009 19:00:59 +0100 [thread overview]
Message-ID: <499706DB.4030001@gmail.com> (raw)
Hello I would like to implement partition in partitions support (it's on
the TODO list) and necessary as a pre-requisite to access solaris' zfs
partitions. I would also like to integrate current bsd partition support
to it. I propose the following design:
Unified naming scheme: purely numerical. It means that
(hd0,1,a) becomes (hd0,1,1)
get_name is removed from grub_partition_map
Unlimited depth support. It means that partitions like
fdisk in sun in apple in gpt will be detected (silly but is
theoretically possible)
Partitions describing whole parent partition or laying outside of parent
partition will be filtered
An arbitrary limit may be put to avoid endless loop
Add pointer to struct grub_disk * in struct grub_partition.
Then the prototypes in grub_partition_map are:
/* Call HOOK with each partition, until HOOK returns non-zero. */
grub_err_t (*iterate) (grub_partition_t parent,
int (*hook) (struct grub_disk *disk,
const grub_partition_t partition));
/* Return the partition NUM on the partition PARENT. */
grub_partition_t (*probe) (grub_partition_t parent,
int num);
For the first level a fake grub_partition_t describing the whole disk
will be created
What do you think about such a design?
Regards
Vladimir 'phcoder' Serbinenko
reply other threads:[~2009-02-14 18:01 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=499706DB.4030001@gmail.com \
--to=phcoder@gmail.com \
--cc=grub-devel@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.