[PATCH] kvm tool: Remove unused variables from the QCOW code

2011-04-14 Thread Ingo Molnar
Newer versions of GCC notice the following unused variables: qcow.c: In function ‘qcow_read_l1_table’: qcow.c:56:7: error: variable ‘page_offset’ set but not used [-Werror=unused-but-set-variable] qcow.c:54:6: error: variable ‘map_offset’ set but not used [-Werror=unused-but-set-variable]

Re: [Qemu-devel] [PATCH 2/2 V7] qemu, qmp: add inject-nmi qmp command

2011-04-14 Thread Markus Armbruster
Blue Swirl blauwir...@gmail.com writes: On Wed, Apr 13, 2011 at 4:08 PM, Luiz Capitulino lcapitul...@redhat.com wrote: On Tue, 12 Apr 2011 21:31:18 +0300 Blue Swirl blauwir...@gmail.com wrote: On Tue, Apr 12, 2011 at 10:52 AM, Avi Kivity a...@redhat.com wrote: On 04/11/2011 08:15 PM,

Re: [PATCHv2] KVM: emulator: do not needlesly sync registers from emulator ctxt to vcpu

2011-04-14 Thread Marcelo Tosatti
On Thu, Mar 31, 2011 at 12:06:41PM +0200, Gleb Natapov wrote: Currently we sync registers back and forth before/after exiting to userspace for IO, but during IO device model shouldn't need to read/write the registers, so we can as well skip those sync points. The only exaception is broken

Re: [PATCH] KVM: Add CPUID support for VIA CPU

2011-04-14 Thread Avi Kivity
On 04/14/2011 06:14 AM, brill...@viatech.com.cn wrote: On 04/13/2011 02:05 PM, brill...@viatech.com.cn wrote: +/* cpuid 0xC001.edx */ + const u32 kvm_supported_word5_x86_features = +F(XSTORE) | F(XSTORE_EN) | F(XCRYPT) | F(XCRYPT_EN) |

Re: [PATCH v2] kvm tool: add QCOW verions 1 read/write support

2011-04-14 Thread Kevin Wolf
Am 13.04.2011 21:26, schrieb Prasad Joshi: The patch only implements the basic read write support for QCOW version 1 images. Many of the QCOW features are not implmented, for example - image creation - snapshot - copy-on-write - encryption Yay, more forks, more code duplication! Have

Re: [PATCH v2] kvm tool: add QCOW verions 1 read/write support

2011-04-14 Thread Ingo Molnar
* Kevin Wolf kw...@redhat.com wrote: Also at least your qcow1.c is lacking the copyright header. Please add this, otherwise you're violating the license. AFAICT it's not a copy, it's a reimplementation - and he credited you in the CREDITS file, for providing a reference implementation. But

Re: [PATCH v2] kvm tool: add QCOW verions 1 read/write support

2011-04-14 Thread Kevin Wolf
Am 14.04.2011 10:07, schrieb Ingo Molnar: * Kevin Wolf kw...@redhat.com wrote: Also at least your qcow1.c is lacking the copyright header. Please add this, otherwise you're violating the license. AFAICT it's not a copy, it's a reimplementation - and he credited you in the CREDITS

Re: [PATCH v2] kvm tool: add QCOW verions 1 read/write support

2011-04-14 Thread Pekka Enberg
* Kevin Wolf kw...@redhat.com wrote: Also at least your qcow1.c is lacking the copyright header. Please add this, otherwise you're violating the license. Am 14.04.2011 10:07, schrieb Ingo Molnar: AFAICT it's not a copy, it's a reimplementation - and he credited you in the CREDITS file, for

Re: [PATCH v2] kvm tool: add QCOW verions 1 read/write support

2011-04-14 Thread Pekka Enberg
On Thu, Apr 14, 2011 at 11:02 AM, Kevin Wolf kw...@redhat.com wrote: Have you thought about a way to actually share code with qemu instead of repeating Xen's mistake of copying code, modifying it until merges are no longer possible and then let it bitrot? No we haven't and we're not planning

Re: [PATCH v2] kvm tool: add QCOW verions 1 read/write support

2011-04-14 Thread Kevin Wolf
Am 14.04.2011 10:15, schrieb Pekka Enberg: * Kevin Wolf kw...@redhat.com wrote: Also at least your qcow1.c is lacking the copyright header. Please add this, otherwise you're violating the license. Am 14.04.2011 10:07, schrieb Ingo Molnar: AFAICT it's not a copy, it's a reimplementation -

Re: [PATCH v2] kvm tool: add QCOW verions 1 read/write support

2011-04-14 Thread Ingo Molnar
* Kevin Wolf kw...@redhat.com wrote: Am 14.04.2011 10:07, schrieb Ingo Molnar: * Kevin Wolf kw...@redhat.com wrote: Also at least your qcow1.c is lacking the copyright header. Please add this, otherwise you're violating the license. AFAICT it's not a copy, it's a

Re: [PATCH v2] kvm tool: add QCOW verions 1 read/write support

2011-04-14 Thread Ingo Molnar
* Kevin Wolf kw...@redhat.com wrote: Am 14.04.2011 10:15, schrieb Pekka Enberg: * Kevin Wolf kw...@redhat.com wrote: Also at least your qcow1.c is lacking the copyright header. Please add this, otherwise you're violating the license. Am 14.04.2011 10:07, schrieb Ingo Molnar:

Re: [PATCH v2] kvm tool: add QCOW verions 1 read/write support

2011-04-14 Thread Kevin Wolf
Am 14.04.2011 10:21, schrieb Pekka Enberg: On Thu, Apr 14, 2011 at 11:02 AM, Kevin Wolf kw...@redhat.com wrote: Have you thought about a way to actually share code with qemu instead of repeating Xen's mistake of copying code, modifying it until merges are no longer possible and then let it

Re: [PATCH v2] kvm tool: add QCOW verions 1 read/write support

2011-04-14 Thread Pekka Enberg
Hi Kevin! Am 14.04.2011 10:21, schrieb Pekka Enberg: On Thu, Apr 14, 2011 at 11:02 AM, Kevin Wolf kw...@redhat.com wrote: Have you thought about a way to actually share code with qemu instead of repeating Xen's mistake of copying code, modifying it until merges are no longer possible and then

Re: [PATCH v2] kvm tool: add QCOW verions 1 read/write support

2011-04-14 Thread Alon Levy
On Thu, Apr 14, 2011 at 11:32:21AM +0300, Pekka Enberg wrote: Hi Kevin! Am 14.04.2011 10:21, schrieb Pekka Enberg: On Thu, Apr 14, 2011 at 11:02 AM, Kevin Wolf kw...@redhat.com wrote: Have you thought about a way to actually share code with qemu instead of repeating Xen's mistake of

Re: [PATCH v2] kvm tool: add QCOW verions 1 read/write support

2011-04-14 Thread Kevin Wolf
Am 14.04.2011 10:32, schrieb Pekka Enberg: Hi Kevin! Am 14.04.2011 10:21, schrieb Pekka Enberg: On Thu, Apr 14, 2011 at 11:02 AM, Kevin Wolf kw...@redhat.com wrote: Have you thought about a way to actually share code with qemu instead of repeating Xen's mistake of copying code, modifying it

Re: [PATCH v2] kvm tool: add QCOW verions 1 read/write support

2011-04-14 Thread Prasad Joshi
On Thu, Apr 14, 2011 at 9:27 AM, Ingo Molnar mi...@elte.hu wrote: * Kevin Wolf kw...@redhat.com wrote: Am 14.04.2011 10:15, schrieb Pekka Enberg: * Kevin Wolf kw...@redhat.com wrote: Also at least your qcow1.c is lacking the copyright header. Please add this, otherwise you're

Re: [PATCH v2] kvm tool: add QCOW verions 1 read/write support

2011-04-14 Thread Markus Armbruster
Kevin Wolf kw...@redhat.com writes: Am 14.04.2011 10:32, schrieb Pekka Enberg: Hi Kevin! Am 14.04.2011 10:21, schrieb Pekka Enberg: On Thu, Apr 14, 2011 at 11:02 AM, Kevin Wolf kw...@redhat.com wrote: Have you thought about a way to actually share code with qemu instead of repeating Xen's

Re: [PATCH v2] kvm tool: add QCOW verions 1 read/write support

2011-04-14 Thread Ingo Molnar
* Prasad Joshi prasadjoshi...@gmail.com wrote: Speaking about the code of finding the cluster offset is so basic, that I thought it should be implemented the way it is done in the QEMU. But none of the code is copied from the QEMU sources. The complete code is written from scratch with

Re: [PATCH v2] kvm tool: add QCOW verions 1 read/write support

2011-04-14 Thread Kevin Wolf
Am 14.04.2011 11:26, schrieb Markus Armbruster: Kevin Wolf kw...@redhat.com writes: Am 14.04.2011 10:32, schrieb Pekka Enberg: Hi Kevin! Am 14.04.2011 10:21, schrieb Pekka Enberg: On Thu, Apr 14, 2011 at 11:02 AM, Kevin Wolf kw...@redhat.com wrote: Have you thought about a way to actually

Re: [PATCH v2] kvm tool: add QCOW verions 1 read/write support

2011-04-14 Thread Stefan Hajnoczi
On Thu, Apr 14, 2011 at 11:26:07AM +0200, Markus Armbruster wrote: Kevin Wolf kw...@redhat.com writes: Am 14.04.2011 10:32, schrieb Pekka Enberg: Hi Kevin! Am 14.04.2011 10:21, schrieb Pekka Enberg: On Thu, Apr 14, 2011 at 11:02 AM, Kevin Wolf kw...@redhat.com wrote: Have you

Re: [PATCH v2] kvm tool: add QCOW verions 1 read/write support

2011-04-14 Thread Pekka Enberg
On 4/14/11 12:23 PM, Prasad Joshi wrote: Oh God. I was walking to university on seventh cloud, hoping to work on caching the l2 table. Now I find myslef under the controversy. Again, it's my fault, not yours. I asked to remove the license banner on top of qcow1.c because it doesn't contain

RE: [PATCH] KVM: Add CPUID support for VIA CPU

2011-04-14 Thread BrillyWu
On 04/14/2011 06:14 AM, brill...@viatech.com.cn wrote: On 04/13/2011 02:05 PM, brill...@viatech.com.cn wrote: +/* cpuid 0xC001.edx */ + const u32 kvm_supported_word5_x86_features = +F(XSTORE) | F(XSTORE_EN) | F(XCRYPT) |

Re: [Qemu-devel] [PATCH 2/2 V7] qemu,qmp: add inject-nmi qmp command

2011-04-14 Thread Daniel P. Berrange
On Wed, Apr 13, 2011 at 10:56:21PM +0300, Blue Swirl wrote: On Wed, Apr 13, 2011 at 4:08 PM, Luiz Capitulino lcapitul...@redhat.com wrote: On Tue, 12 Apr 2011 21:31:18 +0300 Blue Swirl blauwir...@gmail.com wrote: On Tue, Apr 12, 2011 at 10:52 AM, Avi Kivity a...@redhat.com wrote: On

Re: [PATCH v2] kvm tool: add QCOW verions 1 read/write support

2011-04-14 Thread Markus Armbruster
Kevin Wolf kw...@redhat.com writes: Am 14.04.2011 11:26, schrieb Markus Armbruster: Kevin Wolf kw...@redhat.com writes: Am 14.04.2011 10:32, schrieb Pekka Enberg: Hi Kevin! Am 14.04.2011 10:21, schrieb Pekka Enberg: On Thu, Apr 14, 2011 at 11:02 AM, Kevin Wolf kw...@redhat.com wrote:

Re: [PATCH] KVM: Add CPUID support for VIA CPU

2011-04-14 Thread Avi Kivity
On 04/14/2011 12:54 PM, brill...@viatech.com.cn wrote: On 04/14/2011 06:14 AM, brill...@viatech.com.cn wrote: On 04/13/2011 02:05 PM, brill...@viatech.com.cn wrote: + /* cpuid 0xC001.edx */ + const u32 kvm_supported_word5_x86_features =

Re: Network performance with small packets

2011-04-14 Thread Rusty Russell
On Tue, 12 Apr 2011 23:01:12 +0300, Michael S. Tsirkin m...@redhat.com wrote: On Thu, Mar 10, 2011 at 12:19:42PM +1030, Rusty Russell wrote: Here's an old patch where I played with implementing this: ... virtio: put last_used and last_avail index into ring itself. Generally, the

Re: [PATCH 1/2 V2] kvm tools: Set up tun interface using ioctls

2011-04-14 Thread Asias He
On 04/14/2011 01:24 PM, Sasha Levin wrote: Use ioctls to assign IP address and bring interface up instead of using ifconfig. Not breaking aliasing rules this time. Signed-off-by: Sasha Levin levinsasha...@gmail.com --- tools/kvm/virtio-net.c | 29 ++--- 1 files

Re: [PATCH v2] kvm tool: add QCOW verions 1 read/write support

2011-04-14 Thread Anthony Liguori
On 04/14/2011 03:52 AM, Kevin Wolf wrote: Well, copying in itself is not a big problem as long as the copies are kept in sync. It's a bit painful, but manageable. Implementing every image format twice (and implementing image formats in a reliable and performing way isn't trivial) is much more

Re: Network performance with small packets

2011-04-14 Thread Michael S. Tsirkin
On Thu, Apr 14, 2011 at 08:58:41PM +0930, Rusty Russell wrote: On Tue, 12 Apr 2011 23:01:12 +0300, Michael S. Tsirkin m...@redhat.com wrote: On Thu, Mar 10, 2011 at 12:19:42PM +1030, Rusty Russell wrote: Here's an old patch where I played with implementing this: ... virtio:

[PATCH] kvm tools: Add QCOW version 1 read-only support

2011-04-14 Thread Pekka Enberg
From: Prasad Joshi prasadjoshi...@gmail.com The patch only implements the basic read-only support for QCOW version 1 images. Many of the QCOW features are not implemented: - write - image creation - snapshot - copy-on-write - encryption The code is based on the following QCOW 1 image

[RFT/PATCH v2] kvm tools: Add read-only support for block devices

2011-04-14 Thread Pekka Enberg
Add support for booting guests to host block devices in read-only mode. Cc: Asias He asias.he...@gmail.com Cc: Cyrill Gorcunov gorcu...@gmail.com Cc: Prasad Joshi prasadjoshi...@gmail.com Cc: Sasha Levin levinsasha...@gmail.com Cc: Ingo Molnar mi...@elte.hu Signed-off-by: Pekka Enberg

[PATCH] kvm tool: check the cluster boundary in the qcow read code.

2011-04-14 Thread Prasad Joshi
Changed the function names from sect_to_l1_offset(), sect_to_l2_offset() to get_l1_index(), get_l2_index() as they return index into their respective table. Signed-off-by: Prasad Joshi prasadjoshi...@gmail.com --- tools/kvm/qcow.c | 103 ++ 1

Re: [PATCH] kvm tool: check the cluster boundary in the qcow read code.

2011-04-14 Thread Pekka Enberg
On Thu, 2011-04-14 at 20:23 +0100, Prasad Joshi wrote: Changed the function names from sect_to_l1_offset(), sect_to_l2_offset() to get_l1_index(), get_l2_index() as they return index into their respective table. This patch does a lot more than what's described above. Please split the changes

Re: [PATCH] kvm tool: check the cluster boundary in the qcow read code.

2011-04-14 Thread Prasad Joshi
On Thu, Apr 14, 2011 at 8:59 PM, Pekka Enberg penb...@kernel.org wrote: On Thu, 2011-04-14 at 20:23 +0100, Prasad Joshi wrote: Changed the function names from sect_to_l1_offset(), sect_to_l2_offset() to get_l1_index(), get_l2_index() as they return index into their respective table. This

Re: [PATCH] kvm tool: add QCOW verions 1 read/write support

2011-04-14 Thread Christoph Hellwig
On Wed, Apr 13, 2011 at 08:01:58PM +0100, Prasad Joshi wrote: The patch only implements the basic read write support for QCOW version 1 images. Many of the QCOW features are not implmented, for example What's the point? Qcow1 has been deprecated for a long time. -- To unsubscribe from this

[PATCH] KVM: emulator: Use linearize() when fetching instructions.

2011-04-14 Thread Nelson Elhage
This means that the truncation behavior in linearize needs to grow an additional slight piece of complexity: when fetching, truncation is dependent on the execution mode, instead of the current address size. Signed-off-by: Nelson Elhage nelh...@ksplice.com --- arch/x86/include/asm/kvm_emulate.h