Skip to contentSkip to conversation

powerpc/83xx: Fix build issue with ve8313 board due to lbus changes

PATCH New Kumar Gala 3 participants 7 messages Aug 19, 2010 – Aug 20, 2010

Subsystems (2)
lore
Share & tools
lore

Kumar Gala

author
#0 lore raw

PATCH 1/1 powerpc/83xx: Fix build issue with ve8313 board due to lbus changes

We get two build errors:

fsl_elbc_nand.c: In function 'fsl_elbc_run_command':
fsl_elbc_nand.c:231: error: 'fsl_lbc_t' has no member named 'lsor' make[1]: *** [/work/wd/tmp-ppc/drivers/mtd/nand/fsl_elbc_nand.o] Error 1

and

ve8313.c: In function 'initdram':
ve8313.c:104: error: expected '=', ',', ';', 'asm' or '__attribute__' before '*' token
ve8313.c:104: error: 'lbc' undeclared (first use in this function) ve8313.c:104: error: (Each undeclared identifier is reported only once ve8313.c:104: error: for each function it appears in.) ve8313.c:104: error: 'immap_t' has no member named 'lbus' make[1]: *** [ve8313.o] Error 1
make: *** [board/ve8313/libve8313.a] Error 2

Due to changes to unifiy local bus struct definitions.

---
 board/ve8313/ve8313.c            |    2 +-
 drivers/mtd/nand/fsl_elbc_nand.c |    4 +++-
 include/configs/ve8313.h         |    1 +
 3 files changed, 5 insertions(+), 2 deletions(-)
