There are several code style and comment nits. Fix them and also remove
the comment about passing bootstage to the kernel being TBD. This is
already supported.
Signed-off-by: Simon Glass <sjg@chromium.org>
/*
* This module records the progress of boot and arbitrary commands, and
* permits accurate timestamping of each.
/*
* This module records the progress of boot and arbitrary commands, and
* permits accurate timestamping of each.
- *
- * TBD: Pass timings to kernel in the FDT
/* Tell the board about this progress */
show_boot_progress(flags & BOOTSTAGEF_ERROR ? -id : id);
/* Tell the board about this progress */
show_boot_progress(flags & BOOTSTAGEF_ERROR ? -id : id);
if (id == BOOTSTAGE_ID_ALLOC)
flags = BOOTSTAGEF_ALLOC;
if (id == BOOTSTAGE_ID_ALLOC)
flags = BOOTSTAGEF_ALLOC;
return bootstage_add_record(id, name, flags, timer_get_boot_us());
}
return bootstage_add_record(id, name, flags, timer_get_boot_us());
}
rec->start_us = timer_get_boot_us();
rec->name = name;
rec->start_us = timer_get_boot_us();
rec->name = name;
duration = (uint32_t)timer_get_boot_us() - rec->start_us;
rec->time_us += duration;
duration = (uint32_t)timer_get_boot_us() - rec->start_us;
rec->time_us += duration;
#if defined(USE_HOSTCC)
#define show_boot_progress(val) do {} while (0)
#else
#if defined(USE_HOSTCC)
#define show_boot_progress(val) do {} while (0)
#else
* Board code can implement show_boot_progress() if needed.
*
* @param val Progress state (enum bootstage_id), or -id if an error
* Board code can implement show_boot_progress() if needed.
*
* @param val Progress state (enum bootstage_id), or -id if an error
*
* Call this after relocation has happened and after malloc has been initted.
* We need to copy any pointers in bootstage records that were added pre-
*
* Call this after relocation has happened and after malloc has been initted.
* We need to copy any pointers in bootstage records that were added pre-
- * relocation, since memory can be overritten later.
+ * relocation, since memory can be overwritten later.
* @return Always returns 0, to indicate success
*/
int bootstage_relocate(void);
* @return Always returns 0, to indicate success
*/
int bootstage_relocate(void);
ulong bootstage_add_record(enum bootstage_id id, const char *name,
int flags, ulong mark);
ulong bootstage_add_record(enum bootstage_id id, const char *name,
int flags, ulong mark);
* Mark a time stamp for the current boot stage.
*/
ulong bootstage_mark(enum bootstage_id id);
* Mark a time stamp for the current boot stage.
*/
ulong bootstage_mark(enum bootstage_id id);
*/
int bootstage_fdt_add_report(void);
*/
int bootstage_fdt_add_report(void);
* Stash bootstage data into memory
*
* @param base Base address of memory buffer
* Stash bootstage data into memory
*
* @param base Base address of memory buffer