Re: [kvm-devel] Host crashes when creating guest

2007-11-05 Thread Zhao, Yunfeng
I meant the TIP , c388ba81841a1ed30a5dd4f6029db2263ad1aca3, has the problem.
And kernel, a9acc2800d8676d8a9a91aeaedd16ae4f75c05df and userspace, 
179c05cc201592d8d48254133cc0075271a69e23 haven't the problem.
The error always happens when creating linux and windows guest on 64bit host.

>-Original Message-
>From: Izik Eidus [mailto:[EMAIL PROTECTED]
>Sent: 2007年11月5日 15:36
>To: Zhao, Yunfeng
>Cc: kvm-devel
>Subject: Re: [kvm-devel] Host crashes when creating guest
>
>On Mon, 2007-11-05 at 15:27 +0800, Zhao, Yunfeng wrote:
>> Against latest commits, creating guests will cause host to crash.
>> Here is the serial output when the error happens.
>can you please tell me what was the guest you used,
>and what was the latest commit you remember it worked for you?

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] [PATCH] KVM: VMX: Fix repeatlycalling alloc_apic_access_page()

2007-11-05 Thread Dong, Eddie
>> 
>> -if (vm_need_virtualize_apic_accesses(vmx->vcpu.kvm))
>> +if ((vmx->vcpu.vcpu_id == 0) &&
>> +(vm_need_virtualize_apic_accesses(vmx->vcpu.kvm)))
>>  if (alloc_apic_access_page(vmx->vcpu.kvm) != 0)
>>  return -ENOMEM;
>> 
>> 
> 
> We may not have vcpu id 0 (though it's very unlikely).
> 

Current LAPIC code assume vcpu_id = 0 for BSP.
And even no real support of APIC_ID change.

How about use  (vcpu->apic_base & MSR_IA32_APICBASE_BSP) ?

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] [PATCH] Fix writing back APIC reset to inkernel APIC

2007-11-05 Thread Dong, Eddie
Avi Kivity wrote:
> Dong, Eddie wrote:
>> Yes, when reseting, we need to reset both APIC/PIC/IOAPIC and pv
>> driver in future, and also VCPU.
>> But isn't apic_reset a pure user level APIC thing?
> 
> The reset callbacks are still called, so the userspace apic is
> still reset.

OK. But since we have seperate kernel reset, doing double reset here
means
something weir to me.

Maybe you just want to live with a pure apic reset only, then I am ok
too.
Once we established one ABI, probably we won't establish another set, do
we?

Eddie

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] RFC/patch portability: split kvm_vm_ioctl v3

2007-11-05 Thread Carsten Otte
Dong, Eddie wrote:
>> BTW, why we use vector here? shouldn't it be irq_line or irq_no?
> 
> Maybe you mean the Channel Subsystem (1st piece of knowledge and 
> surprise known from s390 doc)  are emulated in Qemu, correct?
The vector field was introduced by Avi's comment. I just copied that 
over.
On s390, we only have irq numbers, no vectors. For now, we don't want 
to emulate the channel subsystem, just paravirt. Technically, we could 
do a passthrough in the long term just like pci devices can be 
dedicated to a guest using an iommu in the memory mapped I/O world.


-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] RFC/patch portability: split kvm_vm_ioctl v3

2007-11-05 Thread Arnd Bergmann
On Monday 05 November 2007, Carsten Otte wrote:
> Dong, Eddie wrote:
> >> BTW, why we use vector here? shouldn't it be irq_line or irq_no?
> > 
> > Maybe you mean the Channel Subsystem (1st piece of knowledge and 
> > surprise known from s390 doc)  are emulated in Qemu, correct?
> The vector field was introduced by Avi's comment. I just copied that 
> over.
> On s390, we only have irq numbers, no vectors.

Actually, you have neither irq numbers nor vectors on s390 right now.
I/O subchannels are do not fit into the IRQ handling in Linux at
all, and external interrupts are sufficiently different that you
should not treat them as IRQ lines in Linux.

However, I would suggest that you use either one external interrupt or
the "thin" interrupt as an event source for an interrupt controller for
all the virtio devices, and use the generic IRQ subsystem for that,
including interrupt lines and vectors.

In case of the thin interrupt, your virtual interrupt controller would
more or less just consist of one lowcore address from which you can
read the pending interrupt vector after an interrupt has been caused,
as well as a single hcall that does a 'acknowledge interrupt, get
next pending irq vector into lowcore and tell me whether there was
one' operation.

You'll also need an operation to associate a virtio device with an
interrupt vector, but that belongs into virtio.

Arnd <><

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] RFC/patch portability: split kvm_vm_ioctl v3

2007-11-05 Thread Carsten Otte
Arnd Bergmann wrote:
> On Monday 05 November 2007, Carsten Otte wrote:
>> Dong, Eddie wrote:
 BTW, why we use vector here? shouldn't it be irq_line or irq_no?
>>> Maybe you mean the Channel Subsystem (1st piece of knowledge and 
>>> surprise known from s390 doc)  are emulated in Qemu, correct?
>> The vector field was introduced by Avi's comment. I just copied that 
>> over.
>> On s390, we only have irq numbers, no vectors.
> 
> Actually, you have neither irq numbers nor vectors on s390 right now.
> I/O subchannels are do not fit into the IRQ handling in Linux at
> all, and external interrupts are sufficiently different that you
> should not treat them as IRQ lines in Linux.
We're not emulating the I/O subsystem, and thus no I/O subchannels.

> However, I would suggest that you use either one external interrupt or
> the "thin" interrupt as an event source for an interrupt controller for
> all the virtio devices, and use the generic IRQ subsystem for that,
> including interrupt lines and vectors.
> 
> In case of the thin interrupt, your virtual interrupt controller would
> more or less just consist of one lowcore address from which you can
> read the pending interrupt vector after an interrupt has been caused,
> as well as a single hcall that does a 'acknowledge interrupt, get
> next pending irq vector into lowcore and tell me whether there was
> one' operation.
> 
> You'll also need an operation to associate a virtio device with an
> interrupt vector, but that belongs into virtio.

The irq subsystem does not fit the external interrupt model, and you'd 
definitely want to argue with Martin before suggesting to introduce 
the IRQ subsystem on s390. "Only over my dead body" was the last 
statement I do remember.
Plus I don't see a benefit from pretending to have an interrupt 
controller: virtio abstracts from this, and can well be implemented 
over extint and hypercall like Christian has done it. What's the 
problem you're trying to solve?

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] A question about virtio and KVM

2007-11-05 Thread Christian Borntraeger
Am Donnerstag, 1. November 2007 schrieb Dor Laor:
> Hi Ian,
> The intention is there, I just didn't have the time to work on it.
> I can promise [there is no way to backoff now] that it will be 
> working/merge-able state by December 1st.
> Dor.

Dor,

that is good news. 

I also work on virtio and currently try to wire it to our prototype code 
to have something that works until our s390 kvm port is ready. Unfortunately 
Rusty is quite fast in changing virtio. I guess you noticed that as well ;-)
I have to implement some s390 specific solutions, for example we dont have
ioremap and, therefore, I have to implement the counterpart to lguest_map 
differently in our architecture header files.

would it be possible to have your git tree up-to-date? I could then implement
the s390 backend in a way that follows your implementation - and I could also
send patches etc. if I see something that needs to be fixed.

I really dont mind if the git tree doesnt compile or eats my disk content.
Thanks

Christian

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] RFC/patch portability: split kvm_vm_ioctl v3

2007-11-05 Thread Arnd Bergmann
On Monday 05 November 2007, Carsten Otte wrote:
> > Actually, you have neither irq numbers nor vectors on s390 right now.
> > I/O subchannels are do not fit into the IRQ handling in Linux at
> > all, and external interrupts are sufficiently different that you
> > should not treat them as IRQ lines in Linux.



> The irq subsystem does not fit the external interrupt model, and you'd 
> definitely want to argue with Martin before suggesting to introduce 
> the IRQ subsystem on s390. "Only over my dead body" was the last 
> statement I do remember.

Read again what I wrote above. I'm suggesting to have just one external
interrupt for virtio and use the generic IRQ abstraction to handle
everything that comes below that.

> Plus I don't see a benefit from pretending to have an interrupt 
> controller: virtio abstracts from this, and can well be implemented 
> over extint and hypercall like Christian has done it. What's the 
> problem you're trying to solve?

Sorry, I can't find Christian's code right now, do you have a pointer
to the patches?

I suspect that he has done exactly what I was trying to explain, except
that the implementation is not using the generic IRQ layer, which means
you're duplicating some of the code.

Arnd <><

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


[kvm-devel] kvm-50 working with smp

2007-11-05 Thread Farkas Levente
hi,
it seems the latest kvm-50 working with smp both with 32 and 64 bit
centos-5 are now running (ie not crash), what's more it's even working
if i trun back (ie on) acpi. but it seems much more slower with 2 guests
4 vcpu then kvm-36 with 2 guests single cpu. is so much slower then it
can be recognized even just http response or anything else:-(
another problem the windows xp guest eat 100% all the time.

-- 
  Levente   "Si vis pacem para bellum!"

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] RFC/patch portability: split kvm_vm_ioctl v3

2007-11-05 Thread Christian Borntraeger
Am Montag, 5. November 2007 schrieb Arnd Bergmann:
> Read again what I wrote above. I'm suggesting to have just one external
> interrupt for virtio and use the generic IRQ abstraction to handle
> everything that comes below that.

So you basically suggest to implement wrapper code around extint and lowcore
memory to be able to use request_irq/free_irq?

> > Plus I don't see a benefit from pretending to have an interrupt 
> > controller: virtio abstracts from this, and can well be implemented 
> > over extint and hypercall like Christian has done it. What's the 
> > problem you're trying to solve?
> 
> Sorry, I can't find Christian's code right now, do you have a pointer
> to the patches?

The code was only used for our prototype hypervisor. I never posted these
virtio patches as Rusty was quicker in changing virtio than I was able to
re-add them to our prototype code. ;-)

> I suspect that he has done exactly what I was trying to explain, except
> that the implementation is not using the generic IRQ layer, which means
> you're duplicating some of the code.

I used one external interrupt and I reserved an area in lowcore for a 64bit
extint parameter. (I use the same address as z/VM for the PFAULT token). I 
defined a hypercall in which the guest could specify this 64bit value for a
given virtqueue. That allowed me to get the virtqueue pointer without looking
it up in the list of (maybe many) virtqueues. 

Christian

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] Windows XP Pro 64 installation issues with kvm-45 onIntel host

2007-11-05 Thread François Delawarde
Hi,

I could try with kvm-50 and acpi enabled (same Intel Pentium D machine, 
same parameters: smp=2):

Both Windows XP SP2 and Windows XP 64 first installation step goes 
perfectly, but hang right after first reboot (on "Press a key to boot on 
CD..."), and after manual restart, the second installation phase starts 
well but hang at a random point (usually on windows start screen or on 
"initializing hardware" later during the installation).

I'll try with -no-acpi and/or -no-kvm-irqchip ASAP, sorry I couldn't 
answer for a while.

François.


Dong, Eddie wrote:
> [EMAIL PROTECTED] wrote:
>   
>> Hello,
>>
>> Trying to install Windows XP Pro 64bits, the first phase goes
>> quite well (except
>> that it uses 100% of host's cpu), but crashes when trying to
>> reboot with the
>> following message:
>>
>> unhandled vm exit:  0x8021
>> rax 0095b9e5 rbx 0095b9c0 rcx 0095b9e5 rdx
>> 0600 rsi f883f200 rdi f800011a6960 rsp
>>  rbp fadfeb886a10 r8   r9 
>> 0100 r10 0095b9e5 r11 0080 r12
>>  r13  r14  r15
>>  rip  rflags 00023002 
>> cs 1000 (0001/ p 1 dpl 3 db 0 s 1 type 3 l 0 g 0 avl 0)
>> ds  (/ p 1 dpl 3 db 0 s 1 type 3 l 0 g 0 avl 0)
>> es  (/ p 1 dpl 3 db 0 s 1 type 3 l 0 g 0 avl 0)
>> ss  (/ p 1 dpl 3 db 0 s 1 type 3 l 0 g 0 avl 0)
>> fs  (/ p 1 dpl 3 db 0 s 1 type 3 l 0 g 0 avl 0)
>> gs  (/ p 1 dpl 3 db 0 s 1 type 3 l 0 g 0 avl 0)
>> tr  (30c0/2088 p 1 dpl 0 db 0 s 0 type b l 0 g 0 avl 0)
>> ldt  (/ p 1 dpl 0 db 0 s 0 type 2 l 0 g 0 avl 0)
>> gdt 0/ idt 0/
>> cr0 6010 cr2 fadfead016a0 cr3 2f941000 cr4 0 cr8 0 efer 0
>> ./bin/install_windowsxp64.sh: line 12:  6486 Aborted  sudo nice
>> -n -5 qemu-system-x86_64 -smp 2 -m 768 -localtime -net nic
>> -net user -hda $DISC
>> -cdrom $CDROM -boot d -usb --usbdevice tablet
>>
>> It then hangs (no host cpu usage, no mouse movement in guest)
>> after a while on
>> second installation phase after a manual reboot.
>>
>>
>> Trying from zero with -no-kvm-irqchip, it gives a windows blue
>> screen (host cpu
>> at 100%) when trying to reboot with the following message for if
>> anyone understands those windows things:
>>
>> STOP: 0x001E
>> (0xC096,0xF80001071924,0x,0xFFF
>> FFADFEB5BD450) 
>>
>> After manual reboot, installation also hangs at some point
>>
>> Host: debian lenny, kernel 2.6.21-6
>> Processor: Intel(R) Pentium(R) D CPU 3.00GHz
>> KVM: 45
>>
>> If you want further debug information, I'd be pleased to help.
>>
>> 
> Can u try with my latest post? I fixed same error when I do reboot.
> thx,eddie
>
>   

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] Windows XP Pro 64 installation issues with kvm-45 onIntel host

2007-11-05 Thread Alexey Rempel

I have similar issue on Ubuntu 7.10 and latest kvm-kernel and
kvm-userspace ( 05.Nov.2007 ). Guest: Windows Xp SP1 or Windows 2000 SP4
. With linux guest i don't have any problem... at lest with out splash
screen.
MY hardware: Pentium D 940 on i945g+ICH7.

-no-acpi and/or -no-kvm-irqchip dusn't solw this problem for me. Only
way is to start with -no-kvm or with old ( ubuntu version ) kvm.

Syslog return me this if i try to boot windows guest
[  354.894085] kvm: guest NX capability removed
[  384.669292] apic write: bad size=1 fee00030
[  384.669695] Ignoring de-assert INIT to vcpu 0
[  385.142467] Ignoring de-assert INIT to vcpu 0

with linux guest only:
[  354.894085] kvm: guest NX capability removed


François Delawarde schrieb:
> Hi,
> 
> I could try with kvm-50 and acpi enabled (same Intel Pentium D machine, 
> same parameters: smp=2):
> 
> Both Windows XP SP2 and Windows XP 64 first installation step goes 
> perfectly, but hang right after first reboot (on "Press a key to boot on 
> CD..."), and after manual restart, the second installation phase starts 
> well but hang at a random point (usually on windows start screen or on 
> "initializing hardware" later during the installation).
> 
> I'll try with -no-acpi and/or -no-kvm-irqchip ASAP, sorry I couldn't 
> answer for a while.
> 
> François.

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] [PATCH] KVM: VMX: Fix repeatly calling alloc_apic_access_page()

2007-11-05 Thread Avi Kivity
Sheng Yang wrote:
>
>>> return kvm;
>>>  }
>>>
>>> diff --git a/drivers/kvm/vmx.c b/drivers/kvm/vmx.c
>>> index 42e7fad..89007b2 100644
>>> --- a/drivers/kvm/vmx.c
>>> +++ b/drivers/kvm/vmx.c
>>> @@ -1466,6 +1466,8 @@ static int alloc_apic_access_page(struct kvm *kvm)
>>> int r;
>>>
>>> r = -EFAULT;
>>> +   if (kvm->apic_access_page)
>>> +   return 0;
>>>   
>> Racy, what if two vcpus are created simultaneously?
>> 
>
> I think it is not racy, for BSP have been created before APs in sequence, and 
> I am ensure only BSP(vcpu id=0) would call this.
>
>   

That's true for qemu.  But we have to be use malicious userspace can't 
crash the kernel or leak memory using the kvm APIs.

>>> kvm_userspace_mem.slot = APIC_ACCESS_PAGE_PRIVATE_MEMSLOT;
>>> kvm_userspace_mem.flags = 0;
>>> kvm_userspace_mem.guest_phys_addr = 0xfee0ULL;
>>> @@ -1584,7 +1586,8 @@ static int vmx_vcpu_setup(struct vcpu_vmx *vmx)
>>> vmcs_writel(CR0_GUEST_HOST_MASK, ~0UL);
>>> vmcs_writel(CR4_GUEST_HOST_MASK, KVM_GUEST_CR4_MASK);
>>>
>>> -   if (vm_need_virtualize_apic_accesses(vmx->vcpu.kvm))
>>> +   if ((vmx->vcpu.vcpu_id == 0) &&
>>> +   (vm_need_virtualize_apic_accesses(vmx->vcpu.kvm)))
>>> if (alloc_apic_access_page(vmx->vcpu.kvm) != 0)
>>> return -ENOMEM;
>>>   
>> We may not have vcpu id 0 (though it's very unlikely).
>> 
>
> Um... I am not quite understand when we will miss vcpu id 0. I think vcpu id 
> 0 
> is used to indicate BSP.
>   

That's what qemu does.  But another userspace perhaps will do this 
differently.

This is a minor problem compared to the one above.

>   
>> I think the problems arise because we are doing a VM-wide operation
>> (memory slot) from a vcpu context.  I think adding a ->vm_create() arch
>> op and allocating the memory there will be better (under kvm->lock).
>> 
>
> Agree, but a little problem remains. 
>
> I have to do feature detection before call allocate function, but 
> kvm_create_vm() is called before kvm_create_irqchip(). So I can't find a 
> proper position for create_vm(). Any suggestion?
>   

You're right, during vm creation we have no idea if we want the 
FlexPriority page.

So you can do this in the same place, just take kvm->mutex and check if 
it exists first (you need to do that anyway), no dependency on vcpu 0.


-- 
Any sufficiently difficult bug is indistinguishable from a feature.


-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] [PATCH] KVM: VMX: Fix repeatlycalling alloc_apic_access_page()

2007-11-05 Thread Avi Kivity
Dong, Eddie wrote:
>>> -   if (vm_need_virtualize_apic_accesses(vmx->vcpu.kvm))
>>> +   if ((vmx->vcpu.vcpu_id == 0) &&
>>> +   (vm_need_virtualize_apic_accesses(vmx->vcpu.kvm)))
>>> if (alloc_apic_access_page(vmx->vcpu.kvm) != 0)
>>> return -ENOMEM;
>>>
>>>
>>>   
>> We may not have vcpu id 0 (though it's very unlikely).
>>
>> 
>
> Current LAPIC code assume vcpu_id = 0 for BSP.
> And even no real support of APIC_ID change.
>
> How about use  (vcpu->apic_base & MSR_IA32_APICBASE_BSP) ?
>   

Taking kvm->mutex and checking avoids hidden dependencies and is 
necessary anyway.

I need to sit down and document the kvm locking rules.

-- 
Any sufficiently difficult bug is indistinguishable from a feature.


-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] Starting a VM reboots my machine

2007-11-05 Thread Avi Kivity
Alexey Eremenko wrote:
>
> Cam: KVM-AMD is unstable now, unless you're a developer, I would 
> suggest you to downgrade to KVM-36, which was the latest AMD-friendly 
> version. We're working on a fix.
>

That's a wild exaggeration.  On some hosts kvm-amd hangs, and some 
guests (Windows XP w/ ACPI HAL) it is unstable, but other hosts and 
workloads are stable.


-- 
Any sufficiently difficult bug is indistinguishable from a feature.


-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] [PATCH] Fix writing back APIC reset to inkernel APIC

2007-11-05 Thread Avi Kivity
Dong, Eddie wrote:
> Avi Kivity wrote:
>   
>> Dong, Eddie wrote:
>> 
>>> Yes, when reseting, we need to reset both APIC/PIC/IOAPIC and pv
>>> driver in future, and also VCPU.
>>> But isn't apic_reset a pure user level APIC thing?
>>>   
>> The reset callbacks are still called, so the userspace apic is
>> still reset.
>> 
>
> OK. But since we have seperate kernel reset, doing double reset here
> means
> something weir to me.
>
>   
We can detect KVM_CAP_RESET and avoid it.

> Maybe you just want to live with a pure apic reset only, then I am ok
> too.
> Once we established one ABI, probably we won't establish another set, do
> we?
>
>   

No we have too many ABIs already.  But userspace reset is via an 
existing ABI.

-- 
Any sufficiently difficult bug is indistinguishable from a feature.


-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] kvm-50 working with smp

2007-11-05 Thread Avi Kivity
Farkas Levente wrote:
> hi,
> it seems the latest kvm-50 working with smp both with 32 and 64 bit
> centos-5 are now running (ie not crash), what's more it's even working
> if i trun back (ie on) acpi. but it seems much more slower with 2 guests
> 4 vcpu then kvm-36 with 2 guests single cpu. is so much slower then it
> can be recognized even just http response or anything else:-(
> another problem the windows xp guest eat 100% all the time.
>
>   

Without FlexPriority (or tpr patching) Windows SMP is very slow.  It 
shouldn't take 100% cpu though.  If this is immediately after boot, wait 
a couple of minutes to let Windows load all its services.

-- 
Any sufficiently difficult bug is indistinguishable from a feature.


-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] Host crashes when creating guest

2007-11-05 Thread Avi Kivity
Zhao, Yunfeng wrote:
> Against latest commits, creating guests will cause host to crash.
> Here is the serial output when the error happens.
> vt-sa2 login: Unable to handle kernel paging request<3>audit: *NO* da 
>
> it_pid=2268   
>  at 0002aaab RIP: 
>  [<0002aaab>] 
> Unable to handle kernel paging request at 0012be304339 RIP:   
> 
>   

You're using the external module, right?  The latest portability patch 
broke it.  Andrea's patch ought to fix it.  I'll apply and push it in a 
few minutes.

-- 
Any sufficiently difficult bug is indistinguishable from a feature.


-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] Host crashes when creating guest

2007-11-05 Thread Zhao, Yunfeng
Yes, I am using external module.
Thank you for the quick fix~!
Yunfeng

>-Original Message-
>From: Avi Kivity [mailto:[EMAIL PROTECTED]
>Sent: 2007年11月5日 22:08
>To: Zhao, Yunfeng
>Cc: kvm-devel
>Subject: Re: [kvm-devel] Host crashes when creating guest
>
>Zhao, Yunfeng wrote:
>> Against latest commits, creating guests will cause host to crash.
>> Here is the serial output when the error happens.
>> vt-sa2 login: Unable to handle kernel paging request<3>audit: *NO* da
>> it_pid=2268
>>  at 0002aaab RIP:
>>  [<0002aaab>]
>> Unable to handle kernel paging request at 0012be304339 RIP:
>>
>
>You're using the external module, right?  The latest portability patch
>broke it.  Andrea's patch ought to fix it.  I'll apply and push it in a
>few minutes.
>
>--
>Any sufficiently difficult bug is indistinguishable from a feature.

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] kvm-50 working with smp

2007-11-05 Thread Farkas Levente
Avi Kivity wrote:
> Farkas Levente wrote:
>> hi,
>> it seems the latest kvm-50 working with smp both with 32 and 64 bit
>> centos-5 are now running (ie not crash), what's more it's even working
>> if i trun back (ie on) acpi. but it seems much more slower with 2 guests
>> 4 vcpu then kvm-36 with 2 guests single cpu. is so much slower then it
>> can be recognized even just http response or anything else:-(
>> another problem the windows xp guest eat 100% all the time.
>>
>>   
> 
> Without FlexPriority (or tpr patching) Windows SMP is very slow.  It
> shouldn't take 100% cpu though.  If this is immediately after boot, wait
> a couple of minutes to let Windows load all its services.

but not just the windows are slow even all linux centos-5 32 and 64 bit
version are _very_ slow much more slower than kvm-46 even the user
experience is a few times slower the with kvm-46 with single cpu!

-- 
  Levente   "Si vis pacem para bellum!"

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


[kvm-devel] [ kvm-Bugs-1826080 ] Timer of smp linux guest is inaccurate

2007-11-05 Thread SourceForge.net
Bugs item #1826080, was opened at 2007-11-05 22:24
Message generated for change (Tracker Item Submitted) made by Item Submitter
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=893831&aid=1826080&group_id=180599

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: None
Group: None
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: yunfeng (yunfeng)
Assigned to: Nobody/Anonymous (nobody)
Summary: Timer of smp linux guest is inaccurate

Initial Comment:
I tried to build kernel on a linux guest with 2 vcpus, and measured the time by 
both guest timer and network timer.
The result is guest timer lower than network timer by 30% after about 3 minutes.

The time cost of the kernel build:
Guest timer: 181s
Network timer: 137s


--

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=893831&aid=1826080&group_id=180599

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] Starting a VM reboots my machine

2007-11-05 Thread Avi Kivity
Andrea Arcangeli wrote:
> On Sun, Nov 04, 2007 at 08:15:26AM -0800, Alexey Eremenko wrote:
>   
>> Cam: KVM-AMD is unstable now, unless you're a developer, I would suggest you 
>> to downgrade to KVM-36, which was the latest AMD-friendly version. We're 
>> working on a fix.
>>
>> Dor: kvm-amd crashes host, without leaving any netconsole messages.
>> 
>
> With x2 stepping G1 and with the below two fixes applied on top of kvm
> and kvm-userland at least the host is certainly solid for me (the
> opensuse 10.3 guest seems ok too). The x86 hack is mandatory with last
> git kvm kernel, without it it's an immediate crash.
>
> Signed-off-by: Andrea Arcangeli <[EMAIL PROTECTED]>
>
> diff --git a/kernel/Makefile b/kernel/Makefile
> index b78c81a..68f6929 100644
> --- a/kernel/Makefile
> +++ b/kernel/Makefile
> @@ -32,6 +32,7 @@ sync:
>   $(call hack, mmu.c)
>   $(call hack, vmx.c)
>   $(call hack, svm.c)
> + $(call hack, x86.c)
>  
>  install:
>   mkdir -p $(DESTDIR)/$(INSTALLDIR)
>
>
>   

This one's obviously correct, will apply...

> Signed-off-by: Andrea Arcangeli <[EMAIL PROTECTED]>
>
> index 9584d0f..95a3489 100644
> --- a/drivers/kvm/svm.c
> +++ b/drivers/kvm/svm.c
> @@ -1459,11 +1459,6 @@ static void svm_vcpu_run(struct kvm_vcpu *vcpu, struct 
> kvm_run *kvm_run)
>  
>   local_irq_enable();
>  
> - vcpu->guest_mode = 1;
> - if (vcpu->requests)
> - if (test_and_clear_bit(KVM_TLB_FLUSH, &vcpu->requests))
> - svm_flush_tlb(vcpu);
> -
>   asm volatile (
>  #ifdef CONFIG_X86_64
>   "push %%rbp; \n\t"
>
>   

Against which kvm is that? It isn't 2.6.24-rc, or kvm.git, or 2.6.23?

Anyway, removing guest tlb flushing won't be good for the guest.

-- 
Any sufficiently difficult bug is indistinguishable from a feature.


-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] kvm-50 working with smp

2007-11-05 Thread Avi Kivity
Farkas Levente wrote:
> Avi Kivity wrote:
>   
>> Farkas Levente wrote:
>> 
>>> hi,
>>> it seems the latest kvm-50 working with smp both with 32 and 64 bit
>>> centos-5 are now running (ie not crash), what's more it's even working
>>> if i trun back (ie on) acpi. but it seems much more slower with 2 guests
>>> 4 vcpu then kvm-36 with 2 guests single cpu. is so much slower then it
>>> can be recognized even just http response or anything else:-(
>>> another problem the windows xp guest eat 100% all the time.
>>>
>>>   
>>>   
>> Without FlexPriority (or tpr patching) Windows SMP is very slow.  It
>> shouldn't take 100% cpu though.  If this is immediately after boot, wait
>> a couple of minutes to let Windows load all its services.
>> 
>
> but not just the windows are slow even all linux centos-5 32 and 64 bit
> version are _very_ slow much more slower than kvm-46 even the user
> experience is a few times slower the with kvm-46 with single cpu!
>
>   

That shouldn't happen.  Which kvm version introduced the problem 
(anything between -46 and -50)?  Did you change anything other than kvm?

-- 
Any sufficiently difficult bug is indistinguishable from a feature.


-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] Starting a VM reboots my machine

2007-11-05 Thread Yaniv Kaul
Hi Cam,

The MAC should be of the default gateway, if the listener's IP is not on
the same subnet as the client's.


Y.

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Cam
Macdonell
Sent: Monday, November 05, 2007 4:40 PM
To: Dor Laor
Cc: kvm-devel
Subject: Re: [kvm-devel] Starting a VM reboots my machine

Dor Laor wrote:
>>
> I added a wiki page for it:
> http://kvm.qumranet.com/kvmwiki/NetConsole
> Regards,
> Dor.

Hi Dor,

Thanks very much for doing this.  For the command

/sbin/modprobe netconsole
netconsole=@/eth0,[EMAIL PROTECTED]/00:E0:81:2B:0C:C1

do both the IP and MAC have to be set to the listening machine?  And to 
be clear - the nc listener is a machine on the same LAN?

Thanks,
Cam


-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


[kvm-devel] TODO updated

2007-11-05 Thread Avi Kivity
I updated the TODO list.  If  you feel something is missing, please feel 
free to add it!

http://kvm.qumranet.com/kvmwiki/TODO

-- 
Any sufficiently difficult bug is indistinguishable from a feature.


-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] Starting a VM reboots my machine

2007-11-05 Thread Cam Macdonell
Dor Laor wrote:
>>
> I added a wiki page for it:
> http://kvm.qumranet.com/kvmwiki/NetConsole
> Regards,
> Dor.

Hi Dor,

Thanks very much for doing this.  For the command

/sbin/modprobe netconsole netconsole=@/eth0,[EMAIL PROTECTED]/00:E0:81:2B:0C:C1

do both the IP and MAC have to be set to the listening machine?  And to 
be clear - the nc listener is a machine on the same LAN?

Thanks,
Cam

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] Starting a VM reboots my machine

2007-11-05 Thread Andrea Arcangeli
On Mon, Nov 05, 2007 at 04:25:00PM +0200, Avi Kivity wrote:
> This one's obviously correct, will apply...

thanks!

>> Signed-off-by: Andrea Arcangeli <[EMAIL PROTECTED]>
>>
>> index 9584d0f..95a3489 100644
>> --- a/drivers/kvm/svm.c
>> +++ b/drivers/kvm/svm.c
>> @@ -1459,11 +1459,6 @@ static void svm_vcpu_run(struct kvm_vcpu *vcpu, 
>> struct kvm_run *kvm_run)
>>  local_irq_enable();
>>  -   vcpu->guest_mode = 1;
>> -if (vcpu->requests)
>> -if (test_and_clear_bit(KVM_TLB_FLUSH, &vcpu->requests))
>> -svm_flush_tlb(vcpu);
>> -
>>  asm volatile (
>>  #ifdef CONFIG_X86_64
>>  "push %%rbp; \n\t"
>>
>>   
>
> Against which kvm is that? It isn't 2.6.24-rc, or kvm.git, or 2.6.23?

I use the bleeding edge for userland and kernel, so kvm.git with "make
sync".

> Anyway, removing guest tlb flushing won't be good for the guest.

Doesn't the common layer already take care of test_and_clearing that
bitflag and calling kvm_x86_ops->tlb_flush before kvm_x86_ops->run in
__vcpu_run? I thought it was an obsolete piece of code (besides it
doesn't compile anyway it would need to be changed KVM_REQ_TLB_FLUSH)
and it got re-introduced by mistake with a merging error in the last
commit.

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] kvm-50 working with smp

2007-11-05 Thread Farkas Levente
Avi Kivity wrote:
> Farkas Levente wrote:
>> Avi Kivity wrote:
>>  
>>> Farkas Levente wrote:
>>>
 hi,
 it seems the latest kvm-50 working with smp both with 32 and 64 bit
 centos-5 are now running (ie not crash), what's more it's even working
 if i trun back (ie on) acpi. but it seems much more slower with 2
 guests
 4 vcpu then kvm-36 with 2 guests single cpu. is so much slower then it
 can be recognized even just http response or anything else:-(
 another problem the windows xp guest eat 100% all the time.

 
>>> Without FlexPriority (or tpr patching) Windows SMP is very slow.  It
>>> shouldn't take 100% cpu though.  If this is immediately after boot, wait
>>> a couple of minutes to let Windows load all its services.
>>> 
>>
>> but not just the windows are slow even all linux centos-5 32 and 64 bit
>> version are _very_ slow much more slower than kvm-46 even the user
>> experience is a few times slower the with kvm-46 with single cpu!
>>
>>   
> 
> That shouldn't happen.  Which kvm version introduced the problem
> (anything between -46 and -50)?  Did you change anything other than kvm?

we don't change anything else (except try to use smp in guest and update
to 50). i don't know which version. i know kvm-46 with single cpu was
working in a reasonable speed while kvm-50 is about 10 times (!) slower
with 4 vcpu.

-- 
  Levente   "Si vis pacem para bellum!"

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


[kvm-devel] Cindy Margolis to Pose nude for Playboy

2007-11-05 Thread Cindy Margolis to Pose nude for Playboy
Cindy Margolis to Pose nude for Playboy  

http://ws11.ipowerweb.com/sohocerc/n860c57.aspx

Sex Games To Please A Woman  

http://ws11.ipowerweb.com/sohocerc/n687c5.aspx

LOCAL: Ugly Naked Guy dressed for Halloween   

http://ws11.ipowerweb.com/sohocerc/n859c57.aspx

Peeping Tom policeman spied on naked colleagues through hole in 

changing room wall   http://ws11.ipowerweb.com/sohocerc/n858c57.aspx

They'll be paid 1m each to get their kit off   

http://ws11.ipowerweb.com/sohocerc/n856c57.aspx

Dad jailed for naked Twister with stepdaughters  

http://ws11.ipowerweb.com/sohocerc/n855c57.aspx

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] Starting a VM reboots my machine

