public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
* [ANNOUNCE] kvm-17 release
@ 2007-03-20 13:27 Avi Kivity
       [not found] ` <45FFE14F.6020808-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
  0 siblings, 1 reply; 14+ messages in thread
From: Avi Kivity @ 2007-03-20 13:27 UTC (permalink / raw)
  To: kvm-devel

Highlights: acpi works again.

Changes from kvm-16:

- live migration enhancements (Uri Lublin)
- better/working acpi support
- revert to unhacked qemu bios
- fix some 32-bit nonpae guests (*BSD)
- initial ballooning support
- random fixes

Note that if you use the modules from Linux 2.6.20, you need to use
kvm-12.  You can use kvm-17 with Linux 2.6.20, provided you use the
external module included in kvm-17.  API/ABI stability is planned for
Linux 2.6.22.

http://kvm.qumranet.com

-- 
error compiling committee.c: too many arguments to function


-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [ANNOUNCE] kvm-17 release
       [not found] ` <45FFE14F.6020808-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
@ 2007-03-22 19:32   ` Michael Riepe
       [not found]     ` <4602D9D5.7060806-0QoEqw4nQxo@public.gmane.org>
  0 siblings, 1 reply; 14+ messages in thread
From: Michael Riepe @ 2007-03-22 19:32 UTC (permalink / raw)
  To: Avi Kivity; +Cc: kvm-devel

Hi!

With respect to the Core Duo, this is the best release I've seen so far:

- FreeBSD 6.1: works.
- NetBSD 3.1: works.
- OpenSuse 10.2 (sans gfxmenu): works.
- Qemu-Puppy 2.01-3: works.
- Qemu-Puppy 2.13-1: works.
- Solaris 10.1: works.
- XP Pro: works.

Unfortunately, Knoppix (both 5.0 and 5.1.1) has stopped working now. I
didn't try 5.2 yet.

(using Kernel 2.6.20)

-- 
Michael "Tired" Riepe <michael-0QoEqw4nQxo@public.gmane.org>
X-Tired: Each morning I get up I die a little

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [ANNOUNCE] kvm-17 release
       [not found]     ` <4602D9D5.7060806-0QoEqw4nQxo@public.gmane.org>
@ 2007-03-23  9:33       ` Avi Kivity
       [not found]         ` <46039EEA.4070504-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
  2007-03-23  9:43       ` Avi Kivity
  1 sibling, 1 reply; 14+ messages in thread
From: Avi Kivity @ 2007-03-23  9:33 UTC (permalink / raw)
  To: Michael Riepe; +Cc: kvm-devel

Michael Riepe wrote:
> Hi!
>
> With respect to the Core Duo, this is the best release I've seen so far:
>
> - FreeBSD 6.1: works.
> - NetBSD 3.1: works.
> - OpenSuse 10.2 (sans gfxmenu): works.
> - Qemu-Puppy 2.01-3: works.
> - Qemu-Puppy 2.13-1: works.
> - Solaris 10.1: works.
> - XP Pro: works.
>
>   

We strive for monotonously increasing quality ;-)  thanks for the 
comprehensive testing.

> Unfortunately, Knoppix (both 5.0 and 5.1.1) has stopped working now. I
> didn't try 5.2 yet.
>   

5.1.1 failed for me, but booted fine with nmi_watchdog=0 as a guest 
kernel parameter.  No version of kvm has supported the nmi watchdog, so 
I don't quite understand what's going on.  Which version of kvm did you 
get 5.1.1 working with?

I added the architectural performance monitor counters to the todo.

-- 
Do not meddle in the internals of kernels, for they are subtle and quick to panic.


-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [ANNOUNCE] kvm-17 release
       [not found]     ` <4602D9D5.7060806-0QoEqw4nQxo@public.gmane.org>
  2007-03-23  9:33       ` Avi Kivity
@ 2007-03-23  9:43       ` Avi Kivity
  1 sibling, 0 replies; 14+ messages in thread
From: Avi Kivity @ 2007-03-23  9:43 UTC (permalink / raw)
  To: Michael Riepe; +Cc: kvm-devel

Michael Riepe wrote:
> Hi!
>
> With respect to the Core Duo, this is the best release I've seen so far:
>
> - FreeBSD 6.1: works.
> - NetBSD 3.1: works.
> - OpenSuse 10.2 (sans gfxmenu): works.
> - Qemu-Puppy 2.01-3: works.
> - Qemu-Puppy 2.13-1: works.
> - Solaris 10.1: works.
> - XP Pro: works.
>
> Unfortunately, Knoppix (both 5.0 and 5.1.1) has stopped working now. I
> didn't try 5.2 yet.
>
> (using Kernel 2.6.20)
>
>   

Can you update http://kvm.qumranet.com/kvmwiki/Guest_Support_Status with 
the results?

-- 
Do not meddle in the internals of kernels, for they are subtle and quick to panic.


-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [ANNOUNCE] kvm-17 release
       [not found]         ` <46039EEA.4070504-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
@ 2007-03-24  2:25           ` Carsten Emde
       [not found]             ` <46048C34.4080300-Q945KHDl0DbYtjvyW6yDsg@public.gmane.org>
  0 siblings, 1 reply; 14+ messages in thread
From: Carsten Emde @ 2007-03-24  2:25 UTC (permalink / raw)
  To: Avi Kivity; +Cc: kvm-devel

Avi Kivity wrote:
> Michael Riepe wrote:
>> With respect to the Core Duo, this is the best release I've seen so far:
Unfortunately, kvm-17 was less successful here. FC6 did not boot any 
longer after I upgraded from kvm-16 to kvm-17, so I was rather surprised 
when I read the above message.

This is the test system:
CPU: Intel(R) Core(TM)2 CPU 6600 @ 2.40GHz, Chipset: Intel 975X

The exact problem was that FC6 stopped booting before under kvm-16 it 
would display the line
IP route cache hash table entries: 4096 (order: 2, 16384 bytes)

I then reverted to kvm-16 and repeated all upgrade changes until the 
problem occurred. The culprit was found to be

--- kvm_main-17.c	2007-03-24 02:09:00.000000000 +0100
+++ kvm_main.c	2007-03-24 02:56:15.000000000 +0100
@@ -1575,7 +1575,9 @@
  	if (kvm_run->mmio_completed) {
  		memcpy(vcpu->mmio_data, kvm_run->mmio.data, 8);
  		vcpu->mmio_read_completed = 1;
+#ifdef THIS_PREVENTS_FC6_FROM_BOOTING
  		emulate_instruction(vcpu, kvm_run, vcpu->mmio_fault_cr2, 0);
+#endif
  	}

  	vcpu->mmio_needed = 0;

-- 
Carsten Emde, OSADL, <C.Emde-Q945KHDl0DbYtjvyW6yDsg@public.gmane.org>, http://www.osadl.org/
News on kvm: http://www.osadl.org/Single-View.111+M595b203da7e.0.html

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [ANNOUNCE] kvm-17 release
       [not found]             ` <46048C34.4080300-Q945KHDl0DbYtjvyW6yDsg@public.gmane.org>
@ 2007-03-24  3:29               ` Carsten Emde
       [not found]                 ` <46049B0C.40501-Q945KHDl0DbYtjvyW6yDsg@public.gmane.org>
  2007-03-24 11:58               ` Michael Riepe
  2007-03-25  8:46               ` Avi Kivity
  2 siblings, 1 reply; 14+ messages in thread
From: Carsten Emde @ 2007-03-24  3:29 UTC (permalink / raw)
  To: Avi Kivity; +Cc: kvm-devel

Carsten Emde wrote:
> I then reverted to kvm-16 and repeated all upgrade changes until the 
> problem occurred. The culprit was found to be
> [..]
> +#ifdef THIS_PREVENTS_FC6_FROM_BOOTING
>   		emulate_instruction(vcpu, kvm_run, vcpu->mmio_fault_cr2, 0);
> +#endif
> [..]
Actually, the above line can be preserved, if we move the previous line 
down by 1: Was it a simple race?

--- kvm_main-17.c	2007-03-24 02:09:00.000000000 +0100
+++ kvm_main.c	2007-03-24 04:10:59.000000000 +0100
@@ -1574,8 +1574,8 @@

  	if (kvm_run->mmio_completed) {
  		memcpy(vcpu->mmio_data, kvm_run->mmio.data, 8);
-		vcpu->mmio_read_completed = 1;
  		emulate_instruction(vcpu, kvm_run, vcpu->mmio_fault_cr2, 0);
+		vcpu->mmio_read_completed = 1;
  	}

  	vcpu->mmio_needed = 0;


--
Carsten Emde <C.Emde-Q945KHDl0DbYtjvyW6yDsg@public.gmane.org>

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [ANNOUNCE] kvm-17 release
       [not found]             ` <46048C34.4080300-Q945KHDl0DbYtjvyW6yDsg@public.gmane.org>
  2007-03-24  3:29               ` Carsten Emde
@ 2007-03-24 11:58               ` Michael Riepe
       [not found]                 ` <46051251.1020401-0QoEqw4nQxo@public.gmane.org>
  2007-03-25  8:46               ` Avi Kivity
  2 siblings, 1 reply; 14+ messages in thread