board/ve8313/ve8313.c +1 -1
index 8ba1b19..2272ff0 100644
@@ -101,7 +101,7 @@ static long fixed_sdram(void)
 phys_size_t initdram(int board_type)
 {
 	volatile immap_t *im = (volatile immap_t *)CONFIG_SYS_IMMR;
-	volatile fsl_lbus_t *lbc = &im->lbus;
+	volatile fsl_lbc_t *lbc = &im->im_lbc;
 	u32 msize;
 
 	if ((im->sysconf.immrbar & IMMRBAR_BASE_ADDR) != (u32)im)
drivers/mtd/nand/fsl_elbc_nand.c +3 -1
index acdb431..ca61daf 100644
@@ -1,6 +1,6 @@
 /* Freescale Enhanced Local Bus Controller FCM NAND driver
  *
- * Copyright (c) 2006-2008 Freescale Semiconductor
+ * Copyright (c) 2006-2010 Freescale Semiconductor
  *
  * Authors: Nick Spence <[email protected]>,
  *          Scott Wood <[email protected]>
@@ -227,8 +227,10 @@ static int fsl_elbc_run_command(struct mtd_info *mtd)
 	     in_be32(&lbc->fbar), in_be32(&lbc->fpar),
 	     in_be32(&lbc->fbcr), priv->bank);
 
+#ifdef CONFIG_FSL_ELBC
 	/* execute special operation */
 	out_be32(&lbc->lsor, priv->bank);
+#endif
 
 	/* wait for FCM complete flag or timeout */
 	end_tick = usec2ticks(FCM_TIMEOUT_MSECS * 1000) + get_ticks();
include/configs/ve8313.h +1 -0
index 1589913..56d24f9 100644
@@ -39,6 +39,7 @@
 #define CONFIG_VE8313		1
 
 #define CONFIG_PCI		1
+#define CONFIG_FSL_ELBC		1
 
 #define CONFIG_BOARD_EARLY_INIT_F	1
 
Signature · 1 line
1.6.0.6
author Applied
#1 lore raw

PATCH 1/1 powerpc/83xx: Fix build issue with ve8313 board due to lbus changes

Quoted 20 lines · Kumar Gala

We get two build errors:

fsl_elbc_nand.c: In function 'fsl_elbc_run_command':
fsl_elbc_nand.c:231: error: 'fsl_lbc_t' has no member named 'lsor' make[1]: *** [/work/wd/tmp-ppc/drivers/mtd/nand/fsl_elbc_nand.o] Error 1

and

ve8313.c: In function 'initdram':
ve8313.c:104: error: expected '=', ',', ';', 'asm' or '__attribute__' before '*' token
ve8313.c:104: error: 'lbc' undeclared (first use in this function) ve8313.c:104: error: (Each undeclared identifier is reported only once ve8313.c:104: error: for each function it appears in.) ve8313.c:104: error: 'immap_t' has no member named 'lbus' make[1]: *** [ve8313.o] Error 1
make: *** [board/ve8313/libve8313.a] Error 2

Due to changes to unifiy local bus struct definitions.

Quoted 7 lines

---

board/ve8313/ve8313.c            |    2 +-
drivers/mtd/nand/fsl_elbc_nand.c |    4 +++-
include/configs/ve8313.h         |    1 +
3 files changed, 5 insertions(+), 2 deletions(-)

applied

- k

#2 lore raw

PATCH 1/1 powerpc/83xx: Fix build issue with ve8313 board due to lbus changes

In reply to Kumar Gala
Quoted 13 lines · On Thu, 19 Aug 2010 01:50:40 -0500 Kumar Gala <[email protected]> wrote:
drivers/mtd/nand/fsl_elbc_nand.c +1 -1
index acdb431..ca61daf 100644
@@ -1,6 +1,6 @@
 /* Freescale Enhanced Local Bus Controller FCM NAND driver
  *
- * Copyright (c) 2006-2008 Freescale Semiconductor
+ * Copyright (c) 2006-2010 Freescale Semiconductor
  *
  * Authors: Nick Spence <[email protected]>,
  *          Scott Wood <[email protected]>

drivers/mtd/nand/fsl_elbc_nand.c static int fsl_elbc_run_command(struct mtd_info *mtd) · line 233

Quoted 7 lines
drivers/mtd/nand/fsl_elbc_nand.c +2 -0
@@ -227,8 +227,10 @@ static int fsl_elbc_run_command(struct mtd_info *mtd)
 	     in_be32(&lbc->fbar), in_be32(&lbc->fpar),
 	     in_be32(&lbc->fbcr), priv->bank);
 
+#ifdef CONFIG_FSL_ELBC
 	/* execute special operation */
 	out_be32(&lbc->lsor, priv->bank);
+#endif

NACK, if you don't have an ELBC you have no business compiling this file at all. This changes a loud failure to a quiet failure if someone forgets to define this symbol.

-Scott

author
#3 lore raw

PATCH 1/1 powerpc/83xx: Fix build issue with ve8313 board due to lbus changes

Quoted 19 lines · Scott Wood
Quoted 16 lines · On Thu, 19 Aug 2010 01:50:40 -0500 Kumar Gala <[email protected]> wrote:
drivers/mtd/nand/fsl_elbc_nand.c +1 -1
index acdb431..ca61daf 100644
@@ -1,6 +1,6 @@
 /* Freescale Enhanced Local Bus Controller FCM NAND driver
 *
- * Copyright (c) 2006-2008 Freescale Semiconductor
+ * Copyright (c) 2006-2010 Freescale Semiconductor
 *
 * Authors: Nick Spence <[email protected]>,
 *          Scott Wood <[email protected]>
@@ -227,8 +227,10 @@ static int fsl_elbc_run_command(struct mtd_info *mtd)
 	     in_be32(&lbc->fbar), in_be32(&lbc->fpar),
 	     in_be32(&lbc->fbcr), priv->bank);
 
Quoted 8 lines

drivers/mtd/nand/fsl_elbc_nand.c static int fsl_elbc_run_command(struct mtd_info *mtd) · line 233

Quoted 4 lines
drivers/mtd/nand/fsl_elbc_nand.c +2 -0
+#ifdef CONFIG_FSL_ELBC
 	/* execute special operation */
 	out_be32(&lbc->lsor, priv->bank);
+#endif

NACK, if you don't have an ELBC you have no business compiling this file at all. This changes a loud failure to a quiet failure if someone forgets to define this symbol.

Ah, didn't even think about that from the file name, duh!

Will drop the change.

- k

author
#4 lore raw

PATCH v2 1/1 powerpc/83xx: Fix build issue with ve8313 board due to lbus changes

In reply to Kumar Gala

We get two build errors:

fsl_elbc_nand.c: In function 'fsl_elbc_run_command':
fsl_elbc_nand.c:231: error: 'fsl_lbc_t' has no member named 'lsor' make[1]: *** [/work/wd/tmp-ppc/drivers/mtd/nand/fsl_elbc_nand.o] Error 1

and

ve8313.c: In function 'initdram':
ve8313.c:104: error: expected '=', ',', ';', 'asm' or '__attribute__' before '*' token
ve8313.c:104: error: 'lbc' undeclared (first use in this function) ve8313.c:104: error: (Each undeclared identifier is reported only once ve8313.c:104: error: for each function it appears in.) ve8313.c:104: error: 'immap_t' has no member named 'lbus' make[1]: *** [ve8313.o] Error 1
make: *** [board/ve8313/libve8313.a] Error 2

Due to changes to unifiy local bus struct definitions.

---
* Removed change to fsl_elbc_nand.c as Scott points out we shouldn't build this if we aren't already CONFIG_FSL_ELBC.

 board/ve8313/ve8313.c    |    2 +-
 include/configs/ve8313.h |    1 +
 2 files changed, 2 insertions(+), 1 deletions(-)
board/ve8313/ve8313.c +1 -1
index 8ba1b19..2272ff0 100644
@@ -101,7 +101,7 @@ static long fixed_sdram(void)
 phys_size_t initdram(int board_type)
 {
 	volatile immap_t *im = (volatile immap_t *)CONFIG_SYS_IMMR;
-	volatile fsl_lbus_t *lbc = &im->lbus;
+	volatile fsl_lbc_t *lbc = &im->im_lbc;
 	u32 msize;
 
 	if ((im->sysconf.immrbar & IMMRBAR_BASE_ADDR) != (u32)im)
include/configs/ve8313.h +1 -0
index 1589913..56d24f9 100644
@@ -39,6 +39,7 @@
 #define CONFIG_VE8313		1
 
 #define CONFIG_PCI		1
+#define CONFIG_FSL_ELBC		1
 
 #define CONFIG_BOARD_EARLY_INIT_F	1
 
Signature · 1 line
1.6.0.6
#5 lore raw

PATCH v2 1/1 powerpc/83xx: Fix build issue with ve8313 board due to lbus changes

Quoted 18 lines · Kumar Gala

We get two build errors:

fsl_elbc_nand.c: In function 'fsl_elbc_run_command':
fsl_elbc_nand.c:231: error: 'fsl_lbc_t' has no member named 'lsor' make[1]: *** [/work/wd/tmp-ppc/drivers/mtd/nand/fsl_elbc_nand.o] Error 1

and

ve8313.c: In function 'initdram':
ve8313.c:104: error: expected '=', ',', ';', 'asm' or '__attribute__' before '*' token
ve8313.c:104: error: 'lbc' undeclared (first use in this function) ve8313.c:104: error: (Each undeclared identifier is reported only once ve8313.c:104: error: for each function it appears in.) ve8313.c:104: error: 'immap_t' has no member named 'lbus' make[1]: *** [ve8313.o] Error 1
make: *** [board/ve8313/libve8313.a] Error 2

Quoted 4 lines

Due to changes to unifiy local bus struct definitions.

ve8313 wasn't in the tree when I submitted my changes but I think this is the right fix - it looks sane WRT to my LBC code merge. That is, assuming, that ve8313 actually has a FSL_ELBC.

Quoted 40 lines

---
* Removed change to fsl_elbc_nand.c as Scott points out we shouldn't build this if we aren't already CONFIG_FSL_ELBC.

board/ve8313/ve8313.c    |    2 +-
include/configs/ve8313.h |    1 +
2 files changed, 2 insertions(+), 1 deletions(-)
board/ve8313/ve8313.c +1 -1
index 8ba1b19..2272ff0 100644
@@ -101,7 +101,7 @@ static long fixed_sdram(void)
 phys_size_t initdram(int board_type)
 {
 	volatile immap_t *im = (volatile immap_t *)CONFIG_SYS_IMMR;
-	volatile fsl_lbus_t *lbc = &im->lbus;
+	volatile fsl_lbc_t *lbc = &im->im_lbc;
 	u32 msize;
 
 	if ((im->sysconf.immrbar & IMMRBAR_BASE_ADDR) != (u32)im)
include/configs/ve8313.h +1 -0
index 1589913..56d24f9 100644
@@ -39,6 +39,7 @@
 #define CONFIG_VE8313		1
 
 #define CONFIG_PCI		1
+#define CONFIG_FSL_ELBC		1
 
 #define CONFIG_BOARD_EARLY_INIT_F	1
 
Signature · 6 lines
1.6.0.6

_______________________________________________
U-Boot mailing list
U-Boot at lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot
#6 lore raw

PATCH v2 1/1 powerpc/83xx: Fix build issue with ve8313 board due to lbus changes

Quoted 3 lines · On Fri, 20 Aug 2010 11:28:38 -0500 Becky Bruce <[email protected]>…

ve8313 wasn't in the tree when I submitted my changes but I think this is the right fix - it looks sane WRT to my LBC code merge. That is, assuming, that ve8313 actually has a FSL_ELBC.

8313 does have eLBC. It's not a board-level issue.

-Scott