Re: [Qemu-devel] [PATCH] SeaBios: Fix reset procedure reentrancy problem on qemu-kvm platform

2015-12-18 Thread Gonglei (Arei)
> > From: Kevin O'Connor [mailto:ke...@koconnor.net] > Sent: Saturday, December 19, 2015 7:13 AM > To: Gonglei (Arei) > Cc: Xulei (Stone); Paolo Bonzini; qemu-devel; seab...@seabios.org; > Huangweidong (C); k...@vger.kernel.org > Subject: Re: [Qemu-devel] [PATCH] SeaBios: Fix reset procedure reentr

Re: [Qemu-devel] RFC: Operation Blockers in QEMU Block Nodes

2015-12-18 Thread Jeff Cody
On Fri, Dec 18, 2015 at 03:19:25PM +0100, Kevin Wolf wrote: > Am 16.12.2015 um 07:25 hat Jeff Cody geschrieben: > > Background: > > > > Block jobs, and other QAPI operations, may modify and impact the > > BlockDriverState graph in QEMU. In order to support multiple > > operations safe

Re: [Qemu-devel] [PATCH] SeaBios: Fix reset procedure reentrancy problem on qemu-kvm platform

2015-12-18 Thread Gonglei (Arei)
Hi Kevin & Paolo, Luckily, I reproduced this problem last night. And I got the below log when SeaBIOS is stuck. [BTW, the whole SeaBIOS log attached] [2015-12-18 10:38:10] >gonglei: enter smp_setup()... [2015-12-18 10:38:10] >gonglei: begine to enable local APIC... [2015-12-18 10:38:10]

[Qemu-devel] ping Re: [PATCH v12] block/raw-posix.c: Make physical devices usable in QEMU under Mac OS X host

2015-12-18 Thread Programmingkid
https://patchwork.ozlabs.org/patch/555945/ On Dec 11, 2015, at 10:27 PM, Programmingkid wrote: > Mac OS X can be picky when it comes to allowing the user > to use physical devices in QEMU. Most mounted volumes > appear to be off limits to QEMU. If an issue is detected, > a message is displayed sh

[Qemu-devel] [Bug 1527765] Re: sh4: ghc randomly segfaults on qemu-sh4-static

2015-12-18 Thread Laurent Vivier
Thank you for the 611 MB tar The behavior is a little bit different on my system: root@Quad:~# ls ghc-7.8.4 ghc_7.8.4-9~bpo8+1.dsc ghc_7.8.4-9~bpo8+1.debian.tar.xz ghc_7.8.4.orig.tar.xz root@Quad:~# cd ghc-7.8.4/utils/ghc-p ghc-pkg/ ghc-pwd/ root@Quad:~# cd ghc-7.8.4

Re: [Qemu-devel] [PATCH] SeaBios: Fix reset procedure reentrancy problem on qemu-kvm platform

2015-12-18 Thread Kevin O'Connor
On Fri, Dec 18, 2015 at 03:04:58AM +, Gonglei (Arei) wrote: > Hi Kevin & Paolo, > > Luckily, I reproduced this problem last night. And I got the below log when > SeaBIOS is stuck. [...] > [2015-12-18 10:38:10] gonglei: finish while [...] > <...>-31509 [035] 154753.180077: kvm_exit: reason

Re: [Qemu-devel] [PATCH 08/11] qjson: Simplify by using json-output-visitor

2015-12-18 Thread Eric Blake
On 12/11/2015 04:10 AM, Paolo Bonzini wrote: > > > On 11/12/2015 00:53, Eric Blake wrote: >> Instead of rolling our own limited JSON outputter, we can just >> wrap the more full-featured JSON output Visitor. >> >> This slightly changes the output (different spacing), but the >> result is still eq

Re: [Qemu-devel] [PATCH] linux-user/syscall.c: Notice about lock bitmask translation for fcntl

2015-12-18 Thread Chen Gang
On 12/19/15 06:15, Laurent Vivier wrote: > > Le 18/12/2015 23:12, Chen Gang a écrit : >> [...] >> >> OK, thank you very much. I shall config my email client again to notice >> about it. > > You should not use your email client to send patches, you should use > "git send-email": > > http://wik

[Qemu-devel] [Bug 1174654] Re: qemu-system-x86_64 takes 100% CPU after host machine resumed from suspend to ram

2015-12-18 Thread varacanero
Same for me here, Ubuntu wily. I'm using vagrant-libvirt, and my hosts also very often run wild with 100% cpu usage after suspend. -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1174654 Title: qemu

Re: [Qemu-devel] [PATCH] linux-user/syscall.c: Notice about lock bitmask translation for fcntl

2015-12-18 Thread Laurent Vivier
Le 18/12/2015 23:12, Chen Gang a écrit : > > On 12/19/15 05:58, Laurent Vivier wrote: >> >> Le 18/12/2015 22:40, Chen Gang a écrit : >>> > > [...] > >>> I did not get any script/checkpatch.pl complains, originally. >>> >>> Does my email client configuration is incorrect, then cause incorrect >

[Qemu-devel] [Bug 1527765] [NEW] sh4: ghc randomly segfaults on qemu-sh4-static

2015-12-18 Thread John Paul Adrian Glaubitz
Public bug reported: Hello! I am currently in the process of bootstrapping ghc for the Debian sh4 port and ran into a strange problem with qemu-sh4-static which randomly segfaults when running ghc to compile a Haskell source: root@jessie32:~/ghc-7.8.4/utils/ghc-pwd# ls Main.hi Main.hs Setup.hs

Re: [Qemu-devel] [PATCH] linux-user/syscall.c: Notice about lock bitmask translation for fcntl

2015-12-18 Thread Chen Gang
On 12/19/15 05:58, Laurent Vivier wrote: > > Le 18/12/2015 22:40, Chen Gang a écrit : >> [...] >> I did not get any script/checkpatch.pl complains, originally. >> >> Does my email client configuration is incorrect, then cause incorrect >> mail format? I guess not. The related reason is below. >

Re: [Qemu-devel] [PATCH] linux-user/syscall.c: Notice about lock bitmask translation for fcntl

2015-12-18 Thread Laurent Vivier
Le 18/12/2015 22:40, Chen Gang a écrit : > > On 12/18/15 17:37, Laurent Vivier wrote: >> >> Le 18/12/2015 07:26, Chen Gang a écrit : >>> >>> For fcntl, it always needs to notice about it, just like do_fcntl() has >>> done, or it will cause issue (e.g. alpha host run i386 guest). >>> >>> Signed-o

Re: [Qemu-devel] [Qemu-block] [PATCH] qemu-iotests: Reduce racy output in 028

2015-12-18 Thread John Snow
On 12/18/2015 03:46 PM, Eric Blake wrote: > On 12/11/2015 06:23 PM, John Snow wrote: >> > > ping > >> >> On 12/10/2015 10:27 PM, Eric Blake wrote: >>> On my machine, './check -qcow2 028' was failing about 80% of the >>> time, due to a race in how many times the repeated attempts >>> to run 'inf

Re: [Qemu-devel] Jobs 2.0 QAPI [RFC]

2015-12-18 Thread Eric Blake
On 12/18/2015 02:24 PM, John Snow wrote: >> To be subclassable, we need a flat union, and the discriminator must be >> non-optional within that union. Either 'options' is that flat union >> (and we have a layer of {} nesting in QMP}, or we directly make the >> 'data' of job-cancel be the flat uni

Re: [Qemu-devel] [PATCH] linux-user/syscall.c: Notice about lock bitmask translation for fcntl

2015-12-18 Thread Chen Gang
On 12/18/15 17:37, Laurent Vivier wrote: > > Le 18/12/2015 07:26, Chen Gang a écrit : >> >> For fcntl, it always needs to notice about it, just like do_fcntl() has >> done, or it will cause issue (e.g. alpha host run i386 guest). >> >> Signed-off-by: Chen Gang >> --- >> linux-user/syscall.c |

Re: [Qemu-devel] Jobs 2.0 QAPI [RFC]

2015-12-18 Thread John Snow
On 12/18/2015 01:07 PM, Eric Blake wrote: > On 12/16/2015 05:50 PM, John Snow wrote: >> In working through a prototype to enable multiple block jobs. A few >> problem spots in our API compatibility become apparent. >> > >> qmp_query_block_jobs >> > >> Let's consider using a new comman

Re: [Qemu-devel] [PATCH 2/5] igd-passthrough-i440FX: convert to realize()

2015-12-18 Thread Markus Armbruster
One short remark in addition to Eduardo's review. Eduardo Habkost writes: > On Fri, Dec 18, 2015 at 07:03:49PM +0800, Cao jin wrote: >> Signed-off-by: Cao jin >> --- >> hw/pci-host/piix.c | 16 +--- >> 1 file changed, 9 insertions(+), 7 deletions(-) >> >> diff --git a/hw/pci-host/

Re: [Qemu-devel] [PATCH 2/2] qdev: safely fail device_add if unable to allocate device

2015-12-18 Thread Markus Armbruster
Eric Blake writes: > On 12/18/2015 09:48 AM, Daniel P. Berrange wrote: >> On Fri, Dec 18, 2015 at 04:30:47PM +0100, Igor Mammedov wrote: >>> qdev_device_add() currently uses object_new() which >>> will abort if there memory allocation for device instance >>> fails. While it's fine it startup, it

Re: [Qemu-devel] [Qemu-block] [PATCH] qemu-iotests: Reduce racy output in 028

2015-12-18 Thread Eric Blake
On 12/11/2015 06:23 PM, John Snow wrote: > ping > > On 12/10/2015 10:27 PM, Eric Blake wrote: >> On my machine, './check -qcow2 028' was failing about 80% of the >> time, due to a race in how many times the repeated attempts >> to run 'info block-jobs' could occur before the job was done, >> sh

[Qemu-devel] [PATCH v3 1/2] i386: expose floppy-related objects in SSDT

2015-12-18 Thread Roman Kagan
On x86-based systems Linux determines the presence and the type of floppy drives via a query of a CMOS field. So does SeaBIOS when populating the return data for int 0x13 function 0x08. Windows doesn't; instead, it requests this information from BIOS via int 0x13/0x08 or through ACPI objects _FDE

[Qemu-devel] [PATCH v3 2/2] tests: update expected SSDT for floppy changes

2015-12-18 Thread Roman Kagan
Update the expected SSDTs to reflect the changes introduced in the previous patch. Signed-off-by: Roman Kagan Signed-off-by: Denis V. Lunev CC: Michael S. Tsirkin CC: Igor Mammedov CC: Paolo Bonzini CC: Richard Henderson CC: Eduardo Habkost CC: John Snow CC: Kevin Wolf --- changes since v

[Qemu-devel] [PATCH v3 0/2] i386: expose floppy-related objects in SSDT

2015-12-18 Thread Roman Kagan
Roman Kagan (2): i386: expose floppy-related objects in SSDT tests: update expected SSDT for floppy changes Signed-off-by: Roman Kagan Signed-off-by: Denis V. Lunev CC: Michael S. Tsirkin CC: Igor Mammedov CC: Paolo Bonzini CC: Richard Henderson CC: Eduardo Habkost CC: John Snow CC: Ke

Re: [Qemu-devel] [PATCH v3 06/11] fdc: do not call revalidate on eject

2015-12-18 Thread John Snow
On 12/18/2015 11:11 AM, Markus Armbruster wrote: > John Snow writes: > >> Currently, fd_revalidate is called in two different places, with two >> different expectations of behavior: >> >> (1) On initialization, as a routine to help pick the drive type and >> initial geometries as a side-eff

Re: [Qemu-devel] x-input-send-event marked as experimental

2015-12-18 Thread Markus Armbruster
Marcelo Tosatti writes: > Gerd, > > commit df5b2adb7398d71016ee469f71e52075ed95e04e > Author: Gerd Hoffmann > Date: Tue Nov 25 14:54:17 2014 +0100 > > input: move input-send-event into experimental namespace > > Ongoing discussions on how we are going to specify the console, >

Re: [Qemu-devel] [PATCH v3 6/9] target-arm: support QMP dump-guest-memory

2015-12-18 Thread Andrew Jones
On Fri, Dec 18, 2015 at 06:46:14PM +, Peter Maydell wrote: > On 18 December 2015 at 18:05, Andrew Jones wrote: > > On Fri, Dec 18, 2015 at 04:31:13PM +, Peter Maydell wrote: > >> On 18 December 2015 at 16:05, Andrew Jones wrote: > >> > On Fri, Dec 18, 2015 at 11:59:39AM +, Peter Mayde

Re: [Qemu-devel] [PATCH] gtk: use setlocale() for LC_MESSAGES only

2015-12-18 Thread Markus Armbruster
Alberto Garcia writes: >>> > We do however have translations for a few simple strings for the GTK+ >>> > menu items, so in order to run QEMU using the C locale, and yet have a >>> > translated UI let's use setlocale() for LC_MESSAGES only. >>> > >>> Not sure why I noticed it only now and if it's

[Qemu-devel] x-input-send-event marked as experimental

2015-12-18 Thread Marcelo Tosatti
Gerd, commit df5b2adb7398d71016ee469f71e52075ed95e04e Author: Gerd Hoffmann Date: Tue Nov 25 14:54:17 2014 +0100 input: move input-send-event into experimental namespace Ongoing discussions on how we are going to specify the console, so tag the command as experiental so we can

Re: [Qemu-devel] [PATCH v2 07/14] acpi: Remove guest_info parameters from functions

2015-12-18 Thread Marcel Apfelbaum
On 12/18/2015 08:08 PM, Eduardo Habkost wrote: On Tue, Dec 15, 2015 at 02:36:10PM +0200, Marcel Apfelbaum wrote: On 12/11/2015 08:42 PM, Eduardo Habkost wrote: We can use PC_MACHINE(qdev_get_machine())->acpi_guest_info to get guest_info. Hi Eduardo, I like the idea of using qdev_get_machine(

Re: [Qemu-devel] [PATCH v3 6/9] target-arm: support QMP dump-guest-memory

2015-12-18 Thread Peter Maydell
On 18 December 2015 at 18:05, Andrew Jones wrote: > On Fri, Dec 18, 2015 at 04:31:13PM +, Peter Maydell wrote: >> On 18 December 2015 at 16:05, Andrew Jones wrote: >> > On Fri, Dec 18, 2015 at 11:59:39AM +, Peter Maydell wrote: >> >> I don't understand why we need to do this. If this is a

Re: [Qemu-devel] [PATCH v4 5/5] kvm/x86: Hyper-V kvm exit

2015-12-18 Thread Roman Kagan
On Fri, Dec 18, 2015 at 10:10:11AM -0800, Peter Hornyack wrote: > On Fri, Dec 18, 2015 at 8:01 AM, Paolo Bonzini wrote: > > On 18/12/2015 16:19, Pavel Fedin wrote: > >> As far as i understand this code, KVM_EXIT_HYPERV is called when one > >> of three MSRs are accessed. But, shouldn't we have impl

Re: [Qemu-devel] [PATCH 2/5] igd-passthrough-i440FX: convert to realize()

2015-12-18 Thread Eduardo Habkost
On Fri, Dec 18, 2015 at 07:03:49PM +0800, Cao jin wrote: > Signed-off-by: Cao jin > --- > hw/pci-host/piix.c | 16 +--- > 1 file changed, 9 insertions(+), 7 deletions(-) > > diff --git a/hw/pci-host/piix.c b/hw/pci-host/piix.c > index 715208b..e3840f0 100644 > --- a/hw/pci-host/piix.

Re: [Qemu-devel] [PATCH v4 5/5] kvm/x86: Hyper-V kvm exit

2015-12-18 Thread 'Roman Kagan'
On Fri, Dec 18, 2015 at 05:01:59PM +0100, Paolo Bonzini wrote: > On 18/12/2015 16:19, Pavel Fedin wrote: > > As far as i understand this code, KVM_EXIT_HYPERV is called when one > > of three MSRs are accessed. But, shouldn't we have implemented > > instead something more generic, like KVM_EXIT_REG

Re: [Qemu-devel] [PATCH] hw/q35: fix pc-q35-1.6 machine options

2015-12-18 Thread Eduardo Habkost
On Thu, Dec 17, 2015 at 07:34:07PM +0200, Marcel Apfelbaum wrote: > Following the convention each machine_options function should call > the next machine options first. > > Signed-off-by: Marcel Apfelbaum Reviewed-by: Eduardo Habkost -- Eduardo

Re: [Qemu-devel] [PATCH v4 5/5] kvm/x86: Hyper-V kvm exit

2015-12-18 Thread Paolo Bonzini
On 18/12/2015 19:10, Peter Hornyack wrote: > On brief inspection of Andrey's patch (I have not been following > closely) it looks like the kvm_hyperv_exit struct that's returned to > userspace contains more data (control, evt_page, and msg_page fields) > than simply the value of the MSR, so would

Re: [Qemu-devel] [PATCH 10/10] iotests: 095: Use TEST_IMG override instead of "mv"

2015-12-18 Thread Max Reitz
On 16.12.2015 10:54, Fam Zheng wrote: > Signed-off-by: Fam Zheng > --- > tests/qemu-iotests/095 | 12 ++-- > tests/qemu-iotests/095.out | 8 > 2 files changed, 10 insertions(+), 10 deletions(-) > > diff --git a/tests/qemu-iotests/095 b/tests/qemu-iotests/095 > index 6630181

Re: [Qemu-devel] [PATCH 00/10] iotests: Clean up "mv $TEST_IMG $TEST_IMG.XXX"

2015-12-18 Thread Max Reitz
On 16.12.2015 10:54, Fam Zheng wrote: > Commit 794d00f71d fixed two "mv" commands into the TEST_IMG override approach. > There are still more occasions of "mv", this series fixes them. > > The benefit is it drops the assumption that the created image is a single > file, > which is not true for VM

Re: [Qemu-devel] [PATCH v4 5/5] kvm/x86: Hyper-V kvm exit

2015-12-18 Thread Peter Hornyack
On Fri, Dec 18, 2015 at 8:01 AM, Paolo Bonzini wrote: > > > On 18/12/2015 16:19, Pavel Fedin wrote: >> As far as i understand this code, KVM_EXIT_HYPERV is called when one >> of three MSRs are accessed. But, shouldn't we have implemented >> instead something more generic, like KVM_EXIT_REG_IO, whi

Re: [Qemu-devel] [PATCH v2 07/14] acpi: Remove guest_info parameters from functions

2015-12-18 Thread Eduardo Habkost
On Tue, Dec 15, 2015 at 02:36:10PM +0200, Marcel Apfelbaum wrote: > On 12/11/2015 08:42 PM, Eduardo Habkost wrote: > >We can use PC_MACHINE(qdev_get_machine())->acpi_guest_info to get > >guest_info. > > Hi Eduardo, > > I like the idea of using qdev_get_machine() to get the machine instead of > ke

Re: [Qemu-devel] Jobs 2.0 QAPI [RFC]

2015-12-18 Thread Eric Blake
On 12/16/2015 05:50 PM, John Snow wrote: > In working through a prototype to enable multiple block jobs. A few > problem spots in our API compatibility become apparent. > > qmp_query_block_jobs > > Let's consider using a new command. I'm not sure if this is strictly > possible with cu

Re: [Qemu-devel] [PATCH v3 6/9] target-arm: support QMP dump-guest-memory

2015-12-18 Thread Andrew Jones
On Fri, Dec 18, 2015 at 04:31:13PM +, Peter Maydell wrote: > On 18 December 2015 at 16:05, Andrew Jones wrote: > > On Fri, Dec 18, 2015 at 11:59:39AM +, Peter Maydell wrote: > >> On 15 December 2015 at 22:51, Andrew Jones wrote: > >> > Add the support needed for creating prstatus elf note

Re: [Qemu-devel] [PATCH] gtk: use setlocale() for LC_MESSAGES only

2015-12-18 Thread Alberto Garcia
>> > We do however have translations for a few simple strings for the GTK+ >> > menu items, so in order to run QEMU using the C locale, and yet have a >> > translated UI let's use setlocale() for LC_MESSAGES only. >> > >> Not sure why I noticed it only now and if it's related to any recent >> pac

Re: [Qemu-devel] guest kernel in the host RAM

2015-12-18 Thread Paolo Bonzini
On 18/12/2015 17:28, Denis V. Lunev wrote: >> Linux patches itself a lot, which >> makes the memory savings minimal (if they exist at all). What is the >> decompression time for a kernel that is compressed with LZO? > > It seems that you are perfectly correct here! > > With large pages enabled

Re: [Qemu-devel] [PATCH 3/5] PXB: convert to realize()

2015-12-18 Thread Paolo Bonzini
On 18/12/2015 12:03, Cao jin wrote: > Signed-off-by: Cao jin > --- > hw/pci-bridge/pci_expander_bridge.c | 24 ++-- > 1 file changed, 14 insertions(+), 10 deletions(-) > > diff --git a/hw/pci-bridge/pci_expander_bridge.c > b/hw/pci-bridge/pci_expander_bridge.c > index 57f8

Re: [Qemu-devel] [PATCH v4 5/5] kvm/x86: Hyper-V kvm exit

2015-12-18 Thread 'Roman Kagan'
On Fri, Dec 18, 2015 at 06:19:25PM +0300, Pavel Fedin wrote: > I dislike implementing architecture-dependent exit code where we could > implement an architecture-independent one. > > As far as i understand this code, KVM_EXIT_HYPERV is called when one of > three MSRs are accessed. But, shouldn

Re: [Qemu-devel] [PATCH 5/5] xen-pvdevice: convert to realize()

2015-12-18 Thread Paolo Bonzini
CCing Stefano, who is the maintainer. Paolo On 18/12/2015 12:03, Cao jin wrote: > Signed-off-by: Cao jin > --- > hw/i386/xen/xen_pvdevice.c | 12 ++-- > 1 file changed, 6 insertions(+), 6 deletions(-) > > diff --git a/hw/i386/xen/xen_pvdevice.c b/hw/i386/xen/xen_pvdevice.c > index c218

Re: [Qemu-devel] [PATCH 4/5] gt64120: convert to realize()

2015-12-18 Thread Paolo Bonzini
Cc: qemu-triv...@nongnu.org On 18/12/2015 12:03, Cao jin wrote: > Signed-off-by: Cao jin > --- > hw/mips/gt64xxx_pci.c | 6 ++ > 1 file changed, 2 insertions(+), 4 deletions(-) > > diff --git a/hw/mips/gt64xxx_pci.c b/hw/mips/gt64xxx_pci.c > index f76a9fd..c1f3c9c 100644 > --- a/hw/mips/gt

Re: [Qemu-devel] [PATCH 1/5] SH PCI Host: convert to realize()

2015-12-18 Thread Paolo Bonzini
Cc: qemu-triv...@nongnu.org On 18/12/2015 12:03, Cao jin wrote: > Signed-off-by: Cao jin > --- > hw/sh4/sh_pci.c | 5 ++--- > 1 file changed, 2 insertions(+), 3 deletions(-) > > diff --git a/hw/sh4/sh_pci.c b/hw/sh4/sh_pci.c > index a2f6d9e..4509053 100644 > --- a/hw/sh4/sh_pci.c > +++ b/hw/sh4

Re: [Qemu-devel] [PATCH v5 5/6] xlnx-zynqmp: Connect the SPI devices

2015-12-18 Thread Paolo Bonzini
On 18/12/2015 18:17, Alistair Francis wrote: > Does anyone have any ideas on how we can do this? > > AFAIK there is no way to currently do this, so we need to add > something. What is the preferred way to expose the buses? For now, what you're doing is okay for me, just moving the funky code in

[Qemu-devel] [PULL 1/1] numa: Clean up query-memdev error handling

2015-12-18 Thread Eduardo Habkost
From: Markus Armbruster qmp_query_memdev() has two error paths: * When object_get_objects_root() returns null. It never does, so simply drop the useless error handling. * When query_memdev() fails. It leaks err then. But any failure there is actually a programming error. Switch it to &e

[Qemu-devel] [PULL 0/1] NUMA queue, 2015-12-18

2015-12-18 Thread Eduardo Habkost
The following changes since commit c688084506cf2cf2eba4ba9df4e91abb6e3dab83: Merge remote-tracking branch 'remotes/berrange/tags/pull-qcrypto-secrets-base-2015-12-18-1' into staging (2015-12-18 17:04:15 +) are available in the git repository at: git://github.com/ehabkost/qemu.git tags/

Re: [Qemu-devel] [RESEND PATCH] q35: Remove old machine versions

2015-12-18 Thread Eduardo Habkost
On Fri, Dec 18, 2015 at 10:41:45AM +0100, Gerd Hoffmann wrote: > On Do, 2015-12-17 at 15:27 -0200, Eduardo Habkost wrote: > > Migration with q35 was not possible before commit > > 04329029a8c539eb5f75dcb6d8b016f0c53a031a, because q35 unconditionally > > creates an ich9-ahci device, that was marked

[Qemu-devel] [PATCH v2] qga: Support enum names in guest-file-seek

2015-12-18 Thread Eric Blake
Magic constants are a pain to use, especially when we run the risk that our choice of '1' for QGA_SEEK_CUR might differ from the host or guest's choice of SEEK_CUR. Better is to use an enum value, via a qapi alternate type for back-compatibility. With this, {"command":"guest-file-seek", "argumen

Re: [Qemu-devel] [PULL v1 0/5] Support for securely passing secrets to QEMU

2015-12-18 Thread Peter Maydell
On 18 December 2015 at 16:53, Daniel P. Berrange wrote: > The following changes since commit 18f49881cf8359e89396aac12f5d3cf3f8a632ba: > > configure: Fix shell syntax to placate OpenBSD's pdksh (2015-12-18 13:32:49 > +) > > are available in the git repository at: > > git://github.com/berr

Re: [Qemu-devel] [PATCH v3 05/11] fdc: Add fallback option

2015-12-18 Thread John Snow
On 12/18/2015 10:57 AM, Markus Armbruster wrote: > John Snow writes: > >> Add the fallback drive type as an option so we can control >> the behavior as a function of the QEMU machine version. > > What's a "fallback drive type", and what does (or will) it do? > I assume you mean "Make your co

Re: [Qemu-devel] [PATCH 2/2] qdev: safely fail device_add if unable to allocate device

2015-12-18 Thread Eric Blake
On 12/18/2015 09:48 AM, Daniel P. Berrange wrote: > On Fri, Dec 18, 2015 at 04:30:47PM +0100, Igor Mammedov wrote: >> qdev_device_add() currently uses object_new() which >> will abort if there memory allocation for device instance >> fails. While it's fine it startup, it is not desirable >> diring

Re: [Qemu-devel] [PATCH COLO-Frame v12 23/38] COLO: Implement failover work for Primary VM

2015-12-18 Thread Dr. David Alan Gilbert
* zhanghailiang (zhang.zhanghaili...@huawei.com) wrote: > For PVM, if there is failover request from users. > The colo thread will exit the loop while the failover BH does the > cleanup work and resumes VM. > > Signed-off-by: zhanghailiang > Signed-off-by: Li Zhijian > --- > v12: > - Fix error r

Re: [Qemu-devel] [PATCH v3 04/11] fdc: add default drive type option

2015-12-18 Thread John Snow
On 12/18/2015 10:54 AM, Markus Armbruster wrote: > John Snow writes: > >> This patch adds a new explicit Floppy Drive Type option. The existing >> behavior in QEMU is to automatically guess a drive type based on the >> media inserted, or if a diskette is not present, arbitrarily assign one. >>

[Qemu-devel] [PULL 48/48] block/qapi: allow best-effort query

2015-12-18 Thread Kevin Wolf
From: John Snow For more complex BDS trees that can be created under normal circumstances, we lose the ability to issue query commands because of our inability to re-construct the absolute filename. Instead, omit this field when it is a problem and present as much information as we can. This wi

[Qemu-devel] [PATCH 1/2] vhdx: DIV_ROUND_UP() in vhdx_calc_bat_entries()

2015-12-18 Thread Max Reitz
We have DIV_ROUND_UP(), so we can use it to produce more easily readable code. It may be slower than the bit shifting currently performed (because it actually performs a division), but since vhdx_calc_bat_entries() is never used in a hot path, this is completely fine. Signed-off-by: Max Reitz ---

[Qemu-devel] [PATCH v3 23/24] s390/sclp: Simplify control flow in sclp_realize()

2015-12-18 Thread Markus Armbruster
Suggested-by: David Hildenbrand Signed-off-by: Markus Armbruster Reviewed-by: David Hildenbrand Acked-by: Cornelia Huck Reviewed-by: Eric Blake --- hw/s390x/sclp.c | 9 +++-- 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/hw/s390x/sclp.c b/hw/s390x/sclp.c index 9a117c9..74f

Re: [Qemu-devel] [PATCH v5 5/6] xlnx-zynqmp: Connect the SPI devices

2015-12-18 Thread Alistair Francis
On Thu, Dec 17, 2015 at 3:12 AM, Paolo Bonzini wrote: > > > On 17/12/2015 12:11, Peter Maydell wrote: >> > It's a hack and I don't want it to become a sanctioned way to do it. >> > It's already messing around pretty heavily with qdev internals, see the >> > line right after QLIST_INSERT_HEAD: >> >

[Qemu-devel] [PULL 26/48] block: Add opaque value to the amend CB

2015-12-18 Thread Kevin Wolf
From: Max Reitz Add an opaque value which is to be passed to the bdrv_amend_options() status callback. Signed-off-by: Max Reitz Reviewed-by: Eric Blake Reviewed-by: Stefan Hajnoczi Reviewed-by: Alberto Garcia Signed-off-by: Kevin Wolf --- block.c | 4 ++-- block/qcow2-cl

[Qemu-devel] [PATCH 0/2] block/vhdx: Small cleanups

2015-12-18 Thread Max Reitz
Just some bits I discovered while going through the Coverity report. (The issue reported by Coverity actually was not an issue.) Max Reitz (2): vhdx: DIV_ROUND_UP() in vhdx_calc_bat_entries() vhdx: Simplify vhdx_set_shift_bits() block/vhdx.c | 18 ++ 1 file changed, 6 inser

Re: [Qemu-devel] [PATCH COLO-Frame v12 14/38] ram: Split host_from_stream_offset() into two helper functions

2015-12-18 Thread Dr. David Alan Gilbert
* zhanghailiang (zhang.zhanghaili...@huawei.com) wrote: > Split host_from_stream_offset() into two parts: > One is to get ram block, which the block idstr may be get from migration > stream, the other is to get hva (host) address from block and the offset. > Besides, we will do the check working in

[Qemu-devel] [PULL 33/48] qcow2: Point to amend function in check

2015-12-18 Thread Kevin Wolf
From: Max Reitz If a reference count is not representable with the current refcount order, the image check should point to qemu-img amend for increasing the refcount order. However, qemu-img amend needs write access to the image which cannot be provided if the image is marked corrupt; and the ima

Re: [Qemu-devel] [PULL 00/48] Block patches

2015-12-18 Thread Peter Maydell
On 18 December 2015 at 15:07, Kevin Wolf wrote: > The following changes since commit 67a708406221f476c0f8fa60c192c186150c5185: > > Merge remote-tracking branch > 'remotes/berrange/tags/pull-io-channel-base-2015-12-18-1' into staging > (2015-12-18 12:42:10 +) > > are available in the git re

[Qemu-devel] [PULL 12/48] block: Allow specifying child options in reopen

2015-12-18 Thread Kevin Wolf
If the child was defined in the same context (-drive argument or blockdev-add QMP command) as its parent, a reopen of the parent should work the same and allow changing options of the child. Signed-off-by: Kevin Wolf Reviewed-by: Max Reitz Reviewed-by: Alberto Garcia --- block.c | 12 +

[Qemu-devel] [PULL 0/2] xsa155

2015-12-18 Thread Stefano Stabellini
The following changes since commit 18f49881cf8359e89396aac12f5d3cf3f8a632ba: configure: Fix shell syntax to placate OpenBSD's pdksh (2015-12-18 13:32:49 +) are available in the git repository at: git://xenbits.xen.org/people/sstabellini/qemu-dm.git tags/xsa155 for you to fetch changes

[Qemu-devel] [PATCH v3 20/24] vhdx: Fix "log that needs to be replayed" error message

2015-12-18 Thread Markus Armbruster
The arguments of error_setg_errno() should yield a short error string without newlines. Here, we try to append additional help to the error message by embedding newlines in the error string. That's nice, but it's doesn't play nicely with the errno part. tests/qemu-iotests/070.out shows the resul

[Qemu-devel] [PULL 44/48] block/qapi: do not redundantly print "actual path"

2015-12-18 Thread Kevin Wolf
From: John Snow If it happens to match the backing path, that was the actual path. Signed-off-by: John Snow Reviewed-by: Max Reitz Message-id: 1450122916-4706-2-git-send-email-js...@redhat.com Signed-off-by: Max Reitz --- block/qapi.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)

[Qemu-devel] [PULL 08/48] block: Consider all block layer options in append_open_options

2015-12-18 Thread Kevin Wolf
The code already special-cased "node-name", which is currently the only option passed in the QDict that isn't driver-specific. Generalise the code to take all general block layer options into consideration. Signed-off-by: Kevin Wolf Reviewed-by: Eric Blake Reviewed-by: Max Reitz Reviewed-by: Al

Re: [Qemu-devel] [PATCH for-2.5??] configure: Fix shell syntax to placate OpenBSD's pdksh

2015-12-18 Thread Peter Maydell
On 14 December 2015 at 15:02, Peter Maydell wrote: > Unfortunately the OpenBSD pdksh does not like brackets inside > the right part of a ${variable+word} parameter expansion: > > $ echo "${a+($b)}" > ksh: ${a+($b)}": bad substitution > > though both bash and dash accept them. In any case this

[Qemu-devel] [PULL 45/48] block/qapi: always report full_backing_filename

2015-12-18 Thread Kevin Wolf
From: John Snow Always report full_backing_filename, even if it's the same as backing_filename. In the next patch, full_backing_filename may be omitted if it cannot be generated instead of allowing e.g. drive_query to abort if it runs into this scenario. The presence or absence of the "full" fie

[Qemu-devel] [PULL 22/48] qemu-iotests: Try setting cache mode for children

2015-12-18 Thread Kevin Wolf
This is a basic test for specifying cache modes for child nodes on the command line. It doesn't take much time and works without O_DIRECT support. Signed-off-by: Kevin Wolf Reviewed-by: Max Reitz --- tests/qemu-iotests/051 | 10 +++- tests/qemu-iotests/051.out | 60 +

Re: [Qemu-devel] [PATCH 6/6] hw/arm/sysbus-fdt: enable amd-xgbe dynamic instantiation

2015-12-18 Thread Peter Maydell
On 17 December 2015 at 12:29, Eric Auger wrote: > This patch allows the instantiation of the vfio-amd-xgbe device > from the QEMU command line (-device vfio-amd-xgbe,host=""). > > The guest is exposed with a device tree node that combines the description > of both XGBE and PHY (representation supp

[Qemu-devel] [PULL 35/48] qcow2: insert assert into qcow2_get_specific_info()

2015-12-18 Thread Kevin Wolf
From: "Denis V. Lunev" s->qcow_version is always set to 2 or 3. Let's assert if this is wrong. Signed-off-by: Denis V. Lunev CC: Roman Kagan CC: Max Reitz CC: Kevin Wolf Reviewed-by: Eric Blake Signed-off-by: Kevin Wolf --- block/qcow2.c | 4 1 file changed, 4 insertions(+) diff --g

[Qemu-devel] [PULL 25/48] progress: Allow regressing progress

2015-12-18 Thread Kevin Wolf
From: Max Reitz Progress may regress; this should be displayed correctly by qemu_progress_print(). While touching that area of code, drop the redundant parentheses in the same condition. Signed-off-by: Max Reitz Reviewed-by: Eric Blake Reviewed-by: Stefan Hajnoczi Signed-off-by: Kevin Wolf

[Qemu-devel] [PULL 04/48] qcow2: Add .bdrv_join_options callback

2015-12-18 Thread Kevin Wolf
qcow2 accepts a few driver-specific options that overlap semantically (e.g. "overlap-check" is an alias of "overlap-check.template", and any missing cache size option is derived from the given ones). When bdrv_reopen() merges the set of updated options with left out options that should be kept at

[Qemu-devel] [PULL v1 5/5] crypto: add support for loading encrypted x509 keys

2015-12-18 Thread Daniel P. Berrange
Make use of the QCryptoSecret object to support loading of encrypted x509 keys. The optional 'passwordid' parameter to the tls-creds-x509 object type, provides the ID of a secret object instance that holds the decryption password for the PEM file. # printf "123456" > mypasswd.txt # $QEMU \ -

Re: [Qemu-devel] [RFC PATCH 0/2] Add GIC ITS description in ACPI MADT table

2015-12-18 Thread Peter Maydell
On 29 November 2015 at 08:22, Shannon Zhao wrote: > From: Shannon Zhao > > These two patches add ITS description in ACPI MADT table. It bases on > Pavel Fedin's ITS series[1]. > > [1]https://www.mail-archive.com/qemu-devel@nongnu.org/msg337421.html > > Shannon Zhao (2): > ACPI: Add GIC Interrup

[Qemu-devel] [PULL v1 4/5] crypto: add QCryptoSecret object class for password/key handling

2015-12-18 Thread Daniel P. Berrange
Introduce a new QCryptoSecret object class which will be used for providing passwords and keys to other objects which need sensitive credentials. The new object can provide secret values directly as properties, or indirectly via a file. The latter includes support for file descriptor passing synta

[Qemu-devel] [PULL v1 3/5] qga: convert to use error checked base64 decode

2015-12-18 Thread Daniel P. Berrange
Switch from using g_base64_decode over to qbase64_decode in order to get error checking of the base64 input data. Reviewed-by: Eric Blake Signed-off-by: Daniel P. Berrange --- qga/commands-posix.c | 11 +-- qga/commands-win32.c | 11 +-- qga/commands.c | 13 -

[Qemu-devel] [PATCH 1/2] qom: add object_class_get_instance_size()

2015-12-18 Thread Igor Mammedov
it will be used for allocating memory for a to be created new object in safe manner. Signed-off-by: Igor Mammedov --- include/qom/object.h | 8 qom/object.c | 5 + 2 files changed, 13 insertions(+) diff --git a/include/qom/object.h b/include/qom/object.h index 4509166..8f61

[Qemu-devel] [PULL 1/2] xen/blkif: Avoid double access to src->nr_segments

2015-12-18 Thread Stefano Stabellini
src is stored in shared memory and src->nr_segments is dereferenced twice at the end of the function. If a compiler decides to compile this into two separate memory accesses then the size limitation could be bypassed. Fix it by removing the double access to src->nr_segments. This is part of XSA-

Re: [Qemu-devel] [PATCH] fix MSI injection on Xen

2015-12-18 Thread Stefano Stabellini
On Wed, 2 Dec 2015, Michael S. Tsirkin wrote: > On Wed, Dec 02, 2015 at 05:16:18PM +, Stefano Stabellini wrote: > > On Wed, 2 Dec 2015, Michael S. Tsirkin wrote: > > > On Wed, Dec 02, 2015 at 04:56:21PM +, Stefano Stabellini wrote: > > > > On Xen MSIs can be remapped into pirqs, which are a

[Qemu-devel] [PULL v1 2/5] qemu-char: convert to use error checked base64 decode

2015-12-18 Thread Daniel P. Berrange
Switch from using g_base64_decode over to qbase64_decode in order to get error checking of the base64 input data. Reviewed-by: Eric Blake Signed-off-by: Daniel P. Berrange --- qapi-schema.json | 2 -- qemu-char.c | 8 +++- qmp-commands.hx | 2 -- 3 files changed, 7 insertions(+), 5 de

[Qemu-devel] [PULL v1 1/5] util: add base64 decoding function

2015-12-18 Thread Daniel P. Berrange
The standard glib provided g_base64_decode doesn't provide any kind of sensible error checking on its input. Add a QEMU custom wrapper qbase64_decode which can be used with untrustworthy input that can contain invalid base64 characters, embedded NUL characters, or not be NUL terminated at all. Rev

[Qemu-devel] [PULL 27/48] qcow2: Use error_report() in qcow2_amend_options()

2015-12-18 Thread Kevin Wolf
From: Max Reitz Signed-off-by: Max Reitz Reviewed-by: Eric Blake Reviewed-by: Alberto Garcia Signed-off-by: Kevin Wolf --- block/qcow2.c | 14 ++ tests/qemu-iotests/061.out | 14 +++--- 2 files changed, 13 insertions(+), 15 deletions(-) diff --git a/block/qc

[Qemu-devel] [PULL 11/48] block: Keep "driver" in bs->options

2015-12-18 Thread Kevin Wolf
Instead of passing a separate drv argument to bdrv_open_common(), just make sure that a "driver" option is set in the QDict. This also means that a "driver" entry is consistently present in bs->options now. This is another step towards keeping all options in the QDict (which is the represenation o

[Qemu-devel] [PULL 2/2] xenfb: avoid reading twice the same fields from the shared page

2015-12-18 Thread Stefano Stabellini
Reading twice the same field could give the guest an attack of opportunity. In the case of event->type, gcc could compile the switch statement into a jump table, effectively ending up reading the type field multiple times. This is part of XSA-155. Signed-off-by: Stefano Stabellini --- hw/displa

Re: [Qemu-devel] [PATCH] linux-user, sh4: fix signal retcode address

2015-12-18 Thread Laurent Vivier
Ping ? Le 23/11/2015 11:38, Laurent Vivier a écrit : > To return from a signal, setup_frame() puts an instruction to > be executed in the stack. This sequence calls the syscall sigreturn(). > > The address of the instruction must be set in the PR register > to be executed. > > This patch fixes t

[Qemu-devel] [PULL 13/48] block: reopen: Document option precedence and refactor accordingly

2015-12-18 Thread Kevin Wolf
The interesting part of reopening an image is from which sources the effective options should be taken, i.e. which options take precedence over which other options. This patch documents the precedence that will be implemented in the following patches. It also refactors bdrv_reopen_queue(), so that

[Qemu-devel] [PULL 07/48] block: Allow references for backing files

2015-12-18 Thread Kevin Wolf
For bs->file, using references to existing BDSes has been possible for a while already. This patch enables the same for bs->backing. Signed-off-by: Kevin Wolf Reviewed-by: Max Reitz --- block.c | 48 +--- block/mirror.c| 2 +- i

[Qemu-devel] [PULL 36/48] raw-posix: Make aio=native option binding

2015-12-18 Thread Kevin Wolf
Traditionally, aio=native was treated as an advice that could simply be ignored if an error occurs while initialising Linux AIO or the feature wasn't compiled in. This behaviour was deprecated in commit 96518254 (qemu 2.3; error during init) and commit 1501ecc1 (qemu 2.5; not compiled in). This pa

[Qemu-devel] [PATCH v3 11/24] error: Use error_reportf_err() where it makes obvious sense

2015-12-18 Thread Markus Armbruster
Done with this Coccinelle semantic patch @@ expression FMT, E, S; expression list ARGS; @@ -error_report(FMT, ARGS, error_get_pretty(E)); +error_reportf_err(E, FMT/*@@@*/, ARGS); ( -error_free(E); | exit(S); | abort(); ) fo

Re: [Qemu-devel] [PATCH] scripts: provide a script for checking glib symbol usage

2015-12-18 Thread Daniel P. Berrange
On Fri, Dec 18, 2015 at 01:43:19PM +, Peter Maydell wrote: > On 18 December 2015 at 13:41, Paolo Bonzini wrote: > > > > > > On 18/12/2015 14:35, Dr. David Alan Gilbert wrote: > >> > That would not be recursive make, but rather a completely separate > >> > Makefile to be manually invoked with -

[Qemu-devel] [PATCH v3 21/24] error: Clean up errors with embedded newlines (again)

2015-12-18 Thread Markus Armbruster
The arguments of error_report() should yield a short error string without newlines. A few places try to print additional help after the error message by embedding newlines in the error string. That's nice, but let's do it the right way. Commit 474c213 cleaned up some, but they keep coming back.

Re: [Qemu-devel] [PATCH COLO-Frame v12 21/38] COLO failover: Introduce a new command to trigger a failover

2015-12-18 Thread Dr. David Alan Gilbert
* zhanghailiang (zhang.zhanghaili...@huawei.com) wrote: > We leave users to choose whatever heartbeat solution they want, if the > heartbeat > is lost, or other errors they detect, they can use experimental command > 'x_colo_lost_heartbeat' to tell COLO to do failover, COLO will do operations > ac

Re: [Qemu-devel] [PATCH 5/6] hw/arm/sysbus-fdt: helpers for clock node generation

2015-12-18 Thread Peter Maydell
On 17 December 2015 at 12:29, Eric Auger wrote: > Some passthrough'ed devices depend on clock nodes. Those need to be > generated in the guest device tree. This patch introduces some helpers > to build a clock node from information retrieved in the host device tree. > > - inherit_properties copies

  1   2   3   >