[rtems commit] arm/lpc176x: Adding "eth" linker script section.

Sebastian Huber sebh at rtems.org
Wed Sep 10 05:08:05 UTC 2014


Module:    rtems
Branch:    master
Commit:    f59e64f2684bd90e70f85c01536ffc58cf06ae5a
Changeset: http://git.rtems.org/rtems/commit/?id=f59e64f2684bd90e70f85c01536ffc58cf06ae5a

Author:    Federico Casares <federico.casares at tallertechnologies.com>
Date:      Tue Sep  9 10:48:21 2014 -0300

arm/lpc176x: Adding "eth" linker script section.

---

 c/src/lib/libbsp/arm/lpc176x/Makefile.am           |    1 +
 .../lpc176x/make/custom/lpc1768_mbed_ahb_ram.cfg   |   16 +--------
 .../custom/lpc1768_mbed_ahb_ram_eth-testsuite.tcfg |   23 ++++++++++++
 .../make/custom/lpc1768_mbed_ahb_ram_eth.cfg       |    5 +++
 .../startup/linkcmds.lpc1768_mbed_ahb_ram_eth      |   39 ++++++++++++++++++++
 5 files changed, 69 insertions(+), 15 deletions(-)

diff --git a/c/src/lib/libbsp/arm/lpc176x/Makefile.am b/c/src/lib/libbsp/arm/lpc176x/Makefile.am
index 3a1d4b2..36711a6 100644
--- a/c/src/lib/libbsp/arm/lpc176x/Makefile.am
+++ b/c/src/lib/libbsp/arm/lpc176x/Makefile.am
@@ -69,6 +69,7 @@ project_lib_DATA += startup/linkcmds
 EXTRA_DIST =
 EXTRA_DIST += startup/linkcmds.lpc1768_mbed
 EXTRA_DIST += startup/linkcmds.lpc1768_mbed_ahb_ram
+EXTRA_DIST += startup/linkcmds.lpc1768_mbed_ahb_ram_eth
 
 
 # ----------------------------
diff --git a/c/src/lib/libbsp/arm/lpc176x/make/custom/lpc1768_mbed_ahb_ram.cfg b/c/src/lib/libbsp/arm/lpc176x/make/custom/lpc1768_mbed_ahb_ram.cfg
index 4cf24c8..e187d1f 100644
--- a/c/src/lib/libbsp/arm/lpc176x/make/custom/lpc1768_mbed_ahb_ram.cfg
+++ b/c/src/lib/libbsp/arm/lpc176x/make/custom/lpc1768_mbed_ahb_ram.cfg
@@ -2,18 +2,4 @@
 # Config file for mbed LPC1768 board.
 #
 
