SIM: If SMP is enabled, show CPU on assertion

This commit is contained in:
Gregory Nutt 2016-02-15 13:47:05 -06:00
parent e238b29ddf
commit d2f13e4b12

View File

@ -113,7 +113,13 @@ void up_assert(const uint8_t *filename, int line)
{ {
/* Show the location of the failed assertion */ /* Show the location of the failed assertion */
fprintf(stderr, "Assertion failed at file:%s line: %d\n", filename, line); #ifdef CONFIG_SMP
fprintf(stderr, "CPU%d: Assertion failed at file:%s line: %d\n",
up_cpundx(), filename, line);
#else
fprintf(stderr, "Assertion failed at file:%s line: %d\n",
filename, line);
#endif
/* Allow for any board/configuration specific crash information */ /* Allow for any board/configuration specific crash information */