Index: /trunk/softs/soft_hello_giet/Makefile
===================================================================
--- /trunk/softs/soft_hello_giet/Makefile	(revision 623)
+++ /trunk/softs/soft_hello_giet/Makefile	(revision 623)
@@ -0,0 +1,36 @@
+LD = mipsel-unknown-elf-ld
+CC = mipsel-unknown-elf-gcc
+AS = mipsel-unknown-elf-as
+DU = mipsel-unknown-elf-objdump
+
+OBJS =   reset.o \
+         giet.o \
+         stdio.o \
+         main.o
+
+CFLAGS = -Wall -mno-gpopt -ffreestanding -fomit-frame-pointer -mips32 -ggdb
+
+GIET =	../giet_tsar
+
+bin.soft: $(OBJS) ldscript
+	$(LD) -o $@ -T ldscript $(OBJS)
+	$(DU) -D $@ > $@.txt
+
+reset.o: $(GIET)/reset.S hard_config.h
+	$(CC) -I. $(CFLAGS) -c -o $@ $<
+	$(DU) -D $@ > $@.txt
+
+giet.o: $(GIET)/giet.S hard_config.h
+	$(CC) -I. $(CFLAGS) -c -o $@ $<
+	$(DU) -D $@ > $@.txt
+
+stdio.o: $(GIET)/stdio.c hard_config.h
+	$(CC) -I. $(CFLAGS) -c -o $@ $<
+	$(DU) -D $@ > $@.txt
+
+main.o: main.c hard_config.h
+	$(CC) -I. $(CFLAGS) -I$(GIET) -c -o $@ $<
+	$(DU) -D $@ > $@.txt
+
+clean:
+	rm -f *.o bin.soft *.txt core term* temp
Index: /trunk/softs/soft_hello_giet/hard_config.h
===================================================================
--- /trunk/softs/soft_hello_giet/hard_config.h	(revision 623)
+++ /trunk/softs/soft_hello_giet/hard_config.h	(revision 623)
@@ -0,0 +1,23 @@
+/*******************************************************************/
+/* This file define various hardware parameters that are used by   */
+/* both the giet_tsar OS and by the hardware (top.cpp file)        */
+/*******************************************************************/
+
+#ifndef _HARD_CONFIG_H
+#define _HARD_CONFIG_H
+
+#define	 X_SIZE              2
+#define	 Y_SIZE              2
+#define	 X_WIDTH             4
+#define	 Y_WIDTH             4
+
+#define	 NB_PROCS_MAX        2
+
+#define	 NB_DMA_CHANNELS     0
+#define	 NB_TTY_CHANNELS     (NB_PROCS_MAX * X_SIZE * Y_SIZE)
+#define	 NB_HBA_CHANNELS     0
+#define	 NB_NIC_CHANNELS     0
+#define	 NB_CMA_CHANNELS     0
+
+
+#endif //_HARD_CONFIG_H
Index: /trunk/softs/soft_hello_giet/ldscript
===================================================================
--- /trunk/softs/soft_hello_giet/ldscript	(revision 623)
+++ /trunk/softs/soft_hello_giet/ldscript	(revision 623)
@@ -0,0 +1,77 @@
+/**********************************************************
+	File : ldscript 
+	Author : Alain Greiner
+	Date : January 2014
+**********************************************************/
+
+/* definition of the base address for all segments 
+The peripherals base addresses are referenced by the
+software drivers and must be defined, even if the 
+peripherals are not present in the architecture */
+
+seg_reset_base  = 0x00000000;       /* boot code */
+
+seg_kcode_base  = 0x00010000;       /* kernel code */
+seg_kdata_base  = 0x00020000;       /* kernel cacheable data */
+seg_kunc_base   = 0x00030000;       /* kernel uncacheable data */
+
+seg_code_base   = 0x00040000;       /* application code */ 
+seg_data_base   = 0x00050000;       /* application data */
+
+seg_heap_base   = 0x00100000;       /* heaps for application tasks */
+seg_stack_base  = 0x00300000;       /* stacks */
+
+seg_xcu_base    = 0xF0000000;       /* controler XCU */
+seg_tty_base    = 0xF2000000;       /* controler TTY */
+seg_fbf_base    = 0xF3000000;       /* controler FBF */
+seg_ioc_base    = 0xF4000000;       /* controler IOC */
+seg_mmc_base    = 0xFF000000;       /* config    MMC */
+
+
+/* Grouping sections into segments */
+
+SECTIONS
+{
+   . = seg_kcode_base;
+   seg_kcode : {
+      *(.giet)
+      *(.switch)
+      *(.drivers)
+      *(.isr)
+   } 
+   . = seg_kdata_base;
+   seg_kdata : {
+      *(.kdata)
+   } 
+   . = seg_kunc_base;
+   seg_kunc : {
+      *(.unckdata)
+   } 
+   . = seg_kdata_base;
+   seg_kdata : {
+      *(.ksave)
+   } 
+   . = seg_code_base;
+   seg_code : {
+      *(.text)
+   } 
+   . = seg_reset_base;
+   seg_reset : {
+      *(.reset)
+   } 
+   . = seg_data_base;
+   seg_data : {
+      *(.rodata)
+      . = ALIGN(4);
+      *(.rodata.*)
+      . = ALIGN(4);
+      *(.data)
+      . = ALIGN(4);
+      *(.sdata)
+      . = ALIGN(4);
+      *(.bss)
+      *(COMMON)
+      *(.sbss)
+   } 
+}
+
Index: /trunk/softs/soft_hello_giet/main.c
===================================================================
--- /trunk/softs/soft_hello_giet/main.c	(revision 623)
+++ /trunk/softs/soft_hello_giet/main.c	(revision 623)
@@ -0,0 +1,29 @@
+#include "hard_config.h"
+#include "stdio.h"
+
+void main()
+{
+    char c;
+    unsigned int proc_id = _procid();
+    unsigned int l       = (proc_id % NB_PROCS_MAX);
+    unsigned int x       = (proc_id / NB_PROCS_MAX) >> Y_WIDTH;
+    unsigned int y       = (proc_id / NB_PROCS_MAX) & ((1<<Y_WIDTH) - 1);
+    while ( 1 )
+    {
+       _tty_printf("hello world... from processor [%d,%d,%d]\n",x,y,l);
+
+       _tty_getc( &c );
+    }
+} // end main()
+
+// Local Variables:
+// tab-width: 3
+// c-basic-offset: 3
+// c-file-offsets:((innamespace . 0)(inline-open . 0))
+// indent-tabs-mode: nil
+// End:
+
+// vim: filetype=cpp:expandtab:shiftwidth=3:tabstop=3:softtabstop=3
+
+
+
Index: /trunk/softs/soft_transpose_giet/Makefile
===================================================================
--- /trunk/softs/soft_transpose_giet/Makefile	(revision 622)
+++ /trunk/softs/soft_transpose_giet/Makefile	(revision 623)
@@ -5,9 +5,7 @@
 
 OBJS =   reset.o \
-	giet.o \
-	isr.o \
-	drivers.o \
-	stdio.o \
-	main.o
+         giet.o \
+         stdio.o \
+         main.o
 
 CFLAGS = -Wall -mno-gpopt -ffreestanding -fomit-frame-pointer -mips32 -ggdb
@@ -19,28 +17,20 @@
 	$(DU) -D $@ > $@.txt
 
-reset.o: $(GIET)/reset.s
-	$(AS) -g -mips32 -o $@ $<
+reset.o: $(GIET)/reset.S hard_config.h
+	$(CC) -I. $(CFLAGS) -c -o $@ $<
 	$(DU) -D $@ > $@.txt
 
-giet.o: $(GIET)/giet.s
-	$(AS) -g -mips32 -o $@ $<
+giet.o: $(GIET)/giet.S hard_config.h
+	$(CC) -I. $(CFLAGS) -c -o $@ $<
 	$(DU) -D $@ > $@.txt
 
-isr.o: $(GIET)/isr.c
-	$(CC) $(CFLAGS) -c -o $@ $<
+stdio.o: $(GIET)/stdio.c hard_config.h
+	$(CC) -I. $(CFLAGS) -c -o $@ $<
 	$(DU) -D $@ > $@.txt
 
-stdio.o: $(GIET)/stdio.c
-	$(CC) $(CFLAGS) -c -o $@ $<
-	$(DU) -D $@ > $@.txt
-
-drivers.o: $(GIET)/drivers.c
-	$(CC) $(CFLAGS) -c -o $@ $<
-	$(DU) -D $@ > $@.txt
-
-main.o: main.c
-	$(CC) $(CFLAGS) -I$(GIET) -c -o $@ $<
+main.o: main.c hard_config.h
+	$(CC) -I. $(CFLAGS) -I$(GIET) -c -o $@ $<
 	$(DU) -D $@ > $@.txt
 
 clean:
-	rm -f *.o bin.soft *.txt core *~ proc* term* temp
+	rm -f *.o bin.soft *.txt core term* temp
Index: /trunk/softs/soft_transpose_giet/ldscript
===================================================================
--- /trunk/softs/soft_transpose_giet/ldscript	(revision 622)
+++ /trunk/softs/soft_transpose_giet/ldscript	(revision 623)
@@ -2,17 +2,6 @@
 	File : ldscript 
 	Author : Alain Greiner
-	Date : March 2011  
+	Date : January 2014
 **********************************************************/
-
-/* definition of various hardware parameters.
-These variables are referenced in the drivers.c file,
-and must be defined, even if the corresponding
-peripherals are not present in the architecture */
-
-NB_CLUSTERS		= 4;		/* number of clusters */
-NB_PROCS		= 4;		/* number of processors per cluster */
-NB_TASKS		= 1;		/* number of tasks per processor */
-NB_TIMERS       	= 1;		/* max number of timers per processor */
-NB_LOCKS        	= 8;		/* number of spin_locks */
 
 /* definition of the base address for all segments 
@@ -21,24 +10,22 @@
 peripherals are not present in the architecture */
 
-seg_code_base   = 0x00000000;       /* le code utilisateur */ 
-seg_data_base   = 0x00100000;       /* les données utilisateur */
+seg_reset_base  = 0x10000000;       /* le code de boot */
 
-seg_heap_base   = 0x00300000;       /* le tas utilisateur */
-seg_stack_base  = 0x00800000;       /* la pile utilisateur */
+seg_kcode_base  = 0x00001000;       /* le code du système */
+seg_kdata_base  = 0x00010000;       /* les donnees du système */
+seg_kunc_base   = 0x00020000;       /* les données non cachées du système */
 
-seg_kcode_base  = 0x80000000;       /* le code du système */
-seg_kdata_base  = 0x80100000;       /* les donnees du système */
-seg_kunc_base   = 0x80200000;       /* les données non cachées du système */
+seg_code_base   = 0x00030000;       /* le code utilisateur */ 
+seg_data_base   = 0x00040000;       /* les données utilisateur */
 
-seg_icu_base    = 0x00F00000;       /* controleur ICU */
-seg_tty_base    = 0xBFF20000;       /* controleur TTY */
-seg_dma_base    = 0x00F30000;       /* controleur DMA */
+seg_heap_base   = 0x00100000;       /* le tas utilisateur */
+seg_stack_base  = 0x00400000;       /* la pile utilisateur */
 
-seg_reset_base  = 0xBFC00000;       /* le code de boot */
-seg_fb_base     = 0xBFD00000;       /* controleur FRAME BUFFER */
-seg_ioc_base    = 0xBFF10000;       /* controleur I/O */
+seg_xcu_base    = 0xF0000000;       /* controleur XCU */
+seg_dma_base    = 0xF1000000;       /* controleur DMA */
+seg_tty_base    = 0xF2000000;       /* controleur TTY */
+seg_fbf_base    = 0xF3000000;       /* controleur FBF */
+seg_ioc_base    = 0xF4000000;       /* controleur IOC */
 
-seg_timer_base  = 0x00F00000;       /* controleur TIMER */
-seg_gcd_base    = 0xBFF50000;       /* controleur GCD */
 
 /* Grouping sections into segments */
Index: /trunk/softs/tsar_boot/include/mips32_registers.h
===================================================================
--- /trunk/softs/tsar_boot/include/mips32_registers.h	(revision 622)
+++ /trunk/softs/tsar_boot/include/mips32_registers.h	(revision 623)
@@ -53,4 +53,5 @@
 #define CP0_EPC         $14,0
 #define CP0_EBASE       $15,1
+#define CP0_PROCID      $15,1
 
 /* CP2 registers */
