All of lore.kernel.org
 help / color / mirror / Atom feed
From: Robert Millan <rmh@aybabtu.com>
To: The development of GRUB 2 <grub-devel@gnu.org>
Subject: Re: [PATCH] grub-probe -t prefix, -t all
Date: Fri, 9 Nov 2007 22:13:02 +0100	[thread overview]
Message-ID: <20071109211302.GC23437@thorin> (raw)
In-Reply-To: <47264070.7060007@t-online.de>

On Mon, Oct 29, 2007 at 09:20:00PM +0100, Christian Franke wrote:
> This patch adds '-t prefix', '-t all', and allows multiple -t options to 
> be specified.
> 
> '-t prefix' was initially added to test grub_get_prefix() on Cygwin, but 
> may be useful in scripts.

What does -t prefix do?  Is it the same as
make_system_path_relative_to_its_root () ?  Sounds like I screwed up then :-/

> +#define PRINT_FS	0x01
> +#define PRINT_DRIVE	0x02
> +#define PRINT_PREFIX	0x04
> +#define PRINT_DEVICE	0x08
> +#define PRINT_PARTMAP	0x10

In general, GRUB bitmasks are declared as (1 << 0), (1 << 1), etc.  It'd be
nice to keep this consistent.
 
>    drive_name = grub_util_get_grub_dev (device_name);
>    if (! drive_name)
>      grub_util_error ("cannot find a GRUB drive for %s.\n", device_name);

This check (and possibly others) is an abort condition.  Before your change,
if we reached this point we knew we wanted to abort, but this may not be
true anymore.  Did you check this?

> +  -t, --target=(fs|drive|prefix|device|partmap|all)\n\
> +                            print filesystem module, GRUB drive, path prefix, system device\n\
> +                            or partition map module [default=fs]\n\

Uhm what's the purpose of `-t all' ?  grub-probe is only intended to be
called by scripts.

-- 
Robert Millan

<GPLv2> I know my rights; I want my phone call!
<DRM> What use is a phone call, if you are unable to speak?
(as seen on /.)



  reply	other threads:[~2007-11-09 21:13 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-10-29 20:20 [PATCH] grub-probe -t prefix, -t all Christian Franke
2007-11-09 21:13 ` Robert Millan [this message]
2007-11-09 21:42   ` Christian Franke
2007-11-09 22:56     ` Robert Millan
2007-11-10  0:03       ` Christian Franke

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=20071109211302.GC23437@thorin \
    --to=rmh@aybabtu.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.