Re: [U-Boot] [PATCH] ARM AT91 new board EB+CPUx9K2

2009-10-30 Thread Wolfgang Denk
Dear Jens Scharsig,

In message 4ae99ba5.3090...@bus-elektronik.de you wrote:

 By the way, the AT91RM9200.h. has hundreds of style problems.
 This requires a complete revision of the AT91RM9200.h. 
 I can try this, but will take a while and I can't test other
 RM9200 boards.

I am aware of these issues. AT91 is indeed in a poor shape.

Also, it's still lacking a custodian.

Nobody volunteered for this job so far. Seems AT91 is not much used
any more these days ?

Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH, MD: Wolfgang Denk  Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: w...@denx.de
Every program has at least one bug and can be shortened by  at  least
one instruction - from which, by induction, one can deduce that every
program can be reduced to one instruction which doesn't work.
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH] ARM AT91 new board EB+CPUx9K2

2009-10-30 Thread Jens Scharsig

Dear Wolfgang Denk
 Dear Jens Scharsig,
 
 In message 4ae99ba5.3090...@bus-elektronik.de you wrote:
 By the way, the AT91RM9200.h. has hundreds of style problems.
 This requires a complete revision of the AT91RM9200.h. 
 I can try this, but will take a while and I can't test other
 RM9200 boards.
 
 I am aware of these issues. AT91 is indeed in a poor shape.
 
 Also, it's still lacking a custodian.
 
 Nobody volunteered for this job so far. Seems AT91 is not much used
 any more these days ?

That is exactly the problem the AT91RM9200 is around 10 years old.
It isn't 100% compatible with the newer AT91SAM derivatives. 
I think the RM9200 is only used in redesigns of old projects.
We ourselves use AT91SAM9xxx for new projects. But we have several 
customer board that use the same hardware like our reference board 
EB+CPUx9K2.
I think there is an second reason, why nobody volunteered for this.
Some people want to benefit from the open-source projects, 
but nobody will help.

Best regards 
Jens Scharsig

___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH] ARM AT91 new board EB+CPUx9K2

2009-10-29 Thread Jens Scharsig
Dear Wolfgang Denk
 writel(AT91C_PA23_TXD2, AT91C_PIOA_OER);

 is the most correct way. 
 
 most correct way are big words. No, this is not correct at all.
 
 The whole set of address / offset definitions in
 include/asm-arm/arch-at91rm9200/AT91RM9200.h should be turned into a C
 struct.
I've got you misunderstood, what real pointer variable means.

If I understand you correctly now? 
The train goes in the opposite direction.

in the AT91RM9200.h

a port is defined as

typedef struct _AT91S_PIO
{
...
AT91_REG PIO_OER;   /* Output Enable Register */
...
} AT91S_PIO, *AT91PS_PIO;

and 

#define AT91C_BASE_PIOC ((AT91PS_PIO)   0xF800) 

So the access should be 

AT91PS_PIO pioa = AT91C_BASE_PIOA;
...
writel(AT91C_PA23_TXD2, pioa-PIO_OER);

or 

writel(AT91C_PA23_TXD2, AT91C_BASE_PIOA-PIO_OER);

instead of

writel(AT91C_PA23_TXD2, ((AT91PS_PIO) AT91C_BASE_PIOA)-PIO_OER)

or 

writel(AT91C_PA23_TXD2, AT91C_PIOA_OER)


The result, if all the board are adjusted, it can be removed
individual register definitions like 
#define AT91C_PIOD_OWER ((AT91_REG *) 0xFAA0)

I'm right?

Best regards,

Jens Scharsig

___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH] ARM AT91 new board EB+CPUx9K2

2009-10-29 Thread Wolfgang Denk
Dear Jens Scharsig,

In message 4ae946e7.4050...@bus-elektronik.de you wrote:

 If I understand you correctly now? 
 The train goes in the opposite direction.
 
 in the AT91RM9200.h
 
 a port is defined as
 
 typedef struct _AT91S_PIO
 {
   ...
   AT91_REG PIO_OER;   /* Output Enable Register */
   ...
 } AT91S_PIO, *AT91PS_PIO;

This is close. Of course we should drop the AT91_REG and use standard
types instead, and PIO_OER is not a logal variable name either
because it's all-capitals. So this entry should rather look like this:

...
u32 pio_oer;
...
 and 
 
 #define AT91C_BASE_PIOC   ((AT91PS_PIO)   0xF800) 

This is definitely deprecated.

 So the access should be 
 
   AT91PS_PIO pioa = AT91C_BASE_PIOA;
   ...
   writel(AT91C_PA23_TXD2, pioa-PIO_OER);

Yes, except for the incorrect variable name.

 or 
 
   writel(AT91C_PA23_TXD2, AT91C_BASE_PIOA-PIO_OER);

No.

 I'm right?

Mostly :-)

Thanks!

Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH, MD: Wolfgang Denk  Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: w...@denx.de
 The software required `Windows 95 or better', so I installed Linux.
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH] ARM AT91 new board EB+CPUx9K2

2009-10-29 Thread Jens Scharsig
Dear Wolfgang Denk
 Dear Jens Scharsig,
 
 
 This is close. Of course we should drop the AT91_REG and use standard
 types instead, and PIO_OER is not a logal variable name either
 because it's all-capitals. So this entry should rather look like this:
 
   ...
   u32 pio_oer;
   ...
 and 

 #define AT91C_BASE_PIOC  ((AT91PS_PIO)   0xF800) 
 
 This is definitely deprecated.
 
 So the access should be 

  AT91PS_PIO pioa = AT91C_BASE_PIOA;
  ...
  writel(AT91C_PA23_TXD2, pioa-PIO_OER);
 
 Yes, except for the incorrect variable name.
 

By the way, the AT91RM9200.h. has hundreds of style problems.
This requires a complete revision of the AT91RM9200.h. 
I can try this, but will take a while and I can't test other
RM9200 boards.


Best regards,

Jens Scharsig
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH] ARM AT91 new board EB+CPUx9K2

2009-10-29 Thread Tom
Jens Scharsig wrote:
 Dear Wolfgang Denk
 Dear Jens Scharsig,

  
 This is close. Of course we should drop the AT91_REG and use standard
 types instead, and PIO_OER is not a logal variable name either
 because it's all-capitals. So this entry should rather look like this:

  ...
  u32 pio_oer;
  ...
 and 

 #define AT91C_BASE_PIOC ((AT91PS_PIO)   0xF800) 
 This is definitely deprecated.

 So the access should be 

 AT91PS_PIO pioa = AT91C_BASE_PIOA;
 ...
 writel(AT91C_PA23_TXD2, pioa-PIO_OER);
 Yes, except for the incorrect variable name.

 
 By the way, the AT91RM9200.h. has hundreds of style problems.
 This requires a complete revision of the AT91RM9200.h. 
 I can try this, but will take a while and I can't test other
 RM9200 boards.
 

Please limit your changes to what you can test.
Tom

 
 Best regards,
 
 Jens Scharsig
 ___
 U-Boot mailing list
 U-Boot@lists.denx.de
 http://lists.denx.de/mailman/listinfo/u-boot

___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH] ARM AT91 new board EB+CPUx9K2

2009-10-29 Thread Wolfgang Denk
Dear Tom,

In message 4ae99f40.4000...@windriver.com you wrote:

  By the way, the AT91RM9200.h. has hundreds of style problems.
  This requires a complete revision of the AT91RM9200.h. 
  I can try this, but will take a while and I can't test other
  RM9200 boards.
 
 Please limit your changes to what you can test.
 Tom

Pure coding style changes are easy to verify - they should lead to
identical (except for the time stamps) images.

Also, board maintainers can and should be challenged to test such
patches.

Please don't stop improving the code just because others need to help
with the testing.

Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH, MD: Wolfgang Denk  Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: w...@denx.de
God made the integers; all else is the work of Man.   - Kronecker
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH] ARM AT91 new board EB+CPUx9K2

2009-10-29 Thread Tom
Wolfgang Denk wrote:
 Dear Tom,
 
 In message 4ae99f40.4000...@windriver.com you wrote:
 By the way, the AT91RM9200.h. has hundreds of style problems.
 This requires a complete revision of the AT91RM9200.h. 
 I can try this, but will take a while and I can't test other
 RM9200 boards.
 Please limit your changes to what you can test.
 Tom
 
 Pure coding style changes are easy to verify - they should lead to
 identical (except for the time stamps) images.
 
 Also, board maintainers can and should be challenged to test such
 patches.
 
 Please don't stop improving the code just because others need to help
 with the testing.

I was thinking that this would be converting from #define offsets to
structures. It can be easy to get these wrong.  Without testing 
as-you-go these types of bugs can be difficult to resolve.

Tom

 
 Best regards,
 
 Wolfgang Denk
 

___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH] ARM AT91 new board EB+CPUx9K2

2009-10-28 Thread Jens Scharsig
Dear Wolfgang Denk,
 writel(AT91C_PA23_TXD2, ((AT91PS_PIO) AT91C_BASE_PIOA)-PIO_OER);

 like notation
 
 Close, but please also get rid of this ((AT91PS_PIO) AT91C_BASE_PIOA)
 thing, especialy the cast is nasty. Declare a real pointer variable to
 the respective data structure, and use that.
 

I, think

writel(AT91C_PA23_TXD2, AT91C_PIOA_OER);

is the most correct way. 
But, there are need some additional def's in AT91RM9200.h. 
Only the port A registers is defined as pointer variable. 
If you think also this is the right way, I will send a 
separate patch for AT91RM9200.h (PORTB .. PORTD, SMC registers)

Best regards,

Jens Scharsig
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH] ARM AT91 new board EB+CPUx9K2

2009-10-28 Thread Wolfgang Denk
Dear Jens Scharsig,

In message 4ae81893.30...@bus-elektronik.de you wrote:

  Close, but please also get rid of this ((AT91PS_PIO) AT91C_BASE_PIOA)
  thing, especialy the cast is nasty. Declare a real pointer variable to
  the respective data structure, and use that.
  
 
 I, think
 
 writel(AT91C_PA23_TXD2, AT91C_PIOA_OER);
 
 is the most correct way. 

most correct way are big words. No, this is not correct at all.

The whole set of address / offset definitions in
include/asm-arm/arch-at91rm9200/AT91RM9200.h should be turned into a C
struct.


Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH, MD: Wolfgang Denk  Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: w...@denx.de
When all else fails, read the instructions.
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


[U-Boot] [PATCH] ARM AT91 new board EB+CPUx9K2

2009-10-27 Thread Jens Scharsig
This patch adds a new ARM AT91RM9200 board, named EB+CPUx9K2.

* support for EB+CPUx9K2 board by BuS Elektronik GmbH  Co. KG 
* select via make EB_CPUx9K2_config 

Signed-off-by: Jens Scharsig e...@bus-elektronik.de
---
This patch needs the [PATCH] AT91RM9200 BGA port D defines 
(http://thread.gmane.org/gmane.comp.boot-loaders.u-boot/50667)

This supports the old CONFIG_DRIVER_ETHER and the new CONFIG_DRIVER_AT91EMAC
([PATCH] AT92RM9200 EMAC driver for NET MULTI API
 http://thread.gmane.org/gmane.comp.boot-loaders.u-boot/69484)
By default the config use the old CONFIG_DRIVER_ETHER (it can be switch on
line 192 in include/configs/EB_CPUx9K2.h) 


diff --git a/MAINTAINERS b/MAINTAINERS
index d70a9d2..6027242 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -696,6 +696,10 @@ Steve Sakoman sako...@gmail.com
 
omap3_overo ARM CORTEX-A8 (OMAP3xx SoC)
 
+Jens Scharsig e...@bus-elektronik.de
+
+   EB_CPUX9K2  ARM920T (AT91RM9200 SoC)
+
 Robert Schwebel r.schwe...@pengutronix.de
 
csb226  xscale
 
diff --git a/MAKEALL b/MAKEALL
index d63c5c2..4cd2a8b 100755
--- a/MAKEALL
+++ b/MAKEALL
@@ -644,6 +644,7 @@ LIST_at91= \
CPU9260 \
CPU9G20 \
csb637  \
+   EB_CPUx9K2  \
kb9202  \
meesc   \
mp2usb  \
diff --git a/Makefile b/Makefile
index a69e6d5..7fd625f 100644
--- a/Makefile
+++ b/Makefile
@@ -2715,6 +2715,9 @@ CPUAT91_config:   unconfig
 csb637_config  :   unconfig
@$(MKCONFIG) $(@:_config=) arm arm920t csb637 NULL at91rm9200
 
+EB_CPUx9K2_config  :   unconfig
+   @$(MKCONFIG) $(@:_config=) arm arm920t EB+CPUx9K2 BuS at91rm9200
+
 kb9202_config  :   unconfig
@$(MKCONFIG) $(@:_config=) arm arm920t kb9202 NULL at91rm9200
 
diff --git a/board/BuS/EB+CPUx9K2/Makefile b/board/BuS/EB+CPUx9K2/Makefile
new file mode 100644
index 000..30e2f18
--- /dev/null
+++ b/board/BuS/EB+CPUx9K2/Makefile
@@ -0,0 +1,51 @@
+#
+# (C) Copyright 2003-2006
+# Wolfgang Denk, DENX Software Engineering, w...@denx.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  := cpux9k2.o
+#led.o
+
+SRCS   := $(SOBJS:.o=.S) $(COBJS:.o=.c)
+OBJS   := $(addprefix $(obj),$(COBJS))
+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 .depend
+
+#
+
+# defines $(obj).depend target
+include $(SRCTREE)/rules.mk
+
+sinclude $(obj).depend
+
+#
diff --git a/board/BuS/EB+CPUx9K2/config.mk b/board/BuS/EB+CPUx9K2/config.mk
new file mode 100644
index 000..ff2cfd1
--- /dev/null
+++ b/board/BuS/EB+CPUx9K2/config.mk
@@ -0,0 +1 @@
+TEXT_BASE = 0x23f0
diff --git a/board/BuS/EB+CPUx9K2/cpux9k2.c b/board/BuS/EB+CPUx9K2/cpux9k2.c
new file mode 100644
index 000..6c29d91
--- /dev/null
+++ b/board/BuS/EB+CPUx9K2/cpux9k2.c
@@ -0,0 +1,393 @@
+/*
+ * (C) Copyright 2008-2009
+ * BuS Elektronik GmbH  Co. KG www.bus-elektronik.de
+ * Jens Scharsig e...@bus-elektronik.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 common.h
+#include 

Re: [U-Boot] [PATCH] ARM AT91 new board EB+CPUx9K2

2009-10-27 Thread Wolfgang Denk
Dear Jens Scharsig,

In message 4ae6b186.9030...@bus-elektronik.de you wrote:
 This patch adds a new ARM AT91RM9200 board, named EB+CPUx9K2.
 
 * support for EB+CPUx9K2 board by BuS Elektronik GmbH  Co. KG 
 * select via make EB_CPUx9K2_config 
 
 Signed-off-by: Jens Scharsig e...@bus-elektronik.de
 ---
 This patch needs the [PATCH] AT91RM9200 BGA port D defines 
 (http://thread.gmane.org/gmane.comp.boot-loaders.u-boot/50667)

Please use shorter lines.

...
 diff --git a/board/BuS/EB+CPUx9K2/cpux9k2.c b/board/BuS/EB+CPUx9K2/cpux9k2.c
 new file mode 100644
 index 000..6c29d91
 --- /dev/null
 +++ b/board/BuS/EB+CPUx9K2/cpux9k2.c
...
 +int board_init(void)
 +{
 + /* Enable Ctrlc */
 + console_init_f();
 +
 + /* Correct IRDA resistor problem / Set PA23_TXD in Output */
 + ((AT91PS_PIO) AT91C_BASE_PIOA)-PIO_OER = AT91C_PA23_TXD2;

Please use I/O accessors to access device registers. Please fix
globally.

 +int misc_init_r(void)
 +{
...
 + if (tm) {
 + sprintf(str, %02x:%02x:%02x:%02x:%02x:%02x,
 + mac[0], mac[1], mac[2],
 + mac[3], mac[4], mac[5]);
 + setenv(ethaddr, str);

Please don't reinvent the wheel. Use eth_setenv_enetaddr().

 +/*
 + * DRAM initialisations
 + */
 +
 +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 auto-sizing the memor and
perfoming at least a basic RAM test.

 +unsigned int lxt972_IsPhyConnected(AT91PS_EMAC p_mac);
 +UCHAR lxt972_GetLinkSpeed(AT91PS_EMAC p_mac);
 +UCHAR lxt972_InitPhy(AT91PS_EMAC p_mac);
 +UCHAR lxt972_AutoNegotiate(AT91PS_EMAC p_mac, int *status);

Please don't use non-stanrard data types like UCHAR.


 +void cpux9k2_nand_hw_init(void)
 +{
 + /* Setup Smart Media, fitst enable the address range of CS3 */
 + *AT91C_EBI_CSA |= AT91C_EBI_CS3A_SMC_SmartMedia;
 + /* set the bus interface characteristics based on
 +tDS Data Set up Time 30 - ns
 +tDH Data Hold Time 20 - ns
 +tALS ALE Set up Time 20 - ns
 +16ns at 60 MHz ~= 3  */
 + /*memory mapping structures */
 +#define SM_ID_RWH(5  28)
 +#define SM_RWH   (1  28)
 +#define SM_RWS   (0  24)
 +#define SM_TDF   (1  8)
 +#define SM_NWS   (3)

Please don't add #defines right in the middle of the code. Move to
header file, or at least to head of file.

And see comment above - use I/O accessors here and everywhere.

 +#if defined(CONFIG_VIDEO)
 +/*
 + h* EB+CPUx9K2/drv_video_init
 + * FUNCTION
 + ***
 + */

Incorrect multiline comment style.

 +int drv_video_init(void)
 +{
 + char *s;
 + unsigned long splash;
 +
 + printf(Init Video as );
 + s = getenv(displaywidth);
 + if (s != NULL)
 + display_width = simple_strtoul(s, NULL, 10);
 + else
 + display_width = 256;
 + s = getenv(displayheight);
 + if (s != NULL)
 + display_height = simple_strtoul(s, NULL, 10);
 + else
 + display_height = 256;
 + printf(%ld x %ld pixel matrix\n, display_width, display_height);
 +
 + #define SM2_RWH (0x7  28)
 + #define SM2_RWS (0x7  24)
 + #define SM2_TDF (15  8)
 + #define SM2_NWS (0x7F)

Please don't add #defines right in the middle of the code. Move to
header file, or at least to head of file.

 diff --git a/board/BuS/EB+CPUx9K2/u-boot.lds b/board/BuS/EB+CPUx9K2/u-boot.lds
 new file mode 100644
 index 000..f4fbf96
 --- /dev/null
 +++ b/board/BuS/EB+CPUx9K2/u-boot.lds

Do you really need a private linker script? Doesn't look so...

 diff --git a/include/configs/EB_CPUx9K2.h b/include/configs/EB_CPUx9K2.h
 new file mode 100644
 index 000..9ff743d
 --- /dev/null
 +++ b/include/configs/EB_CPUx9K2.h
...
 +
 +/*--*/
 +
 +#undef DEBUG
 +
 +/*--*/

Get rid of all this stuff. Don't undef what is not defined in the
beginning, and don't meddle with command line options.


 +#include config_cmd_default.h
 +
 +#define CONFIG_CMD_DHCP
 +#define CONFIG_CMD_PING
 +#define CONFIG_CMD_NAND
 +#define CONFIG_CMD_BMP
 +#define  CONFIG_CMD_I2C
 +#define  CONFIG_I2C_CMD_TREE
 +#define  CONFIG_I2C_CMD_NO_FLAT
 +#define  CONFIG_CMD_DATE
 +#define  CONFIG_CMD_JFFS2

You may want to keep such lists sorted. And please use a consistent
style - either always follow #define with a TAB, or (probably better)
always with a space.


 +#define CONFIG_BAUDRATE 115200
 +#define CONFIG_AT91RM9200_USART
 +#define CONFIG_DBGU  /* define DBGU as console */
 +#undef CONFIG_USART0
 +#undef CONFIG_USART1
 +
 +#undef   CONFIG_HWFLOW
 +#undef   CONFIG_MODEM_SUPPORT

Don;t 

Re: [U-Boot] [PATCH] ARM AT91 new board EB+CPUx9K2

2009-10-27 Thread Wolfgang Denk
Dear Jens Scharsig,

In message 4ae6b186.9030...@bus-elektronik.de you wrote:
 This patch adds a new ARM AT91RM9200 board, named EB+CPUx9K2.

And by the way: please chose a board name that can be used
consistently:

 +EB_CPUx9K2_config:   unconfig
 + @$(MKCONFIG) $(@:_config=) arm arm920t EB+CPUx9K2 BuS at91rm9200

If the target name is EB_CPUx9K2 (why are you shouting here?) then the
board directory and config file names shall be based on EB_CPUx9K2, too.

Thanks.

Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH, MD: Wolfgang Denk  Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: w...@denx.de
Perl itself is  usually  pretty  good  about  telling  you  what  you
shouldn't do. :-) - Larry Wall in 11...@jpl-devvax.jpl.nasa.gov
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH] ARM AT91 new board EB+CPUx9K2

2009-10-27 Thread Jens Scharsig
Wolfgang Denk schrieb:
 Dear Jens Scharsig,
 +int board_init(void)
 +{
 +/* Enable Ctrlc */
 +console_init_f();
 +
 +/* Correct IRDA resistor problem / Set PA23_TXD in Output */
 +((AT91PS_PIO) AT91C_BASE_PIOA)-PIO_OER = AT91C_PA23_TXD2;
 
 Please use I/O accessors to access device registers. Please fix
 globally.
Do you mean change to

writel(AT91C_PA23_TXD2, ((AT91PS_PIO) AT91C_BASE_PIOA)-PIO_OER);

like notation


Best regards Jens

___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH] ARM AT91 new board EB+CPUx9K2

2009-10-27 Thread Jens Scharsig
Wolfgang Denk schrieb:
 And by the way: please chose a board name that can be used
 consistently:
 
 +EB_CPUx9K2_config   :   unconfig
 +@$(MKCONFIG) $(@:_config=) arm arm920t EB+CPUx9K2 BuS at91rm9200
 
 If the target name is EB_CPUx9K2 (why are you shouting here?) then the
 board directory and config file names shall be based on EB_CPUx9K2, too.

It's a incomplete rename by my side. sorry.

Wath name/syntax do you prefer? eb_cpux9k2... or eb+cpux9k2...

Best regards,

Jens Scharsig

___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH] ARM AT91 new board EB+CPUx9K2

2009-10-27 Thread Wolfgang Denk
Dear Jens Scharsig,

In message 4ae7110b.7030...@bus-elektronik.de you wrote:
 Wolfgang Denk schrieb:
  And by the way: please chose a board name that can be used
  consistently:
  
  +EB_CPUx9K2_config :   unconfig
  +  @$(MKCONFIG) $(@:_config=) arm arm920t EB+CPUx9K2 BuS at91rm9200
  
  If the target name is EB_CPUx9K2 (why are you shouting here?) then the
  board directory and config file names shall be based on EB_CPUx9K2, too.
 
 It's a incomplete rename by my side. sorry.
 
 Wath name/syntax do you prefer? eb_cpux9k2... or eb+cpux9k2...

'+' is not a valid character in any identifier, so please avoid this.

Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH, MD: Wolfgang Denk  Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: w...@denx.de
It's not an optical illusion, it just looks like one.   -- Phil White
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH] ARM AT91 new board EB+CPUx9K2

2009-10-27 Thread Scott Wood
On Tue, Oct 27, 2009 at 12:02:34PM +0100, Wolfgang Denk wrote:
  +#define CONFIG_SYS_FLASH_ERASE_TOUT(6*CONFIG_SYS_HZ)
  +#define CONFIG_SYS_FLASH_WRITE_TOUT(2*CONFIG_SYS_HZ)
 
 This looks wrong to me. A timeout is a time, but CONFIG_SYS_HZ is a
 frequency, i. e. the inverse of a time. These don't mix.

We've been over this:
http://lists.denx.de/pipermail/u-boot/2009-September/059961.html
:-P

C values don't carry units, so you can't assume that multiplying a frequency
by 6 means you want another frequency 6 times as fast.

Whether the timeout is supposed to be expressed in ticks or in some other
unit such as milliseconds is another matter.

-Scott
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot