* grub-core/kern/ieee1275/cmain.c (grub_ieee1275_find_options):
Inline name defines used only once.
This commit is contained in:
parent
fe22b071dc
commit
87206f2cf1
2 changed files with 9 additions and 8 deletions
|
@ -1,3 +1,8 @@
|
|||
2013-04-13 Vladimir Serbinenko <phcoder@gmail.com>
|
||||
|
||||
* grub-core/kern/ieee1275/cmain.c (grub_ieee1275_find_options):
|
||||
Inline name defines used only once.
|
||||
|
||||
2013-04-13 Vladimir Serbinenko <phcoder@gmail.com>
|
||||
|
||||
Fix memory leaks in ofnet.
|
||||
|
|
|
@ -43,9 +43,6 @@ grub_ieee1275_set_flag (enum grub_ieee1275_flag flag)
|
|||
grub_ieee1275_flags |= (1 << flag);
|
||||
}
|
||||
|
||||
#define SF "SmartFirmware(tm)"
|
||||
#define OHW "PPC Open Hack'Ware"
|
||||
|
||||
static void
|
||||
grub_ieee1275_find_options (void)
|
||||
{
|
||||
|
@ -76,7 +73,8 @@ grub_ieee1275_find_options (void)
|
|||
|
||||
rc = grub_ieee1275_get_property (openprom, "CodeGen-copyright",
|
||||
tmp, sizeof (tmp), 0);
|
||||
if (rc >= 0 && !grub_strncmp (tmp, SF, sizeof (SF) - 1))
|
||||
if (rc >= 0 && !grub_strncmp (tmp, "SmartFirmware(tm)",
|
||||
sizeof ("SmartFirmware(tm)") - 1))
|
||||
is_smartfirmware = 1;
|
||||
|
||||
rc = grub_ieee1275_get_property (root, "architecture",
|
||||
|
@ -191,7 +189,8 @@ grub_ieee1275_find_options (void)
|
|||
if (! grub_ieee1275_finddevice ("/rom/boot-rom", &bootrom))
|
||||
{
|
||||
rc = grub_ieee1275_get_property (bootrom, "model", tmp, sizeof (tmp), 0);
|
||||
if (rc >= 0 && !grub_strncmp (tmp, OHW, sizeof (OHW) - 1))
|
||||
if (rc >= 0 && !grub_strncmp (tmp, "PPC Open Hack'Ware",
|
||||
sizeof ("PPC Open Hack'Ware") - 1))
|
||||
{
|
||||
grub_ieee1275_set_flag (GRUB_IEEE1275_FLAG_BROKEN_OUTPUT);
|
||||
grub_ieee1275_set_flag (GRUB_IEEE1275_FLAG_CANNOT_SET_COLORS);
|
||||
|
@ -202,9 +201,6 @@ grub_ieee1275_find_options (void)
|
|||
}
|
||||
}
|
||||
|
||||
#undef SF
|
||||
#undef OHW
|
||||
|
||||
void
|
||||
grub_ieee1275_init (void)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue