Re: [U-Boot] [PATCH v2] Add support for KMC KZM-ARM11-01 board

2008-09-08 Thread Wolfgang Denk
Dear Atsuo Igarashi,

In message <[EMAIL PROTECTED]> you wrote:
>
> Hi,
> 
> I've fixed which Jean-Christophe pointed out.
> 
> Regards,
> Atsuo
> ---
> This patch adds support for KMC KZM-ARM11-01 board.
> 
> Signed-off-by Atsuo Igarashi <[EMAIL PROTECTED]>

The you have the content of the message swapped. The "Hi, I've
..Regards, Atsuo" part belongs *below the '---' line, and the "This
patch ... Signed-off-by:" part belongs *above* it.

The text above the '---' line will become the commit message, the text
below it is just comment.

...
> +int board_init (void)
> +{
> + int i;
...
> + /* RedBoot also has an empty loop with 10 iterations here -
> +  * clock doesn't run yet */

Incorrect multiline comment.

> + for (i = 0; i < 10; i++)
> + ;
...
> + /* clock still doesn't run */
> + for (i = 0; i < 10; i++)
> + ;

Be careful here, this might not do what you think it does. The
compiler might optimize these loops away.

Why are they needed in the first place?

> +/*
> + * The MX31ADS board seems to have a hardware "peculiarity" confirmed under
> + * U-Boot, RedBoot and Linux: the ethernet Rx signal is reaching the CS8900A
> + * controller inverted. The controller is capable of detecting and correcting
> + * this, but it needs 4 network packets for that. Which means, at startup, 
> you
> + * will not receive answers to the first 4 packest, unless there have been 
> some
> + * broadcasts on the network, or your board is on a hub. Reducing the ARP
> + * timeout from default 5 seconds to 200ms we speed up the initial TFTP
> + * transfer, should the user wish one, significantly.
> + */
> +#define CONFIG_ARP_TIMEOUT   200UL


Is this really needed on your hardware, too? I doubt it.

> +#define CFG_HZ   CONFIG_MX31_CLK32 /* use 32kHz clock as 
> source */

This is wrong. CFG_HZ must always be defined as 1000; it is a
constant.

> +/* Address and size of Redundant Environment Sector  */
> +#define CFG_ENV_OFFSET_REDUND(CFG_ENV_OFFSET + CFG_ENV_SIZE)
> +#define CFG_ENV_SIZE_REDUND  CFG_ENV_SIZE
> +
> +/* S29WS256N NOR flash has 4 32KiB small sectors at the beginning and at the 
> end.
> + * The rest of 32MiB is in 128KiB big sectors. U-Boot occupies the low 4 
> sectors,
> + * if we put environment next to it, we will have to occupy 128KiB for it.
> + * Putting it at the top of flash we use only 32KiB. */
> +#define CFG_ENV_ADDR (CFG_MONITOR_BASE + CFG_ENV_SECT_SIZE)

This is a very ugly set up, because you split the U-Boot related
informatiomn, and you block both ends of your flash memory. Why don;t
you locate the environment for example in the third and fourts
sectors, i. e. use such a setup (called "embedded environment"):

sector 1:  32 KiB - U-Boot code
sector 2:  32 KiB - more U-Boot code
sector 3:  32 KiB - environment, first copy
sector 4:  32 KiB - environment, second (redundant) copy
sector 5: 128 KiB - more U-Boot code
...

?

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: [EMAIL PROTECTED]
Every living thing wants to survive.
-- Spock, "The Ultimate Computer", stardate 4731.3
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH][for 1.3.5] Fix handling of mem reserves for ramdisk

2008-09-08 Thread Heiko Schocher
Hello Kumar,

Kumar Gala wrote:
[...]
>> Please have a look at the following patch, it deletes the steps a) - c)
>> and fixes the fdt chosen command ...
[...]
>> diff --git a/common/cmd_fdt.c b/common/cmd_fdt.c
>> index 0593bad..288a5c4 100644
>> --- a/common/cmd_fdt.c
>> +++ b/common/cmd_fdt.c
>> @@ -450,7 +450,8 @@ int do_fdt (cmd_tbl_t * cmdtp, int flag, int argc,
>> char *argv[])
>> initrd_end = simple_strtoul(argv[3], NULL, 16);
>> }
>>
>> -fdt_chosen(working_fdt, initrd_start, initrd_end, 1);
>> +fdt_chosen(working_fdt, 1);
>> +fdt_initrd(working_fdt, initrd_start, initrd_end, 1);
> 
> You are removing functionality, if you want to do this add a command
> 'fdt initrd' that sets the initrd props and the mem reserve information.

Hmm... really? Your patch

http://git.denx.de/?p=u-boot.git;a=commitdiff;h=2a1a2cb6e2b87ee550e6f27b647d23331dfd5e1b#patch3

moved functionality from fdt_chosen in the fdt_initrd function and
called fdt_initrd() in fdt_chosen ().

My patch removes now this fdt_initrd() call from fdt_chosen(), and
so I call it here to fix the fdt_chosen command ... maybe I miss
something?

>> }
>> /* resize the fdt */
>> else if (strncmp(argv[1], "re", 2) == 0) {
>> diff --git a/common/fdt_support.c b/common/fdt_support.c
>> index a7773ab..8ceeb0f 100644
>> --- a/common/fdt_support.c
>> +++ b/common/fdt_support.c
>> @@ -165,7 +165,7 @@ int fdt_initrd(void *fdt, ulong initrd_start,
>> ulong initrd_end, int force)
>> return 0;
>> }
>>
>> -int fdt_chosen(void *fdt, ulong initrd_start, ulong initrd_end, int
>> force)
>> +int fdt_chosen(void *fdt, int force)
>> {
>> int   nodeoffset;
>> int   err;
>> @@ -215,8 +215,6 @@ int fdt_chosen(void *fdt, ulong initrd_start,
>> ulong initrd_end, int force)
>> }
>> }
>>
>> -fdt_initrd(fdt, initrd_start, initrd_end, force);
>> -
>> #ifdef CONFIG_OF_STDOUT_VIA_ALIAS
[...]
> The reason we had the code before was to try and make sure the size of
> the fdt was as close to its final size as possible before we dealt with
> the ramdisk relocation (boot_ramdisk_high()) that included the
> properties and the memreserve in the fdt.  Step's a)-c) are there to
> make sure the size is correct.

Hmmm... and thats the reason why we risk to forgot a memreservation?
(Keep in mind, I think actually it is not possible to boot Linux
with actual u-boot from a Ramdisk in Flash on a powerpc!)

Is this really so essential to know the final fdt size?

While writing this, and if the final fdt size is so important,
I wanted to propose a fix Ramdisk address we can later find and
delete, but then I saw your patch

http://lists.denx.de/pipermail/u-boot/2008-September/040054.html

does this principally! So this patch is okay for me.

bye
Heiko
-- 
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


[U-Boot] [PATCH v2] Add support for KMC KZM-ARM11-01 board

2008-09-08 Thread Atsuo Igarashi
Hi,

I've fixed which Jean-Christophe pointed out.

Regards,
Atsuo
---
This patch adds support for KMC KZM-ARM11-01 board.

Signed-off-by Atsuo Igarashi <[EMAIL PROTECTED]>
 MAKEALL |1 +
 Makefile|3 +
 board/kzm_arm11/Makefile|   49 +++
 board/kzm_arm11/config.mk   |1 +
 board/kzm_arm11/kzm_arm11.c |  108 +++
 board/kzm_arm11/lowlevel_init.S |  287 +++
 board/kzm_arm11/u-boot.lds  |   72 ++
 include/asm-arm/mach-types.h|   13 ++
 include/configs/kzm_arm11.h |  192 ++
 9 files changed, 726 insertions(+), 0 deletions(-)
 create mode 100644 board/kzm_arm11/Makefile
 create mode 100644 board/kzm_arm11/config.mk
 create mode 100644 board/kzm_arm11/kzm_arm11.c
 create mode 100644 board/kzm_arm11/lowlevel_init.S
 create mode 100644 board/kzm_arm11/u-boot.lds
 create mode 100644 include/configs/kzm_arm11.h

diff --git a/MAKEALL b/MAKEALL
index 9ccb9ac..ab40abc 100755
--- a/MAKEALL
+++ b/MAKEALL
@@ -522,6 +522,7 @@ LIST_ARM11="		\
 	apollon		\
 	imx31_litekit	\
 	imx31_phycore	\
+	kzm_arm11	\
 	mx31ads		\
 	smdk6400	\
 "
diff --git a/Makefile b/Makefile
index a342a88..6c80b64 100644
--- a/Makefile
+++ b/Makefile
@@ -2785,6 +2785,9 @@ imx31_litekit_config	: unconfig
 imx31_phycore_config	: unconfig
 	@$(MKCONFIG) $(@:_config=) arm arm1136 imx31_phycore NULL mx31
 
+kzm_arm11_config	: unconfig
+	@$(MKCONFIG) $(@:_config=) arm arm1136 kzm_arm11 NULL mx31
+
 mx31ads_config		: unconfig
 	@$(MKCONFIG) $(@:_config=) arm arm1136 mx31ads freescale mx31
 
diff --git a/board/kzm_arm11/Makefile b/board/kzm_arm11/Makefile
new file mode 100644
index 000..dda48ea
--- /dev/null
+++ b/board/kzm_arm11/Makefile
@@ -0,0 +1,49 @@
+#
+# Derived from mx31ads
+#
+# Copyright (C) 2008, Guennadi Liakhovetski <[EMAIL PROTECTED]>
+#
+# 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	:= kzm_arm11.o
+SOBJS	:= lowlevel_init.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 $(obj).depend
+
+#
+
+# defines $(obj).depend target
+include $(SRCTREE)/rules.mk
+
+sinclude $(obj).depend
+
+#
diff --git a/board/kzm_arm11/config.mk b/board/kzm_arm11/config.mk
new file mode 100644
index 000..d34dc02
--- /dev/null
+++ b/board/kzm_arm11/config.mk
@@ -0,0 +1 @@
+TEXT_BASE = 0x87f0
diff --git a/board/kzm_arm11/kzm_arm11.c b/board/kzm_arm11/kzm_arm11.c
new file mode 100644
index 000..39e39b7
--- /dev/null
+++ b/board/kzm_arm11/kzm_arm11.c
@@ -0,0 +1,108 @@
+/*
+ * Derived from mx31ads
+ *
+ * Copyright (C) 2008, Guennadi Liakhovetski <[EMAIL PROTECTED]>
+ *
+ * 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 
+#include 
+#include 
+#include 
+
+DECLARE_GLOBAL_DATA_PTR;
+
+int dram_init (void)
+{
+	gd->bd->bi_dram[0].start = PHYS_SDRAM_1;
+	gd->bd->bi_dram[0].size = PHYS_SDRAM_1_SIZE;
+
+	return 0;
+}
+
+int board_init (void)
+{
+	int i;
+
+	/* CS0 & CS1: Nor Flash */
+	/*
+	 * CS0L, CS0A and CS0U values are from the RedBoot sources.
+	 */
+	__REG(CSCR_U(0)) = 0x1801;
+	__REG(CSCR_L(0)) = 0x45450D01;
+	__REG(CSCR_A(0)) = 0x00

Re: [U-Boot] FSBBP: uboot Programming on to the flash for MPC8548 for bootup

2008-09-08 Thread Ajeesh Kumar
Hi Andy,

Thank you for your Info, so if my compiled output is <200k, my .bin file
will easily fit into the boundary?

Regards,
   AJEESH KUMAR


-Original Message-
From: Andy Fleming [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, September 09, 2008 3:16 AM
To: [EMAIL PROTECTED]
Cc: u-boot@lists.denx.de
Subject: Re: [U-Boot] FSBBP: uboot Programming on to the flash for MPC8548
for bootup

On Wed, Aug 27, 2008 at 12:16 AM, Ajeesh Kumar <[EMAIL PROTECTED]>
wrote:
> hi sir/madam,
>
> I'm using a MPC8548E processor(power pc) also, i've interfaced a nor 
> flash of 128 MB to the processor.
> i've read few documents and got to know that the uboot.bin should be 
> programmed at 0xfff8.
> Also, when i saw the uboot.bin size it was 512K. so, it could fit 
> between 0xfff8 - 0x.
> I 'M USING ABATRON BDI2000/BDI3000 FOR THIS.
> Now my question is:
> 1) If i'm making changes(addition/deletion of code) to the 
> bootloader(uboot
> 1.2) and re compile it, i believe that the size of the uboot.bin will 
> get changed i.e >/< 512K. NOW AT WHICH LOCATION I SHOULD FLASH THE 
> UBOOT.BIN(SIZE IS NOT EQUAL TO 512) FOR Eg.  If my uboot.bin size is 
> >512K ?


Well, it's not likely you will change the size of the binary.  You see, the
512K size is a result of a quirk of the 85xx platform.  The reset vector is
at 0xfffc, but we define the base address to be 0xfff8, so we fill
in the space between, and it's 512K.

The result is, you don't need to mind the size, unless you grow the compiled
output by over 200K.  Try to avoid that ;)

Andy


The information contained in this electronic message and any attachments to 
this message are intended for the exclusive use of the addressee(s) and may 
contain proprietary, confidential or privileged information. If you are not the 
intended recipient, you should not disseminate, distribute or copy this e-mail. 
Please notify the sender immediately and destroy all copies of this message and 
any attachments contained in it.
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH] Support multiple SGMII/TBI interfaces for TSEC ethernet

2008-09-08 Thread Peter Tyser
Hi Andy,

On Mon, 2008-09-08 at 19:34 -0500, Andy Fleming wrote:
> On Mon, Sep 8, 2008 at 6:39 PM, Peter Tyser <[EMAIL PROTECTED]> wrote:
> > The original code only supported using 1 TSEC port in SGMII mode using an
> > internal TBI PHY.  Additionally, the TBI internal PHY was being accessed
> > at the same register offset as the external PHY for the given TSEC port.
> > This hardwiring of the TBI PHY register address based on external PHY
> > address will break in many hardware configurations.
> 
> 
> Hm.  This doesn't sound quite right.  I agree with the first part of
> the patch (I was sure I had tested more than TSEC1, but it doesn't
> look like I did it right).  However, I don't understand what you mean
> by the TBI internal PHY being accessed at the same address as the
> external PHY.

When I was referring to the "register offset" in "the TBI internal PHY
was being accessed at the same register offset as the external PHY for
the given TSEC port", I was talking about the address the CPU
read/writes from to generate an access to the external or TBI PHY.

For example, if a board had 4 sgmii interfaces with 4 external PHYs on
an mpc8572 - all 4 PHYs could be physically connected to the MDIO bus of
TSEC1.  Thus to access the external PHYs, the CPU would have to access
the the 85xx's registers at offset 0x24000 of the IMMR.

My understanding is that to access the TBI PHYs, you'd have to use the
following offsets into the IMMR:
TSEC1 - 0x24000
TSEC2 - 0x25000
TSEC3 - 0x26000
...

So to configure TSEC2's PHYs in this configuration (my configuration by
chance:), you'd have to read/write from TSEC1 @ 0x24000 to access the
external PHY, but TSEC2 @ 0x25000 to access the TBI PHY.  This was my
understanding after reading the manual, and believe this is necessary
after debugging the driver on my hardware.

The original code was accessing the TBI PHY via the same register offset
in the 8572 as was used to access the external PHY (eg TSEC1 @ 0x24000
in this example), which didn't appear to work.

> It's assigned to the value of CFG_TBIPA_VALUE.  It's ok
> for all of the controllers to use the same value.  If the value
> conflicts with that of your external PHY, change CFG_TBIPA_VALUE in
> your board's config file.  I'm not really interested in allocating PHY
> address space for the TBI PHYs.  It will make things more difficult in
> the future, since it effectively halves the number of available
> addresses.

I see, the possibility of having the same PHY address didn't cross my
mind:)  How would the "mii" commands treat having multiple PHYs at the
same address, but on different buses?

I can try giving all TBI PHYs the address of CFG_TBIPA_VALUE tomorrow
and make sure it works.  Assuming it does, I'll resubmit, keeping the
1st part the same while changing the 2nd section of the patch to:

   /* Assign a Physical address to the TBI */
   regs->tbipa = CFG_TBIPA_VALUE;
-   phyregs->tbipa = CFG_TBIPA_VALUE;
   asm("sync");

Let me know if I'm missing something...

Thanks,
Peter

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


Re: [U-Boot] u-boot 1.2.0 -> 1.3.4 migration

2008-09-08 Thread Jerry Van Baren
Alexander Danilov wrote:
> My bsp for u-boot 1.2.0 for AMCC PPC440EPx custom board works. I've
> moved all bsp code to current u-boot version (1.3.4). All works fine
> but I am getting program check exception when sending or receiving
> packet over ethernet (EMAC0).
> I've tryed to debug it but ethernet works when bdm connected.
> What was changed in ethernet code for ppc4xx after 1.2.0?

What initialization does your BDM debugger do that your start up code 
does not do?

I don't know what BDM you are using and am not very familiar with the 
4xx family, but Best Practices is to create a minimal BDM config and use 
that, especially when things work with the BDM plugged in but not when 
running bare.

If that doesn't help, git bisect.

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


Re: [U-Boot] CFG_64BIT_xxx and friends

2008-09-08 Thread Jerry Van Baren
Haavard Skinnemoen wrote:
> Haavard Skinnemoen <[EMAIL PROTECTED]> wrote:
>> That's a bit more than expected. Is this with or without --gc-sections?
>> Linking with --gc-sections should make simple_strtoull() go away unless
>> it's actually used.
> 
> That's assuming the fdt and image code doesn't interpret
> CFG_64BIT_VSPRINTF as CFG_BLOAT_ME_HARDER, which it does. So enabling
> CFG_64BIT_VSPRINTF does increase the code size even with --gc-sections.
> 
> I think fdt and common/image.c should stop abusing CFG_64BIT_VSPRINTF
> and get its own symbol instead, e.g. CFG_64BIT_PHYS_ADDR, and perhaps a
> nice str_to_addr() wrapper which selects between strtoul and strtoull
> based on this symbol.

Hi Haavard,

fdt and common.image.c don't use CFG_64BIT_VSPRINTF:

$ find . -name "*.c" | xargs grep CFG_64BIT_VSPRINTF
./disk/part.c:#if defined(CFG_64BIT_LBA) && defined(CFG_64BIT_VSPRINTF)
./common/cmd_ide.c:#if defined(CFG_64BIT_LBA) && defined(CFG_64BIT_VSPRINTF)
./common/cmd_ide.c:#if defined(CFG_64BIT_LBA) && defined(CFG_64BIT_VSPRINTF)
./lib_generic/vsprintf.c:#ifdef CFG_64BIT_VSPRINTF
./lib_generic/vsprintf.c:#ifdef CFG_64BIT_VSPRINTF
./lib_generic/vsprintf.c:#ifdef CFG_64BIT_VSPRINTF
./lib_generic/vsprintf.c:#ifdef CFG_64BIT_VSPRINTF

...they use CFG_64BIT_STRTOUL.  If a config defines CFG_64BIT_STRTOUL, 
it is reasonable that the code uses it.  I don't see any disadvantage of 
this vs. creating a new CFG_64BIT_PHYS_ADDR (although I would not object 
to that being created).

Only a select set of PowerPC targets actually define CFG_64BIT_STRTOUL:

$ find . -name "*.[ch]" | xargs grep CFG_64BIT_STRTOUL
./cpu/mpc85xx/mp.c:#ifdef CFG_64BIT_STRTOUL
./include/configs/MPC8540ADS.h:#define CFG_64BIT_STRTOUL1
./include/configs/MPC8572DS.h:#define CFG_64BIT_STRTOUL 1
./include/configs/MPC8536DS.h:#define CFG_64BIT_STRTOUL 1
./include/configs/MPC8548CDS.h:#define CFG_64BIT_STRTOUL1
./include/configs/MPC8568MDS.h:#define CFG_64BIT_STRTOUL1
./include/configs/MPC8541CDS.h:#define CFG_64BIT_STRTOUL1
./include/configs/MPC8610HPCD.h:#define CFG_64BIT_STRTOUL   1
./include/configs/MPC8641HPCN.h:#define CFG_64BIT_STRTOUL   1
./include/configs/sbc8641d.h:#define CFG_64BIT_STRTOUL  1
./include/configs/MPC8555CDS.h:#define CFG_64BIT_STRTOUL1
./include/configs/MPC8560ADS.h:#define CFG_64BIT_STRTOUL1
./include/configs/MPC8544DS.h:#define CFG_64BIT_STRTOUL 1
./include/ppc4xx.h:#define CFG_64BIT_STRTOUL
./common/cmd_fdt.c:#ifdef CFG_64BIT_STRTOUL
./common/cmd_fdt.c:#ifdef CFG_64BIT_STRTOUL
./common/image.c:#ifdef CFG_64BIT_STRTOUL
./lib_generic/vsprintf.c:#ifdef CFG_64BIT_STRTOUL
./lib_generic/vsprintf.c:#endif /* CFG_64BIT_STRTOUL */

[snip]

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


Re: [U-Boot] mpc85xx/27

2008-09-08 Thread u-boot
Synopsis: [PATCH] 85xx: Socrates: Major code update.

State-Changed-From-To: open->closed
State-Changed-By: AndyFleming
State-Changed-When: Tue, 09 Sep 2008 03:55:20 +0200
State-Changed-Why:
applied, thanks




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


Re: [U-Boot] mpc85xx/26

2008-09-08 Thread u-boot
Synopsis: [PATCH] 85xx: socrates: Enable Lime support.

State-Changed-From-To: open->closed
State-Changed-By: AndyFleming
State-Changed-When: Tue, 09 Sep 2008 03:54:51 +0200
State-Changed-Why:
Applied, thanks




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


Re: [U-Boot] mpc85xx/22

2008-09-08 Thread u-boot
Synopsis: [PATCH] Removed hardcoded MxMR loop value from upmconfig() for 
MPC85xx.

State-Changed-From-To: open->closed
State-Changed-By: AndyFleming
State-Changed-When: Tue, 09 Sep 2008 03:54:12 +0200
State-Changed-Why:
Applied, with fuzz




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


Re: [U-Boot] mpc85xx/14

2008-09-08 Thread u-boot
Synopsis: [U-Boot-Users] [PATCH] Update Freescale 85xx boards to sys_eeprom.c

State-Changed-From-To: open->closed
State-Changed-By: AndyFleming
State-Changed-When: Tue, 09 Sep 2008 03:53:16 +0200
State-Changed-Why:
Applied




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


[U-Boot] Please pull u-boot-mpc85xx.git

2008-09-08 Thread Andy Fleming
are available in the git repository at:

  git://www.denx.de/git/u-boot-mpc85xx.git master

Anatolij Gustschin (1):
  85xx: socrates: Enable Lime support.

Andy Fleming (1):
  Remove CONFIG_SHOW_ACTIVITY from stx boards which don't support it

Detlev Zundel (1):
  85xx: Socrates: Major code update.

Sergei Poselenov (1):
  Removed hardcoded MxMR loop value from upmconfig() for MPC85xx.

Timur Tabi (1):
  Update Freescale 85xx boards to sys_eeprom.c

 board/freescale/common/Makefile |1 -
 board/freescale/common/cds_eeprom.c |   60 
 board/socrates/law.c|4 +-
 board/socrates/socrates.c   |  280 ++
 board/socrates/tlb.c|   13 ++-
 board/socrates/upm_table.h  |   52 +--
 cpu/mpc85xx/cpu.c   |   15 +-
 drivers/video/mb862xx.c |3 +-
 include/configs/MPC8541CDS.h|9 +-
 include/configs/MPC8548CDS.h|9 +-
 include/configs/MPC8555CDS.h|   10 +-
 include/configs/socrates.h  |  134 +++--
 include/configs/stxgp3.h|4 -
 include/configs/stxssa.h|4 -
 14 files changed, 420 insertions(+), 178 deletions(-)
 delete mode 100644 board/freescale/common/cds_eeprom.c
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


[U-Boot] [PATCH] Remove CONFIG_SHOW_ACTIVITY from stx boards which don't support it

2008-09-08 Thread Andy Fleming
commit 9cff4448a9cb882defe6c8bde73b77fc0c636799 removed the mpc85xx version
of timer_interrupt, which was overriding the lib_ppc version.  The lib_ppc
version tries to invoke board_show_activity() if CONFIG_SHOW_ACTIVITY is
defined.  stxgp3 and stxssa defined it, despite not defining
board_show_activity().  I'll leave it to the stx* maintainer to
implement that function if desired.  :)

Signed-off-by: Andy Fleming <[EMAIL PROTECTED]>
---
 include/configs/stxgp3.h |4 
 include/configs/stxssa.h |4 
 2 files changed, 0 insertions(+), 8 deletions(-)

diff --git a/include/configs/stxgp3.h b/include/configs/stxgp3.h
index ea79de7..7cb5dc9 100644
--- a/include/configs/stxgp3.h
+++ b/include/configs/stxgp3.h
@@ -55,10 +55,6 @@
 
 #define CONFIG_SYS_CLK_FREQ  /* most pci cards are 33Mhz */
 
-/* Blinkin' LEDs for Robert :-)
-*/
-#define CONFIG_SHOW_ACTIVITY 1
-
 /*
  * These can be toggled for performance analysis, otherwise use default.
  */
diff --git a/include/configs/stxssa.h b/include/configs/stxssa.h
index ac349df..8e2d56f 100644
--- a/include/configs/stxssa.h
+++ b/include/configs/stxssa.h
@@ -55,10 +55,6 @@
 
 #define CONFIG_SYS_CLK_FREQ3300 /* most pci cards are 33Mhz */
 
-/* Blinkin' LEDs for Robert :-)
-*/
-#define CONFIG_SHOW_ACTIVITY 1
-
 /*
  * These can be toggled for performance analysis, otherwise use default.
  */
-- 
1.5.4.GIT

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


Re: [U-Boot] [PATCH] Add MTD core & partition

2008-09-08 Thread Kyungmin Park
On Tue, Sep 9, 2008 at 4:30 AM, Scott Wood <[EMAIL PROTECTED]> wrote:
> On Fri, Aug 29, 2008 at 05:13:23PM +0900, Kyungmin Park wrote:
>> It's preparation for UBI codes.
>> UBI uses partition and get & put mtd devices
>
> Please import the latest MTD code; there have been several cleanups/fixes
> in mtdpart.c recently (in particular, the patches from Atsushi Nemoto
> dated Jul 19).
>
> As for the #if 0 blocks, I'd rather leave them out entirely -- I think
> the increased readability would be worth the occasional extra merge
> conflict when importing new upstream code.
>

That's the reason I want to create new tree to sync u-boot tree. At
that time there's no point, ecc_stats, and ... fields at mtd_info, So
I disable it. Now it's included and we can remove #if 0.


>> ---
>> diff --git a/drivers/mtd/Makefile b/drivers/mtd/Makefile
>> index 6538f7a..d225a68 100644
>> --- a/drivers/mtd/Makefile
>> +++ b/drivers/mtd/Makefile
>> @@ -25,6 +25,7 @@ include $(TOPDIR)/config.mk
>>
>>  LIB  := $(obj)libmtd.a
>>
>> +COBJS-$(CONFIG_CMD_UBI) += mtdcore.o mtdpart.o
>
> Is UBI the only case where we want the generic MTD infrastructure?  Maybe
> we can remove some duplication and/or add partition support elsewhere.

Yes I agree. As I know there's no users to use mtdpart. Instead it
used another mtdpart format at mtdpart command. Next time it changes
from previous one to MTD infrastructure.

>
>>  COBJS-$(CONFIG_HAS_DATAFLASH) += at45.o
>>  COBJS-$(CONFIG_FLASH_CFI_DRIVER) += cfi_flash.o
>>  COBJS-$(CONFIG_HAS_DATAFLASH) += dataflash.o
>> diff --git a/drivers/mtd/mtdcore.c b/drivers/mtd/mtdcore.c
>> new file mode 100644
>> index 000..2fb6099
>> --- /dev/null
>> +++ b/drivers/mtd/mtdcore.c
>> @@ -0,0 +1,142 @@
>> +/*
>> + * $Id: mtdcore.c,v 1.47 2005/11/07 11:14:20 gleixner Exp $
>> + *
>> + * Core registration and callback routines for MTD
>> + * drivers and users.
>> + */
>> +
>> +#include 
>> +#include 
>> +#include 
>
> I don't see mtd_uboot.h or ubi_uboot.h in the current tree, nor are they
> added by this patch.
>
> Is this patch supposed to depend on the giant UBI patch (I'd think not,
> since the changelog says it's preparing for UBI)?
>
>> +/**
>> + *  del_mtd_device - unregister an MTD device
>> + *  @mtd: pointer to MTD device info structure
>> + *
>> + *  Remove a device from the list of MTD devices present in the system,
>> + *  and notify each currently active MTD 'user' of its departure.
>> + *  Returns zero on success or 1 on failure, which currently will happen
>> + *  if the requested device does not appear to be present in the list.
>> + */
>> +int del_mtd_device (struct mtd_info *mtd)
>> +{
>> + int ret;
>> +
>> + if (mtd_table[mtd->index] != mtd) {
>> + ret = -ENODEV;
>> + } else if (mtd->usecount) {
>> + printk(KERN_NOTICE "Removing MTD device #%d (%s) with use 
>> count %d\n",
>> + mtd->index, mtd->name, mtd->usecount);
>> + ret = -EBUSY;
>> + } else {
>> + /* No need to get a refcount on the module containing
>> +  *the notifier, since we hold the 
>> mtd_table_mutex */
>> + mtd_table[mtd->index] = NULL;
>> +
>> + ret = 0;
>> + }
>> +
>> + return ret;
>> +}
>
> We should remove all the refcounting/removal stuff -- it's just bloat in
> u-boot.

I don't want to remove or modify imported codes at least MTD & UBI codes.

Thank you,
Kyungmin Park
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH] Support multiple SGMII/TBI interfaces for TSEC ethernet

2008-09-08 Thread Andy Fleming
On Mon, Sep 8, 2008 at 6:39 PM, Peter Tyser <[EMAIL PROTECTED]> wrote:
> The original code only supported using 1 TSEC port in SGMII mode using an
> internal TBI PHY.  Additionally, the TBI internal PHY was being accessed
> at the same register offset as the external PHY for the given TSEC port.
> This hardwiring of the TBI PHY register address based on external PHY
> address will break in many hardware configurations.


Hm.  This doesn't sound quite right.  I agree with the first part of
the patch (I was sure I had tested more than TSEC1, but it doesn't
look like I did it right).  However, I don't understand what you mean
by the TBI internal PHY being accessed at the same address as the
external PHY.  It's assigned to the value of CFG_TBIPA_VALUE.  It's ok
for all of the controllers to use the same value.  If the value
conflicts with that of your external PHY, change CFG_TBIPA_VALUE in
your board's config file.  I'm not really interested in allocating PHY
address space for the TBI PHYs.  It will make things more difficult in
the future, since it effectively halves the number of available
addresses.

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


Re: [U-Boot] [ppc4xx] Please pull git://www.denx.de/git/u-boot-ppc4xx.git

2008-09-08 Thread Wolfgang Denk
Dear Stefan Roese,

In message <[EMAIL PROTECTED]> you wrote:
> The following changes since commit f158c3d51838474c4c36af365af145fbaf92b694:
>   Wolfgang Denk (1):
> Merge branch 'master' of ssh://10.10.0.7/home/wd/git/u-boot/master
> 
> are available in the git repository at:
> 
>   git://www.denx.de/git/u-boot-ppc4xx.git master
> 
> Adam Graham (2):
>   ppc4xx: IBM Memory Controller DDR autocalibration routines
>   ppc4xx: Update Kilauea to use PPC4xx DDR autocalibration routines
> 
> Matthias Fuchs (3):
>   ppc4xx: Update CPCI405 variants handling
>   ppc4xx: Cleanup CPCI405 linker script
>   ppc4xx: Update CPCI405(AB) configuration
> 
> Ricardo Ribalda Delgado (1):
>   ppc44x: Unification of virtex5 pp440 boards
> 
> Stefan Roese (4):
>   ppc4xx: Fix compilation warning for canyonlands & glacier
>   ppc4xx: Fix compilation warning for PIP405
>   ppc4xx: Remove CONFIG_CS8952_PHY define
>   ppc4xx: Move ppc4xx specific prototypes to ppc4xx header
> 
> Victor Gallardo (1):
>   ppc4xx: Add support for GPCS, SGMII and M88E1112 PHY
> 
>  CREDITS|3 +-
>  MAINTAINERS|2 +
>  MAKEALL|4 +
>  Makefile   |   47 +-
>  board/avnet/v5fx30teval/.gitignore |1 +
>  .../ml507/config.mk => avnet/v5fx30teval/Makefile} |   12 +-
>  board/avnet/v5fx30teval/v5fx30teval.c  |   28 +
>  board/avnet/v5fx30teval/xparameters.h  |   33 +
>  board/esd/cpci405/config.mk|   16 +-
>  board/esd/cpci405/u-boot.lds   |   15 -
>  board/xilinx/ml507/.gitignore  |1 +
>  board/xilinx/ml507/Makefile|   41 +-
>  board/xilinx/ml507/init.S  |   53 -
>  board/xilinx/ml507/ml507.c |   21 +-
>  board/xilinx/ml507/xparameters.h   |   17 +-
>  board/xilinx/ppc440-generic/.gitignore |1 +
>  board/xilinx/ppc440-generic/Makefile   |   62 +
>  board/xilinx/ppc440-generic/init.S |   45 +
>  .../{ml507 => ppc440-generic}/u-boot-ram.lds   |0 
>  .../{ml507 => ppc440-generic}/u-boot-rom.lds   |0 
>  .../xilinx/ppc440-generic/xilinx_ppc440_generic.c  |   52 +
>  board/xilinx/ppc440-generic/xparameters.h  |   34 +
>  cpu/ppc4xx/44x_spd_ddr2.c  |  158 ++-
>  cpu/ppc4xx/4xx_enet.c  |  168 +++-
>  cpu/ppc4xx/4xx_ibm_ddr2_autocalib.c| 1212 
> 
>  cpu/ppc4xx/Makefile|3 +
>  cpu/ppc4xx/miiphy.c|   37 +-
>  include/asm-ppc/ppc4xx-sdram.h |3 +-
>  include/configs/CPCI4052.h |6 +
>  include/configs/CPCI405AB.h|6 +
>  include/configs/PIP405.h   |1 -
>  include/configs/kilauea.h  |   19 +
>  include/configs/ml507.h|   91 +--
>  include/configs/v5fx30teval.h  |   49 +
>  include/configs/xilinx-ppc440-generic.h|   49 +
>  include/configs/xilinx-ppc440.h|  106 ++
>  include/ppc440.h   |   13 -
>  include/ppc4xx.h   |   13 +
>  include/ppc4xx_enet.h  |3 +
>  41 files changed, 2112 insertions(+), 336 deletions(-)
>  create mode 100644 board/avnet/v5fx30teval/.gitignore
>  rename board/{xilinx/ml507/config.mk => avnet/v5fx30teval/Makefile} (76%)
>  create mode 100644 board/avnet/v5fx30teval/v5fx30teval.c
>  create mode 100644 board/avnet/v5fx30teval/xparameters.h
>  create mode 100644 board/xilinx/ml507/.gitignore
>  delete mode 100644 board/xilinx/ml507/init.S
>  create mode 100644 board/xilinx/ppc440-generic/.gitignore
>  create mode 100644 board/xilinx/ppc440-generic/Makefile
>  create mode 100644 board/xilinx/ppc440-generic/init.S
>  rename board/xilinx/{ml507 => ppc440-generic}/u-boot-ram.lds (100%)
>  rename board/xilinx/{ml507 => ppc440-generic}/u-boot-rom.lds (100%)
>  create mode 100644 board/xilinx/ppc440-generic/xilinx_ppc440_generic.c
>  create mode 100644 board/xilinx/ppc440-generic/xparameters.h
>  create mode 100644 cpu/ppc4xx/4xx_ibm_ddr2_autocalib.c
>  create mode 100644 include/configs/v5fx30teval.h
>  create mode 100644 include/configs/xilinx-ppc440-generic.h
>  create mode 100644 include/configs/xilinx-ppc440.h

Applied, 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: [EMAIL PROTECTED]
"I knew then (in 1970) that a 4-kbyte m

Re: [U-Boot] [PATCH] disk-on-chip: remove duplicate doc_probe declaration

2008-09-08 Thread Wolfgang Denk
Dear Jean-Christophe PLAGNIOL-VILLARD,

In message <[EMAIL PROTECTED]> you wrote:
> Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <[EMAIL PROTECTED]>
> ---
>  board/atc/atc.c|1 -
>  board/cpu86/cpu86.c|1 -
>  board/cpu87/cpu87.c|1 -
>  board/gen860t/gen860t.c|2 --
>  board/mcc200/mcc200.c  |1 -
>  board/mpl/common/common_util.c |1 -
>  board/pm520/pm520.c|1 -
>  board/pm826/pm826.c|1 -
>  board/pm828/pm828.c|1 -
>  board/svm_sc8xx/svm_sc8xx.c|1 -
>  10 files changed, 0 insertions(+), 11 deletions(-)

Applied, 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: [EMAIL PROTECTED]
In the realm of scientific observation, luck is granted only to those
who are prepared. - Louis Pasteur
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH] onenand_uboot: fix warning: 'struct mtd_oob_ops' declared inside parameter list

2008-09-08 Thread Wolfgang Denk
Dear Jean-Christophe PLAGNIOL-VILLARD,

In message <[EMAIL PROTECTED]> you wrote:
> Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <[EMAIL PROTECTED]>
> ---
>  include/onenand_uboot.h |1 +
>  1 files changed, 1 insertions(+), 0 deletions(-)

Applied, 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: [EMAIL PROTECTED]
Time is a drug. Too much of it kills you.
  - Terry Pratchett, _Small Gods_
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH] rs5c372: fix rtc_set prototype

2008-09-08 Thread Wolfgang Denk
Dear Jean-Christophe PLAGNIOL-VILLARD,

In message <[EMAIL PROTECTED]> you wrote:
> Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <[EMAIL PROTECTED]>
> ---
>  drivers/rtc/rs5c372.c |3 +--
>  1 files changed, 1 insertions(+), 2 deletions(-)

Applied, 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: [EMAIL PROTECTED]
Every revolutionary idea - in science, politics, art, or  whatever  -
evokes three stages of reaction in a hearer:
  1. It is completely impossible - don't waste my time.
  2. It is possible, but it is not worth doing.
  3. I said it was a good idea all along.
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH] Add support for KMC KZM-ARM11-01 board

2008-09-08 Thread Jean-Christophe PLAGNIOL-VILLARD
On 15:45 Wed 27 Aug , Atsuo Igarashi wrote:
> This patch adds support for KMC KZM-ARM11-01 board.
> 
> Signed-off-by Atsuo Igarashi <[EMAIL PROTECTED]>
> 

>  MAKEALL |1 +
>  Makefile|3 +
>  board/kzm_arm11/Makefile|   49 +++
>  board/kzm_arm11/config.mk   |1 +
>  board/kzm_arm11/kzm_arm11.c |  108 ++
>  board/kzm_arm11/lowlevel_init.S |  297 
> +++
>  board/kzm_arm11/u-boot.lds  |   72 ++
>  include/asm-arm/mach-types.h|   13 ++
>  include/configs/kzm_arm11.h |  202 ++
>  9 files changed, 746 insertions(+), 0 deletions(-)
>  create mode 100644 board/kzm_arm11/Makefile
>  create mode 100644 board/kzm_arm11/config.mk
>  create mode 100644 board/kzm_arm11/kzm_arm11.c
>  create mode 100644 board/kzm_arm11/lowlevel_init.S
>  create mode 100644 board/kzm_arm11/u-boot.lds
>  create mode 100644 include/configs/kzm_arm11.h
> 
> diff --git a/MAKEALL b/MAKEALL
> index e807063..8dab1b6 100755
> --- a/MAKEALL
> +++ b/MAKEALL
> @@ -517,6 +517,7 @@ LIST_ARM11="  \
>   imx31_litekit   \
>   imx31_phycore   \
>   mx31ads \
> + kzm_arm11   \
please keep sorted
>  "
>  
>  #
> diff --git a/Makefile b/Makefile
> index 89fea72..26af973 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -2746,6 +2746,9 @@ imx31_phycore_config: unconfig
>  mx31ads_config   : unconfig
>   @$(MKCONFIG) $(@:_config=) arm arm1136 mx31ads freescale mx31
>  
> +kzm_arm11_config : unconfig
> + @$(MKCONFIG) $(@:_config=) arm arm1136 kzm_arm11 NULL mx31
ditto
> +
>  omap2420h4_config: unconfig
>   @$(MKCONFIG) $(@:_config=) arm arm1136 omap2420h4 NULL omap24xx
>  

