<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux-toradex.git/drivers/vhost, branch v3.10.2</title>
<subtitle>Linux kernel for Apalis and Colibri modules</subtitle>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/'/>
<entry>
<title>vhost: fix ubuf_info cleanup</title>
<updated>2013-06-11T09:46:21+00:00</updated>
<author>
<name>Michael S. Tsirkin</name>
<email>mst@redhat.com</email>
</author>
<published>2013-06-06T12:20:46+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=288cfe78c8173f35c7a94f06859f60b3693d828a'/>
<id>288cfe78c8173f35c7a94f06859f60b3693d828a</id>
<content type='text'>
vhost_net_clear_ubuf_info didn't clear ubuf_info
after kfree, this could trigger double free.
Fix this and simplify this code to make it more robust: make sure
ubuf info is always freed through vhost_net_clear_ubuf_info.

Reported-by: Tommi Rantala &lt;tt.rantala@gmail.com&gt;
Signed-off-by: Michael S. Tsirkin &lt;mst@redhat.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
vhost_net_clear_ubuf_info didn't clear ubuf_info
after kfree, this could trigger double free.
Fix this and simplify this code to make it more robust: make sure
ubuf info is always freed through vhost_net_clear_ubuf_info.

Reported-by: Tommi Rantala &lt;tt.rantala@gmail.com&gt;
Signed-off-by: Michael S. Tsirkin &lt;mst@redhat.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>vhost: check owner before we overwrite ubuf_info</title>
<updated>2013-06-11T09:46:21+00:00</updated>
<author>
<name>Michael S. Tsirkin</name>
<email>mst@redhat.com</email>
</author>
<published>2013-06-06T12:20:39+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=05c05351943cc03bf5c77e86953b24ae6fb21368'/>
<id>05c05351943cc03bf5c77e86953b24ae6fb21368</id>
<content type='text'>
If device has an owner, we shouldn't touch ubuf_info
since it might be in use.

Signed-off-by: Michael S. Tsirkin &lt;mst@redhat.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
If device has an owner, we shouldn't touch ubuf_info
since it might be in use.

Signed-off-by: Michael S. Tsirkin &lt;mst@redhat.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>vhost_net: clear msg.control for non-zerocopy case during tx</title>
<updated>2013-06-10T21:31:45+00:00</updated>
<author>
<name>Jason Wang</name>
<email>jasowang@redhat.com</email>
</author>
<published>2013-06-05T07:40:46+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=4364d5f96eed7994a2c625bd9216656e55fba0cb'/>
<id>4364d5f96eed7994a2c625bd9216656e55fba0cb</id>
<content type='text'>
When we decide not use zero-copy, msg.control should be set to NULL otherwise
macvtap/tap may set zerocopy callbacks which may decrease the kref of ubufs
wrongly.

Bug were introduced by commit cedb9bdce099206290a2bdd02ce47a7b253b6a84
(vhost-net: skip head management if no outstanding).

This solves the following warnings:

WARNING: at include/linux/kref.h:47 handle_tx+0x477/0x4b0 [vhost_net]()
Modules linked in: vhost_net macvtap macvlan tun nfsd exportfs bridge stp llc openvswitch kvm_amd kvm bnx2 megaraid_sas [last unloaded: tun]
CPU: 5 PID: 8670 Comm: vhost-8668 Not tainted 3.10.0-rc2+ #1566
Hardware name: Dell Inc. PowerEdge R715/00XHKG, BIOS 1.5.2 04/19/2011
ffffffffa0198323 ffff88007c9ebd08 ffffffff81796b73 ffff88007c9ebd48
ffffffff8103d66b 000000007b773e20 ffff8800779f0000 ffff8800779f43f0
ffff8800779f8418 000000000000015c 0000000000000062 ffff88007c9ebd58
Call Trace:
[&lt;ffffffff81796b73&gt;] dump_stack+0x19/0x1e
[&lt;ffffffff8103d66b&gt;] warn_slowpath_common+0x6b/0xa0
[&lt;ffffffff8103d6b5&gt;] warn_slowpath_null+0x15/0x20
[&lt;ffffffffa0197627&gt;] handle_tx+0x477/0x4b0 [vhost_net]
[&lt;ffffffffa0197690&gt;] handle_tx_kick+0x10/0x20 [vhost_net]
[&lt;ffffffffa019541e&gt;] vhost_worker+0xfe/0x1a0 [vhost_net]
[&lt;ffffffffa0195320&gt;] ? vhost_attach_cgroups_work+0x30/0x30 [vhost_net]
[&lt;ffffffffa0195320&gt;] ? vhost_attach_cgroups_work+0x30/0x30 [vhost_net]
[&lt;ffffffff81061f46&gt;] kthread+0xc6/0xd0
[&lt;ffffffff81061e80&gt;] ? kthread_freezable_should_stop+0x70/0x70
[&lt;ffffffff817a1aec&gt;] ret_from_fork+0x7c/0xb0
[&lt;ffffffff81061e80&gt;] ? kthread_freezable_should_stop+0x70/0x70

