mptcp: remove mptcp_read_actor
Only used to discard stale data from the subflow, so move it where needed. Signed-off-by: Florian Westphal <fw@strlen.de> Reviewed-by: Mat Martineau <mathew.j.martineau@linux.intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:

committed by
David S. Miller

parent
600911ff5f
commit
bfae9dae44
@@ -430,33 +430,6 @@ fallback:
|
||||
return ret;
|
||||
}
|
||||
|
||||
int mptcp_read_actor(read_descriptor_t *desc, struct sk_buff *skb,
|
||||
unsigned int offset, size_t len)
|
||||
{
|
||||
struct mptcp_read_arg *arg = desc->arg.data;
|
||||
size_t copy_len;
|
||||
|
||||
copy_len = min(desc->count, len);
|
||||
|
||||
if (likely(arg->msg)) {
|
||||
int err;
|
||||
|
||||
err = skb_copy_datagram_msg(skb, offset, arg->msg, copy_len);
|
||||
if (err) {
|
||||
pr_debug("error path");
|
||||
desc->error = err;
|
||||
return err;
|
||||
}
|
||||
} else {
|
||||
pr_debug("Flushing skb payload");
|
||||
}
|
||||
|
||||
desc->count -= copy_len;
|
||||
|
||||
pr_debug("consumed %zu bytes, %zu left", copy_len, desc->count);
|
||||
return copy_len;
|
||||
}
|
||||
|
||||
static void mptcp_wait_data(struct sock *sk, long *timeo)
|
||||
{
|
||||
DEFINE_WAIT_FUNC(wait, woken_wake_function);
|
||||
|
Reference in New Issue
Block a user