summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorMilenko Jelisavčić2007-12-10 11:54:57 +0100
committerMilenko Jelisavčić2007-12-10 11:54:57 +0100
commit14b0e8eb96b19b0a2c25c17a0d5f1007bcf6f77e (patch)
tree3968f09f8db3f9eb50cc29df9c421a8b80e2053d /include
parentc449c521844583b8733062b96fe399c45cf85c36 (diff)
Changes for 16MB version. Add some config directives
Diffstat (limited to 'include')
-rw-r--r--include/platform.h39
1 files changed, 28 insertions, 11 deletions
diff --git a/include/platform.h b/include/platform.h
index 72ecfe83cf..42136de201 100644
--- a/include/platform.h
+++ b/include/platform.h
@@ -47,7 +47,31 @@
/* TOP-LEVEL include to set/change the defines related to memory cunsomption/usage */
+#if defined(CONFIG_VERSION_16M)
+
+#define PB_POOL_RING_SIZE (1024)
+
+#define DMA_RX_POOL2_NB_BUFFER 8
+#define DMA_RX_POOL1_NB_BUFFER 16
+#define DMA_RX_POOL0_NB_BUFFER 128
+
+#define DMA_TX_POOL2_NB_BUFFER 8
+#define DMA_TX_POOL1_NB_BUFFER 16
+#define DMA_TX_POOL0_NB_BUFFER 128
+
+#else
+
#define PB_POOL_RING_SIZE (2048)
+
+#define DMA_RX_POOL2_NB_BUFFER 64
+#define DMA_RX_POOL1_NB_BUFFER 64
+#define DMA_RX_POOL0_NB_BUFFER 128
+
+#define DMA_TX_POOL2_NB_BUFFER 64
+#define DMA_TX_POOL1_NB_BUFFER 64
+#define DMA_TX_POOL0_NB_BUFFER 128
+#endif
+
#define PB_DMA_POOL_SIZE (PB_POOL_RING_SIZE*224)
//#define DMA_ZONE_SIZE (0x00300000)
@@ -58,14 +82,6 @@
#define DMA_POOL1_BUFFER_SIZE (4096)
#define DMA_POOL0_BUFFER_SIZE (256)
-#define DMA_RX_POOL2_NB_BUFFER 32
-#define DMA_RX_POOL1_NB_BUFFER 32
-#define DMA_RX_POOL0_NB_BUFFER 128
-
-#define DMA_TX_POOL2_NB_BUFFER 32
-#define DMA_TX_POOL1_NB_BUFFER 32
-#define DMA_TX_POOL0_NB_BUFFER 128
-
#define DMA_RX_POOL2_SIZE (DMA_RX_POOL2_NB_BUFFER * DMA_POOL2_BUFFER_SIZE)
#define DMA_RX_POOL1_SIZE (DMA_RX_POOL1_NB_BUFFER * DMA_POOL1_BUFFER_SIZE)
#define DMA_RX_POOL0_SIZE (DMA_RX_POOL0_NB_BUFFER * DMA_POOL0_BUFFER_SIZE)
@@ -84,9 +100,10 @@
#define DMA_ZONE_USED_SIZE (PLC_DMA_ZONE_SIZE + ETH_DMA_ZONE_SIZE)
#define DMA_ZONE_SIZE (((DMA_ZONE_USED_SIZE + 0x100000 - 1) / 0x100000) * 0x100000)
-#if DMA_ZONE_SIZE != 0x300000
-#error "rrah"
-#endif
+
+//#if DMA_ZONE_SIZE < 0x300000
+//#error "rrah"
+//#endif
#define PLC_DMA_RX_BASE (DMA_zone_base+ETH_DMA_ZONE_SIZE)
#define PLC_DMA_TX_BASE (PLC_DMA_RX_BASE+DMA_RX_POOL_SIZE)