mirror of
https://github.com/apache/nuttx.git
synced 2026-06-02 01:21:26 +08:00
arch/x86/: Change some *err() message to *info() messages if what was a *dbg() message does not indicate and error condition.
This commit is contained in:
@@ -81,9 +81,9 @@ static void up_stackdump(uint32_t sp, uint32_t stack_base)
|
|||||||
for (stack = sp & ~0x1f; stack < stack_base; stack += 32)
|
for (stack = sp & ~0x1f; stack < stack_base; stack += 32)
|
||||||
{
|
{
|
||||||
uint32_t *ptr = (uint32_t*)stack;
|
uint32_t *ptr = (uint32_t*)stack;
|
||||||
llerr("%08x: %08x %08x %08x %08x %08x %08x %08x %08x\n",
|
alert("%08x: %08x %08x %08x %08x %08x %08x %08x %08x\n",
|
||||||
stack, ptr[0], ptr[1], ptr[2], ptr[3],
|
stack, ptr[0], ptr[1], ptr[2], ptr[3],
|
||||||
ptr[4], ptr[5], ptr[6], ptr[7]);
|
ptr[4], ptr[5], ptr[6], ptr[7]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#else
|
#else
|
||||||
@@ -152,10 +152,10 @@ static void up_dumpstate(void)
|
|||||||
|
|
||||||
/* Show interrupt stack info */
|
/* Show interrupt stack info */
|
||||||
|
|
||||||
llerr("sp: %08x\n", sp);
|
alert("sp: %08x\n", sp);
|
||||||
llerr("IRQ stack:\n");
|
alert("IRQ stack:\n");
|
||||||
llerr(" base: %08x\n", istackbase);
|
alert(" base: %08x\n", istackbase);
|
||||||
llerr(" size: %08x\n", istacksize);
|
alert(" size: %08x\n", istacksize);
|
||||||
|
|
||||||
/* Does the current stack pointer lie within the interrupt
|
/* Does the current stack pointer lie within the interrupt
|
||||||
* stack?
|
* stack?
|
||||||
@@ -172,18 +172,18 @@ static void up_dumpstate(void)
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
sp = g_intstackbase;
|
sp = g_intstackbase;
|
||||||
llerr("sp: %08x\n", sp);
|
alert("sp: %08x\n", sp);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Show user stack info */
|
/* Show user stack info */
|
||||||
|
|
||||||
llerr("User stack:\n");
|
alert("User stack:\n");
|
||||||
llerr(" base: %08x\n", ustackbase);
|
alert(" base: %08x\n", ustackbase);
|
||||||
llerr(" size: %08x\n", ustacksize);
|
alert(" size: %08x\n", ustacksize);
|
||||||
#else
|
#else
|
||||||
llerr("sp: %08x\n", sp);
|
alert("sp: %08x\n", sp);
|
||||||
llerr("stack base: %08x\n", ustackbase);
|
alert("stack base: %08x\n", ustackbase);
|
||||||
llerr("stack size: %08x\n", ustacksize);
|
alert("stack size: %08x\n", ustacksize);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* Dump the user stack if the stack pointer lies within the allocated user
|
/* Dump the user stack if the stack pointer lies within the allocated user
|
||||||
@@ -193,7 +193,7 @@ static void up_dumpstate(void)
|
|||||||
if (sp > ustackbase || sp <= ustackbase - ustacksize)
|
if (sp > ustackbase || sp <= ustackbase - ustacksize)
|
||||||
{
|
{
|
||||||
#if !defined(CONFIG_ARCH_INTERRUPTSTACK) || CONFIG_ARCH_INTERRUPTSTACK < 4
|
#if !defined(CONFIG_ARCH_INTERRUPTSTACK) || CONFIG_ARCH_INTERRUPTSTACK < 4
|
||||||
llerr("ERROR: Stack pointer is not within allocated stack\n");
|
alert("ERROR: Stack pointer is not within allocated stack\n");
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
@@ -263,10 +263,10 @@ void up_assert(const uint8_t *filename, int lineno)
|
|||||||
board_autoled_on(LED_ASSERTION);
|
board_autoled_on(LED_ASSERTION);
|
||||||
|
|
||||||
#if CONFIG_TASK_NAME_SIZE > 0
|
#if CONFIG_TASK_NAME_SIZE > 0
|
||||||
llerr("Assertion failed at file:%s line: %d task: %s\n",
|
alert("Assertion failed at file:%s line: %d task: %s\n",
|
||||||
filename, lineno, rtcb->name);
|
filename, lineno, rtcb->name);
|
||||||
#else
|
#else
|
||||||
llerr("Assertion failed at file:%s line: %d\n",
|
alert("Assertion failed at file:%s line: %d\n",
|
||||||
filename, lineno);
|
filename, lineno);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* arch/x86/src/up_elf.c
|
* arch/x86/src/up_elf.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2012, 2014 Gregory Nutt. All rights reserved.
|
* Copyright (C) 2012, 2014, 2016 Gregory Nutt. All rights reserved.
|
||||||
* Author: Gregory Nutt <gnutt@nuttx.org>
|
* Author: Gregory Nutt <gnutt@nuttx.org>
|
||||||
*
|
*
|
||||||
* Redistribution and use in source and binary forms, with or without
|
* Redistribution and use in source and binary forms, with or without
|
||||||
@@ -146,7 +146,6 @@ int up_relocate(FAR const Elf32_Rel *rel, FAR const Elf32_Sym *sym,
|
|||||||
int up_relocateadd(FAR const Elf32_Rela *rel, FAR const Elf32_Sym *sym,
|
int up_relocateadd(FAR const Elf32_Rela *rel, FAR const Elf32_Sym *sym,
|
||||||
uintptr_t addr)
|
uintptr_t addr)
|
||||||
{
|
{
|
||||||
berr("Not supported\n");
|
bwarn("WARNING: Not supported\n");
|
||||||
return -ENOSYS;
|
return -ENOSYS;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* common/up_exit.c
|
* common/up_exit.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2011, 2013-2014 Gregory Nutt. All rights reserved.
|
* Copyright (C) 2011, 2013-2014, 2016 Gregory Nutt. All rights reserved.
|
||||||
* Author: Gregory Nutt <gnutt@nuttx.org>
|
* Author: Gregory Nutt <gnutt@nuttx.org>
|
||||||
*
|
*
|
||||||
* Redistribution and use in source and binary forms, with or without
|
* Redistribution and use in source and binary forms, with or without
|
||||||
@@ -85,8 +85,8 @@ static void _up_dumponexit(FAR struct tcb_s *tcb, FAR void *arg)
|
|||||||
int i;
|
int i;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
serr(" TCB=%p name=%s pid=%d\n", tcb, tcb->argv[0], tcb->pid);
|
sinfo(" TCB=%p name=%s pid=%d\n", tcb, tcb->argv[0], tcb->pid);
|
||||||
serr(" priority=%d state=%d\n", tcb->sched_priority, tcb->task_state);
|
sinfo(" priority=%d state=%d\n", tcb->sched_priority, tcb->task_state);
|
||||||
|
|
||||||
#if CONFIG_NFILE_DESCRIPTORS > 0
|
#if CONFIG_NFILE_DESCRIPTORS > 0
|
||||||
filelist = tcb->group->tg_filelist;
|
filelist = tcb->group->tg_filelist;
|
||||||
@@ -95,8 +95,8 @@ static void _up_dumponexit(FAR struct tcb_s *tcb, FAR void *arg)
|
|||||||
struct inode *inode = filelist->fl_files[i].f_inode;
|
struct inode *inode = filelist->fl_files[i].f_inode;
|
||||||
if (inode)
|
if (inode)
|
||||||
{
|
{
|
||||||
serr(" fd=%d refcount=%d\n",
|
sinfo(" fd=%d refcount=%d\n",
|
||||||
i, inode->i_crefs);
|
i, inode->i_crefs);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
@@ -109,11 +109,11 @@ static void _up_dumponexit(FAR struct tcb_s *tcb, FAR void *arg)
|
|||||||
if (filep->fs_fd >= 0)
|
if (filep->fs_fd >= 0)
|
||||||
{
|
{
|
||||||
#if CONFIG_STDIO_BUFFER_SIZE > 0
|
#if CONFIG_STDIO_BUFFER_SIZE > 0
|
||||||
serr(" fd=%d nbytes=%d\n",
|
sinfo(" fd=%d nbytes=%d\n",
|
||||||
filep->fs_fd,
|
filep->fs_fd,
|
||||||
filep->fs_bufpos - filep->fs_bufstart);
|
filep->fs_bufpos - filep->fs_bufstart);
|
||||||
#else
|
#else
|
||||||
serr(" fd=%d\n", filep->fs_fd);
|
sinfo(" fd=%d\n", filep->fs_fd);
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -146,10 +146,10 @@ void _exit(int status)
|
|||||||
|
|
||||||
(void)up_irq_save();
|
(void)up_irq_save();
|
||||||
|
|
||||||
sllerr("TCB=%p exiting\n", this_task());
|
sllinfo("TCB=%p exiting\n", this_task());
|
||||||
|
|
||||||
#if defined(CONFIG_DUMP_ON_EXIT) && defined(CONFIG_DEBUG_FEATURES)
|
#if defined(CONFIG_DUMP_ON_EXIT) && defined(CONFIG_DEBUG_FEATURES)
|
||||||
sllerr("Other tasks:\n");
|
sllinfo("Other tasks:\n");
|
||||||
sched_foreach(_up_dumponexit, NULL);
|
sched_foreach(_up_dumponexit, NULL);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|||||||
@@ -76,13 +76,13 @@ static void up_calibratedelay(void)
|
|||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
llerr("Beginning 100s delay\n");
|
llwarn("Beginning 100s delay\n");
|
||||||
for (i = 0; i < 100; i++)
|
for (i = 0; i < 100; i++)
|
||||||
{
|
{
|
||||||
up_mdelay(1000);
|
up_mdelay(1000);
|
||||||
}
|
}
|
||||||
|
|
||||||
llerr("End 100s delay\n");
|
llwarn("End 100s delay\n");
|
||||||
}
|
}
|
||||||
#else
|
#else
|
||||||
# define up_calibratedelay()
|
# define up_calibratedelay()
|
||||||
|
|||||||
@@ -67,7 +67,7 @@ void up_release_pending(void)
|
|||||||
{
|
{
|
||||||
struct tcb_s *rtcb = this_task();
|
struct tcb_s *rtcb = this_task();
|
||||||
|
|
||||||
sllerr("From TCB=%p\n", rtcb);
|
sllinfo("From TCB=%p\n", rtcb);
|
||||||
|
|
||||||
/* Merge the g_pendingtasks list into the ready-to-run task list */
|
/* Merge the g_pendingtasks list into the ready-to-run task list */
|
||||||
|
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* arch/arm/src/arm/up_reprioritizertr.c
|
* arch/arm/src/arm/up_reprioritizertr.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2011, 2013-2015 Gregory Nutt. All rights reserved.
|
* Copyright (C) 2011, 2013-2016 Gregory Nutt. All rights reserved.
|
||||||
* Author: Gregory Nutt <gnutt@nuttx.org>
|
* Author: Gregory Nutt <gnutt@nuttx.org>
|
||||||
*
|
*
|
||||||
* Redistribution and use in source and binary forms, with or without
|
* Redistribution and use in source and binary forms, with or without
|
||||||
@@ -95,7 +95,7 @@ void up_reprioritize_rtr(struct tcb_s *tcb, uint8_t priority)
|
|||||||
struct tcb_s *rtcb = this_task();
|
struct tcb_s *rtcb = this_task();
|
||||||
bool switch_needed;
|
bool switch_needed;
|
||||||
|
|
||||||
sllerr("TCB=%p PRI=%d\n", tcb, priority);
|
sllinfo("TCB=%p PRI=%d\n", tcb, priority);
|
||||||
|
|
||||||
/* Remove the tcb task from the ready-to-run list.
|
/* Remove the tcb task from the ready-to-run list.
|
||||||
* sched_removereadytorun will return true if we just
|
* sched_removereadytorun will return true if we just
|
||||||
|
|||||||
@@ -101,7 +101,7 @@ void up_schedule_sigaction(struct tcb_s *tcb, sig_deliver_t sigdeliver)
|
|||||||
{
|
{
|
||||||
irqstate_t flags;
|
irqstate_t flags;
|
||||||
|
|
||||||
serr("tcb=0x%p sigdeliver=0x%p\n", tcb, sigdeliver);
|
sinfo("tcb=0x%p sigdeliver=0x%p\n", tcb, sigdeliver);
|
||||||
|
|
||||||
/* Make sure that interrupts are disabled */
|
/* Make sure that interrupts are disabled */
|
||||||
|
|
||||||
@@ -115,7 +115,7 @@ void up_schedule_sigaction(struct tcb_s *tcb, sig_deliver_t sigdeliver)
|
|||||||
* to the currently executing task.
|
* to the currently executing task.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
serr("rtcb=0x%p g_current_regs=0x%p\n", this_task(), g_current_regs);
|
sinfo("rtcb=0x%p g_current_regs=0x%p\n", this_task(), g_current_regs);
|
||||||
|
|
||||||
if (tcb == this_task())
|
if (tcb == this_task())
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -95,7 +95,7 @@ void up_sigdeliver(void)
|
|||||||
|
|
||||||
board_autoled_on(LED_SIGNAL);
|
board_autoled_on(LED_SIGNAL);
|
||||||
|
|
||||||
serr("rtcb=%p sigdeliver=%p sigpendactionq.head=%p\n",
|
sinfo("rtcb=%p sigdeliver=%p sigpendactionq.head=%p\n",
|
||||||
rtcb, rtcb->xcp.sigdeliver, rtcb->sigpendactionq.head);
|
rtcb, rtcb->xcp.sigdeliver, rtcb->sigpendactionq.head);
|
||||||
ASSERT(rtcb->xcp.sigdeliver != NULL);
|
ASSERT(rtcb->xcp.sigdeliver != NULL);
|
||||||
|
|
||||||
@@ -126,7 +126,7 @@ void up_sigdeliver(void)
|
|||||||
* errno that is needed by the user logic (it is probably EINTR).
|
* errno that is needed by the user logic (it is probably EINTR).
|
||||||
*/
|
*/
|
||||||
|
|
||||||
serr("Resuming\n");
|
sinfo("Resuming\n");
|
||||||
(void)up_irq_save();
|
(void)up_irq_save();
|
||||||
rtcb->pterrno = saved_errno;
|
rtcb->pterrno = saved_errno;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user