[Qemu-devel] [PATCH 1/2] virtio-balloon: export all balloon statistics

2016-02-19 Thread Denis V. Lunev
From: Igor Redko We are making experiments with different autoballooning strategies based on the guest behavior. Thus we need to experiment with different guest statistics. For now every counter change requires QEMU recompilation and dances with Libvirt. This patch

[Qemu-devel] [PATCH 0/2] virtio-balloon: improve balloon statistics

2016-02-19 Thread Denis V. Lunev
New counter from the Linux kernel + generic framework to pass currently unknown counters via QMP for debug purposes. Signed-off-by: Denis V. Lunev CC: Igor Redko CC: Michael S. Tsirkin

[Qemu-devel] [PATCH 2/2] virtio-balloon: add 'available' counter

2016-02-19 Thread Denis V. Lunev
The patch for the kernel part is in linux-next already: commit ac88e7c908b920866e529862f2b2f0129b254ab2 Author: Igor Redko Date: Thu Feb 18 09:23:01 2016 +1100 virtio_balloon: export 'available' memory to balloon statistics Add a new field,

Re: [Qemu-devel] [PATCH 3/3] replay: introduce block devices record/replay

2016-02-19 Thread Pavel Dovgalyuk
> From: Pavel Dovgalyuk [mailto:dovga...@ispras.ru] > > From: Kevin Wolf [mailto:kw...@redhat.com] > > Am 16.02.2016 um 12:20 hat Pavel Dovgalyuk geschrieben: > > > Coroutine Replay > > > bool *done = req_replayed_list_get(reqid) // NULL > >

[Qemu-devel] [PATCH 1/3] exec: store RAMBlock pointer into memory region

2016-02-19 Thread Gonglei
Each RAM memory region has a unique corresponding RAMBlock. In the current realization, the memory region only stored the ram_addr which means the offset of RAM address space, We need to qurey the global ram.list to find the ram block by ram_addr if we want to get the ram block, which is very

[Qemu-devel] [PATCH 0/3] memory: an optimization

2016-02-19 Thread Gonglei
Perf top tells me qemu_get_ram_ptr consume too much cpu cycles. > 22.56% qemu-kvm [.] address_space_translate > 13.29% qemu-kvm [.] qemu_get_ram_ptr > 4.71% qemu-kvm [.] phys_page_find > 4.43% qemu-kvm [.]

[Qemu-devel] [PATCH 2/3] memory: optimize qemu_get_ram_ptr and qemu_ram_ptr_length

2016-02-19 Thread Gonglei
these two functions consume too much cpu overhead to find the RAMBlock by ram address. After this patch, we can pass the RAMBlock pointer to them so that they don't need to find the RAMBlock anymore most of the time. We can get better performance in address translation processing. Signed-off-by:

[Qemu-devel] [PATCH 3/3] memory: Remove the superfluous code

2016-02-19 Thread Gonglei
Signed-off-by: Gonglei --- include/exec/memory.h | 2 -- 1 file changed, 2 deletions(-) diff --git a/include/exec/memory.h b/include/exec/memory.h index 227fbf4..5f96e6b 100644 --- a/include/exec/memory.h +++ b/include/exec/memory.h @@ -1399,8 +1399,6 @@ static inline

Re: [Qemu-devel] [PATCH] migration: reorder code to make it symmetric

2016-02-19 Thread Wei Yang
Hi, Amit Do you like this one? On Thu, Feb 04, 2016 at 10:50:30PM +, Wei Yang wrote: >In qemu_savevm_state_complete_precopy(), it iterates on each device to add >a json object and transfer related status to destination, while the order >of the last two steps could be refined. > >Current

[Qemu-devel] [PATCH 12/17] qapi: Don't special-case simple union wrappers

2016-02-19 Thread Eric Blake
Simple unions were carrying a special case that hid their 'data' QMP member from the resulting C struct, via the hack method QAPISchemaObjectTypeVariant.simple_union_type(). But using the work we started by unboxing flat union and alternate branches, we expose the simple union's implicit type in

[Qemu-devel] [PATCH 14/17] qapi: Allow anonymous base for flat union

2016-02-19 Thread Eric Blake
Rather than requiring all flat unions to explicitly create a separate base struct, we can allow the qapi schema to specify the common fields via an inline dictionary. This is similar to how commands can specify an inline anonymous type for its 'data', and matches the fact that our code base

[Qemu-devel] [PATCH 17/17] qapi: Make c_type() more OO-like

2016-02-19 Thread Eric Blake
QAPISchemaType.c_type() was a bit awkward. Rather than having two optional orthogonal boolean flags that should never both be true, and where all callers pass a compile-time constant, provide three different method names that can be overridden as needed, and where the caller just uses the right

[Qemu-devel] [PATCH 13/17] qapi-visit: Move error check into gen_visit_fields_call()

2016-02-19 Thread Eric Blake
When first introduced, neither branch of gen_visit_fields_call() would output a goto. But now that the implicit struct visit always ends with a goto, we should do the same for regular struct visits, so that callers don't have to worry about whether they are creating two identical goto's in a row.

[Qemu-devel] [PATCH 04/17] ui: Shorten references into InputEvent

2016-02-19 Thread Eric Blake
An upcoming patch will alter how simple unions, like InputEvent, are laid out, which will impact all lines of the form 'evt->u.XXX'. To minimize the impact of that patch, use a temporary variable to reduce the number of lines needing modification when an internal reference within InputEvent

[Qemu-devel] [PATCH 05/17] qapi: Avoid use of 'data' member of qapi unions

2016-02-19 Thread Eric Blake
qapi code generators currently create a 'void *data' member as part of the anonymous union embedded in the C struct corresponding to a qapi union. However, directly assigning to this member of the union feels a bit fishy, when we can directly use the rest of the struct instead. Signed-off-by:

[Qemu-devel] [PATCH 15/17] qapi: Use anonymous base in SchemaInfo

2016-02-19 Thread Eric Blake
Now that the generator supports it, we might as well use an anonymous base rather than breaking out a single-use SchemaInfoBase structure. Oddly enough, this change does not affect the resulting introspection output (because we already inline the members of a base type into an object, and had no

[Qemu-devel] [PATCH 16/17] qapi: Use anonymous base in CpuInfo

2016-02-19 Thread Eric Blake
Now that the generator supports it, we might as well use an anonymous base rather than breaking out a single-use CpuInfoBase structure. Signed-off-by: Eric Blake --- v1: no change Previously posted as part of qapi cleanup subset F: v6: new patch --- scripts/qapi.py | 2 +-

[Qemu-devel] [PATCH 11/17] qapi-visit: Simplify visit of empty branch in union

2016-02-19 Thread Eric Blake
Now that we have is_empty() and gen_visit_fields_call(), it's fairly easy to skip the visit of a variant type that has no members. Only one such instance exists at the moment (CpuInfoOther), but the idea of a union where some branches add no fields beyond the base type is common enough that we

[Qemu-devel] [PATCH 08/17] qapi-visit: Factor out gen_visit_fields_call()

2016-02-19 Thread Eric Blake
Upcoming patches will be adding several contexts where we want to handle the visit of an implicit type (an anonymous base type, or an anonymous branch of a flat union) by directly inlining the visit of each of the implicit type's member fields. The work is made easier by factoring out a new helper

[Qemu-devel] [PATCH 10/17] qapi: Fix command with named empty argument type

2016-02-19 Thread Eric Blake
The generator special-cased { 'command':'foo', 'data': {} } to avoid emitting a visitor variable, but failed to see that { 'struct':'NamedEmptyType, 'data': {} } { 'command':'foo', 'data':'NamedEmptyType' } needs the same treatment. There, the generator happily generates a visitor to get

[Qemu-devel] [PATCH 02/17] chardev: Shorten references into ChardevBackend

2016-02-19 Thread Eric Blake
An upcoming patch will alter how simple unions, like ChardevBackend, are laid out, which will impact all lines of the form 'backend->u.XXX'. To minimize the impact of that patch, use a temporary variable to reduce the number of lines needing modification when an internal reference within

[Qemu-devel] [PATCH 03/17] util: Shorten references into SocketAddress

2016-02-19 Thread Eric Blake
An upcoming patch will alter how simple unions, like SocketAddress, are laid out, which will impact all lines of the form 'addr->u.XXX'. To minimize the impact of that patch, use C99 initialization or a temporary variable to reduce the number of lines needing modification when an internal

[Qemu-devel] [PATCH 00/17] qapi implicit types (continuing the qapi cleanup theme)

2016-02-19 Thread Eric Blake
I don't know what letter and or number to assign this batch, so I'll just call it v1 of 'qapi-implicit' :) It does, however, incorporate reviews on several patches that were in subset E v9 [1], and some that were posted (but not yet reviewed) in subset F v6 [2]; the remaining patches are new but

[Qemu-devel] [PATCH 07/17] qapi: Drop useless 'data' member of unions

2016-02-19 Thread Eric Blake
Now that we no longer have any clients of the 'void *data' member injected into unions, we can drop it. Update the testsuite to drop the negative test union-clash-data, and replace it with a positive test in qapi-schema-test that proves that we no longer have a name collision. Signed-off-by:

[Qemu-devel] [PATCH 01/17] chardev: Properly initialize ChardevCommon components

2016-02-19 Thread Eric Blake
Commit d0d7708b forgot to parse logging for spice chardevs and virtual consoles. This requires making qemu_chr_parse_common() non-static. While at it, use a temporary variable to make the code shorter, as well as reduce the churn when a later patch alters the layout of simple unions.

[Qemu-devel] [PATCH 06/17] chardev: Drop useless ChardevDummy type

2016-02-19 Thread Eric Blake
Commit d0d7708b made ChardevDummy be an empty wrapper type around ChardevCommon. But there is no technical reason for this indirection, so simplify the code by directly using the base type. Also change the fallback assignment to assign u.null rather than u.data, since a future patch will remove

[Qemu-devel] [PATCH 09/17] qapi: Add type.is_empty() helper

2016-02-19 Thread Eric Blake
And use it in qapi-types and qapi-event. Down the road, we may want to lift our artificial restriction of no variants at the top level of an event, at which point, inlining our check for whether members is empty will no longer be sufficient, but adding a check for variants adds verbosity; in the

Re: [Qemu-devel] [PATCH v1 1/1] etraxfs_dma: Dont forward zero-length payload to clients

2016-02-19 Thread Edgar E. Iglesias
On Tue, Feb 16, 2016 at 12:53:32PM +0100, Edgar E. Iglesias wrote: > From: "Edgar E. Iglesias" Applied > > Signed-off-by: Edgar E. Iglesias > --- > hw/dma/etraxfs_dma.c | 13 - > 1 file changed, 8 insertions(+), 5

Re: [Qemu-devel] [PATCH 1/2] vfio/pci: use PCI_MSIX_FLAGS on retrieving the MSIX entries

2016-02-19 Thread Wei Yang
On Fri, Feb 19, 2016 at 09:45:32AM -0700, Alex Williamson wrote: >On Fri, 19 Feb 2016 15:18:10 + >Wei Yang wrote: > >> Even PCI_CAP_FLAGS has the same value as PCI_MSIX_FLAGS, the later one is >> the more proper on retrieving MSIX entries. >> >> This patch uses

[Qemu-devel] [Bug 1546680] Re: Incorrect display colors when running big endian guest on POWER8 little endian host

2016-02-19 Thread Timothy Pearson
** Tags added: power8 ** Tags removed: power8 ** Tags added: ppc qemu vga -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1546680 Title: Incorrect display colors when running big endian guest on

Re: [Qemu-devel] [PATCH] hw/arm/virt: Assume EL3 boot rom will handle PSCI if one is provided

2016-02-19 Thread Laszlo Ersek
On 02/19/16 22:41, Ard Biesheuvel wrote: > On 19 February 2016 at 22:03, Laszlo Ersek wrote: >> Ard, any opinion on this? >> > > I agree with Peter. Note that this is strictly about emulation, under > KVM we always run at EL1 or below and PSCI calls are handled by the > host

Re: [Qemu-devel] [PATCH] hw/arm/virt: Assume EL3 boot rom will handle PSCI if one is provided

2016-02-19 Thread Ard Biesheuvel
On 19 February 2016 at 22:03, Laszlo Ersek wrote: > Ard, any opinion on this? > I agree with Peter. Note that this is strictly about emulation, under KVM we always run at EL1 or below and PSCI calls are handled by the host kernel, not QEMU > On 02/19/16 17:21, Peter Maydell

Re: [Qemu-devel] [PATCH 1/1] virtio-rng: fix condition checking on period_ms

2016-02-19 Thread Wei Huang
On 02/19/2016 02:59 PM, Laszlo Ersek wrote: > On 02/19/16 21:57, Laszlo Ersek wrote: >> On 02/19/16 19:13, Wei Huang wrote: >>> The condition checking on vrng->conf.period_ms appears to be wrong, >>> conflicting with the error comment following it. >>> >>> Signed-off-by: Wei Huang

Re: [Qemu-devel] [PATCH v2 7/9] i.MX: Add i.MX6 SOC implementation.

2016-02-19 Thread Jean-Christophe DUBOIS
Le 19/02/2016 10:32, Peter Maydell a écrit : On 19 February 2016 at 06:32, Jean-Christophe DUBOIS wrote: Le 18/02/2016 22:46, Peter Maydell a écrit : Does SMP work with EL3 not enabled, or is this a different bug? If I set has_el3 to false, I can boot the 4 cores

Re: [Qemu-devel] [PATCH] hw/arm/virt: Assume EL3 boot rom will handle PSCI if one is provided

2016-02-19 Thread Laszlo Ersek
Ard, any opinion on this? Thanks Laszlo On 02/19/16 17:21, Peter Maydell wrote: > If the user passes us an EL3 boot rom, then it is going to want to > implement the PSCI interface itself. In this case, disable QEMU's > internal PSCI implementation so it does not get in the way, and > instead

Re: [Qemu-devel] [PATCH 1/1] virtio-rng: fix condition checking on period_ms

2016-02-19 Thread Laszlo Ersek
On 02/19/16 21:57, Laszlo Ersek wrote: > On 02/19/16 19:13, Wei Huang wrote: >> The condition checking on vrng->conf.period_ms appears to be wrong, >> conflicting with the error comment following it. >> >> Signed-off-by: Wei Huang >> --- >> hw/virtio/virtio-rng.c | 2 +- >> 1

Re: [Qemu-devel] [PATCH 1/1] virtio-rng: fix condition checking on period_ms

2016-02-19 Thread Laszlo Ersek
On 02/19/16 19:13, Wei Huang wrote: > The condition checking on vrng->conf.period_ms appears to be wrong, > conflicting with the error comment following it. > > Signed-off-by: Wei Huang > --- > hw/virtio/virtio-rng.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > >

[Qemu-devel] [PATCH v3 1/2] generic-loader: Add a generic loader

2016-02-19 Thread Alistair Francis
Add a generic loader to QEMU which can be used to load images or set memory values. This only supports ARM architectures at the moment. Signed-off-by: Alistair Francis --- V3: - Pass the ram_size to load_image_targphys() V2: - Add maintainers entry - Perform

[Qemu-devel] [PATCH v3 0/2] Add a generic loader

2016-02-19 Thread Alistair Francis
This work is based on the original work by Li Guang with extra features added by Peter C and myself. The idea of this loader is to allow the user to load multiple images or values into QEMU at startup. Memory values can be loaded like this: -device

[Qemu-devel] [PATCH v3 2/2] docs: Add a generic loader explanation document

2016-02-19 Thread Alistair Francis
Signed-off-by: Alistair Francis --- docs/generic-loader.txt | 21 + 1 file changed, 21 insertions(+) create mode 100644 docs/generic-loader.txt diff --git a/docs/generic-loader.txt b/docs/generic-loader.txt new file mode 100644 index

[Qemu-devel] [PATCH v2 0/8] arm: Steps towards EL2 support round 6

2016-02-19 Thread Edgar E. Iglesias
From: "Edgar E. Iglesias" Hi, Another round of patches towards EL2 support. This one adds partial Instruction Syndrome generation for Data Aborts while running in AArch64. I don't feel very confident with the way I collect the regsize info used to fill out the SF

Re: [Qemu-devel] [RFC PATCH v2 09/10] net/colo-proxy: Compare pri pkt to sec pkt

2016-02-19 Thread Dr. David Alan Gilbert
* Zhang Chen (zhangchen.f...@cn.fujitsu.com) wrote: > From: zhangchen > > We will compare packet sent by primary guest > to secondary guest,if same,send primary packet. > else we will notify colo to do checkpoint to > make secondary guset running same as primary >

[Qemu-devel] [PATCH v2 4/8] target-arm: Add more fields to the data abort syndrome generator

2016-02-19 Thread Edgar E. Iglesias
From: "Edgar E. Iglesias" Add the following flags to the data abort syndrome generator: * isv - Instruction syndrome valid * sas - Syndrome access size * sse - Syndrome sign extend * srt - Syndrome register transfer * sf - Sixty-Four bit register width * ar -

[Qemu-devel] [PATCH v2 8/8] target-arm: Use isyn.swstep.ex to hold the is_ldex state

2016-02-19 Thread Edgar E. Iglesias
From: "Edgar E. Iglesias" Switch to using isyn.swstep.ex to hold the is_ldex state for SWStep syndrome generation. No functional change. Signed-off-by: Edgar E. Iglesias --- target-arm/translate-a64.c | 6 +++--- target-arm/translate.c

[Qemu-devel] [PATCH v2 3/8] target-arm: Add the IL flag to syn_data_abort

2016-02-19 Thread Edgar E. Iglesias
From: "Edgar E. Iglesias" Add the IL flag to syn_data_abort(). Since we at the moment never set ISV, the IL flag is always set to one. Signed-off-by: Edgar E. Iglesias --- target-arm/internals.h | 4 +++- target-arm/op_helper.c | 6 --

[Qemu-devel] [PATCH v2 6/8] target-arm/translate-a64.c: Unify some of the ldst_reg decoding

2016-02-19 Thread Edgar E. Iglesias
From: "Edgar E. Iglesias" The various load/store variants under disas_ldst_reg can all reuse the same decoding for opc, size, rt and is_vector. This patch unifies the decoding in preparation for generating instruction syndromes for data aborts. This will allow us to

[Qemu-devel] [PATCH v2 5/8] target-arm/translate-a64.c: Use extract32 in disas_ldst_reg_imm9

2016-02-19 Thread Edgar E. Iglesias
From: "Edgar E. Iglesias" Use extract32 instead of open coding the bit masking when decoding is_signed and is_extended. This streamlines the decoding with some of the other ldst variants. No functional change. Reviewed-by: Sergey Fedorov

[Qemu-devel] [PATCH v2 7/8] target-arm: A64: Create Instruction Syndromes for Data Aborts

2016-02-19 Thread Edgar E. Iglesias
From: "Edgar E. Iglesias" Add support for generating the instruction syndrome for Data Aborts. These syndromes are used by hypervisors for example to trap and emulate memory accesses. We save the decoded data out-of-band with the TBs at translation time. When

[Qemu-devel] [PATCH v2 2/8] gen-icount: Use tcg_set_insn_param

2016-02-19 Thread Edgar E. Iglesias
From: "Edgar E. Iglesias" Use tcg_set_insn_param() instead of directly accessing internal tcg data structures to update an insn param. Reviewed-by: Richard Henderson Signed-off-by: Edgar E. Iglesias ---

[Qemu-devel] [PATCH v2 1/8] tcg: Add tcg_set_insn_param

2016-02-19 Thread Edgar E. Iglesias
From: "Edgar E. Iglesias" Add tcg_set_insn_param as a mechanism to modify an insn parameter after emiting the insn. This is useful for icount and also for embedding fault information for a specific insn. Reviewed-by: Richard Henderson Signed-off-by:

Re: [Qemu-devel] [RFC PATCH v2 08/10] net/colo-proxy: Handle packet and connection

2016-02-19 Thread Dr. David Alan Gilbert
* Zhang Chen (zhangchen.f...@cn.fujitsu.com) wrote: > From: zhangchen > > In here we will handle ip packet and connection > > Signed-off-by: zhangchen > Signed-off-by: zhanghailiang > --- >

Re: [Qemu-devel] [RFC PATCH v2 06/10] net/colo-proxy: add socket used by forward func

2016-02-19 Thread Dr. David Alan Gilbert
* Zhang Chen (zhangchen.f...@cn.fujitsu.com) wrote: > From: zhangchen > > Colo need to forward packets > we start socket server in secondary and primary > connect to secondary in startup > the packet recv by primary forward to secondary > the packet send by

Re: [Qemu-devel] [PATCH v2 1/2] generic-loader: Add a generic loader

2016-02-19 Thread Alistair Francis
On Thu, Feb 18, 2016 at 5:16 PM, Alistair Francis wrote: > Add a generic loader to QEMU which can be used to load images or set > memory values. > > This only supports ARM architectures at the moment. > > Signed-off-by: Alistair Francis

Re: [Qemu-devel] [RFC PATCH v2 05/10] net/colo-proxy: Add colo interface to use proxy

2016-02-19 Thread Dr. David Alan Gilbert
* Zhang Chen (zhangchen.f...@cn.fujitsu.com) wrote: > From: zhangchen > > Add interface used by migration/colo.c > so colo framework can work with proxy > > Signed-off-by: zhangchen > Signed-off-by: zhanghailiang

Re: [Qemu-devel] [RFC PATCH v2 03/10] Colo-proxy: add colo-proxy framework

2016-02-19 Thread Dr. David Alan Gilbert
* Zhang Chen (zhangchen.f...@cn.fujitsu.com) wrote: > From: zhangchen > > +static void colo_proxy_setup(NetFilterState *nf, Error **errp) > +{ > +COLOProxyState *s = FILTER_COLO_PROXY(nf); > + > +if (!s->addr) { > +error_setg(errp, "filter

Re: [Qemu-devel] [PATCH v2 2/2] target-arm: Implement MDCR_EL3.TPM and MDCR_EL2.TPM traps

2016-02-19 Thread Alistair Francis
On Fri, Feb 19, 2016 at 6:39 AM, Peter Maydell wrote: > Implement the performance monitor register traps controlled > by MDCR_EL3.TPM and MDCR_EL2.TPM. Most of the performance > registers already have an access function to deal with the > user-enable bit, and the TPM

Re: [Qemu-devel] [PATCH v1 1/2] qdev-monitor.c: Register reset function if the device has one

2016-02-19 Thread Alistair Francis
On Fri, Feb 19, 2016 at 9:15 AM, Andreas Färber wrote: > Am 18.02.2016 um 10:56 schrieb Markus Armbruster: >> Alistair Francis writes: >> >>> If the device being added when running qdev_device_add() has >>> a reset function, register it so that it

Re: [Qemu-devel] [PULL 00/14] VFIO updates 2016-02-19

2016-02-19 Thread Peter Maydell
On 19 February 2016 at 17:39, Alex Williamson wrote: > The following changes since commit 1b3337bb1d1c3125a2140c47629f36540ac57605: > > Merge remote-tracking branch 'remotes/armbru/tags/pull-error-2016-02-19' > into staging (2016-02-19 15:19:13 +) > > are

Re: [Qemu-devel] [PATCH 15/37] tcg: Clean up includes

2016-02-19 Thread Peter Maydell
On 6 February 2016 at 13:43, Peter Maydell wrote: > On 6 February 2016 at 00:51, Richard Henderson wrote: >> On 01/27/2016 05:17 AM, Peter Maydell wrote: >>> diff --git a/tcg/i386/tcg-target.c b/tcg/i386/tcg-target.c >>> index 9187d34..d90636c 100644

[Qemu-devel] [PATCH v9 0/5] add ACPI node for fw_cfg on pc and arm

2016-02-19 Thread Gabriel L. Somlo
Generate an ACPI DSDT node for fw_cfg on pc and arm guests. New since v8: - patch 3/5: on pc/x86, place FWCF node in scope \_SB.PCI0 (instead of directly under \_SB), to prevent any possible resource conflict as might be observed by Windows (thanks again to

[Qemu-devel] [PATCH v9 3/5] acpi: pc: add fw_cfg device node to dsdt

2016-02-19 Thread Gabriel L. Somlo
Add a fw_cfg device node to the ACPI DSDT. While the guest-side firmware can't utilize this information (since it has to access the hard-coded fw_cfg device to extract ACPI tables to begin with), having fw_cfg listed in ACPI will help the guest kernel keep a more accurate inventory of in-use IO

[Qemu-devel] [PATCH v9 2/5] pc: fw_cfg: move ioport base constant to pc.h

2016-02-19 Thread Gabriel L. Somlo
Move BIOS_CFG_IOPORT define from pc.c to pc.h, and rename it to FW_CFG_IO_BASE. Cc: Marc Marí Signed-off-by: Gabriel Somlo Reviewed-by: Laszlo Ersek Reviewed-by: Marc Marí --- hw/i386/pc.c | 5 ++---

[Qemu-devel] [PATCH v9 1/5] fw_cfg: expose control register size in fw_cfg.h

2016-02-19 Thread Gabriel L. Somlo
Expose the size of the control register (FW_CFG_CTL_SIZE) in fw_cfg.h. Add comment to fw_cfg_io_realize() pointing out that since the 8-bit data register is always subsumed by the 16-bit control register in the port I/O case, we use the control register width as the *total* width of the (classic,

[Qemu-devel] [PATCH v9 5/5] fw_cfg: document ACPI device node information

2016-02-19 Thread Gabriel L. Somlo
Signed-off-by: Gabriel Somlo Reviewed-by: Laszlo Ersek Reviewed-by: Marc Marí --- docs/specs/fw_cfg.txt | 9 + 1 file changed, 9 insertions(+) diff --git a/docs/specs/fw_cfg.txt b/docs/specs/fw_cfg.txt index 2099ad9..5414140 100644

[Qemu-devel] [PATCH v9 4/5] acpi: arm: add fw_cfg device node to dsdt

2016-02-19 Thread Gabriel L. Somlo
Add a fw_cfg device node to the ACPI DSDT. This is mostly informational, as the authoritative fw_cfg MMIO region(s) are listed in the Device Tree. However, since we are building ACPI tables, we might as well be thorough while at it... Signed-off-by: Gabriel Somlo Reviewed-by:

[Qemu-devel] [PULL 11/14] hw/arm/sysbus-fdt: helpers for clock node generation

2016-02-19 Thread Alex Williamson
From: Eric Auger 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. - copy_properties_from_host copies

[Qemu-devel] [PULL 12/14] hw/arm/sysbus-fdt: enable amd-xgbe dynamic instantiation

2016-02-19 Thread Alex Williamson
From: Eric Auger 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 supported from 4.2

[Qemu-devel] [PATCH 1/1] virtio-rng: fix condition checking on period_ms

2016-02-19 Thread Wei Huang
The condition checking on vrng->conf.period_ms appears to be wrong, conflicting with the error comment following it. Signed-off-by: Wei Huang --- hw/virtio/virtio-rng.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/virtio/virtio-rng.c

Re: [Qemu-devel] [PATCH 4/8] scripts/clean-includes: Enhance to handle header files

2016-02-19 Thread Peter Maydell
On 18 February 2016 at 19:04, Eric Blake wrote: > On 02/18/2016 11:05 AM, Peter Maydell wrote: >> Enhance clean-includes to handle header files as well as .c source >> files. For headers we merely remove all the redundant #include >> lines, including any includes of

Re: [Qemu-devel] [PULL 00/14] VFIO updates 2016-02-19

2016-02-19 Thread Alex Williamson
On Fri, 19 Feb 2016 10:39:31 -0700 Alex Williamson wrote: > The following changes since commit 1b3337bb1d1c3125a2140c47629f36540ac57605: > > Merge remote-tracking branch 'remotes/armbru/tags/pull-error-2016-02-19' > into staging (2016-02-19 15:19:13 +) > >

[Qemu-devel] [PULL 13/14] hw/arm/sysbus-fdt: remove qemu_fdt_setprop returned value check

2016-02-19 Thread Alex Williamson
From: Eric Auger qemu_fdt_setprop asserts in case of error hence no need to check the returned value. Signed-off-by: Eric Auger Reviewed-by: Peter Maydell Signed-off-by: Alex Williamson ---

[Qemu-devel] [PULL 09/14] device_tree: qemu_fdt_getprop converted to use the error API

2016-02-19 Thread Alex Williamson
From: Eric Auger Current qemu_fdt_getprop exits if the property is not found. It is sometimes needed to read an optional property, in which case we do not wish to exit but simply returns a null value. This patch converts qemu_fdt_getprop to accept an Error **, and

Re: [Qemu-devel] [PULL 0/6] softfloat queue

2016-02-19 Thread Peter Maydell
: > > > git://git.linaro.org/people/pmaydell/qemu-arm.git > tags/pull-softfloat-20160219 > > for you to fetch changes up to 1badb5869831de916792628b5e159176f7e342b8: > > MAINTAINERS: Add section for FPU emulation (2016-02-19 16:27:22 +) > > --

[Qemu-devel] [PULL 06/14] hw/vfio/platform: amd-xgbe device

2016-02-19 Thread Alex Williamson
From: Eric Auger This patch introduces the amd-xgbe VFIO platform device. It allows the guest to do passthrough on a device exposing an "amd,xgbe-seattle-v1a" compat string. Signed-off-by: Eric Auger Reviewed-by: Alex Bennée

[Qemu-devel] [PULL 14/14] vfio/pci: use PCI_MSIX_FLAGS on retrieving the MSIX entries

2016-02-19 Thread Alex Williamson
From: Wei Yang Even PCI_CAP_FLAGS has the same value as PCI_MSIX_FLAGS, the later one is the more proper on retrieving MSIX entries. This patch uses PCI_MSIX_FLAGS to retrieve the MSIX entries. Signed-off-by: Wei Yang Signed-off-by: Alex

[Qemu-devel] [PULL 08/14] device_tree: introduce qemu_fdt_node_path

2016-02-19 Thread Alex Williamson
From: Eric Auger This new helper routine returns a NULL terminated array of node paths matching a node name and a compat string. Signed-off-by: Eric Auger Reviewed-by: Peter Maydell Signed-off-by: Alex Williamson

[Qemu-devel] [PULL 10/14] device_tree: qemu_fdt_getprop_cell converted to use the error API

2016-02-19 Thread Alex Williamson
From: Eric Auger This patch aligns the prototype with qemu_fdt_getprop. The caller can choose whether the function self-asserts on error (passing _fatal as Error ** argument, corresponding to the legacy behavior), or behaves differently such as simply output a message. In

[Qemu-devel] [PULL 05/14] vfio/pci: replace 1 with PCI_CAP_LIST_NEXT to make code self-explain

2016-02-19 Thread Alex Williamson
From: Wei Yang Use the macro PCI_CAP_LIST_NEXT instead of 1, so that the code would be more self-explain. This patch makes this change and also fixs one typo in comment. Signed-off-by: Wei Yang Signed-off-by: Alex Williamson

[Qemu-devel] [PULL 03/14] aer: impove pcie_aer_init to support vfio device

2016-02-19 Thread Alex Williamson
From: Chen Fan pcie_aer_init was used to emulate an aer capability for pcie device, but for vfio device, the aer config space size is mutable and is not always equal to PCI_ERR_SIZEOF(0x48). it depends on where the TLP Prefix register required, so here we add a size

[Qemu-devel] [PULL 07/14] device_tree: introduce load_device_tree_from_sysfs

2016-02-19 Thread Alex Williamson
From: Eric Auger This function returns the host device tree blob from sysfs (/proc/device-tree). It uses a recursive function inspired from dtc read_fstree. Signed-off-by: Eric Auger Reviewed-by: Peter Maydell

[Qemu-devel] [PULL 01/14] pcie: modify the capability size assert

2016-02-19 Thread Alex Williamson
From: Chen Fan Device's Offset and size can reach PCIE_CONFIG_SPACE_SIZE, fix the corresponding assert. Signed-off-by: Chen Fan Reviewed-by: Marcel Apfelbaum Reviewed-by: Michael S. Tsirkin

[Qemu-devel] [PULL 02/14] vfio: make the 4 bytes aligned for capability size

2016-02-19 Thread Alex Williamson
From: Chen Fan this function search the capability from the end, the last size should 0x100 - pos, not 0xff - pos. Signed-off-by: Chen Fan Reviewed-by: Marcel Apfelbaum Reviewed-by: Michael S. Tsirkin

[Qemu-devel] [PULL 04/14] pcie_aer: expose pcie_aer_msg() interface

2016-02-19 Thread Alex Williamson
From: Chen Fan For vfio device, we need to propagate the aer error to Guest OS. we use the pcie_aer_msg() to send aer error to guest. Signed-off-by: Chen Fan Reviewed-by: Michael S. Tsirkin Signed-off-by: Alex

[Qemu-devel] [PULL 00/14] VFIO updates 2016-02-19

2016-02-19 Thread Alex Williamson
The following changes since commit 1b3337bb1d1c3125a2140c47629f36540ac57605: Merge remote-tracking branch 'remotes/armbru/tags/pull-error-2016-02-19' into staging (2016-02-19 15:19:13 +) are available in the git repository at: git://github.com/awilliam/qemu-vfio.git

Re: [Qemu-devel] [PATCH] log: Redirect stderr to logfile if deamonized

2016-02-19 Thread Paolo Bonzini
On 18/02/2016 18:12, Dimitris Aragiorgis wrote: > * Paolo Bonzini [2016-02-18 16:22:13 +0100]: > >> >> >> On 18/02/2016 12:38, Dimitris Aragiorgis wrote: >>> In case of daemonize, use the logfile passed with the -D option in >>> order to redirect stderr to it instead of

Re: [Qemu-devel] [RFC 0/1] riscv: Add full-system emulation support for the RISC-V Instruction Set Architecture (RV64G)

2016-02-19 Thread Stefan Hajnoczi
On Thu, Feb 18, 2016 at 05:02:04PM -0800, Sagar Karandikar wrote: > With this RFC, I mainly wanted to get input on the overall design of the > target > implementation, as well as see if any regular contributors would be > interested > in co-mentoring RISC-V related projects for QEMU's Google

Re: [Qemu-devel] [PATCH v1 1/2] qdev-monitor.c: Register reset function if the device has one

2016-02-19 Thread Paolo Bonzini
On 19/02/2016 11:55, Peter Maydell wrote: >> Any abstraction we have in QEMU should have at least a parallel (though >> > it need not be the same) in real hardware. Reset signals _do_ propagate >> > along buses, or at least along some buses, so "debusifying" reset seems >> > like a

Re: [Qemu-devel] [PATCH v1 1/2] qdev-monitor.c: Register reset function if the device has one

2016-02-19 Thread Andreas Färber
Am 18.02.2016 um 10:56 schrieb Markus Armbruster: > Alistair Francis writes: > >> If the device being added when running qdev_device_add() has >> a reset function, register it so that it can be called. >> >> Signed-off-by: Alistair Francis

Re: [Qemu-devel] [PATCH v1 01/10] qdict: implement a qdict_crumple method for un-flattening a dict

2016-02-19 Thread Daniel P. Berrange
On Fri, Feb 19, 2016 at 10:01:07AM -0700, Eric Blake wrote: > On 02/19/2016 09:47 AM, Daniel P. Berrange wrote: > > The qdict_flatten() method will take a dict whose elements are > > further nested dicts/lists and flatten them by concatenating > > keys. > > > > The qdict_crumple() method aims

Re: [Qemu-devel] [PATCH v1 01/10] qdict: implement a qdict_crumple method for un-flattening a dict

2016-02-19 Thread Eric Blake
On 02/19/2016 09:47 AM, Daniel P. Berrange wrote: > The qdict_flatten() method will take a dict whose elements are > further nested dicts/lists and flatten them by concatenating > keys. > > The qdict_crumple() method aims todo the reverse, taking a flat s/todo/to do/ > qdict, and turning it

Re: [Qemu-devel] [PATCH v8 3/5] acpi: pc: add fw_cfg device node to dsdt

2016-02-19 Thread Gabriel L. Somlo
On Fri, Feb 19, 2016 at 02:49:53PM +0100, Igor Mammedov wrote: > On Thu, 11 Feb 2016 17:06:03 -0500 > "Gabriel L. Somlo" wrote: > > > Add a fw_cfg device node to the ACPI DSDT. While the guest-side > > firmware can't utilize this information (since it has to access > > the

[Qemu-devel] [PATCH v1 09/10] chardev: add support for ACLs for TLS clients

2016-02-19 Thread Daniel P. Berrange
Currently any client which can complete the TLS handshake is able to use a chardev server. The server admin can turn on the 'verify-peer' option for the x509 creds to require the client to provide a x509 certificate. This means the client will have to acquire a certificate from the CA before they

[Qemu-devel] [PATCH v1 05/10] util: add QAuthZSimple object type for a simple access control list

2016-02-19 Thread Daniel P. Berrange
Add a QAuthZSimple object type that implements the QAuthZ interface. This simple built-in implementation maintains a trivial access control list with a sequence of match rules and a final default policy. This replicates the functionality currently provided by the qemu_acl module. To create an

[Qemu-devel] [PATCH v1 04/10] util: add QAuthZ object as an authorization base class

2016-02-19 Thread Daniel P. Berrange
The current qemu_acl module provides a simple access control list facility inside QEMU, which is used via a set of monitor commands acl_show, acl_policy, acl_add, acl_remove & acl_reset. Note there is no ability to create ACLs - the network services (eg VNC server) were expected to create ACLs

[Qemu-devel] [PATCH v1 10/10] vnc: allow specifying a custom ACL object name

2016-02-19 Thread Daniel P. Berrange
The VNC server has historically had support for ACLs to check both the SASL username and the TLS x509 distinguished name. The VNC server was responsible for creating the initial ACL, and the client app was then responsible for populating it with rules using the HMP 'acl_add' command. This is not

[Qemu-devel] [PATCH v1 06/10] acl: delete existing ACL implementation

2016-02-19 Thread Daniel P. Berrange
The 'qemu_acl' type was a previous non-QOM based attempt to provide an authorization facility in QEMU. Because it is non-QOM based it cannot be created via the command line and requires special monitor commands to manipulate it. The new QAuthZ and QAuthZSimple QOM classes provide a superset of

[Qemu-devel] [PATCH v1 07/10] qemu-nbd: add support for ACLs for TLS clients

2016-02-19 Thread Daniel P. Berrange
Currently any client which can complete the TLS handshake is able to use the NBD server. The server admin can turn on the 'verify-peer' option for the x509 creds to require the client to provide a x509 certificate. This means the client will have to acquire a certificate from the CA before they

[Qemu-devel] [PATCH v1 03/10] qom: support arbitrary non-scalar properties with -object

2016-02-19 Thread Daniel P. Berrange
The current -object command line syntax only allows for creation of objects with scalar properties, or a list with a fixed scalar element type. Objects which have properties that are represented as structs in the QAPI schema cannot be created using -object. This is a design limitation of the way

Re: [Qemu-devel] [PATCH 1/2] vfio/pci: use PCI_MSIX_FLAGS on retrieving the MSIX entries

2016-02-19 Thread Alex Williamson
On Fri, 19 Feb 2016 15:18:10 + Wei Yang wrote: > Even PCI_CAP_FLAGS has the same value as PCI_MSIX_FLAGS, the later one is > the more proper on retrieving MSIX entries. > > This patch uses PCI_MSIX_FLAGS to retrieve the MSIX entries. > > Signed-off-by: Wei Yang

[Qemu-devel] [PATCH v1 02/10] qapi: allow QmpInputVisitor to auto-cast types

2016-02-19 Thread Daniel P. Berrange
Currently the QmpInputVisitor assumes that all scalar values are directly represented as their final types. ie it assumes an 'int' is using QInt, and a 'bool' is using QBool. This extends it so that QString is optionally permitted for any of the non-string scalar types. This behaviour is turned

  1   2   3   4   >