Re: [Qemu-devel] [PATCH v6 27/28] migration/qmp: add command migrate-pause

2018-02-21 Thread Peter Xu
On Wed, Feb 14, 2018 at 06:56:59PM +, Dr. David Alan Gilbert wrote: > * Peter Xu (pet...@redhat.com) wrote: > > On Tue, Feb 13, 2018 at 08:11:00PM +, Dr. David Alan Gilbert wrote: > > > * Peter Xu (pet...@redhat.com) wrote: > > > > It pauses an ongoing migration. Currently it only

Re: [Qemu-devel] [Resend][PATCH] qga: unset frozen state if no mount points are frozen

2018-02-21 Thread Chen Hanxiao
At 2018-02-16 02:41:25, "Michael Roth" wrote: >Quoting Chen Hanxiao (2018-02-08 19:35:42) >> From: Chen Hanxiao >> >> If we set mountpoints to qmp_guest_fsfreeze_freeze_list, >> we may got nothing to freeze as all mountpoints are >> not valid.

Re: [Qemu-devel] [PATCH v6 21/28] migration: setup ramstate for resume

2018-02-21 Thread Peter Xu
On Wed, Feb 14, 2018 at 06:40:46PM +, Dr. David Alan Gilbert wrote: > * Peter Xu (pet...@redhat.com) wrote: > > On Tue, Feb 13, 2018 at 06:17:51PM +, Dr. David Alan Gilbert wrote: > > > * Peter Xu (pet...@redhat.com) wrote: > > > > After we updated the dirty bitmaps of ramblocks, we also

Re: [Qemu-devel] [Qemu-ppc] [PATCH 0/2] Firmware blob and git submodule for Sam460ex

2018-02-21 Thread Thomas Huth
On 21.02.2018 19:33, Peter Maydell wrote: > On 21 February 2018 at 17:06, BALATON Zoltan wrote: >> It's not that upstream u-boot has abandoned board support (it only removed >> support for the PPC440 CPU it once had). The board itself never had support >> in upstream u-boot,

[Qemu-devel] [PATCH v3 0/5] keymap: support kbd layouts with multiple mappings for the same key.

2018-02-21 Thread Gerd Hoffmann
The reverse keymap (-k $map) code has problems dealing with keymaps where multiple key combinations can create the same keysym, because it can store a single keycode per keysym only. This series fixes it and does some cleanups along the way. v2: rebase, codestyle fixes. v3: use GINT_TO_POINTER

Re: [Qemu-devel] [RFC PATCH v6 00/20] replay additions

2018-02-21 Thread Pavel Dovgalyuk
> From: Pavel Dovgalyuk [mailto:dovga...@ispras.ru] > > From: Ciro Santilli [mailto:ciro.santi...@gmail.com] > > On Wed, Feb 21, 2018 at 6:41 AM, Pavel Dovgalyuk wrote: > > >> From: Ciro Santilli [mailto:ciro.santi...@gmail.com] > > >> On Tue, Feb 20, 2018 at 9:46 AM, Pavel

[Qemu-devel] [PATCH v3 4/5] keymap: record multiple keysym -> keycode mappings

2018-02-21 Thread Gerd Hoffmann
Sometimes the same keysym can be created using different key combinations. Record them all in the reverse keymap, not only the first one. Signed-off-by: Gerd Hoffmann Reviewed-by: Daniel P. Berrangé --- ui/keymaps.c | 14 +++--- 1 file changed,

[Qemu-devel] [PATCH v3 2/5] keymap: use glib hash for kbd_layout_t

2018-02-21 Thread Gerd Hoffmann
Drop home-grown lookup code, which is a strange mix of a lookup table and a list. Use standard glib hash instead. Signed-off-by: Gerd Hoffmann --- ui/keymaps.c| 73 - ui/trace-events | 2 +- 2 files changed, 32

[Qemu-devel] [PATCH v3 1/5] keymap: make struct kbd_layout_t private to ui/keymaps.c

2018-02-21 Thread Gerd Hoffmann
Also use kbd_layout_t pointers instead of void pointers. Signed-off-by: Gerd Hoffmann Reviewed-by: Daniel P. Berrangé --- ui/keymaps.h | 29 ++--- ui/keymaps.c | 32 +--- 2 files changed, 31

Re: [Qemu-devel] [RFC PATCH v6 00/20] replay additions

2018-02-21 Thread Pavel Dovgalyuk
> From: Ciro Santilli [mailto:ciro.santi...@gmail.com] > On Wed, Feb 21, 2018 at 6:41 AM, Pavel Dovgalyuk wrote: > >> From: Ciro Santilli [mailto:ciro.santi...@gmail.com] > >> On Tue, Feb 20, 2018 at 9:46 AM, Pavel Dovgalyuk > >> wrote: > >> > > >> >

[Qemu-devel] [PATCH v3 3/5] keymap: numpad keysyms and keycodes are fixed

2018-02-21 Thread Gerd Hoffmann
No need to figure them at runtime from the keymap. Signed-off-by: Gerd Hoffmann Reviewed-by: Daniel P. Berrangé --- ui/keymaps.c | 61 +--- 1 file changed, 9 insertions(+), 52 deletions(-) diff

[Qemu-devel] [PATCH v3 5/5] keymap: consider modifier state when picking a mapping

2018-02-21 Thread Gerd Hoffmann
Pass the modifier state to the keymap lookup function. In case multiple keysym -> keycode mappings exist look at the modifier state and prefer the mapping where the modifier state matches. Signed-off-by: Gerd Hoffmann Reviewed-by: Daniel P. Berrangé ---