> + __REG(CSCR_A(0)) = 0x0045;
> +
> + __REG(CSCR_U(1)) = 0x1801;
> + __REG(CSCR_L(1)) = 0x45450D01;
> + __REG(CSCR_A(1)) = 0x0045;
> +
> + /* setup pins for UART1 */
> + mx31_gpio_mux(MUX_RXD1__UART1_RXD_MUX);
> + mx31_gpio_mux(MUX_TXD1__UART1_TXD_MUX);
> + mx31_gpio_mux(MUX_RTS1__UART1_RTS_B);
> + mx31_gpio_mux(MUX_CTS1__UART1_CTS_B);
> +
> + /* SPI2 */
> + mx31_gpio_mux(MUX_CSPI2_SS2__CSPI2_SS2_B);
> + mx31_gpio_mux(MUX_CSPI2_SCLK__CSPI2_CLK);
> + mx31_gpio_mux(MUX_CSPI2_SPI_RDY__CSPI2_DATAREADY_B);
> + mx31_gpio_mux(MUX_CSPI2_MOSI__CSPI2_MOSI);
> + mx31_gpio_mux(MUX_CSPI2_MISO__CSPI2_MISO);
> + mx31_gpio_mux(MUX_CSPI2_SS0__CSPI2_SS0_B);
> + mx31_gpio_mux(MUX_CSPI2_SS1__CSPI2_SS1_B);
> +
> + /* start SPI2 clock */
> + __REG(CCM_CGR2) = __REG(CCM_CGR2) | (3 << 4);
> +
> + /* PBC setup */
> + /* Enable UART transceivers also reset the Ethernet/external UART */
> + readw(CS4_BASE + 4);
> +
> + writew(0x8023, CS4_BASE + 4);
> +
> + /* RedBoot also has an empty loop with 10 iterations here -
> +  * clock doesn't run yet */
> + for (i = 0; i < 10; i++)
> + ;
> +
> + /* Clear the reset, toggle the LEDs */
> + writew(0xDF, CS4_BASE + 6);
> +
> + /* clock still doesn't run */
> + for (i = 0; i < 10; i++)
> + ;
> +
> + /* See 1.5.4 in IMX31ADSE_PERI_BUS_CNTRL_CPLD_RM.pdf */
> + readb(CS4_BASE + 8);
> + readb(CS4_BASE + 7);
> + readb(CS4_BASE + 8);
> + readb(CS4_BASE + 7);
> +
> + gd->bd->bi_arch_number = MACH_TYPE_KZM_ARM11_01;/* board id for linux */
> + gd->bd->bi_boot_params = 0x8100;/* adress of boot parameters */
> +
> + return 0;
> +}
> +
> +int checkboard (void)
> +{
> + printf("Board: KZM-ARM11-01\n");
> + return 0;
> +}
> diff --git a/board/kzm_arm11/lowlevel_init.S b/board/kzm_arm11/lowlevel_init.S
> new file mode 100644
> index 000..91d5c9b
> --- /dev/null
> +++ b/board/kzm_arm11/lowlevel_init.S
> + ldr r1, [r0, #0x50]
> + and r1, r1, #0x00FF
> + str r1, [r0, #0x50]
> +.endm /* init_aips */
> +
in this file there is some whitespace please fix it
> +/* RedBoot: MAX (Multi-Layer AHB Crossbar Switch) setup */
> +.macro init_max
> + ldr r0, =0x43F04000
> + /* MPR - priority is M4 > M2 > M3 > M5 > M0 > M1 */
> + ldr r1, =0x00302154
> + str r1, [r0, #0x000]/* for S0 */
> + str r1, [r0, #0x100]/* for S1 */
> + str r1, [r0, #0x200]/* for S2 */
> + str r1, [r0, #0x300]/* for S3 */
> + str r1, [r0, #0x400]/* for S4 */
> + /* SGPCR - always park on last master */
> + ldr r1, =0x10
> + str r1, [r0, #0x010]/* for S0 */
> + str r1, [r0, #0x110]/* for S1 */
> + str r1, [r0, #0x210]/* for S2 */
> + str r1, [r0, #0x310]/* for S3 */
> + str r1, [r0, #0x410]/* for S4 */
> + /* MGPCR - restore default values */
> + ldr r1, =0x0
> + str r1, [r0, #0x800]/* for M0 */
> + str r1, [r0, #0x900]   

[U-Boot] [PATCH] ARM: fix warning: target CPU does not support interworking

2008-09-08 Thread Wolfgang Denk
From: Sergei Poselenov <[EMAIL PROTECTED]>

This patch fixes warnings like this:

start.S:0: warning: target CPU does not support interworking

which come from some ARM cross compilers and are caused by hard-coded
(with "--with-cpu=arm9" configuration option) ARM targets (which
support ARM Thumb instructions), while the ARM target selected from
the command line (with "-march=armv4") doesn't support Thumb
instructions.

This warning is issued by the compiler regardless of the real use of
the Thumb instructions in code.

To fix this problem, we use options according to compiler version
being used.

Signed-off-by: Sergei Poselenov <[EMAIL PROTECTED]>
Signed-off-by: Wolfgang Denk <[EMAIL PROTECTED]>
---

 cpu/arm946es/config.mk  |7 +++
 cpu/arm_intcm/config.mk |7 +++
 2 files changed, 14 insertions(+), 0 deletions(-)

diff --git a/cpu/arm946es/config.mk b/cpu/arm946es/config.mk
index 81ca288..f774c7e 100644
--- a/cpu/arm946es/config.mk
+++ b/cpu/arm946es/config.mk
@@ -25,3 +25,10 @@ PLATFORM_RELFLAGS += -fno-strict-aliasing  -fno-common 
-ffixed-r8 \
 -msoft-float
 
 PLATFORM_CPPFLAGS +=  -march=armv4
+# =
+#
+# Supply options according to compiler version
+#
+# =
+PLATFORM_CPPFLAGS +=$(call cc-option,-mapcs-32,-mabi=apcs-gnu)
+PLATFORM_RELFLAGS +=$(call cc-option,-mshort-load-bytes,$(call 
cc-option,-malignment-traps,))
diff --git a/cpu/arm_intcm/config.mk b/cpu/arm_intcm/config.mk
index 81ca288..f774c7e 100644
--- a/cpu/arm_intcm/config.mk
+++ b/cpu/arm_intcm/config.mk
@@ -25,3 +25,10 @@ PLATFORM_RELFLAGS += -fno-strict-aliasing  -fno-common 
-ffixed-r8 \
 -msoft-float
 
 PLATFORM_CPPFLAGS +=  -march=armv4
+# =
+#
+# Supply options according to compiler version
+#
+# =
+PLATFORM_CPPFLAGS +=$(call cc-option,-mapcs-32,-mabi=apcs-gnu)
+PLATFORM_RELFLAGS +=$(call cc-option,-mshort-load-bytes,$(call 
cc-option,-malignment-traps,))
-- 
1.5.4.2

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


[U-Boot] [PATCH v2] ARM: Use do_div() instead of division for "long long".

2008-09-08 Thread Wolfgang Denk
From: Sergei Poselenov <[EMAIL PROTECTED]>

Signed-off-by: Sergei Poselenov <[EMAIL PROTECTED]>
Signed-off-by: Wolfgang Denk <[EMAIL PROTECTED]>
---

With some (more recent) compiler versions there are problems because
of the use of "long long" divisions in the U-Boot code. For ARM, this
requires the __udivdi3 GCC library function, which currently is not
present in lib_arm. This function was present in older 2.6 kernels,
but at some point it was removed from here, with suggestion to use
do_div() instead. In U-boot, the do_div() function is available, too,
so this patch generally does the replacement of the "long long"
divisions to do_div() to avoid the aforementions issues.

 board/integratorcp/integratorcp.c |7 ++-
 board/trab/tsc2000.c  |   10 ++
 cpu/arm1176/s3c64xx/interrupts.c  |5 -
 3 files changed, 16 insertions(+), 6 deletions(-)

diff --git a/board/integratorcp/integratorcp.c 
b/board/integratorcp/integratorcp.c
index d6d6e13..220513f 100644
--- a/board/integratorcp/integratorcp.c
+++ b/board/integratorcp/integratorcp.c
@@ -34,6 +34,7 @@
  */
 
 #include 
+#include 
 
 DECLARE_GLOBAL_DATA_PTR;
 
@@ -244,7 +245,11 @@ ulong get_timer_masked (void)
total_count += lastdec - now;
}
lastdec   = now;
-   timestamp = (ulong)(total_count/div_timer);
+
+   /* Reuse "now" */
+   now = total_count;
+   do_div(now, div_timer);
+   timestamp = now;
 
return timestamp;
 }
diff --git a/board/trab/tsc2000.c b/board/trab/tsc2000.c
index 382a85b..f13a5a9 100644
--- a/board/trab/tsc2000.c
+++ b/board/trab/tsc2000.c
@@ -27,6 +27,7 @@
 
 #include 
 #include 
+#include 
 #include "tsc2000.h"
 
 #include "Pt1000_temp_data.h"
@@ -332,6 +333,7 @@ void tsc2000_reg_init (void)
 int tsc2000_interpolate(long value, long data[][2], long *result)
 {
int i;
+   unsigned long long val;
 
/* the data is sorted and the first element is upper
 * limit so we can easily check for out-of-band values
@@ -347,10 +349,10 @@ int tsc2000_interpolate(long value, long data[][2], long 
*result)
   result in 'long long'.
*/
 
-   *result = data[i-1][1] +
-   ((unsigned long long)(data[i][1] - data[i-1][1])
-* (unsigned long long)(value - data[i-1][0]))
-   / (data[i][0] - data[i-1][0]);
+   val = ((unsigned long long)(data[i][1] - data[i-1][1])
+  * (unsigned long long)(value - data[i-1][0]));
+   do_div(val, (data[i][0] - data[i-1][0]));
+   *result = data[i-1][1] + val;
 
return 0;
 }
diff --git a/cpu/arm1176/s3c64xx/interrupts.c b/cpu/arm1176/s3c64xx/interrupts.c
index 8356ae4..e34369f 100644
--- a/cpu/arm1176/s3c64xx/interrupts.c
+++ b/cpu/arm1176/s3c64xx/interrupts.c
@@ -41,6 +41,7 @@
 #include 
 #include 
 #include 
+#include 
 
 static ulong timer_load_val;
 
@@ -148,7 +149,9 @@ void reset_timer(void)
 
 ulong get_timer_masked(void)
 {
-   return get_ticks() / (timer_load_val / (100 * CFG_HZ));
+   unsigned long long res = get_ticks();
+   do_div (res, (timer_load_val / (100 * CFG_HZ)));
+   return res;
 }
 
 ulong get_timer(ulong base)
-- 
1.5.4.2

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


Re: [U-Boot] [PATCH] ml507: fix out of tree build problem

2008-09-08 Thread Wolfgang Denk
Dear Ricardo,

In message <[EMAIL PROTECTED]> you wrote:
> 
>   It has change, there is no more copies. Instead of that I used the
> method that you sugggested for re-using linking scripts. If you keep
> you patch you will have a conflict merging.

So I will have to resolve these. I need a fix that cleans the build
now.

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: [EMAIL PROTECTED]
Peace was the way.
-- Kirk, "The City on the Edge of Forever", stardate unknown
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH] ARM: Use do_div() instead of division for "long long"

2008-09-08 Thread Jean-Christophe PLAGNIOL-VILLARD
On 05:34 Tue 09 Sep , Gururaja Hebbar K R wrote:
>  Hmm,
> 
> Interestingly i had sent a patch for the same for both
> integrator[ap/cp].
> http://article.gmane.org/gmane.comp.boot-loaders.u-boot/46044. 
> 

mail tag as SPAM in my mail box as a lot of your mail.

I'll take a look why.

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


Re: [U-Boot] [PATCH] ARM: Use do_div() instead of division for "long long"

2008-09-08 Thread Gururaja Hebbar K R
 Hmm,

Interestingly i had sent a patch for the same for both
integrator[ap/cp].
http://article.gmane.org/gmane.comp.boot-loaders.u-boot/46044. 

i had sent it to Jean-Christophe PLAGNIOL-VILLARD & Peter Pearse & also
to U-Boot user list. 

Don't know y it didn't reach there.

Regards
Gururaja

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


Re: [U-Boot] [PATCH] ml507: fix out of tree build problem

2008-09-08 Thread Ricardo
Hello again

  It has change, there is no more copies. Instead of that I used the
method that you sugggested for re-using linking scripts. If you keep
you patch you will have a conflict merging.

Regards & Thanks


On Mon, Sep 8, 2008 at 19:19, Wolfgang Denk <[EMAIL PROTECTED]> wrote:
> Dear Ricardo,
>
> In message <[EMAIL PROTECTED]> you wrote:
>>
>>   This problem is solved in "Unification of virtex5 pp440 boards",
>> which is ready to be merged in mainline (Today's pullgit by Stefan),
>> Please revert this patch in order to have less problems merging
>> Stefan's ppc4xx branch.
>
> If your fix is the same, then git will sort it out with no problem.
>
> 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: [EMAIL PROTECTED]
> Shakespeare's Law of Prototyping: (Hamlet III, iv, 156-160)
>O, throw away the worser part of it,
>And live the purer with the other half.
>



-- 
Ricardo Ribalda
http://www.eps.uam.es/~rribalda/
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


[U-Boot] [PATCH] disk-on-chip: remove duplicate doc_probe declaration

2008-09-08 Thread Jean-Christophe PLAGNIOL-VILLARD
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <[EMAIL PROTECTED]>
---
 board/atc/atc.c|1 -
 board/cpu86/cpu86.c|1 -
 board/cpu87/cpu87.c|1 -
 board/gen860t/gen860t.c|2 --
 board/mcc200/mcc200.c  |1 -
 board/mpl/common/common_util.c |1 -
 board/pm520/pm520.c|1 -
 board/pm826/pm826.c|1 -
 board/pm828/pm828.c|1 -
 board/svm_sc8xx/svm_sc8xx.c|1 -
 10 files changed, 0 insertions(+), 11 deletions(-)

diff --git a/board/atc/atc.c b/board/atc/atc.c
index 79527f4..b627c1c 100644
--- a/board/atc/atc.c
+++ b/board/atc/atc.c
@@ -380,7 +380,6 @@ phys_size_t initdram (int board_type)
 }
 
 #if defined(CONFIG_CMD_DOC)
-extern void doc_probe (ulong physadr);
 void doc_init (void)
 {
doc_probe (CFG_DOC_BASE);
diff --git a/board/cpu86/cpu86.c b/board/cpu86/cpu86.c
index 9e76c72..23ec283 100644
--- a/board/cpu86/cpu86.c
+++ b/board/cpu86/cpu86.c
@@ -313,7 +313,6 @@ phys_size_t initdram (int board_type)
 }
 
 #if defined(CONFIG_CMD_DOC)
-extern void doc_probe (ulong physadr);
 void doc_init (void)
 {
doc_probe (CFG_DOC_BASE);
diff --git a/board/cpu87/cpu87.c b/board/cpu87/cpu87.c
index f5a5de5..bb8be6b 100644
--- a/board/cpu87/cpu87.c
+++ b/board/cpu87/cpu87.c
@@ -322,7 +322,6 @@ phys_size_t initdram (int board_type)
 }
 
 #if defined(CONFIG_CMD_DOC)
-extern void doc_probe (ulong physadr);
 void doc_init (void)
 {
doc_probe (CFG_DOC_BASE);
diff --git a/board/gen860t/gen860t.c b/board/gen860t/gen860t.c
index e3d0e43..5c497b6 100644
--- a/board/gen860t/gen860t.c
+++ b/board/gen860t/gen860t.c
@@ -223,8 +223,6 @@ phys_size_t initdram (int board_type)
  * The DOC lives in the CS2* space
  */
 #if defined(CONFIG_CMD_DOC)
-extern void doc_probe (ulong physadr);
-
 void doc_init (void)
 {
printf ("Probing at 0x%.8x: ", DOC_BASE);
diff --git a/board/mcc200/mcc200.c b/board/mcc200/mcc200.c
index 8eb0649..65b8184 100644
--- a/board/mcc200/mcc200.c
+++ b/board/mcc200/mcc200.c
@@ -323,7 +323,6 @@ void ide_set_reset (int idereset)
 #endif
 
 #if defined(CONFIG_CMD_DOC)
-extern void doc_probe (ulong physadr);
 void doc_init (void)
 {
doc_probe (CFG_DOC_BASE);
diff --git a/board/mpl/common/common_util.c b/board/mpl/common/common_util.c
index 88b864c..8454420 100644
--- a/board/mpl/common/common_util.c
+++ b/board/mpl/common/common_util.c
@@ -565,7 +565,6 @@ int do_mplcommon(cmd_tbl_t *cmdtp, int flag, int argc, char 
*argv[])
 
 
 #if defined(CONFIG_CMD_DOC)
-extern void doc_probe(ulong physadr);
 void doc_init (void)
 {
   doc_probe(MULTI_PURPOSE_SOCKET_ADDR);
diff --git a/board/pm520/pm520.c b/board/pm520/pm520.c
index 83d9bcd..e00e2d8 100644
--- a/board/pm520/pm520.c
+++ b/board/pm520/pm520.c
@@ -315,7 +315,6 @@ void ide_set_reset (int idereset)
 #endif
 
 #if defined(CONFIG_CMD_DOC)
-extern void doc_probe (ulong physadr);
 void doc_init (void)
 {
doc_probe (CFG_DOC_BASE);
diff --git a/board/pm826/pm826.c b/board/pm826/pm826.c
index 7ee3ab6..58914b4 100644
--- a/board/pm826/pm826.c
+++ b/board/pm826/pm826.c
@@ -311,7 +311,6 @@ phys_size_t initdram (int board_type)
 }
 
 #if defined(CONFIG_CMD_DOC)
-extern void doc_probe (ulong physadr);
 void doc_init (void)
 {
doc_probe (CFG_DOC_BASE);
diff --git a/board/pm828/pm828.c b/board/pm828/pm828.c
index 6038e97..e1a7d57 100644
--- a/board/pm828/pm828.c
+++ b/board/pm828/pm828.c
@@ -344,7 +344,6 @@ phys_size_t initdram (int board_type)
 }
 
 #if defined(CONFIG_CMD_DOC)
-extern void doc_probe (ulong physadr);
 void doc_init (void)
 {
doc_probe (CFG_DOC_BASE);
diff --git a/board/svm_sc8xx/svm_sc8xx.c b/board/svm_sc8xx/svm_sc8xx.c
index 06fb18b..48e05b8 100644
--- a/board/svm_sc8xx/svm_sc8xx.c
+++ b/board/svm_sc8xx/svm_sc8xx.c
@@ -154,7 +154,6 @@ phys_size_t initdram (int board_type)
 }
 
 #if defined(CONFIG_CMD_DOC)
-extern void doc_probe (ulong physadr);
 void doc_init (void)
 {
doc_probe (CFG_DOC_BASE);
-- 
1.5.6.5

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


[U-Boot] [PATCH] Support multiple SGMII/TBI interfaces for TSEC ethernet

2008-09-08 Thread Peter Tyser
The original code only supported using 1 TSEC port in SGMII mode using an
internal TBI PHY.  Additionally, the TBI internal PHY was being accessed
at the same register offset as the external PHY for the given TSEC port.
This hardwiring of the TBI PHY register address based on external PHY
address will break in many hardware configurations.

Signed-off-by: Peter Tyser <[EMAIL PROTECTED]>
---

The above limitations were noticed on an mpc8572-based board with 2 sgmii
interfaces with external PHYs.  Both external PHYs are connected to the
MDIO interface of TSEC1 which caused TSEC2 to be non functional since
writes to TSEC2's TBI PHY were actually going to TSEC1's TBI PHY.

Due to a hardware limitations I've only been able to test TSEC2's
functionality for what its worth.

 drivers/net/tsec.c |   15 +--
 include/tsec.h |2 +-
 2 files changed, 10 insertions(+), 7 deletions(-)

diff --git a/drivers/net/tsec.c b/drivers/net/tsec.c
index f81211a..38d4214 100644
--- a/drivers/net/tsec.c
+++ b/drivers/net/tsec.c
@@ -283,11 +283,13 @@ uint tsec_local_mdio_read(volatile tsec_t *phyregs, uint 
phyid, uint regnum)
 /* Configure the TBI for SGMII operation */
 static void tsec_configure_serdes(struct tsec_private *priv)
 {
-   tsec_local_mdio_write(priv->phyregs, CFG_TBIPA_VALUE, TBI_ANA,
+   /* Access TBI PHY registers at given TSEC register offset as opposed to 
the
+* offset used for external PHY/MII accesses */
+   tsec_local_mdio_write(priv->regs, priv->regs->tbipa, TBI_ANA,
TBIANA_SETTINGS);
-   tsec_local_mdio_write(priv->phyregs, CFG_TBIPA_VALUE, TBI_TBICON,
+   tsec_local_mdio_write(priv->regs, priv->regs->tbipa, TBI_TBICON,
TBICON_CLK_SELECT);
-   tsec_local_mdio_write(priv->phyregs, CFG_TBIPA_VALUE, TBI_CR,
+   tsec_local_mdio_write(priv->regs, priv->regs->tbipa, TBI_CR,
TBICR_SETTINGS);
 }
 
@@ -301,11 +303,12 @@ static int init_phy(struct eth_device *dev)
struct phy_info *curphy;
volatile tsec_t *phyregs = priv->phyregs;
volatile tsec_t *regs = priv->regs;
+   static int tbi_offset = 0;
 
-   /* Assign a Physical address to the TBI */
-   regs->tbipa = CFG_TBIPA_VALUE;
-   phyregs->tbipa = CFG_TBIPA_VALUE;
+   /* Assign a unique physical address to the internal TBI PHY */
+   regs->tbipa = CFG_TBIPA_VALUE + tbi_offset;
asm("sync");
+   tbi_offset++;
 
/* Reset MII (due to new addresses) */
priv->phyregs->miimcfg = MIIMCFG_RESET;
diff --git a/include/tsec.h b/include/tsec.h
index 2db4deb..69f068e 100644
--- a/include/tsec.h
+++ b/include/tsec.h
@@ -110,7 +110,7 @@
 #define miim_read -1
 
 #ifndef CFG_TBIPA_VALUE
-#define CFG_TBIPA_VALUE0x1f
+#define CFG_TBIPA_VALUE0x10
 #endif
 #define MIIMCFG_INIT_VALUE 0x0003
 #define MIIMCFG_RESET  0x8000
-- 
1.5.4.3

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


[U-Boot] [PATCH] onenand_uboot: fix warning: 'struct mtd_oob_ops' declared inside parameter list

2008-09-08 Thread Jean-Christophe PLAGNIOL-VILLARD
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <[EMAIL PROTECTED]>
---
 include/onenand_uboot.h |1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/include/onenand_uboot.h b/include/onenand_uboot.h
index 6605e4f..e960257 100644
--- a/include/onenand_uboot.h
+++ b/include/onenand_uboot.h
@@ -15,6 +15,7 @@
 #define __UBOOT_ONENAND_H
 
 #include 
+#include 
 
 struct mtd_info;
 struct erase_info;
-- 
1.5.6.5

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


[U-Boot] [PATCH] rs5c372: fix rtc_set prototype

2008-09-08 Thread Jean-Christophe PLAGNIOL-VILLARD
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <[EMAIL PROTECTED]>
---
 drivers/rtc/rs5c372.c |3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)

diff --git a/drivers/rtc/rs5c372.c b/drivers/rtc/rs5c372.c
index 34514d0..82dd969 100644
--- a/drivers/rtc/rs5c372.c
+++ b/drivers/rtc/rs5c372.c
@@ -195,8 +195,7 @@ rtc_get (struct rtc_time *tmp)
 /*
  * Set the RTC
  */
-void
-rtc_set (struct rtc_time *tmp)
+int rtc_set (struct rtc_time *tmp)
 {
unsigned char buf[8], reg15;
int ret;
-- 
1.5.6.5

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


Re: [U-Boot] [PATCH] ml507: fix out of tree build problem

2008-09-08 Thread Wolfgang Denk
Dear Ricardo,

In message <[EMAIL PROTECTED]> you wrote:
> 
>   This problem is solved in "Unification of virtex5 pp440 boards",
> which is ready to be merged in mainline (Today's pullgit by Stefan),
> Please revert this patch in order to have less problems merging
> Stefan's ppc4xx branch.

If your fix is the same, then git will sort it out with no problem.

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: [EMAIL PROTECTED]
Shakespeare's Law of Prototyping: (Hamlet III, iv, 156-160)
O, throw away the worser part of it,
And live the purer with the other half.
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


[U-Boot] [PATCH] ARM: Use do_div() instead of division for "long long".

2008-09-08 Thread Wolfgang Denk
From: Sergei Poselenov <[EMAIL PROTECTED]>

Signed-off-by: Sergei Poselenov <[EMAIL PROTECTED]>
Signed-off-by: Wolfgang Denk <[EMAIL PROTECTED]>
---

With some (more recent) compiler versions there are problems because
of the use of "long long" divisions in the U-Boot code. For ARM, this
requires the __udivdi3 GCC library function, which currently is not
present in lib_arm. This function was present in older 2.6 kernels,
but at some point it was removed from here, with suggestion to use
do_div() instead. In U-boot, the do_div() function is available, too,
so this patch generally does the replacement of the "long long"
divisions to do_div() to avoid the aforementions issues.

 board/integratorcp/integratorcp.c |7 ++-
 board/trab/tsc2000.c  |   10 ++
 cpu/arm1176/s3c64xx/interrupts.c  |5 -
 cpu/arm946es/config.mk|7 +++
 cpu/arm_intcm/config.mk   |7 +++
 5 files changed, 30 insertions(+), 6 deletions(-)

diff --git a/board/integratorcp/integratorcp.c 
b/board/integratorcp/integratorcp.c
index d6d6e13..220513f 100644
--- a/board/integratorcp/integratorcp.c
+++ b/board/integratorcp/integratorcp.c
@@ -34,6 +34,7 @@
  */
 
 #include 
+#include 
 
 DECLARE_GLOBAL_DATA_PTR;
 
@@ -244,7 +245,11 @@ ulong get_timer_masked (void)
total_count += lastdec - now;
}
lastdec   = now;
-   timestamp = (ulong)(total_count/div_timer);
+
+   /* Reuse "now" */
+   now = total_count;
+   do_div(now, div_timer);
+   timestamp = now;
 
return timestamp;
 }
diff --git a/board/trab/tsc2000.c b/board/trab/tsc2000.c
index 382a85b..f13a5a9 100644
--- a/board/trab/tsc2000.c
+++ b/board/trab/tsc2000.c
@@ -27,6 +27,7 @@
 
 #include 
 #include 
+#include 
 #include "tsc2000.h"
 
 #include "Pt1000_temp_data.h"
@@ -332,6 +333,7 @@ void tsc2000_reg_init (void)
 int tsc2000_interpolate(long value, long data[][2], long *result)
 {
int i;
+   unsigned long long val;
 
/* the data is sorted and the first element is upper
 * limit so we can easily check for out-of-band values
@@ -347,10 +349,10 @@ int tsc2000_interpolate(long value, long data[][2], long 
*result)
   result in 'long long'.
*/
 
-   *result = data[i-1][1] +
-   ((unsigned long long)(data[i][1] - data[i-1][1])
-* (unsigned long long)(value - data[i-1][0]))
-   / (data[i][0] - data[i-1][0]);
+   val = ((unsigned long long)(data[i][1] - data[i-1][1])
+  * (unsigned long long)(value - data[i-1][0]));
+   do_div(val, (data[i][0] - data[i-1][0]));
+   *result = data[i-1][1] + val;
 
return 0;
 }
diff --git a/cpu/arm1176/s3c64xx/interrupts.c b/cpu/arm1176/s3c64xx/interrupts.c
index 8356ae4..e34369f 100644
--- a/cpu/arm1176/s3c64xx/interrupts.c
+++ b/cpu/arm1176/s3c64xx/interrupts.c
@@ -41,6 +41,7 @@
 #include 
 #include 
 #include 
+#include 
 
 static ulong timer_load_val;
 
@@ -148,7 +149,9 @@ void reset_timer(void)
 
 ulong get_timer_masked(void)
 {
-   return get_ticks() / (timer_load_val / (100 * CFG_HZ));
+   unsigned long long res = get_ticks();
+   do_div (res, (timer_load_val / (100 * CFG_HZ)));
+   return res;
 }
 
 ulong get_timer(ulong base)
diff --git a/cpu/arm946es/config.mk b/cpu/arm946es/config.mk
index 81ca288..f774c7e 100644
--- a/cpu/arm946es/config.mk
+++ b/cpu/arm946es/config.mk
@@ -25,3 +25,10 @@ PLATFORM_RELFLAGS += -fno-strict-aliasing  -fno-common 
-ffixed-r8 \
 -msoft-float
 
 PLATFORM_CPPFLAGS +=  -march=armv4
+# =
+#
+# Supply options according to compiler version
+#
+# =
+PLATFORM_CPPFLAGS +=$(call cc-option,-mapcs-32,-mabi=apcs-gnu)
+PLATFORM_RELFLAGS +=$(call cc-option,-mshort-load-bytes,$(call 
cc-option,-malignment-traps,))
diff --git a/cpu/arm_intcm/config.mk b/cpu/arm_intcm/config.mk
index 81ca288..f774c7e 100644
--- a/cpu/arm_intcm/config.mk
+++ b/cpu/arm_intcm/config.mk
@@ -25,3 +25,10 @@ PLATFORM_RELFLAGS += -fno-strict-aliasing  -fno-common 
-ffixed-r8 \
 -msoft-float
 
 PLATFORM_CPPFLAGS +=  -march=armv4
+# =
+#
+# Supply options according to compiler version
+#
+# =
+PLATFORM_CPPFLAGS +=$(call cc-option,-mapcs-32,-mabi=apcs-gnu)
+PLATFORM_RELFLAGS +=$(call cc-option,-mshort-load-bytes,$(call 
cc-option,-malignment-traps,))
-- 
1.5.4.2

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


Re: [U-Boot] [PATCH] ml507: fix out of tree build problem

2008-09-08 Thread Ricardo
Hello Wolfgang

  This problem is solved in "Unification of virtex5 pp440 boards",
which is ready to be merged in mainline (Today's pullgit by Stefan),
Please revert this patch in order to have less problems merging
Stefan's ppc4xx branch.

Regards


On Mon, Sep 8, 2008 at 16:50, Wolfgang Denk <[EMAIL PROTECTED]> wrote:
> Signed-off-by: Wolfgang Denk <[EMAIL PROTECTED]>
> ---
>  Makefile |4 ++--
>  1 files changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/Makefile b/Makefile
> index 8d82ef5..91f542e 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -1358,13 +1358,13 @@ ml300_config:   unconfig
>
>  ml507_flash_config:unconfig
>@mkdir -p $(obj)include $(obj)board/xilinx/ml507
> -   @cp $(obj)board/xilinx/ml507/u-boot-rom.lds  
> $(obj)board/xilinx/ml507/u-boot.lds
> +   @cp board/xilinx/ml507/u-boot-rom.lds  
> $(obj)board/xilinx/ml507/u-boot.lds
>@echo "TEXT_BASE = 0xFE36" > $(obj)board/xilinx/ml507/config.tmp
>@$(MKCONFIG) $(@:_flash_config=) ppc ppc4xx ml507 xilinx
>
>  ml507_config:  unconfig
>@mkdir -p $(obj)include $(obj)board/xilinx/ml507
> -   @cp $(obj)board/xilinx/ml507/u-boot-ram.lds  
> $(obj)board/xilinx/ml507/u-boot.lds
> +   @cp board/xilinx/ml507/u-boot-ram.lds  
> $(obj)board/xilinx/ml507/u-boot.lds
>@$(MKCONFIG) $(@:_config=) ppc ppc4xx ml507 xilinx
>
>  ocotea_config: unconfig
> --
> 1.5.6.1
>
> ___
> U-Boot mailing list
> U-Boot@lists.denx.de
> http://lists.denx.de/mailman/listinfo/u-boot
>



-- 
Ricardo Ribalda
http://www.eps.uam.es/~rribalda/
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


[U-Boot] [PATCH V2] qemu_mips: move env storage just after u-boot

2008-09-08 Thread Jean-Christophe PLAGNIOL-VILLARD
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <[EMAIL PROTECTED]>
---
Use CFG_MONITOR_LEN instead of value
 include/configs/qemu-mips.h |2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/include/configs/qemu-mips.h b/include/configs/qemu-mips.h
index faaa889..4f02425 100644
--- a/include/configs/qemu-mips.h
+++ b/include/configs/qemu-mips.h
@@ -150,7 +150,7 @@
 #define CFG_FLASH_USE_BUFFER_WRITE 1
 
 #define CONFIG_ENV_IS_IN_FLASH 1
-#define CONFIG_ENV_ADDR(CFG_FLASH_BASE + 0x4)
+#define CONFIG_ENV_ADDR(CFG_FLASH_BASE + CFG_MONITOR_LEN)
 
 /* Address and size of Primary Environment Sector */
 #define CONFIG_ENV_SIZE0x8000
-- 
1.5.6.5

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


Re: [U-Boot] FSBBP: uboot Programming on to the flash for MPC8548 for bootup

2008-09-08 Thread Andy Fleming
On Wed, Aug 27, 2008 at 12:16 AM, Ajeesh Kumar <[EMAIL PROTECTED]> wrote:
> hi sir/madam,
>
> I'm using a MPC8548E processor(power pc) also, i've interfaced a nor flash
> of 128 MB to the processor.
> i've read few documents and got to know that the uboot.bin should be
> programmed at 0xfff8.
> Also, when i saw the uboot.bin size it was 512K. so, it could fit between
> 0xfff8 - 0x.
> I 'M USING ABATRON BDI2000/BDI3000 FOR THIS.
> Now my question is:
> 1) If i'm making changes(addition/deletion of code) to the bootloader(uboot
> 1.2) and re compile it, i believe that the size of the uboot.bin will get
> changed i.e >/< 512K. NOW AT WHICH LOCATION I SHOULD FLASH THE
> UBOOT.BIN(SIZE IS NOT EQUAL TO 512)
> FOR Eg.  If my uboot.bin size is >512K ?


Well, it's not likely you will change the size of the binary.  You
see, the 512K size is a result of a quirk of the 85xx platform.  The
reset vector is at 0xfffc, but we define the base address to be
0xfff8, so we fill in the space between, and it's 512K.

The result is, you don't need to mind the size, unless you grow the
compiled output by over 200K.  Try to avoid that ;)

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


Re: [U-Boot] Please pull u-boot-mpc85xx.git

2008-09-08 Thread Andy Fleming
On Mon, Sep 1, 2008 at 8:57 AM, Detlev Zundel <[EMAIL PROTECTED]> wrote:

> That's really nice that we get the socrates board converted to the new
> style DDR, but I wonder why the other patches for socrates([1]-[3]) are
> becoming neglected pets of myself instead of moving on.  Can you please
> comment on them?
>

They're on my list, I'm just very behind.  They will be applied today
(barring any problems with the patches, themselves).
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] DM9161BMSR must be read twice ?

2008-09-08 Thread Andy Fleming
On Tue, Sep 2, 2008 at 2:37 PM, Nícolas Carneiro Lebedenco
<[EMAIL PROTECTED]> wrote:
> Hi,
>
> I'm developing a custom board based on the AT91RM9200dk. In u-boot prompt,
> every time a enter a network command such as tftp or ping I get a message
> like this:
>
> "MAC: error during MII initialization"
>
> Although the command actually seems to work I was a little concerned.
> After taking a look at cpu/arm920t/at91rm9200/ether.c and
> cpu/arm920t/at91rm9200/dm9161.c I realized the problem was at
> the function UCHAR dm9161_GetLinkSpeed (AT91PS_EMAC p_mac) in dm9161.c.
> Apparently, the link status bit at BMSR register is indicating link down even
> when it's not.

This is part of the 802.3 standard for PHYs.  If the link status bit
is 1, it means the link is up.  However, when the link goes down, the
status bit will stay 0 until read.  This allows temporary link drops
to be detected.  In practice, few drivers bother to take advantage of
this.  So if the first read indicates the link is down, it is
necessary to read the status again.

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


Re: [U-Boot] [PATCH 1/1] qemu_mips: update doc to generate and to use qemu flash, ide file

2008-09-08 Thread Wolfgang Denk
Dear Jean-Christophe PLAGNIOL-VILLARD,

In message <[EMAIL PROTECTED]> you wrote:

> Subject: [PATCH 1/1] 

Could you please omit the "1/1" part is this is a single patch that
does not belong to some series?

[On the other hand, I kind of feel that this *is* actually part of
your qemu series ?]

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: [EMAIL PROTECTED]
A fail-safe circuit will destroy others. -- Klipstein
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 1/1] qemu_mips: move env storage just after u-boot

2008-09-08 Thread Wolfgang Denk
Dear Jean-Christophe PLAGNIOL-VILLARD,

In message <[EMAIL PROTECTED]> you wrote:
> Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <[EMAIL PROTECTED]>
> ---
>  include/configs/qemu-mips.h |2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
> 
> diff --git a/include/configs/qemu-mips.h b/include/configs/qemu-mips.h
> index faaa889..e46976d 100644
> --- a/include/configs/qemu-mips.h
> +++ b/include/configs/qemu-mips.h
> @@ -150,7 +150,7 @@
>  #define CFG_FLASH_USE_BUFFER_WRITE   1
>  
>  #define CONFIG_ENV_IS_IN_FLASH   1
> -#define CONFIG_ENV_ADDR  (CFG_FLASH_BASE + 0x4)
> +#define CONFIG_ENV_ADDR  (CFG_FLASH_BASE + 0x3)

Wouldn't it make sense to use something like

(CFG_FLASH_BASE + CFG_MONITOR_LEN)

instead?

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: [EMAIL PROTECTED]
An optimist believes we live in the best world possible; a  pessimist
fears this is true.
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH] add reboot as a synonym for reset

2008-09-08 Thread Wolfgang Denk
Dear Andrew,

In message <[EMAIL PROTECTED]> you wrote:
> 
> I'm fine with your decision, it was just a convenience for me, so I'll
> keep it in my local tree, but I would ask in the context of u-boot
> where there are essentially no 'services' or state that needs to be
> saved, what's the real difference?

For U-Boot,it makes no difference. The problem is  with  Linux,  when
you get used to using an incorrect or at least imprecise terminology.
When  I ask: "Is it OK to reset the server?" that is pretty different
from "Is it OK to reboot the server?".

My motivation was purely educational :-)

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: [EMAIL PROTECTED]
...when fits of creativity run strong, more than  one  programmer  or
writer  has  been  known to abandon the desktop for the more spacious
floor. - Fred Brooks, Jr.
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] MPC85xx unapplied patches

2008-09-08 Thread Andy Fleming
On Sat, Sep 6, 2008 at 6:38 PM, Wolfgang Denk <[EMAIL PROTECTED]> wrote:
> Dear Andy,
>
> I have a couple of unapplied patches in my list which seem to fall
> into your area of responsibility. Can you please have a look at
> these:

Yes, I'm currently trying to churn through my u-boot backlog (OLS,
vacation, and an "unexpected" project deadline all conspired against
me this last month).  I will get these in today.

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


Re: [U-Boot] [PATCH V2] qemu_mips: Update linux bootm to support dynamic cmdline

2008-09-08 Thread Jean-Christophe PLAGNIOL-VILLARD
On 22:26 Mon 08 Sep , Wolfgang Denk wrote:
> Dear Jean-Christophe PLAGNIOL-VILLARD,
> 
> In message <[EMAIL PROTECTED]> you wrote:
> > Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <[EMAIL PROTECTED]>
> > ---
> > Fix e-mail in copyright
> >  lib_mips/Makefile  |4 ++
> >  lib_mips/bootm_qemu_mips.c |   76 
> > 
> 
> Why do we need a completely separate implementation for the bootm
> command? If this is a true emulation, using the same kernel interface,
> we should also be able to use the exactly same bootm code?

Unfortunaltely not, the qemu_mips have it's own implementation.

To simplify it, I've prefer to sepate them.

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


[U-Boot] [PATCH] ml507: fix out of tree build problem

2008-09-08 Thread Wolfgang Denk
Signed-off-by: Wolfgang Denk <[EMAIL PROTECTED]>
---
 Makefile |4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/Makefile b/Makefile
index 8d82ef5..91f542e 100644
--- a/Makefile
+++ b/Makefile
@@ -1358,13 +1358,13 @@ ml300_config:   unconfig
 
 ml507_flash_config:unconfig
@mkdir -p $(obj)include $(obj)board/xilinx/ml507
-   @cp $(obj)board/xilinx/ml507/u-boot-rom.lds  
$(obj)board/xilinx/ml507/u-boot.lds
+   @cp board/xilinx/ml507/u-boot-rom.lds  
$(obj)board/xilinx/ml507/u-boot.lds
@echo "TEXT_BASE = 0xFE36" > $(obj)board/xilinx/ml507/config.tmp
@$(MKCONFIG) $(@:_flash_config=) ppc ppc4xx ml507 xilinx
 
 ml507_config:  unconfig
@mkdir -p $(obj)include $(obj)board/xilinx/ml507
-   @cp $(obj)board/xilinx/ml507/u-boot-ram.lds  
$(obj)board/xilinx/ml507/u-boot.lds
+   @cp board/xilinx/ml507/u-boot-ram.lds  
$(obj)board/xilinx/ml507/u-boot.lds
@$(MKCONFIG) $(@:_config=) ppc ppc4xx ml507 xilinx
 
 ocotea_config: unconfig
-- 
1.5.6.1

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


[U-Boot] [PATCH] common/cmd_bootm.c: fix printf() format warnings

2008-09-08 Thread Wolfgang Denk
Signed-off-by: Wolfgang Denk <[EMAIL PROTECTED]>
---
 common/cmd_bootm.c |4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/common/cmd_bootm.c b/common/cmd_bootm.c
index 751f5b9..8dbab02 100644
--- a/common/cmd_bootm.c
+++ b/common/cmd_bootm.c
@@ -337,13 +337,13 @@ static int bootm_load_os(image_info_t os, ulong 
*load_end, int boot_progress)
return BOOTM_ERR_UNIMPLEMENTED;
}
puts ("OK\n");
-   debug ("   kernel loaded at 0x%08lx, end = 0x%08lx\n", load, load_end);
+   debug ("   kernel loaded at 0x%08lx, end = 0x%8p\n", load, load_end);
if (boot_progress)
show_boot_progress (7);
 
if ((load < blob_end) && (*load_end > blob_start)) {
debug ("images.os.start = 0x%lX, images.os.end = 0x%lx\n", 
blob_start, blob_end);
-   debug ("images.os.load = 0x%lx, load_end = 0x%lx\n", load, 
load_end);
+   debug ("images.os.load = 0x%lx, load_end = 0x%p\n", load, 
load_end);
 
return BOOTM_ERR_OVERLAP;
}
-- 
1.5.6.1

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


[U-Boot] [PATCH] mk48t59: fix compile problem introduced by commit d1e23194

2008-09-08 Thread Wolfgang Denk
Signed-off-by: Wolfgang Denk <[EMAIL PROTECTED]>
---
 drivers/rtc/mk48t59.c |2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/rtc/mk48t59.c b/drivers/rtc/mk48t59.c
index b6c234e..dabf322 100644
--- a/drivers/rtc/mk48t59.c
+++ b/drivers/rtc/mk48t59.c
@@ -227,7 +227,7 @@ void rtc_reset (void)
rtc_write(RTC_CONTROLB, control_b);
 }
 
-int rtc_set_watchdog(short multi, short res)
+void rtc_set_watchdog(short multi, short res)
 {
uchar wd_value;
 
-- 
1.5.6.1

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


[U-Boot] [PATCH] BMW, PCIPPC2, PCIPPC6, RBC82: fix compile warnings

2008-09-08 Thread Wolfgang Denk
missing doc_probe() prototype.

Signed-off-by: Wolfgang Denk <[EMAIL PROTECTED]>
---
 include/common.h |3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/include/common.h b/include/common.h
index a394988..33c6e10 100644
--- a/include/common.h
+++ b/include/common.h
@@ -236,6 +236,9 @@ int autoscript (ulong addr, const char *fit_uname);
 
 extern ulong load_addr;/* Default Load Address */
 
+/* common/cmd_doc.c */
+void   doc_probe(unsigned long physadr);
+
 /* common/cmd_nvedit.c */
 intenv_init (void);
 void   env_relocate (void);
-- 
1.5.6.1

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


[U-Boot] [PATCH 1/1] qemu_mips: update doc to generate and to use qemu flash, ide file

2008-09-08 Thread Jean-Christophe PLAGNIOL-VILLARD
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <[EMAIL PROTECTED]>
---
 doc/README.qemu_mips |   67 +++--
 1 files changed, 58 insertions(+), 9 deletions(-)

diff --git a/doc/README.qemu_mips b/doc/README.qemu_mips
index 2a6f1cf..13c98b9 100644
--- a/doc/README.qemu_mips
+++ b/doc/README.qemu_mips
@@ -17,7 +17,28 @@ create image:
 start it:
 # qemu-system-mips -M mips -pflash flash -monitor null -nographic
 
-Ide Disk
+2) Download kernel + initrd
+
+On ftp://ftp.denx.de/pub/contrib/Jean-Christophe_Plagniol-Villard/qemu_mips/
+you can downland
+
+#config to build the kernel
+qemu_mips_defconfig
+#patch to fix mips interupt init on 2.6.24.y kernel
+qemu_mips_kernel.patch
+initrd.gz
+vmlinux
+vmlinux.bin
+System.map
+
+4) Generate uImage
+
+# tools/mkimage -A mips -O linux -T kernel -C gzip -a 0x8001 -e 0x80245650 
-n "Linux 2.6.24.y" -d vmlinux.bin.gz uImage
+
+5) Copy uImage to Flash
+# dd if=uImage bs=1k conv=notrunc seek=224 of=flash
+
+6) Generate Ide Disk
 
 # dd of=ide bs=1k cout=100k if=/dev/zero
 
@@ -30,14 +51,12 @@ unit: sectors
  ide3 : start=64260, size=  4128705, Id=83
  ide4 : start=0, size=0, Id= 0
 
-# Generate uImage
-# tools/mkimage -A mips -O linux -T kernel -C gzip -a 0x8001 -e 0x80245650 
-n "Linux 2.6.24.y" -d vmlinux.bin.gz uImage
-# Copy to Flash
-# dd if=uImage bs=1k conv=notrunc seek=224 of=flash
-# Copy to ide
+7) Copy to ide
+
 # dd if=uImage bs=512 conv=notrunc seek=63 of=ide
 
-# Generate ext2 on part 2
+8) Generate ext2 on part 2 on Copy uImage and initrd.gz
+
 # Attached as loop device ide offset = 32130 * 512
 # losetup -o 16450560 -f ide
 # Format as ext2 ( arg2 : nb blocks)
@@ -45,10 +64,40 @@ unit: sectors
 # losetup -d /dev/loop0
 # Mount and copy uImage and initrd.gz to it
 # mount -o loop,offset=16450560 -t ext2 ide /mnt
+# mkdir /mnt/boot
+# cp {initrd.gz,uImage} /mnt/boot/
 # Umount it
 # umount /mnt
 
-Now you can boot from flash, ide, ide+ext2 and tfp
+9) Set Environment
+
+setenv rd_start 0x8080
+setenv rd_size 2663940
+setenv kernel BFC38000
+setenv oad_addr 8050
+setenv load_addr2 80F0
+setenv kernel_flash BFC38000
+setenv load_addr_hello 8020
+setenv bootargs 'root=/dev/ram0 init=/bin/sh'
+setenv load_rd_ext2 'ide res; ext2load ide 0:2 ${rd_start} /boot/initrd.gz'
+setenv load_rd_tftp 'tftp ${rd_start} /initrd.gz'
+setenv load_kernel_hda 'ide res; diskboot ${load_addr} 0:2'
+setenv load_kernel_ext2 'ide res; ext2load ide 0:2 ${load_addr} /boot/uImage'
+setenv load_kernel_tftp 'tftp ${load_addr} /qemu_mips/uImage'
+setenv boot_ext2_ext2 'run load_rd_ext2; run load_kernel_ext2; run addmisc; 
bootm ${load_addr}'
+setenv boot_ext2_flash 'run load_rd_ext2; run addmisc; bootm ${kernel_flash}'
+setenv boot_ext2_hda 'run load_rd_ext2; run load_kernel_hda; run addmisc; 
bootm ${load_addr}'
+setenv boot_ext2_tftp 'run load_rd_ext2; run load_kernel_tftp; run addmisc; 
bootm ${load_addr}'
+setenv boot_tftp_hda 'run load_rd_tftp; run load_kernel_hda; run addmisc; 
bootm ${load_addr}'
+setenv boot_tftp_ext2 'run load_rd_tftp; run load_kernel_ext2; run addmisc; 
bootm ${load_addr}'
+setenv boot_tftp_flash 'run load_rd_tftp; run addmisc; bootm ${kernel_flash}'
+setenv boot_tftp_tftp 'run load_rd_tftp; run load_kernel_tftp; run addmisc; 
bootm ${load_addr}'
+setenv load_hello_tftp 'tftp ${load_addr_hello} /examples/hello_world.bin'
+setenv go_tftp 'run load_hello_tftp; go ${load_addr_hello}'
+setenv addmisc 'setenv bootargs ${bootargs} console=ttyS0,${baudrate} 
rd_start=${rd_start} rd_size=${rd_size} ethaddr=${ethaddr}'
+setenv bootcmd 'run boot_tftp_flash'
+
+10) Now you can boot from flash, ide, ide+ext2 and tfp
 
 # qemu-system-mips -M mips -pflash flash -monitor null -nographic -net nic 
-net user -tftp `pwd` -hda ide
 
@@ -64,7 +113,7 @@ in an other console you start gdb
 1) Debugging of U-Boot Before Relocation
 
 Before relocation, the addresses in the ELF file can be used without any 
problems
-buy connecting to the gdb server localhost:1234
+by connecting to the gdb server localhost:1234
 
 # mipsel-unknown-linux-gnu-gdb u-boot
 GNU gdb 6.6
-- 
1.5.6.5

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


[U-Boot] [PATCH 1/1] qemu_mips: move env storage just after u-boot

2008-09-08 Thread Jean-Christophe PLAGNIOL-VILLARD
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <[EMAIL PROTECTED]>
---
 include/configs/qemu-mips.h |2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/include/configs/qemu-mips.h b/include/configs/qemu-mips.h
index faaa889..e46976d 100644
--- a/include/configs/qemu-mips.h
+++ b/include/configs/qemu-mips.h
@@ -150,7 +150,7 @@
 #define CFG_FLASH_USE_BUFFER_WRITE 1
 
 #define CONFIG_ENV_IS_IN_FLASH 1
-#define CONFIG_ENV_ADDR(CFG_FLASH_BASE + 0x4)
+#define CONFIG_ENV_ADDR(CFG_FLASH_BASE + 0x3)
 
 /* Address and size of Primary Environment Sector */
 #define CONFIG_ENV_SIZE0x8000
-- 
1.5.6.5

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


Re: [U-Boot] [PATCH V2] qemu_mips: Update linux bootm to support dynamic cmdline

2008-09-08 Thread Wolfgang Denk
Dear Jean-Christophe PLAGNIOL-VILLARD,

In message <[EMAIL PROTECTED]> you wrote:
> Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <[EMAIL PROTECTED]>
> ---
> Fix e-mail in copyright
>  lib_mips/Makefile  |4 ++
>  lib_mips/bootm_qemu_mips.c |   76 
> 

Why do we need a completely separate implementation for the bootm
command? If this is a true emulation, using the same kernel interface,
we should also be able to use the exactly same bootm code?

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: [EMAIL PROTECTED]
Pray to God, but keep rowing to shore. - Russian Proverb
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH] add board support for virtex4fx12 minimodul

2008-09-08 Thread Ricardo
Hello again

  Some comments:

1) The board is manufactured by avnet, you must create it under the
folder boards/avnet/fx12mm
2) Try to unificate the fx12mm board under a more global board, like
the ml507 with is now in mainstream
3) Add your boad to the MAKEALL script and yourself to the MAINTAINERS
4) There are some object that are not used (or I don't see where are
they used) in your makefile. (../common/*)
5) You can obtain CONFIG_SYS_CLK_FREQ from the xparameters (it is
adjustable by the suer)

Best regards


On Mon, Sep 8, 2008 at 14:07, schardt <[EMAIL PROTECTED]> wrote:
> From: schardt <[EMAIL PROTECTED](none)>
>
> ---
>  Makefile  |3 +
>  board/xilinx/fx12mm/Makefile  |   63 
>  board/xilinx/fx12mm/config.mk |   28 +++
>  board/xilinx/fx12mm/fx12mm.c  |   67 +
>  board/xilinx/fx12mm/init.S|   32 
>  board/xilinx/fx12mm/u-boot.lds|  149 
> +
>  board/xilinx/fx12mm/xparameters.h |   40 ++
>  include/configs/FX12MM.h  |  127 +++
>  8 files changed, 509 insertions(+), 0 deletions(-)
>  create mode 100644 board/xilinx/fx12mm/Makefile
>  create mode 100644 board/xilinx/fx12mm/config.mk
>  create mode 100644 board/xilinx/fx12mm/fx12mm.c
>  create mode 100644 board/xilinx/fx12mm/init.S
>  create mode 100644 board/xilinx/fx12mm/u-boot.lds
>  create mode 100644 board/xilinx/fx12mm/xparameters.h
>  create mode 100644 include/configs/FX12MM.h
>
> diff --git a/Makefile b/Makefile
> index 8d82ef5..1fc476d 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -1282,6 +1282,9 @@ ERIC_config:  unconfig
>  EXBITGEN_config:   unconfig
>@$(MKCONFIG) $(@:_config=) ppc ppc4xx exbitgen
>
> +FX12MM_config: unconfig
> +   @$(MKCONFIG) $(@:_config=) ppc ppc4xx fx12mm xilinx
> +
>  G2000_config:  unconfig
>@$(MKCONFIG) $(@:_config=) ppc ppc4xx g2000
>
> diff --git a/board/xilinx/fx12mm/Makefile b/board/xilinx/fx12mm/Makefile
> new file mode 100644
> index 000..aed47ef
> --- /dev/null
> +++ b/board/xilinx/fx12mm/Makefile
> @@ -0,0 +1,63 @@
> +#
> +# (C) Copyright 2000-2006
> +# Wolfgang Denk, DENX Software Engineering, [EMAIL PROTECTED]
> +#
> +# 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
> +ifneq ($(OBJTREE),$(SRCTREE))
> +$(shell mkdir -p $(obj)../common)
> +$(shell mkdir -p $(obj)../xilinx_iic)
> +endif
> +
> +INCS   := -I../common  -I../xilinx_iic
> +CFLAGS += $(INCS)
> +HOST_CFLAGS+= $(INCS)
> +
> +LIB= $(obj)lib$(BOARD).a
> +
> +COBJS  = $(BOARD).o \
> + ../common/xbasic_types.o ../common/xdma_channel.o \
> + ../common/xdma_channel_sg.o \
> + ../common/xversion.o \
> +
> +SOBJS   = init.o
> +
> +SRCS   := $(SOBJS:.o=.S) $(COBJS:.o=.c)
> +OBJS   := $(addprefix $(obj),$(COBJS))
> +SOBJS  := $(addprefix $(obj),$(SOBJS))
> +
> +$(LIB):$(OBJS) $(SOBJS)
> +   $(AR) $(ARFLAGS) $@ $^
> +
> +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/xilinx/fx12mm/config.mk b/board/xilinx/fx12mm/config.mk
> new file mode 100644
> index 000..69490fb
> --- /dev/null
> +++ b/board/xilinx/fx12mm/config.mk
> @@ -0,0 +1,28 @@
> +#
> +# (C) Copyright 2000
> +# Wolfgang Denk, DENX Software Engineering, [EMAIL PROTECTED]
> +#
> +# 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

[U-Boot] [PATCH v2] Add support for booting of INTEGRITY operating system uImages

2008-09-08 Thread Peter Tyser
Signed-off-by: Peter Tyser <[EMAIL PROTECTED]>
---

This should be applied after "[PATCH v2] Remove support for booting ARTOS 
images".

 README|5 ++-
 common/cmd_bootm.c|   38 +
 common/image.c|3 ++
 doc/uImage.FIT/source_file_format.txt |2 +-
 include/image.h   |1 +
 5 files changed, 46 insertions(+), 3 deletions(-)

diff --git a/README b/README
index d138c43..f44fb68 100644
--- a/README
+++ b/README
@@ -3030,8 +3030,9 @@ details; basically, the header defines the following 
image properties:
 
 * Target Operating System (Provisions for OpenBSD, NetBSD, FreeBSD,
   4.4BSD, Linux, SVR4, Esix, Solaris, Irix, SCO, Dell, NCR, VxWorks,
-  LynxOS, pSOS, QNX, RTEMS;
-  Currently supported: Linux, NetBSD, VxWorks, QNX, RTEMS, LynxOS).
+  LynxOS, pSOS, QNX, RTEMS, INTEGRITY;
+  Currently supported: Linux, NetBSD, VxWorks, QNX, RTEMS, LynxOS,
+  INTEGRITY).
 * Target CPU Architecture (Provisions for Alpha, ARM, AVR32, Intel x86,
   IA64, MIPS, NIOS, PowerPC, IBM S390, SuperH, Sparc, Sparc 64 Bit;
   Currently supported: ARM, AVR32, Intel x86, MIPS, NIOS, PowerPC).
diff --git a/common/cmd_bootm.c b/common/cmd_bootm.c
index 1880bc3..f7cbc9e 100644
--- a/common/cmd_bootm.c
+++ b/common/cmd_bootm.c
@@ -108,6 +108,9 @@ static boot_os_fn do_bootm_qnxelf;
 int do_bootvx (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[]);
 int do_bootelf (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[]);
 #endif
+#if defined(CONFIG_INTEGRITY)
+static boot_os_fn do_bootm_integrity;
+#endif
 
 ulong load_addr = CFG_LOAD_ADDR;   /* Default Load Address */
 static bootm_headers_t images; /* pointers to os/initrd/fdt images */
@@ -452,6 +455,11 @@ int do_bootm (cmd_tbl_t *cmdtp, int flag, int argc, char 
*argv[])
break;
 #endif
 
+#ifdef CONFIG_INTEGRITY
+   case IH_OS_INTEGRITY:
+   do_bootm_integrity (0, argc, argv, &images);
+   break;
+#endif
}
 
show_boot_progress (-9);
@@ -1144,3 +1152,33 @@ static int do_bootm_qnxelf(int flag, int argc, char 
*argv[],
return 1;
 }
 #endif
