diff options
Diffstat (limited to 'net/rxrpc/sendmsg.c')
-rw-r--r-- | net/rxrpc/sendmsg.c | 21 |
1 files changed, 12 insertions, 9 deletions
diff --git a/net/rxrpc/sendmsg.c b/net/rxrpc/sendmsg.c index 46c9312085b1..bec64deb7b0a 100644 --- a/net/rxrpc/sendmsg.c +++ b/net/rxrpc/sendmsg.c | |||
@@ -152,12 +152,13 @@ static void rxrpc_notify_end_tx(struct rxrpc_sock *rx, struct rxrpc_call *call, | |||
152 | } | 152 | } |
153 | 153 | ||
154 | /* | 154 | /* |
155 | * Queue a DATA packet for transmission, set the resend timeout and send the | 155 | * Queue a DATA packet for transmission, set the resend timeout and send |
156 | * packet immediately | 156 | * the packet immediately. Returns the error from rxrpc_send_data_packet() |
157 | * in case the caller wants to do something with it. | ||
157 | */ | 158 | */ |
158 | static void rxrpc_queue_packet(struct rxrpc_sock *rx, struct rxrpc_call *call, | 159 | static int rxrpc_queue_packet(struct rxrpc_sock *rx, struct rxrpc_call *call, |
159 | struct sk_buff *skb, bool last, | 160 | struct sk_buff *skb, bool last, |
160 | rxrpc_notify_end_tx_t notify_end_tx) | 161 | rxrpc_notify_end_tx_t notify_end_tx) |
161 | { | 162 | { |
162 | struct rxrpc_skb_priv *sp = rxrpc_skb(skb); | 163 | struct rxrpc_skb_priv *sp = rxrpc_skb(skb); |
163 | unsigned long now; | 164 | unsigned long now; |
@@ -250,7 +251,8 @@ static void rxrpc_queue_packet(struct rxrpc_sock *rx, struct rxrpc_call *call, | |||
250 | 251 | ||
251 | out: | 252 | out: |
252 | rxrpc_free_skb(skb, rxrpc_skb_tx_freed); | 253 | rxrpc_free_skb(skb, rxrpc_skb_tx_freed); |
253 | _leave(""); | 254 | _leave(" = %d", ret); |
255 | return ret; | ||
254 | } | 256 | } |
255 | 257 | ||
256 | /* | 258 | /* |
@@ -423,9 +425,10 @@ static int rxrpc_send_data(struct rxrpc_sock *rx, | |||
423 | if (ret < 0) | 425 | if (ret < 0) |
424 | goto out; | 426 | goto out; |
425 | 427 | ||
426 | rxrpc_queue_packet(rx, call, skb, | 428 | ret = rxrpc_queue_packet(rx, call, skb, |
427 | !msg_data_left(msg) && !more, | 429 | !msg_data_left(msg) && !more, |
428 | notify_end_tx); | 430 | notify_end_tx); |
431 | /* Should check for failure here */ | ||
429 | skb = NULL; | 432 | skb = NULL; |
430 | } | 433 | } |
431 | } while (msg_data_left(msg) > 0); | 434 | } while (msg_data_left(msg) > 0); |