[PATCH 5/9] staging/ccg: initialize ret in functionfs_ready_callback()

Sebastian Andrzej Siewior bigeasy at linutronix.de
Wed Aug 15 19:59:15 UTC 2012


The ret variable is not initialized and therefore random. I guess the
Android compiler is doing this right :P

Cc: devel at driverdev.osuosl.org
Signed-off-by: Sebastian Andrzej Siewior <bigeasy at linutronix.de>
---
 drivers/staging/ccg/ccg.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/staging/ccg/ccg.c b/drivers/staging/ccg/ccg.c
index eadda55..8fb8663 100644
--- a/drivers/staging/ccg/ccg.c
+++ b/drivers/staging/ccg/ccg.c
@@ -226,7 +226,7 @@ static int functionfs_ready_callback(struct ffs_data *ffs)
 		goto done;
 	}
 	ffs_obj->desc_ready = true;
-
+	ret = 0;
 done:
 	mutex_unlock(&_ccg_dev->mutex);
 	return ret;
-- 
1.7.10.4




More information about the devel mailing list