From c618ee05943cb7eae9e9b28fe06c0b960d71c116 Mon Sep 17 00:00:00 2001
From: Andreas Faerber <andreas.faerber@web.de>
Date: Thu, 3 Jun 2010 14:09:32 +0200
Subject: [PATCH] Initialize machine to unknown before return
---
src/system/boot/platform/openfirmware/start.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/system/boot/platform/openfirmware/start.c b/src/system/boot/platform/openfirmware/start.c
index 7a8dc2e..4782a74 100644
a
|
b
|
clear_bss(void)
|
54 | 54 | static void |
55 | 55 | determine_machine(void) |
56 | 56 | { |
| 57 | gMachine = MACHINE_UNKNOWN; |
| 58 | |
57 | 59 | int root = of_finddevice("/"); |
58 | 60 | char buffer[64]; |
59 | 61 | int length; |
… |
… |
determine_machine(void)
|
63 | 65 | |
64 | 66 | // ToDo: add more, and be as generic as possible |
65 | 67 | |
66 | | gMachine = MACHINE_UNKNOWN; |
67 | | |
68 | 68 | if (!strcasecmp("chrp", buffer)) |
69 | 69 | gMachine = MACHINE_CHRP; |
70 | 70 | else if (!strcasecmp("bootrom", buffer)) |