[Qemu-devel] Re: [FOR 0.12 PATCH] qdev: Replace device names containing whitespace

2009-12-08 Thread Gerd Hoffmann
diff --git a/hw/usb-msd.c b/hw/usb-msd.c index bb39b62..dec35bc 100644 --- a/hw/usb-msd.c +++ b/hw/usb-msd.c @@ -591,7 +591,7 @@ static USBDevice *usb_msd_init(const char *filename) } /* create guest device */ -dev = usb_create(NULL /* FIXME */, "QEMU USB MSD"); +dev = usb_c

Re: [Qemu-devel] [PATCH V8 09/18] pc: remove a global variable, RTCState *rtc_state.

2009-12-08 Thread Isaku Yamahata
On Mon, Dec 07, 2009 at 10:15:17AM +0100, Gerd Hoffmann wrote: > On 12/04/09 06:50, Isaku Yamahata wrote: >> remove a global variable, RTCState *rtc_state. >> Only the cmos_set_s3_resume_init() needs it global. >> So introduce a registering function and make it local. >> As for other function which

Re: [Qemu-devel] [PATCH] Fixes a bug that tries to use the unimplemented function fdatasync on Mac OS X.

2009-12-08 Thread Alexander Graf
Am 08.12.2009 um 19:35 schrieb Blue Swirl : On Tue, Dec 8, 2009 at 4:35 PM, Pierre Riteau wrote: On 1 oct. 2009, at 18:13, Blue Swirl wrote: On Thu, Oct 1, 2009 at 6:30 PM, G 3 wrote: On Sep 30, 2009, at 3:16 PM, Anthony Liguori wrote: G 3 wrote: This patch fixes a problem in the file

Re: [Qemu-devel] [PATCH] fix rtc-td-hack on host without high-res timers

2009-12-08 Thread Anthony Liguori
Gleb Natapov wrote: On hosts without high-res timers it is impossible to inject rtc interrupt faster then 1kHz. Windows sometimes configures RTC to generate 1kHz interrupts, so we can't inject missed interrupts when running on such hosts. Always injecting an interrupt on REG_C read is also not an

[Qemu-devel] [PATCH 06/11] target-mips: split out delay slot handling

2009-12-08 Thread Nathan Froyd
Move delay slot handling to common code whose invocation can be controlled from gen_intermediate_code_internal. Signed-off-by: Nathan Froyd --- target-mips/translate.c | 134 +++--- 1 files changed, 79 insertions(+), 55 deletions(-) diff --git a/target-m

Re: [Qemu-devel] [PATCH] Fixes a bug that tries to use the unimplemented function fdatasync on Mac OS X.

2009-12-08 Thread Pierre Riteau
On 8 déc. 2009, at 19:35, Blue Swirl wrote: > On Tue, Dec 8, 2009 at 4:35 PM, Pierre Riteau wrote: >> On 1 oct. 2009, at 18:13, Blue Swirl wrote: >> >>> On Thu, Oct 1, 2009 at 6:30 PM, G 3 wrote: On Sep 30, 2009, at 3:16 PM, Anthony Liguori wrote: G 3 wrote: This patc

[Qemu-devel] [FOR 0.12 PATCH] qdev: Replace device names containing whitespace

2009-12-08 Thread Markus Armbruster
Device names with whitespace require quoting in the shell and in the monitor. Some of the offenders are also overly long. Some have a more convenient alias, some don't. The place for verbose device names is DeviceInfo member desc. The name should be short & sweet. Signed-off-by: Markus Armbrus

[Qemu-devel] [PATCH 07/11] target-mips: add enums for MIPS16 opcodes

2009-12-08 Thread Nathan Froyd
Signed-off-by: Nathan Froyd --- target-mips/translate.c | 112 +++ 1 files changed, 112 insertions(+), 0 deletions(-) diff --git a/target-mips/translate.c b/target-mips/translate.c index 36bfdeb..7aac6bf 100644 --- a/target-mips/translate.c +++ b/tar

[Qemu-devel] [PATCH 03/11] target-mips: move ROTR and ROTRV inside gen_shift_{imm, }

2009-12-08 Thread Nathan Froyd
It's easier to implement mips16 shift instructions if we're not examining the opcode inside gen_shift_{imm,}. So move ROTR and ROTRV and do the special-case handling of SRL and SRLV inside decode_opc. Likewise for their 64-bit counterparts. Signed-off-by: Nathan Froyd --- target-mips/translate.

Re: [Qemu-devel] [PATCH] Fixes a bug that tries to use the unimplemented function fdatasync on Mac OS X.

2009-12-08 Thread Blue Swirl
On Tue, Dec 8, 2009 at 4:35 PM, Pierre Riteau wrote: > On 1 oct. 2009, at 18:13, Blue Swirl wrote: > >> On Thu, Oct 1, 2009 at 6:30 PM, G 3 wrote: >>> On Sep 30, 2009, at 3:16 PM, Anthony Liguori wrote: >>> >>> G 3 wrote: >>> >>> This patch fixes a problem in the file cutils.c that prevents qemu

[Qemu-devel] Re: [FOR 0.12 PATCH v4 01/22] default devices: qdev integration.

