diff options
author | Zhi Yong Wu <wuzhy@linux.vnet.ibm.com> | 2013-12-06 14:16:50 +0800 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2013-12-06 12:42:14 -0500 |
commit | e6ebc7f16ca1434a334647aa56399c546be4e64b (patch) | |
tree | efd351267b1d78e3fb8afd6380827078f1c45e7f | |
parent | 239c78db9c41a8f524cce60507440d72229d73bc (diff) | |
download | op-kernel-dev-e6ebc7f16ca1434a334647aa56399c546be4e64b.zip op-kernel-dev-e6ebc7f16ca1434a334647aa56399c546be4e64b.tar.gz |
macvtap: update file current position
Signed-off-by: Zhi Yong Wu <wuzhy@linux.vnet.ibm.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r-- | drivers/net/macvtap.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/net/macvtap.c b/drivers/net/macvtap.c index 9093004..957cc5c 100644 --- a/drivers/net/macvtap.c +++ b/drivers/net/macvtap.c @@ -876,6 +876,8 @@ static ssize_t macvtap_aio_read(struct kiocb *iocb, const struct iovec *iv, ret = macvtap_do_read(q, iocb, iv, len, file->f_flags & O_NONBLOCK); ret = min_t(ssize_t, ret, len); /* XXX copied from tun.c. Why? */ + if (ret > 0) + iocb->ki_pos = ret; out: return ret; } |