-include $(RTEMS_ROOT)/make/custom/default.cfg
-
-RTEMS_CPU = arm
-
-CPU_CFLAGS = -march=armv7-m -mthumb
-
-CFLAGS_OPTIMIZE_V = -O2 -ggdb3 -DNDEBUG
-BINEXT?=.bin
-# This defines the operations performed on the linked executable.
-# is currently required.
-define bsp-post-link
-    $(OBJCOPY) -O binary --strip-all \
-        $(basename $@)$(EXEEXT) $(basename $@)$(BINEXT)
-    $(SIZE) $(basename $@)$(EXEEXT)
-endef
+include $(RTEMS_ROOT)/make/custom/lpc1768_mbed.cfg
diff --git a/c/src/lib/libbsp/arm/lpc176x/make/custom/lpc1768_mbed_ahb_ram_eth-testsuite.tcfg b/c/src/lib/libbsp/arm/lpc176x/make/custom/lpc1768_mbed_ahb_ram_eth-testsuite.tcfg
new file mode 100644
index 0000000..8d4c215
--- /dev/null
+++ b/c/src/lib/libbsp/arm/lpc176x/make/custom/lpc1768_mbed_ahb_ram_eth-testsuite.tcfg
@@ -0,0 +1,23 @@
+#
+# lpc1768_mbed_ahb_ram_eth RTEMS Test Database
+#
+# Format is one line per test that is _NOT_ built.
+#
+
+fileio
+cdtest
+flashdisk01
+fsdosfsname01
+jffs2_fserror
+jffs2_fslink
+jffs2_fspatheval
+jffs2_fspermission
+jffs2_fsrdwr
+jffs2_fssymlink
+jffs2_fstime
+mghttpd01
+pppd
+spstkalloc02
+utf8proc01
+iostream
+rtems++
diff --git a/c/src/lib/libbsp/arm/lpc176x/make/custom/lpc1768_mbed_ahb_ram_eth.cfg b/c/src/lib/libbsp/arm/lpc176x/make/custom/lpc1768_mbed_ahb_ram_eth.cfg
new file mode 100644
index 0000000..e187d1f
--- /dev/null
+++ b/c/src/lib/libbsp/arm/lpc176x/make/custom/lpc1768_mbed_ahb_ram_eth.cfg
@@ -0,0 +1,5 @@
+#
+# Config file for mbed LPC1768 board.
+#
+
+include $(RTEMS_ROOT)/make/custom/lpc1768_mbed.cfg
diff --git a/c/src/lib/libbsp/arm/lpc176x/startup/linkcmds.lpc1768_mbed_ahb_ram_eth b/c/src/lib/libbsp/arm/lpc176x/startup/linkcmds.lpc1768_mbed_ahb_ram_eth
new file mode 100644
index 0000000..eecb6b1
--- /dev/null
+++ b/c/src/lib/libbsp/arm/lpc176x/startup/linkcmds.lpc1768_mbed_ahb_ram_eth
@@ -0,0 +1,39 @@
+/* LPC1768 OEM Board from Embedded Artists */
+
+MEMORY {
+	ROM_INT (RX)  : ORIGIN = 0x00000000, LENGTH = 512k
+	RAM_INT (AIW) : ORIGIN = 0x10000000, LENGTH = 32k
+	RAM_AHB1 (AIW) : ORIGIN = 0x2007C000, LENGTH = 16k
+	RAM_AHB2 (AIW) : ORIGIN = 0x20080000, LENGTH = 16k
+}
+
+REGION_ALIAS ("REGION_START", ROM_INT);
+REGION_ALIAS ("REGION_VECTOR", RAM_INT);
+REGION_ALIAS ("REGION_TEXT", ROM_INT);
+REGION_ALIAS ("REGION_TEXT_LOAD", ROM_INT);
+REGION_ALIAS ("REGION_RODATA", ROM_INT);
+REGION_ALIAS ("REGION_RODATA_LOAD", ROM_INT);
+REGION_ALIAS ("REGION_DATA", RAM_INT);
+REGION_ALIAS ("REGION_DATA_LOAD", ROM_INT);
+REGION_ALIAS ("REGION_FAST_TEXT", RAM_INT);
+REGION_ALIAS ("REGION_FAST_TEXT_LOAD", ROM_INT);
+REGION_ALIAS ("REGION_FAST_DATA", RAM_INT);
+REGION_ALIAS ("REGION_FAST_DATA_LOAD", ROM_INT);
+REGION_ALIAS ("REGION_BSS", RAM_AHB1);
+REGION_ALIAS ("REGION_WORK", RAM_INT);
+REGION_ALIAS ("REGION_STACK", RAM_INT);
+REGION_ALIAS ("REGION_ETH", RAM_AHB2);
+
+bsp_stack_main_size = DEFINED (bsp_stack_main_size) ? bsp_stack_main_size : 1024;
+bsp_stack_main_size = ALIGN (bsp_stack_main_size, bsp_stack_align);
+
+SECTIONS {
+    .eth (NOLOAD) : ALIGN_WITH_INPUT {
+        bsp_section_eth_begin = .;
+        *(.eth)
+        bsp_section_eth_end = .;
+    } > REGION_ETH AT > REGION_ETH
+    bsp_section_eth_size = bsp_section_eth_end - bsp_section_eth_begin;
+}
+
+INCLUDE linkcmds.armv7m



More information about the vc mailing list