Re: [Qemu-devel] [PATCH v4 0/7] vfio: add display support

2018-02-21 Thread Zhenyu Wang
On 2018.02.20 18:04:17 +0100, Gerd Hoffmann wrote: > Hi, > > > Sneak preview at https://www.kraxel.org/cgit/qemu/log/?h=work/intel-vgpu > > Note: branch is a moving target ;) > > > > State: > > spice: Partly working (no mouse ptr yet). > > Working now, in case anyone wants play. > > Must

Re: [Qemu-devel] [qemu-s390x] [PATCH v8 13/13] s390-ccw: interactive boot menu for scsi

2018-02-21 Thread Thomas Huth
On 21.02.2018 20:35, Collin L. Walling wrote: > Interactive boot menu for scsi. This follows a similar procedure > as the interactive menu for eckd dasd. An example follows: > > s390x Enumerated Boot Menu. > > 3 entries detected. Select from index 0 to 2. > > Signed-off-by: Collin L.

Re: [Qemu-devel] [qemu-s390x] [PATCH v8 12/13] s390-ccw: use zipl values when no boot menu options are present

2018-02-21 Thread Thomas Huth
On 21.02.2018 20:35, Collin L. Walling wrote: > If no boot menu options are present, then flag the boot menu to > use the zipl options that were set in the zipl configuration file > (and stored on disk by zipl). These options are found at some > offset prior to the start of the zipl boot menu

Re: [Qemu-devel] [qemu-s390x] [PATCH v8 11/13] s390-ccw: set cp_receive mask only when needed and consume pending service irqs

2018-02-21 Thread Thomas Huth
On 21.02.2018 20:35, Collin L. Walling wrote: > It is possible while waiting for multiple types of external > interrupts that we might have pending irqs remaining between > irq consumption and irq-type disabling. Those interrupts > could potentially propagate to the guest after IPL completes > and

Re: [Qemu-devel] [RFC PATCH v0 1/2] pc-dimm: Make pc_dimm_built_list() global

2018-02-21 Thread Bharata B Rao
On Tue, Feb 20, 2018 at 03:35:10PM +0100, Igor Mammedov wrote: > On Mon, 19 Feb 2018 12:12:53 +0530 > Bharata B Rao wrote: > > > Making pc_dimm_built_list() global allows other parts of QEMU code > > to build and walk through the DIMM list in address-sorted order. > >

Re: [Qemu-devel] [qemu-s390x] [PATCH v8 06/13] s390-ccw: parse and set boot menu options

2018-02-21 Thread Thomas Huth
On 21.02.2018 20:35, Collin L. Walling wrote: > Set boot menu options for an s390 guest and store them in > the iplb. These options are set via the QEMU command line > option: > > -boot menu=on|off[,splash-time=X] > > or via the libvirt domain xml: > > > > > > Where X

[Qemu-devel] [PATCH qemu repost] qmp: Add qom-list-properties to list QOM object properties

2018-02-21 Thread Alexey Kardashevskiy
There is already 'device-list-properties' which does most of the job, however it does not handle everything returned by qom-list-types such as machines as they inherit directly from TYPE_OBJECT and not TYPE_DEVICE. This adds a new qom-list-properties command which prints properties of a specific

[Qemu-devel] [PATCH V4 0/3] tests: Add migration test for aarch64

2018-02-21 Thread Wei Huang
This patchset adds a migration test for aarch64. It leverages Dave Gilbert's recent patch "tests/migration: Add source to PC boot block" to create a new test case for aarch64. V3->V4: * Rename .s to .S, allowing assembly to include C-style header file * Move test defines into a new

[Qemu-devel] [PATCH V4 3/3] tests: Add migration test for aarch64

2018-02-21 Thread Wei Huang
This patch adds migration test support for aarch64. The test code, which implements the same functionality as x86, is booted as a kernel in qemu. Here are the design choices we make for aarch64: * We choose this -kernel approach because aarch64 QEMU doesn't provide a built-in fw like x86

[Qemu-devel] [PATCH V4 1/3] tests/migration: Convert the boot block compilation script into Makefile

2018-02-21 Thread Wei Huang
The x86 boot block header currently is generated with a shell script. To better support other CPUs (e.g. aarch64), we convert the script into Makefile. This allows us to 1) support cross-compilation easily, and 2) avoid creating a script file for every architecture. Signed-off-by: Wei Huang

[Qemu-devel] [PATCH V4 2/3] tests/migration: Add migration-test header file

2018-02-21 Thread Wei Huang
This patch moves the settings related migration-test from the migration-test.c file to a seperate header file. It also renames the x86-a-b-bootblock.s file extension from .s to .S, allowing gcc pre-processor to include the C-style header file correctly. Signed-off-by: Wei Huang

Re: [Qemu-devel] [qemu-s390x] [PATCH v8 05/13] s390-ccw: move auxiliary IPL data to separate location

2018-02-21 Thread Thomas Huth
On 21.02.2018 20:35, Collin L. Walling wrote: > The s390-ccw firmware needs some information in support of the > boot process which is not available on the native machine. > Examples are the netboot firmware load address and now the > boot menu parameters. > > While storing that data in unused

Re: [Qemu-devel] [PATCH] intel-iommu: Accept 64-bit writes to FEADDR

2018-02-21 Thread Peter Xu
On Sat, Feb 17, 2018 at 12:26:19PM +0100, Jan Kiszka wrote: > From: Jan Kiszka > > Xen is doing this [1] and currently triggers an abort. > > [1] >

