diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2014-11-25 01:07:38 +0300 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2014-12-10 00:29:10 +0300 |
commit | 17836394e578b8d6475ecdb309ad1356bbcf37a2 (patch) | |
tree | 0a96321812719cff97012d161bcdf4d47b4740ea /net/bluetooth/l2cap_core.c | |
parent | c0371da6047abd261bc483c744dbc7d81a116172 (diff) | |
download | linux-17836394e578b8d6475ecdb309ad1356bbcf37a2.tar.xz |
first fruits - kill l2cap ->memcpy_fromiovec()
Just use copy_from_iter(). That's what this method is trying to do
in all cases, in a very convoluted fashion.
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'net/bluetooth/l2cap_core.c')
-rw-r--r-- | net/bluetooth/l2cap_core.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/net/bluetooth/l2cap_core.c b/net/bluetooth/l2cap_core.c index 5201d6167acb..1754040d00a8 100644 --- a/net/bluetooth/l2cap_core.c +++ b/net/bluetooth/l2cap_core.c @@ -2096,8 +2096,7 @@ static inline int l2cap_skbuff_fromiovec(struct l2cap_chan *chan, struct sk_buff **frag; int sent = 0; - if (chan->ops->memcpy_fromiovec(chan, skb_put(skb, count), - msg, count)) + if (copy_from_iter(skb_put(skb, count), count, &msg->msg_iter) != count) return -EFAULT; sent += count; @@ -2117,8 +2116,8 @@ static inline int l2cap_skbuff_fromiovec(struct l2cap_chan *chan, *frag = tmp; - if (chan->ops->memcpy_fromiovec(chan, skb_put(*frag, count), - msg, count)) + if (copy_from_iter(skb_put(*frag, count), count, + &msg->msg_iter) != count) return -EFAULT; sent += count; |