summaryrefslogtreecommitdiffstats
path: root/include/bootstage.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/bootstage.h')
-rw-r--r--include/bootstage.h30
1 files changed, 28 insertions, 2 deletions
diff --git a/include/bootstage.h b/include/bootstage.h
index 8f7fcd7d77..b56d95351c 100644
--- a/include/bootstage.h
+++ b/include/bootstage.h
@@ -178,9 +178,35 @@ enum bootstage_id {
* has occurred.
*/
void show_boot_progress(int val);
-static inline void show_boot_error(int val)
+
+#ifdef CONFIG_BOOTSTAGE
+/* This is the full bootstage implementation */
+
+/*
+ * Mark a time stamp for the current boot stage.
+ */
+ulong bootstage_mark(enum bootstage_id id);
+
+ulong bootstage_error(enum bootstage_id id);
+
+#else
+/*
+ * This is a dummy implementation which just calls show_boot_progress(),
+ * and won't even do that unless CONFIG_SHOW_BOOT_PROGRESS is defined
+ */
+
+static inline ulong bootstage_mark(enum bootstage_id id)
+{
+ show_boot_progress(id);
+ return 0;
+}
+
+static inline ulong bootstage_error(enum bootstage_id id)
{
- show_boot_progress(-val);
+ show_boot_progress(-id);
+ return 0;
}
+#endif /* CONFIG_BOOTSTAGE */
+
#endif
OpenPOWER on IntegriCloud