+
+#ifdef CONFIG_INTEGRITY
+static int do_bootm_integrity (int flag, int argc, char *argv[],
+  bootm_headers_t *images)
+{
+   void (*entry_point)(void);
+
+#if defined(CONFIG_FIT)
+   if (!images->legacy_hdr_valid) {
+   fit_unsupported_reset ("INTEGRITY");
+   return 1;
+   }
+#endif
+
+   entry_point = (void (*)(void))images->ep;
+
+   printf ("## Transferring control to INTEGRITY (at address %08lx) ...\n",
+   (ulong)entry_point);
+
+   show_boot_progress (15);
+
+   /*
+* INTEGRITY Parameters:
+*   None
+*/
+   (*entry_point)();
+
+   return 1;
+}
+#endif
diff --git a/common/image.c b/common/image.c
index 78efe2e..b011932 100644
--- a/common/image.c
+++ b/common/image.c
@@ -116,6 +116,9 @@ static table_entry_t uimage_os[] = {
{   IH_OS_QNX,  "qnx",  "QNX",  },
{   IH_OS_VXWORKS,  "vxworks",  "VxWorks",  },
 #endif
+#if defined(CONFIG_INTEGRITY) || defined(USE_HOSTCC)
+   {   IH_OS_INTEGRITY,"integrity","INTEGRITY",},
+#endif
 #ifdef USE_HOSTCC
{   IH_OS_4_4BSD,   "4_4bsd",   "4_4BSD",   },
{   IH_OS_DELL, "dell", "Dell", },
diff --git a/doc/uImage.FIT/source_file_format.txt 
b/doc/uImage.FIT/source_file_format.txt
index 1e30d22..157936e 100644
--- a/doc/uImage.FIT/source_file_format.txt
+++ b/doc/uImage.FIT/source_file_format.txt
@@ -169,7 +169,7 @@ the '/images' node should have the following layout:
   - os : OS name, mandatory for type="kernel", valid OS names are: "openbsd",
 "netbsd", "freebsd", "4_4bsd", "linux", "svr4", "esix", "solaris", "irix",
 "sco", "dell", "ncr", "lynxos", "vxworks", "psos", "qnx", "u_boot",
-"rtems", "unity".
+"rtems", "unity", "integrity".
   - arch : Architecture name, mandatory for types: "standalone", "kernel",
 "firmware", "ramdisk" and "fdt". Valid architecture names are: "alpha",
 "arm", "i386", "ia64", "mips", "mips64", "ppc", "s390", "sh", "sparc",
diff --git a/include/image.h b/include/image.h
index 9be806e..4654485 100644
--- a/include/image.h
+++ b/include/image.h
@@ -85,6 +85,7 @@
 #define IH_OS_RTEMS18  /* RTEMS*/
 #define IH_OS_ARTOS19  /* ARTOS*/
 #define IH_OS_UNITY20  /* Unity OS */
+#define IH_OS_INTEGRITY21  /* INTEGRITY*/
 
 /*
  * CPU Architecture Codes (supported by Linux)
-- 
1.5.4.3

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


Re: [U-Boot] [PATCH] add reboot as a synonym for reset

2008-09-08 Thread Andrew Dyer
On Mon, Sep 8, 2008 at 1:43 PM, Wolfgang Denk <[EMAIL PROTECTED]> wrote:
> Dear Andrew Dyer,
>
> In message <[EMAIL PROTECTED]> you wrote:
>> Add 'reboot' as a synonym for 'reset' at the u-boot command line.
>
> I tend to reject this change, because I think it is  actually  wrong.
> 'reboot'  and  'reset' are two different things - the former includes
> an ordered shut-down  of  running  services  while  the  latter  just
> performs what the name says: a hardware reset.

I'm fine with your decision, it was just a convenience for me, so I'll
keep it in my local tree, but I would ask in the context of u-boot
where there are essentially no 'services' or state that needs to be
saved, what's the real difference?

For a hypothetical do_reboot(), I suppose one could extract some of
the code of do_bootm() (shut off interrupts, usb, maybe caches) into a
common function, run an optional platform hook and then do_reset(),
but it doesn't seem like it would make much difference for the vast
majority of cases, once the hardware reset comes through.

-- 
Hardware, n.:
 The parts of a computer system that can be kicked.
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


[U-Boot] [PATCH V2] qemu_mips: Update linux bootm to support dynamic cmdline

2008-09-08 Thread Jean-Christophe PLAGNIOL-VILLARD
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <[EMAIL PROTECTED]>
---
Fix e-mail in copyright
 lib_mips/Makefile  |4 ++
 lib_mips/bootm_qemu_mips.c |   76 
 2 files changed, 80 insertions(+), 0 deletions(-)
 create mode 100644 lib_mips/bootm_qemu_mips.c

diff --git a/lib_mips/Makefile b/lib_mips/Makefile
index 8176437..7967e58 100644
--- a/lib_mips/Makefile
+++ b/lib_mips/Makefile
@@ -28,7 +28,11 @@ LIB  = $(obj)lib$(ARCH).a
 SOBJS-y+=
 
 COBJS-y+= board.o
+ifeq ($(CONFIG_QEMU_MIPS),y)
+COBJS-y+= bootm_qemu_mips.o
+else
 COBJS-y+= bootm.o
+endif
 COBJS-y+= time.o
 
 SRCS   := $(SOBJS-y:.o=.S) $(COBJS-y:.o=.c)
diff --git a/lib_mips/bootm_qemu_mips.c b/lib_mips/bootm_qemu_mips.c
new file mode 100644
index 000..cc70fa9
--- /dev/null
+++ b/lib_mips/bootm_qemu_mips.c
@@ -0,0 +1,76 @@
+/*
+ * (C) Copyright 2008
+ * Jean-Christophe PLAGNIOL-VILLARD <[EMAIL PROTECTED]>
+ *
+ * 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 
+#include 
+#include 
+#include 
+#include 
+
+DECLARE_GLOBAL_DATA_PTR;
+
+int do_bootm_linux(int flag, int argc, char *argv[], bootm_headers_t *images)
+{
+   void(*theKernel) (int, char **, char **, int *);
+   char*bootargs = getenv ("bootargs");
+   char*start;
+   uintlen;
+
+   /* find kernel entry point */
+   theKernel = (void (*)(int, char **, char **, int *))images->ep;
+
+   show_boot_progress (15);
+
+   debug ("## Transferring control to Linux (at address %08lx) ...\n",
+   (ulong) theKernel);
+
+   gd->bd->bi_boot_params = gd->bd->bi_memstart + (16 << 20) - 256;
+   debug ("%-12s= 0x%08lX\n", "boot_params", 
(ulong)gd->bd->bi_boot_params);
+
+   /* set Magic */
+   *(int32_t *)(gd->bd->bi_boot_params - 4) = 0x12345678;
+   /* set ram_size */
+   *(int32_t *)(gd->bd->bi_boot_params - 8) = gd->ram_size;
+
+   start = (char*)gd->bd->bi_boot_params;
+
+   len = strlen(bootargs);
+
+   strncpy(start, bootargs, len + 1);
+
+   start += len;
+
+   len = images->rd_end - images->rd_start;
+   if (len > 0) {
+   start += sprintf(start," rd_start=0x%08X rd_size=0x%0X",
+   (uint) UNCACHED_SDRAM (images->rd_start),
+   (uint) len);
+   }
+
+   /* we assume that the kernel is in place */
+   printf ("\nStarting kernel ...\n\n");
+
+   theKernel (0, NULL, NULL, 0);
+   /* does not return */
+   return 1;
+}
-- 
1.5.6.5

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


Re: [U-Boot] [PATCH] Add MTD core & partition

2008-09-08 Thread Scott Wood
On Fri, Aug 29, 2008 at 05:13:23PM +0900, Kyungmin Park wrote:
> It's preparation for UBI codes.
> UBI uses partition and get & put mtd devices

Please import the latest MTD code; there have been several cleanups/fixes
in mtdpart.c recently (in particular, the patches from Atsushi Nemoto
dated Jul 19).

As for the #if 0 blocks, I'd rather leave them out entirely -- I think
the increased readability would be worth the occasional extra merge
conflict when importing new upstream code.

> Signed-off-by: Kyungmin Park <[EMAIL PROTECTED]>
> ---
> diff --git a/drivers/mtd/Makefile b/drivers/mtd/Makefile
> index 6538f7a..d225a68 100644
> --- a/drivers/mtd/Makefile
> +++ b/drivers/mtd/Makefile
> @@ -25,6 +25,7 @@ include $(TOPDIR)/config.mk
>  
>  LIB  := $(obj)libmtd.a
>  
> +COBJS-$(CONFIG_CMD_UBI) += mtdcore.o mtdpart.o

Is UBI the only case where we want the generic MTD infrastructure?  Maybe
we can remove some duplication and/or add partition support elsewhere.

>  COBJS-$(CONFIG_HAS_DATAFLASH) += at45.o
>  COBJS-$(CONFIG_FLASH_CFI_DRIVER) += cfi_flash.o
>  COBJS-$(CONFIG_HAS_DATAFLASH) += dataflash.o
> diff --git a/drivers/mtd/mtdcore.c b/drivers/mtd/mtdcore.c
> new file mode 100644
> index 000..2fb6099
> --- /dev/null
> +++ b/drivers/mtd/mtdcore.c
> @@ -0,0 +1,142 @@
> +/*
> + * $Id: mtdcore.c,v 1.47 2005/11/07 11:14:20 gleixner Exp $
> + *
> + * Core registration and callback routines for MTD
> + * drivers and users.
> + */
> +
> +#include 
> +#include 
> +#include 

I don't see mtd_uboot.h or ubi_uboot.h in the current tree, nor are they
added by this patch.

Is this patch supposed to depend on the giant UBI patch (I'd think not,
since the changelog says it's preparing for UBI)?

> +/**
> + *  del_mtd_device - unregister an MTD device
> + *  @mtd: pointer to MTD device info structure
> + *
> + *  Remove a device from the list of MTD devices present in the system,
> + *  and notify each currently active MTD 'user' of its departure.
> + *  Returns zero on success or 1 on failure, which currently will happen
> + *  if the requested device does not appear to be present in the list.
> + */
> +int del_mtd_device (struct mtd_info *mtd)
> +{
> + int ret;
> +
> + if (mtd_table[mtd->index] != mtd) {
> + ret = -ENODEV;
> + } else if (mtd->usecount) {
> + printk(KERN_NOTICE "Removing MTD device #%d (%s) with use count 
> %d\n",
> + mtd->index, mtd->name, mtd->usecount);
> + ret = -EBUSY;
> + } else {
> + /* No need to get a refcount on the module containing
> +  *the notifier, since we hold the 
> mtd_table_mutex */
> + mtd_table[mtd->index] = NULL;
> +
> + ret = 0;
> + }
> +
> + return ret;
> +}

We should remove all the refcounting/removal stuff -- it's just bloat in
u-boot.

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


[U-Boot] [PATCH 1/1] mips/bootm: Fix typo in commit c4f9419c, "initrd_start" replaced by "images->rd_start"

2008-09-08 Thread Jean-Christophe PLAGNIOL-VILLARD
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <[EMAIL PROTECTED]>
---
 lib_mips/bootm.c |2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/lib_mips/bootm.c b/lib_mips/bootm.c
index c1bf21e..dced28c 100644
--- a/lib_mips/bootm.c
+++ b/lib_mips/bootm.c
@@ -73,7 +73,7 @@ int do_bootm_linux(int flag, int argc, char *argv[], 
bootm_headers_t *images)
linux_env_set ("memsize", env_buf);
 
sprintf (env_buf, "0x%08X", (uint) UNCACHED_SDRAM (images->rd_start));
-   linux_env_set ("images->rd_start", env_buf);
+   linux_env_set ("initrd_start", env_buf);
 
sprintf (env_buf, "0x%X", (uint) (images->rd_end - images->rd_start));
linux_env_set ("initrd_size", env_buf);
-- 
1.5.6.5

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


[U-Boot] [PATCH] qemu_mips: Update linux bootm to support dynamic cmdline

2008-09-08 Thread Jean-Christophe PLAGNIOL-VILLARD
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <[EMAIL PROTECTED]>
---
 lib_mips/Makefile  |4 ++
 lib_mips/bootm_qemu_mips.c |   76 
 2 files changed, 80 insertions(+), 0 deletions(-)
 create mode 100644 lib_mips/bootm_qemu_mips.c

diff --git a/lib_mips/Makefile b/lib_mips/Makefile
index 8176437..7967e58 100644
--- a/lib_mips/Makefile
+++ b/lib_mips/Makefile
@@ -28,7 +28,11 @@ LIB  = $(obj)lib$(ARCH).a
 SOBJS-y+=
 
 COBJS-y+= board.o
+ifeq ($(CONFIG_QEMU_MIPS),y)
+COBJS-y+= bootm_qemu_mips.o
+else
 COBJS-y+= bootm.o
+endif
 COBJS-y+= time.o
 
 SRCS   := $(SOBJS-y:.o=.S) $(COBJS-y:.o=.c)
diff --git a/lib_mips/bootm_qemu_mips.c b/lib_mips/bootm_qemu_mips.c
new file mode 100644
index 000..cc70fa9
--- /dev/null
+++ b/lib_mips/bootm_qemu_mips.c
@@ -0,0 +1,76 @@
+/*
+ * (C) Copyright 2008
+ * Jean-Christophe PLAGNIOL-VILLARD <[EMAIL PROTECTED]>
+ *
+ * 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 
+#include 
+#include 
+#include 
+#include 
+
+DECLARE_GLOBAL_DATA_PTR;
+
+int do_bootm_linux(int flag, int argc, char *argv[], bootm_headers_t *images)
+{
+   void(*theKernel) (int, char **, char **, int *);
+   char*bootargs = getenv ("bootargs");
+   char*start;
+   uintlen;
+
+   /* find kernel entry point */
+   theKernel = (void (*)(int, char **, char **, int *))images->ep;
+
+   show_boot_progress (15);
+
+   debug ("## Transferring control to Linux (at address %08lx) ...\n",
+   (ulong) theKernel);
+
+   gd->bd->bi_boot_params = gd->bd->bi_memstart + (16 << 20) - 256;
+   debug ("%-12s= 0x%08lX\n", "boot_params", 
(ulong)gd->bd->bi_boot_params);
+
+   /* set Magic */
+   *(int32_t *)(gd->bd->bi_boot_params - 4) = 0x12345678;
+   /* set ram_size */
+   *(int32_t *)(gd->bd->bi_boot_params - 8) = gd->ram_size;
+
+   start = (char*)gd->bd->bi_boot_params;
+
+   len = strlen(bootargs);
+
+   strncpy(start, bootargs, len + 1);
+
+   start += len;
+
+   len = images->rd_end - images->rd_start;
+   if (len > 0) {
+   start += sprintf(start," rd_start=0x%08X rd_size=0x%0X",
+   (uint) UNCACHED_SDRAM (images->rd_start),
+   (uint) len);
+   }
+
+   /* we assume that the kernel is in place */
+   printf ("\nStarting kernel ...\n\n");
+
+   theKernel (0, NULL, NULL, 0);
+   /* does not return */
+   return 1;
+}
-- 
1.5.6.5

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


[U-Boot] [PATCH v2] Remove support for booting ARTOS images

2008-09-08 Thread Kumar Gala
Pantelis Antoniou stated:
AFAIK, it is still used but the products using PPC are long gone.
Nuke it plz (from orbit).

So remove it since it cleans up a usage of env_get_char outside of
the environment code.

Signed-off-by: Kumar Gala <[EMAIL PROTECTED]>
---
 README|4 +-
 common/cmd_bootm.c|   99 -
 common/image.c|3 -
 doc/uImage.FIT/source_file_format.txt |2 +-
 include/configs/NETPHONE.h|2 -
 include/configs/NETTA.h   |2 -
 include/configs/NETTA2.h  |2 -
 include/configs/NETVIA.h  |2 -
 8 files changed, 3 insertions(+), 113 deletions(-)

diff --git a/README b/README
index 37449d1..d138c43 100644
--- a/README
+++ b/README
@@ -3030,8 +3030,8 @@ details; basically, the header defines the following 
image properties:
 
 * Target Operating System (Provisions for OpenBSD, NetBSD, FreeBSD,
   4.4BSD, Linux, SVR4, Esix, Solaris, Irix, SCO, Dell, NCR, VxWorks,
-  LynxOS, pSOS, QNX, RTEMS, ARTOS;
-  Currently supported: Linux, NetBSD, VxWorks, QNX, RTEMS, ARTOS, LynxOS).
+  LynxOS, pSOS, QNX, RTEMS;
+  Currently supported: Linux, NetBSD, VxWorks, QNX, RTEMS, LynxOS).
 * Target CPU Architecture (Provisions for Alpha, ARM, AVR32, Intel x86,
   IA64, MIPS, NIOS, PowerPC, IBM S390, SuperH, Sparc, Sparc 64 Bit;
   Currently supported: ARM, AVR32, Intel x86, MIPS, NIOS, PowerPC).
diff --git a/common/cmd_bootm.c b/common/cmd_bootm.c
index 751f5b9..1880bc3 100644
--- a/common/cmd_bootm.c
+++ b/common/cmd_bootm.c
@@ -108,9 +108,6 @@ static boot_os_fn do_bootm_qnxelf;
 int do_bootvx (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[]);
 int do_bootelf (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[]);
 #endif
-#if defined(CONFIG_ARTOS) && defined(CONFIG_PPC)
-static boot_os_fn do_bootm_artos;
-#endif
 
 ulong load_addr = CFG_LOAD_ADDR;   /* Default Load Address */
 static bootm_headers_t images; /* pointers to os/initrd/fdt images */
@@ -455,11 +452,6 @@ int do_bootm (cmd_tbl_t *cmdtp, int flag, int argc, char 
*argv[])
break;
 #endif
 
-#ifdef CONFIG_ARTOS
-   case IH_OS_ARTOS:
-   do_bootm_artos (0, argc, argv, &images);
-   break;
-#endif
}
 
show_boot_progress (-9);
@@ -1152,94 +1144,3 @@ static int do_bootm_qnxelf(int flag, int argc, char 
*argv[],
return 1;
 }
 #endif
-
-#if defined(CONFIG_ARTOS) && defined(CONFIG_PPC)
-static int do_bootm_artos (int flag, int argc, char *argv[],
-  bootm_headers_t *images)
-{
-   ulong top;
-   char *s, *cmdline;
-   char **fwenv, **ss;
-   int i, j, nxt, len, envno, envsz;
-   bd_t *kbd;
-   void (*entry)(bd_t *bd, char *cmdline, char **fwenv, ulong top);
-
-#if defined(CONFIG_FIT)
-   if (!images->legacy_hdr_valid) {
-   fit_unsupported_reset ("ARTOS");
-   return 1;
-   }
-#endif
-
-   /*
-* Booting an ARTOS kernel image + application
-*/
-
-   /* this used to be the top of memory, but was wrong... */
-#ifdef CONFIG_PPC
-   /* get stack pointer */
-   asm volatile ("mr %0,1" : "=r"(top) );
-#endif
-   debug ("## Current stack ends at 0x%08lX ", top);
-
-   top -= 2048;/* just to be sure */
-   if (top > CFG_BOOTMAPSZ)
-   top = CFG_BOOTMAPSZ;
-   top &= ~0xF;
-
-   debug ("=> set upper limit to 0x%08lX\n", top);
-
-   /* first check the artos specific boot args, then the linux args*/
-   if ((s = getenv( "abootargs")) == NULL && (s = getenv ("bootargs")) == 
NULL)
-   s = "";
-
-   /* get length of cmdline, and place it */
-   len = strlen (s);
-   top = (top - (len + 1)) & ~0xF;
-   cmdline = (char *)top;
-   debug ("## cmdline at 0x%08lX ", top);
-   strcpy (cmdline, s);
-
-   /* copy bdinfo */
-   top = (top - sizeof (bd_t)) & ~0xF;
-   debug ("## bd at 0x%08lX ", top);
-   kbd = (bd_t *)top;
-   memcpy (kbd, gd->bd, sizeof (bd_t));
-
-   /* first find number of env entries, and their size */
-   envno = 0;
-   envsz = 0;
-   for (i = 0; env_get_char (i) != '\0'; i = nxt + 1) {
-   for (nxt = i; env_get_char (nxt) != '\0'; ++nxt)
-   ;
-   envno++;
-   envsz += (nxt - i) + 1; /* plus trailing zero */
-   }
-   envno++;/* plus the terminating zero */
-   debug ("## %u envvars total size %u ", envno, envsz);
-
-   top = (top - sizeof (char **) * envno) & ~0xF;
-   fwenv = (char **)top;
-   debug ("## fwenv at 0x%08lX ", top);
-
-   top = (top - envsz) & ~0xF;
-   s = (char *)top;
-   ss = fwenv;
-
-   /* now copy them */
-   for (i = 0; env_get_char (i) != '\0'; i = nxt + 1) {
-   for (nxt = i; env_get_char (nxt) != '\0'; ++nxt)
-   ;
- 

Re: [U-Boot] [PATCH] add reboot as a synonym for reset

2008-09-08 Thread Wolfgang Denk
Dear Andrew Dyer,

In message <[EMAIL PROTECTED]> you wrote:
> Add 'reboot' as a synonym for 'reset' at the u-boot command line.

I tend to reject this change, because I think it is  actually  wrong.
'reboot'  and  'reset' are two different things - the former includes
an ordered shut-down  of  running  services  while  the  latter  just
performs what the name says: a hardware reset.

This is a difference which some may consider small, but I think it is
important enough not to confuse terminology.

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: [EMAIL PROTECTED]
It's hard to make a program foolproof because fools are so ingenious.
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


u-boot@lists.denx.de

2008-09-08 Thread Wolfgang Denk
Dear "Victor Gallardo",

In message <[EMAIL PROTECTED]> you wrote:
> 
> Oops, Sorry Stefan my fault for introducing this. 
...
>  #if defined(CONFIG_HAS_ETH1) && defined(CONFIG_GPCS_PHY1_ADDR)
>   case CONFIG_GPCS_PHY1_ADDR:
> - mode_reg = in_be32((void *)EMAC_M1 + 0x100);
> - if (addr == EMAC_M1_IPPA_GET(mode_reg))
> + if (addr == EMAC_M1_IPPA_GET(in_be32((void *)EMAC_M1 +
> 0x100)))
^^
Line wrapped.

>  #if defined(CONFIG_HAS_ETH2) && defined(CONFIG_GPCS_PHY2_ADDR)
>   case CONFIG_GPCS_PHY2_ADDR:
> - mode_reg = in_be32((void *)EMAC_M1 + 0x300);
> - if (addr == EMAC_M1_IPPA_GET(mode_reg))
> + if (addr == EMAC_M1_IPPA_GET(in_be32((void *)EMAC_M1 +
> 0x300)))
^^
Line wrapped.

>  #if defined(CONFIG_HAS_ETH3) && defined(CONFIG_GPCS_PHY3_ADDR)
>   case CONFIG_GPCS_PHY3_ADDR:
> - mode_reg = in_be32((void *)EMAC_M1 + 0x400);
> - if (addr == EMAC_M1_IPPA_GET(mode_reg))
> + if (addr == EMAC_M1_IPPA_GET(in_be32((void *)EMAC_M1 +
> 0x400)))
^^
Line wrapped.

Please fix your mailer setup and resubmit.

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: [EMAIL PROTECTED]
I have never understood the female capacity to avoid a direct  answer
to any question.
-- Spock, "This Side of Paradise", stardate 3417.3
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


[U-Boot] [PATCH] add reboot as a synonym for reset

2008-09-08 Thread Andrew Dyer
Add 'reboot' as a synonym for 'reset' at the u-boot command line.

This saves me confusion when switching back and forth between linux
and u-boot about which command to use by making u-boot accept both.

Signed-off-by: Andrew Dyer <[EMAIL PROTECTED]>
---
 common/cmd_boot.c |6 ++
 1 files changed, 6 insertions(+), 0 deletions(-)

diff --git a/common/cmd_boot.c b/common/cmd_boot.c
index d83f5af..644bb85 100644
--- a/common/cmd_boot.c
+++ b/common/cmd_boot.c
@@ -76,3 +76,9 @@ U_BOOT_CMD(
"reset   - Perform RESET of the CPU\n",
NULL
 );
+
+U_BOOT_CMD(
+   reboot, 1, 0,   do_reset,
+   "reboot  - Perform RESET of the CPU\n",
+   NULL
+);
-- 
1.5.4.3

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


[U-Boot] [PATCH] add board support for virtex4fx12 minimodul

2008-09-08 Thread schardt
From: schardt <[EMAIL PROTECTED](none)>

---
 Makefile  |3 +
 board/xilinx/fx12mm/Makefile  |   63 
 board/xilinx/fx12mm/config.mk |   28 +++
 board/xilinx/fx12mm/fx12mm.c  |   67 +
 board/xilinx/fx12mm/init.S|   32 
 board/xilinx/fx12mm/u-boot.lds|  149 +
 board/xilinx/fx12mm/xparameters.h |   40 ++
 include/configs/FX12MM.h  |  127 +++
 8 files changed, 509 insertions(+), 0 deletions(-)
 create mode 100644 board/xilinx/fx12mm/Makefile
 create mode 100644 board/xilinx/fx12mm/config.mk
 create mode 100644 board/xilinx/fx12mm/fx12mm.c
 create mode 100644 board/xilinx/fx12mm/init.S
 create mode 100644 board/xilinx/fx12mm/u-boot.lds
 create mode 100644 board/xilinx/fx12mm/xparameters.h
 create mode 100644 include/configs/FX12MM.h

diff --git a/Makefile b/Makefile
index 8d82ef5..1fc476d 100644
--- a/Makefile
+++ b/Makefile
@@ -1282,6 +1282,9 @@ ERIC_config:  unconfig
 EXBITGEN_config:   unconfig
@$(MKCONFIG) $(@:_config=) ppc ppc4xx exbitgen
 
+FX12MM_config: unconfig
+   @$(MKCONFIG) $(@:_config=) ppc ppc4xx fx12mm xilinx
+
 G2000_config:  unconfig
@$(MKCONFIG) $(@:_config=) ppc ppc4xx g2000
 
diff --git a/board/xilinx/fx12mm/Makefile b/board/xilinx/fx12mm/Makefile
new file mode 100644
index 000..aed47ef
--- /dev/null
+++ b/board/xilinx/fx12mm/Makefile
@@ -0,0 +1,63 @@
+#
+# (C) Copyright 2000-2006
+# Wolfgang Denk, DENX Software Engineering, [EMAIL PROTECTED]
+#
+# 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
+ifneq ($(OBJTREE),$(SRCTREE))
+$(shell mkdir -p $(obj)../common)
+$(shell mkdir -p $(obj)../xilinx_iic)
+endif
+
+INCS   := -I../common  -I../xilinx_iic 
+CFLAGS += $(INCS)
+HOST_CFLAGS+= $(INCS)
+
+LIB= $(obj)lib$(BOARD).a
+
+COBJS  = $(BOARD).o \
+ ../common/xbasic_types.o ../common/xdma_channel.o \
+ ../common/xdma_channel_sg.o \
+ ../common/xversion.o \
+
+SOBJS   = init.o 
+
+SRCS   := $(SOBJS:.o=.S) $(COBJS:.o=.c)
+OBJS   := $(addprefix $(obj),$(COBJS))
+SOBJS  := $(addprefix $(obj),$(SOBJS))
+
+$(LIB):$(OBJS) $(SOBJS)
+   $(AR) $(ARFLAGS) $@ $^
+
+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/xilinx/fx12mm/config.mk b/board/xilinx/fx12mm/config.mk
new file mode 100644
index 000..69490fb
--- /dev/null
+++ b/board/xilinx/fx12mm/config.mk
@@ -0,0 +1,28 @@
+#
+# (C) Copyright 2000
+# Wolfgang Denk, DENX Software Engineering, [EMAIL PROTECTED]
+#
+# 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
+#
+
+#
+# Memec/Avnet Virtex4FX12 MiniModul
+# Standard EDK 10.1 Flash Address
+#
+TEXT_BASE = 0xFF80
diff --git a/board/xilinx/fx12mm/fx12mm.c b/board/xilinx/fx12mm/fx12mm.c
new file mode 100644
index 000..66adde9
--- /dev/null
+++ b/board/xilinx/fx12mm/fx12mm.c
@@ -0,0 +1,67 @@
+/*
+ * (C) Copyright 2008
+ *
+ * Georg Schardt <[EMAIL PROTECTED]>
+ *
+ * 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

Re: [U-Boot] [PATCH] Add support for booting of INTEGRITY operating system uImages

2008-09-08 Thread Peter Tyser
Hello,

> In message <[EMAIL PROTECTED]> you wrote:
> > Signed-off-by: Peter Tyser <[EMAIL PROTECTED]>
> > ---
> >  README |5 +++--
> >  common/cmd_bootm.c |   39 +++
> >  common/image.c |3 +++
> >  include/image.h|1 +
> >  4 files changed, 46 insertions(+), 2 deletions(-)
> 
> Can you please rebase your patch against current top of tree, and
> resubmit?   Thanks.

Sure.  I'll post after Kumar re-submits his removal of ARTOS support
patches as the INTEGRITY patch touches the same files.  I made a
aesthetic comment on his patchset and will base the INTEGRITY change on
top of his changes.

Kumar, if you don't plan on resubmitting the ARTOS support patches let
me know and I'll go ahead and send my rebased patch now.

Thanks,
Peter

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


Re: [U-Boot] [PATCH] ARM DaVinci: Fix broken HW ECC for large page NAND.

2008-09-08 Thread Scott Wood
On Sat, Aug 30, 2008 at 05:06:55PM -0400, Hugo Villeneuve wrote:
> ARM DaVinci: Fix broken HW ECC for large page NAND.
> 
> Signed-off-by: Hugo Villeneuve <[EMAIL PROTECTED]>
> 
> ---
> 
> Based on original patch by Bernard Blackham <[EMAIL PROTECTED]>
> 
> U-boot's HW ECC support for large page NAND on Davinci is completely
> broken.  Some kernels, such as the 2.6.10 one supported by
> MontaVista for DaVinci, rely upon this broken behaviour as they
> share the same code for ECCs. In the existing scheme, error
> detection *might* work on large page, but error correction
> definitely does not.  Small page ECC correction works, but the
> format is not compatible with the mainline git kernel.
> 
> This patch adds ECC code that matches what is currently in the
> Davinci git repository (since NAND support was added in 2.6.24).
> This makes the ECC and OOB layout written by u-boot compatible with
> Linux for both small page and large page devices and fixes ECC
> correction for large page devices.
> 
> The old behaviour can be restored by defining the macro
> CFG_DAVINCI_BROKEN_ECC, which is undefined by default.

Applied to u-boot-nand-flash.  Next time, please put the commit message
above the "---", except for extra commentary that isn't intended to go
into the git history.

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


Re: [U-Boot] [PATCH] cmd_mem.c: Fix help message alignment

2008-09-08 Thread Peter Tyser
> > What is the preferred command indentation in general?
> > 
> > - Tabs or spaces? eg:
> > "dhcp\t- invoke DHCP client to obtain IP/boot params\n"
> > "exit- exit script\n"
> 
> TABs are preferred, as they save  memory  footprint  for  the  U-Boot
> image. But for the help textx, this often makes the code hard to read
> and difficult to edit, so spaces are accepted here as well.
> 
> > - What about commands that exceed the soft limit of 8 characters?  Are
> > they acceptable?  Should there be a space between the command and the -?
> > eg I currently see both:
> > "interrupts - enable or disable interrupts\n"
> > "reiserload- load binary file from a Reiser filesystem\n"
> 
> Long command names should be avoided  in  general.  If  the  name  is
> exactly  8  characters,  so  that the '-' would align without a space
> between the name and the '-', then omit it; otherwise add it.
> 
> > I'd be happy to post these patches if desired.  If so, I'll wait till I
> > hear back about the preferred indentation method.
> 
> Well, try and post them; probably on the next merge window.

Will do, thanks for the feedback,
Peter

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


Re: [U-Boot] [PATCH] Remove support for booting ARTOS images

2008-09-08 Thread Peter Tyser
Hello Kumar,

On Mon, 2008-09-08 at 08:41 -0500, Kumar Gala wrote:
> Pantelis Antoniou stated:
>   AFAIK, it is still used but the products using PPC are long gone.
>   Nuke it plz (from orbit).
> 
> So remove it since it cleans up a usage of env_get_char outside of
> the environment code.
> 
> Signed-off-by: Kumar Gala <[EMAIL PROTECTED]>
> ---
>  common/cmd_bootm.c |   99 
> 
>  common/image.c |3 -
>  include/configs/NETPHONE.h |2 -
>  include/configs/NETTA.h|2 -
>  include/configs/NETTA2.h   |2 -
>  include/configs/NETVIA.h   |2 -
>  6 files changed, 0 insertions(+), 110 deletions(-)

ARTOS references in the following 2 files could also be cleaned up:
./README
./doc/uImage.FIT/source_file_format.txt

Peter

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


u-boot@lists.denx.de

2008-09-08 Thread Victor Gallardo

Oops, Sorry Stefan my fault for introducing this. 

Thanks for fixing this.

Regards

Victor Gallardo

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
On Behalf Of Stefan Roese
Sent: Friday, September 05, 2008 5:13 AM
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH] ppc4xx: Fix compilation warning for
canyonlands &glacier

Signed-off-by: Stefan Roese <[EMAIL PROTECTED]>
---
 cpu/ppc4xx/miiphy.c |   10 +++---
 1 files changed, 3 insertions(+), 7 deletions(-)

diff --git a/cpu/ppc4xx/miiphy.c b/cpu/ppc4xx/miiphy.c index
d303598..84b1bbe 100644
--- a/cpu/ppc4xx/miiphy.c
+++ b/cpu/ppc4xx/miiphy.c
@@ -236,28 +236,24 @@ unsigned int miiphy_getemac_offset(u8 addr)
#endif
 
 #if defined(CONFIG_460EX) || defined(CONFIG_460GT)
-   u32 mode_reg;
u32 eoffset = 0;
 
switch (addr) {
 #if defined(CONFIG_HAS_ETH1) && defined(CONFIG_GPCS_PHY1_ADDR)
case CONFIG_GPCS_PHY1_ADDR:
-   mode_reg = in_be32((void *)EMAC_M1 + 0x100);
-   if (addr == EMAC_M1_IPPA_GET(mode_reg))
+   if (addr == EMAC_M1_IPPA_GET(in_be32((void *)EMAC_M1 +
0x100)))
eoffset = 0x100;
break;
 #endif
 #if defined(CONFIG_HAS_ETH2) && defined(CONFIG_GPCS_PHY2_ADDR)
case CONFIG_GPCS_PHY2_ADDR:
-   mode_reg = in_be32((void *)EMAC_M1 + 0x300);
-   if (addr == EMAC_M1_IPPA_GET(mode_reg))
+   if (addr == EMAC_M1_IPPA_GET(in_be32((void *)EMAC_M1 +
0x300)))
eoffset = 0x300;
break;
 #endif
 #if defined(CONFIG_HAS_ETH3) && defined(CONFIG_GPCS_PHY3_ADDR)
case CONFIG_GPCS_PHY3_ADDR:
-   mode_reg = in_be32((void *)EMAC_M1 + 0x400);
-   if (addr == EMAC_M1_IPPA_GET(mode_reg))
+   if (addr == EMAC_M1_IPPA_GET(in_be32((void *)EMAC_M1 +
0x400)))
eoffset = 0x400;
break;
 #endif
--
1.5.6.5

___
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] FW: Fwd: Problem in writing jffs2 fiesystem

2008-09-08 Thread Scott Wood
On Mon, Sep 08, 2008 at 04:54:03PM +0200, Pedro Luis D. L. wrote:
> On Mon, 8 Sep 2008 19:51:59 +0530 Navin wrote:
> 
> >Hi all,
> >
> >I am running u-b00t-1.6.6 on custom at91sam9263 board.
> 
> Are you sure it is u-boot-1.6.6? The latest u-boot in repository is
> 1.3.4.

I'm guessing he meant 1.1.6, which is quite old (and apparently old
enough to suffer l33tsp34k bitrot).

> >Now i am able to boot, jffs2 filesystem with linux-2.6.20 kernel.

Especially since he's also using a kernel that is quite old. :-)

> >but the procedure i am using to burn is jffs2 is :
> 
> >1)boot the linux kernel with ramdisk
> 
> >2)erase the flash partition using $flasheraseall -j /dev/mtd1
> >3)writing the image using $nandwrite -p /dev/mtd1 rootfs.jffs2
> >
> 
> You should be able to flash the jffs2 file sytem from u-boot.
> No need to do it from linux.

I think that's the point, that it should work from u-boot but doesn't.

There's probably either something wrong with the u-boot NAND driver being
used, or the ECC layout doesn't match the kernel's.

> >In uboot i did this way:
> >
> >1) tftp 2110 rootfs.jffs2
> >2)nand write.jffs2 2110 0x20 0x(hex add of displayed by tftp)
> >
> 
> Which command is "nand write.jffs2"?

It's a perfectly normal u-boot command.

> Maybe you're using a version which
> is modified by the board supplier. 
> A "normal" way to flash it would be:
> 
> cp.b 2110 $(destiny_addr) $(filesize)

That's for NOR flash.  It does not work for NAND.

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


Re: [U-Boot] [PATCH][for 1.3.5] Fix handling of mem reserves for ramdisk

2008-09-08 Thread Kumar Gala

On Sep 8, 2008, at 9:10 AM, Wolfgang Denk wrote:

> Dear Kumar Gala,
>
> In message <6E892604-9B2A-4338-8DF7- 
> [EMAIL PROTECTED]> you wrote:
>>
>> The reason we had the code before was to try and make sure the size  
>> of
>> the fdt was as close to its final size as possible before we dealt
>> with the ramdisk relocation (boot_ramdisk_high()) that included the
>> properties and the memreserve in the fdt.  Step's a)-c) are there to
>> make sure the size is correct.
>
> Well, but the size needed for this should be a constant, so it should
> be sufficioent to determine  it  once  and  then  use  a  hard  coded
> constant; eventually add some padding.
>
> Doing this in runtime is a waste of resources (flash memory, RAM, and
> time - not to mention human time for maintaining the code).

I'm ok with determining the size bump and doing it that way.

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


Re: [U-Boot] [PATCH RFC] mpc8572ds relocatable

2008-09-08 Thread JerryVanBaren
Ed Swarthout wrote:
> Fixes boot crash from bad string pointers in get_table_entry_name
> when flash is erased or differs from current u-boot image.
> 
> Signed-off-by: Ed Swarthout <[EMAIL PROTECTED]>
> ---
> 
> Fix was pointed out by Peter Tyser in Image.c get_table_entry_name thread.
> 
> This redoes Grant Likey's relocation change, but leaves control to each board.
> This also fixes the "mii dump" command when flash is erased.
> Tested with gcc 4.2
> 
>  board/freescale/mpc8572ds/config.mk  |1 +
>  board/freescale/mpc8572ds/u-boot.lds |2 +-
>  2 files changed, 2 insertions(+), 1 deletions(-)
> 
> diff --git a/board/freescale/mpc8572ds/config.mk 
> b/board/freescale/mpc8572ds/config.mk
> index 5b32186..8b3651b 100644
> --- a/board/freescale/mpc8572ds/config.mk
> +++ b/board/freescale/mpc8572ds/config.mk
> @@ -30,3 +30,4 @@ endif
>  PLATFORM_CPPFLAGS += -DCONFIG_E500=1
>  PLATFORM_CPPFLAGS += -DCONFIG_MPC85xx=1
>  PLATFORM_CPPFLAGS += -DCONFIG_MPC8572=1
> +PLATFORM_CPPFLAGS += -mrelocatable -DCONFIG_RELOC_FIXUP_WORKS
> diff --git a/board/freescale/mpc8572ds/u-boot.lds 
> b/board/freescale/mpc8572ds/u-boot.lds
> index a05ece5..79fb41f 100644
> --- a/board/freescale/mpc8572ds/u-boot.lds
> +++ b/board/freescale/mpc8572ds/u-boot.lds
> @@ -58,7 +58,7 @@ SECTIONS
>.text  :
>{
>  *(.text)
> -*(.fixup)
> +/*  *(.fixup)*/

Please don't (just) comment this out.

Preferably your commit message would have enough information to answer 
the question of why .fixup was removed and no comment in the linker 
control file would be necessary.

In some cases it is worth adding a comment to the code as to why .fixup 
was removed so that someone that doesn't know the background doesn't add 
it back in.  Something like this hand generated pseudo patch:

+/*
+ * Note: The *(.fixup) section is unnecessary because the
+ * CONFIG_RELOC_FIXUP_WORKS method is being used to do the relocation.
+ */

.text  :
{
  *(.text)
-*(.fixup)
  *(.got1)
 } :text


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


Re: [U-Boot] [POWERPC] [BUG?] ppc4xx: PCIX0_STS versus PCIX0_STATUS in 4xx_pci.c

2008-09-08 Thread Stefan Roese
Carolyn,

On Friday 05 September 2008, [EMAIL PROTECTED] wrote:
> In the pci_440_init function in cpu/ppc4xx/4xx_pci.c, shouldn't this
>
> out32r( PCIX0_STS, in32r( PCIX0_STS ) & ~0xfff8 );
>
> really be this?
>
> out32r( PCIX0_STATUS, in32r( PCIX0_STATUS ) & ~0xfff8 );

Could you please explain, why you think this is the case? Are you seeing 
problems with this code? And are they solved when you use the other register 
instead?

Best regards,
Stefan

=
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-0 Fax: +49-8142-66989-80  Email: [EMAIL PROTECTED]
=
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


[U-Boot] FW: Fwd: Problem in writing jffs2 fiesystem

2008-09-08 Thread Pedro Luis D. L.








On Mon, 8 Sep 2008 19:51:59 +0530 Navin wrote:

>Hi all,
>
>I am running u-b00t-1.6.6 on custom at91sam9263 board.

Are you sure it is u-boot-1.6.6? The latest u-boot in repository is
1.3.4.

>Now i am able to boot, jffs2 filesystem with linux-2.6.20 kernel.
>but the procedure i am using to burn is jffs2 is :

>1)boot the linux kernel with ramdisk

>2)erase the flash partition using $flasheraseall -j /dev/mtd1
>3)writing the image using $nandwrite -p /dev/mtd1 rootfs.jffs2
>

You should be able to flash the jffs2 file sytem from u-boot.
No need to do it from linux.

>The above procedure works well for me. But when i try writing the jffs2 
>filesytem in uboot prompt its not booting (kernel panic).


>In uboot i did this way:
>
>1) tftp 2110 rootfs.jffs2
>2)nand write.jffs2 2110 0x20 0x(hex add of displayed by tftp)
>

Which command is "nand write.jffs2"? Maybe you're using a version which
is modified by the board supplier. 
A "normal" way to flash it would be:

cp.b 2110 $(destiny_addr) $(filesize)

Cheers.

Pedro L.

>
>What is the write  of doing this?
>- 
>Regards,
>Naveen




Juega a las preguntas de Live Quiz con tus contactos de Messenger ¡Empieza 
ahora!

_
¿Sigue el calor? Consulta MSN El tiempo
http://eltiempo.es.msn.com/___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH] [ARM] Moved conditional compile into Makefile

2008-09-08 Thread Andreas Engel
Wolfgang Denk schrieb:
> Dear Jean-Christophe PLAGNIOL-VILLARD,
> 
> In message <[EMAIL PROTECTED]> you wrote:
>> what append if CONFIG_PL010_SERIAL and CONFIG_PL011_SERIAL is active at the
>> same time?
> 
> Then something is missing.

In this particular case, this will not work anyway. The driver is not prepared
to support both a PL010 and a PL011 at the same time. And I doubt that there's
some real hardware out there which actually contains both types of uarts.

>> serial_pl01x.c will be compile twice
>>
>> so please move to 
>> +COBJS-$(CONFIG_PL010_SERIAL)$(CONFIG_PL011_SERIAL) += serial_pl01x.o
> 
> This alone is not sufficient, since then you need to add a  rule  for
> the resulting COBJS-yy.

There's already such a rule in common/Makefile.

> But as I learned all of this is completely unnecessary.
> 
> As Detlev Zundel pointed out, just doing "COBJS-y = $(sort COBJS-y)"
> would fix any such problems in a clean and readable way.
> 
> I recommend to add such a statement instead.

Yes, that's definitely better, as it also catches cases with more than
two y's.

Regards,
  Andreas

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


Re: [U-Boot] [PATCH][for 1.3.5] Fix handling of mem reserves for ramdisk

2008-09-08 Thread Wolfgang Denk
Dear Kumar Gala,

In message <[EMAIL PROTECTED]> you wrote:
>
> The reason we had the code before was to try and make sure the size of  
> the fdt was as close to its final size as possible before we dealt  
> with the ramdisk relocation (boot_ramdisk_high()) that included the  
> properties and the memreserve in the fdt.  Step's a)-c) are there to  
> make sure the size is correct.

Well, but the size needed for this should be a constant, so it should
be sufficioent to determine  it  once  and  then  use  a  hard  coded
constant; eventually add some padding.

Doing this in runtime is a waste of resources (flash memory, RAM, and
time - not to mention human time for maintaining the code).

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: [EMAIL PROTECTED]
Let the programmers be many and the managers few -- then all will  be
productive.   -- Geoffrey James, "The Tao of Programming"
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


[U-Boot] u-boot 1.2.0 -> 1.3.4 migration

2008-09-08 Thread Alexander Danilov
My bsp for u-boot 1.2.0 for AMCC PPC440EPx custom board works. I've
moved all bsp code to current u-boot version (1.3.4). All works fine
but I am getting program check exception when sending or receiving
packet over ethernet (EMAC0).
I've tryed to debug it but ethernet works when bdm connected.
What was changed in ethernet code for ppc4xx after 1.2.0?

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


Re: [U-Boot] [PATCH] [ARM] Moved conditional compile into Makefile

2008-09-08 Thread Wolfgang Denk
Dear Jean-Christophe PLAGNIOL-VILLARD,

In message <[EMAIL PROTECTED]> you wrote:
>
> what append if CONFIG_PL010_SERIAL and CONFIG_PL011_SERIAL is active at the
> same time?

Then something is missing.

> serial_pl01x.c will be compile twice
> 
> so please move to 
> +COBJS-$(CONFIG_PL010_SERIAL)$(CONFIG_PL011_SERIAL) += serial_pl01x.o

This alone is not sufficient, since then you need to add a  rule  for
the resulting COBJS-yy.

But as I learned all of this is completely unnecessary.

As Detlev Zundel pointed out, just doing "COBJS-y = $(sort COBJS-y)"
would fix any such problems in a clean and readable way.

I recommend to add such a statement instead.

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: [EMAIL PROTECTED]
Do you know about being with somebody? Wanting to be? If  I  had  the
whole  universe,  I'd  give it to you, Janice. When I see you, I feel
like I'm hungry all over. Do you know how that feels?
-- Charlie Evans, "Charlie X", stardate 1535.8
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH][for 1.3.5] Fix handling of mem reserves for ramdisk

2008-09-08 Thread Kumar Gala
> Hmm... OK, now the code will do the same as before, but is this  
> optimal?
>
> Why must we do a
>
> a) dummy mem reservation
> b) search for it
> c) delete it
> d) make the right mem reservation?
>
> Think the steps a) - c) are useless ...
>
> Please have a look at the following patch, it deletes the steps a) -  
> c)
> and fixes the fdt chosen command ...
>
> [PATCH] powerpc: Fix bootm to boot up again with a Ramdisk.
>
> Patch
> http://git.denx.de/?p=u-boot.git;a=commitdiff;h=2a1a2cb6e2b87ee550e6f27b647d23331dfd5e1b#patch3
>
> didnt remove the dummy mem reservation which was set up
> in fdt_chosen, and this stopped Linux from booting with a
> Ramdisk. This patch fixes this, by deleting the useless
> dummy mem reservation.
>
> Signed-off-by: Heiko Schocher <[EMAIL PROTECTED]>
> ---
> common/cmd_fdt.c  |3 ++-
> common/fdt_support.c  |4 +---
> include/fdt_support.h |2 +-
> lib_ppc/bootm.c   |5 +++--
> 4 files changed, 7 insertions(+), 7 deletions(-)
>
> diff --git a/common/cmd_fdt.c b/common/cmd_fdt.c
> index 0593bad..288a5c4 100644
> --- a/common/cmd_fdt.c
> +++ b/common/cmd_fdt.c
> @@ -450,7 +450,8 @@ int do_fdt (cmd_tbl_t * cmdtp, int flag, int  
> argc, char *argv[])
>   initrd_end = simple_strtoul(argv[3], NULL, 16);
>   }
>
> - fdt_chosen(working_fdt, initrd_start, initrd_end, 1);
> + fdt_chosen(working_fdt, 1);
> + fdt_initrd(working_fdt, initrd_start, initrd_end, 1);

You are removing functionality, if you want to do this add a command  
'fdt initrd' that sets the initrd props and the mem reserve information.

>
>   }
>   /* resize the fdt */
>   else if (strncmp(argv[1], "re", 2) == 0) {
> diff --git a/common/fdt_support.c b/common/fdt_support.c
> index a7773ab..8ceeb0f 100644
> --- a/common/fdt_support.c
> +++ b/common/fdt_support.c
> @@ -165,7 +165,7 @@ int fdt_initrd(void *fdt, ulong initrd_start,  
> ulong initrd_end, int force)
>   return 0;
> }
>
> -int fdt_chosen(void *fdt, ulong initrd_start, ulong initrd_end, int  
> force)
> +int fdt_chosen(void *fdt, int force)
> {
>   int   nodeoffset;
>   int   err;
> @@ -215,8 +215,6 @@ int fdt_chosen(void *fdt, ulong initrd_start,  
> ulong initrd_end, int force)
>   }
>   }
>
> - fdt_initrd(fdt, initrd_start, initrd_end, force);
> -
> #ifdef CONFIG_OF_STDOUT_VIA_ALIAS
>   path = fdt_getprop(fdt, nodeoffset, "linux,stdout-path", NULL);
>   if ((path == NULL) || force)
> diff --git a/include/fdt_support.h b/include/fdt_support.h
> index 424c3c6..ceaadc2 100644
> --- a/include/fdt_support.h
> +++ b/include/fdt_support.h
> @@ -28,7 +28,7 @@
>
> #include 
>
> -int fdt_chosen(void *fdt, ulong initrd_start, ulong initrd_end, int  
> force);
> +int fdt_chosen(void *fdt, int force);
> int fdt_initrd(void *fdt, ulong initrd_start, ulong initrd_end, int  
> force);
> void do_fixup_by_path(void *fdt, const char *path, const char *prop,
> const void *val, int len, int create);
> diff --git a/lib_ppc/bootm.c b/lib_ppc/bootm.c
> index 348421f..d581493 100644
> --- a/lib_ppc/bootm.c
> +++ b/lib_ppc/bootm.c
> @@ -145,8 +145,9 @@ int do_bootm_linux(int flag, int argc, char  
> *argv[], bootm_headers_t *images)
>* if the user wants it (the logic is in the subroutines).
>*/
>   if (of_size) {
> - /* pass in dummy initrd info, we'll fix up later */
> - if (fdt_chosen(of_flat_tree, images->rd_start, images->rd_end, 
> 0)  
> < 0) {
> + /* we dont have to pass anymore the dummy initrd info!
> +   we'll add this later, immediately with the right  
> values. */
> + if (fdt_chosen(of_flat_tree, 0) < 0) {
>   puts ("ERROR: ");
>   puts ("/chosen node create failed");
>   puts (" - must RESET the board to recover.\n");


The reason we had the code before was to try and make sure the size of  
the fdt was as close to its final size as possible before we dealt  
with the ramdisk relocation (boot_ramdisk_high()) that included the  
properties and the memreserve in the fdt.  Step's a)-c) are there to  
make sure the size is correct.

- k

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


Re: [U-Boot] MPC85xx unapplied patches

2008-09-08 Thread Kumar Gala

On Sep 6, 2008, at 6:38 PM, Wolfgang Denk wrote:

> Dear Andy,
>
> I have a couple of unapplied patches in my list which seem to fall
> into your area of responsibility. Can you please have a look at
> these:
>
> 4316  07/18 Timur Tabi [U-Boot-Users] [PATCH] Update  
> Freescale 85xx boards to sys_eeprom.c
>   -> see http://bugs.denx.de/databases/u-boot/prs/14
> 5974  08/15 [EMAIL PROTECTED]  [U-Boot] unassigned-patches/22:  
> [PATCH] Removed hardcoded MxMR loop v
>   -> see http://bugs.denx.de/databases/u-boot/prs/22
> 5978  08/15 [EMAIL PROTECTED]  [U-Boot] unassigned-patches/26:  
> [PATCH] 85xx: socrates: Enable Lime s
>   -> see http://bugs.denx.de/databases/u-boot/prs/26
> 5979  08/15 [EMAIL PROTECTED]  [U-Boot] unassigned-patches/27:  
> [PATCH] 85xx: Socrates: Major code up
>   -> see http://bugs.denx.de/databases/u-boot/prs/27
> 6184  08/19 Kumar Gala [U-Boot] [PATCH v2] 85xx: remove  
> redudant code with lib_ppc/interrupt

This has been applied.

However:
85xx: Ensure timebase is zero on secondary cores

hasn't been.

- k

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


[U-Boot] [PATCH v2] 85xx: Ensure timebase is zero on secondary cores

2008-09-08 Thread Kumar Gala
The e500um says the timebase is volatile out of reset.  To ensure
TB sync works we need to make sure its zero.

Signed-off-by: Kumar Gala <[EMAIL PROTECTED]>
---
Swapped mftbl,mftbu at Scott's request.. it doesnt mater since TB isn't
ticking when we do this.

- k

 cpu/mpc85xx/release.S |5 +
 1 files changed, 5 insertions(+), 0 deletions(-)

diff --git a/cpu/mpc85xx/release.S b/cpu/mpc85xx/release.S
index 75676b5..ec5e4da 100644
--- a/cpu/mpc85xx/release.S
+++ b/cpu/mpc85xx/release.S
@@ -37,6 +37,11 @@ __secondary_start_page:
li  r3,0x201
mtspr   SPRN_BUCSR,r3
 
+   /* Ensure TB is 0 */
+   li  r3,0
+   mttbl   r3
+   mttbu   r3
+
/* Enable/invalidate the I-Cache */
mfspr   r0,SPRN_L1CSR1
ori r0,r0,(L1CSR1_ICFI|L1CSR1_ICE)
-- 
1.5.5.1

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


Re: [U-Boot] [PATCH] [ARM] Moved conditional compile into Makefile

2008-09-08 Thread Jean-Christophe PLAGNIOL-VILLARD
On 14:30 Mon 08 Sep , Andreas Engel wrote:
> 
> Signed-off-by: Andreas Engel <[EMAIL PROTECTED]>
> ---
>  README |4 ++--
>  drivers/serial/Makefile|3 ++-
>  drivers/serial/serial_pl01x.c  |   15 +--
>  include/configs/integratorap.h |2 +-
>  include/configs/integratorcp.h |2 +-
>  include/configs/versatile.h|2 +-
>  6 files changed, 12 insertions(+), 16 deletions(-)
> 
> diff --git a/README b/README
> index 37449d1..4daff33 100644
> --- a/README
> +++ b/README
> @@ -380,11 +380,11 @@ The following options need to be configured:
>   param header, the default value is zero if undefined.
> 
>  - Serial Ports:
> - CFG_PL010_SERIAL
> + CONFIG_PL010_SERIAL
> 
>   Define this if you want support for Amba PrimeCell PL010 UARTs.
> 
> - CFG_PL011_SERIAL
> + CONFIG_PL011_SERIAL
> 
>   Define this if you want support for Amba PrimeCell PL011 UARTs.
> 
> diff --git a/drivers/serial/Makefile b/drivers/serial/Makefile
> index 3cc1999..b370828 100644
> --- a/drivers/serial/Makefile
> +++ b/drivers/serial/Makefile
> @@ -33,7 +33,8 @@ COBJS-$(CONFIG_DRIVER_S3C4510_UART) += s3c4510b_uart.o
>  COBJS-$(CONFIG_S3C64XX) += s3c64xx.o
>  COBJS-y += serial.o
>  COBJS-$(CONFIG_MAX3100_SERIAL) += serial_max3100.o
> -COBJS-y += serial_pl01x.o
> +COBJS-$(CONFIG_PL010_SERIAL) += serial_pl01x.o
> +COBJS-$(CONFIG_PL011_SERIAL) += serial_pl01x.o

what append if CONFIG_PL010_SERIAL and CONFIG_PL011_SERIAL is active at the
same time?

serial_pl01x.c will be compile twice

so please move to 
+COBJS-$(CONFIG_PL010_SERIAL)$(CONFIG_PL011_SERIAL) += serial_pl01x.o

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


[U-Boot] [PATCH] Remove support for booting ARTOS images

2008-09-08 Thread Kumar Gala
Pantelis Antoniou stated:
AFAIK, it is still used but the products using PPC are long gone.
Nuke it plz (from orbit).

So remove it since it cleans up a usage of env_get_char outside of
the environment code.

Signed-off-by: Kumar Gala <[EMAIL PROTECTED]>
---
 common/cmd_bootm.c |   99 
 common/image.c |3 -
 include/configs/NETPHONE.h |2 -
 include/configs/NETTA.h|2 -
 include/configs/NETTA2.h   |2 -
 include/configs/NETVIA.h   |2 -
 6 files changed, 0 insertions(+), 110 deletions(-)

diff --git a/common/cmd_bootm.c b/common/cmd_bootm.c
index 751f5b9..1880bc3 100644
--- a/common/cmd_bootm.c
+++ b/common/cmd_bootm.c
@@ -108,9 +108,6 @@ static boot_os_fn do_bootm_qnxelf;
 int do_bootvx (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[]);
 int do_bootelf (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[]);
 #endif
-#if defined(CONFIG_ARTOS) && defined(CONFIG_PPC)
-static boot_os_fn do_bootm_artos;
-#endif
 
 ulong load_addr = CFG_LOAD_ADDR;   /* Default Load Address */
 static bootm_headers_t images; /* pointers to os/initrd/fdt images */
@@ -455,11 +452,6 @@ int do_bootm (cmd_tbl_t *cmdtp, int flag, int argc, char 
*argv[])
break;
 #endif
 
-#ifdef CONFIG_ARTOS
-   case IH_OS_ARTOS:
-   do_bootm_artos (0, argc, argv, &images);
-   break;
-#endif
}
 
show_boot_progress (-9);
@@ -1152,94 +1144,3 @@ static int do_bootm_qnxelf(int flag, int argc, char 
*argv[],
return 1;
 }
 #endif
-
-#if defined(CONFIG_ARTOS) && defined(CONFIG_PPC)
-static int do_bootm_artos (int flag, int argc, char *argv[],
-  bootm_headers_t *images)
-{
-   ulong top;
-   char *s, *cmdline;
-   char **fwenv, **ss;
-   int i, j, nxt, len, envno, envsz;
-   bd_t *kbd;
-   void (*entry)(bd_t *bd, char *cmdline, char **fwenv, ulong top);
-
-#if defined(CONFIG_FIT)
-   if (!images->legacy_hdr_valid) {
-   fit_unsupported_reset ("ARTOS");
-   return 1;
-   }
-#endif
-
-   /*
-* Booting an ARTOS kernel image + application
-*/
-
-   /* this used to be the top of memory, but was wrong... */
-#ifdef CONFIG_PPC
-   /* get stack pointer */
-   asm volatile ("mr %0,1" : "=r"(top) );
-#endif
-   debug ("## Current stack ends at 0x%08lX ", top);
-
-   top -= 2048;/* just to be sure */
-   if (top > CFG_BOOTMAPSZ)
-   top = CFG_BOOTMAPSZ;
-   top &= ~0xF;
-
-   debug ("=> set upper limit to 0x%08lX\n", top);
-
-   /* first check the artos specific boot args, then the linux args*/
-   if ((s = getenv( "abootargs")) == NULL && (s = getenv ("bootargs")) == 
NULL)
-   s = "";
-
-   /* get length of cmdline, and place it */
-   len = strlen (s);
-   top = (top - (len + 1)) & ~0xF;
-   cmdline = (char *)top;
-   debug ("## cmdline at 0x%08lX ", top);
-   strcpy (cmdline, s);
-
-   /* copy bdinfo */
-   top = (top - sizeof (bd_t)) & ~0xF;
-   debug ("## bd at 0x%08lX ", top);
-   kbd = (bd_t *)top;
-   memcpy (kbd, gd->bd, sizeof (bd_t));
-
-   /* first find number of env entries, and their size */
-   envno = 0;
-   envsz = 0;
-   for (i = 0; env_get_char (i) != '\0'; i = nxt + 1) {
-   for (nxt = i; env_get_char (nxt) != '\0'; ++nxt)
-   ;
-   envno++;
-   envsz += (nxt - i) + 1; /* plus trailing zero */
-   }
-   envno++;/* plus the terminating zero */
-   debug ("## %u envvars total size %u ", envno, envsz);
-
-   top = (top - sizeof (char **) * envno) & ~0xF;
-   fwenv = (char **)top;
-   debug ("## fwenv at 0x%08lX ", top);
-
-   top = (top - envsz) & ~0xF;
-   s = (char *)top;
-   ss = fwenv;
-
-   /* now copy them */
-   for (i = 0; env_get_char (i) != '\0'; i = nxt + 1) {
-   for (nxt = i; env_get_char (nxt) != '\0'; ++nxt)
-   ;
-   *ss++ = s;
-   for (j = i; j < nxt; ++j)
-   *s++ = env_get_char (j);
-   *s++ = '\0';
-   }
-   *ss++ = NULL;   /* terminate */
-
-   entry = (void (*)(bd_t *, char *, char **, ulong))images->ep;
-   (*entry) (kbd, cmdline, fwenv, top);
-
-   return 1;
-}
-#endif
diff --git a/common/image.c b/common/image.c
index 94f01ad..78efe2e 100644
--- a/common/image.c
+++ b/common/image.c
@@ -105,9 +105,6 @@ static table_entry_t uimage_arch[] = {
 
 static table_entry_t uimage_os[] = {
{   IH_OS_INVALID,  NULL,   "Invalid OS",   },
-#if defined(CONFIG_ARTOS) || defined(USE_HOSTCC)
-   {   IH_OS_ARTOS,"artos","ARTOS",},
-#endif
{   IH_OS_LINUX,"linux","Linux",},
 #if defined(CONFIG_LYNXKDI) || defined(USE_HOSTCC)

Re: [U-Boot] PPC4xx unapplied patches

2008-09-08 Thread Stefan Roese
Hi Wolfgang,

On Sunday 07 September 2008, Wolfgang Denk wrote:
> I have a an unapplied patch in my list which seem to fall into your
> area of responsibility. Can you please have a look at this:
>
>  6385  08/22 Ricardo Ribalda D  [U-Boot] [PATCH] ppc440: ml507: Add
> .gitignore

Not needed anymore. Its included in one other patch from Ricardo which is 
included in my pull request sent a few minutes ago.

Best regards,
Stefan

=
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-0 Fax: +49-8142-66989-80  Email: [EMAIL PROTECTED]
=
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


[U-Boot] [ppc4xx] Please pull git://www.denx.de/git/u-boot-ppc4xx.git

2008-09-08 Thread Stefan Roese
The following changes since commit f158c3d51838474c4c36af365af145fbaf92b694:
  Wolfgang Denk (1):
Merge branch 'master' of ssh://10.10.0.7/home/wd/git/u-boot/master

are available in the git repository at:

  git://www.denx.de/git/u-boot-ppc4xx.git master

Adam Graham (2):
  ppc4xx: IBM Memory Controller DDR autocalibration routines
  ppc4xx: Update Kilauea to use PPC4xx DDR autocalibration routines

Matthias Fuchs (3):
  ppc4xx: Update CPCI405 variants handling
  ppc4xx: Cleanup CPCI405 linker script
  ppc4xx: Update CPCI405(AB) configuration

Ricardo Ribalda Delgado (1):
  ppc44x: Unification of virtex5 pp440 boards

Stefan Roese (4):
  ppc4xx: Fix compilation warning for canyonlands & glacier
  ppc4xx: Fix compilation warning for PIP405
  ppc4xx: Remove CONFIG_CS8952_PHY define
  ppc4xx: Move ppc4xx specific prototypes to ppc4xx header

Victor Gallardo (1):
  ppc4xx: Add support for GPCS, SGMII and M88E1112 PHY

 CREDITS|3 +-
 MAINTAINERS|2 +
 MAKEALL|4 +
 Makefile   |   47 +-
 board/avnet/v5fx30teval/.gitignore |1 +
 .../ml507/config.mk => avnet/v5fx30teval/Makefile} |   12 +-
 board/avnet/v5fx30teval/v5fx30teval.c  |   28 +
 board/avnet/v5fx30teval/xparameters.h  |   33 +
 board/esd/cpci405/config.mk|   16 +-
 board/esd/cpci405/u-boot.lds   |   15 -
 board/xilinx/ml507/.gitignore  |1 +
 board/xilinx/ml507/Makefile|   41 +-
 board/xilinx/ml507/init.S  |   53 -
 board/xilinx/ml507/ml507.c |   21 +-
 board/xilinx/ml507/xparameters.h   |   17 +-
 board/xilinx/ppc440-generic/.gitignore |1 +
 board/xilinx/ppc440-generic/Makefile   |   62 +
 board/xilinx/ppc440-generic/init.S |   45 +
 .../{ml507 => ppc440-generic}/u-boot-ram.lds   |0 
 .../{ml507 => ppc440-generic}/u-boot-rom.lds   |0 
 .../xilinx/ppc440-generic/xilinx_ppc440_generic.c  |   52 +
 board/xilinx/ppc440-generic/xparameters.h  |   34 +
 cpu/ppc4xx/44x_spd_ddr2.c  |  158 ++-
 cpu/ppc4xx/4xx_enet.c  |  168 +++-
 cpu/ppc4xx/4xx_ibm_ddr2_autocalib.c| 1212 
 cpu/ppc4xx/Makefile|3 +
 cpu/ppc4xx/miiphy.c|   37 +-
 include/asm-ppc/ppc4xx-sdram.h |3 +-
 include/configs/CPCI4052.h |6 +
 include/configs/CPCI405AB.h|6 +
 include/configs/PIP405.h   |1 -
 include/configs/kilauea.h  |   19 +
 include/configs/ml507.h|   91 +--
 include/configs/v5fx30teval.h  |   49 +
 include/configs/xilinx-ppc440-generic.h|   49 +
 include/configs/xilinx-ppc440.h|  106 ++
 include/ppc440.h   |   13 -
 include/ppc4xx.h   |   13 +
 include/ppc4xx_enet.h  |3 +
 41 files changed, 2112 insertions(+), 336 deletions(-)
 create mode 100644 board/avnet/v5fx30teval/.gitignore
 rename board/{xilinx/ml507/config.mk => avnet/v5fx30teval/Makefile} (76%)
 create mode 100644 board/avnet/v5fx30teval/v5fx30teval.c
 create mode 100644 board/avnet/v5fx30teval/xparameters.h
 create mode 100644 board/xilinx/ml507/.gitignore
 delete mode 100644 board/xilinx/ml507/init.S
 create mode 100644 board/xilinx/ppc440-generic/.gitignore
 create mode 100644 board/xilinx/ppc440-generic/Makefile
 create mode 100644 board/xilinx/ppc440-generic/init.S
 rename board/xilinx/{ml507 => ppc440-generic}/u-boot-ram.lds (100%)
 rename board/xilinx/{ml507 => ppc440-generic}/u-boot-rom.lds (100%)
 create mode 100644 board/xilinx/ppc440-generic/xilinx_ppc440_generic.c
 create mode 100644 board/xilinx/ppc440-generic/xparameters.h
 create mode 100644 cpu/ppc4xx/4xx_ibm_ddr2_autocalib.c
 create mode 100644 include/configs/v5fx30teval.h
 create mode 100644 include/configs/xilinx-ppc440-generic.h
 create mode 100644 include/configs/xilinx-ppc440.h
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH] ppc440: ml507: Add .gitignore

2008-09-08 Thread Ricardo Ribalda Delgado
Hello Stefan

You can forget about this patch.

With the commit e07f4a8033b6270b8103049adb6456f660ff4a89 it is not again needed


 Best regards

On Mon, Sep 8, 2008 at 08:56, Stefan Roese <[EMAIL PROTECTED]> wrote:
> On Friday 22 August 2008, Ricardo Ribalda Delgado wrote:
>> Signed-off-by: Ricardo Ribalda Delgado <[EMAIL PROTECTED]>
>
> Does not apply anymore. Please rebase against current u-boot-ppc4xx repository
> and resubmit.
>
> Thanks.
>
> Best regards,
> Stefan
>
> =
> DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
> HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
> Phone: +49-8142-66989-0 Fax: +49-8142-66989-80  Email: [EMAIL PROTECTED]
> =
>



-- 
Ricardo Ribalda
http://www.eps.uam.es/~rribalda/
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 2/3] fix checkpatch errors

2008-09-08 Thread Haavard Skinnemoen
JerryVanBaren <[EMAIL PROTECTED]> wrote:
> Georg Schardt wrote:
> > ---
> >  include/configs/FX12MM.h |   12 ++--
> >  1 files changed, 6 insertions(+), 6 deletions(-)
> > 
> > diff --git a/include/configs/FX12MM.h b/include/configs/FX12MM.h
> > index b47e403..8b8d41c 100644
> > --- a/include/configs/FX12MM.h
> > +++ b/include/configs/FX12MM.h
> > @@ -15,28 +15,28 @@
> >  #define CONFIG_DOS_PARTITION1
> >  #define CFG_SYSTEMACE_BASE  XPAR_SYSACE_0_BASEADDR
> >  #define CFG_SYSTEMACE_WIDTH XPAR_SYSACE_0_MEM_WIDTH
> > -#define ADD_SYSTEMACE_CMDS  (| CFG_CMD_FAT)
> > +#define ADD_SYSTEMACE_CMDS  ( | CFG_CMD_FAT )
> >  #define RM_SYSTEMACE_CMDS
> >  #else
> >  #define ADD_SYSTEMACE_CMDS
> > -#define RM_SYSTEMACE_CMDS   | CFG_CMD_FAT
> > +#define RM_SYSTEMACE_CMDS   ( | CFG_CMD_FAT )
> 
> Dear List,
> 
> Philosophical question: is it better to put silly parenthesis around 
> #defines to make checkpatch shut up or to accept that checkpatch isn't 
> perfect and let it bitch about things that were done intentionally and 
> make sense per their usage?

In this particular case, I'd recommend not starting the macro with a
binary operator in the first place. That's just _wrong_.

Better define ADD_SYSTEMACE_CMDS etc. as 0 if no flags are to be
added/removed, and add the operator at the callsite.

> (Yes, I see the first one already had () and the change is just fixing 
> the spacing.)

The checkpatch author probably never considered that anyone would
actually define a macro beginning with a binary operator, so it's no
surprise that it comes up with strange suggestions.

That said, putting parentheses around macro contents is a good rule in
general since it might avoid quite a few surprises. E.g.

#define FOO -1

bar = 2FOO; /* should give a compile error, but doesn't */

> I'm serious about this question: in my day job I see a lot of mechanical 
> praying to the god of miserableC (MISRA-C) adding a HUGE amount of 
> unnecessary syntax noise such that it becomes hard to read the code 
> because of all the noise.  I've had people at work ask me why "we" 
> cannot write code that is as easy to understand as the linux kernel. 
> The answer is simple: "we" are slavishly and mechanically following the 
> god of "if it was good practice somewhere, sometime, it must always be a 
> good practice" and not applying good engineering judgment and experience.

I'm not particularly familiar with MISRA-C, but from what I've seen of
it, it's a particularly horrible example of following rules just for
the sake of the rules.

> It is WRONG to let our tools rule us.[1]

Agreed.

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


Re: [U-Boot] [PATCH] ppc440: ml507: Add .gitignore

2008-09-08 Thread Stefan Roese
On Friday 22 August 2008, Ricardo Ribalda Delgado wrote:
> Signed-off-by: Ricardo Ribalda Delgado <[EMAIL PROTECTED]>

Does not apply anymore. Please rebase against current u-boot-ppc4xx repository 
and resubmit.

Thanks.

Best regards,
Stefan

=
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-0 Fax: +49-8142-66989-80  Email: [EMAIL PROTECTED]
=
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 2/3] fix checkpatch errors

2008-09-08 Thread Wolfgang Denk
Dear JerryVanBaren,

In message <[EMAIL PROTECTED]> you wrote:
> Georg Schardt wrote:
...
> > -#define RM_SYSTEMACE_CMDS   | CFG_CMD_FAT
> > +#define RM_SYSTEMACE_CMDS   ( | CFG_CMD_FAT )
...

> Philosophical question: is it better to put silly parenthesis around 
> #defines to make checkpatch shut up or to accept that checkpatch isn't 
> perfect and let it bitch about things that were done intentionally and 
> make sense per their usage?

Well, the most important thin is actually that the code is correct,
and the second important thing is that it can be compiled.

With above definitions of "( | CFG_CMD_FAT )" and  similar,  I  think
that  the code would NOT compile; instead, I expect GCC to issue some
"error: expected expression before '|' token"  error  messages  (most
probably  followed by some other "error: called object 'foo' is not a
function" erros.

> (Yes, I see the first one already had () and the change is just fixing 
> the spacing.)

No matter if it fixes spacing or not - it breaks the code.


> I'm serious about this question: in my day job I see a lot of mechanical 

OK, here is a serious anser: no. Such changes as suggested above make
zero sense even if they don't effect correctness of code.

See my previous discussion with Guennadi - changing all "return (1);"
into "return 1;" makes no sense to me when it's done just to silence
checkpatch.pl.

> It is WRONG to let our tools rule us.[1]

Agreed 100%.


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: [EMAIL PROTECTED]
Do not underestimate the value of print statements for debugging.
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


[U-Boot] [PATCH] [ARM] Moved conditional compile into Makefile

2008-09-08 Thread Andreas Engel

Signed-off-by: Andreas Engel <[EMAIL PROTECTED]>
---
 README |4 ++--
 drivers/serial/Makefile|3 ++-
 drivers/serial/serial_pl01x.c  |   15 +--
 include/configs/integratorap.h |2 +-
 include/configs/integratorcp.h |2 +-
 include/configs/versatile.h|2 +-
 6 files changed, 12 insertions(+), 16 deletions(-)

diff --git a/README b/README
index 37449d1..4daff33 100644
--- a/README
+++ b/README
@@ -380,11 +380,11 @@ The following options need to be configured:
param header, the default value is zero if undefined.

 - Serial Ports:
-   CFG_PL010_SERIAL
+   CONFIG_PL010_SERIAL

Define this if you want support for Amba PrimeCell PL010 UARTs.

-   CFG_PL011_SERIAL
+   CONFIG_PL011_SERIAL

Define this if you want support for Amba PrimeCell PL011 UARTs.

diff --git a/drivers/serial/Makefile b/drivers/serial/Makefile
index 3cc1999..b370828 100644
--- a/drivers/serial/Makefile
+++ b/drivers/serial/Makefile
@@ -33,7 +33,8 @@ COBJS-$(CONFIG_DRIVER_S3C4510_UART) += s3c4510b_uart.o
 COBJS-$(CONFIG_S3C64XX) += s3c64xx.o
 COBJS-y += serial.o
 COBJS-$(CONFIG_MAX3100_SERIAL) += serial_max3100.o
-COBJS-y += serial_pl01x.o
+COBJS-$(CONFIG_PL010_SERIAL) += serial_pl01x.o
+COBJS-$(CONFIG_PL011_SERIAL) += serial_pl01x.o
 COBJS-$(CONFIG_XILINX_UARTLITE) += serial_xuartlite.o
 COBJS-$(CONFIG_SCIF_CONSOLE) += serial_sh.o
 COBJS-$(CONFIG_USB_TTY) += usbtty.o
diff --git a/drivers/serial/serial_pl01x.c b/drivers/serial/serial_pl01x.c
index d0497ec..c645cef 100644
--- a/drivers/serial/serial_pl01x.c
+++ b/drivers/serial/serial_pl01x.c
@@ -25,14 +25,11 @@
  * MA 02111-1307 USA
  */

-/* Simple U-Boot driver for the PrimeCell PL011 UARTs on the IntegratorCP */
-/* Should be fairly simple to make it work with the PL010 as well */
+/* Simple U-Boot driver for the PrimeCell PL010/PL011 UARTs */

 #include 
 #include 

-#if defined(CFG_PL010_SERIAL) || defined(CFG_PL011_SERIAL)
-
 #include "serial_pl01x.h"

 #define IO_WRITE(addr, val) (*(volatile unsigned int *)(addr) = (val))
@@ -52,7 +49,7 @@ static void pl01x_putc (int portnum, char c);
 static int pl01x_getc (int portnum);
 static int pl01x_tstc (int portnum);

-#ifdef CFG_PL010_SERIAL
+#ifdef CONFIG_PL010_SERIAL

 int serial_init (void)
 {
@@ -110,9 +107,9 @@ int serial_init (void)
return 0;
 }

-#endif /* CFG_PL010_SERIAL */
+#endif /* CONFIG_PL010_SERIAL */

-#ifdef CFG_PL011_SERIAL
+#ifdef CONFIG_PL011_SERIAL

 int serial_init (void)
 {
@@ -157,7 +154,7 @@ int serial_init (void)
return 0;
 }

-#endif /* CFG_PL011_SERIAL */
+#endif /* CONFIG_PL011_SERIAL */

 void serial_putc (const char c)
 {
@@ -224,5 +221,3 @@ static int pl01x_tstc (int portnum)
return !(IO_READ (port[portnum] + UART_PL01x_FR) &
 UART_PL01x_FR_RXFE);
 }
-
-#endif
diff --git a/include/configs/integratorap.h b/include/configs/integratorap.h
index 1452bf2..ba3c531 100644
--- a/include/configs/integratorap.h
+++ b/include/configs/integratorap.h
@@ -58,7 +58,7 @@
 /*
  * PL010 Configuration
  */
-#define CFG_PL010_SERIAL
+#define CONFIG_PL010_SERIAL
 #define CONFIG_CONS_INDEX  0
 #define CONFIG_BAUDRATE38400
 #define CONFIG_PL01x_PORTS { (void *) (CFG_SERIAL0), (void *) 
(CFG_SERIAL1) }
diff --git a/include/configs/integratorcp.h b/include/configs/integratorcp.h
index 347fa02..5340f7c 100644
--- a/include/configs/integratorcp.h
+++ b/include/configs/integratorcp.h
@@ -61,7 +61,7 @@
 /*
  * NS16550 Configuration
  */
-#define CFG_PL011_SERIAL
+#define CONFIG_PL011_SERIAL
 #define CONFIG_PL011_CLOCK 14745600
 #define CONFIG_PL01x_PORTS { (void *)CFG_SERIAL0, (void *)CFG_SERIAL1 }
 #define CONFIG_CONS_INDEX  0
diff --git a/include/configs/versatile.h b/include/configs/versatile.h
index a88d356..c18a248 100644
--- a/include/configs/versatile.h
+++ b/include/configs/versatile.h
@@ -86,7 +86,7 @@
 /*
  * NS16550 Configuration
  */
-#define CFG_PL011_SERIAL
+#define CONFIG_PL011_SERIAL
 #define CONFIG_PL011_CLOCK 2400
 #define CONFIG_PL01x_PORTS { (void *)CFG_SERIAL0, (void *)CFG_SERIAL1 }
 #define CONFIG_CONS_INDEX  0
-- 
1.5.6.5

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


Re: [U-Boot] [PATCH 1/2] Update i386 code (sc520_cdp)

2008-09-08 Thread JerryVanBaren
Graeme Russ wrote:
> Third time lucky maybe - ditched Evolution (can't adjust line wrap
> width) for Thunderbird. I don't have git-send-email installed - will
> investigate

Read the kernel Documentation/email-clients.txt:


Evolution and Tbird reportedly can work if you jump the right hoops. 
Maybe.  It's the clicky-gooey curse.[1]

See also my previous diatribe about letting our tools rule us.
   

Curmudgeonly yours,
gvb


[1] The Hitchhiker's Guide to the Galaxy, in a moment of reasoned 
lucidity which is almost unique among its current tally of five million, 
nine hundred and seventy-three thousand, five hundred and nine pages, 
says of the Sirius Cybernetics Corporation products that "it is very 
easy to be blinded to the essential uselessness of them by the sense of 
achievement you get from getting them to work at all." In other words, - 
and this is the rock-solid principle on which the whole of the 
Corporation's Galaxywide success is founded - their fundamental design 
flaws are completely hidden by their superficial design flaws.

- The Hitchhiker's Guide to the Galaxy / Douglas Adams (1952 - 2001). 
1st American ed. New York : Harmony Books, 1980, c1979
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


[U-Boot] [PATCH] ppc4xx: Move ppc4xx specific prototypes to ppc4xx header

2008-09-08 Thread Stefan Roese
This patch moves some 4xx specific prototypes out of include common.h
to a ppc4xx specific header.

Signed-off-by: Stefan Roese <[EMAIL PROTECTED]>
---
This patch is based on the u-boot-ppc4xx repository. It can't be applied
directly to the master repository. It's needed to clean up some 4xx
specific stuff that I missed in on of the ppc4xx SDRAM related patches.
I didn't want to rebase my repository so this additional patch is needed.


 board/netstal/hcu5/sdram.c |2 +-
 include/asm-ppc/ppc4xx-sdram.h |   14 ++
 include/common.h   |   21 -
 3 files changed, 15 insertions(+), 22 deletions(-)

diff --git a/board/netstal/hcu5/sdram.c b/board/netstal/hcu5/sdram.c
index 66a958c..e5df62e 100644
--- a/board/netstal/hcu5/sdram.c
+++ b/board/netstal/hcu5/sdram.c
@@ -122,7 +122,7 @@ void sdram_panic(const char *reason)
 }
 
 #ifdef CONFIG_DDR_ECC
-static void blank_string(int size)
+void blank_string(int size)
 {
int i;
 
diff --git a/include/asm-ppc/ppc4xx-sdram.h b/include/asm-ppc/ppc4xx-sdram.h
index a1ef029..8efa557 100644
--- a/include/asm-ppc/ppc4xx-sdram.h
+++ b/include/asm-ppc/ppc4xx-sdram.h
@@ -1402,4 +1402,18 @@
 
 #endif /* CONFIG_SDRAM_PPC4xx_DENALI_DDR2 */
 
+#ifndef __ASSEMBLY__
+/*
+ * Prototypes
+ */
+void inline blank_string(int size);
+inline void ppc4xx_ibm_ddr2_register_dump(void);
+u32 mfdcr_any(u32);
+void mtdcr_any(u32, u32);
+u32 ddr_wrdtr(u32);
+u32 ddr_clktr(u32);
+void spd_ddr_init_hang(void);
+u32 DQS_autocalibration(void);
+#endif /* __ASSEMBLY__ */
+
 #endif /* _PPC4xx_SDRAM_H_ */
diff --git a/include/common.h b/include/common.h
index 2516bfd..a394988 100644
--- a/include/common.h
+++ b/include/common.h
@@ -287,27 +287,6 @@ void   pciinfo   (int, int);
 #endif
 #endif
 
-/*
- * Prototypes
- */
-#if defined(CONFIG_SDRAM_PPC4xx_IBM_DDR2)
-void blank_string(int);
-inline void ppc4xx_ibm_ddr2_register_dump(void);
-#if defined(CONFIG_440)
-u32 mfdcr_any(u32);
-void mtdcr_any(u32, u32);
-#endif
-#if defined(CONFIG_SPD_EEPROM)
-u32 ddr_wrdtr(u32);
-u32 ddr_clktr(u32);
-void spd_ddr_init_hang(void);
-#endif
-#endif /* defined(CONFIG_SDRAM_PPC4xx_IBM_DDR2) */
-
-#if defined(CONFIG_PPC4xx_DDR_AUTOCALIBRATION)
-u32 DQS_autocalibration(void);
-#endif /* CONFIG_PPC4xx_DDR_AUTOCALIBRATION */
-
 intmisc_init_f   (void);
 intmisc_init_r   (void);
 
-- 
1.5.6.5

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


Re: [U-Boot] CFG_64BIT_xxx and friends

2008-09-08 Thread Haavard Skinnemoen
Haavard Skinnemoen <[EMAIL PROTECTED]> wrote:
> That's a bit more than expected. Is this with or without --gc-sections?
> Linking with --gc-sections should make simple_strtoull() go away unless
> it's actually used.

That's assuming the fdt and image code doesn't interpret
CFG_64BIT_VSPRINTF as CFG_BLOAT_ME_HARDER, which it does. So enabling
CFG_64BIT_VSPRINTF does increase the code size even with --gc-sections.

I think fdt and common/image.c should stop abusing CFG_64BIT_VSPRINTF
and get its own symbol instead, e.g. CFG_64BIT_PHYS_ADDR, and perhaps a
nice str_to_addr() wrapper which selects between strtoul and strtoull
based on this symbol.

> Another thing that might hurt is that lib_generic/vsprintf.c reinvents
> do_div() without the out-of-line __div_64_32() bit. Converting it to
> use do_div() from include/div64.h should help.

It does. A lot. Here are some numbers from avr32:

vanilla:
   textdata bss dec hex filename
  962327528  216208  319968   4e1e0 ./u-boot

with CFG_64BIT_VSPRINTF:
   textdata bss dec hex filename
  981007528  216208  321836   4e92c ./u-boot

with CFG_64BIT_VSPRINTF and generic do_div():
   textdata bss dec hex filename
  963967528  216208  320132   4e284 ./u-boot

So I highly recommend applying the patch below before killing
CFG_64BIT_VSPRINTF.

> In fact, enabling CFG_64BIT_VSPRINTF unconditionally without fixing
> this first will probably break all architectures that don't link with
> libgcc.

I was sort of expecting avr32 to break because of this, but it didn't.
Apparently, the top-level Makefile adds -lgcc unconditionally...which
makes it quite hard to catch undesired bloat like this.

Haavard

From: Haavard Skinnemoen <[EMAIL PROTECTED]>
Subject: vsprintf: Use generic do_div()

lib_generic/vsprintf.c uses its own reimplementation of do_div().
Switch it over to use the generic implementation from include/div64.h.
This saves 2K of .text on avr32 with CFG_64BIT_VSPRINTF enabled.

Signed-off-by: Haavard Skinnemoen <[EMAIL PROTECTED]>

diff --git a/lib_generic/vsprintf.c b/lib_generic/vsprintf.c
index 7c9cfe1..a4f8a83 100644
--- a/lib_generic/vsprintf.c
+++ b/lib_generic/vsprintf.c
@@ -15,6 +15,7 @@
 #include 
 
 #include 
+#include 
 #if !defined (CONFIG_PANIC_HANG)
 #include 
 /*cmd_boot.c*/
@@ -106,22 +107,6 @@ static int skip_atoi(const char **s)
 #define LARGE  64  /* use 'ABCDEF' instead of 'abcdef' */
 
 #ifdef CFG_64BIT_VSPRINTF
-#define do_div(n,base) ({ \
-   unsigned int __res; \
-   __res = ((unsigned long long) n) % base; \
-   n = ((unsigned long long) n) / base; \
-   __res; \
-})
-#else
-#define do_div(n,base) ({ \
-   int __res; \
-   __res = ((unsigned long) n) % base; \
-   n = ((unsigned long) n) / base; \
-   __res; \
-})
-#endif
-
-#ifdef CFG_64BIT_VSPRINTF
 static char * number(char * str, long long num, unsigned int base, int size, 
int precision ,int type)
 #else
 static char * number(char * str, long num, unsigned int base, int size, int 
precision ,int type)
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 2/3] fix checkpatch errors

2008-09-08 Thread JerryVanBaren
Georg Schardt wrote:
> ---
>  include/configs/FX12MM.h |   12 ++--
>  1 files changed, 6 insertions(+), 6 deletions(-)
> 
> diff --git a/include/configs/FX12MM.h b/include/configs/FX12MM.h
> index b47e403..8b8d41c 100644
> --- a/include/configs/FX12MM.h
> +++ b/include/configs/FX12MM.h
> @@ -15,28 +15,28 @@
>  #define CONFIG_DOS_PARTITION1
>  #define CFG_SYSTEMACE_BASE  XPAR_SYSACE_0_BASEADDR
>  #define CFG_SYSTEMACE_WIDTH XPAR_SYSACE_0_MEM_WIDTH
> -#define ADD_SYSTEMACE_CMDS  (| CFG_CMD_FAT)
> +#define ADD_SYSTEMACE_CMDS  ( | CFG_CMD_FAT )
>  #define RM_SYSTEMACE_CMDS
>  #else
>  #define ADD_SYSTEMACE_CMDS
> -#define RM_SYSTEMACE_CMDS   | CFG_CMD_FAT
> +#define RM_SYSTEMACE_CMDS   ( | CFG_CMD_FAT )

Dear List,

Philosophical question: is it better to put silly parenthesis around 
#defines to make checkpatch shut up or to accept that checkpatch isn't 
perfect and let it bitch about things that were done intentionally and 
make sense per their usage?

(Yes, I see the first one already had () and the change is just fixing 
the spacing.)

I'm serious about this question: in my day job I see a lot of mechanical 
praying to the god of miserableC (MISRA-C) adding a HUGE amount of 
unnecessary syntax noise such that it becomes hard to read the code 
because of all the noise.  I've had people at work ask me why "we" 
cannot write code that is as easy to understand as the linux kernel. 
The answer is simple: "we" are slavishly and mechanically following the 
god of "if it was good practice somewhere, sometime, it must always be a 
good practice" and not applying good engineering judgment and experience.

It is WRONG to let our tools rule us.[1]

Thanks for letting me unload,
gvb

[1] It took four movies to kill the Terminators, and now I see we still 
haven't succeeded.
   

P.S. In my day job I've seen way too much lot of...
#define FOOBAR_THREE(3)

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


Re: [U-Boot] CFG_64BIT_xxx and friends

2008-09-08 Thread Haavard Skinnemoen
Matthias Fuchs <[EMAIL PROTECTED]> wrote:
> Here is the U-Boot size for the PLU405 board (405EP-based) with
> and without
> 
> #define CFG_64BIT_VSPRINTF
> #define CFG_64BIT_STRTOUL
> .
> 
> without:
> # ppc_4xx-size u-boot
>textdata bss dec hex filename
>  289568   17532  301312  608412   9489c u-boot
> 
> with 64bit format handling:
> # ppc_4xx-size u-boot
>textdata bss dec hex filename
>  291368   17532  301312  610212   94fa4 u-boot
> 
> So the difference is 1800 bytes on this architecture.

Thanks.

That's a bit more than expected. Is this with or without --gc-sections?
Linking with --gc-sections should make simple_strtoull() go away unless
it's actually used.

Another thing that might hurt is that lib_generic/vsprintf.c reinvents
do_div() without the out-of-line __div_64_32() bit. Converting it to
use do_div() from include/div64.h should help.

In fact, enabling CFG_64BIT_VSPRINTF unconditionally without fixing
this first will probably break all architectures that don't link with
libgcc.

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


Re: [U-Boot] CFG_64BIT_xxx and friends

2008-09-08 Thread Matthias Fuchs
Here is the U-Boot size for the PLU405 board (405EP-based) with
and without

#define CFG_64BIT_VSPRINTF
#define CFG_64BIT_STRTOUL
.

without:
# ppc_4xx-size u-boot
   textdata bss dec hex filename
 289568   17532  301312  608412   9489c u-boot

with 64bit format handling:
# ppc_4xx-size u-boot
   textdata bss dec hex filename
 291368   17532  301312  610212   94fa4 u-boot

So the difference is 1800 bytes on this architecture.

Matthias

On Monday 08 September 2008 13:00, Haavard Skinnemoen wrote:
> Stefan Roese <[EMAIL PROTECTED]> wrote:
> > > Seriously: How much of code size are we talking about? And activating
> > > / deactivation the feature is  not  so  trivial  as  it  affects  the
> > > printf() format specifiers we have to use.  
> > 
> > I'm with Wolfgang here and think it would be best to unconditionally 
> > support 
> > the 64bit printf format too.
> 
> Would be nice to see some numbers first though. I suspect there won't
> be much difference, but it could be the printf() implementation does
> something stupid, and it's much easier to tell when the config symbol
> is still in place.
> 
> Haavard
> 
> 
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] CFG_64BIT_xxx and friends

2008-09-08 Thread Haavard Skinnemoen
Stefan Roese <[EMAIL PROTECTED]> wrote:
> > Seriously: How much of code size are we talking about? And activating
> > / deactivation the feature is  not  so  trivial  as  it  affects  the
> > printf() format specifiers we have to use.  
> 
> I'm with Wolfgang here and think it would be best to unconditionally support 
> the 64bit printf format too.

Would be nice to see some numbers first though. I suspect there won't
be much difference, but it could be the printf() implementation does
something stupid, and it's much easier to tell when the config symbol
is still in place.

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


Re: [U-Boot] [PATCH] [UPDATE #2] Merged serial_pl010.c and serial_pl011.c.

2008-09-08 Thread Wolfgang Denk
Dear Andreas Engel,

In message <[EMAIL PROTECTED]> you wrote:
> Jean-Christophe PLAGNIOL-VILLARD wrote:
> > On 10:17 Mon 08 Sep , Andreas Engel wrote:
> >> [...]
> >>
> >> -#ifdef CFG_PL010_SERIAL
> >> +#if defined(CFG_PL010_SERIAL) || defined(CFG_PL011_SERIAL)
> > Please move this to the Makefile
> 
> Shouldn't this better be a separate patch?

Yes, indeed.

Thanks in advance.

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: [EMAIL PROTECTED]
You have the capacity to learn from  mistakes.  You'll  learn  a  lot
today.
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH] [UPDATE #2] Merged serial_pl010.c and serial_pl011.c.

2008-09-08 Thread Andreas Engel
Jean-Christophe PLAGNIOL-VILLARD wrote:
> On 10:17 Mon 08 Sep , Andreas Engel wrote:
>> [...]
>>
>> -#ifdef CFG_PL010_SERIAL
>> +#if defined(CFG_PL010_SERIAL) || defined(CFG_PL011_SERIAL)
> Please move this to the Makefile

Shouldn't this better be a separate patch?

Regards,
  Andreas

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


Re: [U-Boot] [PATCH] [UPDATE #2] Merged serial_pl010.c and serial_pl011.c.

2008-09-08 Thread Jean-Christophe PLAGNIOL-VILLARD
On 10:17 Mon 08 Sep , Andreas Engel wrote:
> They only differ in the init function.
> This also adds the missing watchdog support for the PL011.
> 
> Signed-off-by: Andreas Engel <[EMAIL PROTECTED]>
> ---
> 
>  Updated patch to the current git head as of today.
> 
>  drivers/serial/Makefile   |3 +-
>  drivers/serial/serial_pl011.c |  161 
> -
>  drivers/serial/{serial_pl010.c => serial_pl01x.c} |   83 +--
>  drivers/serial/{serial_pl011.h => serial_pl01x.h} |0
>  4 files changed, 69 insertions(+), 178 deletions(-)
>  delete mode 100644 drivers/serial/serial_pl011.c
>  rename drivers/serial/{serial_pl010.c => serial_pl01x.c} (66%)
>  rename drivers/serial/{serial_pl011.h => serial_pl01x.h} (100%)
> 
> diff --git a/drivers/serial/Makefile b/drivers/serial/Makefile
> index f30014d..3cc1999 100644
> --- a/drivers/serial/Makefile
> +++ b/drivers/serial/Makefile
> @@ -33,8 +33,7 @@ COBJS-$(CONFIG_DRIVER_S3C4510_UART) += s3c4510b_uart.o
>  COBJS-$(CONFIG_S3C64XX) += s3c64xx.o
>  COBJS-y += serial.o
>  COBJS-$(CONFIG_MAX3100_SERIAL) += serial_max3100.o
> -COBJS-y += serial_pl010.o
> -COBJS-y += serial_pl011.o
> +COBJS-y += serial_pl01x.o
>  COBJS-$(CONFIG_XILINX_UARTLITE) += serial_xuartlite.o
>  COBJS-$(CONFIG_SCIF_CONSOLE) += serial_sh.o
>  COBJS-$(CONFIG_USB_TTY) += usbtty.o
> diff --git a/drivers/serial/serial_pl011.c b/drivers/serial/serial_pl011.c
> deleted file mode 100644
> index 4d35fe5..000
> --- a/drivers/serial/serial_pl011.c
> +++ /dev/null
> @@ -1,161 +0,0 @@
> -/*
> - * (C) Copyright 2000
> - * Rob Taylor, Flying Pig Systems. [EMAIL PROTECTED]
> - *
> - * (C) Copyright 2004
> - * ARM Ltd.
> - * Philippe Robin, <[EMAIL PROTECTED]>
> - *
> - * 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.
> +++ b/drivers/serial/serial_pl01x.c
> @@ -31,24 +31,28 @@
>  #include 
>  #include 
> 
> -#ifdef CFG_PL010_SERIAL
> +#if defined(CFG_PL010_SERIAL) || defined(CFG_PL011_SERIAL)
Please move this to the Makefile

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


[U-Boot] NET: Updated SMSC LAN9x1x EEPROM program?

2008-09-08 Thread Magnus Lilja
Hi


Is there an up to date smsc9111x_eeprom.c floating around somewhere? I
found Mike Frysinger's post from March '08 but it needs updating to
compile and work with current mainline U-boot, has anyone already done
this?

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


Re: [U-Boot] [PATCH 1/3] ppc4xx: Update CPCI405 variants handling

2008-09-08 Thread Stefan Roese
On Friday 05 September 2008, [EMAIL PROTECTED] wrote:
> From: Matthias Fuchs <[EMAIL PROTECTED]>
>
> This patch replaces the BOARD_REVISION variable in include/config.mk
> by a using a temporary include file in the platform directory.
>
> The former way does not work anymore and the latter is alos used by
> some other boards.

Applied to u-boot-ppc4xx (all 3 patches from this series). Thanks.

Best regards,
Stefan

=
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-0 Fax: +49-8142-66989-80  Email: [EMAIL PROTECTED]
=
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


[U-Boot] [PATCH RFC] mpc8572ds relocatable

2008-09-08 Thread Ed Swarthout
Fixes boot crash from bad string pointers in get_table_entry_name
when flash is erased or differs from current u-boot image.

Signed-off-by: Ed Swarthout <[EMAIL PROTECTED]>
---

Fix was pointed out by Peter Tyser in Image.c get_table_entry_name thread.

This redoes Grant Likey's relocation change, but leaves control to each board.
This also fixes the "mii dump" command when flash is erased.
Tested with gcc 4.2

 board/freescale/mpc8572ds/config.mk  |1 +
 board/freescale/mpc8572ds/u-boot.lds |2 +-
 2 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/board/freescale/mpc8572ds/config.mk 
b/board/freescale/mpc8572ds/config.mk
index 5b32186..8b3651b 100644
--- a/board/freescale/mpc8572ds/config.mk
+++ b/board/freescale/mpc8572ds/config.mk
@@ -30,3 +30,4 @@ endif
 PLATFORM_CPPFLAGS += -DCONFIG_E500=1
 PLATFORM_CPPFLAGS += -DCONFIG_MPC85xx=1
 PLATFORM_CPPFLAGS += -DCONFIG_MPC8572=1
+PLATFORM_CPPFLAGS += -mrelocatable -DCONFIG_RELOC_FIXUP_WORKS
diff --git a/board/freescale/mpc8572ds/u-boot.lds 
b/board/freescale/mpc8572ds/u-boot.lds
index a05ece5..79fb41f 100644
--- a/board/freescale/mpc8572ds/u-boot.lds
+++ b/board/freescale/mpc8572ds/u-boot.lds
@@ -58,7 +58,7 @@ SECTIONS
   .text  :
   {
 *(.text)
-*(.fixup)
+/*  *(.fixup)*/
 *(.got1)
} :text
 _etext = .;
-- 
1.5.6.5

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


  1   2   >