Signed-off-by: Jason Wang &lt;jasowang@redhat.com&gt;
Acked-by: Michael S. Tsirkin &lt;mst@redhat.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
When we decide not use zero-copy, msg.control should be set to NULL otherwise
macvtap/tap may set zerocopy callbacks which may decrease the kref of ubufs
wrongly.

Bug were introduced by commit cedb9bdce099206290a2bdd02ce47a7b253b6a84
(vhost-net: skip head management if no outstanding).

This solves the following warnings:

WARNING: at include/linux/kref.h:47 handle_tx+0x477/0x4b0 [vhost_net]()
Modules linked in: vhost_net macvtap macvlan tun nfsd exportfs bridge stp llc openvswitch kvm_amd kvm bnx2 megaraid_sas [last unloaded: tun]
CPU: 5 PID: 8670 Comm: vhost-8668 Not tainted 3.10.0-rc2+ #1566
Hardware name: Dell Inc. PowerEdge R715/00XHKG, BIOS 1.5.2 04/19/2011
ffffffffa0198323 ffff88007c9ebd08 ffffffff81796b73 ffff88007c9ebd48
ffffffff8103d66b 000000007b773e20 ffff8800779f0000 ffff8800779f43f0
ffff8800779f8418 000000000000015c 0000000000000062 ffff88007c9ebd58
Call Trace:
[&lt;ffffffff81796b73&gt;] dump_stack+0x19/0x1e
[&lt;ffffffff8103d66b&gt;] warn_slowpath_common+0x6b/0xa0
[&lt;ffffffff8103d6b5&gt;] warn_slowpath_null+0x15/0x20
[&lt;ffffffffa0197627&gt;] handle_tx+0x477/0x4b0 [vhost_net]
[&lt;ffffffffa0197690&gt;] handle_tx_kick+0x10/0x20 [vhost_net]
[&lt;ffffffffa019541e&gt;] vhost_worker+0xfe/0x1a0 [vhost_net]
[&lt;ffffffffa0195320&gt;] ? vhost_attach_cgroups_work+0x30/0x30 [vhost_net]
[&lt;ffffffffa0195320&gt;] ? vhost_attach_cgroups_work+0x30/0x30 [vhost_net]
[&lt;ffffffff81061f46&gt;] kthread+0xc6/0xd0
[&lt;ffffffff81061e80&gt;] ? kthread_freezable_should_stop+0x70/0x70
[&lt;ffffffff817a1aec&gt;] ret_from_fork+0x7c/0xb0
[&lt;ffffffff81061e80&gt;] ? kthread_freezable_should_stop+0x70/0x70

Signed-off-by: Jason Wang &lt;jasowang@redhat.com&gt;
Acked-by: Michael S. Tsirkin &lt;mst@redhat.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Add missing module license tag to vring helpers.</title>
<updated>2013-05-08T01:19:03+00:00</updated>
<author>
<name>Dave Jones</name>
<email>davej@redhat.com</email>
</author>
<published>2013-05-03T20:40:09+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=f558a845c3a043d032bb247cdbe50db9202476a1'/>
<id>f558a845c3a043d032bb247cdbe50db9202476a1</id>
<content type='text'>
[  624.286653] vringh: module license 'unspecified' taints kernel.

Signed-off-by: Dave Jones &lt;davej@redhat.com&gt;
Signed-off-by: Rusty Russell &lt;rusty@rustcorp.com.au&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
[  624.286653] vringh: module license 'unspecified' taints kernel.

Signed-off-by: Dave Jones &lt;davej@redhat.com&gt;
Signed-off-by: Rusty Russell &lt;rusty@rustcorp.com.au&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge tag 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mst/vhost</title>
<updated>2013-05-07T17:13:52+00:00</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2013-05-07T17:13:52+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=eac84105cddf8686440aaa9fbcb58093e37e4180'/>
<id>eac84105cddf8686440aaa9fbcb58093e37e4180</id>
<content type='text'>
Pull more vhost fixes from Michael Tsirkin:
 "This fixes some minor issues in the patches that have been merged.

  We also finally drop the workaround disabling event_idx for scsi: it
  was always questionable, and now we know it's not needed.

  There's also a memory leak fix"

* tag 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mst/vhost:
  vhost-scsi: Enable VIRTIO_RING_F_EVENT_IDX
  vhost: drop virtio_net.h dependency
  vhost-net: Cleanup vhost_ubuf and vhost_zcopy
  vhost: Remove vhost_enable_zcopy in vhost.h
  vhost: Remove comments for hdr in vhost.h
  vhost: Move VHOST_NET_FEATURES to net.c
  vhost-net: Free ubuf when vhost_dev_set_owner fails
  vhost: Export vhost_dev_set_owner
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Pull more vhost fixes from Michael Tsirkin:
 "This fixes some minor issues in the patches that have been merged.

  We also finally drop the workaround disabling event_idx for scsi: it
  was always questionable, and now we know it's not needed.

  There's also a memory leak fix"

* tag 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mst/vhost:
  vhost-scsi: Enable VIRTIO_RING_F_EVENT_IDX
  vhost: drop virtio_net.h dependency
  vhost-net: Cleanup vhost_ubuf and vhost_zcopy
  vhost: Remove vhost_enable_zcopy in vhost.h
  vhost: Remove comments for hdr in vhost.h
  vhost: Move VHOST_NET_FEATURES to net.c
  vhost-net: Free ubuf when vhost_dev_set_owner fails
  vhost: Export vhost_dev_set_owner
</pre>
</div>
</content>
</entry>
<entry>
<title>vhost-scsi: Enable VIRTIO_RING_F_EVENT_IDX</title>
<updated>2013-05-07T08:11:08+00:00</updated>
<author>
<name>Asias He</name>
<email>asias@redhat.com</email>
</author>
<published>2013-05-07T06:51:49+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=a18cc421649dfdc21edb6c4c867dd05447d7df8c'/>
<id>a18cc421649dfdc21edb6c4c867dd05447d7df8c</id>
<content type='text'>
It was disabled as a workaround. Now userspace bits work fine with it.
The broken version was not ever committed to QEMU, I guess the same is
true for nlkt.

So, let's enable it.

Signed-off-by: Asias He &lt;asias@redhat.com&gt;
Acked-by: Paolo Bonzini &lt;pbonzini@redhat.com&gt;
Signed-off-by: Michael S. Tsirkin &lt;mst@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
It was disabled as a workaround. Now userspace bits work fine with it.
The broken version was not ever committed to QEMU, I guess the same is
true for nlkt.

So, let's enable it.

Signed-off-by: Asias He &lt;asias@redhat.com&gt;
Acked-by: Paolo Bonzini &lt;pbonzini@redhat.com&gt;
Signed-off-by: Michael S. Tsirkin &lt;mst@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>vhost: drop virtio_net.h dependency</title>
<updated>2013-05-06T11:04:06+00:00</updated>
<author>
<name>Michael S. Tsirkin</name>
<email>mst@redhat.com</email>
</author>
<published>2013-05-06T10:29:36+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=7542a6b0d273ba4338028d39bc0e6e8cbfc68898'/>
<id>7542a6b0d273ba4338028d39bc0e6e8cbfc68898</id>
<content type='text'>
There's no net specific code in vhost.c anymore,
don't include the virtio_net.h header.

Signed-off-by: Michael S. Tsirkin &lt;mst@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
There's no net specific code in vhost.c anymore,
don't include the virtio_net.h header.

Signed-off-by: Michael S. Tsirkin &lt;mst@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>vhost-net: Cleanup vhost_ubuf and vhost_zcopy</title>
<updated>2013-05-06T10:25:47+00:00</updated>
<author>
<name>Asias He</name>
<email>asias@redhat.com</email>
</author>
<published>2013-05-06T08:38:24+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=fe729a57c8d85b6b38d62b64215d5f064e682940'/>
<id>fe729a57c8d85b6b38d62b64215d5f064e682940</id>
<content type='text'>
- Rename vhost_ubuf to vhost_net_ubuf
- Rename vhost_zcopy_mask to vhost_net_zcopy_mask
- Make funcs static

Signed-off-by: Asias He &lt;asias@redhat.com&gt;
Signed-off-by: Michael S. Tsirkin &lt;mst@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
- Rename vhost_ubuf to vhost_net_ubuf
- Rename vhost_zcopy_mask to vhost_net_zcopy_mask
- Make funcs static

Signed-off-by: Asias He &lt;asias@redhat.com&gt;
Signed-off-by: Michael S. Tsirkin &lt;mst@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>vhost: Remove vhost_enable_zcopy in vhost.h</title>
<updated>2013-05-06T10:21:15+00:00</updated>
<author>
<name>Asias He</name>
<email>asias@redhat.com</email>
</author>
<published>2013-05-06T08:38:19+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=e40ab7484f8e9cc9f5e59ae53214800e50f5615e'/>
<id>e40ab7484f8e9cc9f5e59ae53214800e50f5615e</id>
<content type='text'>
It is net.c specific.

Signed-off-by: Asias He &lt;asias@redhat.com&gt;
Signed-off-by: Michael S. Tsirkin &lt;mst@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
It is net.c specific.

Signed-off-by: Asias He &lt;asias@redhat.com&gt;
Signed-off-by: Michael S. Tsirkin &lt;mst@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>vhost: Remove comments for hdr in vhost.h</title>
<updated>2013-05-06T10:21:07+00:00</updated>
<author>
<name>Asias He</name>
<email>asias@redhat.com</email>
</author>
<published>2013-05-06T08:38:22+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=ab00c42a567b21024383db3fac98118497d6270b'/>
<id>ab00c42a567b21024383db3fac98118497d6270b</id>
<content type='text'>
It is supposed to be removed when hdr is moved into vhost_net_virtqueue.

Signed-off-by: Asias He &lt;asias@redhat.com&gt;
Signed-off-by: Michael S. Tsirkin &lt;mst@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
It is supposed to be removed when hdr is moved into vhost_net_virtqueue.

Signed-off-by: Asias He &lt;asias@redhat.com&gt;
Signed-off-by: Michael S. Tsirkin &lt;mst@redhat.com&gt;
</pre>
</div>
</content>
</entry>
</feed>
