Skip to contentSkip to conversation

Fix warning in env_nand.c if compiled for DaVinci Schmoogie

PATCH New dirk.behme at googlemail.com 3 participants 3 messages Apr 30, 2008

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Fix warning in env_nand.c if compiled for DaVinci Schmoogie

Fix warnings

nv_nand.c: In function 'saveenv':
env_nand.c:200: warning: passing argument 3 of 'nand_write' from incompatible pointer type env_nand.c: In function 'env_relocate_spec':
env_nand.c:275: warning: passing argument 3 of 'nand_read' from incompatible pointer type

if compiled for davinci_schmoogie_config.

common/env_nand.c +3 -3
Index: uboot_davinci/common/env_nand.c
===================================================================
@@ -102,7 +102,7 @@ uchar env_get_char_spec (int index)
 int env_init(void)
 {
 #if defined(ENV_IS_EMBEDDED)
-	ulong total;
+	size_t total;
 	int crc1_ok = 0, crc2_ok = 0;
 	env_t *tmp_env1, *tmp_env2;
 
@@ -188,7 +188,7 @@ int saveenv(void)
 #else /* ! CFG_ENV_OFFSET_REDUND */
 int saveenv(void)
 {
-	ulong total;
+	size_t total;
 	int ret = 0;
 
 	puts ("Erasing Nand...");
@@ -268,7 +268,7 @@ void env_relocate_spec (void)
 void env_relocate_spec (void)
 {
 #if !defined(ENV_IS_EMBEDDED)
-	ulong total;
+	size_t total;
 	int ret;
 
 	total = CFG_ENV_SIZE;
#1 lore raw

PATCH 1/1 Fix warning in env_nand.c if compiled for DaVinci Schmoogie

On Wed, 30 Apr 2008, dirk.behme at googlemail.com wrote:

Ack by: Sergey Kubushyn <[email protected]>

P.S. Dirk, you were faster than me :)

Quoted 48 lines

Fix warnings

nv_nand.c: In function 'saveenv':
env_nand.c:200: warning: passing argument 3 of 'nand_write' from incompatible pointer type
env_nand.c: In function 'env_relocate_spec':
env_nand.c:275: warning: passing argument 3 of 'nand_read' from incompatible pointer type

if compiled for davinci_schmoogie_config.

Index: uboot_davinci/common/env_nand.c
===================================================================

common/env_nand.c +3 -5
@@ -102,7 +102,7 @@ uchar env_get_char_spec (int index)
 int env_init(void)
 {
 #if defined(ENV_IS_EMBEDDED)
-	ulong total;
+	size_t total;
 	int crc1_ok = 0, crc2_ok = 0;
 	env_t *tmp_env1, *tmp_env2;
 
@@ -188,7 +188,7 @@ int saveenv(void)
 #else /* ! CFG_ENV_OFFSET_REDUND */
 int saveenv(void)
 {
-	ulong total;
+	size_t total;
 	int ret = 0;
 
 	puts ("Erasing Nand...");
@@ -268,7 +268,7 @@ void env_relocate_spec (void)
 void env_relocate_spec (void)
 {
 #if !defined(ENV_IS_EMBEDDED)
-	ulong total;
+	size_t total;
 	int ret;
 
 	total = CFG_ENV_SIZE;
 
------------------------------------------------------------------------
-

This SF.net email is sponsored by the 2008 JavaOne(SM) Conference

Quoted 9 lines

Don't miss this year's exciting event. There's still time to save $100. Use priority code J8TL2D2.
http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/j
avaone
_______________________________________________
U-Boot-Users mailing list
U-Boot-Users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/u-boot-users

---
******************************************************************
* KSI at home KOI8 Net < > The impossible we do immediately. *
* Las Vegas NV, USA < > Miracles require 24-hour notice. *
******************************************************************

#2 lore raw

PATCH 1/1 Fix warning in env_nand.c if compiled for DaVinci Schmoogie

In reply to dirk.behme at googlemail.com
Quoted 10 lines · In message <[email protected]> you wrote:

Fix warnings

nv_nand.c: In function 'saveenv':
env_nand.c:200: warning: passing argument 3 of 'nand_write' from incompatible pointer type env_nand.c: In function 'env_relocate_spec':
env_nand.c:275: warning: passing argument 3 of 'nand_read' from incompatible pointer type

if compiled for davinci_schmoogie_config.

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
A morsel of genuine history is a  thing  so  rare  as  to  be  always
valuable.                                          - Thomas Jefferson