[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Minios-devel] [UNIKRAFT PATCH] lib/uksched: Add newlines at end of messages in sched.c
Hi Simon, looks good, thanks. -- Felipe Reviewed-by: Felipe Huici <felipe.huici@xxxxxxxxx> On Sat, Feb 8, 2020 at 11:42 AM Simon Kuenzer <simon.kuenzer@xxxxxxxxx> wrote: > > Adds newlines at the end of messages in sched.c. The message level is > also increased from warning to error because things are failing. > > Signed-off-by: Simon Kuenzer <simon.kuenzer@xxxxxxxxx> > --- > lib/uksched/sched.c | 14 ++++++++------ > 1 file changed, 8 insertions(+), 6 deletions(-) > > diff --git a/lib/uksched/sched.c b/lib/uksched/sched.c > index 94ac5aaa..5903fe5a 100644 > --- a/lib/uksched/sched.c > +++ b/lib/uksched/sched.c > @@ -119,7 +119,7 @@ struct uk_sched *uk_sched_create(struct uk_alloc *a, > size_t prv_size) > > sched = uk_malloc(a, sizeof(struct uk_sched) + prv_size); > if (sched == NULL) { > - uk_pr_warn("Could not allocate scheduler."); > + uk_pr_warn("Failed to allocate scheduler\n"); > return NULL; > } > > @@ -143,7 +143,7 @@ static void *create_stack(struct uk_alloc *allocator) > > uk_posix_memalign(allocator, &stack, STACK_SIZE, STACK_SIZE); > if (stack == NULL) { > - uk_pr_warn("Error allocating thread stack."); > + uk_pr_err("Failed to allocate thread stack\n"); > return NULL; > } > > @@ -155,8 +155,10 @@ static void *uk_thread_tls_create(struct uk_alloc > *allocator) > void *tls; > > if (uk_posix_memalign(allocator, &tls, ukarch_tls_area_align(), > - ukarch_tls_area_size())) > + ukarch_tls_area_size())) { > + uk_pr_err("Failed to allocate thread TLS area\n"); > return NULL; > + } > ukarch_tls_area_copy(tls); > return tls; > } > @@ -188,7 +190,7 @@ void uk_sched_idle_init(struct uk_sched *sched, > return; > > out_crash: > - UK_CRASH("Error initializing the idle thread."); > + UK_CRASH("Failed to initialize `idle` thread\n"); > } > > struct uk_thread *uk_sched_thread_create(struct uk_sched *sched, > @@ -202,7 +204,7 @@ struct uk_thread *uk_sched_thread_create(struct uk_sched > *sched, > > thread = uk_malloc(sched->allocator, sizeof(struct uk_thread)); > if (thread == NULL) { > - uk_pr_warn("Error allocating memory for thread."); > + uk_pr_err("Failed to allocate thread\n"); > goto err; > } > > @@ -277,5 +279,5 @@ void uk_sched_thread_exit(void) > thread = uk_thread_current(); > UK_ASSERT(thread->sched); > uk_sched_thread_remove(thread->sched, thread); > - UK_CRASH("Error stopping thread."); > + UK_CRASH("Failed to stop the thread\n"); > } > -- > 2.20.1 > > > _______________________________________________ > Minios-devel mailing list > Minios-devel@xxxxxxxxxxxxxxxxxxxx > https://lists.xenproject.org/mailman/listinfo/minios-devel _______________________________________________ Minios-devel mailing list Minios-devel@xxxxxxxxxxxxxxxxxxxx https://lists.xenproject.org/mailman/listinfo/minios-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |