Index: /trunk/platforms/tsar_generic_xbar/top.cpp
===================================================================
--- /trunk/platforms/tsar_generic_xbar/top.cpp	(revision 474)
+++ /trunk/platforms/tsar_generic_xbar/top.cpp	(revision 475)
@@ -27,4 +27,5 @@
 // - the disk controller (BDEV)
 // - the multi-channel network controller (MNIC)
+// - the multi-channel chained buffer dma controller (CHBUF)
 // - the multi-channel tty controller (MTTY)
 // - the frame buffer controller (FBUF)
@@ -249,4 +250,7 @@
 #define MNIC_SIZE       0x0000080000   // 512 Kbytes (for 8 channels)
 
+#define CHBUF_BASE       0x00B6000000      
+#define CHBUF_SIZE       0x0000004000  // For 16 Channels 
+
 // replicated segments : address is incremented by a cluster offset 
 //     offset  = cluster(x,y) << (address_width-x_width-y_width);
@@ -274,4 +278,5 @@
 #define MNIC_TGTID      6
 #define BROM_TGTID      7
+#define CHBUF_TGTID      8
 
 /////////////////////////////////
@@ -499,4 +504,6 @@
             maptabd.add(Segment("seg_mnic", MNIC_BASE, MNIC_SIZE, 
                         IntTab(cluster(x,y),MNIC_TGTID), false));
+            maptabd.add(Segment("seg_chbuf", CHBUF_BASE, CHBUF_SIZE, 
+                        IntTab(cluster(x,y),CHBUF_TGTID), false));
             maptabd.add(Segment("seg_brom", BROM_BASE, BROM_SIZE, 
                         IntTab(cluster(x,y),BROM_TGTID), true));
@@ -630,4 +637,5 @@
                 BROM_TGTID,
                 MNIC_TGTID,
+                CHBUF_TGTID,
                 BDEV_TGTID,
                 MEMC_WAYS,
Index: /trunk/platforms/tsar_generic_xbar/tsar_xbar_cluster/caba/metadata/tsar_xbar_cluster.sd
===================================================================
--- /trunk/platforms/tsar_generic_xbar/tsar_xbar_cluster/caba/metadata/tsar_xbar_cluster.sd	(revision 474)
+++ /trunk/platforms/tsar_generic_xbar/tsar_xbar_cluster/caba/metadata/tsar_xbar_cluster.sd	(revision 475)
@@ -67,4 +67,7 @@
               cell_size       = parameter.Reference('vci_data_width_int')),
 
+        Uses('caba:vci_chbuf_dma',
+              cell_size       = parameter.Reference('vci_data_width_int')),
+
 		Uses('caba:vci_block_device_tsar',
               cell_size       = parameter.Reference('vci_data_width_int')),
Index: /trunk/platforms/tsar_generic_xbar/tsar_xbar_cluster/caba/source/include/tsar_xbar_cluster.h
===================================================================
--- /trunk/platforms/tsar_generic_xbar/tsar_xbar_cluster/caba/source/include/tsar_xbar_cluster.h	(revision 474)
+++ /trunk/platforms/tsar_generic_xbar/tsar_xbar_cluster/caba/source/include/tsar_xbar_cluster.h	(revision 475)
@@ -29,4 +29,5 @@
 #include "vci_multi_tty.h"
 #include "vci_multi_nic.h"
+#include "vci_chbuf_dma.h"
 #include "vci_block_device_tsar.h"
 #include "vci_framebuffer.h"
@@ -62,4 +63,5 @@
     sc_signal<bool>         signal_irq_mnic_rx[8];  // unused
     sc_signal<bool>         signal_irq_mnic_tx[8];  // unused
+    sc_signal<bool>         signal_irq_chbuf[8];  // unused
     sc_signal<bool>         signal_irq_bdev;
 
@@ -80,4 +82,5 @@
     VciSignals<vci_param_int>       signal_vci_ini_mdma;
     VciSignals<vci_param_int>       signal_vci_ini_bdev;
+    VciSignals<vci_param_int>       signal_vci_ini_chbuf;
 
     VciSignals<vci_param_int>       signal_vci_tgt_memc;
@@ -89,4 +92,5 @@
     VciSignals<vci_param_int>       signal_vci_tgt_fbuf;
     VciSignals<vci_param_int>       signal_vci_tgt_mnic;
+    VciSignals<vci_param_int>       signal_vci_tgt_chbuf;
 
     // Direct DSPIN signals to local crossbars
@@ -97,4 +101,6 @@
     DspinSignals<dspin_cmd_width>     signal_dspin_cmd_bdev_i;
     DspinSignals<dspin_rsp_width>     signal_dspin_rsp_bdev_i;
+    DspinSignals<dspin_cmd_width>     signal_dspin_cmd_chbuf_i;
+    DspinSignals<dspin_rsp_width>     signal_dspin_rsp_chbuf_i;
 
     DspinSignals<dspin_cmd_width>     signal_dspin_cmd_memc_t;
@@ -114,4 +120,6 @@
     DspinSignals<dspin_cmd_width>     signal_dspin_cmd_mnic_t;
     DspinSignals<dspin_rsp_width>     signal_dspin_rsp_mnic_t;
+    DspinSignals<dspin_cmd_width>     signal_dspin_cmd_chbuf_t;
+    DspinSignals<dspin_rsp_width>     signal_dspin_rsp_chbuf_t;
 
     // Coherence DSPIN signals to local crossbar
@@ -187,4 +195,14 @@
                           dspin_cmd_width,
                           dspin_rsp_width>*       wt_mnic;
+
+    VciChbufDma<vci_param_int>*                   chbuf;
+
+    VciDspinTargetWrapper<vci_param_int,
+                          dspin_cmd_width,
+                          dspin_rsp_width>*       wt_chbuf;
+
+    VciDspinInitiatorWrapper<vci_param_int,
+                          dspin_cmd_width,
+                          dspin_rsp_width>*       wi_chbuf;
 
     VciBlockDeviceTsar<vci_param_int>*            bdev;
@@ -226,4 +244,5 @@
                      size_t                             tgtid_brom,
                      size_t                             tgtid_mnic,
+                     size_t                             tgtid_chbuf,
                      size_t                             tgtid_bdev,
                      size_t                             memc_ways,
Index: /trunk/platforms/tsar_generic_xbar/tsar_xbar_cluster/caba/source/src/tsar_xbar_cluster.cpp
===================================================================
--- /trunk/platforms/tsar_generic_xbar/tsar_xbar_cluster/caba/source/src/tsar_xbar_cluster.cpp	(revision 474)
+++ /trunk/platforms/tsar_generic_xbar/tsar_xbar_cluster/caba/source/src/tsar_xbar_cluster.cpp	(revision 475)
@@ -57,4 +57,5 @@
          size_t                             tgtid_brom,
          size_t                             tgtid_mnic,
+         size_t                             tgtid_chbuf,
          size_t                             tgtid_bdev,
          size_t                             memc_ways,
@@ -214,6 +215,6 @@
     if ( io )
     {
-        nb_direct_initiators         = nb_procs + 2;
-        nb_direct_targets            = 8;
+        nb_direct_initiators         = nb_procs + 3;
+        nb_direct_targets            = 9;
     }
 
@@ -350,4 +351,5 @@
 
         /////////////////////////////////////////////
+        int mac = 0xBEEF0000;
         mnic = new VciMultiNic<vci_param_int>(
                      "mnic",
@@ -357,6 +359,6 @@
                      nic_rx_name,
                      nic_tx_name,
-                     0,             // mac_4 address
-                     0 );           // mac_2 address
+                     mac,             // mac_4 address
+                     0xBABE );           // mac_2 address
 
         wt_mnic = new VciDspinTargetWrapper<vci_param_int,
@@ -364,4 +366,25 @@
                                             dspin_rsp_width>(
                      "wt_mnic",
+                     x_width + y_width + l_width);
+
+        /////////////////////////////////////////////
+        chbuf = new VciChbufDma<vci_param_int>(
+                     "chbuf_dma",
+                     mtd,
+                     IntTab(cluster_id, nb_procs + 2),
+                     IntTab(cluster_id, tgtid_chbuf),
+                     64,
+                     2 * nic_channels ); // Two chbuf dma channel by nic channel
+
+        wt_chbuf = new VciDspinTargetWrapper<vci_param_int,
+                                            dspin_cmd_width,
+                                            dspin_rsp_width>(
+                     "wt_chbuf",
+                     x_width + y_width + l_width);
+
+        wi_chbuf = new VciDspinInitiatorWrapper<vci_param_int,
+                                            dspin_cmd_width,
+                                            dspin_rsp_width>(
+                     "wi_chbuf",
                      x_width + y_width + l_width);
 
@@ -449,6 +472,8 @@
         xbar_cmd_d->p_local_out[tgtid_fbuf]      (signal_dspin_cmd_fbuf_t);
         xbar_cmd_d->p_local_out[tgtid_mnic]      (signal_dspin_cmd_mnic_t);
+        xbar_cmd_d->p_local_out[tgtid_chbuf]      (signal_dspin_cmd_chbuf_t);
 
         xbar_cmd_d->p_local_in[nb_procs+1]       (signal_dspin_cmd_bdev_i);
+        xbar_cmd_d->p_local_in[nb_procs+2]       (signal_dspin_cmd_chbuf_i);
     }
 
@@ -477,6 +502,8 @@
         xbar_rsp_d->p_local_in[tgtid_fbuf]       (signal_dspin_rsp_fbuf_t);
         xbar_rsp_d->p_local_in[tgtid_mnic]       (signal_dspin_rsp_mnic_t);
+        xbar_rsp_d->p_local_in[tgtid_chbuf]       (signal_dspin_rsp_chbuf_t);
 
         xbar_rsp_d->p_local_out[nb_procs+1]      (signal_dspin_rsp_bdev_i);
+        xbar_rsp_d->p_local_out[nb_procs+2]      (signal_dspin_rsp_chbuf_i);
     }
 
@@ -686,4 +713,30 @@
         std::cout << "  - MNIC connected" << std::endl;
 
+        // CHBUF
+        chbuf->p_clk                    (this->p_clk);
+        chbuf->p_resetn                 (this->p_resetn);
+        chbuf->p_vci_target             (signal_vci_tgt_chbuf);
+        chbuf->p_vci_initiator          (signal_vci_ini_chbuf);
+        for ( size_t i=0 ; i < nic_channels * 2 ; i++ )
+        {
+            chbuf->p_irq[i]          (signal_irq_chbuf[i]);
+        }
+
+        // wrapper tgt CHBUF
+        wt_chbuf->p_clk                 (this->p_clk);
+        wt_chbuf->p_resetn              (this->p_resetn);
+        wt_chbuf->p_dspin_cmd           (signal_dspin_cmd_chbuf_t);
+        wt_chbuf->p_dspin_rsp           (signal_dspin_rsp_chbuf_t);
+        wt_chbuf->p_vci                 (signal_vci_tgt_chbuf);
+
+        // wrapper ini CHBUF
+        wi_chbuf->p_clk                 (this->p_clk);
+        wi_chbuf->p_resetn              (this->p_resetn);
+        wi_chbuf->p_dspin_cmd           (signal_dspin_cmd_chbuf_i);
+        wi_chbuf->p_dspin_rsp           (signal_dspin_rsp_chbuf_i);
+        wi_chbuf->p_vci                 (signal_vci_ini_chbuf);
+
+        std::cout << "  - CHBUF connected" << std::endl;
+
         // BROM
         brom->p_clk                    (this->p_clk);
