spdk_top: rename print_bottom_error_message
Rename print_bottom_error_message() to pint_bottom_message(). This is to avoid confusion, beacuse in the next patch this funciton is used to print messages unrelated to errors. Additionally added clearing bottom before printing given message. Change-Id: Ibaeea03bb92124098fee51f78a6ac773eb288897 Signed-off-by: Krzysztof Karas <krzysztof.karas@intel.com> Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/10016 Tested-by: SPDK CI Jenkins <sys_sgci@intel.com> Reviewed-by: Jim Harris <james.r.harris@intel.com> Reviewed-by: Ben Walker <benjamin.walker@intel.com>
This commit is contained in:
parent
8616736318
commit
de7493e697
@ -2200,8 +2200,13 @@ get_position_for_window(uint64_t window_size, uint64_t max_size)
|
||||
}
|
||||
|
||||
static void
|
||||
print_bottom_error_message(char *msg)
|
||||
print_bottom_message(char *msg)
|
||||
{
|
||||
uint64_t i;
|
||||
|
||||
for (i = 1; i < (uint64_t)g_max_col - 1; i++) {
|
||||
mvprintw(g_max_row - 1, i, " ");
|
||||
}
|
||||
mvprintw(g_max_row - 1, g_max_col - strlen(msg) - 2, "%s", msg);
|
||||
}
|
||||
|
||||
@ -2616,16 +2621,16 @@ data_thread_routine(void *arg)
|
||||
* Start with cores since their number should not change. */
|
||||
rc = get_cores_data();
|
||||
if (rc) {
|
||||
print_bottom_error_message("ERROR occurred while getting cores data");
|
||||
print_bottom_message("ERROR occurred while getting cores data");
|
||||
}
|
||||
rc = get_thread_data();
|
||||
if (rc) {
|
||||
print_bottom_error_message("ERROR occurred while getting threads data");
|
||||
print_bottom_message("ERROR occurred while getting threads data");
|
||||
}
|
||||
|
||||
rc = get_pollers_data();
|
||||
if (rc) {
|
||||
print_bottom_error_message("ERROR occurred while getting pollers data");
|
||||
print_bottom_message("ERROR occurred while getting pollers data");
|
||||
}
|
||||
|
||||
usleep(g_sleep_time * SPDK_SEC_TO_USEC);
|
||||
|
Loading…
Reference in New Issue
Block a user