Re: [Qemu-devel] [qemu-s390x] [PATCH v8 04/13] s390-ccw: update libc

2018-02-21 Thread Thomas Huth
On 21.02.2018 20:35, Collin L. Walling wrote: > Moved: > memcmp from bootmap.h to libc.h (renamed from _memcmp) > strlen from sclp.c to libc.h (renamed from _strlen) > > Added C standard functions: > isdigit > > Added non C-standard function: > uitoa > atoui > > Signed-off-by: Collin

Re: [Qemu-devel] [PATCH 0/2] Firmware blob and git submodule for Sam460ex

2018-02-21 Thread David Gibson
On Wed, Feb 21, 2018 at 06:33:42PM +, Peter Maydell wrote: > On 21 February 2018 at 17:06, BALATON Zoltan wrote: > > It's not that upstream u-boot has abandoned board support (it only removed > > support for the PPC440 CPU it once had). The board itself never had support >

Re: [Qemu-devel] [PATCH 09/11] mac_newworld: use object link to pass OpenPIC object to macio

2018-02-21 Thread David Gibson
On Mon, Feb 19, 2018 at 06:19:20PM +, Mark Cave-Ayland wrote: > Also switch macio_newworld_realize() over to use it rather than using the > pic_mem > memory region directly. > > Now that both Old World and New World macio devices no longer make use of the > pic_mem memory region directly, we

Re: [Qemu-devel] [PATCH 08/11] openpic: move OpenPIC state and related definitions to openpic.h

2018-02-21 Thread David Gibson
On Mon, Feb 19, 2018 at 06:19:19PM +, Mark Cave-Ayland wrote: > This is to faciliate access to OpenPICState when wiring up the PIC to the > macio > controller. > > Signed-off-by: Mark Cave-Ayland Reviewed-by: David Gibson > ---

Re: [Qemu-devel] [PATCH 10/11] macio: move setting of CUDA timebase frequency to macio_common_realize()

2018-02-21 Thread David Gibson
On Mon, Feb 19, 2018 at 06:19:21PM +, Mark Cave-Ayland wrote: > This removes the last of the functionality from macio_init() in preparation > for its subsequent removal. > > Signed-off-by: Mark Cave-Ayland Reviewed-by: David Gibson

Re: [Qemu-devel] [PATCH] hw/acpi-build: build SRAT memory affinity structures for NVDIMM

2018-02-21 Thread Haozhong Zhang
On 02/21/18 14:55 +0100, Igor Mammedov wrote: > On Tue, 20 Feb 2018 17:17:58 -0800 > Dan Williams wrote: > > > On Tue, Feb 20, 2018 at 6:10 AM, Igor Mammedov wrote: > > > On Sat, 17 Feb 2018 14:31:35 +0800 > > > Haozhong Zhang

Re: [Qemu-devel] [PATCH v4 00/22] re-factor softfloat and add fp16 functions

2018-02-21 Thread Fam Zheng
On Mon, 02/19 13:56, Peter Maydell wrote: > On 17 February 2018 at 13:23, Alex Bennée wrote: > > Peter Maydell writes: > >> If you persuade git to use the --minimal, --patience or --histogram > >> git diff option when generating these patches

[Qemu-devel] [PATCH v2 2/3] qcow2: Don't allow overflow during cluster allocation