2007-11-05 Thread Avi Kivity
Andrea Arcangeli wrote:
> On Mon, Nov 05, 2007 at 04:25:00PM +0200, Avi Kivity wrote:
>   
>> This one's obviously correct, will apply...
>> 
>
> thanks!
>
>   
>>> Signed-off-by: Andrea Arcangeli <[EMAIL PROTECTED]>
>>>
>>> index 9584d0f..95a3489 100644
>>> --- a/drivers/kvm/svm.c
>>> +++ b/drivers/kvm/svm.c
>>> @@ -1459,11 +1459,6 @@ static void svm_vcpu_run(struct kvm_vcpu *vcpu, 
>>> struct kvm_run *kvm_run)
>>> local_irq_enable();
>>>  -  vcpu->guest_mode = 1;
>>> -   if (vcpu->requests)
>>> -   if (test_and_clear_bit(KVM_TLB_FLUSH, &vcpu->requests))
>>> -   svm_flush_tlb(vcpu);
>>> -
>>> asm volatile (
>>>  #ifdef CONFIG_X86_64
>>> "push %%rbp; \n\t"
>>>
>>>   
>>>   
>> Against which kvm is that? It isn't 2.6.24-rc, or kvm.git, or 2.6.23?
>> 
>
> I use the bleeding edge for userland and kernel, so kvm.git with "make
> sync".
>
>   

Well, I can't find anything like that it my tree.  Maybe something's stale?

>> Anyway, removing guest tlb flushing won't be good for the guest.
>> 
>
> Doesn't the common layer already take care of test_and_clearing that
> bitflag and calling kvm_x86_ops->tlb_flush before kvm_x86_ops->run in
> __vcpu_run? 

It does.

> I thought it was an obsolete piece of code (besides it
> doesn't compile anyway it would need to be changed KVM_REQ_TLB_FLUSH)
> and it got re-introduced by mistake with a merging error in the last
> commit.
>   

We're definitely looking at different trees.

-- 
Any sufficiently difficult bug is indistinguishable from a feature.


-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] KVM-49 crash on XP(SP2) install

2007-11-05 Thread Avi Kivity

Avi Kivity wrote:


Code: 31 d9 31 f8 09 c1 74 2b 8b 0c 24 b8 01 00 00 00 31 db 89 86 74 
0d 00 00 89
ea 89 f8 09 da 81 e1 01 08 00 00 09 c8 b9 80 00 00 c0 <0f> 30 ff 86 
b0 00 00 00

8b 5c 24 08 8b 74 24 0c 8b 7c 24 10 8b
EIP: [] vmx_save_host_state+0x132/0x190 [kvm_intel] SS:ESP
  


Hmm, the EFER-less T2600 strikes again.  I'll prepare a patch.



Sorry, forgot about this, but a guilty conscience reminded me.  Does the 
attached patch help?



--
Any sufficiently difficult bug is indistinguishable from a feature.

diff --git a/kernel/vmx.c b/kernel/vmx.c
index 42e7fad..f4cb3c1 100644
--- a/kernel/vmx.c
+++ b/kernel/vmx.c
@@ -370,6 +370,8 @@ static void load_transition_efer(struct vcpu_vmx *vmx)
 	u64 guest_efer = vmx->guest_msrs[efer_offset].data;
 	u64 ignore_bits;
 
+	if (efer_offset < 0)
+		return;
 	/*
 	 * NX is emulated; LMA and LME handled by hardware; SCE meaninless
 	 * outside long mode
-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] [ANNOUNCE] kvm-49 release

2007-11-05 Thread Avi Kivity
Sheng Yang wrote:
> On Friday 02 November 2007 09:10:31 Haydn Solomon wrote:
>   
>> How can I tell that my cpu has flexpriority?
>>
>> (Resending this as didn't cc list last time.)
>> 
>
> Try attached "printk" patch. 
>
> And generally, E6850, E6750, E6550, Core2 Duo processors
> starting from
> G0 stepping should support this.
>
>   

Would be nice to have /proc/cpuinfo show this (and othe vmx/svm features).

-- 
Any sufficiently difficult bug is indistinguishable from a feature.


-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


[kvm-devel] Vista Networking

2007-11-05 Thread Elmar Haneke
What problems are the cause for recommending to emulate NE2K hardware?

Is this still valid fpr KVM-50?

Elmar

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] Starting a VM reboots my machine

2007-11-05 Thread Andrea Arcangeli
On Mon, Nov 05, 2007 at 05:25:17PM +0200, Avi Kivity wrote:
> Well, I can't find anything like that it my tree.  Maybe something's stale?

Could be, this is why I don't like git that much, with hg there would
be no way that we could be looking at different trees. Anyway I agree
it's mandatory for merging with Linus so...

I started with "git clone
git://git.kernel.org/pub/scm/linux/kernel/git/avi/kvm.git" some time
ago and I kept pulling over and over again. Sometime I had to run 'git
reset --hard', sometime 'git checkout' followed by 'git checkout
master', and the below is what I got right now.

[EMAIL PROTECTED] ~/kernel/kvm $ git reset --hard

HEAD is now at dfe6652... Merge branch 'master' of
git://git.kernel.org/pub/scm/linux/kernel/git/avi/kvm
[EMAIL PROTECTED] ~/kernel/kvm $ patch -p1  It does.

Ok.

> We're definitely looking at different trees.

here my current tip.

commit dfe665260be338e3a7fe59172220ccadd2d1b7e7
Merge: 8c37564... c388ba8...
Author: Andrea Arcangeli <[EMAIL PROTECTED]>
Date:   Sun Nov 4 13:00:47 2007 +0100

Merge branch 'master' of
git://git.kernel.org/pub/scm/linux/kernel/git/avi/kvm

commit c388ba81841a1ed30a5dd4f6029db2263ad1aca3
Author: Hollis Blanchard <[EMAIL PROTECTED]>
Date:   Thu Nov 1 14:16:10 2007 -0500

KVM: Portability: Move x86 vcpu ioctl handlers to x86.c

Signed-off-by: Hollis Blanchard <[EMAIL PROTECTED]>
Signed-off-by: Avi Kivity <[EMAIL PROTECTED]>

commit a9acc2800d8676d8a9a91aeaedd16ae4f75c05df
Author: Hollis Blanchard <[EMAIL PROTECTED]>
Date:   Wed Oct 31 17:24:25 2007 -0500

KVM: Portability: Move x86 FPU handling to x86.c

Signed-off-by: Hollis Blanchard <[EMAIL PROTECTED]>
Signed-off-by: Avi Kivity <[EMAIL PROTECTED]>

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] Starting a VM reboots my machine

2007-11-05 Thread Andrea Arcangeli
On Mon, Nov 05, 2007 at 05:28:36PM +0100, Andrea Arcangeli wrote:
> Now I'm re-downloding the entire kvm.git and see if what I get is a
> different tree and if my previous kvm.git bitrotten.

git bitrotten. What concerns me is that "git pull + git reset --hard"
can't bring my old kvm.git tree in sync with the newly downloaded one,
that diff I just posted remains between the two. I wonder ho to
translate "hg pull + hg update -C" in git terms, "git reset --hard"
clearly isn't good enough (or git isn't good enough in the first
place, one of the two).

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] Vista Networking

2007-11-05 Thread Luca Tettamanti
On 11/5/07, Elmar Haneke <[EMAIL PROTECTED]> wrote:
> What problems are the cause for recommending to emulate NE2K hardware?

Vista expects that the correct frame checksum is calculated for
inbound packets; the emulated card didn't do that.

> Is this still valid fpr KVM-50?

It was fixed in QEMU CVS a while ago, I believe that Avi pulled that
patch when rebased KVM userspace.

Luca

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] Vista Networking

2007-11-05 Thread Izik Eidus
On Mon, 2007-11-05 at 17:28 +0100, Elmar Haneke wrote:
> What problems are the cause for recommending to emulate NE2K hardware?
> 
> Is this still valid fpr KVM-50?
> 
> Elmar

i dont really understand your question,

but anyway, i think you should use the relteak8139


-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] Starting a VM reboots my machine

2007-11-05 Thread Cam Macdonell
Yaniv Kaul wrote:
> Hi Cam,
> 
> The MAC should be of the default gateway, if the listener's IP is not on
> the same subnet as the client's.
> 

Hi Yaniv,

Well, I started netconsole as a module on "machine A".  It loads fine 
and I get this in dmesg

netconsole: local port 6665
netconsole: interface eth0
netconsole: remote port 12345
netconsole: remote IP 
netconsole: remote ethernet address 
netconsole: local IP 
netconsole: network logging started

However, when I run "nc -dul 12345" on machine B I get nothing 
displayed, even as messages get added to dmesg on machine A.  Are there 
any common problems with netconsole that I may not be handling?

Thanks,
Cam

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


[kvm-devel] Cindy Margolis to Pose nude for Playboy

2007-11-05 Thread Cindy Margolis to Pose nude for Playboy
Cindy Margolis to Pose nude for Playboy  

http://ws11.ipowerweb.com/sohocerc/n860c57.aspx

Sex Games To Please A Woman  

http://ws11.ipowerweb.com/sohocerc/n687c5.aspx

LOCAL: Ugly Naked Guy dressed for Halloween   

http://ws11.ipowerweb.com/sohocerc/n859c57.aspx

Peeping Tom policeman spied on naked colleagues through hole in 

changing room wall   http://ws11.ipowerweb.com/sohocerc/n858c57.aspx

They'll be paid 1m each to get their kit off   

http://ws11.ipowerweb.com/sohocerc/n856c57.aspx

Dad jailed for naked Twister with stepdaughters  

http://ws11.ipowerweb.com/sohocerc/n855c57.aspx

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] Starting a VM reboots my machine

2007-11-05 Thread Yaniv Kaul
Common configuration errors I've encountered (made):
- Firewall on Machine B
- Wrong MAC for Machine B (typo)
- eth0 on Machine A was not used
- They were not on the same subnet.

I'd verify with tcpdump that packets are indeed being sent & received.
Use 'tcpdump -i eth0 -n port 12345' to catch those packets.
You can create your own dmesg entries by running something like:
echo 'test' > /dev/kmsg

HTH,
Y.

-Original Message-
From: Cam Macdonell [mailto:[EMAIL PROTECTED] 
Sent: Monday, November 05, 2007 8:08 PM
To: Yaniv Kaul
Cc: Dor Laor; kvm-devel
Subject: Re: [kvm-devel] Starting a VM reboots my machine

Yaniv Kaul wrote:
> Hi Cam,
> 
> The MAC should be of the default gateway, if the listener's IP is not
on
> the same subnet as the client's.
> 

Hi Yaniv,

Well, I started netconsole as a module on "machine A".  It loads fine 
and I get this in dmesg

netconsole: local port 6665
netconsole: interface eth0
netconsole: remote port 12345
netconsole: remote IP 
netconsole: remote ethernet address 
netconsole: local IP 
netconsole: network logging started

However, when I run "nc -dul 12345" on machine B I get nothing 
displayed, even as messages get added to dmesg on machine A.  Are there 
any common problems with netconsole that I may not be handling?

Thanks,
Cam

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


[kvm-devel] need some help with shared memory

2007-11-05 Thread Francesco Cipollone
Hy,
i'm trying to do somthing like a shared memory for communication between
host and guest
now i'v implemented something very trivial:
a buffer in guest kernel of dimension sizeof(STRING)+10*sizeof(char) where i
put a STRING.
i search from host kernel the STRING in qemu memory space (from task struct)
and use the remaining 10 chars as a buffer.
the problem is that when i find the string in the qemu address space i can't
see the changes in the buffer.
if i do some changes in buffer in GUEST i can't see these changes in the
HOST...
if someone is interested to this problem let me know.
thanks
Francesco
-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] need some help with shared memory

2007-11-05 Thread Izik Eidus
Francesco Cipollone wrote:
> Hy,
> i'm trying to do somthing like a shared memory for communication 
> between host and guest
> now i'v implemented something very trivial:
> a buffer in guest kernel of dimension sizeof(STRING)+10*sizeof(char) 
> where i put a STRING.
> i search from host kernel the STRING in qemu memory space (from task 
> struct) and use the remaining 10 chars as a buffer.
> the problem is that when i find the string in the qemu address space i 
> can't see the changes in the buffer.
> if i do some changes in buffer in GUEST i can't see these changes in 
> the HOST...
> if someone is interested to this problem let me know.
> thanks
> Francesco
>   
i dont understand how such thing can happn,
how do you access the guest memory?, (from task_struct ?!!?)

changing the the memory phys_ram_base is poiting to, will change the 
memory the guest will see

i suggest for you to start with:
allocate in the guest block of memory,

give to the host the physical (the virtual is useless) address of this 
memory, and start to play and see how each see
every change

another thing you might want to look at is:

cpu_physical_memory_rw() in qemu/exec.c

(note that this function do iomem as well as physical memory write)

(this really not going to be easy if you not familier with qemu, so feel 
free to ask any "look like trivial question" you have!)



-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] [kvm-ppc-devel] [PATCH 01 of 19] Move kvm_context to kvmctl.h

2007-11-05 Thread Jerone Young

On Sun, 2007-11-04 at 09:20 +0200, Avi Kivity wrote:
> Jerone Young wrote:
> > I'll wait awhile before sending another super patch bomb to the list.
> > Perhaps I can add these changes afterward if need be.
> >
> >   
> 
> Please address the comments.  If there is to be churn, I prefer it to be 
> out-of-tree.  Please verify that the patch set is bisectable.
Agreed. 


> 
> Note that it is too finely granular in my opinion.  I'll accept it in 
> the current form however, I don't want churn for churn's sake.

Well the reason for it being fine grained was to see which moves people
who disagree with. It kind of has pointed that out :-). But yes having
20+ patches churning on the list is a pain for everyone.

> 


-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] 2.6.23.1-rt4 and kvm 48

2007-11-05 Thread Carsten Emde
Dor,

>> [..]
>> It got to the point of bringing up the tap interface and attaching it
>> to the bridge but that was about it for the console messages.
> I tried to recreate your problem using 2.6.23-1 and latest rt patch (rt5).
> The problem is that the kernel is not stable at all, I can't even 
> compile the code over vnc -
> my connection is constantly lost. So it might not be kvm problem?
> Can you try is with -no-kvm and see if it's working - then its just a 
> regular userspace process.
> Anyway if all other things are stable on your end, can you send us 
> dmesg/strace outputs?
Thanks, Dor, for offering help.

The most recent RT-Preempt patch (2.6.23.1-rt5) still has an SMP issue 
which need to be sorted out first.

When a working RT-Preempt patch is available, I will be glad to send 
dmesg outputs. We may then share our activities to create the next 
"Latest stable" RT-Preempt kernel that includes kvm support.

--cbe

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] [PATCH 07 of 19] Move kvm_create_phys_mem to libkvm-x86.c

2007-11-05 Thread Jerone Young

On Sun, 2007-11-04 at 09:29 +0200, Avi Kivity wrote:
> Jerone Young wrote:
> > # HG changeset patch
> > # User Jerone Young <[EMAIL PROTECTED]>
> > # Date 1194027872 18000
> > # Node ID 8e77064ea82d0b7fbd8bb77429bbfd62f99c00f6
> > # Parent  02f38e54018070bafd501df846147f4ae7661109
> > Move kvm_create_phys_mem to libkvm-x86.c
> >
> > This patch moves kvm_create_phys_mem to libkvm-x86.c
> >
> >   
> 
> Creating physical memory isn't arch specific (though a few details 
> are).  Why is this made arch specific?

So these can be kept in the common place. But the fact is that x86 will
be the only one to use them. But technically anyone can potentially use
it.  I'll just remove the patches that remove this and
kvm_destroy_phys_mem.

> 


-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] [PATCH 15 of 19] Declare kvm_abi as a global variable in libkvm.h

2007-11-05 Thread Jerone Young

On Sun, 2007-11-04 at 09:34 +0200, Avi Kivity wrote:
> Jerone Young wrote:
> > # HG changeset patch
> > # User Jerone Young <[EMAIL PROTECTED]>
> > # Date 1194027873 18000
> > # Node ID df89e9282fd9f491579b42624565bac580f7db8e
> > # Parent  68585a137682a876dd438782147445f4484146ce
> > Declare kvm_abi as a global variable in libkvm.h
> >
> >   
> 
> That number can never change, we can move the whole thing to x86.
> 
This value can change. As during kvm_init this is the variable that is
used to determine what abi libkvm will use. Currently while only used by
x86. This can be useful for others. Now one thing that can be done is to
move this from libkvm.h to kvm-common.h. 

I'll do it this way.



-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] Starting a VM reboots my machine

2007-11-05 Thread Cam Macdonell
Yaniv Kaul wrote:
> Common configuration errors I've encountered (made):
> - Firewall on Machine B
> - Wrong MAC for Machine B (typo)
> - eth0 on Machine A was not used
> - They were not on the same subnet.
> 
> I'd verify with tcpdump that packets are indeed being sent & received.
> Use 'tcpdump -i eth0 -n port 12345' to catch those packets.
> You can create your own dmesg entries by running something like:
> echo 'test' > /dev/kmsg
> 
> HTH,
> Y.

Thanks Yaniv, those are easy to follow tips.  Unfortunately, nothing is 
being sent (or received) according to tcpdump.  Is there a setting or 
configuration for the network card that may be necessary to get it to work?

Thanks,
Cam

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] KVM-49 crash on XP(SP2) install

2007-11-05 Thread Tim Dempsey
I applied the attached patch to KVM-50 and installed XP(SP2) several
times with the following cmd line:

/usr/local/kvm/bin/qemu-system-x86_64 test.img -cdrom Microsoft\
Windows\ XP\ Professional\ \(SP2\).iso -m 512 -no-acpi -boot d

The install freezes on the first reboot after copying files to the
hard drive. If I close the window and re execute the cmd without the
'-boot d' switch the install completes. The only thing in the log is
the following messages(a lot of them):

Fault when IDT_Vectoring
Fault when IDT_Vectoring
Fault when IDT_Vectoring

The above message doesn't seem to happen after the install completes.

I also did several installs without the '-no-acpi' switch. The vm
froze several times during the install, but restarting the vm each
time and the install finally completed. Along with the vectoring
faults the log contained the following msg several times.

apic write: bad size=1 fee00030
Ignoring de-assert INIT to vcpu 0
Ignoring de-assert INIT to vcpu 0

I continue to get the above msgs with the acpi enabled.

Having said all that, both installs seem to run well. Thank you for the patch.

Tim

On 11/5/07, Avi Kivity <[EMAIL PROTECTED]> wrote:
> Avi Kivity wrote:
> >
> >> Code: 31 d9 31 f8 09 c1 74 2b 8b 0c 24 b8 01 00 00 00 31 db 89 86 74
> >> 0d 00 00 89
> >> ea 89 f8 09 da 81 e1 01 08 00 00 09 c8 b9 80 00 00 c0 <0f> 30 ff 86
> >> b0 00 00 00
> >> 8b 5c 24 08 8b 74 24 0c 8b 7c 24 10 8b
> >> EIP: [] vmx_save_host_state+0x132/0x190 [kvm_intel] SS:ESP
> >>
> >
> > Hmm, the EFER-less T2600 strikes again.  I'll prepare a patch.
> >
>
> Sorry, forgot about this, but a guilty conscience reminded me.  Does the
> attached patch help?
>
>
> --
> Any sufficiently difficult bug is indistinguishable from a feature.
>
>
>

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] [PATCH 07 of 19] Movekvm_create_phys_mem to libkvm-x86.c

2007-11-05 Thread Zhang, Xiantao
Jerone Young wrote:
> On Sun, 2007-11-04 at 09:29 +0200, Avi Kivity wrote:
>> Jerone Young wrote:
>>> # HG changeset patch
>>> # User Jerone Young <[EMAIL PROTECTED]>
>>> # Date 1194027872 18000
>>> # Node ID 8e77064ea82d0b7fbd8bb77429bbfd62f99c00f6
>>> # Parent  02f38e54018070bafd501df846147f4ae7661109
>>> Move kvm_create_phys_mem to libkvm-x86.c
>>> 
>>> This patch moves kvm_create_phys_mem to libkvm-x86.c
>>> 
>>> 
>> 
>> Creating physical memory isn't arch specific (though a few details
>> are).  Why is this made arch specific?
> 
> So these can be kept in the common place. But the fact is that x86
> will be the only one to use them. But technically anyone can
> potentially use it.  I'll just remove the patches that remove this and
> kvm_destroy_phys_mem.
> 

For the first stage, we also need it, and will implement userspace
memory later. 

>

-
> This SF.net email is sponsored by: Splunk Inc.
> Still grepping through log files to find problems?  Stop.
> Now Search log events and configuration files using AJAX and a
> browser. Download your FREE copy of Splunk now >>
> http://get.splunk.com/ ___
> kvm-devel mailing list
> kvm-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/kvm-devel

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] [Patch] improvement of "make rpm"

2007-11-05 Thread Akio Takebe
Hi, Avi

Sorry for my late responce, and thank you for your review.

>> --- kvm-49.orig/kvm.spec 2007-10-29 02:14:57.0 +0900
>> +++ kvm-49/kvm.spec  2007-10-31 23:24:05.0 +0900
>> @@ -1,3 +1,12 @@
>> +%define Distribution %(rpm -q -qf /etc/redhat-release --qf '%{name}' | 
>> cut -d - 
>> -f 1)
>> +%define os_release %(rpm -q --qf '%%{version}' /etc/redhat-release)
>> +%define bindir /usr/bin
>> +%define bin %{bindir}/kvm
>> +%define initdir /etc/init.d
>> +%define confdir /etc/kvm
>> +%define utilsdir /etc/kvm/utils
>> +%define _prebuilt %{?prebuilt:1}%{!?prebuilt:0}
>> +
>>   
>
>Why are you moving this around?  It makes the patch harder to review 
>because you can't immediately see if the code has changed.
>
It was for cleanup. I'll put it back.


>>  Name:   kvm
>>  Version:0.0
>>  Release:0
>> @@ -11,20 +20,8 @@ BuildRoot:  %{_tmppath}/%{name}-%{ve
>>  ExclusiveArch:  i386 x86_64
>>  
>>  Requires:   kvm-kmod bridge-utils
>> -
>> -%define Distribution %(cat /etc/redhat-release | awk '{ print $1}' | tr [
>> A-Z] 
>> [a-z])
>> -%define os_release %(rpm -q --qf '%%{version}' %{Distribution}-release)
>> -
>> -%if %{Distribution} == "fedora" && %{os_release} == 5 || %{Distribution} 
>> == 
>> "centos" && %{os_release} == 4
>> -BuildRequires: compat-gcc-32
>> -%else
>> -BuildRequires: compat-gcc-34
>> -%endif
>> -
>>  BuildRequires:  SDL-devel zlib-devel alsa-lib-devel
>>  
>> -%define _prebuilt %{?prebuilt:1}%{!?prebuilt:0}
>> -
>>  %if !%{_prebuilt}
>>  Source0: kvm.tar.gz
>>  Source1: user.tar.gz
>> @@ -32,15 +29,32 @@ Source2: kernel.tar.gz
>>  Source3: scripts.tar.gz
>>  Source4: Makefile
>>  Source5: configure
>> -Source5: kvm_stat
>> +Source6: kvm_stat
>>  %endif
>>  
>>  %description
>>  The Kernel Virtual Machine provides a virtualization enviroment for 
>> processors
>>  with hardware support for virtualization: Intel's VT and AMD's AMD-V.
>>  
>> -%prep
>> +%if %([ x"%{Distribution}" = x"fedora" -a x"%{os_release}" = x"5" ] && 
>> echo 1 |
>> | echo 0)
>> +%define fedora5 1
>> +%endif
>>   
>
>Why not use regular rpm conditionals instead of calling the shell?
>
The regular rpm conditionals are poor facilities.
Shell has better parsing facilities.
The original checking fedora5 and centos4 doesn't work on RHEL5.
So I changed the checking with shell.

>Can you add an explicit test for RHEL 5?
OK, I'll add it.

Best Reagards,

Akio Takebe


-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] Host crashes when creating guest

2007-11-05 Thread Zhao, Yunfeng
Hi, Avi
This error still exists in today's testing.
The commits are:
kernel: c388ba81841a1ed30a5dd4f6029db2263ad1aca3 userspace: 
0fcf487831bbc48e720210c164ca9747b6e99af7

>-Original Message-
>From: Avi Kivity [mailto:[EMAIL PROTECTED]
>Sent: 2007年11月5日 22:08
>To: Zhao, Yunfeng
>Cc: kvm-devel
>Subject: Re: [kvm-devel] Host crashes when creating guest
>
>Zhao, Yunfeng wrote:
>> Against latest commits, creating guests will cause host to crash.
>> Here is the serial output when the error happens.
>> vt-sa2 login: Unable to handle kernel paging request<3>audit: *NO* da
>> it_pid"68
>>  at 0002aaab RIP:
>>  [<0002aaab>]
>> Unable to handle kernel paging request at 0012be304339 RIP:
>>
>
>You're using the external module, right?  The latest portability patch
>broke it.  Andrea's patch ought to fix it.  I'll apply and push it in a
>few minutes.
>
>--
>Any sufficiently difficult bug is indistinguishable from a feature.

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


[kvm-devel] KVM Test Result, kernel: c388ba8... userspace: 0fcf4878...

2007-11-05 Thread Zhao, Yunfeng
Hi,
Here is the quality status summary for current KVM development tree.
kernel: c388ba81841a1ed30a5dd4f6029db2263ad1aca3 userspace:
0fcf487831bbc48e720210c164ca9747b6e99af7

Totally 11 issues still open. 

One block issue:
1. 64bit host crashes when creating guest
https://sourceforge.net/tracker/?func=detail&atid=893831&aid=1825874&gro
up_id=180599

Five Windows issues:
2. Cannot boot 64bit Vista
"-no-kvm-irqchip" has the same issue. And "-no-kvm" gets blue screen.
https://sourceforge.net/tracker/index.php?func=detail&aid=1812072&group_
id=180599&atid=893831
3. windows xp with acpi hal fails to reboot
"-no-kvm-irqchip" has the same issue
https://sourceforge.net/tracker/index.php?func=detail&aid=1805016&group_
id=180599&atid=893831
5. 64bit xpsp2 installer crashed when rebooting
With "-no-kvm-irqchip", blue screen happens when reboot
https://sourceforge.net/tracker/index.php?func=detail&aid=1804990&group_
id=180599&atid=893831
5. xpsp2 with 2vpus may fail to boot
"-no-kvm-irqchip" has the same issue. 
https://sourceforge.net/tracker/index.php?func=detail&aid=1805017&group_
id=180599&atid=893831
6. Error "Fault when IDT_Vectoring" while running 64bit UP vista 
https://sourceforge.net/tracker/index.php?func=detail&aid=1816460&group_
id=180599&atid=893831

Five Linux guest issues:
7. segfault while booting 64bit linux with 4GB mem
https://sourceforge.net/tracker/?func=detail&atid=893831&aid=1812050&gro
up_id=180599
8. Cannot boot 32bit smp RHEL5.1 guest
Only "-on-kvm" can boot it.
https://sourceforge.net/tracker/?func=detail&atid=893831&aid=1812043&gro
up_id=180599
9 Some ltp cases fail on KVM guests
https://sourceforge.net/tracker/index.php?func=detail&aid=1741316&group_
id=180599&atid=893831
10. 64bit KVM guest fails to save/restore.
https://sourceforge.net/tracker/index.php?func=detail&aid=1824525&group_
id=180599&atid=893831
11. Timer of SMP linux guest timer is inaccurate
By network timer the time-cost of make kernel is about 180s, while by
guest timer it's 137s.
https://sourceforge.net/tracker/index.php?func=detail&aid=1826080&group_
id=180599&atid=893831


thanks
Yunfeng

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


[kvm-devel] [Patch] improvement of "make rpm" (take2)

2007-11-05 Thread Akio Takebe
Hi,

This patch is for improvement of "make rpm".

I updated the patch of the following thread.
http://thread.gmane.org/gmane.comp.emulators.kvm.devel/8899
Changelog:
- put back some position of definitions.
- add checking RHEL5

If you try my patch with kvm-50, you can do the below.
1. rm SOURCES 
2. mkdir SOURCES
3. ./configure
4. make rpm

Signed-off-by: Akio Takebe <[EMAIL PROTECTED]>

Best Regards,

Akio Takebe

---
--- kvm-50.orig/kvm.spec2007-10-31 22:50:28.0 +0900
+++ kvm-50/kvm.spec 2007-11-06 11:11:20.0 +0900
@@ -12,10 +12,23 @@ ExclusiveArch:  i386 x86_64
 
 Requires:  kvm-kmod bridge-utils
 
-%define Distribution %(cat /etc/redhat-release | awk '{ print $1}' | tr [A-Z] 
[a-z])
-%define os_release %(rpm -q --qf '%%{version}' %{Distribution}-release)
+%define Distribution %(rpm -q -qf /etc/redhat-release --qf '%{name}' | cut 
-d"-"  -f 1)
+%define os_version %(rpm -q --qf '%%{version}' %{Distribution}-release)
+%define os_release %(rpm -q --qf '%%{release}' %{Distribution}-release | cut 
-d"." -f 1)
 
-%if %{Distribution} == "fedora" && %{os_release} == 5 || %{Distribution} == 
"centos" && %{os_release} == 4
+%if %([ x"%{Distribution}" = x"fedora" -a x"%{os_version}" = x"5" ] && echo 1 
|| echo 0)
+%define require_gccver 32
+%endif
+
+%if %([ x"%{Distribution}" = x"centos" -a x"%{os_version}" = x"4" ] && echo 1 
|| echo 0)
+%define require_gccver 32
+%endif
+
+%if %([ x"%{Distribution}" = x"redhat" -a x"%{os_release}" = x"5" ] && echo 1 
|| echo 0)
+%define require_gccver 34
+%endif
+
+%if %( [ x"%{require_gccver}" = x"32" ] && echo 1 || echo 0)
 BuildRequires: compat-gcc-32
 %else
 BuildRequires: compat-gcc-34
@@ -90,11 +103,15 @@ make DESTDIR=%{buildroot} install-rpm
 %define utilsdir /etc/kvm/utils
 
 %post 
+/sbin/chkconfig --add kvm
 /sbin/chkconfig --level 2345 kvm on
 /sbin/chkconfig --level 16 kvm off
 /usr/sbin/groupadd -fg 444 kvm
 
 %postun
+/sbin/service kvm stop
+/sbin/chkconfig --level 2345 kvm off
+/sbin/chkconfig --del kvm
 
 %clean
 %{__rm} -rf %{buildroot}


-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


[kvm-devel] [PATCH] KVM: VMX: Fix repeatly allocate of apic access page

2007-11-05 Thread Sheng Yang
From 05164d73994a88ae130a086b592cd127c15a617f Mon Sep 17 00:00:00 2001
From: Sheng Yang <[EMAIL PROTECTED]>
Date: Tue, 6 Nov 2007 11:37:44 +0800
Subject: [PATCH] KVM: VMX: Fix repeatly allocate of apic access page

For SMP guest, alloc_apic_access_page() would be called more than once.
So only the last one works, causing SMP guest can't benifit from FlexPriority.

This patch fixed this issue.

Signed-off-by: Sheng Yang <[EMAIL PROTECTED]>
---
 drivers/kvm/vmx.c |   14 ++
 1 files changed, 10 insertions(+), 4 deletions(-)

diff --git a/drivers/kvm/vmx.c b/drivers/kvm/vmx.c
index 42e7fad..6670e2b 100644
--- a/drivers/kvm/vmx.c
+++ b/drivers/kvm/vmx.c
@@ -1463,18 +1463,24 @@ static void seg_setup(int seg)
 static int alloc_apic_access_page(struct kvm *kvm)
 {
struct kvm_userspace_memory_region kvm_userspace_mem;
-   int r;
+   int r = 0;
 
-   r = -EFAULT;
+   mutex_lock(&kvm->lock);
+   if (kvm->apic_access_page)
+   goto out;
+   mutex_unlock(&kvm->lock);
kvm_userspace_mem.slot = APIC_ACCESS_PAGE_PRIVATE_MEMSLOT;
kvm_userspace_mem.flags = 0;
kvm_userspace_mem.guest_phys_addr = 0xfee0ULL;
kvm_userspace_mem.memory_size = PAGE_SIZE;
r = kvm_set_memory_region(kvm, &kvm_userspace_mem, 0);
if (r)
-   return r;
+   goto out;
+   mutex_lock(&kvm->lock);
kvm->apic_access_page = gfn_to_page(kvm, 0xfee00);
-   return 0;
+out:
+   mutex_unlock(&kvm->lock);
+   return r;
 }
 
 /*
-- 
1.5.2

From 05164d73994a88ae130a086b592cd127c15a617f Mon Sep 17 00:00:00 2001
From: Sheng Yang <[EMAIL PROTECTED]>
Date: Tue, 6 Nov 2007 11:37:44 +0800
Subject: [PATCH] KVM: VMX: Fix repeatly allocate of apic access page

For SMP guest, alloc_apic_access_page() would be called more than once.
So only the last one works, causing SMP guest can't benifit from FlexPriority.

This patch fixed this issue.

Signed-off-by: Sheng Yang <[EMAIL PROTECTED]>
---
 drivers/kvm/vmx.c |   14 ++
 1 files changed, 10 insertions(+), 4 deletions(-)

diff --git a/drivers/kvm/vmx.c b/drivers/kvm/vmx.c
index 42e7fad..6670e2b 100644
--- a/drivers/kvm/vmx.c
+++ b/drivers/kvm/vmx.c
@@ -1463,18 +1463,24 @@ static void seg_setup(int seg)
 static int alloc_apic_access_page(struct kvm *kvm)
 {
 	struct kvm_userspace_memory_region kvm_userspace_mem;
-	int r;
+	int r = 0;
 
-	r = -EFAULT;
+	mutex_lock(&kvm->lock);
+	if (kvm->apic_access_page)
+		goto out;
+	mutex_unlock(&kvm->lock);
 	kvm_userspace_mem.slot = APIC_ACCESS_PAGE_PRIVATE_MEMSLOT;
 	kvm_userspace_mem.flags = 0;
 	kvm_userspace_mem.guest_phys_addr = 0xfee0ULL;
 	kvm_userspace_mem.memory_size = PAGE_SIZE;
 	r = kvm_set_memory_region(kvm, &kvm_userspace_mem, 0);
 	if (r)
-		return r;
+		goto out;
+	mutex_lock(&kvm->lock);
 	kvm->apic_access_page = gfn_to_page(kvm, 0xfee00);
-	return 0;
+out:
+	mutex_unlock(&kvm->lock);
+	return r;
 }
 
 /*
-- 
1.5.2

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel


Re: [kvm-devel] 2.6.23.1-rt4 and kvm 48

2007-11-05 Thread David Brown
> > I tried to recreate your problem using 2.6.23-1 and latest rt patch (rt5).
> > The problem is that the kernel is not stable at all, I can't even
> > compile the code over vnc -
> > my connection is constantly lost. So it might not be kvm problem?
> > Can you try is with -no-kvm and see if it's working - then its just a
> > regular userspace process.
> > Anyway if all other things are stable on your end, can you send us
> > dmesg/strace outputs?
> Thanks, Dor, for offering help.
>
> The most recent RT-Preempt patch (2.6.23.1-rt5) still has an SMP issue
> which need to be sorted out first.
>
> When a working RT-Preempt patch is available, I will be glad to send
> dmesg outputs. We may then share our activities to create the next
> "Latest stable" RT-Preempt kernel that includes kvm support.

Wow, that smp issue may be a problem I've got a Intel Core 2 cpu with
just 2 cores.

but I've not seen a dump like this in a while (lustre?).

I've updated to 2.6.23-rt5 and kvm-50 and I got this dump

[  254.639143] audit(1194322621.379:3): dev=tap0 prom=256 old_prom=0 auid=429496
7295
[  254.647231] br0: port 2(tap0) entering learning state
[  255.988741] IRQ-23[942]: segfault at  rip 2ac.994386] Cal
l Trace:
<4>[  255.994387] <3>[  255.998090] BUG: scheduling while atomic: swapper/0x0  2
56.002986] Call Trace:
[  256.002986]
[  256.00ad!
<4>[  256.007635]
<4>[  256.007635] Call Trace:G: scheduling while atomic: swapper/0x0003/0, C
PU#all Trace:
[  256.016955]
[  256.016956] bad: sched1615]
<4>[  256.021615] Call Trace:
[  256.021616]e atomic: swapper/0x0003/0, CPU#1
[  256.026276] .030935]
[  256.030936] bad: scheduling from the idl35595] Call Trace:
[  256.035595]
[  256.035596] B003/0, CPU#1
<4>[  256.040256]

This loops forever basically...
I'm really confused about this one. I've got the full minicom.cap file
from the session that produced this its attached zipped up.

If you'd like any other information I'd be glad to post it.

- David Brown


minicom.cap.gz
Description: GNU Zip compressed data
-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/___
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel