Re: [U-Boot] [PATCH v3] [ARM] at91: Add support for taskit AT91SAM9G20 boards
Hello Tom, are there still objections to our patch or has it just got forgotten? Kind regards Achim -- product manager email:aehrl...@taskit.de Tel.: ++49 30 611295-25 Fax: ++49 30 611295-11 -- taskit GmbH Seelenbinderstr. 33 | D-12555 Berlin web:http://www.taskit.de Amtsgericht Charlottenburg: 93HRB39014 Managing director: Thorsten Raulfs -- ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH v3] [ARM] at91: Add support for taskit AT91SAM9G20 boards
This adds support for the AT91SAM9G20 boards by taskit GmbH. Both boards, Stamp9G20 and PortuxG20, are integrated in one file. PortuxG20 is basically a SBC built around Stam9G20. Signed-off-by: Achim Ehrlich aehrl...@taskit.de --- MAINTAINERS|5 + MAKEALL|1 + Makefile |4 + board/taskit/stamp9G20/Makefile| 50 + board/taskit/stamp9G20/config.mk |1 + board/taskit/stamp9G20/stamp9G20.c | 199 include/configs/stamp9G20.h| 183 + 7 files changed, 443 insertions(+), 0 deletions(-) create mode 100644 board/taskit/stamp9G20/Makefile create mode 100644 board/taskit/stamp9G20/config.mk create mode 100644 board/taskit/stamp9G20/stamp9G20.c create mode 100644 include/configs/stamp9G20.h diff --git a/MAINTAINERS b/MAINTAINERS index 0658bc3..2052d74 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -136,6 +136,11 @@ Jon Diekema jon.diek...@smiths-aerospace.com sbc8260 MPC8260 +Achim Ehrlich aehrl...@taskit.de + + Stamp9G20 AT91SAM9G20 + PortuxG20 AT91SAM9G20 + Dirk Eibach eib...@gdsys.de devconcenterPPC460EX diff --git a/MAKEALL b/MAKEALL index a88c31e..3102085 100755 --- a/MAKEALL +++ b/MAKEALL @@ -671,6 +671,7 @@ LIST_at91= \ pm9261 \ pm9263 \ SBC35_A9G20 \ + stamp9G20 \ TNY_A9260 \ TNY_A9G20 \ diff --git a/Makefile b/Makefile index 4532550..9480e99 100644 --- a/Makefile +++ b/Makefile @@ -2883,6 +2883,10 @@ TNY_A9260_config : unconfig @echo #define CONFIG_$(@:_config=) 1 $(obj)include/config.h @$(MKCONFIG) -a tny_a9260 arm arm926ejs tny_a9260 calao at91 +portuxG20_config \ +stamp9G20_config : unconfig + @$(MKCONFIG) -t $(@:_config=) stamp9G20 arm arm926ejs stamp9G20 taskit at91 + ## ARM Integrator boards - see doc/README-integrator for more info. integratorap_config\ diff --git a/board/taskit/stamp9G20/Makefile b/board/taskit/stamp9G20/Makefile new file mode 100644 index 000..191fb8e --- /dev/null +++ b/board/taskit/stamp9G20/Makefile @@ -0,0 +1,50 @@ +# +# (C) Copyright 2010 +# Achim Ehrlich, taskit GmbH, aehrl...@taskit.de. +# +# 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 +# + +include $(TOPDIR)/config.mk + +LIB= $(obj)lib$(BOARD).a + +COBJS-y+= stamp9G20.o + +SRCS := $(SOBJS:.o=.S) $(COBJS-y:.o=.c) +OBJS := $(addprefix $(obj),$(COBJS-y)) +SOBJS := $(addprefix $(obj),$(SOBJS)) + +$(LIB):$(obj).depend $(OBJS) $(SOBJS) + $(AR) $(ARFLAGS) $@ $(OBJS) $(SOBJS) + +clean: + rm -f $(SOBJS) $(OBJS) + +distclean: clean + rm -f $(LIB) core *.bak $(obj).depend + +# + +# defines $(obj).depend target +include $(SRCTREE)/rules.mk + +sinclude $(obj).depend + +# diff --git a/board/taskit/stamp9G20/config.mk b/board/taskit/stamp9G20/config.mk new file mode 100644 index 000..ff2cfd1 --- /dev/null +++ b/board/taskit/stamp9G20/config.mk @@ -0,0 +1 @@ +TEXT_BASE = 0x23f0 diff --git a/board/taskit/stamp9G20/stamp9G20.c b/board/taskit/stamp9G20/stamp9G20.c new file mode 100644 index 000..6beb1cd --- /dev/null +++ b/board/taskit/stamp9G20/stamp9G20.c @@ -0,0 +1,199 @@ +/* + * (C) Copyright 2007-2008 + * Stelian Pop stelian@leadtechdesign.com + * Lead Tech Design www.leadtechdesign.com + * + * (C) Copyright 2010 + * Achim Ehrlich aehrl...@taskit.de + * taskit GmbH www.taskit.de + * + * 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
[U-Boot] [PATCH v2] [ARM] at91: Add support for taskit AT91SAM9G20 boards
This adds support for the AT91SAM9G20 boards by taskit GmbH. Both boards, Stamp9G20 and PortuxG20, are integrated in one file. PortuxG20 is basically a SBC built around Stamp9G20. Signed-off-by: Achim Ehrlich aehrl...@taskit.de --- MAINTAINERS|5 + MAKEALL|1 + Makefile |4 + board/taskit/stamp9G20/Makefile| 50 + board/taskit/stamp9G20/config.mk |1 + board/taskit/stamp9G20/stamp9G20.c | 203 include/configs/stamp9G20.h| 180 7 files changed, 444 insertions(+), 0 deletions(-) create mode 100644 board/taskit/stamp9G20/Makefile create mode 100644 board/taskit/stamp9G20/config.mk create mode 100644 board/taskit/stamp9G20/stamp9G20.c create mode 100644 include/configs/stamp9G20.h diff --git a/MAINTAINERS b/MAINTAINERS index 7f40ebd..c4259a0 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -138,6 +138,11 @@ Jon Diekema jon.diek...@smiths-aerospace.com sbc8260 MPC8260 +Achim Ehrlich aehrl...@taskit.de + + Stamp9G20 AT91SAM9G20 + PortuxG20 AT91SAM9G20 + Dirk Eibach eib...@gdsys.de devconcenterPPC460EX diff --git a/MAKEALL b/MAKEALL index 1949985..516 100755 --- a/MAKEALL +++ b/MAKEALL @@ -675,6 +675,7 @@ LIST_at91= \ pm9261 \ pm9263 \ SBC35_A9G20 \ + stamp9G20 \ TNY_A9260 \ TNY_A9G20 \ diff --git a/Makefile b/Makefile index ce77e10..ed9ae00 100644 --- a/Makefile +++ b/Makefile @@ -2903,6 +2903,10 @@ TNY_A9260_config : unconfig @echo #define CONFIG_$(@:_config=) 1 $(obj)include/config.h @$(MKCONFIG) -a tny_a9260 arm arm926ejs tny_a9260 calao at91 +portuxG20_config \ +stamp9G20_config : unconfig + @$(MKCONFIG) -t $(@:_config=) stamp9G20 arm arm926ejs stamp9G20 taskit at91 + ## ARM Integrator boards - see doc/README-integrator for more info. integratorap_config\ diff --git a/board/taskit/stamp9G20/Makefile b/board/taskit/stamp9G20/Makefile new file mode 100644 index 000..191fb8e --- /dev/null +++ b/board/taskit/stamp9G20/Makefile @@ -0,0 +1,50 @@ +# +# (C) Copyright 2010 +# Achim Ehrlich, taskit GmbH, aehrl...@taskit.de. +# +# 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 +# + +include $(TOPDIR)/config.mk + +LIB= $(obj)lib$(BOARD).a + +COBJS-y+= stamp9G20.o + +SRCS := $(SOBJS:.o=.S) $(COBJS-y:.o=.c) +OBJS := $(addprefix $(obj),$(COBJS-y)) +SOBJS := $(addprefix $(obj),$(SOBJS)) + +$(LIB):$(obj).depend $(OBJS) $(SOBJS) + $(AR) $(ARFLAGS) $@ $(OBJS) $(SOBJS) + +clean: + rm -f $(SOBJS) $(OBJS) + +distclean: clean + rm -f $(LIB) core *.bak $(obj).depend + +# + +# defines $(obj).depend target +include $(SRCTREE)/rules.mk + +sinclude $(obj).depend + +# diff --git a/board/taskit/stamp9G20/config.mk b/board/taskit/stamp9G20/config.mk new file mode 100644 index 000..ff2cfd1 --- /dev/null +++ b/board/taskit/stamp9G20/config.mk @@ -0,0 +1 @@ +TEXT_BASE = 0x23f0 diff --git a/board/taskit/stamp9G20/stamp9G20.c b/board/taskit/stamp9G20/stamp9G20.c new file mode 100644 index 000..b543b0a --- /dev/null +++ b/board/taskit/stamp9G20/stamp9G20.c @@ -0,0 +1,203 @@ +/* + * (C) Copyright 2007-2008 + * Stelian Pop stelian@leadtechdesign.com + * Lead Tech Design www.leadtechdesign.com + * + * (C) Copyright 2010 + * Achim Ehrlich aehrl...@taskit.de + * taskit GmbH www.taskit.de + * + * 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
[U-Boot] [PATCH] [ARM] Convert at91 watchdog driver to new SoC access
This converts the at91 watchdog driver to new c structure type to access registers of the SoC Signed-off-by: Achim Ehrlich aehrl...@taskit.de --- drivers/watchdog/at91sam9_wdt.c | 21 +++-- 1 files changed, 11 insertions(+), 10 deletions(-) diff --git a/drivers/watchdog/at91sam9_wdt.c b/drivers/watchdog/at91sam9_wdt.c index 5bb8b77..25afae7 100644 --- a/drivers/watchdog/at91sam9_wdt.c +++ b/drivers/watchdog/at91sam9_wdt.c @@ -42,11 +42,10 @@ static int at91_wdt_settimeout(unsigned int timeout) { unsigned int reg; - unsigned int mr; + at91_wdt_t *wd = (at91_wdt_t *) AT91_WDT_BASE; /* Check if disabled */ - mr = at91_sys_read(AT91_WDT_MR); - if (mr AT91_WDT_WDDIS) { + if (readl(wd-mr) AT91_WDT_MR_WDDIS) { printf(sorry, watchdog is disabled\n); return -1; } @@ -57,19 +56,21 @@ static int at91_wdt_settimeout(unsigned int timeout) * Since WDV is a 12-bit counter, the maximum period is * 4096 / 256 = 16 seconds. */ - reg = AT91_WDT_WDRSTEN /* causes watchdog reset */ - /* | AT91_WDT_WDRPROC causes processor reset only */ - | AT91_WDT_WDDBGHLT /* disabled in debug mode */ - | AT91_WDT_WDD /* restart at any time */ - | (timeout AT91_WDT_WDV); /* timer value */ - at91_sys_write(AT91_WDT_MR, reg); + + reg = AT91_WDT_MR_WDRSTEN /* causes watchdog reset */ + | AT91_WDT_MR_WDDBGHLT /* disabled in debug mode */ + | AT91_WDT_MR_WDD(0xfff)/* restart at any time */ + | AT91_WDT_MR_WDV(timeout); /* timer value */ + + writel(reg, wd-mr); return 0; } void hw_watchdog_reset(void) { - at91_sys_write(AT91_WDT_CR, AT91_WDT_KEY | AT91_WDT_WDRSTT); + at91_wdt_t *wd = (at91_wdt_t *) AT91_WDT_BASE; + writel(AT91_WDT_CR_WDRSTT | AT91_WDT_CR_KEY, wd-cr); } void hw_watchdog_init(void) -- 1.6.4.4 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] U-BOOT porting to PORTUX 920T
Hello Luca, Thank to Achim Ehrlich - we got all we needed working! Timing has been set to s$ Basically - we have seen: - dataflash working - usb transfers ok - environment We should test other hardware - hoping to get feedback, at least from Taskit! Nice to hear, that things are working now for you. Testing your changes is not so easy, as you didn't provide a proper patch to apply (and especially with which tree are you working?). Do you have any intention to post your board file to the mailing list, when it is ready? I guess it is not. Kind regards Achim -- product manager email:aehrl...@taskit.de Tel.: ++49 30 611295-25 Fax: ++49 30 611295-11 -- taskit GmbH Seelenbinderstr. 33 | D-12555 Berlin web:http://www.taskit.de Amtsgericht Charlottenburg: 93HRB39014 Managing director: Thorsten Raulfs -- ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH] ARM change name of defines for AT91 arm926ejs
Configuration defines should be preceeded with CONFIG_SYS_. Renamed some at91 specific defines to conform to this naming convention: AT91_CPU_NAME to CONFIG_SYS_AT91_CPU_NAME AT91_MAIN_CLOCK to CONFIG_SYS_AT91_MAIN_CLOCK Signed-off-by: Achim Ehrlich aehrl...@taskit.de --- board/atmel/at91cap9adk/at91cap9adk.c |2 +- board/atmel/at91sam9261ek/at91sam9261ek.c |2 +- board/atmel/at91sam9263ek/at91sam9263ek.c |2 +- board/atmel/at91sam9m10g45ek/at91sam9m10g45ek.c |2 +- board/atmel/at91sam9rlek/at91sam9rlek.c |2 +- board/esd/otc570/otc570.c |2 +- board/ronetix/pm9261/pm9261.c |2 +- board/ronetix/pm9263/pm9263.c |2 +- cpu/arm926ejs/at91/clock.c |2 +- cpu/arm926ejs/at91/cpu.c|8 include/asm-arm/arch-at91/at91cap9.h|2 +- include/asm-arm/arch-at91/at91rm9200.h |2 +- include/asm-arm/arch-at91/at91sam9260.h |4 ++-- include/asm-arm/arch-at91/at91sam9261.h |2 +- include/asm-arm/arch-at91/at91sam9263.h |2 +- include/asm-arm/arch-at91/at91sam9g45.h |2 +- include/asm-arm/arch-at91/at91sam9rl.h |2 +- include/configs/afeb9260.h |2 +- include/configs/at91cap9adk.h |2 +- include/configs/at91sam9260ek.h |2 +- include/configs/at91sam9261ek.h |2 +- include/configs/at91sam9263ek.h |2 +- include/configs/at91sam9m10g45ek.h |2 +- include/configs/at91sam9rlek.h |2 +- include/configs/cpu9260.h |2 +- include/configs/pm9261.h|4 ++-- include/configs/pm9263.h|2 +- include/configs/sbc35_a9g20.h |2 +- include/configs/tny_a9260.h |2 +- 29 files changed, 34 insertions(+), 34 deletions(-) diff --git a/board/atmel/at91cap9adk/at91cap9adk.c b/board/atmel/at91cap9adk/at91cap9adk.c index 9f73df6..258d1ea 100644 --- a/board/atmel/at91cap9adk/at91cap9adk.c +++ b/board/atmel/at91cap9adk/at91cap9adk.c @@ -282,7 +282,7 @@ void lcd_show_board_info(void) lcd_printf ((C) 2008 ATMEL Corp\n); lcd_printf (at91supp...@atmel.com\n); lcd_printf (%s CPU at %s MHz\n, - AT91_CPU_NAME, + CONFIG_SYS_AT91_CPU_NAME, strmhz(temp, get_cpu_clk_rate())); dram_size = 0; diff --git a/board/atmel/at91sam9261ek/at91sam9261ek.c b/board/atmel/at91sam9261ek/at91sam9261ek.c index 7ead2b8..de5cfae 100644 --- a/board/atmel/at91sam9261ek/at91sam9261ek.c +++ b/board/atmel/at91sam9261ek/at91sam9261ek.c @@ -217,7 +217,7 @@ void lcd_show_board_info(void) lcd_printf ((C) 2008 ATMEL Corp\n); lcd_printf (at91supp...@atmel.com\n); lcd_printf (%s CPU at %s MHz\n, - AT91_CPU_NAME, + CONFIG_SYS_AT91_CPU_NAME, strmhz(temp, get_cpu_clk_rate())); dram_size = 0; diff --git a/board/atmel/at91sam9263ek/at91sam9263ek.c b/board/atmel/at91sam9263ek/at91sam9263ek.c index 8ab45af..5cd7aa7 100644 --- a/board/atmel/at91sam9263ek/at91sam9263ek.c +++ b/board/atmel/at91sam9263ek/at91sam9263ek.c @@ -218,7 +218,7 @@ void lcd_show_board_info(void) lcd_printf ((C) 2008 ATMEL Corp\n); lcd_printf (at91supp...@atmel.com\n); lcd_printf (%s CPU at %s MHz\n, - AT91_CPU_NAME, + CONFIG_SYS_AT91_CPU_NAME, strmhz(temp, get_cpu_clk_rate())); dram_size = 0; diff --git a/board/atmel/at91sam9m10g45ek/at91sam9m10g45ek.c b/board/atmel/at91sam9m10g45ek/at91sam9m10g45ek.c index 45a14a9..edfb627 100644 --- a/board/atmel/at91sam9m10g45ek/at91sam9m10g45ek.c +++ b/board/atmel/at91sam9m10g45ek/at91sam9m10g45ek.c @@ -217,7 +217,7 @@ void lcd_show_board_info(void) lcd_printf ((C) 2008 ATMEL Corp\n); lcd_printf (at91supp...@atmel.com\n); lcd_printf (%s CPU at %s MHz\n, - AT91_CPU_NAME, + CONFIG_SYS_AT91_CPU_NAME, strmhz(temp, get_cpu_clk_rate())); dram_size = 0; diff --git a/board/atmel/at91sam9rlek/at91sam9rlek.c b/board/atmel/at91sam9rlek/at91sam9rlek.c index 7013ba2..e374917 100644 --- a/board/atmel/at91sam9rlek/at91sam9rlek.c +++ b/board/atmel/at91sam9rlek/at91sam9rlek.c @@ -157,7 +157,7 @@ void lcd_show_board_info(void) lcd_printf ((C) 2008 ATMEL Corp\n); lcd_printf (at91supp...@atmel.com\n); lcd_printf (%s CPU at %s MHz\n, - AT91_CPU_NAME, + CONFIG_SYS_AT91_CPU_NAME, strmhz(temp, get_cpu_clk_rate())); dram_size = 0; diff --git a/board/esd/otc570/otc570.c b/board/esd/otc570/otc570.c index 056df37..3fe28cb 100644 --- a/board/esd/otc570/otc570.c +++ b/board/esd/otc570/otc570.c
Re: [U-Boot] Taskit Portux920T port - Some issues
Hello, Hi, Hi, we are Enrico Luca. Hi Enrico and Luca, welcome aboard! We have tried to port u-boot to a Portux920T MiniPC. It seems we are successful, in fact u-boot brings up the device with no error and can boot a linux kernel. Ethernet driver works, dhcp works and major problems are present. Congratulations! Do you realize that only yesterday there was another posting of a port to this board? In that other port NOR flash support wasn't even tried ;) No, Portux920T and PortuxG20 are different boards with different CPUs. Portux920T indeed boots from NOR Flash. The only thing we can't get right is flash programming. We are trying to use CFI flash driver that shows evident timing issues, at least in our opinion. When running saveenv more than once we get the typical Flash not erased error, while running cp.b (for example) does not give us any problem. Running a bootm kerneladdr initaddr command it frequently gives us a No boot image - CRC error, but running it another time, without rebooting the machine, results in a successful boot. So in essence you see read errors without any writing, correct? In this case I would not suspect the CFI driver at all, because it is not involved, but rather point the finger to the RAM initialization. Are you 100% sure that this is correct? Maybe compare with the other posted port. I think both, Flash and SDRAM chipselect settings are not correct. Please use the following values: #define CONFIG_SYS_SMC_CSR0_VAL 0x3286 #define CONFIG_SYS_SDRC_CR_VAL 0x21914159 So in essence I suggest, you compare your work with the other work and work out where to go from there. You may even ask Achim Ehrlic directly, after all he works at Taskit, so he may be able to help you efficiently :) [...] After all, he should. Hope that helps. Achim -- product manager email:aehrl...@taskit.de Tel.: ++49 30 611295-25 Fax: ++49 30 611295-11 -- taskit GmbH Seelenbinderstr. 33 | D-12555 Berlin web:http://www.taskit.de Amtsgericht Charlottenburg: 93HRB39014 Managing director: Thorsten Raulfs -- ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH] AT91: Added support for taskit Stamp9G20 and PortuxG20
Dear Wolfgang Denk, In message 4b7c14ec.7050...@taskit.de you wrote: Signed-off-by: Achim Ehrlich aehrl...@taskit.de --- ... --- a/Makefile +++ b/Makefile @@ -2906,6 +2906,15 @@ TNY_A9260_config : unconfig @echo #define CONFIG_$(@:_config=) 1 $(obj)include/config.h @$(MKCONFIG) -a tny_a9260 arm arm926ejs tny_a9260 calao at91 +portuxG20_config \ +stamp9G20_config: unconfig +@mkdir -p $(obj)include +@if [ $(findstring portux,$@) ] ; then \ +echo #define CONFIG_PORTUXG20 1 $(obj)include/config.h; \ +$(XECHO) ... PortuxG20;\ +fi; NAK. We don't accept such scripting in the Makefile any more. Please use the available mkconfig features instead. Sorry, I overlooked that feature and will change that. diff --git a/board/taskit/stamp9G20/partition.c b/board/taskit/stamp9G20/partition.c new file mode 100644 index 000..2629c67 --- /dev/null +++ b/board/taskit/stamp9G20/partition.c So we are adding yet another copy of this file. We already have 12 of these. Mostly identical. Isn't there a more intelligent way to handle this? The file has not much content anyway. I can get rid of it completely. ... +int dram_init(void) +{ +gd-bd-bi_dram[0].start = PHYS_SDRAM; +gd-bd-bi_dram[0].size = PHYS_SDRAM_SIZE; +return 0; +} Please consider using get_ram_size() for memory auto-sizing and testing. Thanks for the hint, i will test it. +#ifdef CONFIG_RESET_PHY_R +void reset_phy(void) +{ +#ifdef CONFIG_MACB CONFIG_MACB seems to be an undocumented variable. What is it supposed to do? It switches on the pin initialization for the Ethernet MAC. Actually, i just copied this part from the AT91SAM9260ek board code. diff --git a/include/configs/stamp9G20.h b/include/configs/stamp9G20.h new file mode 100644 index 000..5008554 --- /dev/null +++ b/include/configs/stamp9G20.h ... +/* ARM asynchronous clock */ +#define AT91_MAIN_CLOCK 18432000/* 18.432 MHz crystal */ This should be changed into a CONFIG_SYS_ (globally). Do you mean, I should change that for all AT91-Boards in u-boot? How or who is going to test that? +#define AT91_CPU_NAME AT91SAM9G20 Ditto. +#define CONFIG_ATMEL_USART 1 +#undef CONFIG_USART0 +#undef CONFIG_USART1 +#undef CONFIG_USART2 +#define CONFIG_USART3 1 /* USART 3 is DBGU */ Do not undefine what is not defined anyway. +/* LED */ + +#undef CONFIG_AT91_LED Ditto. +/* + * Command line configuration. + */ +#include config_cmd_default.h +#undef CONFIG_CMD_BDI +#undef CONFIG_CMD_FPGA +#undef CONFIG_CMD_IMI +#undef CONFIG_CMD_IMLS +#undef CONFIG_CMD_SOURCE Is there any specific reason for disabling the bdi, imi, imls and source commands? They are pretty useful, and you don't seem to be especially short on resources... ... +/* USB */ +#define CONFIG_USB_ATMEL +#define CONFIG_USB_OHCI_NEW 1 +#define CONFIG_DOS_PARTITION1 +#define CONFIG_SYS_USB_OHCI_CPU_INIT1 +#define CONFIG_SYS_USB_OHCI_REGS_BASE 0x0050 /* AT91SAM9260_UHP_BASE */ Line too long. Please fix globally. ... +basicargs=console=ttyS0,115200 mem=64M\0 \ + + + + Excessive white space. Drop 3 of the empty lines. I will fix these as well. Thank you for your corrections. Kind regards Achim -- product manager email:aehrl...@taskit.de Tel.: ++49 30 611295-25 Fax: ++49 30 611295-11 -- taskit GmbH Seelenbinderstr. 33 | D-12555 Berlin web:http://www.taskit.de Amtsgericht Charlottenburg: 93HRB39014 Managing director: Thorsten Raulfs -- ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH] AT91: Added support for taskit Stamp9G20 and PortuxG20
Hello Detlef, Signed-off-by: Achim Ehrlich aehrl...@taskit.de --- Makefile |9 ++ board/taskit/stamp9G20/Makefile| 56 ++ board/taskit/stamp9G20/config.mk |1 + board/taskit/stamp9G20/led.c | 35 ++ board/taskit/stamp9G20/partition.c | 40 +++ board/taskit/stamp9G20/stamp9G20.c | 200 include/configs/stamp9G20.h| 197 +++ 7 files changed, 538 insertions(+), 0 deletions(-) create mode 100644 board/taskit/stamp9G20/Makefile create mode 100644 board/taskit/stamp9G20/config.mk create mode 100644 board/taskit/stamp9G20/led.c create mode 100644 board/taskit/stamp9G20/partition.c create mode 100644 board/taskit/stamp9G20/stamp9G20.c create mode 100644 include/configs/stamp9G20.h diff --git a/Makefile b/Makefile index 524b9da..ef1a7d4 100644 --- a/Makefile +++ b/Makefile @@ -2906,6 +2906,15 @@ TNY_A9260_config : unconfig @echo #define CONFIG_$(@:_config=) 1 $(obj)include/config.h @$(MKCONFIG) -a tny_a9260 arm arm926ejs tny_a9260 calao at91 +portuxG20_config \ +stamp9G20_config: unconfig +@mkdir -p $(obj)include +@if [ $(findstring portux,$@) ] ; then \ +echo #define CONFIG_PORTUXG20 1 $(obj)include/config.h; \ +$(XECHO) ... PortuxG20;\ +fi; +@$(MKCONFIG) -a stamp9G20 arm arm926ejs stamp9G20 taskit at91 + ## ARM Integrator boards - see doc/README-integrator for more info. integratorap_config \ diff --git a/board/taskit/stamp9G20/Makefile b/board/taskit/stamp9G20/Makefile new file mode 100644 index 000..ef82428 --- /dev/null +++ b/board/taskit/stamp9G20/Makefile @@ -0,0 +1,56 @@ +# +# (C) Copyright 2003-2008 +# Wolfgang Denk, DENX Software Engineering, w...@denx.de. +# +# (C) Copyright 2008 +# Stelian Pop stelian@leadtechdesign.com +# Lead Tech Design www.leadtechdesign.com Well actually I am not a fan of including all these copyrights in a file which has so little content - so I'd vote to remove them and include your own copyright. But if for some reason the copyrights are not removed, then please at least add yourself in. [...] OK. diff --git a/board/taskit/stamp9G20/led.c b/board/taskit/stamp9G20/led.c new file mode 100644 index 000..dc6ac63 --- /dev/null +++ b/board/taskit/stamp9G20/led.c @@ -0,0 +1,35 @@ +/* + * (C) Copyright 2007-2008 + * Stelian Pop stelian@leadtechdesign.com + * Lead Tech Design www.leadtechdesign.com Dito. I haven't changed one bit in this file, I really do not feel like even adding my copyright. + * + * 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 + */ + +#include common.h +#include asm/arch/at91sam9260.h +#include asm/arch/at91_pmc.h +#include asm/arch/gpio.h +#include asm/arch/io.h + +void coloured_LED_init(void) +{ +/* Enable clock */ +at91_sys_write(AT91_PMC_PCER, 1 AT91SAM9260_ID_PIOC); +} diff --git a/board/taskit/stamp9G20/partition.c b/board/taskit/stamp9G20/partition.c new file mode 100644 index 000..2629c67 --- /dev/null +++ b/board/taskit/stamp9G20/partition.c @@ -0,0 +1,40 @@ +/* + * (C) Copyright 2008 + * Ulf Samuelsson u...@atmel.com Dito. diff --git a/board/taskit/stamp9G20/stamp9G20.c b/board/taskit/stamp9G20/stamp9G20.c new file mode 100644 index 000..28cd8b1 --- /dev/null +++ b/board/taskit/stamp9G20/stamp9G20.c @@ -0,0 +1,200 @@ +/* + * (C) Copyright 2007-2008 + * Stelian Pop stelian@leadtechdesign.com + * Lead Tech Design www.leadtechdesign.com + * + * Achim Ehrlich aehrl...@taskit.de + * taskit GmbH www.taskit.de Ok, this time you added your name - although I would have expected a year. Hmm, right. Kind regards Achim -- product manager email:aehrl...@taskit.de Tel.: ++49 30 611295-25 Fax: ++49 30 611295-11 -- taskit GmbH Seelenbinderstr. 33 | D-12555 Berlin web:http://www.taskit.de Amtsgericht Charlottenburg: 93HRB39014 Managing director: Thorsten Raulfs -- ___ U-Boot mailing
Re: [U-Boot] Timeout in tftp.c
Jean-Christophe PLAGNIOL-VILLARD schrieb: My value was at 100. Switching back to 1000 didn't solve my problem, but instead causes erase and write operations on nand flash to timeout as well. My u-boot was built on commit 03bab0091948196b9558248684c04f60943ca4b5 of the at-91 tree. this revision does not integrate the timer fix Rebasing it to the current version with the changed timer code caused u-boot to not boot at all on my hardware. I just made a simple board port and didn't change much, but I add my diff against u-boot-at91 anyway. It should work on the Atmel Board as well, but I don't own any. normaly yes but you need to update a few your config to have it working see comment on your patch Thank you for your help Achim + +#ifdef CONFIG_AT91SAM9G20EK +/* arch number of AT91SAM9260EK-Board */ +gd-bd-bi_arch_number = MACH_TYPE_AT91SAM9G20EK; +#else +/* arch number of AT91SAM9260EK-Board */ +gd-bd-bi_arch_number = MACH_TYPE_AT91SAM9260EK; +#endif sure? +/* adress of boot parameters */ +gd-bd-bi_boot_params = PHYS_SDRAM + 0x100; + +at91_serial_hw_init(); +#ifdef CONFIG_CMD_NAND +stamp9G20_nand_hw_init(); +#endif diff --git a/include/asm-arm/mach-types.h b/include/asm-arm/mach-types.h index 2c1e69b..91fc62f 100644 --- a/include/asm-arm/mach-types.h +++ b/include/asm-arm/mach-types.h when you will send your final please send a sync request diff --git a/include/configs/stamp9G20.h b/include/configs/stamp9G20.h new file mode 100644 index 000..6c4a1b5 --- /dev/null +++ b/include/configs/stamp9G20.h @@ -0,0 +1,183 @@ +/* + * (C) Copyright 2007-2008 + * Stelian Pop stelian@leadtechdesign.com + * Lead Tech Design www.leadtechdesign.com + * (C) Achim Ehrlich aehrl...@taskit.de + * taskit GmbH www.taskit.de + * + * Configuation settings for the Stamp9G20 CPU module. + * + * 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 + */ + +#ifndef __CONFIG_H +#define __CONFIG_H + +/* ARM asynchronous clock */ +#define AT91_MAIN_CLOCK 18432000/* 18.432 MHz crystal */ +#define CONFIG_SYS_AT91_PLLB0x10193f05 /* PLLB settings for USB */ please remove +#define CONFIG_SYS_HZ 1000/* 1ms resolution */ + +#define AT91_SLOW_CLOCK 32768 /* slow clock */ please remove + +#define CONFIG_ARM926EJS1 /* This is an ARM926EJS Core*/ +#define AT91_CPU_NAME AT91SAM9G20 +//#define AT91_MASTER_CLOCK 13200 /* peripheral */ +//#define AT91_CPU_CLOCK39600 /* cpu */ +#define CONFIG_AT91SAM9G20 1 /* It's an Atmel AT91SAM9G20 SoC*/ please add #define CONFIG_ARCH_CPU_INIT + please note I've sync the at91 with u-boot general tree they are the same now but for dev please base your code against u-boot-arm/next Best Regards, J. Thank you, these changes made it work fine. The tftpboot timeout is now correct as well. Kind regards Achim -- product manager email:aehrl...@taskit.de Tel.: ++49 30 611295-25 Fax: ++49 30 611295-11 -- taskit GmbH Seelenbinderstr. 33 | D-12555 Berlin web:http://www.taskit.de Amtsgericht Charlottenburg: 93HRB39014 Managing director: Thorsten Raulfs -- ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] Timeout in tftp.c
Jean-Christophe PLAGNIOL-VILLARD schrieb: On 13:37 Wed 13 May , Achim Ehrlich wrote: Jens Gehrlein schrieb: Wolfgang Denk schrieb: Dear Achim Ehrlich, In message 4a0969fc.2060...@taskit.de you wrote: The timeout for lost packages in tftp.c is defined to 5000 msecs. But when setting the timeout get_timer(0) is called in NetSetTimeout in net.c. But on AT91 the timer code returns usecs and not msecs resulting in a timeout of 5 ms instead of 5 secs, which is kind of short. I looked in the timer code of other ARM-based platforms and they seem to use usec-based timers as well. Of course I can change the defined timeout in tftp.c to one second or so, but that doesn't seem to be the right way to solve this issue. Any suggestions or ideas or do I miss something here? Any chance that you are using an old version of U-Boot? Hi Achim, I'm interested in this, too. I observed timeouts on ARM11 (MX31), but couldn't do any investigation due to other projects. I'm working on a custom developed board with AT91Sam9G20 and on the current at91-tree of u-boot, so all new. I will do further work this afternoon on this issue. which value do you put in the CONFIG_SYS_HZ? if you can send patch we could take a look on this Best Regards, J. My value was at 100. Switching back to 1000 didn't solve my problem, but instead causes erase and write operations on nand flash to timeout as well. My u-boot was built on commit 03bab0091948196b9558248684c04f60943ca4b5 of the at-91 tree. Rebasing it to the current version with the changed timer code caused u-boot to not boot at all on my hardware. I just made a simple board port and didn't change much, but I add my diff against u-boot-at91 anyway. It should work on the Atmel Board as well, but I don't own any. Thank you for your help Achim -- product manager email:aehrl...@taskit.de Tel.: ++49 30 611295-25 Fax: ++49 30 611295-11 -- taskit GmbH Seelenbinderstr. 33 | D-12555 Berlin web:http://www.taskit.de Amtsgericht Charlottenburg: 93HRB39014 Managing director: Thorsten Raulfs -- diff --git a/Makefile b/Makefile index c52894c..a2cf333 100644 --- a/Makefile +++ b/Makefile @@ -2752,6 +2752,9 @@ at91sam9rlek_config : unconfig pm9263_config : unconfig @$(MKCONFIG) $(@:_config=) arm arm926ejs pm9263 ronetix at91 +stamp9G20_config : unconfig + @$(MKCONFIG) $(@:_config=) arm arm926ejs stamp9G20 NULL at91 + ## ARM Integrator boards - see doc/README-integrator for more info. integratorap_config\ diff --git a/board/stamp9G20/Makefile b/board/stamp9G20/Makefile new file mode 100644 index 000..ef82428 --- /dev/null +++ b/board/stamp9G20/Makefile @@ -0,0 +1,56 @@ +# +# (C) Copyright 2003-2008 +# Wolfgang Denk, DENX Software Engineering, w...@denx.de. +# +# (C) Copyright 2008 +# Stelian Pop stelian@leadtechdesign.com +# Lead Tech Design www.leadtechdesign.com +# +# 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 +# + +include $(TOPDIR)/config.mk + +LIB= $(obj)lib$(BOARD).a + +COBJS-y+= stamp9G20.o +COBJS-y+= led.o +COBJS-$(CONFIG_HAS_DATAFLASH) += partition.o + +SRCS := $(SOBJS:.o=.S) $(COBJS-y:.o=.c) +OBJS := $(addprefix $(obj),$(COBJS-y)) +SOBJS := $(addprefix $(obj),$(SOBJS)) + +$(LIB):$(obj).depend $(OBJS) $(SOBJS) + $(AR) $(ARFLAGS) $@ $(OBJS) $(SOBJS) + +clean: + rm -f $(SOBJS) $(OBJS) + +distclean: clean + rm -f $(LIB) core *.bak $(obj).depend + +# + +# defines $(obj).depend target +include $(SRCTREE)/rules.mk + +sinclude $(obj).depend + +# diff --git a/board/stamp9G20/config.mk b/board/stamp9G20/config.mk new file mode 100644 index 000..ff2cfd1 --- /dev/null +++ b/board/stamp9G20/config.mk @@ -0,0 +1 @@ +TEXT_BASE = 0x23f0 diff --git a/board/stamp9G20/led.c b/board/stamp9G20/led.c new file mode 100644 index 000..2424d27 --- /dev/null +++ b/board/stamp9G20/led.c @@ -0,0 +1,41 @@ +/* + * (C) Copyright 2007-2008 + * Stelian Pop stelian@leadtechdesign.com + * Lead Tech Design
Re: [U-Boot] Timeout in tftp.c
Jens Gehrlein schrieb: Wolfgang Denk schrieb: Dear Achim Ehrlich, In message 4a0969fc.2060...@taskit.de you wrote: The timeout for lost packages in tftp.c is defined to 5000 msecs. But when setting the timeout get_timer(0) is called in NetSetTimeout in net.c. But on AT91 the timer code returns usecs and not msecs resulting in a timeout of 5 ms instead of 5 secs, which is kind of short. I looked in the timer code of other ARM-based platforms and they seem to use usec-based timers as well. Of course I can change the defined timeout in tftp.c to one second or so, but that doesn't seem to be the right way to solve this issue. Any suggestions or ideas or do I miss something here? Any chance that you are using an old version of U-Boot? Hi Achim, I'm interested in this, too. I observed timeouts on ARM11 (MX31), but couldn't do any investigation due to other projects. I'm working on a custom developed board with AT91Sam9G20 and on the current at91-tree of u-boot, so all new. I will do further work this afternoon on this issue. Kind regards Achim -- product manager email:aehrl...@taskit.de Tel.: ++49 30 611295-25 Fax: ++49 30 611295-11 -- taskit GmbH Seelenbinderstr. 33 | D-12555 Berlin web:http://www.taskit.de Amtsgericht Charlottenburg: 93HRB39014 Managing director: Thorsten Raulfs -- ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] Timeout in tftp.c
Hello, The timeout for lost packages in tftp.c is defined to 5000 msecs. But when setting the timeout get_timer(0) is called in NetSetTimeout in net.c. But on AT91 the timer code returns usecs and not msecs resulting in a timeout of 5 ms instead of 5 secs, which is kind of short. I looked in the timer code of other ARM-based platforms and they seem to use usec-based timers as well. Of course I can change the defined timeout in tftp.c to one second or so, but that doesn't seem to be the right way to solve this issue. Any suggestions or ideas or do I miss something here? Kind regards Achim -- product manager email:aehrl...@taskit.de Tel.: ++49 30 611295-25 Fax: ++49 30 611295-11 -- taskit GmbH Seelenbinderstr. 33 | D-12555 Berlin web:http://www.taskit.de Amtsgericht Charlottenburg: 93HRB39014 Managing director: Thorsten Raulfs -- ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot