* util/grub-probe.c (escape_of_path): Don't add ieee1275/.
(probe): Add ieee1275 to OFW devices.
This commit is contained in:
parent
007ae52dac
commit
1c715b5afd
2 changed files with 19 additions and 5 deletions
|
@ -1,3 +1,8 @@
|
||||||
|
2012-06-05 Vladimir Serbinenko <phcoder@gmail.com>
|
||||||
|
|
||||||
|
* util/grub-probe.c (escape_of_path): Don't add ieee1275/.
|
||||||
|
(probe): Add ieee1275 to OFW devices.
|
||||||
|
|
||||||
2012-06-04 Vladimir Serbinenko <phcoder@gmail.com>
|
2012-06-04 Vladimir Serbinenko <phcoder@gmail.com>
|
||||||
|
|
||||||
* util/ieee1275/ofpath.c (of_path_of_scsi): Fix wrong format specifier.
|
* util/ieee1275/ofpath.c (of_path_of_scsi): Fix wrong format specifier.
|
||||||
|
|
|
@ -157,11 +157,10 @@ escape_of_path (const char *orig_path)
|
||||||
if (!strchr (orig_path, ','))
|
if (!strchr (orig_path, ','))
|
||||||
return (char *) xstrdup (orig_path);
|
return (char *) xstrdup (orig_path);
|
||||||
|
|
||||||
new_path = xmalloc (strlen (orig_path) * 2 + sizeof ("ieee1275/"));
|
new_path = xmalloc (strlen (orig_path) * 2 + 1);
|
||||||
|
|
||||||
p = orig_path;
|
p = orig_path;
|
||||||
grub_strcpy (new_path, "ieee1275/");
|
d = new_path;
|
||||||
d = new_path + sizeof ("ieee1275/") - 1;
|
|
||||||
while ((c = *p++) != '\0')
|
while ((c = *p++) != '\0')
|
||||||
{
|
{
|
||||||
if (c == ',')
|
if (c == ',')
|
||||||
|
@ -499,9 +498,14 @@ probe (const char *path, char **device_names, char delim)
|
||||||
|
|
||||||
if (ofpath)
|
if (ofpath)
|
||||||
{
|
{
|
||||||
|
char *tmp = xmalloc (strlen (ofpath) + sizeof ("ieee1275/"));
|
||||||
|
char *p;
|
||||||
|
p = stpcpy (tmp, "ieee1275/");
|
||||||
|
strcpy (p, ofpath);
|
||||||
printf ("--hint-ieee1275='");
|
printf ("--hint-ieee1275='");
|
||||||
print_full_name (ofpath, dev);
|
print_full_name (tmp, dev);
|
||||||
printf ("' ");
|
printf ("' ");
|
||||||
|
free (tmp);
|
||||||
}
|
}
|
||||||
|
|
||||||
biosname = guess_bios_drive (*curdev);
|
biosname = guess_bios_drive (*curdev);
|
||||||
|
@ -611,7 +615,12 @@ probe (const char *path, char **device_names, char delim)
|
||||||
|
|
||||||
if (ofpath)
|
if (ofpath)
|
||||||
{
|
{
|
||||||
print_full_name (ofpath, dev);
|
char *tmp = xmalloc (strlen (ofpath) + sizeof ("ieee1275/"));
|
||||||
|
char *p;
|
||||||
|
p = stpcpy (tmp, "ieee1275/");
|
||||||
|
strcpy (p, ofpath);
|
||||||
|
print_full_name (tmp, dev);
|
||||||
|
free (tmp);
|
||||||
putchar (delim);
|
putchar (delim);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue