Re: [Qemu-devel] [PATCH v2 0/2] HMP: support specifying dump format for dump-guest-memory

2014-04-23 Thread Markus Armbruster
qiaonuohan writes: > On 04/23/2014 09:30 PM, Luiz Capitulino wrote: >> On Wed, 23 Apr 2014 12:38:12 +0200 >> Christian Borntraeger wrote: >> >>> On 17/04/14 10:15, Qiao Nuohan wrote: The last version is here: http://lists.nongnu.org/archive/html/qemu-devel/2014-04/msg00018.html >>

Re: [Qemu-devel] [GSoC] Wanted: small warmup tasks

2014-04-23 Thread Peter Crosthwaite
On Thu, Apr 24, 2014 at 4:45 PM, Peter Crosthwaite wrote: > Hi Jan, > > IDEA1: > > "Convert existing device models to use FIFO API" is one. FIFO API is a > factored out circular buffer helper that avoids having all the head > and tail pointer arithmetic in every device model. > > Check util/fifo.c

Re: [Qemu-devel] [GSoC] Wanted: small warmup tasks

2014-04-23 Thread Peter Crosthwaite
Hi Jan, IDEA1: "Convert existing device models to use FIFO API" is one. FIFO API is a factored out circular buffer helper that avoids having all the head and tail pointer arithmetic in every device model. Check util/fifo.c git grep -i fifo hw will hit candidate device models. The biggest obst

Re: [Qemu-devel] [PATCH 1/3] virtio: Introduce VirtIODevice.broken

2014-04-23 Thread Michael S. Tsirkin
On Thu, Apr 24, 2014 at 11:19:14AM +0800, Fam Zheng wrote: > On Wed, 04/23 10:17, Michael S. Tsirkin wrote: > > On Tue, Apr 22, 2014 at 04:55:15PM +0800, Fam Zheng wrote: > > > If guest driver behaves abnormally, emulation code could mark the device > > > as "broken". > > > > > > Once "broken" is

Re: [Qemu-devel] [GSoC] Wanted: small warmup tasks

2014-04-23 Thread Marc Marí
I was waiting to chat with my mentors, but I wanted to ask the same thing. So, if you have any, I'm also interested. Marc 2014-04-24 8:19 GMT+02:00 Jan Kiszka : > On 2014-04-23 11:25, Stefan Hajnoczi wrote: > > Dear QEMU, Libvirt, and KVM communities, > > We are participating in Google Summer o

Re: [Qemu-devel] [PATCH] ps2: set ps/2 output buffer size as the same as kernel

2014-04-23 Thread Gerd Hoffmann
> @@ -137,7 +139,7 @@ void ps2_queue(void *opaque, int b) > PS2State *s = (PS2State *)opaque; > PS2Queue *q = &s->queue; > > -if (q->count >= PS2_QUEUE_SIZE) > +if (q->count >= PS2_QUEUE_SIZE - 1) Why? > if (!(s->mouse_status & MOUSE_STATUS_REMOTE) && > -(s->commo

[Qemu-devel] [GSoC] Wanted: small warmup tasks

2014-04-23 Thread Jan Kiszka
On 2014-04-23 11:25, Stefan Hajnoczi wrote: > Dear QEMU, Libvirt, and KVM communities, > We are participating in Google Summer of Code 2014 > (http://google-melange.com/) and Outreach Program for Women > (http://opw.gnome.org/). Both programs fund candidates to work on our > open source projects f

Re: [Qemu-devel] [PATCH 1/3] virtio: Introduce VirtIODevice.broken

2014-04-23 Thread Fam Zheng
On Wed, 04/23 10:17, Michael S. Tsirkin wrote: > On Tue, Apr 22, 2014 at 04:55:15PM +0800, Fam Zheng wrote: > > If guest driver behaves abnormally, emulation code could mark the device > > as "broken". > > > > Once "broken" is set, device emulation will typically wait for a reset > > command and i

[Qemu-devel] [PATCH] ps2: set ps/2 output buffer size as the same as kernel

2014-04-23 Thread arei.gonglei
From: Gonglei According to the PS/2 Mouse/Keyboard Protocol, the keyboard outupt buffer size is 16 bytes. And the PS2_QUEUE_SIZE 256 was introduced in Qemu from the very beginning. When I started a redhat5.6 32bit guest, meanwhile tapped the keyboard as quickly as possible, the screen would sh

Re: [Qemu-devel] [PATCH] block: Expose host_* drivers in blockdev-add

2014-04-23 Thread Fam Zheng
On Wed, 04/23 17:12, Kevin Wolf wrote: > All the functionality to use the host_device, host_cdrom and host_floppy > drivers is already there, they just need to be added to the schema. > > Signed-off-by: Kevin Wolf > --- > qapi-schema.json | 6 +- > 1 file changed, 5 insertions(+), 1 deletion

Re: [Qemu-devel] [PATCH v2 0/2] HMP: support specifying dump format for dump-guest-memory

2014-04-23 Thread qiaonuohan
On 04/23/2014 09:30 PM, Luiz Capitulino wrote: On Wed, 23 Apr 2014 12:38:12 +0200 Christian Borntraeger wrote: On 17/04/14 10:15, Qiao Nuohan wrote: The last version is here: http://lists.nongnu.org/archive/html/qemu-devel/2014-04/msg00018.html ChangLog: Changes from v7 to v8: 1. add a patc

Re: [Qemu-devel] [PATCH RFC] ps2: set the keybord output buffer size as the same as kernel

2014-04-23 Thread Gonglei (Arei)
Hi, > Subject: Re: [PATCH RFC] ps2: set the keybord output buffer size as the same > as > > > So do you agree with my method to address the issue? > > Using a temporary buffer is fine, simple and save choice. For the > second copy you can use a simple memcpy instead of the loop. > Okay, I wil

Re: [Qemu-devel] [RFC 2/4] Add EXEC_FLAG to VFIO DMA mappings

2014-04-23 Thread Peter Crosthwaite
On Fri, Apr 18, 2014 at 3:29 AM, Alvise Rigo wrote: > The flag is mandatory for the ARM SMMU, add it. > When VFIO will be able to tell about the IOMMU being used, we will add > it only if necessary. > > Signed-off-by: Alvise Rigo > --- > hw/vfio/common.c | 3 +++ > linux-headers/linux/

Re: [Qemu-devel] [RFC 0/4] AMBA platform device passthrough

2014-04-23 Thread Peter Crosthwaite
On Thu, Apr 24, 2014 at 1:21 AM, Eric Auger wrote: > On 04/17/2014 07:29 PM, Alvise Rigo wrote: >> These patches were born after trying the current work on device >> passthrough (see thread "[Qemu-devel] [RFC v2 0/6] KVM platform device >> passthrough") with a DMA330 and FastModels. This work wan

Re: [Qemu-devel] [PATCH v4 0/4] Generalise FIFO to more integer types

2014-04-23 Thread Peter Crosthwaite
Ping! On Thu, Apr 17, 2014 at 5:58 PM, Peter Maydell wrote: > On 17 April 2014 04:06, Peter Crosthwaite > wrote: >> Hi Peter, >> >> On Tue, Apr 15, 2014 at 1:17 PM, Peter Crosthwaite >>> Peter Crosthwaite (4): >>> util/fifo: Generalise naming scheme >>> util/fifo: Generalise for common inte

Re: [Qemu-devel] [PATCH v4 0/6] Data Driven device registers + Zynq DEVCFG

2014-04-23 Thread Peter Crosthwaite
Ping! On Wed, Apr 9, 2014 at 5:15 PM, Peter Crosthwaite wrote: > Hi All. This is a new scheme i've come up with handling device registers in a > data driven way. My motivation for this is to factor out a lot of the access > checking that seems to be replicated in every device. See P2 commit messa

Re: [Qemu-devel] [PATCH for-2.1 v1 0/3] Named GPIOs

2014-04-23 Thread Peter Crosthwaite
Ping! On Wed, Apr 9, 2014 at 9:44 AM, Peter Crosthwaite wrote: > This series implements Named GPIOs on the qdev level. Patch 2 is the > feature presentation. > > First patch is a developer-centric patch I have had in my tree for a > while. I include it so it picks up the change pattern in P2. > >

[Qemu-devel] [PATCH v2 2/2] ohw: let the right reset entry point 0xfff00100 jump to the currently wrong entry point (0xfffffffc)

2014-04-23 Thread Hervé Poussineau
This is easier to do this than to copy the code from the wrong entry point to the right entry point. Suggested-by: Alexander Graf Signed-off-by: Hervé Poussineau --- src/vectors.S |4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/vectors.S b/src/vectors.S index 691d

[Qemu-devel] [PATCH v3 07/12] target-i386: Filter KVM and 0xC0000001 features on TCG

2014-04-23 Thread Eduardo Habkost
TCG doesn't support any of the feature flags on FEAT_KVM and FEAT_C000_0001_EDX feature words, so clear all bits on those feature words. Reviewed-by: Richard Henderson Signed-off-by: Eduardo Habkost --- Changes v1 -> v2: * Trivial rebase to latest qom-cpu (commit 90c5d39c) (Reviewed-by line

Re: [Qemu-devel] [PATCH v3 00/12] target-i386: Support check/enforce flags & -cpu host in TCG mode, too

2014-04-23 Thread Eduardo Habkost
On Wed, Apr 23, 2014 at 05:29:28PM -0300, Eduardo Habkost wrote: > This removes some duplication in the CPU feature checking and filtering code > in > cpu.c, and as a nice side-effect, will make the "check" and "enforce" flags > work > in TCG mode too. The series description was supposed to ment

[Qemu-devel] [PATCH v2 1/2] ohw: correctly program BAR addresses of PCI devices

2014-04-23 Thread Hervé Poussineau
Note that offsets are PReP ones, so this breaks compatibility with hardware which has different values. Signed-off-by: Hervé Poussineau --- Indentation may look strange, but I tried to stay consistent with other parts of the file. src/pci.c |7 ++- 1 file changed, 6 insertions(+), 1

[Qemu-devel] [PATCH v3 06/12] target-i386: Filter FEAT_7_0_EBX TCG features too

2014-04-23 Thread Eduardo Habkost
The TCG_7_0_EBX_FEATURES macro was defined but never used (it even had a typo that was never noticed). Make the existing TCG feature filtering code use it. Change the TCG feature flag filtering code to use it. Reviewed-by: Richard Henderson Signed-off-by: Eduardo Habkost --- Changes v1 -> v2:

[Qemu-devel] [PATCH v2 0/2] prep: Remove some clearly wrong assumptions

2014-04-23 Thread Hervé Poussineau
Hi, These two patches remove some bugs for a PReP firmware. Note that first patch is very PReP-oriented, and breaks OHW compatibility with other QEMU emulations (oldworld and newworld machines). Patches to remove corresponding hacks on QEMU side have already been sent: http://lists.gnu.org/archi

[Qemu-devel] [PATCH v3 03/12] target-i386: Pass FeatureWord argument to report_unavailable_features()

2014-04-23 Thread Eduardo Habkost
This will help us simplify the code that calls report_unavailable_features() later. Signed-off-by: Eduardo Habkost --- Changes v1 -> v2: * Rebase to latest qom-cpu (commit 90c5d39c) Changes v2 -> v3: * Trivial rebase after QEMU 2.0 (onto commit 2d03b49) --- target-i386/cpu.c | 5 +++-- 1 file

[Qemu-devel] [PATCH v3 00/12] target-i386: Support check/enforce flags & -cpu host in TCG mode, too

2014-04-23 Thread Eduardo Habkost
This removes some duplication in the CPU feature checking and filtering code in cpu.c, and as a nice side-effect, will make the "check" and "enforce" flags work in TCG mode too. Changes v2 -> v3: * Rebase after QEMU v2.0.0 (onto commit 2d03b49) * Added new patch: target-i386: support "invariant

[Qemu-devel] [PATCH v3 05/12] target-i386: Make TCG feature filtering more readable

2014-04-23 Thread Eduardo Habkost
Instead of an #ifdef in the middle of the code, just set TCG_EXT2_FEATURES to a different value depending on TARGET_X86_64. Reviewed-by: Richard Henderson Signed-off-by: Eduardo Habkost --- Changes v1 -> v2: * Trivial rebase to latest qom-cpu (commit 90c5d39c) (Reviewed-by line kept) Changes

[Qemu-devel] target-i386: block migration and savevm if invariant tsc is exposed (v3)

2014-04-23 Thread Marcelo Tosatti
Invariant TSC documentation mentions that "invariant TSC will run at a constant rate in all ACPI P-, C-. and T-states". This is not the case if migration to a host with different TSC frequency is allowed, or if savevm is performed. So block migration/savevm. Signed-off-by: Marcelo Tosatti Ind

[Qemu-devel] [PATCH v3 08/12] target-i386: Define TCG_*_FEATURES earlier on cpu.c

2014-04-23 Thread Eduardo Habkost
Those macros will be used in the feature_word_info array data, so need to be defined earlier. Signed-off-by: Eduardo Habkost --- Changes v1 -> v2: * Rebase to latest qom-cpu (commit 90c5d39c) Changes v2 -> v3: * Trivial rebase after QEMU 2.0 (onto commit 2d03b49) --- target-i386/cpu.c | 117 ++

[Qemu-devel] [PATCH v3 11/12] target-i386: support "invariant tsc" flag

2014-04-23 Thread Eduardo Habkost
From: Marcelo Tosatti Expose "Invariant TSC" flag, if KVM is enabled. From Intel documentation: 17.13.1 Invariant TSC The time stamp counter in newer processors may support an enhancement, referred to as invariant TSC. Processor’s support for invariant TSC is indicated by CPUID.8007H:EDX[8].

[Qemu-devel] [PATCH v3 09/12] target-i386: Loop-based feature word filtering in TCG mode

2014-04-23 Thread Eduardo Habkost
Instead of manually filtering each feature word, add a tcg_features field to FeatureWordInfo, and use that field to filter all feature words in TCG mode. Reviewed-by: Richard Henderson Signed-off-by: Eduardo Habkost --- Changes v1 -> v2: * Trivial rebase to latest qom-cpu (commit 90c5d39c) (

[Qemu-devel] [PATCH v3 12/12] target-i386: Support "-cpu host" in TCG mode

2014-04-23 Thread Eduardo Habkost
As "-cpu host" simply means "enable every bit that can be enabled on this host", we can emulate similar behavior even if KVM is not enabled. We just need to set all feature bits supported by TCG, accordingly. Signed-off-by: Eduardo Habkost --- target-i386/cpu.c | 32 ++---

[Qemu-devel] [PATCH v3 10/12] target-i386: Support check/enforce flags in TCG mode, too

2014-04-23 Thread Eduardo Habkost
If enforce/check is specified in TCG mode, QEMU will ensure all CPU features are supported by TCG, so no CPU feature is silently disabled. Reviewed-by: Richard Henderson Signed-off-by: Eduardo Habkost --- Changes v1 -> v2: * Trivial rebase to latest qom-cpu (commit 90c5d39c) (Reviewed-by lin

[Qemu-devel] [PATCH v3 02/12] target-i386: Merge feature filtering/checking functions

2014-04-23 Thread Eduardo Habkost
Merge filter_features_for_kvm() and kvm_check_features_against_host(). Both functions made exactly the same calculations, the only difference was that filter_features_for_kvm() changed the bits on cpu->features[], and kvm_check_features_against_host() did error reporting. Reviewed-by: Richard Hen

[Qemu-devel] Cannot boot my VM image after switching to ahci.

2014-04-23 Thread Alex Davis
I currently run my QEMU VM using the following command: /spare/qemu-1.7.1/bin/qemu-system-x86_64 -soundhw ac97 -sdl -vga std -net nic,macaddr=de:ad:be:ef:89:32 -net user -m 2048 -enable-kvm -drive file="$1",media=disk,if=ide,index=0 -drive file=/dev/sr0,media=cdrom,if=ide,index=1 -boot c -smp 2

[Qemu-devel] [PATCH v3 01/12] target-i386: Simplify reporting of unavailable features

2014-04-23 Thread Eduardo Habkost
Instead of checking and calling unavailable_host_feature() once for each bit, simply call the function (now renamed to report_unavailable_features()) once for each feature word. Signed-off-by: Eduardo Habkost --- Changes v1 -> v2: * Rebase to latest qom-cpu (commit 90c5d39c) Changes v2 -> v3: *

[Qemu-devel] [PATCH v3 04/12] target-i386: Isolate KVM-specific code on CPU feature filtering logic

2014-04-23 Thread Eduardo Habkost
This will allow us to re-use the feature filtering logic (and the check/enforce flag logic) for TCG. Reviewed-by: Richard Henderson Signed-off-by: Eduardo Habkost --- Changes v1 -> v2: * Trivial rebase to latest qom-cpu (commit 90c5d39c) (Reviewed-by line kept) Changes v2 -> v3: * Trivial r

Re: [Qemu-devel] [Bug 1288620] Re: memory leak with default NIC model

2014-04-23 Thread Aidan Gauland
On Wed, 23 Apr 2014 13:10:39 -, Stefan Hajnoczi wrote: > So this is a problem that only happens under Valgrind? Perhaps this > is > a valgrind bug. No, it happens outside of Valgrind as well. It only happens when QEMU is told to read a config file (with -readconfig). -- You received this

Re: [Qemu-devel] [patch 2/2] target-i386: block migration and savevm if invariant tsc is exposed

2014-04-23 Thread Eduardo Habkost
On Wed, Apr 23, 2014 at 03:20:04PM -0300, Marcelo Tosatti wrote: > Invariant TSC documentation mentions that "invariant TSC will run at a > constant rate in all ACPI P-, C-. and T-states". > > This is not the case if migration to a host with different TSC frequency > is allowed, or if savevm is p

[Qemu-devel] [SeaBIOS v4 PATCH] SMBIOS: Check for aggregate tables & entry point in fw_cfg

2014-04-23 Thread Gabriel L. Somlo
Check fw_cfg for the presence of an aggregate set of smbios tables (etc/smbios/smbios-tables) and an entry point structure (etc/smbios/smbios-anchor), and, if found, use them instead of generating entries locally. We ensure the presence of a type 0 (bios information) structure by generating it loc

Re: [Qemu-devel] [patch 1/2] target-i386: support "invariant tsc" flag

2014-04-23 Thread Eduardo Habkost
On Wed, Apr 23, 2014 at 03:20:03PM -0300, Marcelo Tosatti wrote: > Expose "Invariant TSC" flag, if KVM is enabled. From Intel documentation: > > 17.13.1 Invariant TSC The time stamp counter in newer processors may > support an enhancement, referred to as invariant TSC. Processor’s > support for in

Re: [Qemu-devel] [RFC PATCH v2 00/16] visitor+BER migration format

2014-04-23 Thread Eric Blake
On 04/23/2014 11:54 AM, Michael S. Tsirkin wrote: > On Wed, Apr 23, 2014 at 11:47:21AM -0600, Eric Blake wrote: >> On 04/23/2014 11:16 AM, Dr. David Alan Gilbert wrote: >>> The one thing that the environment variable does make nice and easy, >>> for dev, is using it with existing test setups - e.g.

[Qemu-devel] [patch 2/2] target-i386: block migration and savevm if invariant tsc is exposed

2014-04-23 Thread Marcelo Tosatti
Invariant TSC documentation mentions that "invariant TSC will run at a constant rate in all ACPI P-, C-. and T-states". This is not the case if migration to a host with different TSC frequency is allowed, or if savevm is performed. So block migration/savevm. Also do not expose invariant tsc flag

[Qemu-devel] [patch 0/2] expose invariant tsc flag for kvm guests (v2)

2014-04-23 Thread Marcelo Tosatti
v2: - filter for TCG at cpu realizefn. - allow invariant tsc by default with "-cpu host". - fix initialization with multiple vcpus.

[Qemu-devel] [patch 1/2] target-i386: support "invariant tsc" flag

2014-04-23 Thread Marcelo Tosatti
Expose "Invariant TSC" flag, if KVM is enabled. From Intel documentation: 17.13.1 Invariant TSC The time stamp counter in newer processors may support an enhancement, referred to as invariant TSC. Processor’s support for invariant TSC is indicated by CPUID.8007H:EDX[8]. The invariant TSC wil

Re: [Qemu-devel] [PATCH] linux-user: avoid using glibc internals

2014-04-23 Thread Peter Maydell
On 23 April 2014 15:59, Natanael Copa wrote: > Avoid using glibc specific internals. > > Calculate the sigevent pad size is calculated in similar way as kernel > does it. > > This is needed for building with musl libc. Thanks for this patch -- is this the only fix that was needed, or are there mo

Re: [Qemu-devel] [RFC PATCH v2 00/16] visitor+BER migration format

2014-04-23 Thread Michael S. Tsirkin
On Wed, Apr 23, 2014 at 11:47:21AM -0600, Eric Blake wrote: > On 04/23/2014 11:16 AM, Dr. David Alan Gilbert wrote: > > The one thing that the environment variable does make nice and easy, > > for dev, is using it with existing test setups - e.g. running virt-test > > in BER mode or existing mode.

Re: [Qemu-devel] [RFC PATCH v2 00/16] visitor+BER migration format

2014-04-23 Thread Eric Blake
On 04/23/2014 11:16 AM, Dr. David Alan Gilbert wrote: > The one thing that the environment variable does make nice and easy, > for dev, is using it with existing test setups - e.g. running virt-test > in BER mode or existing mode. Hmm. Maybe a compromise - an environment variable determines the de

[Qemu-devel] [RFC PATCH v2 11/16] BER Visitor: Create output visitor

2014-04-23 Thread Dr. David Alan Gilbert (git)
From: "Dr. David Alan Gilbert" Signed-off-by: Dr. David Alan Gilbert --- include/qapi/ber.h | 117 +++ include/qapi/qemu-file-ber-output-visitor.h | 26 + qapi/Makefile.objs |1 + qapi/qemu-file-ber-output-visitor.c | 1067 +++

Re: [Qemu-devel] [RFC PATCH v2 00/16] visitor+BER migration format

2014-04-23 Thread Michael S. Tsirkin
On Wed, Apr 23, 2014 at 06:16:23PM +0100, Dr. David Alan Gilbert wrote: > * Eric Blake (ebl...@redhat.com) wrote: > > On 04/23/2014 10:37 AM, Dr. David Alan Gilbert (git) wrote: > > > From: "Dr. David Alan Gilbert" > > > > > > > >4) At the moment you select BER output format by setting an en

[Qemu-devel] [RFC PATCH v2 15/16] Wire in BER visitors

2014-04-23 Thread Dr. David Alan Gilbert (git)
From: "Dr. David Alan Gilbert" BER output visitor to be selected with env BER input visitor recognized by file header Signed-off-by: Dr. David Alan Gilbert --- include/migration/migration.h | 2 + savevm.c | 105 +++--- 2 files changed

[Qemu-devel] [RFC PATCH v2 05/16] Header/constant/types fixes for visitors

2014-04-23 Thread Dr. David Alan Gilbert (git)
From: "Dr. David Alan Gilbert" Move constants around and add types to allow file structure to move into visitors. Signed-off-by: Dr. David Alan Gilbert --- arch_init.c | 12 include/migration/migration.h | 17 + include/migration/vmstate.h | 20

[Qemu-devel] [RFC PATCH v2 01/16] Visitor: Add methods for migration format use

2014-04-23 Thread Dr. David Alan Gilbert (git)
From: "Dr. David Alan Gilbert" array types From https://lists.gnu.org/archive/html/qemu-devel/2011-09/msg02465.html str256 type For the upto 256byte strings QEMU commonly uses for IDs buffer type For a blob of data that the caller wants to deliver whole (e.g. a page of RAM or b

Re: [Qemu-devel] [RFC PATCH v2 00/16] visitor+BER migration format

2014-04-23 Thread Dr. David Alan Gilbert
* Eric Blake (ebl...@redhat.com) wrote: > On 04/23/2014 10:37 AM, Dr. David Alan Gilbert (git) wrote: > > From: "Dr. David Alan Gilbert" > > > > >4) At the moment you select BER output format by setting an environment > > variable ( export QEMUMIGFORMAT=BER ) , I need to put more thoug

[Qemu-devel] [RFC PATCH v2 07/16] Visitor: Binary compatible input visitor

2014-04-23 Thread Dr. David Alan Gilbert (git)
From: "Dr. David Alan Gilbert" based on Michael Roth's https://lists.gnu.org/archive/html/qemu-devel/2011-09/msg02470.html Signed-off-by: Dr. David Alan Gilbert --- include/qapi/qemu-file-binary-input-visitor.h | 27 + qapi/Makefile.objs| 2 +- qapi/qemu-file-bin

[Qemu-devel] [RFC PATCH v2 03/16] QEMUFilePart: A shim to read part of a file

2014-04-23 Thread Dr. David Alan Gilbert (git)
From: "Dr. David Alan Gilbert" QEMUFilePart takes a backing QEMUFile and a length, and exposes only 'length' bytes from the backing QEMUFile. Signed-off-by: Dr. David Alan Gilbert --- include/migration/qemu-file.h | 2 ++ qemu-file.c | 73

[Qemu-devel] Monitor Readline - no terminal echo after exit

2014-04-23 Thread Mike Day
I believe someone on the list mentioned they are seeing a couple problems entering and exiting the Monitor. I'd like to look at this more closely, starting with my most pending issue: losing the terminal echo after exiting the Monitor. Does anyone have a quick pointer as to where I should look fo

[Qemu-devel] [RFC PATCH v2 02/16] QEMUSizedBuffer/QEMUFile

2014-04-23 Thread Dr. David Alan Gilbert (git)
From: "Dr. David Alan Gilbert" Stefan Berger's to create a QEMUFile that goes to a memory buffer; from: http://lists.gnu.org/archive/html/qemu-devel/2013-03/msg05036.html Using the QEMUFile interface, this patch adds support functions for operating on in-memory sized buffers that can be written

[Qemu-devel] [RFC PATCH v2 00/16] visitor+BER migration format

2014-04-23 Thread Dr. David Alan Gilbert (git)
From: "Dr. David Alan Gilbert" This is the 2nd version of my work-in-progress cut of my visitor+BER format migration world; there's lots to do but it's starting to get there. I'd appreciate if anyone who has more experience with either the visitor code, or ASN.1/BER in general has a look to see i

Re: [Qemu-devel] [RFC PATCH v2 00/16] visitor+BER migration format

2014-04-23 Thread Eric Blake
On 04/23/2014 10:37 AM, Dr. David Alan Gilbert (git) wrote: > From: "Dr. David Alan Gilbert" > >4) At the moment you select BER output format by setting an environment > variable ( export QEMUMIGFORMAT=BER ) , I need to put more thought > in to the right way to do this, there are

[Qemu-devel] [RFC PATCH v2 04/16] qemu-file: Add set/get tmp_visitor

2014-04-23 Thread Dr. David Alan Gilbert (git)
From: "Dr. David Alan Gilbert" Signed-off-by: Dr. David Alan Gilbert --- include/migration/qemu-file.h | 4 qemu-file.c | 12 2 files changed, 16 insertions(+) diff --git a/include/migration/qemu-file.h b/include/migration/qemu-file.h index 88728c9..da99606

[Qemu-devel] [RFC PATCH v2 16/16] Add vmstate_cpu_common BER type code and wire it in.

2014-04-23 Thread Dr. David Alan Gilbert (git)
From: "Dr. David Alan Gilbert" Signed-off-by: Dr. David Alan Gilbert --- docs/specs/migration.schema | 8 +++- exec.c | 2 ++ include/qapi/ber.h | 1 + 3 files changed, 10 insertions(+), 1 deletion(-) diff --git a/docs/specs/migration.schema b/docs/specs/migra

[Qemu-devel] [RFC PATCH v2 13/16] Start some BER format docs

2014-04-23 Thread Dr. David Alan Gilbert (git)
From: "Dr. David Alan Gilbert" Add information on the QEMUFile/Visitor/VMState split Describe how to verify a BER stream against the schema Signed-off-by: Dr. David Alan Gilbert --- docs/migration.txt | 34 -- 1 file changed, 32 insertions(+), 2 deletions(-) di

[Qemu-devel] [RFC PATCH v2 10/16] Visitor: Common types to use visitors

2014-04-23 Thread Dr. David Alan Gilbert (git)
From: "Dr. David Alan Gilbert" Rework the common types in vmstate.c to use .visit rather than .get/.put and now call the correct visitor function. Signed-off-by: Dr. David Alan Gilbert --- vmstate.c | 376 -- 1 file changed, 73 insert

[Qemu-devel] [RFC PATCH v2 14/16] ASN.1 schema for new migration format

2014-04-23 Thread Dr. David Alan Gilbert (git)
From: "Dr. David Alan Gilbert" Signed-off-by: Dr. David Alan Gilbert --- docs/specs/migration.schema | 133 1 file changed, 133 insertions(+) create mode 100644 docs/specs/migration.schema diff --git a/docs/specs/migration.schema b/docs/specs/migra

[Qemu-devel] [RFC PATCH v2 12/16] BER Visitor: Create input visitor

2014-04-23 Thread Dr. David Alan Gilbert (git)
From: "Dr. David Alan Gilbert" Signed-off-by: Dr. David Alan Gilbert --- include/qapi/qemu-file-ber-input-visitor.h | 26 + qapi/Makefile.objs |2 +- qapi/qemu-file-ber-input-visitor.c | 1575 3 files changed, 1602 insertions(+)

[Qemu-devel] [RFC PATCH v2 08/16] Visitor: Output path

2014-04-23 Thread Dr. David Alan Gilbert (git)
From: "Dr. David Alan Gilbert" Replace QEMUFile by Visitor in most of the output path. There are still a few places that want a QEMUFile* and those are TODOs at the moment. Hacks in pci.c, spapr, spapr_vscsi.c for now where new visitor/qemufile boundaries have been added. Signed-off-by: Dr. Dav

[Qemu-devel] [RFC PATCH v2 06/16] Visitor: Binary compatible output visitor

2014-04-23 Thread Dr. David Alan Gilbert (git)
From: "Dr. David Alan Gilbert" Binary compatible output visitor to write to a QEMUFile in current migration format. This is based on Michael Roth's series : https://lists.gnu.org/archive/html/qemu-devel/2011-09/msg02466.html Signed-off-by: Dr. David Alan Gilbert --- include/qapi/qemu-file-bin

[Qemu-devel] [RFC PATCH v2 09/16] Visitor: Load path

2014-04-23 Thread Dr. David Alan Gilbert (git)
From: "Dr. David Alan Gilbert" Hacks in piix4.c, pci.c, spapr_vscsi.c for now Signed-off-by: Dr. David Alan Gilbert --- arch_init.c | 93 +++--- hw/acpi/piix4.c | 5 +- hw/pci/pci.c| 3 +- hw/scsi/spapr_vscsi.c |

Re: [Qemu-devel] [PATCH] block: Expose host_* drivers in blockdev-add

2014-04-23 Thread Eric Blake
On 04/23/2014 09:39 AM, Kevin Wolf wrote: > Am 23.04.2014 um 17:34 hat Eric Blake geschrieben: >> On 04/23/2014 09:12 AM, Kevin Wolf wrote: >>> All the functionality to use the host_device, host_cdrom and host_floppy >>> drivers is already there, they just need to be added to the schema. >>> >>> Si

Re: [Qemu-devel] where can I find the latest memory hot plugging patch for Qemu?

2014-04-23 Thread Igor Mammedov
On Wed, 23 Apr 2014 12:16:30 + "Kolk, G. van der" wrote: > Dear Qemu developers, > > I'm doing a masters thesis project which involves Qemu. Especially cpu and > memory hot plugging. But I have a hard time finding the right git repository > which contains the latest memory hot plugging wo

Re: [Qemu-devel] [PATCH] block: Expose host_* drivers in blockdev-add

2014-04-23 Thread Kevin Wolf
Am 23.04.2014 um 17:34 hat Eric Blake geschrieben: > On 04/23/2014 09:12 AM, Kevin Wolf wrote: > > All the functionality to use the host_device, host_cdrom and host_floppy > > drivers is already there, they just need to be added to the schema. > > > > Signed-off-by: Kevin Wolf > > --- > > qapi-s

[Qemu-devel] [PATCH] linux-user: avoid using glibc internals

2014-04-23 Thread Natanael Copa
Avoid using glibc specific internals. Calculate the sigevent pad size is calculated in similar way as kernel does it. This is needed for building with musl libc. Signed-off-by: Natanael Copa --- linux-user/syscall.c | 2 +- linux-user/syscall_defs.h | 6 +- 2 files changed, 6 insertio

Re: [Qemu-devel] [PATCH] block: Expose host_* drivers in blockdev-add

2014-04-23 Thread Eric Blake
On 04/23/2014 09:12 AM, Kevin Wolf wrote: > All the functionality to use the host_device, host_cdrom and host_floppy > drivers is already there, they just need to be added to the schema. > > Signed-off-by: Kevin Wolf > --- > qapi-schema.json | 6 +- > 1 file changed, 5 insertions(+), 1 delet

[Qemu-devel] [PATCH] block: Expose host_* drivers in blockdev-add

2014-04-23 Thread Kevin Wolf
All the functionality to use the host_device, host_cdrom and host_floppy drivers is already there, they just need to be added to the schema. Signed-off-by: Kevin Wolf --- qapi-schema.json | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/qapi-schema.json b/qapi-schema.json

Re: [Qemu-devel] [RFC 0/4] AMBA platform device passthrough

2014-04-23 Thread Eric Auger
On 04/17/2014 07:29 PM, Alvise Rigo wrote: > These patches were born after trying the current work on device > passthrough (see thread "[Qemu-devel] [RFC v2 0/6] KVM platform device > passthrough") with a DMA330 and FastModels. This work want to be the > starting point for dicussion on some aspect

Re: [Qemu-devel] [QEMU v8 PATCH 0/7] SMBIOS: build full tables in QEMU

2014-04-23 Thread Gerd Hoffmann
Hi, > Sounds like a plan! BTW, would it make sense to have Kevin apply > this: http://www.seabios.org/pipermail/seabios/2014-April/007856.html > to SeaBIOS and then pull a new blob from there around the same > time (or before ?) this patch set is applied to QEMU ? Usual way to handle things is

Re: [Qemu-devel] 答复: [PULL 01/14] tcg: Fix warning (1 bit signed bitfield entry) and replace int by bool

2014-04-23 Thread Richard Henderson
On 04/22/2014 07:19 PM, lig.f...@cn.fujitsu.com wrote: >> > typedef struct TCGLabelQemuLdst { >> > -int is_ld:1;/* qemu_ld: 1, qemu_st: 0 */ >> > +bool is_ld:1; /* qemu_ld: true, qemu_st: false */ > As boot type now, specify 1 bit is unnecessary, Huh? Certainly it i

Re: [Qemu-devel] 答复: [PULL 06/14] tcg: Add TCGType parameter to tcg_target_const_match

2014-04-23 Thread Richard Henderson
On 04/22/2014 07:22 PM, lig.f...@cn.fujitsu.com wrote: >> > -static inline int tcg_target_const_match(tcg_target_long val, >> > +static inline int tcg_target_const_match(tcg_target_long val, TCGType >> > +type, > Why a line break here? > And also others below. There is no line break here. Your ma

Re: [Qemu-devel] [RFC 4/4] MemoryRegion with EOI callbacks for VFIO Platform devices

2014-04-23 Thread Eric Auger
Hi Alvise, Thank you for the patch. Indeed I am very interested in further discussing the vfio-platform integration with you. On 04/17/2014 07:29 PM, Alvise Rigo wrote: > The user can specify the location of the memory region (register) used > by the guest driver to clear the pending interrupt; i

Re: [Qemu-devel] [PATCH RFC] ps2: set the keybord output buffer size as the same as kernel

2014-04-23 Thread Gerd Hoffmann
Hi, > > Good catch, Juan, Thanks. It should use a temp data array to save the > > q->data[] value, > > Check out memmove(). Doesn't help if you have to move two chunks (wraparound case). cheers, Gerd

Re: [Qemu-devel] [PATCH RFC] ps2: set the keybord output buffer size as the same as kernel

2014-04-23 Thread Gerd Hoffmann
Hi, > So do you agree with my method to address the issue? Using a temporary buffer is fine, simple and save choice. For the second copy you can use a simple memcpy instead of the loop. cheers, Gerd

[Qemu-devel] seabios release?

2014-04-23 Thread Gerd Hoffmann
Hi, I think it's time to start planning the next seabios release. First, because a bunch of changes have piled up in master. And second, because of the smbios changes. They are a step forward in making seabios less dependent on qemu internals and I want have that in qemu soonish. So, how abo

Re: [Qemu-devel] [PATCH] configure: Change --enable-tpm to --disable-tpm

2014-04-23 Thread Stefan Berger
On 04/21/2014 10:38 PM, Paolo Bonzini wrote: Il 21/04/2014 19:09, Cole Robinson ha scritto: I don't see why tpm is disabled by default: it doesn't have any external dependencies, or change default behavior. Leaving it disabled is just going to cause it to bit rot. Enable it by default, and chan

Re: [Qemu-devel] [PATCH RFC] ps2: set the keybord output buffer size as the same as kernel

2014-04-23 Thread Gonglei (Arei)
> > Hi, > > > > Completely separate question: Have you figured what the root cause for > > > the bug is? > > > > > While wading through the code I've figured the queue size > > > isn't (directly) exposed to the guest. > > > The process correspond with the above linux kernel code, i8042_flush(

Re: [Qemu-devel] [PATCH RFC] ps2: set the keybord output buffer size as the same as kernel

2014-04-23 Thread Markus Armbruster
"Gonglei (Arei)" writes: >> >> "Gonglei (Arei)" wrote: >> >> Hi, >> >> >> >> > Anything bigger than 16bytes, no? And that is the whole point that we >> >> > are talking about? Or the 16bytes that we are using can be at any place >> >> > on the buffer? >> >> >> >> Yes. It's a ring buffer, w

Re: [Qemu-devel] Who signed gemu-1.7.1.tar.bz2?

2014-04-23 Thread Markus Armbruster
Anthony Liguori writes: > On 04/22/14 07:35, Michael Roth wrote: >> Quoting Stefan Hajnoczi (2014-04-22 08:31:08) >>> On Wed, Apr 02, 2014 at 05:40:23PM -0700, Alex Davis wrote: and where is their gpg key? >>> >>> Michael Roth is doing releases: >>> >>> http://pgp.mit.edu/pks/lookup?op=vi

Re: [Qemu-devel] [PATCH RFC] ps2: set the keybord output buffer size as the same as kernel

2014-04-23 Thread Gonglei (Arei)
> > Hi, > > > > > if (++q->rptr == 256) { > > > > q->rptr = 0; > > > > } > > > > } > > > > > > That fails for the wraparound (rptr > wptr) case. > > > > > Yep, it should use a temporary data array to transfer, which I have written > > in the previous email. > >

Re: [Qemu-devel] [PULL v2 2/2] usb: mtp filesharing

2014-04-23 Thread Gerd Hoffmann
On Mi, 2014-04-23 at 16:09 +0200, Laszlo Ersek wrote: > On 04/23/14 10:31, Gerd Hoffmann wrote: > > Implementation of a USB Media Transfer Device device for easy > > filesharing. Read-only. No access control inside qemu, it will > > happily export any file it is able to open to the guest, i.e. >

Re: [Qemu-devel] [PATCH RFC] ps2: set the keybord output buffer size as the same as kernel

2014-04-23 Thread Gerd Hoffmann
Hi, > > > if (++q->rptr == 256) { > > > q->rptr = 0; > > > } > > > } > > > > That fails for the wraparound (rptr > wptr) case. > > > Yep, it should use a temporary data array to transfer, which I have written > in the previous email. Saw it. And this wraparoun

Re: [Qemu-devel] [PULL v2 2/2] usb: mtp filesharing

2014-04-23 Thread Laszlo Ersek
On 04/23/14 10:31, Gerd Hoffmann wrote: > Implementation of a USB Media Transfer Device device for easy > filesharing. Read-only. No access control inside qemu, it will > happily export any file it is able to open to the guest, i.e. > standard unix access rights for the qemu process apply. > > S

Re: [Qemu-devel] [PATCH RFC] ps2: set the keybord output buffer size as the same as kernel

2014-04-23 Thread Gerd Hoffmann
Hi, > > Completely separate question: Have you figured what the root cause for > > the bug is? > > > While wading through the code I've figured the queue size > > isn't (directly) exposed to the guest. > The process correspond with the above linux kernel code, i8042_flush(void). So linux

Re: [Qemu-devel] [PATCH RFC] ps2: set the keybord output buffer size as the same as kernel

2014-04-23 Thread Gonglei (Arei)
> > Hi, > > > /* the new version id for this patch */ > > if (version_id == 4) { > > return 0; > > } > > I don't think we need a new version. > OK. > > /* set the useful data buffer queue size, < PS2_QUEUE_SIZE */ > > size = MIN(q->count, PS2_QUEUE_SIZE); > > I'd

Re: [Qemu-devel] [PATCH 00/13] __{get, put}_user return value cleanup

2014-04-23 Thread Riku Voipio
On Wed, Apr 23, 2014 at 02:22:32PM +0100, Peter Maydell wrote: > On 23 April 2014 14:11, wrote: > > From: Riku Voipio > > > > This series is primarily motivated to have a gcc-4.9 buildfix: > > > > linux-user/syscall.c: In function ‘host_to_target_stat64’: > > linux-user/qemu.h:301:19: error: rig

[Qemu-devel] [QEMU v8 PATCH 2/7] PC: Add machine version 2.1 for piix and q35

2014-04-23 Thread Gabriel L. Somlo
Add v2.1 machine types and (empty) compat functions for v2.0, to both piix and q35. For now, the new machines will behave identically to their 2.0 counterparts. Signed-off-by: Gabriel Somlo --- hw/i386/pc_piix.c | 27 --- hw/i386/pc_q35.c | 25 +++--

[Qemu-devel] [QEMU v8 PATCH 4/7] SMBIOS: Update header file definitions

2014-04-23 Thread Gabriel L. Somlo
Add definitions for smbios entry point (anchor), and for type 2 (base board) structure which is required by some versions of OS X. Remove definition for type 20 (memory device mapped address) structure, which is no longer required as of smbios spec v2.5. Update all other structure definitions to

[Qemu-devel] [QEMU v8 PATCH 6/7] SMBIOS: Use bitmaps to prevent incompatible comand line options

2014-04-23 Thread Gabriel L. Somlo
Replace existing smbios_check_collision() functionality with a pair of bitmaps: have_binfile_bitmap and have_fields_bitmap. Bits corresponding to each smbios type are set by smbios_entry_add(), which also uses the bitmaps to ensure that binary blobs and field values are never accepted for the same

[Qemu-devel] [QEMU v8 PATCH 3/7] SMBIOS: Rename symbols to better reflect future use

2014-04-23 Thread Gabriel L. Somlo
Rename the following symbols: - smbios_set_type1_defaults() to the more general smbios_set_defaults(); - bool smbios_type1_defaults to the more general smbios_defaults; - smbios_get_table() to smbios_get_table_legacy(); This patch contains no functional changes. Signed-off-by: Gabriel Soml

[Qemu-devel] [QEMU v8 PATCH 5/7] SMBIOS: Use macro to set smbios defaults

2014-04-23 Thread Gabriel L. Somlo
The function smbios_set_defaults() uses a repeating code pattern for each field. This patch replaces that pattern with a macro. This patch contains no functional changes. Signed-off-by: Gabriel Somlo --- hw/i386/smbios.c | 27 +-- 1 file changed, 13 insertions(+), 14 del

[Qemu-devel] [QEMU v8 PATCH 7/7] SMBIOS: Build aggregate smbios tables and entry point

2014-04-23 Thread Gabriel L. Somlo
Build an aggregate set of smbios tables and an entry point structure. Insert tables and entry point into fw_cfg respectively under "etc/smbios/smbios-tables" and "etc/smbios/smbios-anchor". Machine types <= 2.0 will for now continue using field-by-field overrides to SeaBIOS defaults, but for mach

[Qemu-devel] [QEMU v8 PATCH 1/7] E820: Add interface for accessing e820 table

2014-04-23 Thread Gabriel L. Somlo
Add the following two functions: - e820_get_num_entries() - query the size of the e820 table - e820_get_entry() - grab an entry matching a given set of criteria This interface is currently necessary for creating type 19 (memory array mapped address) structures in smbios. Signed-off-by: Gabri

  1   2   >