[PATCH 1/2] ubi: cdev->write has to return the bytes read, not 0

Sascha Hauer s.hauer at pengutronix.de
Tue Jul 31 15:45:10 EDT 2012


Signed-off-by: Sascha Hauer <s.hauer at pengutronix.de>
---
 drivers/mtd/ubi/cdev.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/mtd/ubi/cdev.c b/drivers/mtd/ubi/cdev.c
index c99b64d..6b1e432 100644
--- a/drivers/mtd/ubi/cdev.c
+++ b/drivers/mtd/ubi/cdev.c
@@ -78,7 +78,7 @@ static ssize_t ubi_volume_cdev_write(struct cdev* cdev, const void *buf,
 		return err;
 	}
 
-	return err;
+	return size;
 }
 
 static int ubi_volume_cdev_open(struct cdev *cdev, unsigned long flags)
-- 
1.7.10.4




More information about the barebox mailing list