2018-02-21 Thread Eric Blake
Our code was already checking that we did not attempt to allocate more clusters than what would fit in an INT64 (the physical maximimum if we can access a full off_t's worth of data). But this does not catch smaller limits enforced by various spots in the qcow2 image description: L1 and normal

[Qemu-devel] [PATCH v2 1/3] qcow2: Prefer byte-based calls into bs->file

2018-02-21 Thread Eric Blake
We had only three sector-based stragglers left; convert them to use our preferred byte-based accesses. Signed-off-by: Eric Blake Reviewed-by: Alberto Garcia --- v2: indentation fix --- block/qcow2-cluster.c | 5 ++--- block/qcow2-refcount.c | 6 +++--- 2

[Qemu-devel] [PATCH v2 3/3] qcow2: Avoid memory over-allocation on compressed images

2018-02-21 Thread Eric Blake
When reading a compressed image, we were allocating s->cluster_data to 32*cluster_size + 512 (possibly over 64 megabytes, for an image with 2M clusters). Let's check out the history: Back when qcow2 was first written, we used s->cluster_data for everything, including copy_sectors() and

[Qemu-devel] [PATCH v2 0/3] qcow2: minor compression improvements

2018-02-21 Thread Eric Blake
Updates to v1: - fix whitespace [Berto] - fix g_try_malloc usage [Berto, Kevin] - improve comments [Berto, Kevin] - add a patch to avoid overflow on 512TB images with 2M clusters Eric Blake (3): qcow2: Prefer byte-based calls into bs->file qcow2: Don't allow overflow during cluster allocation

Re: [Qemu-devel] [RFC PATCH v6 00/20] replay additions

2018-02-21 Thread Ciro Santilli
On Wed, Feb 21, 2018 at 6:41 AM, Pavel Dovgalyuk wrote: >> From: Ciro Santilli [mailto:ciro.santi...@gmail.com] >> On Tue, Feb 20, 2018 at 9:46 AM, Pavel Dovgalyuk wrote: >> > >> > Updated the branch on github. >> > You may try it. >> >> At

Re: [Qemu-devel] [PATCHv3 1/2] translator: merge max_insns into DisasContextBase

2018-02-21 Thread Emilio G. Cota
On Wed, Feb 21, 2018 at 13:05:45 -0800, Richard Henderson wrote: > On 02/21/2018 12:55 PM, Emilio G. Cota wrote: > > While at it, use int for both num_insns and max_insns to make > > sure we have same-type comparisons. > > > > Signed-off-by: Emilio G. Cota > > --- > >

Re: [Qemu-devel] [PATCH v3] specs/qcow2: Fix documentation of the compressed cluster descriptor

2018-02-21 Thread Eric Blake
On 02/21/2018 08:08 AM, Alberto Garcia wrote: This patch fixes several mistakes in the documentation of the compressed cluster descriptor: More things to consider, as followup patches: Note that both the L1 table, and the standard L2 descriptors, have a cap on bit 55 as the maximum host

[Qemu-devel] [PATCH v8 11/13] s390-ccw: set cp_receive mask only when needed and consume pending service irqs

2018-02-21 Thread Collin L. Walling
It is possible while waiting for multiple types of external interrupts that we might have pending irqs remaining between irq consumption and irq-type disabling. Those interrupts could potentially propagate to the guest after IPL completes and cause unwanted behavior. As it is today, the SCLP will

Re: [Qemu-devel] [PATCHv2 1/2] translator: merge max_insns into DisasContextBase

2018-02-21 Thread Emilio G. Cota
On Wed, Feb 21, 2018 at 10:19:05 -0800, Richard Henderson wrote: > On 02/19/2018 06:26 PM, Emilio G. Cota wrote: > > @@ -68,6 +69,7 @@ typedef struct DisasContextBase { > > target_ulong pc_next; > > DisasJumpType is_jmp; > > unsigned int num_insns; > > +int max_insns; > >

Re: [Qemu-devel] [PATCHv3 1/2] translator: merge max_insns into DisasContextBase

2018-02-21 Thread Richard Henderson
On 02/21/2018 12:55 PM, Emilio G. Cota wrote: > While at it, use int for both num_insns and max_insns to make > sure we have same-type comparisons. > > Signed-off-by: Emilio G. Cota > --- > accel/tcg/translator.c | 21 ++--- > include/exec/translator.h | 8

Re: [Qemu-devel] [PATCH v2 10/36] test-qemu-opts: Test qemu_opts_to_qdict_filtered()

2018-02-21 Thread Eric Blake
On 02/21/2018 07:53 AM, Kevin Wolf wrote: Signed-off-by: Kevin Wolf --- tests/test-qemu-opts.c | 125 + 1 file changed, 125 insertions(+) diff --git a/tests/test-qemu-opts.c b/tests/test-qemu-opts.c index

[Qemu-devel] [PATCH] tcg/i386: Support INDEX_op_dup2_vec for -m32

2018-02-21 Thread Richard Henderson
Unknown why -m32 was passing with gcc but not clang; it should have failed for both. This would be used for tcg_gen_dup_i64_vec, and visible with the right TB and an aarch64 guest. Reported-by: Max Reitz Signed-off-by: Richard Henderson ---

[Qemu-devel] [PATCHv3 2/2] target/sh4: convert to TranslatorOps

2018-02-21 Thread Emilio G. Cota
This was fairly straightforward since it had already been converted to DisasContextBase; just had to add TARGET_TOO_MANY to the switch in tb_stop. Reviewed-by: Richard Henderson Signed-off-by: Emilio G. Cota --- target/sh4/translate.c | 171

Re: [Qemu-devel] [PATCH v2 09/36] test-qemu-opts: Test qemu_opts_append()

2018-02-21 Thread Eric Blake
On 02/21/2018 07:53 AM, Kevin Wolf wrote: Basic test for merging two QemuOptsLists. Signed-off-by: Kevin Wolf --- tests/test-qemu-opts.c | 128 + 1 file changed, 128 insertions(+) Reviewed-by: Eric Blake

[Qemu-devel] [PATCHv3 0/2] target/sh4: translator loop conversion

2018-02-21 Thread Emilio G. Cota
Changes from v2: - Use int for both num_insns and max_insns, which involves no churn compared to converting everything to unsigned. Thanks, Emilio

[Qemu-devel] [PATCHv3 1/2] translator: merge max_insns into DisasContextBase

2018-02-21 Thread Emilio G. Cota
While at it, use int for both num_insns and max_insns to make sure we have same-type comparisons. Signed-off-by: Emilio G. Cota --- accel/tcg/translator.c | 21 ++--- include/exec/translator.h | 8 target/alpha/translate.c | 6 ++

Re: [Qemu-devel] [PATCH] fpu/softfloat: use hardware sqrt if we can (EXPERIMENT!)

2018-02-21 Thread Alex Bennée
Alex Bennée writes: > This is an attempt to save some of the cost of sqrt by using the > inbuilt support of the host hardware. The idea is assuming we start > with a valid input we can use the hardware. If any tininess issues > occur this will trip and FPU exception

Re: [Qemu-devel] [PATCH v2 08/36] util: Add qemu_opts_to_qdict_filtered()

2018-02-21 Thread Eric Blake
On 02/21/2018 07:53 AM, Kevin Wolf wrote: This allows, given a QemuOpts for a QemuOptsList that was merged from multiple QemuOptsList, to only consider those options that exist in one specific list. Block drivers need this to separate format-layer create options from protocol-level options.

[Qemu-devel] [Bug 1750899] [NEW] Mouse cursor sometimes can't pass the invisible border on the right side of the screen

2018-02-21 Thread Michael Akushsky
Public bug reported: I'm using qemu 2.11 on Gentoo Linux, with configured GPU passthrough (Radeon RX580) to the guest Windows 10. This configuration is alive for last 4 years, this time I changed a lot qemu, linux kernel and windows versions, changed GPU and always all was working as expected.

Re: [Qemu-devel] [PATCH v5 4/4] linux-user: MIPS set cpu to r6 CPU if binary is R6

2018-02-21 Thread Richard Henderson
On 02/20/2018 09:33 AM, Laurent Vivier wrote: > From: YunQiang Su > > So here we need to detect the version of binaries and set > cpu_model for it. > > Signed-off-by: YunQiang Su > [lv: original patch modified to move code into cpu_get_model()] >

[Qemu-devel] [PATCH v8 06/13] s390-ccw: parse and set boot menu options

2018-02-21 Thread Collin L. Walling
Set boot menu options for an s390 guest and store them in the iplb. These options are set via the QEMU command line option: -boot menu=on|off[,splash-time=X] or via the libvirt domain xml: Where X represents some positive integer representing milliseconds. Any value set

[Qemu-devel] [PATCH v8 05/13] s390-ccw: move auxiliary IPL data to separate location

2018-02-21 Thread Collin L. Walling
The s390-ccw firmware needs some information in support of the boot process which is not available on the native machine. Examples are the netboot firmware load address and now the boot menu parameters. While storing that data in unused fields of the IPL parameter block works, that approach could

Re: [Qemu-devel] [PATCH 2/2] qcow2: Avoid memory over-allocation on compressed images

2018-02-21 Thread Kevin Wolf
Am 21.02.2018 um 19:32 hat Eric Blake geschrieben: > On 02/21/2018 11:39 AM, Kevin Wolf wrote: > > > See my commit message comment - we have other spots in the code base that > > > blindly g_malloc(2 * s->cluster_size). > > > > Though is that a reason to do the same in new code or to phase out

[Qemu-devel] [PATCH v8 12/13] s390-ccw: use zipl values when no boot menu options are present

2018-02-21 Thread Collin L. Walling
If no boot menu options are present, then flag the boot menu to use the zipl options that were set in the zipl configuration file (and stored on disk by zipl). These options are found at some offset prior to the start of the zipl boot menu banner. The zipl timeout value is limited to a 16-bit

Re: [Qemu-devel] [PULL 19/20] tcg/i386: Add vector operations

2018-02-21 Thread Richard Henderson
On 02/20/2018 08:44 AM, Max Reitz wrote: > This patch makes make check with clang -m32 fail for me. (Interestingly > enough, though, clang -m64 and gcc -m32 work fine.) What's really interesting is that gcc -m32 should *not* have worked, but does. I'm not sure why. The assert is for the missing

[Qemu-devel] [PATCH v8 00/13] Interactive Boot Menu for DASD and SCSI Guests on s390x

2018-02-21 Thread Collin L. Walling
Due to the introduction of the QemuIplParameter block and taking some time to revist some areas, a few chunks of code have been reworked to better align with those changes. I also think the reworkings improve readability. The same functionality is still there, the code just looks a little

Re: [Qemu-devel] [PATCHv2 1/2] translator: merge max_insns into DisasContextBase

2018-02-21 Thread Richard Henderson
On 02/19/2018 06:26 PM, Emilio G. Cota wrote: > @@ -68,6 +69,7 @@ typedef struct DisasContextBase { > target_ulong pc_next; > DisasJumpType is_jmp; > unsigned int num_insns; > +int max_insns; > bool singlestep_enabled; > } DisasContextBase; We really should pick the same

Re: [Qemu-devel] [PATCH] docs: document how to use the l2-cache-entry-size parameter

2018-02-21 Thread Kevin Wolf
Am 19.02.2018 um 15:54 hat Alberto Garcia geschrieben: > This patch updates docs/qcow2-cache.txt explaining how to use the new > l2-cache-entry-size parameter. > > Here's a more detailed technical description of this feature: > >

Re: [Qemu-devel] [PATCH 1/2] target/openrisc: convert to DisasContextBase

2018-02-21 Thread Richard Henderson
On 02/17/2018 05:32 PM, Emilio G. Cota wrote: > Signed-off-by: Emilio G. Cota > --- > target/openrisc/translate.c | 87 > ++--- > 1 file changed, 43 insertions(+), 44 deletions(-) > > diff --git a/target/openrisc/translate.c

[Qemu-devel] [PATCH v8 09/13] s390-ccw: print zipl boot menu

2018-02-21 Thread Collin L. Walling
When the boot menu options are present and the guest's disk has been configured by the zipl tool, then the user will be presented with an interactive boot menu with labeled entries. An example of what the menu might look like: zIPL v1.37.1-build-20170714 interactive boot menu. 0. default

Re: [Qemu-devel] [PATCH 2/2] qcow2: Avoid memory over-allocation on compressed images

2018-02-21 Thread John Snow
On 02/21/2018 10:59 AM, Eric Blake wrote: > On 02/21/2018 09:00 AM, Eric Blake wrote: >> On 02/21/2018 04:04 AM, Alberto Garcia wrote: >>> On Tue 20 Feb 2018 11:24:59 PM CET, Eric Blake wrote: >>> >>> I was also preparing a patch to change this, but you arrived first :-) >>> So, it's time

Re: [Qemu-devel] [PATCH 1/6] build-sys: fix -fsanitize=address check

2018-02-21 Thread Emilio G. Cota
On Thu, Feb 15, 2018 at 22:25:47 +0100, Marc-André Lureau wrote: > Since 218bb57dd79d6843e0592c30a82ea8c1fddc74a5, the -fsanitize=address > check fails with: > config-temp/qemu-conf.c:3:20: error: integer overflow in expression > [-Werror=overflow] >return INT32_MIN / -1; > > Interestingly,

[Qemu-devel] [PATCH v8 01/13] s390-ccw: refactor boot map table code

2018-02-21 Thread Collin L. Walling
Some ECKD bootmap code was using structs designed for SCSI. Even though this works, it confuses readability. Add a new BootMapTable struct to assist with readability in bootmap entry code. Also: - replace ScsiMbr in ECKD code with appropriate structs - fix read_block messages to reflect

Re: [Qemu-devel] [PATCHv2 1/2] translator: merge max_insns into DisasContextBase

2018-02-21 Thread Richard Henderson
On 02/21/2018 12:17 PM, Emilio G. Cota wrote: > On Wed, Feb 21, 2018 at 10:19:05 -0800, Richard Henderson wrote: >> On 02/19/2018 06:26 PM, Emilio G. Cota wrote: >>> @@ -68,6 +69,7 @@ typedef struct DisasContextBase { >>> target_ulong pc_next; >>> DisasJumpType is_jmp; >>> unsigned

[Qemu-devel] [PATCH v8 13/13] s390-ccw: interactive boot menu for scsi

2018-02-21 Thread Collin L. Walling
Interactive boot menu for scsi. This follows a similar procedure as the interactive menu for eckd dasd. An example follows: s390x Enumerated Boot Menu. 3 entries detected. Select from index 0 to 2. Signed-off-by: Collin L. Walling Reviewed-by: Thomas Huth

[Qemu-devel] [PATCH v8 08/13] s390-ccw: read stage2 boot loader data to find menu

2018-02-21 Thread Collin L. Walling
Read the stage2 boot loader data block-by-block. We scan the current block for the string "zIPL" to detect the start of the boot menu banner. We then load the adjacent blocks (previous block and next block) to account for the possibility of menu data spanning multiple blocks. Signed-off-by:

[Qemu-devel] [PATCH v8 07/13] s390-ccw: set up interactive boot menu parameters

2018-02-21 Thread Collin L. Walling
Reads boot menu flag and timeout values from the iplb and sets the respective fields for the menu. Signed-off-by: Collin L. Walling Reviewed-by: Thomas Huth --- pc-bios/s390-ccw/Makefile | 2 +- pc-bios/s390-ccw/main.c | 24

[Qemu-devel] [PATCH v8 03/13] s390-ccw: refactor IPL structs

2018-02-21 Thread Collin L. Walling
ECKD DASDs have different IPL structures for CDL and LDL formats. The current Ipl1 and Ipl2 structs follow the CDL format, so we prepend "EckdCdl" to them. Boot info for LDL has been moved to a new struct: EckdLdlIpl1. Signed-off-by: Collin L. Walling Acked-by:

[Qemu-devel] [PATCH v8 04/13] s390-ccw: update libc

2018-02-21 Thread Collin L. Walling
Moved: memcmp from bootmap.h to libc.h (renamed from _memcmp) strlen from sclp.c to libc.h (renamed from _strlen) Added C standard functions: isdigit Added non C-standard function: uitoa atoui Signed-off-by: Collin L. Walling Acked-by: Christian

[Qemu-devel] [PATCH v8 02/13] s390-ccw: refactor eckd_block_num to use CHS

2018-02-21 Thread Collin L. Walling
Add new cylinder/head/sector struct. Use it to calculate eckd block numbers instead of a BootMapPointer (which used eckd chs anyway). Signed-off-by: Collin L. Walling Reviewed-by: Thomas Huth --- pc-bios/s390-ccw/bootmap.c | 28

[Qemu-devel] [PATCH v8 10/13] s390-ccw: read user input for boot index via the SCLP console

2018-02-21 Thread Collin L. Walling
Implements an sclp_read function to capture input from the console and a wrapper function that handles parsing certain characters and adding input to a buffer. The input is checked for any erroneous values and is handled appropriately. A prompt will persist until input is entered or the timeout

Re: [Qemu-devel] [PATCH v2 1/1] 390x/cpumodel: document S390FeatDef.bit not applicable

2018-02-21 Thread Cornelia Huck
On Wed, 21 Feb 2018 18:29:19 +0100 David Hildenbrand wrote: > On 21.02.2018 17:56, Halil Pasic wrote: s/390x/s390x/ > > The 'bit' field of the 'S390FeatDef' structure is not applicable to all > > its instances. Currently this field is not applicable, and remains > > unused,

Re: [Qemu-devel] [PATCH] configure: fix sanitizers' test program to mend ASan detection

2018-02-21 Thread Emilio G. Cota
On Wed, Feb 21, 2018 at 10:12:28 +0100, Marc-André Lureau wrote: > I sent a patch a few days ago: > "[PATCH 1/6] build-sys: fix -fsanitize=address check" Ouch, I missed that. Please disregard my patch. Thanks, Emilio

Re: [Qemu-devel] [PATCH 2/2] target/openrisc: convert to TranslatorOps

2018-02-21 Thread Richard Henderson
On 02/17/2018 05:32 PM, Emilio G. Cota wrote: > +dc->next_page_start = (dc->base.pc_first & TARGET_PAGE_MASK) + > +TARGET_PAGE_SIZE; > +return max_insns; OpenRISC is standard 4-byte risc insn; should use the same bound mechanism as ppc and sparc. r~

Re: [Qemu-devel] [PATCH 0/2] Firmware blob and git submodule for Sam460ex

2018-02-21 Thread Peter Maydell
On 21 February 2018 at 17:06, BALATON Zoltan wrote: > It's not that upstream u-boot has abandoned board support (it only removed > support for the PPC440 CPU it once had). The board itself never had support > in upstream u-boot, it only exists in vendor's fork which is the

Re: [Qemu-devel] [PATCH 2/2] qcow2: Avoid memory over-allocation on compressed images

2018-02-21 Thread Eric Blake
On 02/21/2018 11:39 AM, Kevin Wolf wrote: See my commit message comment - we have other spots in the code base that blindly g_malloc(2 * s->cluster_size). Though is that a reason to do the same in new code or to phase out such allocations whenever you touch them? Touché. And I intended

Re: [Qemu-devel] [PATCH v2 03/32] target/arm/cpu64: allow fp16 to be disabled

2018-02-21 Thread Richard Henderson
On 02/21/2018 08:35 AM, Alex Bennée wrote: >> Good news everybody -- this is an opportunity for a naming bikeshed >> discussion! ... >> * use the hwcaps names that Linux defines and prints in /proc/cpuinfo >>(in this case that would be a combination of "fphp" and "asimdhp", >>since hwcaps

Re: [Qemu-devel] [PATCH v7 00/23] QMP: out-of-band (OOB) execution support

2018-02-21 Thread Stefan Hajnoczi
On Wed, Jan 24, 2018 at 01:39:34PM +0800, Peter Xu wrote: > This version should have addressed all comments in previous one, also > fixed another race condition after I addressed all the comments (a new > race condition introduced by addressing the comments...). For some > more details of the

Re: [Qemu-devel] [PATCH v7 19/23] qmp: isolate responses into io thread

2018-02-21 Thread Stefan Hajnoczi
On Wed, Jan 24, 2018 at 01:39:53PM +0800, Peter Xu wrote: > For those monitors who have enabled IO thread, we'll offload the > responding procedure into IO thread. The main reason is that chardev is > not thread safe, and we need to do all the read/write IOs in the same > thread. For

Re: [Qemu-devel] [PATCH 2/2] qcow2: Avoid memory over-allocation on compressed images

2018-02-21 Thread Kevin Wolf
Am 21.02.2018 um 17:59 hat Eric Blake geschrieben: > On 02/21/2018 10:51 AM, Kevin Wolf wrote: > > Am 20.02.2018 um 23:24 hat Eric Blake geschrieben: > > > When reading a compressed image, we were allocating s->cluster_data > > > to 32*cluster_size + 512 (possibly over 64 megabytes, for an image >

Re: [Qemu-devel] [PATCH RFCv2] s390x/sclp: remove memory hotplug support

2018-02-21 Thread Cornelia Huck
On Tue, 20 Feb 2018 16:05:54 +0100 David Hildenbrand wrote: > On 20.02.2018 15:57, Cornelia Huck wrote: > > On Tue, 20 Feb 2018 13:16:37 +0100 > > David Hildenbrand wrote: > > > >> On 20.02.2018 13:05, Christian Borntraeger wrote: > >>> > >>> > >>> On

Re: [Qemu-devel] [PATCH v7 18/23] qmp: support out-of-band (oob) execution

2018-02-21 Thread Stefan Hajnoczi
On Wed, Jan 24, 2018 at 01:39:52PM +0800, Peter Xu wrote: > Having "allow-oob" to true for a command does not mean that this command > will always be run in out-of-band mode. The out-of-band quick path will > only be executed if we specify the extra "run-oob" flag when sending the > QMP request:

Re: [Qemu-devel] [PATCH v1 3/3] s390x/sclp: extend SCLP event masks to 64 bits

2018-02-21 Thread Cornelia Huck
On Wed, 21 Feb 2018 17:51:19 +0100 Claudio Imbrenda wrote: > On Wed, 21 Feb 2018 16:34:59 +0100 > Cornelia Huck wrote: > > > On Tue, 20 Feb 2018 19:45:02 +0100 > > Claudio Imbrenda wrote: > > > +static const

Re: [Qemu-devel] [PATCH v1 2/3] s390x/sclp: clean up sclp masks

2018-02-21 Thread Cornelia Huck
On Wed, 21 Feb 2018 17:42:57 +0100 Claudio Imbrenda wrote: > On Wed, 21 Feb 2018 16:20:05 +0100 > Cornelia Huck wrote: > > > On Tue, 20 Feb 2018 19:45:01 +0100 > > Claudio Imbrenda wrote: > > > diff --git

Re: [Qemu-devel] [PATCH v2 1/1] 390x/cpumodel: document S390FeatDef.bit not applicable

2018-02-21 Thread David Hildenbrand
On 21.02.2018 17:56, Halil Pasic wrote: > The 'bit' field of the 'S390FeatDef' structure is not applicable to all > its instances. Currently this field is not applicable, and remains > unused, iff the feature is of type S390_FEAT_TYPE_MISC. Having the value 0 > specified for multiple such feature

Re: [Qemu-devel] [PATCH v7 16/23] monitor: send event when command queue full

2018-02-21 Thread Stefan Hajnoczi
On Wed, Jan 24, 2018 at 01:39:50PM +0800, Peter Xu wrote: > Set maximum QMP command queue length to 8. If queue full, instead of > queue the command, we directly return a "command-dropped" event, telling > client that specific command is dropped. > > Note that this flow control mechanism is only

Re: [Qemu-devel] [PATCH v7 15/23] qmp: add new event "command-dropped"

2018-02-21 Thread Stefan Hajnoczi
On Wed, Jan 24, 2018 at 01:39:49PM +0800, Peter Xu wrote: > This event will be emitted if one QMP command is dropped. Along, > declare an enum for the reasons. > > Reviewed-by: Fam Zheng > Signed-off-by: Peter Xu > --- > qapi-schema.json | 37

Re: [Qemu-devel] [PATCH v7 14/23] monitor: separate QMP parser and dispatcher

2018-02-21 Thread Stefan Hajnoczi
On Wed, Jan 24, 2018 at 01:39:48PM +0800, Peter Xu wrote: > Originally QMP goes through these steps: > > JSON Parser --> QMP Dispatcher --> Respond > /|\(2)(3) | >(1) | \|/ (4) >+- main thread + > > This

[Qemu-devel] [RFC PATCH 1/5] kbd-state: add keyboard state tracker

2018-02-21 Thread Gerd Hoffmann
Now that most user interfaces are using QKeyCodes it is easier to have common keyboard code useable by all user interfaces. This patch adds helper code to track the state of all keyboard keys, using a bitmap indexed by QKeyCode. Modifier state is tracked too, as separate bitmap. That makes

[Qemu-devel] [RFC PATCH 2/5] kbd-state: add hotkey registry

2018-02-21 Thread Gerd Hoffmann
Add support to register hotkeys and to check whenever a given QKeyCode combined with the current modifier state is a hotkey. A hotkey can be any key combined with up to three modifier keys. Signed-off-by: Gerd Hoffmann --- include/ui/kbd-state.h | 27

Re: [Qemu-devel] [PATCH v3] specs/qcow2: Fix documentation of the compressed cluster descriptor

2018-02-21 Thread Kevin Wolf
Am 21.02.2018 um 15:08 hat Alberto Garcia geschrieben: > This patch fixes several mistakes in the documentation of the > compressed cluster descriptor: > > 1) the documentation claims that the cluster descriptor contains the >number of sectors used to store the compressed data, but what it >

[Qemu-devel] [RFC PATCH 5/5] sdl2: use only QKeyCode in sdl2_process_key()

2018-02-21 Thread Gerd Hoffmann
Small cleanup. Also drop the special backspace handling, kbd_put_qcode_console() learned to handle that meanwhile. And sdl2_process_key is never called with scon == NULL. Signed-off-by: Gerd Hoffmann --- ui/sdl2-input.c | 10 +++--- 1 file changed, 3 insertions(+), 7

[Qemu-devel] [RFC PATCH 0/5] ui: add keyboard state and hotkey tracker

2018-02-21 Thread Gerd Hoffmann
Ok, here is my alternative approach to hotkey configuration. Downside: It does *not* allow to freely choose any keys for hotkeys. Hotkeys are restricted to be one normal key combined with up to three modifiers (no modifiers is fine too). Upside: The code is simpler. We don't have to keep back

[Qemu-devel] [RFC PATCH 3/5] kbd-state: use state tracker for sdl2

2018-02-21 Thread Gerd Hoffmann
Use the new keyboard state tracked for sdl2. We can drop the modifier state tracking from sdl2. Also keyup code is simpler, the state tracker will take care to not send suspious keyup events to the guest. Signed-off-by: Gerd Hoffmann --- include/ui/sdl2.h | 2 ++

[Qemu-devel] [RFC PATCH 4/5] kbd-state: register sdl2 hotkeys

2018-02-21 Thread Gerd Hoffmann
Register SDL2 hotkeys in keyboard state tracker, use it to check for hotkeys. Drop even more modifier code. This also changes behavior a bit. The Ctrl-Alt- hotkey combinations accept both ctrl keys now. Likewise the Ctrl-Alt-Shift- mode you can enable with -alt-grab accepts both ctrl and shift

Re: [Qemu-devel] [PATCH v1 1/3] s390x/sclp: proper support of larger send and receive masks

2018-02-21 Thread Cornelia Huck
On Wed, 21 Feb 2018 17:28:49 +0100 Claudio Imbrenda wrote: > On Wed, 21 Feb 2018 16:12:59 +0100 > Cornelia Huck wrote: > > > On Tue, 20 Feb 2018 19:45:00 +0100 > > Claudio Imbrenda wrote: > > > > > The

Re: [Qemu-devel] [PATCH 0/2] Firmware blob and git submodule for Sam460ex

2018-02-21 Thread BALATON Zoltan
On Wed, 21 Feb 2018, Peter Maydell wrote: On 20 February 2018 at 20:44, Emilio G. Cota wrote: On Tue, Feb 20, 2018 at 18:31:17 +, Peter Maydell wrote: On 20 February 2018 at 18:10, BALATON Zoltan wrote: I've created a git repo for the Sam460ex u-boot

Re: [Qemu-devel] [PATCH 2/2] qcow2: Avoid memory over-allocation on compressed images

2018-02-21 Thread Eric Blake
On 02/21/2018 10:51 AM, Kevin Wolf wrote: Am 20.02.2018 um 23:24 hat Eric Blake geschrieben: When reading a compressed image, we were allocating s->cluster_data to 32*cluster_size + 512 (possibly over 64 megabytes, for an image with 2M clusters). Let's check out the history: Much later, in

  1   2   3   >