All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Grégoire Sutre" <gregoire.sutre@gmail.com>
To: The development of GNU GRUB <grub-devel@gnu.org>
Subject: Re: [Patch] Discard incorrect nested partitions (fixes #29956)
Date: Sat, 12 Jun 2010 18:06:23 +0200	[thread overview]
Message-ID: <4C13B07F.4080208@gmail.com> (raw)
In-Reply-To: <4C040166.3030502@gmail.com>

On 05/31/2010 08:35 PM, Vladimir 'φ-coder/phcoder' Serbinenko wrote:

> There are few ramifications of this patch. First of all some
> partitions which are just barely outside of the host partition will
> lead to something like "partition not found" errors in grub-probe.

It's not ideal, but IMHO it's better than getting "unknown filesystem"
in grub-probe -t fs while the partition is detected fine by
-t drive.

> This message should be more informative (the easiest way is to issue
> a warning in grub-probe if partitions are discarded except some cases
> where it's known not to affect the functionality like 'd'
> "subpartitions", probably such a warning in grub proper would be too
> annoying though).

A grub_dprintf when the partition is discarded (in the proposed patch)
would only print the message for relevant partitions.

> Then if you check partitions when iterating no need to recheck in
> adjust_range.

Agreed.

>> The patch still accepts sub-partitions that start at the same
>> (absolute) offset as the parent.  For instance, in the above
>> example, ls -l in grub gives both (hd1,msdos1) and
>> (hd1,msdos1,bsd1).  Should we discard (hd0,msdos1,bsd1), i.e.
>> require that sub-partitions start at a strictly positive relative
>> offset?
> No. SUN partitions comonly start at offset 0.

I don't understand what you mean: here bsd1 also starts at (relative)
offset 0, and the above example actually assumed that.

By the way, when several partition identifiers denote the same
partition, the MBI boot_device field can have different values for the
same physical partition.  This means more work (or assumptions) on the
kernel side to identify the root partition.  In the above example,
(hd1,msdos1,bsd1) would be more explicit to the NetBSD kernel than
(hd1,msdos1).

Grégoire


  reply	other threads:[~2010-06-12 16:06 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-05-28  0:49 [Patch] Discard incorrect nested partitions (fixes #29956) Grégoire Sutre
2010-05-28  1:10 ` Seth Goldberg
2010-05-31 18:35 ` Vladimir 'φ-coder/phcoder' Serbinenko
2010-06-12 16:06   ` Grégoire Sutre [this message]
2010-07-06 21:55   ` Grégoire Sutre
2010-07-08  0:28     ` Vladimir 'φ-coder/phcoder' Serbinenko
2010-07-09 10:53       ` Grégoire Sutre
2010-07-13  9:53         ` Vladimir 'φ-coder/phcoder' Serbinenko
2010-07-14  9:43           ` Grégoire Sutre

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=4C13B07F.4080208@gmail.com \
    --to=gregoire.sutre@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.