[PATCHv2] staging: pi433: pi433_write fixed the return value

Oliver Graute oliver.graute at gmail.com
Tue Dec 19 19:58:31 UTC 2017


The pi433_write function should return the number of processed bytes

Reported-by: Marcin Ciupak <marcin.s.ciupak at gmail.com>
Signed-off-by: Oliver Graute <oliver.graute at gmail.com>
---
Changes in v2:

	- added Reported-By Tag

 drivers/staging/pi433/pi433_if.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/staging/pi433/pi433_if.c b/drivers/staging/pi433/pi433_if.c
index 1f3ba55..109b9ea 100644
--- a/drivers/staging/pi433/pi433_if.c
+++ b/drivers/staging/pi433/pi433_if.c
@@ -845,7 +845,7 @@ static irqreturn_t DIO1_irq_handler(int irq, void *dev_id)
 	wake_up_interruptible(&device->tx_wait_queue);
 	dev_dbg(device->dev, "write: generated new msg with %d bytes.", copied);
 
-	return 0;
+	return copied;
 
 abort:
 	dev_dbg(device->dev, "write to fifo failed: 0x%x", retval);
-- 
1.9.1



More information about the devel mailing list