Index: trunk/kernel/kern/kernel_init.c
===================================================================
--- trunk/kernel/kern/kernel_init.c	(revision 409)
+++ trunk/kernel/kern/kernel_init.c	(revision 428)
@@ -205,8 +205,7 @@
         if (func == DEV_FUNC_TXT )
         {
-            assert( (channels > 0) , __FUNCTION__ ,
-                    "numner of TXT channels cannot be 0\n");
-
-            // initializes TXT0 basic fields
+            assert( (channels > 0) , __FUNCTION__ , "number of TXT channels cannot be 0\n");
+
+            // initializes TXT_TX[0] chdev
             txt0_chdev.func    = func;
             txt0_chdev.impl    = impl;
@@ -366,5 +365,4 @@
 	uint32_t        directions;      // number of directions (1 or 2)
 	uint32_t        rx;              // direction index (0 or 1)
-    uint32_t        first_channel;   // used in loop on channels for TXT
     chdev_t       * chdev;           // local pointer on one channel_device descriptor
     uint32_t        ext_chdev_gid;   // global index of external chdev
@@ -388,8 +386,4 @@
         if((func == DEV_FUNC_NIC) || (func == DEV_FUNC_TXT)) directions = 2;
         else                                                 directions = 1;
-
-        // The TXT0 chdev has already been created
-        if (func == DEV_FUNC_TXT) first_channel = 1;
-        else                      first_channel = 0;
 
         // do nothing for ROM, that does not require a device descriptor.
@@ -412,9 +406,12 @@
 
         // loops on channels
-        for( channel = first_channel ; channel < channels ; channel++ )
+        for( channel = 0 ; channel < channels ; channel++ )
         {
             // loop on directions
             for( rx = 0 ; rx < directions ; rx++ )
             {
+                // skip TXT_TX[0] chdev that has already been created & registered
+                if( (func == DEV_FUNC_TXT) && (channel == 0) && (rx == 0) ) continue;
+
                 // compute target cluster for chdev[func,channel,direction]
                 uint32_t offset     = ext_chdev_gid % ( info->x_size * info->y_size );
@@ -587,5 +584,5 @@
             else if((func == DEV_FUNC_NIC) && (is_rx != 0)) ptr = &iopic_input.nic_rx[channel]; 
             else if( func == DEV_FUNC_IOB )                 ptr = &iopic_input.iob; 
-            else     panic( "illegal source device for IOPIC input" );
+            else     assert( false , __FUNCTION__ , "illegal source device for IOPIC input" );
 
             // set one entry in all "iopic_input" structures
@@ -796,6 +793,7 @@
     if( error )
     {
-        panic("illegal core identifiers gid = %x / cxy = %x / lid = %d",
-              core_lid , core_cxy , core_lid );
+        assert( false , __FUNCTION__ ,
+        "illegal core identifiers gid = %x / cxy = %x / lid = %d",
+        core_lid , core_cxy , core_lid );
     }
 
@@ -807,5 +805,6 @@
         if( error )
         {
-            panic("cannot initialise cluster %x", local_cxy );
+            assert( false , __FUNCTION__ ,
+            "cannot initialise cluster %x", local_cxy );
         }
     }
@@ -831,5 +830,5 @@
 
     // all CP0s initialize the process_zero descriptor
-    if( core_lid == 0 ) process_zero_init( &process_zero );
+    if( core_lid == 0 ) process_zero_create( &process_zero );
 
     // CP0 in cluster 0 initializes the PIC chdev,
@@ -900,6 +899,6 @@
     if( error )
     {
-        panic("core[%x][%d] cannot initialize idle thread",
-              local_cxy , core_lid );
+        assert( false , __FUNCTION__ ,
+        "core[%x][%d] cannot initialize idle thread", local_cxy , core_lid );
     }
 
@@ -965,5 +964,6 @@
         else
         {
-            panic("root FS must be FATFS");
+            assert( false , __FUNCTION__ ,
+            "root FS must be FATFS" );
         }
 
@@ -1113,10 +1113,15 @@
 
     /////////////////////////////////////////////////////////////////////////////////
-    // STEP 8 : CP0 in I/O cluster creates the first user process (process_init)
-    /////////////////////////////////////////////////////////////////////////////////
-
-    if( (core_lid ==  0) && (local_cxy == io_cxy) ) 
-    {
-        process_init_create();
+    // STEP 8 : CP0 in cluster 0 creates the first user process (process_init)
+    /////////////////////////////////////////////////////////////////////////////////
+
+    if( (core_lid ==  0) && (local_cxy == 0) ) 
+    {
+
+#if CONFIG_KINIT_DEBUG
+vfs_display( vfs_root_inode_xp );
+#endif
+
+       process_init_create();
     }
 
@@ -1127,8 +1132,4 @@
     /////////////////////////////////////////////////////////////////////////////////
 
-#if CONFIG_KINIT_DEBUG
-sched_display( core_lid );
-#endif
-
     if( (core_lid ==  0) && (local_cxy == 0) ) 
     kinit_dmsg("\n[DBG] %s : exit barrier 8 : process init created / cycle %d\n", 
@@ -1144,6 +1145,4 @@
 
 #if CONFIG_KINIT_DEBUG
-
-        vfs_display( vfs_root_inode_xp );
 
         printk("\n\n***** memory fooprint for main kernel objects\n\n"
