Skip to contentSkip to conversation

drivers/mmc/mmc.c: Fix build warning

PATCH New Anatolij Gustschin 3 participants 3 messages Mar 29, 2012 – Mar 30, 2012 MMC, SD and SDIO

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 drivers/mmc/mmc.c: Fix build warning

Fix:
mmc.c: In function 'mmc_bounce_buffer_start':
mmc.c:132:13: warning: no return statement in function returning non-void [-Wreturn-type]

---
Note: This appears when building with merged u-boot-arm.git master.

 drivers/mmc/mmc.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
drivers/mmc/mmc.c +1 -1
index 74e5fea..e70fa9f 100644
@@ -129,7 +129,7 @@ static void mmc_bounce_buffer_stop(struct mmc_data *backup,
 }
 #else
 static inline int mmc_bounce_buffer_start(struct mmc_data *backup,
-					struct mmc_data *orig) { }
+					struct mmc_data *orig) { return 0; }
 static inline void mmc_bounce_buffer_stop(struct mmc_data *backup,
 					struct mmc_data *orig) { }
 #endif
Signature · 1 line
1.7.7.6
#1 lore raw

PATCH 1/1 drivers/mmc/mmc.c: Fix build warning

Dear Anatolij Gustschin,

Quoted 19 lines

Fix:
mmc.c: In function 'mmc_bounce_buffer_start':
mmc.c:132:13: warning: no return statement in function returning non-void [-Wreturn-type]

---
Note: This appears when building with merged u-boot-arm.git master.

 drivers/mmc/mmc.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
drivers/mmc/mmc.c +0 -0
index 74e5fea..e70fa9f 100644

drivers/mmc/mmc.c static void mmc_bounce_buffer_stop(struct mmc_data · line 135

Quoted 8 lines
drivers/mmc/mmc.c +1 -1
@@ -129,7 +129,7 @@ static void mmc_bounce_buffer_stop(struct mmc_data
 *backup, }
 #else
 static inline int mmc_bounce_buffer_start(struct mmc_data *backup,
-					struct mmc_data *orig) { }
+					struct mmc_data *orig) { return 0; }
 static inline void mmc_bounce_buffer_stop(struct mmc_data *backup,
 					struct mmc_data *orig) { }
 #endif

Dang :/

Best regards,
Marek Vasut

#2 lore raw

PATCH 1/1 drivers/mmc/mmc.c: Fix build warning

In reply to Anatolij Gustschin

Dear Anatolij Gustschin,

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

Fix:
mmc.c: In function 'mmc_bounce_buffer_start':
mmc.c:132:13: warning: no return statement in function returning non-void [-Wreturn-type]

---
Note: This appears when building with merged u-boot-arm.git master.

Applied, thanks.

Albert, Andy: hope this is OK with you.

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
"Morality is one thing.  Ratings are everything."
- A Network 23 executive on "Max Headroom"