Re: [kvm-devel] [RFC] linuxboot Option ROM for Linux kernel booting

2008-04-23 Thread Nguyen Anh Quynh
On 4/23/08, H. Peter Anvin <[EMAIL PROTECTED]> wrote: > Nguyen Anh Quynh wrote: > > > Hi, > > > > I am thinking about comibing this ROM with the extboot. Both two ROM > > are about "booting", so I think that is reasonable. So we will have > > o

Re: [kvm-devel] [RFC] linuxboot Option ROM for Linux kernel booting

2008-04-23 Thread Nguyen Anh Quynh
On 4/22/08, Anthony Liguori <[EMAIL PROTECTED]> wrote: > Nguyen Anh Quynh wrote: > > > Hi, > > > > This should be submitted to upstream (but not to kvm-devel list), but > > this is only the test code that I want to quickly send out for > > comments. In ca

Re: [kvm-devel] [Qemu-devel] Re: [RFC] linuxboot Option ROM for Linux kernel booting

2008-04-23 Thread Nguyen Anh Quynh
On 4/22/08, Alexander Graf <[EMAIL PROTECTED]> wrote: > I believe that's the way to go. If you have spare time on your hands, feel > free to integrate my multiboot patches as well. > OK, that looks straightforward enough. Thanks, Q > > On Apr 22, 2008, at 11:07

Re: [kvm-devel] [RFC] linuxboot Option ROM for Linux kernel booting

2008-04-22 Thread Nguyen Anh Quynh
Hi, I am thinking about comibing this ROM with the extboot. Both two ROM are about "booting", so I think that is reasonable. So we will have only 1 ROM that supports both external boot and Linux boot. Is that desirable or not? Thanks, Quynh On 4/21/08, Nguyen Anh Quynh <[EM

Re: [kvm-devel] Using -kernel .. with -drive ...

2008-04-21 Thread Nguyen Anh Quynh
On Tue, Apr 22, 2008 at 12:59 AM, Damjan <[EMAIL PROTECTED]> wrote: > > > If I try > > > $ qemu -kernel minimal-kernel -drive file=jeos-devel.img,if=virtio > > > I get the following error: > > > A disk image must be given for 'hda' when booting a Linux kernel > > > is this neccesseary? > >

Re: [kvm-devel] [RFC] linuxboot Option ROM for Linux kernel booting

2008-04-20 Thread Nguyen Anh Quynh
/hw/linuxboot.c | 39 +++ qemu/hw/pc.c | 22 +++- qemu/hw/pc.h |5 + 12 files changed, 600 insertions(+), 9 deletions(-) On Mon, Apr 21, 2008 at 12:33 PM, Nguyen Anh Quynh <[EMAIL PROTECTED]> wrote: > Forget to say that this patch is again

Re: [kvm-devel] [RFC] linuxboot Option ROM for Linux kernel booting

2008-04-20 Thread Nguyen Anh Quynh
Forget to say that this patch is against kvm-66. Thanks, Q On Mon, Apr 21, 2008 at 12:32 PM, Nguyen Anh Quynh <[EMAIL PROTECTED]> wrote: > Hi, > > This should be submitted to upstream (but not to kvm-devel list), but > this is only the test code that I want to quickly send o

[kvm-devel] [RFC] linuxboot Option ROM for Linux kernel booting

2008-04-20 Thread Nguyen Anh Quynh
/linuxboot.c | 39 +++ qemu/hw/pc.c | 22 +++- qemu/hw/pc.h |5 + 13 files changed, 600 insertions(+), 9 deletions(-) commit f4f1178898c8a4bbbc0a432354dbcc56353099c3 Author: Nguyen Anh Quynh <[EMAIL PROTECTED]> Date: Mon Apr 21 12:27:47 2008

Re: [kvm-devel] Extboot Option ROM rewritten in C - v3

2008-04-18 Thread Nguyen Anh Quynh
On 4/18/08, Anthony Liguori <[EMAIL PROTECTED]> wrote: > Nguyen Anh Quynh wrote: > > > > > > > > > The thinking is to eliminate the need to hijack the boot sector when > using > > > the -kernel option. > > > > > > > >

Re: [kvm-devel] Extboot Option ROM rewritten in C - v3

2008-04-18 Thread Nguyen Anh Quynh
On 4/18/08, Anthony Liguori <[EMAIL PROTECTED]> wrote: > Nguyen Anh Quynh wrote: > > > On Thu, Apr 17, 2008 at 3:00 PM, H. Peter Anvin <[EMAIL PROTECTED]> wrote: > > > > > > > > > > > + .globl linux_boot > > > > +linux_boot

Re: [kvm-devel] Extboot Option ROM rewritten in C - v3

2008-04-18 Thread Nguyen Anh Quynh
On Thu, Apr 17, 2008 at 4:36 PM, Carlo Marcelo Arenas Belon <[EMAIL PROTECTED]> wrote: > On Thu, Apr 17, 2008 at 10:30:27AM +0900, Nguyen Anh Quynh wrote: > > +++ b/extboot/farvar.h > @@ -0,0 +1,113 @@ > +// Code to access multiple segments within gcc. > +// > +/

Re: [kvm-devel] Extboot Option ROM rewritten in C - v3

2008-04-18 Thread Nguyen Anh Quynh
On Thu, Apr 17, 2008 at 3:00 PM, H. Peter Anvin <[EMAIL PROTECTED]> wrote: > > + .globl linux_boot > > +linux_boot: > > + cli > > + cld > > + mov $0x9000, %ax > > + mov %ax, %ds > > + mov %ax, %es > > + mov %ax, %fs > > + mov %ax, %gs > > + mov

Re: [kvm-devel] Extboot Option ROM rewritten in C - v3

2008-04-18 Thread Nguyen Anh Quynh
On Thu, Apr 17, 2008 at 2:58 PM, H. Peter Anvin <[EMAIL PROTECTED]> wrote: > Nguyen Anh Quynh wrote: > > > This patch replaces the current assembly code of Extboot option rom > > with new C code. Patch is against kvm-66. > > > > This version returns an erro

[kvm-devel] Extboot Option ROM rewritten in C - v3

2008-04-16 Thread Nguyen Anh Quynh
This patch replaces the current assembly code of Extboot option rom with new C code. Patch is against kvm-66. This version returns an error code in case int 13 handler cannot handle a requested function. Signed-off-by: Nguyen Anh Quynh <[EMAIL PROTECTED]> # diffstat extboot3.diff b/e

Re: [kvm-devel] Extboot Option ROM rewritten in C - v2

2008-04-16 Thread Nguyen Anh Quynh
On Thu, Apr 17, 2008 at 12:02 AM, Anthony Liguori <[EMAIL PROTECTED]> wrote: > A couple general comments. > > I'd feel a lot more comfortable with the int13 handler returning an int and > the asm stub code uses that result to determine how to set CF. You set CF > deep within the function stack an

[kvm-devel] Extboot Option ROM rewritten in C - v2

2008-04-16 Thread Nguyen Anh Quynh
Hi Anthony, I found a bug in the last code: send_command() failed to copy back the result into extboot_cmd structure. This patch fixes it. I succesfully tested this version with guest Win2K (fully updated, scsi boot) and Linux 2.6.25-rc8 (virtio). Let me know if you can boot Windows with this ve

Re: [kvm-devel] Extboot Option Rom rewritten in C

2008-04-14 Thread Nguyen Anh Quynh
On 4/15/08, Nguyen Anh Quynh <[EMAIL PROTECTED]> wrote: > > You should be able to get very far along the Windows boot process with > > extboot. If you just install the LSI driver in Win2k, you can boot up > > completely. Someone just posted instructions for doing scs

Re: [kvm-devel] Extboot Option Rom rewritten in C

2008-04-14 Thread Nguyen Anh Quynh
On 4/15/08, Anthony Liguori <[EMAIL PROTECTED]> wrote: > Nguyen Anh Quynh wrote: > > > On 4/15/08, Anthony Liguori <[EMAIL PROTECTED]> wrote: > > > > > > > Hi Nguyen, > > > > > > Nguyen Anh Quynh wrote: > > > > > >

Re: [kvm-devel] Extboot Option Rom rewritten in C

2008-04-14 Thread Nguyen Anh Quynh
On 4/15/08, Anthony Liguori <[EMAIL PROTECTED]> wrote: > Hi Nguyen, > > Nguyen Anh Quynh wrote: > > > Hi Anthony, > > > > I spot a bug and few dead code in the extboot option rom. Perhaps the > > reason they are there is because less people want to look

[kvm-devel] Extboot Option Rom rewritten in C

2008-04-14 Thread Nguyen Anh Quynh
Hi Anthony, I spot a bug and few dead code in the extboot option rom. Perhaps the reason they are there is because less people want to look at assembly code, and it looks indeed scary. So I decided to rewrite it in C, using .code16gcc directive. Some advantages: - C code is easier to understand,

Re: [kvm-devel] [PATCH] wrong pa calculation fix (extboot)

2008-04-14 Thread Nguyen Anh Quynh
On 4/14/08, Anthony Liguori <[EMAIL PROTECTED]> wrote: > Nguyen Anh Quynh wrote: > > > > > This patch fixes a wrong calculation in the physical address of > > extboot (qemu/hw/extboot.c). Looks like a typo. > > > > Signed-off-by: Nguyen Anh Quynh <

[kvm-devel] [PATCH] wrong pa calculation fix (extboot)

2008-04-14 Thread Nguyen Anh Quynh
This patch fixes a wrong calculation in the physical address of extboot (qemu/hw/extboot.c). Looks like a typo. Signed-off-by: Nguyen Anh Quynh <[EMAIL PROTECTED]> diff --git a/qemu/hw/extboot.c b/qemu/hw/extboot.c index 056fb59..0dac34c 100644 --- a/qemu/hw/extboot.c +++ b/qemu/hw/ext

Re: [kvm-devel] [patch] mmu.c: remove unused functions

2007-07-24 Thread Nguyen Anh Quynh
On 7/25/07, Avi Kivity <[EMAIL PROTECTED]> wrote: > Nguyen Anh Quynh wrote: > > On 7/24/07, Avi Kivity <[EMAIL PROTECTED]> wrote: > >> Nguyen Anh Quynh wrote: > >> > This patch removes some unused functions in mmu.c > >> > >> > -static

Re: [kvm-devel] [patch] mmu.c: remove unused functions

2007-07-24 Thread Nguyen Anh Quynh
On 7/24/07, Avi Kivity <[EMAIL PROTECTED]> wrote: > Nguyen Anh Quynh wrote: > > This patch removes some unused functions in mmu.c > > > -static int is_nx(struct kvm_vcpu *vcpu) > > -{ > > - return vcpu->shadow_efer & EFER_NX; > > -} > > -

[kvm-devel] [patch] mmu.c: remove unused functions

2007-07-24 Thread Nguyen Anh Quynh
This patch removes some unused functions in mmu.c Signed-off-by: Nguyen Anh Quynh <[EMAIL PROTECTED]> diff --git a/drivers/kvm/mmu.c b/drivers/kvm/mmu.c index a7985b1..13fb6bb 100644 --- a/drivers/kvm/mmu.c +++ b/drivers/kvm/mmu.c @@ -156,21 +156,6 @@ static struct kmem_cache *pte_chain

Re: [kvm-devel] [patch] Make sure that we compile before installing

2007-07-23 Thread Nguyen Anh Quynh
On 7/23/07, Avi Kivity <[EMAIL PROTECTED]> wrote: > Nguyen Anh Quynh wrote: > > This patch makes "install" compile code, and "install-rpm" package rpms. > > 'install' and 'install-rpm' are typically run as root, and we don'

[kvm-devel] [patch] Make sure that we compile before installing

2007-07-23 Thread Nguyen Anh Quynh
This patch makes "install" compile code, and "install-rpm" package rpms. Signed-off-by: Nguyen Anh Quynh <[EMAIL PROTECTED]> diff --git a/Makefile b/Makefile index 37b01d2..dd3f51c 100644 --- a/Makefile +++ b/Makefile @@ -22,7 +22,7 @@ initdir = /etc/init.d confdir =

[kvm-devel] [PATCH] kvmctl.c: mmap() should be called with NULL rather than 0

2007-07-23 Thread Nguyen Anh Quynh
kvmctl.c: The first param of mmap() should be NULL rather than 0. Signed-off-by: Nguyen Anh Quynh <[EMAIL PROTECTED]> diff --git a/user/kvmctl.c b/user/kvmctl.c index 3b0d8bc..43b374d 100644 --- a/user/kvmctl.c +++ b/user/kvmctl.c @@ -222,7 +222,7 @@ int kvm_create_vcpu(kvm_context_t kv

Re: [kvm-devel] [PATCH] hardware debug register handling

2007-07-19 Thread Nguyen Anh Quynh
On 7/19/07, Avi Kivity <[EMAIL PROTECTED]> wrote: > Nguyen Anh Quynh wrote: > > Currently, when handling hardware breakpoints, we always set values > > for all the 4 hardware debug registers, regardless it is needed or > > not. This patch fixes the bug. > > Why

[kvm-devel] [PATCH] hardware debug register handling

2007-07-19 Thread Nguyen Anh Quynh
Currently, when handling hardware breakpoints, we always set values for all the 4 hardware debug registers, regardless it is needed or not. This patch fixes the bug. Signed-off-by: Nguyen Anh Quynh <[EMAIL PROTECTED]> diff --git a/drivers/kvm/kvm.h b/drivers/kvm/kvm.h index 7bdffe6..c

Re: [kvm-devel] [kvm-commits] kvm: external module: rename original kernel's modules when installing

2007-07-12 Thread Nguyen Anh Quynh
s when installing this avoids an ambiguity when using the kvm external module in conjuction with 2.6.20 or later, which may also have kvm built. This patch raises a problem if /lib/modules//kernel/drivers/kvm/ does not exist. The enclosed patch fixes the bug. Signed-off-by: Nguyen

Re: [kvm-devel] [PATCH] fix *nopage() in kvm_main.c

2007-07-11 Thread Nguyen Anh Quynh
On 7/11/07, Avi Kivity <[EMAIL PROTECTED]> wrote: > Nguyen Anh Quynh wrote: > > *nopage() in kvm_main.c should only store the type of mmap() fault if > > the pointers are not NULL. This patch fixes the problem. > > > > What caller of ->nopage() passes a NULL

[kvm-devel] [PATCH] fix *nopage() in kvm_main.c

2007-07-11 Thread Nguyen Anh Quynh
*nopage() in kvm_main.c should only store the type of mmap() fault if the pointers are not NULL. This patch fixes the problem. Signed-off-by: Nguyen Anh Quynh <[EMAIL PROTECTED]> diff --git a/drivers/kvm/kvm_main.c b/drivers/kvm/kvm_main.c index 83bb284..0520d15 100644 --- a/drive

Re: [kvm-devel] [PATCH] memslot check before deferencing

2007-06-04 Thread Nguyen Anh Quynh
patch is fine for you, or how do you want to take patch from gmail. On 6/4/07, Avi Kivity <[EMAIL PROTECTED]> wrote: Nguyen Anh Quynh wrote: > "memslot" in makr_page_dirty() should be verified before dereferencing > it (kvm_main.c) The patches still don't show up inline

Re: [kvm-devel] [kvm-commits] kvm: kvmctl: create secondary vcpus

2007-06-04 Thread Nguyen Anh Quynh
Hi Avi, Perhaps I miss something, but I dont see you initialize ncpus anywhere in the patch? Cheers, Quynh On 6/5/07, Avi Kivity <[EMAIL PROTECTED]> wrote: > repository: /home/avi/kvm > branch: master > commit 9d02d1c4345c77ffbc95136c12011a112a8d1c7e > Author: Avi Kivity <[EMAIL PROTECTED]> > Da

[kvm-devel] [PATCH] memslot check before deferencing

2007-06-03 Thread Nguyen Anh Quynh
"memslot" in makr_page_dirty() should be verified before dereferencing it (kvm_main.c) Signed-off-by: Nguyen Anh Quynh <[EMAIL PROTECTED]> patch9.patch Description: Binary data - This SF.net email is

[kvm-devel] [PATCH] remove dead structure in kvmctl.c

2007-06-03 Thread Nguyen Anh Quynh
This patch removes a dead struct in kvmctl.c Signed-off-by: Nguyen Anh Quynh <[EMAIL PROTECTED]> patch8.patch Description: Binary data - This SF.net email is sponsored by DB2 Express Download DB2 Express C - th

[kvm-devel] [PATCH] symbol instead of constant in kvm_show_code()

2007-06-03 Thread Nguyen Anh Quynh
This patch uses symbol rather than a constant in kvm_show_code(), so more readable :-) Signed-off-by: Nguyen Anh Quynh <[EMAIL PROTECTED]> patch7.patch Description: Binary data - This SF.net email is sponsored

Re: [kvm-devel] [PATCH] use symbols rather than constant vars in kvm_create

2007-06-03 Thread Nguyen Anh Quynh
On 6/3/07, Avi Kivity <[EMAIL PROTECTED]> wrote: > Nguyen Anh Quynh wrote: > > On 6/3/07, Avi Kivity <[EMAIL PROTECTED]> wrote: > >> Nguyen Anh Quynh wrote: > >> > This patch replaces 2 constant variables "dosmem" and "exmem" in >

[kvm-devel] [PATCH] return NULL instead of 0

2007-06-03 Thread Nguyen Anh Quynh
This patch makes kvm_get_msr_list() returns NULL rather than plain 0 in error cases. Signed-off-by: Nguyen Anh Quynh <[EMAIL PROTECTED]> patch6.patch Description: Binary data - This SF.net email is sponsored by DB2 E

[kvm-devel] [PATCH] make handle_debug() static

2007-06-03 Thread Nguyen Anh Quynh
This patch turnes a local function in kvmctl.c static. Signed-off-by: Nguyen Anh Quynh <[EMAIL PROTECTED]> patch5.patch Description: Binary data - This SF.net email is sponsored by DB2 Express Download DB2 Express C

Re: [kvm-devel] [PATCH] use symbols rather than constant vars in kvm_create

2007-06-03 Thread Nguyen Anh Quynh
On 6/3/07, Avi Kivity <[EMAIL PROTECTED]> wrote: > Nguyen Anh Quynh wrote: > > This patch replaces 2 constant variables "dosmem" and "exmem" in > > kvm_create() with symbols. > > What is the benefit of this? Readability is not improved. > >

[kvm-devel] [PATCH] kvmctl.h

2007-06-03 Thread Nguyen Anh Quynh
This patch moves a comment in kvmctl.h to the right place, and fixes some stuffs for doxygen. Signed-off-by: Nguyen Anh Quynh <[EMAIL PROTECTED]> patch4.patch Description: Binary data - This SF.net email is sponso

[kvm-devel] [PATCH] use symbols rather than constant vars in kvm_create

2007-06-03 Thread Nguyen Anh Quynh
This patch replaces 2 constant variables "dosmem" and "exmem" in kvm_create() with symbols. Signed-off-by: Nguyen Anh Quynh <[EMAIL PROTECTED]> patch3.patch Description: Binary data - This SF.net

[kvm-devel] [PATCH] Use symbol insted of number

2007-06-01 Thread Nguyen Anh Quynh
This patch makes hypercall.c use symbol instead of number with hypercall-ioport-size. Signed-off-by: Nguyen Anh Quynh <[EMAIL PROTECTED]> patch2 Description: Binary data - This SF.net email is sponsored by DB2 E

[kvm-devel] [PATCH] make some functions/vars static

2007-06-01 Thread Nguyen Anh Quynh
This patch turns some local functions and variables in hypercall.c static. Signed-off-by: Nguyen Anh Quynh <[EMAIL PROTECTED]> patch1 Description: Binary data - This SF.net email is sponsored by DB2 Express Downlo

[kvm-devel] [PATCH] install kvm modules into drivers/kvm

2007-05-07 Thread Nguyen Anh Quynh
sometime because the old modules (which is available in 2.6.20) is not supported by the current libkvm. Signed-off-by: Nguyen Anh Quynh <[EMAIL PROTECTED]> # diffstat patch2.patch Makefile |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kernel/Makefile b/kernel/Makefile

[kvm-devel] Clarify old version messages and clean-up

2007-05-07 Thread Nguyen Anh Quynh
This patch clarifies some "old version" error message, and deletes some unused functions in userspace code. Signed-off-by: Nguyen Anh Quynh <[EMAIL PROTECTED]> diffstat patch1.patch kvmctl.c | 36 +++- 1 file changed, 3 insertions(+), 33 deletio

[kvm-devel] [PATCH] rename few MSR registers & cleanup

2006-12-27 Thread Nguyen Anh Quynh
Hi, This patch renames few MSR registers in vmx.h and did few trivial cleanups. Signed-off-by: Nguyen Anh Quynh <[EMAIL PROTECTED]> $ diffstat msr.patch vmx.c | 13 ++--- vmx.h | 10 +- 2 files changed, 11 insertions(+), 12 deletions(-) Index: kernel