[PATCH] AF_RXRPC: Return the number of bytes buffered in rxrpc_send_data()

Subsystems: networking [general], rxrpc sockets (af_rxrpc), the rest

STALE6995d

2 messages, 2 authors, 2007-06-19 · open the first message on its own page

[PATCH] AF_RXRPC: Return the number of bytes buffered in rxrpc_send_data()

From: David Howells <dhowells@redhat.com>
Date: 2007-06-18 11:54:19

Return the number of bytes buffered in rxrpc_send_data().

Signed-off-by: David Howells <dhowells@redhat.com>
---

 net/rxrpc/ar-output.c |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)
diff --git a/net/rxrpc/ar-output.c b/net/rxrpc/ar-output.c
index 591c442..cc9102c 100644
--- a/net/rxrpc/ar-output.c
+++ b/net/rxrpc/ar-output.c
@@ -640,6 +640,7 @@ static int rxrpc_send_data(struct kiocb *iocb,
 			goto efault;
 		sp->remain -= copy;
 		skb->mark += copy;
+		copied += copy;
 
 		len -= copy;
 		segment -= copy;
@@ -709,6 +710,8 @@ static int rxrpc_send_data(struct kiocb *iocb,
 
 	} while (segment > 0);
 
+success:
+	ret = copied;
 out:
 	call->tx_pending = skb;
 	_leave(" = %d", ret);
@@ -725,7 +728,7 @@ call_aborted:
 
 maybe_error:
 	if (copied)
-		ret = copied;
+		goto success;
 	goto out;
 
 efault:

Re: [PATCH] AF_RXRPC: Return the number of bytes buffered in rxrpc_send_data()

From: David Miller <davem@davemloft.net>
Date: 2007-06-19 06:30:50

From: David Howells <dhowells@redhat.com>
Date: Mon, 18 Jun 2007 12:52:36 +0100
Return the number of bytes buffered in rxrpc_send_data().

Signed-off-by: David Howells <dhowells@redhat.com>
Patch applied, thanks a lot David.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help