aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlistair Popple <alistair@popple.id.au>2014-11-13 17:16:06 +1100
committerStewart Smith <stewart@linux.vnet.ibm.com>2014-12-02 18:44:38 +1100
commite9ba0c924d6eed70cef4e41695196705759e60e6 (patch)
tree8e233651d023227943e70faf4a0ccef4d1ca39db
parentdd173e4beaf1da11db3bcfb2ccdfe8a623f26e53 (diff)
downloadskiboot-e9ba0c924d6eed70cef4e41695196705759e60e6.zip
skiboot-e9ba0c924d6eed70cef4e41695196705759e60e6.tar.gz
skiboot-e9ba0c924d6eed70cef4e41695196705759e60e6.tar.bz2
astbmc: Add a system-id device tree property
The pel logging code requires a system-id device tree property. This should be passed to us from Hostboot but at present we don't seem to get one. This patch adds a default value of "unavailable" if it doesn't exist. Signed-off-by: Alistair Popple <alistair@popple.id.au> Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
-rw-r--r--platforms/astbmc/common.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/platforms/astbmc/common.c b/platforms/astbmc/common.c
index 26f90f5..993ac4c 100644
--- a/platforms/astbmc/common.c
+++ b/platforms/astbmc/common.c
@@ -81,6 +81,15 @@ int64_t astbmc_ipmi_reboot(void)
return ipmi_chassis_control(IPMI_CHASSIS_PWR_CYCLE);
}
+static void astbmc_fixup_dt_system_id(void)
+{
+ /* Make sure we don't already have one */
+ if (dt_find_property(dt_root, "system-id"))
+ return;
+
+ dt_add_property_strings(dt_root, "system-id", "unavailable");
+}
+
static void astbmc_fixup_dt_bt(struct dt_node *lpc)
{
struct dt_node *bt;
@@ -265,6 +274,10 @@ static void astbmc_fixup_dt(void)
/* Add i2c masters if needed */
astbmc_fixup_dt_i2cm();
+
+ /* The pel logging code needs a system-id property to work so
+ make sure we have one. */
+ astbmc_fixup_dt_system_id();
}
static void astbmc_fixup_psi_bar(void)