2009-12-08 Thread Luiz Capitulino
On Tue, 8 Dec 2009 13:11:32 +0100 Gerd Hoffmann wrote: > New in v4: > * Rebased against latest master. > * Moved the included fixes from (yesterdays) staging to the head >of this series. > * Fixed segfault without -monitor switch. > * Killed noisy debug leftover. > * Replaced fprintf("f

[Qemu-devel] [PATCH] virtio: verify features on load

2009-12-08 Thread Michael S. Tsirkin
migrating between hosts which have different features might break silently, if the migration destination does not support some features supported by source. Prevent this from happening by comparing acked feature bits with the mask supported by the device. Signed-off-by: Michael S. Tsirkin --- P

[Qemu-devel] [PATCH 04/11] target-mips: make gen_compute_branch 16/32-bit-aware

2009-12-08 Thread Nathan Froyd
Signed-off-by: Nathan Froyd --- target-mips/translate.c | 15 --- 1 files changed, 8 insertions(+), 7 deletions(-) diff --git a/target-mips/translate.c b/target-mips/translate.c index d403c56..3751516 100644 --- a/target-mips/translate.c +++ b/target-mips/translate.c @@ -2390,6 +2

Re: [Qemu-devel] [PATCH 05/11] target-mips: add gen_base_offset_addr

2009-12-08 Thread Nathan Froyd
This is a common pattern in existing code. We'll also use it to implement the mips16 SAVE/RESTORE instructions. Signed-off-by: Nathan Froyd --- Argh, please use this one instead; the arguments passed to gen_op_addr_add in gen_base_offset_addr are in the "proper" order. target-mips/translate.c

[Qemu-devel] [PATCH, try 2] qemu/tap: add -net tap,dev= option

2009-12-08 Thread Arnd Bergmann
In order to support macvtap, we need a way to select the actual tap endpoint. While it would be nice to pass it by network interface name, passing the character device is more flexible, and we can easily do both in the long run. Signed-off-by: Arnd Bergmann --- diff --git a/net.c b/net.c index 13

[Qemu-devel] [PATCH 10/11] target-mips: add copyright notice for mips16 work

2009-12-08 Thread Nathan Froyd
Also cross off mips16 ASE in TODO. Signed-off-by: Nathan Froyd --- target-mips/TODO|1 - target-mips/translate.c |1 + 2 files changed, 1 insertions(+), 1 deletions(-) diff --git a/target-mips/TODO b/target-mips/TODO index 4769e2a..9101881 100644 --- a/target-mips/TODO +++ b/tar

[Qemu-devel] [PATCH 05/11] target-mips: add gen_base_offset_addr

2009-12-08 Thread Nathan Froyd
This is a common pattern in existing code. We'll also use it to implement the mips16 SAVE/RESTORE instructions. Signed-off-by: Nathan Froyd --- target-mips/translate.c | 40 1 files changed, 16 insertions(+), 24 deletions(-) diff --git a/target-mips/t

[Qemu-devel] [FOR 0.12][PATCH] kvm: x86: Save/restore exception_index

2009-12-08 Thread Jan Kiszka
As KVM now makes use of exception_index to keep pending exceptions, we have to save&restore this field as well. NOTE: We have to nail the arch-independent exception_index down to a certain bit width for proper vmstate processing, namely to 32 bit. Signed-off-by: Jan Kiszka --- cpu-defs.h

[Qemu-devel] [PATCH 08/11] target-mips: add mips16 instruction decoding

2009-12-08 Thread Nathan Froyd
There's no good way to add this incrementally, so we do it all at once. The only changes to shared code are in handle_delay_slot. We need to flip ISAMode when doing a jump-and-exchange. We also need to set ISAMode the low bit of the target address for jump-to-register. Also, since we're now addi

[Qemu-devel] [PATCH 01/11] target-mips: add new HFLAGs for JALX and 16/32-bit delay slots

2009-12-08 Thread Nathan Froyd
We create separate masks for the "basic" branch hflags and the "extended" branch hflags and define MIPS_HFLAG_BMASK as the logical or of those two. This is done to avoid churning the codebase in lots of different places. We also make the execution mode an hflag under MIPS_HFLAG_TMASK Signed-off-

Re: [Qemu-devel] Re: [FOR 0.12 PATCH v3 10/21] default devices: add global cmd line option.

2009-12-08 Thread Paolo Bonzini
> > Here is my thinking: if you used -writeconfig, your machine description > > is (at least in theory) entirely included in the config file including > > (again in theory) the default devices. > > The default devices are *not* included by in the file created by > -writeconfig. Yes, that's why I

Re: [Qemu-devel] Re: [FOR 0.12 PATCH v3 10/21] default devices: add global cmd line option.

2009-12-08 Thread Gerd Hoffmann
On 12/08/09 17:11, Paolo Bonzini wrote: Add global command line option to disable default devices. Should -readconfig imply this? Hmm, not sure. Why do you think this would be useful? Here is my thinking: if you used -writeconfig, your machine description is (at least in theory) entirely i

Re: [Qemu-devel] Re: [FOR 0.12 PATCH v3 10/21] default devices: add global cmd line option.

2009-12-08 Thread Daniel P. Berrange
On Tue, Dec 08, 2009 at 11:11:29AM -0500, Paolo Bonzini wrote: > > > > Add global command line option to disable default devices. > > > > > > Should -readconfig imply this? > > > > Hmm, not sure. Why do you think this would be useful? > > Here is my thinking: if you used -writeconfig, your machi

[Qemu-devel] [PATCH-RFC 3/3] virtio: add missing barriers

2009-12-08 Thread Michael S. Tsirkin
Add missing memory barriers in virtio: - before checking interrupt enabled bit, make sure data has been written to memory - make sure ring index has been read before reading ring data Signed-off-by: Michael S. Tsirkin --- hw/virtio.c |8 +++- 1 files changed, 7 insertions(+), 1 deletio

[Qemu-devel] [PATCH-RFC 2/3] virtio: use a real wmb

2009-12-08 Thread Michael S. Tsirkin
include barriers.h and remove a non-portable wmb implementation from virtio.c (it will work for intel but not for other architectures). Signed-off-by: Michael S. Tsirkin --- hw/virtio.c | 10 +- 1 files changed, 1 insertions(+), 9 deletions(-) diff --git a/hw/virtio.c b/hw/virtio.c in

[Qemu-devel] [PATCH-RFC 1/3] qemu: add barriers.h header

2009-12-08 Thread Michael S. Tsirkin
With qemu-kvm and with iothread, guest might read in-memory structures on one host CPU while it is being updated on another one, and vice versa. Therefore we must use memory barriers to ensure proper memory read/write ordering. The following implements memory barriers with API matching that of th

[Qemu-devel] [PATCH-RFC 0/3] qemu: memory barriers in virtio

2009-12-08 Thread Michael S. Tsirkin
The following fixes a class of long-standing bugs in qemu: when kvm is enabled, guest might access device structures in memory while they are updated by qemu on another CPU. In this scenario, memory barriers are necessary to prevent host CPU from reordering memory accesses, which might confuse the

Re: [Qemu-devel] [PATCH] kvm: x86: Add support for VCPU event states

2009-12-08 Thread Jan Kiszka
Marcelo Tosatti wrote: > On Wed, Nov 25, 2009 at 12:33:03AM +0100, Jan Kiszka wrote: >> This patch extends the qemu-kvm state sync logic with support for >> KVM_GET/SET_VCPU_EVENTS, giving access to yet missing exception, >> interrupt and NMI states. >> >> Signed-off-by: Jan Kiszka >> --- >> kvm-

[Qemu-devel] [PATCH 09/11] gdbstub: add MIPS16 support

2009-12-08 Thread Nathan Froyd
The only thing to do here is to expose the current processor mode to GDB and to set the processor mode properly when we change the PC. Signed-off-by: Nathan Froyd --- gdbstub.c | 18 +++--- 1 files changed, 15 insertions(+), 3 deletions(-) diff --git a/gdbstub.c b/gdbstub.c index

[Qemu-devel] [PATCH 02/11] target-mips: change interrupt bits to be mips16-aware

2009-12-08 Thread Nathan Froyd
We need to stash the operating mode into the low bit of the error PC and restore it on return from interrupts. Signed-off-by: Nathan Froyd --- target-mips/helper.c| 51 +++--- target-mips/op_helper.c | 17 -- 2 files changed, 44 inserti

[Qemu-devel] [PATCH 11/11] target-mips: set Config1.CA for MIPS16-aware CPUs

2009-12-08 Thread Nathan Froyd
Signed-off-by: Nathan Froyd --- target-mips/translate_init.c | 27 ++- 1 files changed, 18 insertions(+), 9 deletions(-) diff --git a/target-mips/translate_init.c b/target-mips/translate_init.c index c950eab..6f50555 100644 --- a/target-mips/translate_init.c +++ b/targ

Re: [Qemu-devel] Re: [FOR 0.12 PATCH v3 10/21] default devices: add global cmd line option.

2009-12-08 Thread Paolo Bonzini
> > > Add global command line option to disable default devices. > > > > Should -readconfig imply this? > > Hmm, not sure. Why do you think this would be useful? Here is my thinking: if you used -writeconfig, your machine description is (at least in theory) entirely included in the config file i

Re: [Qemu-devel] [PATCH] kvm: x86: Add support for VCPU event states

2009-12-08 Thread Marcelo Tosatti
On Wed, Nov 25, 2009 at 12:33:03AM +0100, Jan Kiszka wrote: > This patch extends the qemu-kvm state sync logic with support for > KVM_GET/SET_VCPU_EVENTS, giving access to yet missing exception, > interrupt and NMI states. > > Signed-off-by: Jan Kiszka > --- > kvm-all.c | 11 ++

[Qemu-devel] Guest bridge setup variations

2009-12-08 Thread Arnd Bergmann
As promised, here is my small writeup on which setups I feel are important in the long run for server-type guests. This does not cover -net user, which is really for desktop kinds of applications where you do not want to connect into the guest from another IP address. I can see four separate setup

[Qemu-devel] [PATCH v2 00/11] target-mips: add mips16 support

2009-12-08 Thread Nathan Froyd
This patchset adds MIPS16 support to the MIPS backend. MIPS16 is a compact encoding of a subset of the MIPS integer instructions, similar to ARM's Thumb mode. Mode switching occurs when either a special instruction (JALX) is executed, or when a jump-to-register instruction is executed; the instru

Re: [Qemu-devel] Re: [FOR 0.12 PATCH v3 10/21] default devices: add global cmd line option.

2009-12-08 Thread Gerd Hoffmann
On 12/08/09 13:46, Paolo Bonzini wrote: On 12/07/2009 01:42 PM, Gerd Hoffmann wrote: Add global command line option to disable default devices. Should -readconfig imply this? Hmm, not sure. Why do you think this would be useful? cheers, Gerd

Re: [Qemu-devel] Re: [FOR 0.12 PATCH 18/18] QMP: add human-readable description to error response

2009-12-08 Thread Luiz Capitulino
On Tue, 8 Dec 2009 12:25:13 + "Daniel P. Berrange" wrote: > On Tue, Dec 08, 2009 at 10:11:48AM -0200, Luiz Capitulino wrote: > > On Mon, 7 Dec 2009 21:37:16 +0100 > > Markus Armbruster wrote: > > > > > -{ "error": { "class": json-string, "data": json-value }, "id": > > > json-value } > >

Re: [Qemu-devel] Re: Endless loop in qcow2_alloc_cluster_offset

2009-12-08 Thread Kevin Wolf
Am 07.12.2009 16:00, schrieb Kevin Wolf: > Am 07.12.2009 15:16, schrieb Jan Kiszka: >>> Likely not. What I did was nothing special, and I did not noticed such a >>> crash in the last months. >> >> And now it happened again (qemu-kvm head, during kernel installation >> from network onto local qcow2-

Re: [Qemu-devel] Re: [FOR 0.12 PATCH 18/18] QMP: add human-readable description to error response

2009-12-08 Thread Markus Armbruster
Luiz Capitulino writes: > On Tue, 8 Dec 2009 12:25:13 + > "Daniel P. Berrange" wrote: > >> On Tue, Dec 08, 2009 at 10:11:48AM -0200, Luiz Capitulino wrote: >> > On Mon, 7 Dec 2009 21:37:16 +0100 >> > Markus Armbruster wrote: >> > >> > > -{ "error": { "class": json-string, "data": json-val

Re: [Qemu-devel] Re: [FOR 0.12 PATCH 18/18] QMP: add human-readable description to error response

2009-12-08 Thread Luiz Capitulino
On Tue, 08 Dec 2009 07:18:11 -0600 Anthony Liguori wrote: > Luiz Capitulino wrote: > > On Mon, 7 Dec 2009 21:37:16 +0100 > > Markus Armbruster wrote: > > > > > >> -{ "error": { "class": json-string, "data": json-value }, "id": json-value > >> } > >> +{ "error": { "class": json-string, "data

Re: [Qemu-devel] [PATCH] Fixes a bug that tries to use the unimplemented function fdatasync on Mac OS X.

2009-12-08 Thread Pierre Riteau
On 1 oct. 2009, at 18:13, Blue Swirl wrote: > On Thu, Oct 1, 2009 at 6:30 PM, G 3 wrote: >> On Sep 30, 2009, at 3:16 PM, Anthony Liguori wrote: >> >> G 3 wrote: >> >> This patch fixes a problem in the file cutils.c that prevents qemu from >> being built on Mac OS X. This patch makes sure fsync

[Qemu-devel] [PATCH] block/vdi: allow disk sizes not multiple of block size

2009-12-08 Thread François Revol
The disk image I created from my old laptop disk with VBoxManage internalcommand converthd obviously was not a multiple of 1MB as when created from scratch. This fixes QEMU refusing it. We still require the size to be a multiple of sector size though. It then boots correctly. Signed-off-by: Al

[Qemu-devel] [PATCH] fix rtc-td-hack on host without high-res timers

2009-12-08 Thread Gleb Natapov
On hosts without high-res timers it is impossible to inject rtc interrupt faster then 1kHz. Windows sometimes configures RTC to generate 1kHz interrupts, so we can't inject missed interrupts when running on such hosts. Always injecting an interrupt on REG_C read is also not an option since Windows

Re: [Qemu-devel] Re: [FOR 0.12 PATCH 18/18] QMP: add human-readable description to error response

2009-12-08 Thread Anthony Liguori
Luiz Capitulino wrote: On Mon, 7 Dec 2009 21:37:16 +0100 Markus Armbruster wrote: -{ "error": { "class": json-string, "data": json-value }, "id": json-value } +{ "error": { "class": json-string, "data": json-value, "desc": json-string }, + "id": json-value } Where, - The "class" me

Re: [Qemu-devel] [ANNOUNCE][Call-For-Testing] Release 0.12.0-rc1 of QEMU

2009-12-08 Thread Gerd Hoffmann
On 12/08/09 13:52, Gerd Hoffmann wrote: The latter. The guest does not see it, but it at least does not abort. It is the 'does not abort' behaviour I'm interested in - quite OK with this returning an error to the monitor client when acpi is disabled. Does the attached patch fix it for you? On

[Qemu-devel] Re: [FOR 0.12 PATCH 18/18] QMP: add human-readable description to error response

2009-12-08 Thread Markus Armbruster
Paolo Bonzini writes: > On 12/08/2009 01:11 PM, Luiz Capitulino wrote: >> Not to mention that those strings can't be modified when the protocol >> becomes stable and we're probably talking about dozens if not a hundred >> of strings. > > I would say that there is _explicitly no promise_ of keep

Re: [Qemu-devel] [ANNOUNCE][Call-For-Testing] Release 0.12.0-rc1 of QEMU

2009-12-08 Thread Gerd Hoffmann
On 12/08/09 11:52, Daniel P. Berrange wrote: On Tue, Dec 08, 2009 at 11:40:54AM +0100, Gerd Hoffmann wrote: "worked" as in "guest actually sees the new device (without reboot)" or "worked" as in "qemu didn't abort" ? The latter. The guest does not see it, but it at least does not abort. It is

[Qemu-devel] Re: [FOR 0.12 PATCH 18/18] QMP: add human-readable description to error response

2009-12-08 Thread Markus Armbruster
Luiz Capitulino writes: > On Mon, 7 Dec 2009 21:37:16 +0100 > Markus Armbruster wrote: > >> -{ "error": { "class": json-string, "data": json-value }, "id": json-value } >> +{ "error": { "class": json-string, "data": json-value, "desc": json-string >> }, >> + "id": json-value } >> >> Where

[Qemu-devel] Re: [FOR 0.12 PATCH v3 10/21] default devices: add global cmd line option.

2009-12-08 Thread Paolo Bonzini
On 12/07/2009 01:42 PM, Gerd Hoffmann wrote: Add global command line option to disable default devices. Should -readconfig imply this? Paolo

[Qemu-devel] Re: [FOR 0.12 PATCH 18/18] QMP: add human-readable description to error response

2009-12-08 Thread Paolo Bonzini
On 12/08/2009 01:11 PM, Luiz Capitulino wrote: Not to mention that those strings can't be modified when the protocol becomes stable and we're probably talking about dozens if not a hundred of strings. I would say that there is _explicitly no promise_ of keeping these stable. You can serve

[Qemu-devel] [FOR 0.12 PATCH] Fix recently added QERR_ definitions

2009-12-08 Thread Markus Armbruster
Commits c7c338c4, 41471a23, 7a046f5f and a488be27 used lower_case_with_underscores for class values. Existing usage CamelCase. ChangeToThatForConsistency. Signed-off-by: Markus Armbruster --- qerror.h |8 1 files changed, 4 insertions(+), 4 deletions(-) diff --git a/qerror.h b/qe

[Qemu-devel] Re: [FOR 0.12 PATCH 12/18] QError: New QERR_FD_NOT_FOUND

2009-12-08 Thread Markus Armbruster
Luiz Capitulino writes: > On Mon, 7 Dec 2009 21:37:10 +0100 > Markus Armbruster wrote: > >> +#define QERR_FD_NOT_FOUND \ >> +"{ 'class': 'fd_not_found', 'data': { 'name': %s } }" >> + > > I think this came from your previous series of not using CamelCase? > > Also happens in next patches.

Re: [Qemu-devel] Re: [FOR 0.12 PATCH 18/18] QMP: add human-readable description to error response

2009-12-08 Thread Daniel P. Berrange
On Tue, Dec 08, 2009 at 10:11:48AM -0200, Luiz Capitulino wrote: > On Mon, 7 Dec 2009 21:37:16 +0100 > Markus Armbruster wrote: > > > -{ "error": { "class": json-string, "data": json-value }, "id": json-value } > > +{ "error": { "class": json-string, "data": json-value, "desc": json-string > >

[Qemu-devel] [FOR 0.12 PATCH v4 18/22] rework -monitor handling, switch to QemuOpts

2009-12-08 Thread Gerd Hoffmann
This patch reworks the -monitor handling: - It adds a new "mon" QemuOpts list for the monitor(s). - It adds a monitor_parse() function to parse the -monitor switch. - It adds a mon_init function to initialize the monitor(s) from the "mon" QemuOpts list. - It winds up everything and removes

[Qemu-devel] [FOR 0.12 PATCH v4 16/22] default devices: drives

2009-12-08 Thread Gerd Hoffmann
Add a default_drive variable which specified whenever the default drives (cdrom, floppy, sd) should be created. It is cleared when the new -nodefaults switch is specified on the command line. Signed-off-by: Gerd Hoffmann --- vl.c | 16 ++-- 1 files changed, 10 insertions(+), 6 del

[Qemu-devel] [FOR 0.12 PATCH v4 20/22] add -qmp convinience switch

2009-12-08 Thread Gerd Hoffmann
Acts like -monitor but switched into qmp mode. Signed-off-by: Gerd Hoffmann --- qemu-options.hx |2 ++ vl.c| 14 +- 2 files changed, 11 insertions(+), 5 deletions(-) diff --git a/qemu-options.hx b/qemu-options.hx index 7234447..b8cc375 100644 --- a/qemu-options.hx

[Qemu-devel] [FOR 0.12 PATCH v4 22/22] Set default console to virtio on S390x

2009-12-08 Thread Gerd Hoffmann
All "normal" system emulation targets in qemu I'm aware of display output on either VGA or serial output. Our S390x virtio machine doesn't have such kind of legacy hardware. So instead we need to default to a virtio console. Add flags to QEMUMachine to indicate which kind of default devices make

[Qemu-devel] [FOR 0.12 PATCH v4 21/22] default devices: virtio consoles.

2009-12-08 Thread Gerd Hoffmann
This patch adds a variable default_virtcon which says whenever a default virtio console should be added. It is disabled by default, followup patch will enable it for s390. It is cleared when qemu finds '-virtiocon', '-device virtio-console-s390' or '-device virtio-console-pci' on the command line

[Qemu-devel] [FOR 0.12 PATCH v4 15/22] default devices: network

2009-12-08 Thread Gerd Hoffmann
Add a default_net variable which specified whenever a default network should be created. It is cleared in case any -net option is specified and it is also added to the new -nodefaults switch. Signed-off-by: Gerd Hoffmann --- net.c |5 - net.h |1 + vl.c |1 + 3 files changed, 6

[Qemu-devel] [FOR 0.12 PATCH v4 19/22] add new -mon switch

2009-12-08 Thread Gerd Hoffmann
Add -mon switch which maps pretty straight forward into the QemuOpts internal representation: -mon chardev=[,mode=[control|readline]][,[no]default] Via config file: [mon] chardev = "" mode = "readline" default = "on" Signed-off-by: Gerd Hoffmann --- qemu-options.hx |7 +++

[Qemu-devel] [FOR 0.12 PATCH v4 17/22] un-static qemu_chr_parse_compat()

2009-12-08 Thread Gerd Hoffmann
Signed-off-by: Gerd Hoffmann --- qemu-char.c |2 +- qemu-char.h |1 + 2 files changed, 2 insertions(+), 1 deletions(-) diff --git a/qemu-char.c b/qemu-char.c index da5c15c..c6008c3 100644 --- a/qemu-char.c +++ b/qemu-char.c @@ -2231,7 +2231,7 @@ static CharDriverState *qemu_chr_open_soc

[Qemu-devel] [FOR 0.12 PATCH v4 13/22] default devices: vga adapter.

2009-12-08 Thread Gerd Hoffmann
Qemu creates a vga display for you in case you didn't specify one on the command line. Right now this is tied to the '-vga ' command line switch, which in turn causes trouble if you are creating your gfx card using '-device VGA,'. This patch adds a variable default_vga which says whenever a defau

[Qemu-devel] [FOR 0.12 PATCH v4 11/22] default devices: qemu monitor.

2009-12-08 Thread Gerd Hoffmann
This patch makes the monitor default device configuration work like the default serial and parallel port devices. It adds a variable default_monitor which says whenever a default monitor should be added. It is enabled by default. It is cleared when qemu finds '-monitor' on the command line. Sign

[Qemu-devel] [FOR 0.12 PATCH v4 12/22] zap serial_monitor_mux

2009-12-08 Thread Gerd Hoffmann
The logic in this code obviously predates the multiple monitor capability of qemu and looks increasingly silly these days. I think the intention of this piece of code is to get a reasonable default for the -nographic case: have monitor and serial line muxed on stdio. With the new default_serial a

[Qemu-devel] [FOR 0.12 PATCH v4 10/22] default devices: parallel port.

2009-12-08 Thread Gerd Hoffmann
Qemu creates a default parallel port for you in case you didn't specify one on the command line. Right now this is tied to the '-parallel ' command line switch, which in turn causes trouble if you are creating your parallel port via '-device isa-parallel,'. This patch adds a variable default_para

[Qemu-devel] [FOR 0.12 PATCH v4 14/22] default devices: add global cmd line option.

2009-12-08 Thread Gerd Hoffmann
Add global command line option to disable default devices. Signed-off-by: Gerd Hoffmann --- qemu-options.hx |5 + vl.c|6 ++ 2 files changed, 11 insertions(+), 0 deletions(-) diff --git a/qemu-options.hx b/qemu-options.hx index 420b7d8..e05b2a0 100644 --- a/qemu-opti

[Qemu-devel] [FOR 0.12 PATCH v4 09/22] default devices: core code & serial lines.

2009-12-08 Thread Gerd Hoffmann
Qemu creates a default serial line for you in case you didn't specify one on the command line. Right now this is tied to the '-serial ' command line switch, which in turn causes trouble if you are creating your serial line via '-device isa-serial,'. This patch adds a variable default_serial which

[Qemu-devel] [FOR 0.12 PATCH v4 08/22] vc: colorize chardev title line with blue background.

2009-12-08 Thread Gerd Hoffmann
Signed-off-by: Gerd Hoffmann --- console.c |2 ++ 1 files changed, 2 insertions(+), 0 deletions(-) diff --git a/console.c b/console.c index 2aeb5b3..8086bd6 100644 --- a/console.c +++ b/console.c @@ -1388,8 +1388,10 @@ static void text_console_do_init(CharDriverState *chr, DisplayState *ds

[Qemu-devel] [FOR 0.12 PATCH v4 02/22] qdev: add command line option to set global defaults for properties.

2009-12-08 Thread Gerd Hoffmann
This patch adds infrastructure and command line option for setting global defaults for device properties, i.e. you can for example use -global virtio-blk-pci.vectors=0 to turn off msi by default for all virtio block devices. The config file syntax is: [global] driver = "virtio-blk-pci" pr

[Qemu-devel] [FOR 0.12 PATCH v4 06/22] Revert "Set default console to virtio on S390x"

2009-12-08 Thread Gerd Hoffmann
This reverts commit 93d434b4aec0702b87ebf52449a3cdf2c3596825. Signed-off-by: Gerd Hoffmann --- vl.c | 26 -- 1 files changed, 0 insertions(+), 26 deletions(-) diff --git a/vl.c b/vl.c index 11eda45..172828a 100644 --- a/vl.c +++ b/vl.c @@ -4720,20 +4720,6 @@ int main(i

[Qemu-devel] [FOR 0.12 PATCH v4 07/22] chardev: move greeting into vc backend.

2009-12-08 Thread Gerd Hoffmann
Make the 'vc' chardev backend print a title line with the chardev name after initialization, using CharDriverState->label. This replaces the banner printing code in vl.c. Signed-off-by: Gerd Hoffmann --- console.c |8 vl.c | 24 2 files changed, 8 in

[Qemu-devel] [FOR 0.12 PATCH v4 01/22] qdev: make compat stuff more generic

2009-12-08 Thread Gerd Hoffmann
This patch renames the compat properties into global properties and makes them more generic. The compatibility stuff is only one of multiple possible users now. Signed-off-by: Gerd Hoffmann --- hw/boards.h |2 +- hw/pc.c |2 +- hw/qdev-properties.c | 22 +

[Qemu-devel] [FOR 0.12 PATCH v4 05/22] Revert "monitor: Command-line flag to enable control mode"

2009-12-08 Thread Gerd Hoffmann
This reverts commit adcb181afe5a951c521411c7a8e9d9b791aa6742. Conflicts: monitor.h Signed-off-by: Gerd Hoffmann --- monitor.c | 18 -- monitor.h |1 - qemu-options.hx |5 ++--- vl.c| 11 --- 4 files changed, 6 insertions(+), 2

[Qemu-devel] [FOR 0.12 PATCH v4 04/22] chardev: make chardevs specified in config file work.

2009-12-08 Thread Gerd Hoffmann
The patch decuples the -chardev switch and the actual chardev initialization. Without this patch qemu ignores chardev entries coming via -readconfig. Signed-off-by: Gerd Hoffmann --- vl.c | 16 +--- 1 files changed, 13 insertions(+), 3 deletions(-) diff --git a/vl.c b/vl.c index

[Qemu-devel] [FOR 0.12 PATCH v4 03/22] qdev: also match bus name for global properties

2009-12-08 Thread Gerd Hoffmann
i.e. -global PCI.= will set a default property for all PCI devices. Also works for the compat properties used by machine types. Signed-off-by: Gerd Hoffmann --- hw/qdev-properties.c |3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git a/hw/qdev-properties.c b/hw/qdev-propert

[Qemu-devel] [FOR 0.12 PATCH v4 01/22] default devices: qdev integration.

2009-12-08 Thread Gerd Hoffmann
Hi, Qemu creates a bunch of default devices (serial, parallel, vga, ...) if the user didn't specify one on the command line. Unfortunaly this doesn't work well with the qdev way of doing things because this logic is tied to the -serial, -parallel, ... command line switches. Devices created via

[Qemu-devel] Re: [FOR 0.12 PATCH 18/18] QMP: add human-readable description to error response

2009-12-08 Thread Luiz Capitulino
On Mon, 7 Dec 2009 21:37:16 +0100 Markus Armbruster wrote: > -{ "error": { "class": json-string, "data": json-value }, "id": json-value } > +{ "error": { "class": json-string, "data": json-value, "desc": json-string }, > + "id": json-value } > > Where, > > - The "class" member contains t

[Qemu-devel] Re: [FOR 0.12 PATCH 12/18] QError: New QERR_FD_NOT_FOUND

2009-12-08 Thread Luiz Capitulino
On Mon, 7 Dec 2009 21:37:10 +0100 Markus Armbruster wrote: > +#define QERR_FD_NOT_FOUND \ > +"{ 'class': 'fd_not_found', 'data': { 'name': %s } }" > + I think this came from your previous series of not using CamelCase? Also happens in next patches..

[Qemu-devel] Re: [FOR 0.12 PATCH 00/18] QError conversions and more

2009-12-08 Thread Luiz Capitulino
On Mon, 7 Dec 2009 21:36:58 +0100 Markus Armbruster wrote: > This patch series converts monitor commands eject, change, closefd, > getfd to QError. Thanks a lot for this work. Although the series is already merged, I have some comments and will reply the patches.

Re: [Qemu-devel] [ANNOUNCE][Call-For-Testing] Release 0.12.0-rc1 of QEMU

2009-12-08 Thread Daniel P. Berrange
On Tue, Dec 08, 2009 at 11:40:54AM +0100, Gerd Hoffmann wrote: > On 12/07/09 19:34, Daniel P. Berrange wrote: > >On Sun, Dec 06, 2009 at 04:43:03PM -0600, Anthony Liguori wrote: > >> > >>It can be downloaded from Savannah at: > >> > >>http://download.savannah.gnu.org/releases/qemu/qemu-0.12.0-rc1.t

Re: [Qemu-devel] [PATCH] Fix backcompat for hotplug of SCSI controllers

2009-12-08 Thread Gerd Hoffmann
On 12/07/09 22:54, Anthony Liguori wrote: Daniel P. Berrange wrote: SCSI controllers have no trouble existing without any attached disks. This could be achieved with the (legacy) monitor syntax pci_add pci_addr=auto storage if=scsi This is now denied with scsi requires a backing file/device.

Re: [Qemu-devel] [ANNOUNCE][Call-For-Testing] Release 0.12.0-rc1 of QEMU

2009-12-08 Thread Gerd Hoffmann
On 12/07/09 19:34, Daniel P. Berrange wrote: On Sun, Dec 06, 2009 at 04:43:03PM -0600, Anthony Liguori wrote: It can be downloaded from Savannah at: http://download.savannah.gnu.org/releases/qemu/qemu-0.12.0-rc1.tar.gz Please send testing feedback (positive or negative) to qemu-devel and file

Re: [Qemu-devel] [PATCH VERSION 2] Disk image shared and exclusive locks.

2009-12-08 Thread Richard W.M. Jones
On Tue, Dec 08, 2009 at 11:00:17AM +0100, Kevin Wolf wrote: > Am 07.12.2009 15:16, schrieb Richard W.M. Jones: > > Here's a second go at this patch. The only change is that we add a > > second parameter (backinglock=none|shared|exclusive) which can be used > > to control locking on the first level

Re: [Qemu-devel] [PATCH] Permit zero-sized qemu_malloc() & friends

2009-12-08 Thread malc
On Tue, 8 Dec 2009, Markus Armbruster wrote: > malc writes: > [..snip..] > glibc frees since 1999. From glibc/ChangeLog.10: > > 1999-04-28 Andreas Jaeger > > * malloc/malloc.c (REALLOC_ZERO_BYTES_FREES): Define it to follow > ISO C9x and Unix98. Problem is - this is NOT what

Re: [Qemu-devel] [PATCH] Disk image shared and exclusive locks.

2009-12-08 Thread Richard W.M. Jones
On Tue, Dec 08, 2009 at 10:48:17AM +0100, Kevin Wolf wrote: > Am 07.12.2009 15:31, schrieb Richard W.M. Jones: > > So to be clear, the use case is that all the other VMs must be shut > > down, then the VM which wants to commit will upgrade its lock and > > commit, and then all the other VMs will re

Re: [Qemu-devel] [PATCH] Disk image shared and exclusive locks.

2009-12-08 Thread Kevin Wolf
Am 07.12.2009 15:31, schrieb Richard W.M. Jones: > On Mon, Dec 07, 2009 at 08:22:24AM -0600, Anthony Liguori wrote: >> Richard W.M. Jones wrote: >>> On Mon, Dec 07, 2009 at 07:39:11AM -0600, Anthony Liguori wrote: >>> Richard W.M. Jones wrote: > Also if we only acquire the loc

Re: [Qemu-devel] [PATCH VERSION 2] Disk image shared and exclusive locks.

2009-12-08 Thread Kevin Wolf
Am 07.12.2009 15:16, schrieb Richard W.M. Jones: > Here's a second go at this patch. The only change is that we add a > second parameter (backinglock=none|shared|exclusive) which can be used > to control locking on the first level (only) of backing disk. And what about the backing file of the bac

[Qemu-devel] Re: [PATCH] virtio spec: add virtio-blk max sectors feature

2009-12-08 Thread Avi Kivity
On 12/08/2009 11:44 AM, Avishay Traeger1 wrote: Thanks! Rusty. Sure. Avi - do you want me to resubmit the kvm and qemu patches? You mean the virtio and qemu patches. That's up to their maintainers (Rusty and Anthony). -- error compiling committee.c: too many arguments to funct

[Qemu-devel] Re: [PATCH] virtio spec: add virtio-blk max sectors feature

2009-12-08 Thread Avishay Traeger1
Rusty Russell wrote on 12/08/2009 07:48:00 AM: > Avishay; this would be the total sectors in an I/O, as separate from SIZE_MAX > (maximum size of any single scatterlist entry) and SEG_MAX (maximum number of > scatterlist entries)? Correct. In the guest virtblk driver, it changes the call to blk_

Re: [Qemu-devel] [PATCH] Disk image shared and exclusive locks.

2009-12-08 Thread Kevin Wolf
Am 07.12.2009 15:53, schrieb Anthony Liguori: > Daniel P. Berrange wrote: >> It is safe if you assume that no one else has tried to modify the disk >> since you opened it, otherwise you'd be commiting changes against a >> base state which no longer exists. > > 1) first user opens cow1.qcow, acqui

[Qemu-devel] Re: [FOR 0.12 PATCH v3 05/21] default devices: core code & serial lines.

2009-12-08 Thread Gerd Hoffmann
Hi, Doesn't make sense. The list is not about *creating* default devices, but about *not* creating them. Why do we need a negative list? Wouldn't it be a lot more useful to have positive lists? Maybe I'm just missing the whole point of your patchset though. Probably the latter ;) The s

Re: [Qemu-devel] [PATCH] Permit zero-sized qemu_malloc() & friends

2009-12-08 Thread Kevin Wolf
Am 07.12.2009 18:09, schrieb malc: > On Mon, 7 Dec 2009, Anthony Liguori wrote: > >> malc wrote: Does anyone object to this moving forward? >>> >>> Yeah, i object to the split production/development qemu_malloc[z]. >>> >> >> It's clear to me that there are still improper callers

[Qemu-devel] [PATCH V9 04/20] acpi: split acpi.c into the common part and the piix4 part.

2009-12-08 Thread Isaku Yamahata
Split acpi.c into the common part and the piix4 specific part. The common part will be used later. Signed-off-by: Isaku Yamahata --- Makefile.target |4 +- hw/acpi.c | 557 --- hw/{acpi.c => acpi_piix4.c} | 172 +

[Qemu-devel] [PATCH V9 01/20] acpi: split out pc smbus routines from acpi.c into pc_smbus.c

2009-12-08 Thread Isaku Yamahata
Split out pc smbus routines from acpi.c into pc_smbus.c and use it. The split out smbus emulation will be used later. Signed-off-by: Isaku Yamahata --- Makefile.target |2 + hw/acpi.c | 164 +++ hw/pc_smbus.c | 178 +++

[Qemu-devel] Re: [PATCH VERSION 2] Disk image shared and exclusive locks.

2009-12-08 Thread Paolo Bonzini
On 12/07/2009 04:06 PM, Anthony Liguori wrote: For GPFS-like shared filesystems (:-P) we would always use lock=off. It wouldn't protect us from a non-cluster aware writer. Management tools can always do this the right way---even with partition-grained locking if needed. Paolo

[Qemu-devel] [PATCH V9 16/20] pc: split out basic device init from pc_init1() into pc_basic_device_init()

2009-12-08 Thread Isaku Yamahata
Split out basic device, i.e. legacy devices like floppy, initialization from pc_init1() into pc_basic_device_init(). Later it will be used. Signed-off-by: Isaku Yamahata --- hw/pc.c | 89 +++--- 1 files changed, 50 insertions(+), 39 delet

[Qemu-devel] [PATCH V9 20/20] rtc: make rtc_xxx accept/return ISADevice instead of RTCState.

2009-12-08 Thread Isaku Yamahata
To match rtc_xxx with qdev, make rtc_xxx accept and return ISADevice instead of RTCState. Signed-off-by: Isaku Yamahata --- hw/mc146818rtc.c | 26 +++--- hw/mc146818rtc.h |8 hw/mips_jazz.c |1 + hw/mips_malta.c |3 ++- hw/mips_r4k.c|3 ++- h

[Qemu-devel] [PATCH V9 13/20] pc: split out cpu initialization from pc_init1() into pc_cpus_init().

2009-12-08 Thread Isaku Yamahata
split out cpu initialization which is piix independent from pc_init1() into pc_cpus_init(). Later it will be used. Signed-off-by: Isaku Yamahata --- hw/pc.c | 32 +++- 1 files changed, 19 insertions(+), 13 deletions(-) diff --git a/hw/pc.c b/hw/pc.c index d0ef06b..

[Qemu-devel] [PATCH V9 05/20] acpi_piix4: remove unused variable in get_pmsts().

2009-12-08 Thread Isaku Yamahata
remove unused variable in get_pmsts(). Signed-off-by: Isaku Yamahata --- hw/acpi_piix4.c |2 -- 1 files changed, 0 insertions(+), 2 deletions(-) diff --git a/hw/acpi_piix4.c b/hw/acpi_piix4.c index 53efa2a..887c82f 100644 --- a/hw/acpi_piix4.c +++ b/hw/acpi_piix4.c @@ -63,8 +63,6 @@ static

[Qemu-devel] [PATCH V9 06/20] pc: initialize ioapic before use.

2009-12-08 Thread Isaku Yamahata
The changeset of 2c8d9340203c7f19265fd4cb2341f568217a3af6 prevents isa_irq_handler() from NULL refering of IsaIrqState::ioapic. However it would be better to initialize the member before reference. Signed-off-by: Isaku Yamahata --- hw/pc.c |6 +++--- 1 files changed, 3 insertions(+), 3 delet

  1   2   >