[PATCH] bsps: Print CPU in default fatal error extension

Sebastian Huber sebastian.huber at embedded-brains.de
Wed Dec 9 13:28:34 UTC 2020


---
 bsps/shared/start/bspfatal-default.c | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/bsps/shared/start/bspfatal-default.c b/bsps/shared/start/bspfatal-default.c
index f5f7e58812..0289dbda63 100644
--- a/bsps/shared/start/bspfatal-default.c
+++ b/bsps/shared/start/bspfatal-default.c
@@ -26,9 +26,16 @@ void bsp_fatal_extension(
     printk(
       "\n"
       "*** FATAL ***\n"
-      "fatal source: %i (%s)\n",
+      "fatal source: %i (%s)\n"
+      #ifdef RTEMS_SMP
+        "CPU: %" PRIu32 "\n"
+      #endif
+      ,
       source,
       rtems_fatal_source_text( source )
+      #ifdef RTEMS_SMP
+        , rtems_scheduler_get_processor()
+      #endif
     );
   #endif
 
-- 
2.26.2



More information about the devel mailing list