Skip to contentSkip to conversation

sbc8548: Fix cfi flash bank declaration

PATCH New Jean-Christophe PLAGNIOL-VILLARD 6 participants 16 messages Feb 17, 2008 – Feb 22, 2008 Network drivers

lore
Share & tools
lore
#0 lore raw

cover sbc8548: Fix cfi flash bank declaration

include/configs/sbc8548.h +1 -1
index 0a7a904..516203a 100644
@@ -168,7 +168,7 @@
 #define	CFG_OR0_PRELIM		0xff806e65
 #define	CFG_OR6_PRELIM		0xfc006e65
 
-#define CFG_FLASH_BANKS_LIST	{0xff800000, CFG_FLASH_BASE}
+#define CFG_FLASH_BANKS_LIST	{CFG_FLASH_BASE}
 #define CFG_MAX_FLASH_BANKS	1		/* number of banks */
 #define CFG_MAX_FLASH_SECT	128		/* sectors per device */
 #undef	CFG_FLASH_CHECKSUM
Signature · 1 line
1.5.4.1
#1 lore raw

PATCH 1/2 sbc8548: Fix Revision reading and unused variable 'path'

board/sbc8548/sbc8548.c +4 -2
index 65052e6..d57548a 100644
@@ -56,9 +56,10 @@ int checkboard (void)
 {
 	volatile ccsr_gur_t *gur = (void *)(CFG_MPC85xx_GUTS_ADDR);
 	volatile ccsr_local_ecm_t *ecm = (void *)(CFG_MPC85xx_ECM_ADDR);
+	volatile u_char *rev= (void *)CFG_BD_REV;
 
 	printf ("Board: Wind River SBC8548 Rev. 0x%01x\n",
-			(volatile)(*(u_char *)CFG_BD_REV) >> 4);
+			(*rev) >> 4);
 
 	/*
 	 * Initialize local bus.
@@ -533,12 +534,12 @@ void
 ft_pci_setup(void *blob, bd_t *bd)
 {
 	int node, tmp[2];
-	const char *path;
 
 	node = fdt_path_offset(blob, "/aliases");
 	tmp[0] = 0;
 	if (node >= 0) {
 #ifdef CONFIG_PCI1
+		const char *path;
 		path = fdt_getprop(blob, node, "pci0", NULL);
 		if (path) {
 			tmp[1] = pci1_hose.last_busno - pci1_hose.first_busno;
@@ -546,6 +547,7 @@ ft_pci_setup(void *blob, bd_t *bd)
 		}
 #endif
 #ifdef CONFIG_PCIE1
+		const char *path;
 		path = fdt_getprop(blob, node, "pci1", NULL);
 		if (path) {
 			tmp[1] = pcie1_hose.last_busno - pcie1_hose.first_busno;
Signature · 1 line
1.5.4.1
#4 lore raw

PATCH 1/1 mpc86xx: Fix unused variable 'config' and 'immap'

and remove useless CONFIG_DDR_INTERLEAVE

cpu/mpc86xx/spd_sdram.c +6 -4
index e501caf..60a7818 100644
@@ -943,7 +943,7 @@ unsigned int enable_ddr(unsigned int ddr_num)
 	spd_eeprom_t spd1,spd2;
 	volatile ccsr_ddr_t *ddr;
 	unsigned sdram_cfg_1;
-	unsigned char sdram_type, mem_type, config, mod_attr;
+	unsigned char sdram_type, mem_type, mod_attr;
 	unsigned char d_init;
 	unsigned int no_dimm1=0, no_dimm2=0;
 
@@ -1017,6 +1017,10 @@ unsigned int enable_ddr(unsigned int ddr_num)
 		printf("No memory modules found for DDR controller %d!!\n", ddr_num);
 		return 0;
 	} else {
+
+#if defined(CONFIG_DDR_ECC)
+		unsigned char config;
+#endif
 		mem_type = no_dimm2 ? spd1.mem_type : spd2.mem_type;
 
 		/*
@@ -1122,8 +1126,8 @@ spd_sdram(void)
 	int memsize_ddr1_dimm2 = 0;
 	int memsize_ddr1 = 0;
 	unsigned int law_size_ddr1;
-	volatile immap_t *immap = (immap_t *)CFG_IMMR;
 #ifdef CONFIG_DDR_INTERLEAVE
+	volatile immap_t *immap = (immap_t *)CFG_IMMR;
 	volatile ccsr_ddr_t *ddr1 = &immap->im_ddr1;
 #endif
 
@@ -1183,7 +1187,6 @@ spd_sdram(void)
 #endif
 		debug("Interleaved memory size is 0x%08lx\n", memsize_total);
 
-#ifdef	CONFIG_DDR_INTERLEAVE
 #if (CFG_PAGE_INTERLEAVING == 1)
 		printf("Page ");
 #elif (CFG_BANK_INTERLEAVING == 1)
@@ -1193,7 +1196,6 @@ spd_sdram(void)
 #else
 		printf("Cache-line ");
 #endif
-#endif
 		printf("Interleaved");
 		return memsize_total * 1024 * 1024;
 	}  else {
Signature · 1 line
1.5.4.1
#5 lore raw

PATCH 1/1 uli526x: Fix multiple differ in signedness and parentheses around comparison

drivers/net/uli526x.c +5 -5
index 8460f69..d64845f 100644
@@ -32,9 +32,9 @@
 #define ULI5261_DEVICE_ID	0x5261
 #define ULI5263_DEVICE_ID	0x5263
 /* ULi M5261 ID*/
-#define PCI_ULI5261_ID		ULI5261_DEVICE_ID << 16 | ULI_VENDOR_ID
+#define PCI_ULI5261_ID		(ULI5261_DEVICE_ID << 16 | ULI_VENDOR_ID)
 /* ULi M5263 ID*/
-#define PCI_ULI5263_ID		ULI5263_DEVICE_ID << 16 | ULI_VENDOR_ID
+#define PCI_ULI5263_ID		(ULI5263_DEVICE_ID << 16 | ULI_VENDOR_ID)
 
 #define ULI526X_IO_SIZE	0x100
 #define TX_DESC_CNT	0x10		/* Allocated Tx descriptors */
@@ -281,7 +281,7 @@ static int uli526x_init_one(struct eth_device *dev, bd_t *bis)
 	if (db->desc_pool_ptr == NULL)
 		return -1;
 
-	db->buf_pool_ptr = &buf_pool[0];
+	db->buf_pool_ptr = (uchar *)&buf_pool[0];
 	db->buf_pool_dma_ptr = (dma_addr_t)&buf_pool[0];
 	if (db->buf_pool_ptr == NULL)
 		return -1;
@@ -588,7 +588,7 @@ static int uli526x_rx_packet(struct eth_device *dev)
 					__FUNCTION__, i, rxptr->rx_buf_ptr[i]);
 #endif
 
-				NetReceive(rxptr->rx_buf_ptr, rxlen);
+				NetReceive((uchar *)rxptr->rx_buf_ptr, rxlen);
 				uli526x_reuse_buf(rxptr);
 
 			} else {
@@ -656,7 +656,7 @@ static void uli526x_descriptor_init(struct uli526x_board_info *db,
 	tmp_tx_dma = db->first_tx_desc_dma;
 	for (tmp_tx = db->first_tx_desc, i = 0;
 			i < TX_DESC_CNT; i++, tmp_tx++) {
-		tmp_tx->tx_buf_ptr = tmp_buf;
+		tmp_tx->tx_buf_ptr = (char *)tmp_buf;
 		tmp_tx->tdes0 = cpu_to_le32(0);
 		tmp_tx->tdes1 = cpu_to_le32(0x81000000);	/* IC, chain */
 		tmp_tx->tdes2 = cpu_to_le32(tmp_buf_dma);
Signature · 1 line
1.5.4.1
#6 lore raw

PATCH 1/1 uli526x: Fix multiple differ in signedness and parentheses around comparison

Quoted 2 lines · In message <[email protected]> you wrote:

Applied, thanks.

Best regards,

Wolfgang Denk

Signature · 5 lines
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: wd at denx.de
Real programmers can write assembly code in any language.   :-)
                      - Larry Wall in  <[email protected]>
#8 lore raw

PATCH 1/1 mpc86xx: Fix implicit declaration of functions 'init_laws' and 'disable_law'

In reply to Jean-Christophe PLAGNIOL-VILLARD
Quoted 7 lines · Jean-Christophe PLAGNIOL-VILLARD
cpu/mpc86xx/cpu_init.c +0 -0
index ab5906d..0efd855 100644

cpu/mpc86xx/cpu_init.c line 34

Quoted 7 lines
cpu/mpc86xx/cpu_init.c +1 -0
@@ -28,6 +28,7 @@
 
 #include <common.h>
 #include <mpc86xx.h>
+#include <asm/fsl_law.h>
 
 DECLARE_GLOBAL_DATA_PTR;
 

*sigh* That I'll take and apply.

Thanks,
jdl

#9 lore raw

PATCH 1/1 mpc86xx: Fix implicit declaration of functions 'init_laws' and 'disable_law'

Quoted 10 lines · Jon Loeliger
Quoted 9 lines · Jean-Christophe PLAGNIOL-VILLARD

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD
<[email protected]>

cpu/mpc86xx/cpu_init.c +0 -0
index ab5906d..0efd855 100644
@@ -28,6 +28,7 @@
 
Quoted 9 lines

cpu/mpc86xx/cpu_init.c line 34

Quoted 6 lines
cpu/mpc86xx/cpu_init.c +1 -0
 #include <common.h>
 #include <mpc86xx.h>
+#include <asm/fsl_law.h>
 
 DECLARE_GLOBAL_DATA_PTR;
 

*sigh* That I'll take and apply.

My apologies - I somehow missed this in my patch series. I'm not used to the incredibly verbose output from uboot build - warnings don't jump out at you like they do with linux builds.

Thanks for the patch!
-Becky

#10 lore raw

PATCH 1/1 mpc86xx: Fix implicit declaration of functions 'init_laws' and 'disable_law'

Quoted 15 lines · Becky Bruce
Quoted 14 lines · Jon Loeliger
Quoted 13 lines · Jean-Christophe PLAGNIOL-VILLARD

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD
<[email protected]>

cpu/mpc86xx/cpu_init.c +1 -0
index ab5906d..0efd855 100644
@@ -28,6 +28,7 @@
 
 #include <common.h>
 #include <mpc86xx.h>
+#include <asm/fsl_law.h>
 
Quoted 7 lines
Quoted 3 lines

cpu/mpc86xx/cpu_init.c line 33

Quoted 1 line
cpu/mpc86xx/cpu_init.c +0 -0
 DECLARE_GLOBAL_DATA_PTR;

*sigh* That I'll take and apply.

My apologies - I somehow missed this in my patch series. I'm not used to the incredibly verbose output from uboot build - warnings don't jump out at you like they do with linux builds.

"make -s" is your friend (s for silent).

And I'm still waiting for Jon's patches with the build-system rework with Linux style compilation output. :)

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: office at denx.de
=====================================================================

#11 lore raw

PATCH 1/1 mpc86xx: Fix implicit declaration of functions 'init_laws' and 'disable_law'

Quoted 1 line · Stefan Roese
Quoted 1 line

My apologies - I somehow missed this in my patch series.

Me three.

Quoted 5 lines
Quoted 3 lines

I'm not
used to the incredibly verbose output from uboot build - warnings don't jump out at you like they do with linux builds.

"make -s" is your friend (s for silent).

Well, not _really_... :-)

Quoted 1 line

And I'm still waiting for Jon's patches

So am I. Has anyone asked him when we'll get them? :-)

Quoted 2 lines

with the build-system rework with
Linux style compilation output. :)

It's on my list... :-)

jdl

#12 lore raw

PATCH 2/2 mpc86xx: Fix Missing '}' in ft_cpu_setup

In reply to Jean-Christophe PLAGNIOL-VILLARD
Quoted 7 lines · Jean-Christophe PLAGNIOL-VILLARD
cpu/mpc86xx/cpu.c +0 -0
index e1b3c52..230e2b3 100644

cpu/mpc86xx/cpu.c ft_cpu_setup(void *blob, bd_t *bd) · line 331

Quoted 7 lines
cpu/mpc86xx/cpu.c +1 -0
@@ -325,6 +325,7 @@ ft_cpu_setup(void *blob, bd_t *bd)
 	if (p != NULL)
 		memcpy(p, bd->bi_enet3addr, 6);
 #endif
+}
 #endif /* CONFIG_OF_FLAT_TREE */
 
 /*

As Terri Garr would said, "This is a puzzlement."

All that OF_FLAT_TREE stuff should be _gone_!

I'll investigate.

Thanks,
jdl

#13 lore raw

PATCH 2/2 mpc86xx: Fix Missing '}' in ft_cpu_setup

In reply to Jean-Christophe PLAGNIOL-VILLARD
Quoted 7 lines · Jean-Christophe PLAGNIOL-VILLARD
cpu/mpc86xx/cpu.c +0 -0
index e1b3c52..230e2b3 100644

cpu/mpc86xx/cpu.c ft_cpu_setup(void *blob, bd_t *bd) · line 331

Quoted 7 lines
cpu/mpc86xx/cpu.c +1 -0
@@ -325,6 +325,7 @@ ft_cpu_setup(void *blob, bd_t *bd)
 	if (p != NULL)
 		memcpy(p, bd->bi_enet3addr, 6);
 #endif
+}
 #endif /* CONFIG_OF_FLAT_TREE */
 
 /*

OK. We're going to NAK this one, and claim that the real fix is to just trash all that crap inside the CONFIG_OF_FLAT_TREE that should have been ripped out in the first place.

Sorry.

jdl