All of lore.kernel.org
 help / color / mirror / Atom feed
* [U-Boot] [PATCH 1/7] arch/arm/lib/board.c: fix warning: variable ... set but not used
@ 2011-10-05 21:17 Wolfgang Denk
  2011-10-05 21:17 ` [U-Boot] [PATCH 2/7] CFI: " Wolfgang Denk
                   ` (7 more replies)
  0 siblings, 8 replies; 21+ messages in thread
From: Wolfgang Denk @ 2011-10-05 21:17 UTC (permalink / raw)
  To: u-boot

Fix:
board.c:445:8: warning: variable 'bd' set but not used [-Wunused-but-set-variable]

Signed-off-by: Wolfgang Denk <wd@denx.de>
Cc: Albert ARIBAUD <albert.u.boot@aribaud.net>
---
 arch/arm/lib/board.c |    2 --
 1 files changed, 0 insertions(+), 2 deletions(-)

diff --git a/arch/arm/lib/board.c b/arch/arm/lib/board.c
index 705d4d2..b266f78 100644
--- a/arch/arm/lib/board.c
+++ b/arch/arm/lib/board.c
@@ -442,14 +442,12 @@ static char *failed = "*** failed ***\n";
 void board_init_r(gd_t *id, ulong dest_addr)
 {
 	char *s;
-	bd_t *bd;
 	ulong malloc_start;
 #if !defined(CONFIG_SYS_NO_FLASH)
 	ulong flash_size;
 #endif
 
 	gd = id;
-	bd = gd->bd;
 
 	gd->flags |= GD_FLG_RELOC;	/* tell others: relocation done */
 
-- 
1.7.6.2

^ permalink raw reply related	[flat|nested] 21+ messages in thread

* [U-Boot] [PATCH 2/7] CFI: fix warning: variable ... set but not used
  2011-10-05 21:17 [U-Boot] [PATCH 1/7] arch/arm/lib/board.c: fix warning: variable ... set but not used Wolfgang Denk
@ 2011-10-05 21:17 ` Wolfgang Denk
  2011-10-06  5:54   ` Stefan Roese
  2011-10-09 20:41   ` Wolfgang Denk
  2011-10-05 21:17 ` [U-Boot] [PATCH 3/7] fs/jffs2/jffs2_1pass.c: " Wolfgang Denk
                   ` (6 subsequent siblings)
  7 siblings, 2 replies; 21+ messages in thread
From: Wolfgang Denk @ 2011-10-05 21:17 UTC (permalink / raw)
  To: u-boot

Fix:
cfi_mtd.c: In function 'cfi_mtd_init':
cfi_mtd.c:226:19: warning: variable 'mtd_list' set but not used [-Wunused-but-set-variable]
cfi_mtd.c: In function 'cfi_mtd_init':
cfi_mtd.c:226:19: warning: variable 'mtd_list' set but not used [-Wunused-but-set-variable]

Signed-off-by: Wolfgang Denk <wd@denx.de>
Cc: Stefan Roese <sr@denx.de>
---
 common/cmd_mtdparts.c |    9 +++++++--
 drivers/mtd/cfi_mtd.c |    4 ++++
 2 files changed, 11 insertions(+), 2 deletions(-)

diff --git a/common/cmd_mtdparts.c b/common/cmd_mtdparts.c
index 5481c88..2c2e4e0 100644
--- a/common/cmd_mtdparts.c
+++ b/common/cmd_mtdparts.c
@@ -838,7 +838,10 @@ static int device_parse(const char *const mtd_dev, const char **ret, struct mtd_
 	struct mtdids *id;
 	const char *mtd_id;
 	unsigned int mtd_id_len;
-	const char *p, *pend;
+	const char *p;
+#ifdef DEBUG
+	const char *pend;
+#endif
 	LIST_HEAD(tmp_list);
 	struct list_head *entry, *n;
 	u16 num_parts;
@@ -868,10 +871,12 @@ static int device_parse(const char *const mtd_dev, const char **ret, struct mtd_
 		return 1;
 	}
 
+#ifdef DEBUG
+	pend = strchr(p, ';');
+#endif
 	debug("dev type = %d (%s), dev num = %d, mtd-id = %s\n",
 			id->type, MTD_DEV_TYPE(id->type),
 			id->num, id->mtd_id);
-	pend = strchr(p, ';');
 	debug("parsing partitions %.*s\n", (pend ? pend - p : strlen(p)), p);
 
 
diff --git a/drivers/mtd/cfi_mtd.c b/drivers/mtd/cfi_mtd.c
index cbcc165..7796c4c 100644
--- a/drivers/mtd/cfi_mtd.c
+++ b/drivers/mtd/cfi_mtd.c
@@ -223,7 +223,9 @@ int cfi_mtd_init(void)
 	flash_info_t *fi;
 	int error, i;
 	int devices_found = 0;
+#ifdef CONFIG_MTD_CONCAT
 	struct mtd_info *mtd_list[CONFIG_SYS_MAX_FLASH_BANKS];
+#endif
 
 	for (i = 0; i < CONFIG_SYS_MAX_FLASH_BANKS; i++) {
 		fi = &flash_info[i];
@@ -253,7 +255,9 @@ int cfi_mtd_init(void)
 		if (add_mtd_device(mtd))
 			return -ENOMEM;
 
+#ifdef CONFIG_MTD_CONCAT
 		mtd_list[devices_found++] = mtd;
+#endif
 	}
 
 #ifdef CONFIG_MTD_CONCAT
-- 
1.7.6.2

^ permalink raw reply related	[flat|nested] 21+ messages in thread

* [U-Boot] [PATCH 3/7] fs/jffs2/jffs2_1pass.c: fix warning: variable ... set but not used
  2011-10-05 21:17 [U-Boot] [PATCH 1/7] arch/arm/lib/board.c: fix warning: variable ... set but not used Wolfgang Denk
  2011-10-05 21:17 ` [U-Boot] [PATCH 2/7] CFI: " Wolfgang Denk
@ 2011-10-05 21:17 ` Wolfgang Denk
  2011-10-09 20:41   ` Wolfgang Denk
  2011-10-05 21:17 ` [U-Boot] [PATCH 4/7] drivers/net/smc91111.c: " Wolfgang Denk
                   ` (5 subsequent siblings)
  7 siblings, 1 reply; 21+ messages in thread
From: Wolfgang Denk @ 2011-10-05 21:17 UTC (permalink / raw)
  To: u-boot

Fix:
jffs2_1pass.c: In function 'jffs2_1pass_read_inode':
jffs2_1pass.c:699:7: warning: variable 'ret' set but not used [-Wunused-but-set-variable]
jffs2_1pass.c: In function 'jffs2_1pass_build_lists':
jffs2_1pass.c:1578:14: warning: variable 'empty_start' set but not used [-Wunused-but-set-variable]

Signed-off-by: Wolfgang Denk <wd@denx.de>
---
 fs/jffs2/jffs2_1pass.c |   14 ++++----------
 1 files changed, 4 insertions(+), 10 deletions(-)

diff --git a/fs/jffs2/jffs2_1pass.c b/fs/jffs2/jffs2_1pass.c
index 5ddc2b9..a0b02e4 100644
--- a/fs/jffs2/jffs2_1pass.c
+++ b/fs/jffs2/jffs2_1pass.c
@@ -696,7 +696,6 @@ jffs2_1pass_read_inode(struct b_lists *pL, u32 inode, char *dest)
 	u32 latestVersion = 0;
 	uchar *lDest;
 	uchar *src;
-	long ret;
 	int i;
 	u32 counter = 0;
 #ifdef CONFIG_SYS_JFFS2_SORT_FRAGMENTS
@@ -768,28 +767,25 @@ jffs2_1pass_read_inode(struct b_lists *pL, u32 inode, char *dest)
 #endif
 				switch (jNode->compr) {
 				case JFFS2_COMPR_NONE:
-					ret = (unsigned long) ldr_memcpy(lDest, src, jNode->dsize);
+					ldr_memcpy(lDest, src, jNode->dsize);
 					break;
 				case JFFS2_COMPR_ZERO:
-					ret = 0;
 					for (i = 0; i < jNode->dsize; i++)
 						*(lDest++) = 0;
 					break;
 				case JFFS2_COMPR_RTIME:
-					ret = 0;
 					rtime_decompress(src, lDest, jNode->csize, jNode->dsize);
 					break;
 				case JFFS2_COMPR_DYNRUBIN:
 					/* this is slow but it works */
-					ret = 0;
 					dynrubin_decompress(src, lDest, jNode->csize, jNode->dsize);
 					break;
 				case JFFS2_COMPR_ZLIB:
-					ret = zlib_decompress(src, lDest, jNode->csize, jNode->dsize);
+					zlib_decompress(src, lDest, jNode->csize, jNode->dsize);
 					break;
 #if defined(CONFIG_JFFS2_LZO)
 				case JFFS2_COMPR_LZO:
-					ret = lzo_decompress(src, lDest, jNode->csize, jNode->dsize);
+					lzo_decompress(src, lDest, jNode->csize, jNode->dsize);
 					break;
 #endif
 				default:
@@ -803,7 +799,6 @@ jffs2_1pass_read_inode(struct b_lists *pL, u32 inode, char *dest)
 
 #if 0
 			putLabeledWord("read_inode: totalSize = ", totalSize);
-			putLabeledWord("read_inode: compr ret = ", ret);
 #endif
 		}
 		counter++;
@@ -1575,9 +1570,8 @@ jffs2_1pass_build_lists(struct part_info * part)
 
 			if (*(uint32_t *)(&buf[ofs-buf_ofs]) == 0xffffffff) {
 				uint32_t inbuf_ofs;
-				uint32_t empty_start, scan_end;
+				uint32_t scan_end;
 
-				empty_start = ofs;
 				ofs += 4;
 				scan_end = min_t(uint32_t, EMPTY_SCAN_SIZE(
 							part->sector_size)/8,
-- 
1.7.6.2

^ permalink raw reply related	[flat|nested] 21+ messages in thread

* [U-Boot] [PATCH 4/7] drivers/net/smc91111.c: fix warning: variable ... set but not used
  2011-10-05 21:17 [U-Boot] [PATCH 1/7] arch/arm/lib/board.c: fix warning: variable ... set but not used Wolfgang Denk
  2011-10-05 21:17 ` [U-Boot] [PATCH 2/7] CFI: " Wolfgang Denk
  2011-10-05 21:17 ` [U-Boot] [PATCH 3/7] fs/jffs2/jffs2_1pass.c: " Wolfgang Denk
@ 2011-10-05 21:17 ` Wolfgang Denk
  2011-10-09 20:42   ` Wolfgang Denk
  2011-10-05 21:17 ` [U-Boot] [PATCH 5/7] common/cmd_usb.c: " Wolfgang Denk
                   ` (4 subsequent siblings)
  7 siblings, 1 reply; 21+ messages in thread
From: Wolfgang Denk @ 2011-10-05 21:17 UTC (permalink / raw)
  To: u-boot

Fix:
smc91111.c: In function 'smc_phy_configure':
smc91111.c:1194:6: warning: variable 'failed' set but not used [-Wunused-but-set-variable]
smc91111.c:1190:7: warning: variable 'phyaddr' set but not used [-Wunused-but-set-variable]

Signed-off-by: Wolfgang Denk <wd@denx.de>
---
 drivers/net/smc91111.c |    8 --------
 1 files changed, 0 insertions(+), 8 deletions(-)

diff --git a/drivers/net/smc91111.c b/drivers/net/smc91111.c
index ba9c67e..9b8236d 100644
--- a/drivers/net/smc91111.c
+++ b/drivers/net/smc91111.c
@@ -1187,18 +1187,12 @@ static void smc_wait_ms(unsigned int ms)
 static void smc_phy_configure (struct eth_device *dev)
 {
 	int timeout;
-	byte phyaddr;
 	word my_phy_caps;	/* My PHY capabilities */
 	word my_ad_caps;	/* My Advertised capabilities */
 	word status = 0;	/*;my status = 0 */
-	int failed = 0;
 
 	PRINTK3 ("%s: smc_program_phy()\n", SMC_DEV_NAME);
 
-
-	/* Get the detected phy address */
-	phyaddr = SMC_PHY_ADDR;
-
 	/* Reset the PHY, setting all other bits to zero */
 	smc_write_phy_register (dev, PHY_CNTL_REG, PHY_CNTL_RST);
 
@@ -1296,13 +1290,11 @@ static void smc_phy_configure (struct eth_device *dev)
 
 	if (timeout < 1) {
 		printf ("%s: PHY auto-negotiate timed out\n", SMC_DEV_NAME);
-		failed = 1;
 	}
 
 	/* Fail if we detected an auto-negotiate remote fault */
 	if (status & PHY_STAT_REM_FLT) {
 		printf ("%s: PHY remote fault detected\n", SMC_DEV_NAME);
-		failed = 1;
 	}
 
 	/* Re-Configure the Receive/Phy Control register */
-- 
1.7.6.2

^ permalink raw reply related	[flat|nested] 21+ messages in thread

* [U-Boot] [PATCH 5/7] common/cmd_usb.c: fix warning: variable ... set but not used
  2011-10-05 21:17 [U-Boot] [PATCH 1/7] arch/arm/lib/board.c: fix warning: variable ... set but not used Wolfgang Denk
                   ` (2 preceding siblings ...)
  2011-10-05 21:17 ` [U-Boot] [PATCH 4/7] drivers/net/smc91111.c: " Wolfgang Denk
@ 2011-10-05 21:17 ` Wolfgang Denk
  2011-10-08 17:55   ` Remy Bohmer
  2011-10-09 20:42   ` Wolfgang Denk
  2011-10-05 21:17 ` [U-Boot] [PATCH 6/7] drivers/usb/host/ohci-hcd.c: " Wolfgang Denk
                   ` (3 subsequent siblings)
  7 siblings, 2 replies; 21+ messages in thread
From: Wolfgang Denk @ 2011-10-05 21:17 UTC (permalink / raw)
  To: u-boot

Fix:
cmd_usb.c: In function 'usb_show_tree_graph':
cmd_usb.c:284:29: warning: variable 'port' set but not used [-Wunused-but-set-variable]

Signed-off-by: Wolfgang Denk <wd@denx.de>
Cc: Remy Bohmer <linux@bohmer.net>
---
 common/cmd_usb.c |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)

diff --git a/common/cmd_usb.c b/common/cmd_usb.c
index cd4d417..8c87265 100644
--- a/common/cmd_usb.c
+++ b/common/cmd_usb.c
@@ -281,7 +281,7 @@ static inline char *portspeed(int speed)
 void usb_show_tree_graph(struct usb_device *dev, char *pre)
 {
 	int i, index;
-	int has_child, last_child, port;
+	int has_child, last_child;
 
 	index = strlen(pre);
 	printf(" %s", pre);
@@ -300,7 +300,6 @@ void usb_show_tree_graph(struct usb_device *dev, char *pre)
 				/* found our pointer, see if we have a
 				 * little sister
 				 */
-				port = i;
 				while (i++ < dev->parent->maxchild) {
 					if (dev->parent->children[i] != NULL) {
 						/* found a sister */
-- 
1.7.6.2

^ permalink raw reply related	[flat|nested] 21+ messages in thread

* [U-Boot] [PATCH 6/7] drivers/usb/host/ohci-hcd.c: fix warning: variable ... set but not used
  2011-10-05 21:17 [U-Boot] [PATCH 1/7] arch/arm/lib/board.c: fix warning: variable ... set but not used Wolfgang Denk
                   ` (3 preceding siblings ...)
  2011-10-05 21:17 ` [U-Boot] [PATCH 5/7] common/cmd_usb.c: " Wolfgang Denk
@ 2011-10-05 21:17 ` Wolfgang Denk
  2011-10-08 17:56   ` Remy Bohmer
  2011-10-09 20:42   ` Wolfgang Denk
  2011-10-05 21:17 ` [U-Boot] [PATCH 7/7] common/usb.c: " Wolfgang Denk
                   ` (2 subsequent siblings)
  7 siblings, 2 replies; 21+ messages in thread
From: Wolfgang Denk @ 2011-10-05 21:17 UTC (permalink / raw)
  To: u-boot

Fix:
ohci-hcd.c: In function 'dl_transfer_length':
ohci-hcd.c:968:8: warning: variable 'tdINFO' set but not used [-Wunused-but-set-variable]

Signed-off-by: Wolfgang Denk <wd@denx.de>
Cc: Remy Bohmer <linux@bohmer.net>
---
 drivers/usb/host/ohci-hcd.c |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)

diff --git a/drivers/usb/host/ohci-hcd.c b/drivers/usb/host/ohci-hcd.c
index bc8bb20..c20d706 100644
--- a/drivers/usb/host/ohci-hcd.c
+++ b/drivers/usb/host/ohci-hcd.c
@@ -965,10 +965,9 @@ static void td_submit_job(struct usb_device *dev, unsigned long pipe,
 
 static void dl_transfer_length(td_t *td)
 {
-	__u32 tdINFO, tdBE, tdCBP;
+	__u32 tdBE, tdCBP;
 	urb_priv_t *lurb_priv = td->ed->purb;
 
-	tdINFO = m32_swap(td->hwINFO);
 	tdBE   = m32_swap(td->hwBE);
 	tdCBP  = m32_swap(td->hwCBP);
 
-- 
1.7.6.2

^ permalink raw reply related	[flat|nested] 21+ messages in thread

* [U-Boot] [PATCH 7/7] common/usb.c: fix warning: variable ... set but not used
  2011-10-05 21:17 [U-Boot] [PATCH 1/7] arch/arm/lib/board.c: fix warning: variable ... set but not used Wolfgang Denk
                   ` (4 preceding siblings ...)
  2011-10-05 21:17 ` [U-Boot] [PATCH 6/7] drivers/usb/host/ohci-hcd.c: " Wolfgang Denk
@ 2011-10-05 21:17 ` Wolfgang Denk
  2011-10-08 17:57   ` Remy Bohmer
  2011-10-09 20:43   ` Wolfgang Denk
  2011-10-07 17:13 ` [U-Boot] [PATCH 1/7] arch/arm/lib/board.c: " Simon Glass
  2011-10-09 20:40 ` Wolfgang Denk
  7 siblings, 2 replies; 21+ messages in thread
From: Wolfgang Denk @ 2011-10-05 21:17 UTC (permalink / raw)
  To: u-boot

Fix:
usb.c: In function 'usb_parse_config':
usb.c:331:17: warning: variable 'ch' set but not used [-Wunused-but-set-variable]
usb.c: In function 'usb_hub_port_connect_change':
usb.c:1123:29: warning: variable 'portchange' set but not used [-Wunused-but-set-variable]
usb.c: In function 'usb_hub_configure':
usb.c:1183:25: warning: variable 'hubsts' set but not used [-Wunused-but-set-variable]

Signed-off-by: Wolfgang Denk <wd@denx.de>
Cc: Remy Bohmer <linux@bohmer.net>
---
 common/usb.c |   20 +++++++++++++-------
 1 files changed, 13 insertions(+), 7 deletions(-)

diff --git a/common/usb.c b/common/usb.c
index a401c09..2cd50db 100644
--- a/common/usb.c
+++ b/common/usb.c
@@ -328,7 +328,6 @@ int usb_parse_config(struct usb_device *dev, unsigned char *buffer, int cfgno)
 	struct usb_descriptor_header *head;
 	int index, ifno, epno, curr_if_num;
 	int i;
-	unsigned char *ch;
 
 	ifno = -1;
 	epno = -1;
@@ -386,7 +385,9 @@ int usb_parse_config(struct usb_device *dev, unsigned char *buffer, int cfgno)
 				   head->bDescriptorType);
 
 			{
-				ch = (unsigned char *)head;
+#ifdef USB_DEBUG
+				unsigned char *ch = (unsigned char *)head;
+#endif
 				for (i = 0; i < head->bLength; i++)
 					USB_PRINTF("%02X ", *ch++);
 				USB_PRINTF("\n\n\n");
@@ -1120,7 +1121,7 @@ void usb_hub_port_connect_change(struct usb_device *dev, int port)
 {
 	struct usb_device *usb;
 	struct usb_port_status portsts;
-	unsigned short portstatus, portchange;
+	unsigned short portstatus;
 
 	/* Check status */
 	if (usb_get_port_status(dev, port + 1, &portsts) < 0) {
@@ -1129,9 +1130,10 @@ void usb_hub_port_connect_change(struct usb_device *dev, int port)
 	}
 
 	portstatus = le16_to_cpu(portsts.wPortStatus);
-	portchange = le16_to_cpu(portsts.wPortChange);
 	USB_HUB_PRINTF("portstatus %x, change %x, %s\n",
-			portstatus, portchange, portspeed(portstatus));
+			portstatus,
+			le16_to_cpu(portsts.wPortChange),
+			portspeed(portstatus));
 
 	/* Clear the connection change status */
 	usb_clear_port_feature(dev, port + 1, USB_PORT_FEAT_C_CONNECTION);
@@ -1178,11 +1180,13 @@ void usb_hub_port_connect_change(struct usb_device *dev, int port)
 
 int usb_hub_configure(struct usb_device *dev)
 {
+	int i;
 	unsigned char buffer[USB_BUFSIZ], *bitmap;
 	struct usb_hub_descriptor *descriptor;
-	struct usb_hub_status *hubsts;
-	int i;
 	struct usb_hub_device *hub;
+#ifdef USB_HUB_DEBUG
+	struct usb_hub_status *hubsts;
+#endif
 
 	/* "allocate" Hub device */
 	hub = usb_hub_allocate();
@@ -1284,7 +1288,9 @@ int usb_hub_configure(struct usb_device *dev)
 		return -1;
 	}
 
+#ifdef USB_HUB_DEBUG
 	hubsts = (struct usb_hub_status *)buffer;
+#endif
 	USB_HUB_PRINTF("get_hub_status returned status %X, change %X\n",
 			le16_to_cpu(hubsts->wHubStatus),
 			le16_to_cpu(hubsts->wHubChange));
-- 
1.7.6.2

^ permalink raw reply related	[flat|nested] 21+ messages in thread

* [U-Boot] [PATCH 2/7] CFI: fix warning: variable ... set but not used
  2011-10-05 21:17 ` [U-Boot] [PATCH 2/7] CFI: " Wolfgang Denk
@ 2011-10-06  5:54   ` Stefan Roese
  2011-10-06  7:55     ` Wolfgang Denk
  2011-10-09 20:41   ` Wolfgang Denk
  1 sibling, 1 reply; 21+ messages in thread
From: Stefan Roese @ 2011-10-06  5:54 UTC (permalink / raw)
  To: u-boot

Hi Wolfgang,

On Wednesday 05 October 2011 23:17:28 Wolfgang Denk wrote:
> Fix:
> cfi_mtd.c: In function 'cfi_mtd_init':
> cfi_mtd.c:226:19: warning: variable 'mtd_list' set but not used
> [-Wunused-but-set-variable] cfi_mtd.c: In function 'cfi_mtd_init':
> cfi_mtd.c:226:19: warning: variable 'mtd_list' set but not used
> [-Wunused-but-set-variable]
>
> Signed-off-by: Wolfgang Denk <wd@denx.de>
> Cc: Stefan Roese <sr@denx.de>

Acked-by: Stefan Roese <sr@denx.de>

Feel free to apply directly if this is easier for you.

Thanks,
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

^ permalink raw reply	[flat|nested] 21+ messages in thread

* [U-Boot] [PATCH 2/7] CFI: fix warning: variable ... set but not used
  2011-10-06  5:54   ` Stefan Roese
@ 2011-10-06  7:55     ` Wolfgang Denk
  0 siblings, 0 replies; 21+ messages in thread
From: Wolfgang Denk @ 2011-10-06  7:55 UTC (permalink / raw)
  To: u-boot

Dear Stefan Roese,

In message <201110060754.18167.sr@denx.de> you wrote:
> 
> Acked-by: Stefan Roese <sr@denx.de>
> 
> Feel free to apply directly if this is easier for you.

Thanks, but actually the patch is incomplete; there is another similar
place that needs fixing, too.

Will send a v2 soon.

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: wd at denx.de
"The lesser of two evils -- is evil."             - Seymour (Sy) Leon

^ permalink raw reply	[flat|nested] 21+ messages in thread

* [U-Boot] [PATCH 1/7] arch/arm/lib/board.c: fix warning: variable ... set but not used
  2011-10-05 21:17 [U-Boot] [PATCH 1/7] arch/arm/lib/board.c: fix warning: variable ... set but not used Wolfgang Denk
                   ` (5 preceding siblings ...)
  2011-10-05 21:17 ` [U-Boot] [PATCH 7/7] common/usb.c: " Wolfgang Denk
@ 2011-10-07 17:13 ` Simon Glass
  2011-10-09 20:51   ` Wolfgang Denk
  2011-10-09 20:40 ` Wolfgang Denk
  7 siblings, 1 reply; 21+ messages in thread
From: Simon Glass @ 2011-10-07 17:13 UTC (permalink / raw)
  To: u-boot

Hi Wolfgang,

On Wed, Oct 5, 2011 at 2:17 PM, Wolfgang Denk <wd@denx.de> wrote:
> Fix:
> board.c:445:8: warning: variable 'bd' set but not used [-Wunused-but-set-variable]
>
> Signed-off-by: Wolfgang Denk <wd@denx.de>
> Cc: Albert ARIBAUD <albert.u.boot@aribaud.net>
> ---
> ?arch/arm/lib/board.c | ? ?2 --
> ?1 files changed, 0 insertions(+), 2 deletions(-)
>
> diff --git a/arch/arm/lib/board.c b/arch/arm/lib/board.c
> index 705d4d2..b266f78 100644
> --- a/arch/arm/lib/board.c
> +++ b/arch/arm/lib/board.c
> @@ -442,14 +442,12 @@ static char *failed = "*** failed ***\n";
> ?void board_init_r(gd_t *id, ulong dest_addr)
> ?{
> ? ? ? ?char *s;
> - ? ? ? bd_t *bd;
> ? ? ? ?ulong malloc_start;
> ?#if !defined(CONFIG_SYS_NO_FLASH)
> ? ? ? ?ulong flash_size;
> ?#endif
>
> ? ? ? ?gd = id;
> - ? ? ? bd = gd->bd;
>
> ? ? ? ?gd->flags |= GD_FLG_RELOC; ? ? ?/* tell others: relocation done */

Sorry if I have missed a mailing list patch, but in my version of the
source there is a line a little lower down which uses bd:

       mmc_initialize(bd);

Of course it can just become gd->bd so there is no problem removing
the variable.

Regards,
Simon

>
> --
> 1.7.6.2
>
> _______________________________________________
> U-Boot mailing list
> U-Boot at lists.denx.de
> http://lists.denx.de/mailman/listinfo/u-boot
>

^ permalink raw reply	[flat|nested] 21+ messages in thread

* [U-Boot] [PATCH 5/7] common/cmd_usb.c: fix warning: variable ... set but not used
  2011-10-05 21:17 ` [U-Boot] [PATCH 5/7] common/cmd_usb.c: " Wolfgang Denk
@ 2011-10-08 17:55   ` Remy Bohmer
  2011-10-09 20:42   ` Wolfgang Denk
  1 sibling, 0 replies; 21+ messages in thread
From: Remy Bohmer @ 2011-10-08 17:55 UTC (permalink / raw)
  To: u-boot

Hi,

2011/10/5 Wolfgang Denk <wd@denx.de>:
> Fix:
> cmd_usb.c: In function 'usb_show_tree_graph':
> cmd_usb.c:284:29: warning: variable 'port' set but not used [-Wunused-but-set-variable]
>
> Signed-off-by: Wolfgang Denk <wd@denx.de>
> Cc: Remy Bohmer <linux@bohmer.net>
> ---
> ?common/cmd_usb.c | ? ?3 +--
> ?1 files changed, 1 insertions(+), 2 deletions(-)
>
Acked-by: Remy Bohmer <linux@bohmer.net>

Kind regards,

Remy

^ permalink raw reply	[flat|nested] 21+ messages in thread

* [U-Boot] [PATCH 6/7] drivers/usb/host/ohci-hcd.c: fix warning: variable ... set but not used
  2011-10-05 21:17 ` [U-Boot] [PATCH 6/7] drivers/usb/host/ohci-hcd.c: " Wolfgang Denk
@ 2011-10-08 17:56   ` Remy Bohmer
  2011-10-09 20:42   ` Wolfgang Denk
  1 sibling, 0 replies; 21+ messages in thread
From: Remy Bohmer @ 2011-10-08 17:56 UTC (permalink / raw)
  To: u-boot

Hi,

2011/10/5 Wolfgang Denk <wd@denx.de>:
> Fix:
> ohci-hcd.c: In function 'dl_transfer_length':
> ohci-hcd.c:968:8: warning: variable 'tdINFO' set but not used [-Wunused-but-set-variable]
>
> Signed-off-by: Wolfgang Denk <wd@denx.de>
> Cc: Remy Bohmer <linux@bohmer.net>
> ---
> ?drivers/usb/host/ohci-hcd.c | ? ?3 +--
> ?1 files changed, 1 insertions(+), 2 deletions(-)
>
Acked-by: Remy Bohmer <linux@bohmer.net>

Kind regards,

Remy

^ permalink raw reply	[flat|nested] 21+ messages in thread

* [U-Boot] [PATCH 7/7] common/usb.c: fix warning: variable ... set but not used
  2011-10-05 21:17 ` [U-Boot] [PATCH 7/7] common/usb.c: " Wolfgang Denk
@ 2011-10-08 17:57   ` Remy Bohmer
  2011-10-09 20:43   ` Wolfgang Denk
  1 sibling, 0 replies; 21+ messages in thread
From: Remy Bohmer @ 2011-10-08 17:57 UTC (permalink / raw)
  To: u-boot

Hi,

2011/10/5 Wolfgang Denk <wd@denx.de>:
> Fix:
> usb.c: In function 'usb_parse_config':
> usb.c:331:17: warning: variable 'ch' set but not used [-Wunused-but-set-variable]
> usb.c: In function 'usb_hub_port_connect_change':
> usb.c:1123:29: warning: variable 'portchange' set but not used [-Wunused-but-set-variable]
> usb.c: In function 'usb_hub_configure':
> usb.c:1183:25: warning: variable 'hubsts' set but not used [-Wunused-but-set-variable]
>
> Signed-off-by: Wolfgang Denk <wd@denx.de>
> Cc: Remy Bohmer <linux@bohmer.net>
> ---
> ?common/usb.c | ? 20 +++++++++++++-------
> ?1 files changed, 13 insertions(+), 7 deletions(-)
>
Acked-by: Remy Bohmer <linux@bohmer.net>

Kind regards,

Remy

^ permalink raw reply	[flat|nested] 21+ messages in thread

* [U-Boot] [PATCH 1/7] arch/arm/lib/board.c: fix warning: variable ... set but not used
  2011-10-05 21:17 [U-Boot] [PATCH 1/7] arch/arm/lib/board.c: fix warning: variable ... set but not used Wolfgang Denk
                   ` (6 preceding siblings ...)
  2011-10-07 17:13 ` [U-Boot] [PATCH 1/7] arch/arm/lib/board.c: " Simon Glass
@ 2011-10-09 20:40 ` Wolfgang Denk
  7 siblings, 0 replies; 21+ messages in thread
From: Wolfgang Denk @ 2011-10-09 20:40 UTC (permalink / raw)
  To: u-boot

Dear Wolfgang Denk,

In message <1317849453-8216-1-git-send-email-wd@denx.de> you wrote:
> Fix:
> board.c:445:8: warning: variable 'bd' set but not used [-Wunused-but-set-variable]
> 
> Signed-off-by: Wolfgang Denk <wd@denx.de>
> Cc: Albert ARIBAUD <albert.u.boot@aribaud.net>
> ---
>  arch/arm/lib/board.c |    2 --
>  1 files changed, 0 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: wd at denx.de
Anyone who knows history, particularly the history of Europe, will, I
think, recognize that the domination of education or of government by
any one particular religious faith is never a happy  arrangement  for
the people.                                       - Eleanor Roosevelt

^ permalink raw reply	[flat|nested] 21+ messages in thread

* [U-Boot] [PATCH 2/7] CFI: fix warning: variable ... set but not used
  2011-10-05 21:17 ` [U-Boot] [PATCH 2/7] CFI: " Wolfgang Denk
  2011-10-06  5:54   ` Stefan Roese
@ 2011-10-09 20:41   ` Wolfgang Denk
  1 sibling, 0 replies; 21+ messages in thread
From: Wolfgang Denk @ 2011-10-09 20:41 UTC (permalink / raw)
  To: u-boot

Dear Wolfgang Denk,

In message <1317849453-8216-2-git-send-email-wd@denx.de> you wrote:
> Fix:
> cfi_mtd.c: In function 'cfi_mtd_init':
> cfi_mtd.c:226:19: warning: variable 'mtd_list' set but not used [-Wunused-but-set-variable]
> cfi_mtd.c: In function 'cfi_mtd_init':
> cfi_mtd.c:226:19: warning: variable 'mtd_list' set but not used [-Wunused-but-set-variable]
> 
> Signed-off-by: Wolfgang Denk <wd@denx.de>
> Cc: Stefan Roese <sr@denx.de>
> ---
>  common/cmd_mtdparts.c |    9 +++++++--
>  drivers/mtd/cfi_mtd.c |    4 ++++
>  2 files changed, 11 insertions(+), 2 deletions(-)

Applied (with changes to fix the other issue, too).

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: wd at denx.de
Is truth not truth for all?
	-- Natira, "For the World is Hollow and I have Touched
		   the Sky", stardate 5476.4.

^ permalink raw reply	[flat|nested] 21+ messages in thread

* [U-Boot] [PATCH 3/7] fs/jffs2/jffs2_1pass.c: fix warning: variable ... set but not used
  2011-10-05 21:17 ` [U-Boot] [PATCH 3/7] fs/jffs2/jffs2_1pass.c: " Wolfgang Denk
@ 2011-10-09 20:41   ` Wolfgang Denk
  0 siblings, 0 replies; 21+ messages in thread
From: Wolfgang Denk @ 2011-10-09 20:41 UTC (permalink / raw)
  To: u-boot

Dear Wolfgang Denk,

In message <1317849453-8216-3-git-send-email-wd@denx.de> you wrote:
> Fix:
> jffs2_1pass.c: In function 'jffs2_1pass_read_inode':
> jffs2_1pass.c:699:7: warning: variable 'ret' set but not used [-Wunused-but-set-variable]
> jffs2_1pass.c: In function 'jffs2_1pass_build_lists':
> jffs2_1pass.c:1578:14: warning: variable 'empty_start' set but not used [-Wunused-but-set-variable]
> 
> Signed-off-by: Wolfgang Denk <wd@denx.de>
> ---
>  fs/jffs2/jffs2_1pass.c |   14 ++++----------
>  1 files changed, 4 insertions(+), 10 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: wd at denx.de
If all you have is a hammer, everything looks like a nail.

^ permalink raw reply	[flat|nested] 21+ messages in thread

* [U-Boot] [PATCH 4/7] drivers/net/smc91111.c: fix warning: variable ... set but not used
  2011-10-05 21:17 ` [U-Boot] [PATCH 4/7] drivers/net/smc91111.c: " Wolfgang Denk
@ 2011-10-09 20:42   ` Wolfgang Denk
  0 siblings, 0 replies; 21+ messages in thread
From: Wolfgang Denk @ 2011-10-09 20:42 UTC (permalink / raw)
  To: u-boot

Dear Wolfgang Denk,

In message <1317849453-8216-4-git-send-email-wd@denx.de> you wrote:
> Fix:
> smc91111.c: In function 'smc_phy_configure':
> smc91111.c:1194:6: warning: variable 'failed' set but not used [-Wunused-but-set-variable]
> smc91111.c:1190:7: warning: variable 'phyaddr' set but not used [-Wunused-but-set-variable]
> 
> Signed-off-by: Wolfgang Denk <wd@denx.de>
> ---
>  drivers/net/smc91111.c |    8 --------
>  1 files changed, 0 insertions(+), 8 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: wd at denx.de
The price of curiosity is a terminal experience.
                         - Terry Pratchett, _The Dark Side of the Sun_

^ permalink raw reply	[flat|nested] 21+ messages in thread

* [U-Boot] [PATCH 5/7] common/cmd_usb.c: fix warning: variable ... set but not used
  2011-10-05 21:17 ` [U-Boot] [PATCH 5/7] common/cmd_usb.c: " Wolfgang Denk
  2011-10-08 17:55   ` Remy Bohmer
@ 2011-10-09 20:42   ` Wolfgang Denk
  1 sibling, 0 replies; 21+ messages in thread
From: Wolfgang Denk @ 2011-10-09 20:42 UTC (permalink / raw)
  To: u-boot

Dear Wolfgang Denk,

In message <1317849453-8216-5-git-send-email-wd@denx.de> you wrote:
> Fix:
> cmd_usb.c: In function 'usb_show_tree_graph':
> cmd_usb.c:284:29: warning: variable 'port' set but not used [-Wunused-but-set-variable]
> 
> Signed-off-by: Wolfgang Denk <wd@denx.de>
> Cc: Remy Bohmer <linux@bohmer.net>
> ---
>  common/cmd_usb.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: wd at denx.de
You are only young once, but you can stay immature indefinitely.

^ permalink raw reply	[flat|nested] 21+ messages in thread

* [U-Boot] [PATCH 6/7] drivers/usb/host/ohci-hcd.c: fix warning: variable ... set but not used
  2011-10-05 21:17 ` [U-Boot] [PATCH 6/7] drivers/usb/host/ohci-hcd.c: " Wolfgang Denk
  2011-10-08 17:56   ` Remy Bohmer
@ 2011-10-09 20:42   ` Wolfgang Denk
  1 sibling, 0 replies; 21+ messages in thread
From: Wolfgang Denk @ 2011-10-09 20:42 UTC (permalink / raw)
  To: u-boot

Dear Wolfgang Denk,

In message <1317849453-8216-6-git-send-email-wd@denx.de> you wrote:
> Fix:
> ohci-hcd.c: In function 'dl_transfer_length':
> ohci-hcd.c:968:8: warning: variable 'tdINFO' set but not used [-Wunused-but-set-variable]
> 
> Signed-off-by: Wolfgang Denk <wd@denx.de>
> Cc: Remy Bohmer <linux@bohmer.net>
> ---
>  drivers/usb/host/ohci-hcd.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: wd at denx.de
The shortest unit of time in the multiverse is the News York  Second,
defined  as  the  period  of  time between the traffic lights turning
green and the cab behind you honking.
                                - Terry Pratchett, _Lords and Ladies_

^ permalink raw reply	[flat|nested] 21+ messages in thread

* [U-Boot] [PATCH 7/7] common/usb.c: fix warning: variable ... set but not used
  2011-10-05 21:17 ` [U-Boot] [PATCH 7/7] common/usb.c: " Wolfgang Denk
  2011-10-08 17:57   ` Remy Bohmer
@ 2011-10-09 20:43   ` Wolfgang Denk
  1 sibling, 0 replies; 21+ messages in thread
From: Wolfgang Denk @ 2011-10-09 20:43 UTC (permalink / raw)
  To: u-boot

Dear Wolfgang Denk,

In message <1317849453-8216-7-git-send-email-wd@denx.de> you wrote:
> Fix:
> usb.c: In function 'usb_parse_config':
> usb.c:331:17: warning: variable 'ch' set but not used [-Wunused-but-set-variable]
> usb.c: In function 'usb_hub_port_connect_change':
> usb.c:1123:29: warning: variable 'portchange' set but not used [-Wunused-but-set-variable]
> usb.c: In function 'usb_hub_configure':
> usb.c:1183:25: warning: variable 'hubsts' set but not used [-Wunused-but-set-variable]
> 
> Signed-off-by: Wolfgang Denk <wd@denx.de>
> Cc: Remy Bohmer <linux@bohmer.net>
> ---
>  common/usb.c |   20 +++++++++++++-------
>  1 files changed, 13 insertions(+), 7 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: wd at denx.de
God may be subtle, but He isn't plain mean.         - Albert Einstein

^ permalink raw reply	[flat|nested] 21+ messages in thread

* [U-Boot] [PATCH 1/7] arch/arm/lib/board.c: fix warning: variable ... set but not used
  2011-10-07 17:13 ` [U-Boot] [PATCH 1/7] arch/arm/lib/board.c: " Simon Glass
@ 2011-10-09 20:51   ` Wolfgang Denk
  0 siblings, 0 replies; 21+ messages in thread
From: Wolfgang Denk @ 2011-10-09 20:51 UTC (permalink / raw)
  To: u-boot

Dear Simon Glass,

In message <CAPnjgZ2okU0d5KzjHJnQar2Zi_8y0Fsp1pSkpCy5GSdeY1iPCg@mail.gmail.com> you wrote:
> 
> Sorry if I have missed a mailing list patch, but in my version of the
> source there is a line a little lower down which uses bd:
> 
>        mmc_initialize(bd);
> 
> Of course it can just become gd->bd so there is no problem removing
> the variable.

You are right - thanks for pointing out.  Fixed when checking in.

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: wd at denx.de
If I don't document something, it's usually either for a good reason,
or a bad reason.  In this case it's a good reason.  :-)
                 - Larry Wall in <1992Jan17.005405.16806@netlabs.com>

^ permalink raw reply	[flat|nested] 21+ messages in thread

end of thread, other threads:[~2011-10-09 20:51 UTC | newest]

Thread overview: 21+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-10-05 21:17 [U-Boot] [PATCH 1/7] arch/arm/lib/board.c: fix warning: variable ... set but not used Wolfgang Denk
2011-10-05 21:17 ` [U-Boot] [PATCH 2/7] CFI: " Wolfgang Denk
2011-10-06  5:54   ` Stefan Roese
2011-10-06  7:55     ` Wolfgang Denk
2011-10-09 20:41   ` Wolfgang Denk
2011-10-05 21:17 ` [U-Boot] [PATCH 3/7] fs/jffs2/jffs2_1pass.c: " Wolfgang Denk
2011-10-09 20:41   ` Wolfgang Denk
2011-10-05 21:17 ` [U-Boot] [PATCH 4/7] drivers/net/smc91111.c: " Wolfgang Denk
2011-10-09 20:42   ` Wolfgang Denk
2011-10-05 21:17 ` [U-Boot] [PATCH 5/7] common/cmd_usb.c: " Wolfgang Denk
2011-10-08 17:55   ` Remy Bohmer
2011-10-09 20:42   ` Wolfgang Denk
2011-10-05 21:17 ` [U-Boot] [PATCH 6/7] drivers/usb/host/ohci-hcd.c: " Wolfgang Denk
2011-10-08 17:56   ` Remy Bohmer
2011-10-09 20:42   ` Wolfgang Denk
2011-10-05 21:17 ` [U-Boot] [PATCH 7/7] common/usb.c: " Wolfgang Denk
2011-10-08 17:57   ` Remy Bohmer
2011-10-09 20:43   ` Wolfgang Denk
2011-10-07 17:13 ` [U-Boot] [PATCH 1/7] arch/arm/lib/board.c: " Simon Glass
2011-10-09 20:51   ` Wolfgang Denk
2011-10-09 20:40 ` Wolfgang Denk

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.