From: Michael Riepe @ 2007-03-24 11:58 UTC (permalink / raw)
  To: Carsten Emde; +Cc: kvm-devel

Hi!

Carsten Emde wrote:
> Avi Kivity wrote:
> 
>>Michael Riepe wrote:
>>
>>>With respect to the Core Duo, this is the best release I've seen so far:
> 
> Unfortunately, kvm-17 was less successful here. FC6 did not boot any 
> longer after I upgraded from kvm-16 to kvm-17, so I was rather surprised 
> when I read the above message.

Probably the same problem that killed Knoppix in -17 (-16 worked fine).
But it was the first release that worked with both Net- and FreeBSD as
well as Solaris.

Oh by the way: Knoppix 5.2 behaves the same way as 5.1.1. With -17, it
hangs before the penguin logo appears on the framebuffer.

> This is the test system:
> CPU: Intel(R) Core(TM)2 CPU 6600 @ 2.40GHz, Chipset: Intel 975X

There's quite a difference between Core Duo and Core 2 Duo.

Did the host and/or guest run in 64-bit mode, by the way?

-- 
Michael "Tired" Riepe <michael-0QoEqw4nQxo@public.gmane.org>
X-Tired: Each morning I get up I die a little

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [ANNOUNCE] kvm-17 release
       [not found]                 ` <46049B0C.40501-Q945KHDl0DbYtjvyW6yDsg@public.gmane.org>
@ 2007-03-24 12:29                   ` Michael Riepe
       [not found]                     ` <460519A6.1020005-0QoEqw4nQxo@public.gmane.org>
  2007-03-25  8:47                   ` Avi Kivity
  1 sibling, 1 reply; 14+ messages in thread
From: Michael Riepe @ 2007-03-24 12:29 UTC (permalink / raw)
  To: Carsten Emde; +Cc: kvm-devel

Hi!

Carsten Emde wrote:

> Actually, the above line can be preserved, if we move the previous line 
> down by 1: Was it a simple race?
> 
> --- kvm_main-17.c	2007-03-24 02:09:00.000000000 +0100
> +++ kvm_main.c	2007-03-24 04:10:59.000000000 +0100
> @@ -1574,8 +1574,8 @@
> 
>   	if (kvm_run->mmio_completed) {
>   		memcpy(vcpu->mmio_data, kvm_run->mmio.data, 8);
> -		vcpu->mmio_read_completed = 1;
>   		emulate_instruction(vcpu, kvm_run, vcpu->mmio_fault_cr2, 0);
> +		vcpu->mmio_read_completed = 1;
>   	}
> 
>   	vcpu->mmio_needed = 0;
> 

As far as I understand, vcpu->mmio_read_completed indicates that read
data is present in vcpu->mmio_data. If the flag isn't set,
emulator_read_emulated() - which is called by emulate_instruction() -
will try to read the data *again*. While that's supposed to be okay for
ordinary memory, it might make memory mapped i/o devices fail.

On the other hand, emulator_read_emulated() clears the flag to indicate
that the emulated read has actually happened - which means that another
read may drop us into userspace for emulation again. There is, however,
no other place where the flag is reset, so setting it after
emulate_instruction() may affect the *next* emulated instruction. I
think that the flag should be cleared after the call, rather than set.

Besides that, vcpu->mmio_read_completed seems to guard a call to
do_interrupt_requests() in vmx_vcpu_run(). I guess the reason is that
interrupts must not be processed if the current instruction has already
been partially emulated.

Or did I get something wrong?

There's another point here that bothers me: The result of
emulate_instruction() isn't checked. Are you sure that it never fails,
and that it's safe to proceed to kvm_arch_ops->run(), aka vmx_vcpu_run()
in case it's an Intel CPU?

-- 
Michael "Tired" Riepe <michael-0QoEqw4nQxo@public.gmane.org>
X-Tired: Each morning I get up I die a little

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [ANNOUNCE] kvm-17 release
       [not found]                 ` <46051251.1020401-0QoEqw4nQxo@public.gmane.org>
@ 2007-03-24 13:06                   ` Carsten Emde
  2007-03-25  8:49                   ` Avi Kivity
  1 sibling, 0 replies; 14+ messages in thread
From: Carsten Emde @ 2007-03-24 13:06 UTC (permalink / raw)
  To: Michael Riepe; +Cc: kvm-devel

Michael,

>>>> With respect to the Core Duo, this is the best release I've seen so far:
>> Unfortunately, kvm-17 was less successful here. FC6 did not boot any 
>> longer after I upgraded from kvm-16 to kvm-17, so I was rather surprised 
>> when I read the above message. [..]
> But it was the first release that worked with both Net- and FreeBSD as
> well as Solaris.
Yes, of course. I certainly did not mean to question your merits.

> Probably the same problem that killed Knoppix in -17 (-16 worked fine). [..]
> Oh by the way: Knoppix 5.2 behaves the same way as 5.1.1. With -17, it
> hangs before the penguin logo appears on the framebuffer.
Do you have one of these Knoppix handy to check whether moving the line 
in question in kvm_main.c:1578 solves the problem?

>> This is the test system:
>> CPU: Intel(R) Core(TM)2 CPU 6600 @ 2.40GHz, Chipset: Intel 975X
> There's quite a difference between Core Duo and Core 2 Duo.
Yes, indeed.

> Did the host and/or guest run in 64-bit mode, by the way?
32-bit.

--
Carsten Emde <C.Emde-Q945KHDl0DbYtjvyW6yDsg@public.gmane.org>

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [ANNOUNCE] kvm-17 release
       [not found]                     ` <460519A6.1020005-0QoEqw4nQxo@public.gmane.org>
@ 2007-03-24 13:25                       ` Carsten Emde
  2007-03-25  8:53                       ` Avi Kivity
  1 sibling, 0 replies; 14+ messages in thread
From: Carsten Emde @ 2007-03-24 13:25 UTC (permalink / raw)
  To: Michael Riepe; +Cc: kvm-devel

Hi!

>> Actually, the above line can be preserved, if we move the previous line 
>> down by 1: Was it a simple race?
>> --- kvm_main-17.c	2007-03-24 02:09:00.000000000 +0100
>> +++ kvm_main.c	2007-03-24 04:10:59.000000000 +0100
>> [..]
>> -		vcpu->mmio_read_completed = 1;
>>   		emulate_instruction(vcpu, kvm_run, vcpu->mmio_fault_cr2, 0);
>> +		vcpu->mmio_read_completed = 1;
> As far as I understand, vcpu->mmio_read_completed indicates that read
> data is present in vcpu->mmio_data. If the flag isn't set,
> emulator_read_emulated() - which is called by emulate_instruction() -
> will try to read the data *again*. While that's supposed to be okay for
> ordinary memory, it might make memory mapped i/o devices fail.
> [..]
> Or did I get something wrong?
I was probably a bit too fast. The only proven fact is that the system 
no longer stops booting when the call to emulate_instruction() is 
removed. Before speculating further, I will study the situation in more 
detail in order to better understand where and why it hangs.


--
Carsten Emde <C.Emde-Q945KHDl0DbYtjvyW6yDsg@public.gmane.org>

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [ANNOUNCE] kvm-17 release
       [not found]             ` <46048C34.4080300-Q945KHDl0DbYtjvyW6yDsg@public.gmane.org>
  2007-03-24  3:29               ` Carsten Emde
  2007-03-24 11:58               ` Michael Riepe
@ 2007-03-25  8:46               ` Avi Kivity
  2 siblings, 0 replies; 14+ messages in thread
From: Avi Kivity @ 2007-03-25  8:46 UTC (permalink / raw)
  To: Carsten Emde; +Cc: kvm-devel

Carsten Emde wrote:
> Avi Kivity wrote:
>> Michael Riepe wrote:
>>> With respect to the Core Duo, this is the best release I've seen so 
>>> far:
> Unfortunately, kvm-17 was less successful here. FC6 did not boot any 
> longer after I upgraded from kvm-16 to kvm-17, so I was rather 
> surprised when I read the above message.
>
> This is the test system:
> CPU: Intel(R) Core(TM)2 CPU 6600 @ 2.40GHz, Chipset: Intel 975X
>
> The exact problem was that FC6 stopped booting before under kvm-16 it 
> would display the line
> IP route cache hash table entries: 4096 (order: 2, 16384 bytes)
>
> I then reverted to kvm-16 and repeated all upgrade changes until the 
> problem occurred. The culprit was found to be
>
> --- kvm_main-17.c    2007-03-24 02:09:00.000000000 +0100
> +++ kvm_main.c    2007-03-24 02:56:15.000000000 +0100
> @@ -1575,7 +1575,9 @@
>      if (kvm_run->mmio_completed) {
>          memcpy(vcpu->mmio_data, kvm_run->mmio.data, 8);
>          vcpu->mmio_read_completed = 1;
> +#ifdef THIS_PREVENTS_FC6_FROM_BOOTING
>          emulate_instruction(vcpu, kvm_run, vcpu->mmio_fault_cr2, 0);
> +#endif
>      }
>
>      vcpu->mmio_needed = 0;
>

I've already reverted this optimization.  I'd like to get it back, since 
it is sound, but I don't yet understand why it caused the regression.


-- 
error compiling committee.c: too many arguments to function


-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [ANNOUNCE] kvm-17 release
       [not found]                 ` <46049B0C.40501-Q945KHDl0DbYtjvyW6yDsg@public.gmane.org>
  2007-03-24 12:29                   ` Michael Riepe
@ 2007-03-25  8:47                   ` Avi Kivity
  1 sibling, 0 replies; 14+ messages in thread
From: Avi Kivity @ 2007-03-25  8:47 UTC (permalink / raw)
  To: Carsten Emde; +Cc: kvm-devel

Carsten Emde wrote:
> Carsten Emde wrote:
>> I then reverted to kvm-16 and repeated all upgrade changes until the 
>> problem occurred. The culprit was found to be
>> [..]
>> +#ifdef THIS_PREVENTS_FC6_FROM_BOOTING
>>           emulate_instruction(vcpu, kvm_run, vcpu->mmio_fault_cr2, 0);
>> +#endif
>> [..]
> Actually, the above line can be preserved, if we move the previous 
> line down by 1: Was it a simple race?
>
> --- kvm_main-17.c    2007-03-24 02:09:00.000000000 +0100
> +++ kvm_main.c    2007-03-24 04:10:59.000000000 +0100
> @@ -1574,8 +1574,8 @@
>
>      if (kvm_run->mmio_completed) {
>          memcpy(vcpu->mmio_data, kvm_run->mmio.data, 8);
> -        vcpu->mmio_read_completed = 1;
>          emulate_instruction(vcpu, kvm_run, vcpu->mmio_fault_cr2, 0);
> +        vcpu->mmio_read_completed = 1;
>      }
>
>      vcpu->mmio_needed = 0;
>
>

It's just a different way of backing it out.  With mmio_read_completed 
unset, the emulation will simply fail.


-- 
error compiling committee.c: too many arguments to function


-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [ANNOUNCE] kvm-17 release
       [not found]                 ` <46051251.1020401-0QoEqw4nQxo@public.gmane.org>
  2007-03-24 13:06                   ` Carsten Emde
@ 2007-03-25  8:49                   ` Avi Kivity
  1 sibling, 0 replies; 14+ messages in thread
From: Avi Kivity @ 2007-03-25  8:49 UTC (permalink / raw)
  To: Michael Riepe; +Cc: kvm-devel, Carsten Emde

Michael Riepe wrote:
> Hi!
>
> Carsten Emde wrote:
>   
>> Avi Kivity wrote:
>>
>>     
>>> Michael Riepe wrote:
>>>
>>>       
>>>> With respect to the Core Duo, this is the best release I've seen so far:
>>>>         
>> Unfortunately, kvm-17 was less successful here. FC6 did not boot any 
>> longer after I upgraded from kvm-16 to kvm-17, so I was rather surprised 
>> when I read the above message.
>>     
>
> Probably the same problem that killed Knoppix in -17 (-16 worked fine).
>   

That is likely.  When I reported knoppix worked for me, it was using the 
head, which already had this reverted.  Sloppy of me.


-- 
error compiling committee.c: too many arguments to function


-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [ANNOUNCE] kvm-17 release
       [not found]                     ` <460519A6.1020005-0QoEqw4nQxo@public.gmane.org>
  2007-03-24 13:25                       ` Carsten Emde
@ 2007-03-25  8:53                       ` Avi Kivity
  1 sibling, 0 replies; 14+ messages in thread
From: Avi Kivity @ 2007-03-25  8:53 UTC (permalink / raw)
  To: Michael Riepe; +Cc: kvm-devel, Carsten Emde

Michael Riepe wrote:
> Hi!
>
> Carsten Emde wrote:
>
>   
>> Actually, the above line can be preserved, if we move the previous line 
>> down by 1: Was it a simple race?
>>
>> --- kvm_main-17.c	2007-03-24 02:09:00.000000000 +0100
>> +++ kvm_main.c	2007-03-24 04:10:59.000000000 +0100
>> @@ -1574,8 +1574,8 @@
>>
>>   	if (kvm_run->mmio_completed) {
>>   		memcpy(vcpu->mmio_data, kvm_run->mmio.data, 8);
>> -		vcpu->mmio_read_completed = 1;
>>   		emulate_instruction(vcpu, kvm_run, vcpu->mmio_fault_cr2, 0);
>> +		vcpu->mmio_read_completed = 1;
>>   	}
>>
>>   	vcpu->mmio_needed = 0;
>>
>>     
>
> As far as I understand, vcpu->mmio_read_completed indicates that read
> data is present in vcpu->mmio_data. If the flag isn't set,
> emulator_read_emulated() - which is called by emulate_instruction() -
> will try to read the data *again*. While that's supposed to be okay for
> ordinary memory, it might make memory mapped i/o devices fail.
>
> On the other hand, emulator_read_emulated() clears the flag to indicate
> that the emulated read has actually happened - which means that another
> read may drop us into userspace for emulation again. There is, however,
> no other place where the flag is reset, so setting it after
> emulate_instruction() may affect the *next* emulated instruction. I
> think that the flag should be cleared after the call, rather than set.
>
> Besides that, vcpu->mmio_read_completed seems to guard a call to
> do_interrupt_requests() in vmx_vcpu_run(). I guess the reason is that
> interrupts must not be processed if the current instruction has already
> been partially emulated.
>
> Or did I get something wrong?
>   

No, it looks right.  The code is fairly convoluted due to a control 
inversion problem: the instruction emulator wants to call userspace, but 
the only efficient way to do that is to return to userspace, and have 
userspace call the kernel again with the flag marking the continuation.

> There's another point here that bothers me: The result of
> emulate_instruction() isn't checked. Are you sure that it never fails,
> and that it's safe to proceed to kvm_arch_ops->run(), aka vmx_vcpu_run()
> in case it's an Intel CPU?
>
>   

When emulate_instruction() fails, it's a benign failure; it doesn't 
update any state.

-- 
error compiling committee.c: too many arguments to function


-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV

^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2007-03-25  8:53 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-03-20 13:27 [ANNOUNCE] kvm-17 release Avi Kivity
     [not found] ` <45FFE14F.6020808-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
2007-03-22 19:32   ` Michael Riepe
     [not found]     ` <4602D9D5.7060806-0QoEqw4nQxo@public.gmane.org>
2007-03-23  9:33       ` Avi Kivity
     [not found]         ` <46039EEA.4070504-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
2007-03-24  2:25           ` Carsten Emde
     [not found]             ` <46048C34.4080300-Q945KHDl0DbYtjvyW6yDsg@public.gmane.org>
2007-03-24  3:29               ` Carsten Emde
     [not found]                 ` <46049B0C.40501-Q945KHDl0DbYtjvyW6yDsg@public.gmane.org>
2007-03-24 12:29                   ` Michael Riepe
     [not found]                     ` <460519A6.1020005-0QoEqw4nQxo@public.gmane.org>
2007-03-24 13:25                       ` Carsten Emde
2007-03-25  8:53                       ` Avi Kivity
2007-03-25  8:47                   ` Avi Kivity
2007-03-24 11:58               ` Michael Riepe
     [not found]                 ` <46051251.1020401-0QoEqw4nQxo@public.gmane.org>
2007-03-24 13:06                   ` Carsten Emde
2007-03-25  8:49                   ` Avi Kivity
2007-03-25  8:46               ` Avi Kivity
2007-03-23  9:43       ` Avi Kivity

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox