All of lore.kernel.org
 help / color / mirror / Atom feed
From: Heiko Schocher <hs@denx.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH] ppc: cleanup compilererrors/warnings
Date: Tue, 24 Mar 2009 11:52:38 +0100	[thread overview]
Message-ID: <49C8BB76.4050607@denx.de> (raw)

Hello Mike,

actual u-boot top of tree builds with warnings/errors for the following
boards:

ads5121 cpci5200 mecp5200 v38b IAD210 MBX MBX860T NX823 RPXClassic debris PN62

following patch solves it for:

ads5121, cpci5200, mecp5200, NX823, debris and PN62

Signed-off-by: Heiko Schocher <hs@denx.de>
---

but for the remaining boards MAKEALL drops the error:
(example for v38b board)

Configuring for v38b board...
v38b.c: In function 'misc_init_r':
v38b.c:234: warning: implicit declaration of function 'eth_putenv_enetaddr'
board/v38b/libv38b.a(v38b.o): In function `misc_init_r':
/home/hs/i2c/u-boot-i2c/board/v38b/v38b.c:234: undefined reference to `eth_putenv_enetaddr'
make: *** [u-boot] Fehler 1
ppc_82xx-size: './u-boot': No such file

I could not find "eth_putenv_enetaddr" in code ...

[hs at pollux u-boot-i2c]$ grep -lr eth_putenv_enetaddr .
./board/RPXClassic/RPXClassic.c
./board/mbx8xx/mbx8xx.c
./board/sandburst/karef/karef.c
./board/sandburst/metrobox/metrobox.c
./board/siemens/IAD210/IAD210.c
./board/v38b/v38b.c
./board/xpedite1k/xpedite1k.c
grep: ./include/asm-ppc/arch: Datei oder Verzeichnis nicht gefunden
grep: ./include/asm/arch: Datei oder Verzeichnis nicht gefunden

Mike can you help?

 board/RPXClassic/RPXClassic.c |    1 +
 board/etin/debris/debris.c    |    1 +
 board/mbx8xx/mbx8xx.c         |    1 +
 board/nx823/nx823.c           |    5 +++--
 board/pn62/pn62.c             |    1 +
 board/siemens/IAD210/IAD210.c |    1 +
 board/sixnet/sixnet.c         |    3 ---
 board/v38b/v38b.c             |    1 +
 common/cmd_elf.c              |    4 ++--
 cpu/mpc512x/cpu.c             |    1 +
 include/configs/MBX860T.h     |    1 +
 11 files changed, 13 insertions(+), 7 deletions(-)

diff --git a/board/RPXClassic/RPXClassic.c b/board/RPXClassic/RPXClassic.c
index 5aa713f..4409066 100644
--- a/board/RPXClassic/RPXClassic.c
+++ b/board/RPXClassic/RPXClassic.c
@@ -30,6 +30,7 @@
 #include <i2c.h>
 #include <config.h>
 #include <mpc8xx.h>
+#include <net.h>

 /* ------------------------------------------------------------------------- */

diff --git a/board/etin/debris/debris.c b/board/etin/debris/debris.c
index a971af3..33efe16 100644
--- a/board/etin/debris/debris.c
+++ b/board/etin/debris/debris.c
@@ -23,6 +23,7 @@

 #include <common.h>
 #include <mpc824x.h>
+#include <net.h>
 #include <pci.h>
 #include <i2c.h>
 #include <netdev.h>
diff --git a/board/mbx8xx/mbx8xx.c b/board/mbx8xx/mbx8xx.c
index a3bf1f7..138d883 100644
--- a/board/mbx8xx/mbx8xx.c
+++ b/board/mbx8xx/mbx8xx.c
@@ -34,6 +34,7 @@
 #include <common.h>
 #include <commproc.h>
 #include <mpc8xx.h>
+#include <net.h>
 #include "dimm.h"
 #include "vpd.h"
 #include "csr.h"
diff --git a/board/nx823/nx823.c b/board/nx823/nx823.c
index 6ec29dc..15bb2d8 100644
--- a/board/nx823/nx823.c
+++ b/board/nx823/nx823.c
@@ -27,6 +27,7 @@
 #include <common.h>
 #include <malloc.h>
 #include <mpc8xx.h>
+#include <net.h>

 DECLARE_GLOBAL_DATA_PTR;

@@ -366,7 +367,7 @@ int misc_init_r (void)
 	char tmp[50];
 	uchar ethaddr[6];
 	bd_t *bd = gd->bd;
