[U-Boot] [PATCH] avr32: unified u-boot.lds

Jean-Christophe PLAGNIOL-VILLARD plagnioj at jcrosoft.com
Sat May 23 12:49:55 CEST 2009


all avr32 boards use the same cpu lds so move it to cpu/$(CPU)

that could be overwrite in following order
SOC
BOARD
via the corresponding config.mk

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj at jcrosoft.com>
Cc: Haavard Skinnemoen <haavard.skinnemoen at atmel.com>
---
 board/atmel/atngw100/u-boot.lds                  |   72 ----------------------
 board/earthlcd/favr-32-ezkit/u-boot.lds          |   70 ---------------------
 board/mimc/mimc200/u-boot.lds                    |   72 ----------------------
 board/miromico/hammerhead/u-boot.lds             |   72 ----------------------
 cpu/at32ap/config.mk                             |    2 +
 {board/atmel/atstk1000 => cpu/at32ap}/u-boot.lds |    3 +-
 6 files changed, 4 insertions(+), 287 deletions(-)
 delete mode 100644 board/atmel/atngw100/u-boot.lds
 delete mode 100644 board/earthlcd/favr-32-ezkit/u-boot.lds
 delete mode 100644 board/mimc/mimc200/u-boot.lds
 delete mode 100644 board/miromico/hammerhead/u-boot.lds
 rename {board/atmel/atstk1000 => cpu/at32ap}/u-boot.lds (96%)

diff --git a/board/atmel/atngw100/u-boot.lds b/board/atmel/atngw100/u-boot.lds
deleted file mode 100644
index a7243f2..0000000
--- a/board/atmel/atngw100/u-boot.lds
+++ /dev/null
@@ -1,72 +0,0 @@
-/* -*- Fundamental -*-
- *
- * Copyright (C) 2005-2006 Atmel Corporation
- *
- * See file CREDITS for list of people who contributed to this
- * project.
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License as
- * published by the Free Software Foundation; either version 2 of
- * the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
- * MA 02111-1307 USA
- */
-OUTPUT_FORMAT("elf32-avr32", "elf32-avr32", "elf32-avr32")
-OUTPUT_ARCH(avr32)
-ENTRY(_start)
-
-SECTIONS
-{
-	. = 0;
-	_text = .;
-	.text : {
-		*(.exception.text)
-		*(.text)
-		*(.text.*)
-	}
-	_etext = .;
-
-	.rodata : {
-		*(SORT_BY_ALIGNMENT(SORT_BY_NAME(.rodata*)))
-	}
-
-	. = ALIGN(8);
-	_data = .;
-	.data : {
-		*(.data)
-		*(.data.*)
-	}
-
-	. = ALIGN(4);
-	__u_boot_cmd_start = .;
-	.u_boot_cmd : {
-		KEEP(*(.u_boot_cmd))
-	}
-	__u_boot_cmd_end = .;
-
-	. = ALIGN(4);
-	_got = .;
-	.got : {
-		*(.got)
-	}
-	_egot = .;
-
-	. = ALIGN(8);
-	_edata = .;
-
-	.bss : {
-		*(.bss)
-		*(.bss.*)
-	}
-	. = ALIGN(8);
-	_end = .;
-}
diff --git a/board/earthlcd/favr-32-ezkit/u-boot.lds b/board/earthlcd/favr-32-ezkit/u-boot.lds
deleted file mode 100644
index 0d413a0..0000000
--- a/board/earthlcd/favr-32-ezkit/u-boot.lds
+++ /dev/null
@@ -1,70 +0,0 @@
-/* -*- Fundamental -*-
- *
- * Copyright (C) 2008 Atmel Corporation
- *
- * See file CREDITS for list of people who contributed to this project.
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the Free
- * Software Foundation; either version 2 of the License, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License for
- * more details.
- *
- * You should have received a copy of the GNU General Public License along with
- * this program; if not, write to the Free Software Foundation, Inc., 59 Temple
- * Place, Suite 330, Boston, MA 02111-1307 USA
- */
-OUTPUT_FORMAT("elf32-avr32", "elf32-avr32", "elf32-avr32")
-OUTPUT_ARCH(avr32)
-ENTRY(_start)
-
-SECTIONS
-{
-	. = 0;
-	_text = .;
-	.text : {
-		*(.exception.text)
-		*(.text)
-		*(.text.*)
-	}
-	_etext = .;
-
-	.rodata : {
-		*(SORT_BY_ALIGNMENT(SORT_BY_NAME(.rodata*)))
-	}
-
-	. = ALIGN(8);
-	_data = .;
-	.data : {
-		*(.data)
-		*(.data.*)
-	}
-
-	. = ALIGN(4);
-	__u_boot_cmd_start = .;
-	.u_boot_cmd : {
-		KEEP(*(.u_boot_cmd))
-	}
-	__u_boot_cmd_end = .;
-
-	. = ALIGN(4);
-	_got = .;
-	.got : {
-		*(.got)
-	}
-	_egot = .;
-
-	. = ALIGN(8);
-	_edata = .;
-
-	.bss (NOLOAD) : {
-		*(.bss)
-		*(.bss.*)
-	}
-	. = ALIGN(8);
-	_end = .;
-}
diff --git a/board/mimc/mimc200/u-boot.lds b/board/mimc/mimc200/u-boot.lds
deleted file mode 100644
index a7243f2..0000000
--- a/board/mimc/mimc200/u-boot.lds
+++ /dev/null
@@ -1,72 +0,0 @@
-/* -*- Fundamental -*-
- *
- * Copyright (C) 2005-2006 Atmel Corporation
- *
- * See file CREDITS for list of people who contributed to this
- * project.
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License as
- * published by the Free Software Foundation; either version 2 of
- * the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
- * MA 02111-1307 USA
- */
-OUTPUT_FORMAT("elf32-avr32", "elf32-avr32", "elf32-avr32")
-OUTPUT_ARCH(avr32)
-ENTRY(_start)
-
-SECTIONS
-{
-	. = 0;
-	_text = .;
-	.text : {
-		*(.exception.text)
-		*(.text)
-		*(.text.*)
-	}
-	_etext = .;
-
-	.rodata : {
-		*(SORT_BY_ALIGNMENT(SORT_BY_NAME(.rodata*)))
-	}
-
-	. = ALIGN(8);
-	_data = .;
-	.data : {
-		*(.data)
-		*(.data.*)
-	}
-
-	. = ALIGN(4);
-	__u_boot_cmd_start = .;
-	.u_boot_cmd : {
-		KEEP(*(.u_boot_cmd))
-	}
-	__u_boot_cmd_end = .;
-
-	. = ALIGN(4);
-	_got = .;
-	.got : {
-		*(.got)
-	}
-	_egot = .;
-
-	. = ALIGN(8);
-	_edata = .;
-
-	.bss : {
-		*(.bss)
-		*(.bss.*)
-	}
-	. = ALIGN(8);
-	_end = .;
-}
diff --git a/board/miromico/hammerhead/u-boot.lds b/board/miromico/hammerhead/u-boot.lds
deleted file mode 100644
index a7243f2..0000000
--- a/board/miromico/hammerhead/u-boot.lds
+++ /dev/null
@@ -1,72 +0,0 @@
-/* -*- Fundamental -*-
- *
- * Copyright (C) 2005-2006 Atmel Corporation
- *
- * See file CREDITS for list of people who contributed to this
- * project.
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License as
- * published by the Free Software Foundation; either version 2 of
- * the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
- * MA 02111-1307 USA
- */
-OUTPUT_FORMAT("elf32-avr32", "elf32-avr32", "elf32-avr32")
-OUTPUT_ARCH(avr32)
-ENTRY(_start)
-
-SECTIONS
-{
-	. = 0;
-	_text = .;
-	.text : {
-		*(.exception.text)
-		*(.text)
-		*(.text.*)
-	}
-	_etext = .;
-
-	.rodata : {
-		*(SORT_BY_ALIGNMENT(SORT_BY_NAME(.rodata*)))
-	}
-
-	. = ALIGN(8);
-	_data = .;
-	.data : {
-		*(.data)
-		*(.data.*)
-	}
-
-	. = ALIGN(4);
-	__u_boot_cmd_start = .;
-	.u_boot_cmd : {
-		KEEP(*(.u_boot_cmd))
-	}
-	__u_boot_cmd_end = .;
-
-	. = ALIGN(4);
-	_got = .;
-	.got : {
-		*(.got)
-	}
-	_egot = .;
-
-	. = ALIGN(8);
-	_edata = .;
-
-	.bss : {
-		*(.bss)
-		*(.bss.*)
-	}
-	. = ALIGN(8);
-	_end = .;
-}
diff --git a/cpu/at32ap/config.mk b/cpu/at32ap/config.mk
index 1c12169..7e131fe 100644
--- a/cpu/at32ap/config.mk
+++ b/cpu/at32ap/config.mk
@@ -20,3 +20,5 @@
 # MA 02111-1307 USA
 #
 PLATFORM_RELFLAGS       += -mcpu=ap7000
+
+LDSCRIPT := $(SRCTREE)/cpu/$(CPU)/u-boot.lds
diff --git a/board/atmel/atstk1000/u-boot.lds b/cpu/at32ap/u-boot.lds
similarity index 96%
rename from board/atmel/atstk1000/u-boot.lds
rename to cpu/at32ap/u-boot.lds
index 86ef939..c9ced5d 100644
--- a/board/atmel/atstk1000/u-boot.lds
+++ b/cpu/at32ap/u-boot.lds
@@ -1,6 +1,6 @@
 /* -*- Fundamental -*-
  *
- * Copyright (C) 2005-2006 Atmel Corporation
+ * Copyright (C) 2005-2008 Atmel Corporation
  *
  * See file CREDITS for list of people who contributed to this
  * project.
@@ -20,6 +20,7 @@
  * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
  * MA 02111-1307 USA
  */
+
 OUTPUT_FORMAT("elf32-avr32", "elf32-avr32", "elf32-avr32")
 OUTPUT_ARCH(avr32)
 ENTRY(_start)
-- 
1.6.3.1



More information about the U-Boot mailing list