-	ulong my_sernum = bd->bi_sernum;
+	ulong *my_sernum = (unsigned long *)&bd->bi_sernum;

 	/* load unique serial number */
 	for (i = 0; i < 8; ++i)
diff --git a/board/pn62/pn62.c b/board/pn62/pn62.c
index 53d7e57..676f8d3 100644
--- a/board/pn62/pn62.c
+++ b/board/pn62/pn62.c
@@ -22,6 +22,7 @@

 #include <common.h>
 #include <mpc824x.h>
+#include <net.h>
 #include <pci.h>
 #include <netdev.h>

diff --git a/board/siemens/IAD210/IAD210.c b/board/siemens/IAD210/IAD210.c
index 67e5c8f..ce861f1 100644
--- a/board/siemens/IAD210/IAD210.c
+++ b/board/siemens/IAD210/IAD210.c
@@ -23,6 +23,7 @@

 #include <common.h>
 #include <mpc8xx.h>
+#include <net.h>
 #include "atm.h"
 #include <i2c.h>

diff --git a/board/sixnet/sixnet.c b/board/sixnet/sixnet.c
index 4fcd84b..6e39b01 100644
--- a/board/sixnet/sixnet.c
+++ b/board/sixnet/sixnet.c
@@ -260,9 +260,6 @@ int misc_init_r (void)
 {
 	volatile immap_t     *immap = (immap_t *)CONFIG_SYS_IMMR;
 	volatile memctl8xx_t *memctl = &immap->im_memctl;
-	char* s;
-	char* e;
-	int reg;
 	bd_t *bd = gd->bd;
 	uchar enetaddr[6];

diff --git a/board/v38b/v38b.c b/board/v38b/v38b.c
index 9e7c1d7..e2bf67c 100644
--- a/board/v38b/v38b.c
+++ b/board/v38b/v38b.c
@@ -26,6 +26,7 @@

 #include <common.h>
 #include <mpc5xxx.h>
+#include <net.h>
 #include <asm/processor.h>


diff --git a/common/cmd_elf.c b/common/cmd_elf.c
index 4a3fff1..83e7589 100644
--- a/common/cmd_elf.c
+++ b/common/cmd_elf.c
@@ -131,11 +131,11 @@ int do_bootvx (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[])

 #if defined(CONFIG_WALNUT)
 	tmp = (char *) CONFIG_SYS_NVRAM_BASE_ADDR + 0x500;
-	eth_getenv_enetaddr("ethaddr", build_buf);
+	eth_getenv_enetaddr("ethaddr", (uchar *)build_buf);
 	memcpy(tmp, &build_buf[3], 3);
 #elif defined(CONFIG_SYS_VXWORKS_MAC_PTR)
 	tmp = (char *) CONFIG_SYS_VXWORKS_MAC_PTR;
-	eth_getenv_enetaddr("ethaddr", build_buf);
+	eth_getenv_enetaddr("ethaddr", (uchar *)build_buf);
 	memcpy(tmp, build_buf, 6);
 #else
 	puts ("## Ethernet MAC address not copied to NV RAM\n");
diff --git a/cpu/mpc512x/cpu.c b/cpu/mpc512x/cpu.c
index be532af..8021bc1 100644
--- a/cpu/mpc512x/cpu.c
+++ b/cpu/mpc512x/cpu.c
@@ -30,6 +30,7 @@
 #include <common.h>
 #include <command.h>
 #include <mpc512x.h>
+#include <net.h>
 #include <netdev.h>
 #include <asm/processor.h>

diff --git a/include/configs/MBX860T.h b/include/configs/MBX860T.h
index 0c28710..afe2383 100644
--- a/include/configs/MBX860T.h
+++ b/include/configs/MBX860T.h
@@ -381,6 +381,7 @@
 */
 #define NR_8259_INTS	0

+#define CONFIG_CMD_NET
 /*
  * MPC8xx CPM Options
  */
-- 
1.6.0.6

-- 
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany

             reply	other threads:[~2009-03-24 10:52 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-03-24 10:52 Heiko Schocher [this message]
2009-03-24 23:41 ` [U-Boot] [PATCH] ppc: cleanup compilererrors/warnings Mike Frysinger
2009-03-25  6:37   ` Heiko Schocher
2009-03-25 22:50     ` Mike Frysinger
2009-03-28 23:16 ` Wolfgang Denk
2009-03-29  0:05   ` Wolfgang Denk

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=49C8BB76.4050607@denx.de \
    --to=hs@denx.de \
    --cc=u-boot@lists.denx.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.