[Qemu-devel] [Bug 1416988] [NEW] Wrong signal handling in qemu-aarch64.

2015-02-02 Thread Maxim Ostapenko
Public bug reported: Running GCC 5.0 testsuite under qemu-aarch64, I noticed that tests connected with stack unwinding fail with: qemu: uncaught target signal 11 (Segmentation fault) - core dumped or run into infinite loop. Here is one example: $ /home/max/build/gcc-aarch64/gcc/xgcc -B/home/ma

Re: [Qemu-devel] QEMU segfault: Booting an overlay with backing_file over NBD: nbd.c:nbd_receive_request():L756: read failed

2015-02-02 Thread Stefan Hajnoczi
On Fri, Jan 30, 2015 at 02:32:25PM -0500, Max Reitz wrote: > Kevin, Stefan: The real problem is that block/nbd.c stores a BDRVNBDState > object in bs->opaque and passes &BDRVNBDState.client (an NbdClientSession > object) to the block/nbd-client.c functions. Those functions then receive > the BDS po

Re: [Qemu-devel] [RFC 01/10] target-arm: protect cpu_exclusive_*.

2015-02-02 Thread Frederic Konrad
On 29/01/2015 16:17, Peter Maydell wrote: On 16 January 2015 at 17:19, wrote: From: KONRAD Frederic This adds a lock to avoid multiple exclusive access at the same time in case of TCG multithread. Signed-off-by: KONRAD Frederic Hi Peter, All the same comments I had on this patch earlier

Re: [Qemu-devel] [PATCH v6 3/5] acpi: add build_append_namestring() helper

2015-02-02 Thread Igor Mammedov
On Sat, 31 Jan 2015 19:05:47 +0200 "Michael S. Tsirkin" wrote: > On Fri, Jan 30, 2015 at 12:46:41PM +0100, Igor Mammedov wrote: > > On Wed, 28 Jan 2015 17:16:17 +0200 > > "Michael S. Tsirkin" wrote: > > > > > On Wed, Jan 28, 2015 at 02:34:48PM +, Igor Mammedov wrote: > > > > Use build_appen

Re: [Qemu-devel] [RFC 01/10] target-arm: protect cpu_exclusive_*.

2015-02-02 Thread Peter Maydell
On 2 February 2015 at 08:31, Frederic Konrad wrote: >> * This is making no attempt to learn from or unify with >> the existing attempts at handling exclusives in linux-user. >> When we've done this work we should have a single >> mechanism for handling exclusives in a multithreaded >

Re: [Qemu-devel] [RFC 02/10] use a different translation block list for each cpu.

2015-02-02 Thread Frederic Konrad
On 29/01/2015 16:24, Peter Maydell wrote: On 16 January 2015 at 17:19, wrote: From: KONRAD Frederic We need a different TranslationBlock list for each core in case of multithread TCG. Signed-off-by: KONRAD Frederic --- translate-all.c | 40 ++-- 1 fil

Re: [Qemu-devel] [RFC 03/10] replace spinlock by QemuMutex.

2015-02-02 Thread Frederic Konrad
On 29/01/2015 16:25, Peter Maydell wrote: On 16 January 2015 at 17:19, wrote: From: KONRAD Frederic spinlock is only used in two cases: * cpu-exec.c: to protect TranslationBlock * mem_helper.c: for lock helper in target-i386 (which seems broken). It's a pthread_mutex_t in user-mode so

Re: [Qemu-devel] [RFC 02/10] use a different translation block list for each cpu.

2015-02-02 Thread Peter Maydell
On 2 February 2015 at 08:39, Frederic Konrad wrote: > On 29/01/2015 16:24, Peter Maydell wrote: >> >> On 16 January 2015 at 17:19, wrote: >>> >>> From: KONRAD Frederic >>> >>> We need a different TranslationBlock list for each core in case of >>> multithread >>> TCG. >>> >>> Signed-off-by: KONR

Re: [Qemu-devel] [RFC PATCH v1 00/13] CPU and Memory hotplug for PowerPC guests

2015-02-02 Thread Bharata B Rao
On Thu, Jan 29, 2015 at 06:46:30PM +0100, Andreas Färber wrote: > Hi, > > Am 08.01.2015 um 07:10 schrieb Bharata B Rao: > > This patchset enables CPU and memory hotplug support for PowerPC guests. > > > > Changes in this patchset (v1): > > > > - Based on top of Michael Roth's tree > > (https:/

Re: [Qemu-devel] [PATCH v2] vfio-pci: Fix missing unparent of dynamically allocated MemoryRegion

2015-02-02 Thread Paolo Bonzini
On 01/02/2015 17:06, Alex Williamson wrote: > Commit d8d95814609e added explicit object_unparent() calls for > dynamically allocated MemoryRegions. The VFIOMSIXInfo structure also > contains such a MemoryRegion, covering the mmap'd region of a PCI BAR > above the MSI-X table. This structure is

Re: [Qemu-devel] [PATCH v2 1/4] blockdev: Give find_block_job() an Error ** parameter

2015-02-02 Thread Markus Armbruster
Max Reitz writes: > On 2015-01-29 at 04:36, Markus Armbruster wrote: >> When find_block_job() fails, all its callers build the same Error >> object. Build it in find_block_job() instead. >> >> Signed-off-by: Markus Armbruster >> Reviewed-by: Eric Blake >> --- >> blockdev.c | 19 -

Re: [Qemu-devel] -device xen-platform crashes

2015-02-02 Thread Markus Armbruster
Stefano Stabellini writes: > On Fri, 30 Jan 2015, Markus Armbruster wrote: >> Stefano Stabellini writes: >> >> > On Thu, 29 Jan 2015, Markus Armbruster wrote: >> >> Stefano Stabellini writes: >> >> >> >> > On Thu, 29 Jan 2015, Markus Armbruster wrote: >> >> >> Reproducer: qemu -nodefaults -S

Re: [Qemu-devel] [PATCH 2/2] bootdevice: add check in restore_boot_order()

2015-02-02 Thread Markus Armbruster
Gonglei writes: > On 2015/1/30 20:32, Markus Armbruster wrote: > >> Gonglei writes: >> >>> On 2015/1/30 20:01, Markus Armbruster wrote: >>> Gonglei writes: > On 2015/1/30 15:46, Markus Armbruster wrote: > >> Gonglei writes: >> >>> On 2015/1/30 0:03, Alexander Gra

Re: [Qemu-devel] [PATCH v2 4/4] linux-user: initialize progname with error_set_progname()

2015-02-02 Thread Hitoshi Mitake
Hi Peter, Sorry for my late reply. At Thu, 22 Jan 2015 10:07:27 +, Peter Maydell wrote: > > On 22 January 2015 at 09:08, Hitoshi Mitake > wrote: > > Calling error_get_progname() in the context of qemu-x86_64 can cause > > segmentation fault because linux-user/main.c doesn't initialize its >

Re: [Qemu-devel] [PATCH v2 1/4] qemu-io: initialize progname with error_set_progname()

2015-02-02 Thread Hitoshi Mitake
At Thu, 22 Jan 2015 18:08:11 +0900, Hitoshi Mitake wrote: > > Calling error_get_progname() in the context of qemu-io can cause > segmentation fault because qemu-io doesn't initialize its progname > with error_set_progname(). This patch adds the initialization. > > Currently, the missing call of e

Re: [Qemu-devel] [PATCH] vl.c: fix -usb option assertion failure in qemu_opt_get_bool_helper()

2015-02-02 Thread Marcel Apfelbaum
On 01/31/2015 11:23 AM, Jan Kiszka wrote: On 2015-01-05 12:37, Jan Kiszka wrote: On 2015-01-05 12:22, Stefan Hajnoczi wrote: Commit 49d2e648e8087d154d8bf8b91f27c8e05e79d5a6 ("machine: remove qemu_machine_opts global list") removed option descriptions from the -machine QemuOptsList to avoid repe

Re: [Qemu-devel] [RFC 09/10] cpu: remove exit_request global.

2015-02-02 Thread Paolo Bonzini
On 29/01/2015 16:52, Peter Maydell wrote: >> > +CPU_FOREACH(cpu) { >> > +cpu->exit_loop_request = 1; >> > +} >> > } > You can't do this -- this code is a signal handler so it could > get run at any time including while the list of CPUs is being > updated. (This is why we have the

Re: [Qemu-devel] [PATCH v11 03/13] qmp: Add block-dirty-bitmap-add and block-dirty-bitmap-remove

2015-02-02 Thread Markus Armbruster
Kevin Wolf writes: > Am 30.01.2015 um 18:04 hat John Snow geschrieben: >> >> >> On 01/30/2015 09:32 AM, Kevin Wolf wrote: >> >Am 21.01.2015 um 10:34 hat Markus Armbruster geschrieben: >> >>I'm afraid I forgot much of the discussion we had before the break, and >> >>only now it's coming back, sl

Re: [Qemu-devel] [PATCH 04/19] libqos/ahci: Add command header helpers

2015-02-02 Thread Paolo Bonzini
On 30/01/2015 19:41, John Snow wrote: > +/* Construct our Command Header (set_command_header handles endianness.) > */ > +memset(&cmd, 0x00, sizeof(cmd)); > +cmd.flags = 5; /* reg_h2d_fis is 5 double-words long */ > +cmd.flags = 0x400; /* clear PxTFD.STS.BSY when done */ And

Re: [Qemu-devel] [PATCH 03/19] qtest/ahci: rename 'Command' to 'CommandHeader'

2015-02-02 Thread Paolo Bonzini
On 30/01/2015 19:41, John Snow wrote: > @@ -703,8 +703,8 @@ static void ahci_test_identify(AHCIQState *ahci) > /* Copy the existing Command #0 structure from the CLB into local memory, > * and build a new command #0. */ > memread(ahci->port[i].clb, &cmd, sizeof(cmd)); > -cmd.b

Re: [Qemu-devel] [PATCH 04/19] libqos/ahci: Add command header helpers

2015-02-02 Thread Paolo Bonzini
On 30/01/2015 19:41, John Snow wrote: > +/* Set the #cx'th command of port #px. */ > +void ahci_set_command_header(AHCIQState *ahci, uint8_t px, > + uint8_t cx, AHCICommandHeader *cmd) > +{ > +uint64_t ba = ahci->port[px].clb; > +ba += cx * sizeof(AHCICommandHe

Re: [Qemu-devel] [PATCH 09/19] qtest/ahci: Demagic ahci tests.

2015-02-02 Thread Paolo Bonzini
On 30/01/2015 19:42, John Snow wrote: > memset(&cmd, 0x00, sizeof(cmd)); > -cmd.flags = 5; /* reg_h2d_fis is 5 double-words long */ > -cmd.flags = 0x400; /* clear PxTFD.STS.BSY when done */ > -cmd.prdtl = 1; /* One PRD table entry. */ > +cmd.flags = 5;/* r

Re: [Qemu-devel] [PATCH 10/19] libqos/ahci: Add ide cmd properties

2015-02-02 Thread Paolo Bonzini
On 30/01/2015 19:42, John Snow wrote: > The "Invalid Command Sentinel" here that caps the property array is an > invalid ATA command, namely 0x01. 0x00 is NOP and 0xFF is reserved for > vendor usage, so I chose the first invalid one instead. You can use ARRAY_SIZE instead. Paolo

Re: [Qemu-devel] [PATCH 13/19] libqos/ahci: add ahci command size setters

2015-02-02 Thread Paolo Bonzini
On 30/01/2015 19:42, John Snow wrote: > +void ahci_command_set_sizes(AHCICommand *cmd, uint64_t xbytes, > +unsigned prd_size) > +{ > +/* Each PRD can describe up to 4MiB, and must not be odd. */ > +g_assert_cmphex(prd_size, <=, 4096 * 1024); > +g_assert_cmp

Re: [Qemu-devel] [PATCH 17/19] qtest/ahci: Add a macro bootup routine

2015-02-02 Thread Paolo Bonzini
On 30/01/2015 19:42, John Snow wrote: > +/** > + * Boot and fully enable the HBA device. > + * @see ahci_boot, ahci_pci_enable and ahci_hba_enable. > + */ > +static AHCIQState *ahci_macro_bootup(void) Ugly name... I would just leave out this patch. Paolo > +{ > +AHCIQState *ahci; > +a

Re: [Qemu-devel] [PATCH 19/19] qtest/ahci: Adding simple dma read-write test

2015-02-02 Thread Paolo Bonzini
On 30/01/2015 19:42, John Snow wrote: > +memwrite(ptr, tx, bufsize); > + > +/* Write this buffer to disk, then read it back to the DMA buffer. */ > +ahci_guest_io(ahci, px, CMD_WRITE_DMA, ptr, bufsize); I would qmemset the buffer here. Paolo > +ahci_guest_io(ahci, px, CMD_READ_

Re: [Qemu-devel] [PATCH 00/19] qtest/ahci: add dma test

2015-02-02 Thread Paolo Bonzini
On 30/01/2015 19:41, John Snow wrote: > Add a simple DMA r/w test to ahci-test. > > Oh, and for the first 18 patches, refactor everything into helpers so > that each ahci_test isn't a thousand lines long. > > This patch depends upon the "ahci test preliminary refactoring" series > upstream, whi

Re: [Qemu-devel] [v2][PATCH] libxl: add one machine property to support IGD GFX passthrough

2015-02-02 Thread Ian Campbell
On Mon, 2015-02-02 at 09:17 +0800, Tiejun Chen wrote: > When we're working to support IGD GFX passthrough with qemu > upstream, instead of "-gfx_passthru" we'd like to make that > a machine option, "-machine xxx,-igd-passthru=on". This need > to bring a change on tool side. >From which Qemu versio

[Qemu-devel] [v4 03/13] migration: Add the framework of multi-thread decompression

2015-02-02 Thread Liang Li
Add the code to create and destroy the multiple threads those will be used to do data decompression. Left some functions empty just to keep clearness, and the code will be added later. Signed-off-by: Liang Li Signed-off-by: Yang Zhang --- arch_init.c | 75 +

[Qemu-devel] [v4 04/13] qemu-file: Add compression functions to QEMUFile

2015-02-02 Thread Liang Li
qemu_put_compression_data() compress the data and put it to QEMUFile. qemu_put_qemu_file() put the data in the buffer of source QEMUFile to destination QEMUFile. Signed-off-by: Liang Li Signed-off-by: Yang Zhang --- include/migration/qemu-file.h | 3 +++ migration/qemu-file.c | 39

[Qemu-devel] [v4 01/13] docs: Add a doc about multiple thread compression

2015-02-02 Thread Liang Li
Give some details about the multiple thread (de)compression and how to use it in live migration. Signed-off-by: Liang Li Signed-off-by: Yang Zhang Reviewed-by: Dr.David Alan Gilbert --- docs/multi-thread-compression.txt | 149 ++ 1 file changed, 149 insertio

[Qemu-devel] [v4 13/13] migration: Add command to query migration parameter

2015-02-02 Thread Liang Li
Add the qmp and hmp commands to query the parameters used in live migration. Signed-off-by: Liang Li Signed-off-by: Yang Zhang --- hmp-commands.hx | 2 ++ hmp.c | 21 + hmp.h | 1 + migration/migration.c | 27 ++

[Qemu-devel] [v4 08/13] migration: Add the core code of multi-thread compression

2015-02-02 Thread Liang Li
Implement the core logic of the multiple thread compression. At this point, multiple thread compression can't co-work with xbzrle yet. Signed-off-by: Liang Li Signed-off-by: Yang Zhang --- arch_init.c | 167 +--- 1 file changed, 159 insert

[Qemu-devel] [v4 07/13] migration: Split the function ram_save_page

2015-02-02 Thread Liang Li
Split the function ram_save_page for code reuse purpose. Signed-off-by: Liang Li Signed-off-by: Yang Zhang --- arch_init.c | 102 +--- 1 file changed, 56 insertions(+), 46 deletions(-) diff --git a/arch_init.c b/arch_init.c index 500f299.

[Qemu-devel] [v4 05/13] arch_init: Alloc and free data struct for compression

2015-02-02 Thread Liang Li
Define the data structure and variables used to do multiple thread compression, and add the code to initialize and free them. Signed-off-by: Liang Li Signed-off-by: Yang Zhang --- arch_init.c | 34 +- 1 file changed, 33 insertions(+), 1 deletion(-) diff --git a/

[Qemu-devel] [v4 12/13] migration: Add command to set migration parameter

2015-02-02 Thread Liang Li
Add the qmp and hmp commands to tune the parameters used in live migration. Signed-off-by: Liang Li Signed-off-by: Yang Zhang --- hmp-commands.hx | 15 ++ hmp.c | 35 ++ hmp.h | 3 ++ include/migration/mi

[Qemu-devel] [v4 10/13] migration: Add the core code for decompression

2015-02-02 Thread Liang Li
Implement the core logic of multiple thread decompression, the decompression can work now. Signed-off-by: Liang Li Signed-off-by: Yang Zhang --- arch_init.c | 49 +++-- 1 file changed, 47 insertions(+), 2 deletions(-) diff --git a/arch_init.c b/arch_

[Qemu-devel] [PATCH v4 0/13] migration: Add a new feature to do live migration

2015-02-02 Thread Liang Li
This feature can help to reduce the data transferred about 60%, and the migration time can also be reduced about 70%. Summary of changed from v3->v4 -Update the test data in the document -Fix some typo errors -Use compressBound instead of MACRO define -Optimize the perfor

[Qemu-devel] [v4 09/13] migration: Make compression co-work with xbzrle

2015-02-02 Thread Liang Li
Now, multiple thread compression can co-work with xbzrle. when xbzrle is on, multiple thread compression will only work at the first round of RAM data sync. Signed-off-by: Liang Li Signed-off-by: Yang Zhang --- arch_init.c | 11 ++- 1 file changed, 10 insertions(+), 1 deletion(-) diff

[Qemu-devel] [v4 11/13] migration: Add interface to control compression

2015-02-02 Thread Liang Li
The multiple compression threads can be turned on/off through qmp and hmp interface before doing live migration. Signed-off-by: Liang Li Signed-off-by: Yang Zhang Reviewed-by: Dr.David Alan Gilbert --- migration/migration.c | 7 +-- qapi-schema.json | 7 ++- 2 files changed, 11 in

[Qemu-devel] [v4 06/13] arch_init: Add and free data struct for decompression

2015-02-02 Thread Liang Li
Define the data structure and variables used to do multiple thread decompression, and add the code to initialize and free them. Signed-off-by: Liang Li Signed-off-by: Yang Zhang --- arch_init.c | 13 - 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/arch_init.c b/arch_

[Qemu-devel] [v4 02/13] migration: Add the framework of multi-thread compression

2015-02-02 Thread Liang Li
Add the code to create and destroy the multiple threads those will be used to do data compression. Left some functions empty to keep clearness, and the code will be added later. Signed-off-by: Liang Li Signed-off-by: Yang Zhang --- arch_init.c | 79

Re: [Qemu-devel] [PATCH v2 1/4] qemu-io: initialize progname with error_set_progname()

2015-02-02 Thread Kevin Wolf
Am 02.02.2015 um 10:51 hat Hitoshi Mitake geschrieben: > At Thu, 22 Jan 2015 18:08:11 +0900, > Hitoshi Mitake wrote: > > > > Calling error_get_progname() in the context of qemu-io can cause > > segmentation fault because qemu-io doesn't initialize its progname > > with error_set_progname(). This p

Re: [Qemu-devel] [PATCH 2/2] atapi migration: Throw recoverable error to avoid recovery

2015-02-02 Thread Kevin Wolf
Am 16.01.2015 um 18:28 hat John Snow geschrieben: > > > On 12/09/2014 01:15 PM, Dr. David Alan Gilbert (git) wrote: > >From: "Dr. David Alan Gilbert" > > > >(With the previous atapi_dma flag recovery) > >If migration happens between the ATAPI command being written and the > >bmdma being started,

Re: [Qemu-devel] [v2][PATCH] libxl: add one machine property to support IGD GFX passthrough

2015-02-02 Thread Wei Liu
On Mon, Feb 02, 2015 at 09:17:23AM +0800, Tiejun Chen wrote: > When we're working to support IGD GFX passthrough with qemu > upstream, instead of "-gfx_passthru" we'd like to make that > a machine option, "-machine xxx,-igd-passthru=on". This need > to bring a change on tool side. > > Signed-off-b

Re: [Qemu-devel] [RFC PATCH v8 08/21] cpu: replay instructions sequence

2015-02-02 Thread Pavel Dovgaluk
> From: Paolo Bonzini [mailto:pbonz...@redhat.com] > On 22/01/2015 09:52, Pavel Dovgalyuk wrote: > > This patch adds calls to replay functions into the icount setup block. > > In record mode number of executed instructions is written to the log. > > In replay mode number of istructions to execute i

Re: [Qemu-devel] [RFC PATCH v8 08/21] cpu: replay instructions sequence

2015-02-02 Thread Paolo Bonzini
On 02/02/2015 13:28, Pavel Dovgaluk wrote: >>> > > cpu->exception_index = EXCP_INTERRUPT; >>> > > next_tb = 0; >>> > > +qemu_notify_event(); >> > >> > Why is this needed? > It is needed to wake up iothread in r

Re: [Qemu-devel] [RFC PATCH v8 08/21] cpu: replay instructions sequence

2015-02-02 Thread Pavel Dovgaluk
> From: Paolo Bonzini [mailto:pbonz...@redhat.com] > On 02/02/2015 13:28, Pavel Dovgaluk wrote: > >>> > > cpu->exception_index = EXCP_INTERRUPT; > >>> > > next_tb = 0; > >>> > > +qemu_notify_event(); > >> > > >> >

Re: [Qemu-devel] [PATCH V11 2/3] i386: Add a Virtual Machine Generation ID device

2015-02-02 Thread Igor Mammedov
On Sun, 01 Feb 2015 14:56:26 +0200 Gal Hammer wrote: > On 22/01/2015 15:52, Igor Mammedov wrote: > > On Tue, 16 Dec 2014 17:50:43 +0200 > > Gal Hammer wrote: > > > >> Based on Microsoft's sepecifications (paper can be dowloaded from > >> http://go.microsoft.com/fwlink/?LinkId=260709), add a devi

Re: [Qemu-devel] [v2][PATCH] libxl: add one machine property to support IGD GFX passthrough

2015-02-02 Thread Ian Jackson
Wei Liu writes ("Re: [v2][PATCH] libxl: add one machine property to support IGD GFX passthrough"): > On Mon, Feb 02, 2015 at 09:17:23AM +0800, Tiejun Chen wrote: > > When we're working to support IGD GFX passthrough with qemu > > upstream, instead of "-gfx_passthru" we'd like to make that > > a ma

Re: [Qemu-devel] [RFC 09/10] cpu: remove exit_request global.

2015-02-02 Thread Peter Maydell
On 2 February 2015 at 10:03, Paolo Bonzini wrote: >> You can't do this -- this code is a signal handler so it could >> get run at any time including while the list of CPUs is being >> updated. (This is why we have the exit_request flag in the >> first place rather than just setting the exit_reques

Re: [Qemu-devel] [PATCH V11 2/3] i386: Add a Virtual Machine Generation ID device

2015-02-02 Thread Gal Hammer
On 02/02/2015 14:46, Igor Mammedov wrote: On Sun, 01 Feb 2015 14:56:26 +0200 Gal Hammer wrote: On 22/01/2015 15:52, Igor Mammedov wrote: On Tue, 16 Dec 2014 17:50:43 +0200 Gal Hammer wrote: Based on Microsoft's sepecifications (paper can be dowloaded from http://go.microsoft.com/fwlink/?Li

Re: [Qemu-devel] [RFC 09/10] cpu: remove exit_request global.

2015-02-02 Thread Paolo Bonzini
On 02/02/2015 14:12, Peter Maydell wrote: > > In particular, you can do it while you are under the big QEMU lock. > > ...but this is a signal handler, so we can't guarantee that the > thread holds the big lock. > > ...and if we can iterate over CPU lists in signal handlers, > the correct approa

Re: [Qemu-devel] [RFC PATCH v8 08/21] cpu: replay instructions sequence

2015-02-02 Thread Paolo Bonzini
On 02/02/2015 13:42, Pavel Dovgaluk wrote: >> From: Paolo Bonzini [mailto:pbonz...@redhat.com] >> On 02/02/2015 13:28, Pavel Dovgaluk wrote: >>> cpu->exception_index = EXCP_INTERRUPT; >>> next_tb = 0; >>> +

Re: [Qemu-devel] [PATCH 7/7] block/raw-posix: set max_write_zeroes to INT_MAX for regular files

2015-02-02 Thread Kevin Wolf
Am 30.01.2015 um 09:42 hat Denis V. Lunev geschrieben: > fallocate() works fine and could handle properly with arbitrary size > requests. There is no sense to reduce the amount of space to fallocate. > The bigger is the size, the better is the performance as the amount of > journal updates is reduc

Re: [Qemu-devel] [PATCH v6 0/7] eliminate data write in bdrv_write_zeroes on Linux in raw-posix.c

2015-02-02 Thread Kevin Wolf
Am 30.01.2015 um 09:42 hat Denis V. Lunev geschrieben: > I have performed several tests with non-aligned fallocate calls and > in all cases (with non-aligned fallocates) Linux performs fine, i.e. > areas are zeroed correctly. Checks were made on > Linux 3.16.0-28-generic #38-Ubuntu SMP > > This sh

Re: [Qemu-devel] [RFC PATCH v8 09/21] replay: interrupts and exceptions

2015-02-02 Thread Pavel Dovgaluk
> From: Paolo Bonzini [mailto:pbonz...@redhat.com] > On 22/01/2015 09:52, Pavel Dovgalyuk wrote: > > +if (replay_mode == REPLAY_MODE_RECORD) { > > +replay_save_instructions(); > > +replay_put_event(EVENT_EXCEPTION); > > +return true; > > Missing mutex lock/unlock. I th

[Qemu-devel] [PATCH v4 2/5] hw/virtio-blk: add a constant for max number of merged requests

2015-02-02 Thread Peter Lieven
As it was not obvious (at least for me) where the 32 comes from; add a constant for it. Signed-off-by: Peter Lieven Reviewed-by: Eric Blake Reviewed-by: Max Reitz --- hw/block/virtio-blk.c | 2 +- include/hw/virtio/virtio-blk.h | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-

[Qemu-devel] [PATCH v4 4/5] virtio-blk: introduce multiread

2015-02-02 Thread Peter Lieven
this patch finally introduces multiread support to virtio-blk. While multiwrite support was there for a long time, read support was missing. The complete merge logic is moved into virtio-blk.c which has been the only user of request merging ever since. This is required to be able to merge chunks o

[Qemu-devel] [PATCH v4 0/5] this series adds the long missing multiread support to virtio-blk.

2015-02-02 Thread Peter Lieven
some remarks: - i introduced rd_merged and wr_merged block accounting stats to blockstats as a generic interface which can be set from any driver that will introduce multirequest merging in the future. - the old multiwrite interface is still there and might be removed. v3->v4: - added a p

[Qemu-devel] [PATCH v4 3/5] block-backend: expose bs->bl.max_transfer_length

2015-02-02 Thread Peter Lieven
Signed-off-by: Peter Lieven Reviewed-by: Max Reitz --- block/block-backend.c | 5 + include/sysemu/block-backend.h | 1 + 2 files changed, 6 insertions(+) diff --git a/block/block-backend.c b/block/block-backend.c index d00c129..c28e240 100644 --- a/block/block-backend.c +++ b/bloc

Re: [Qemu-devel] [PATCH V11 2/3] i386: Add a Virtual Machine Generation ID device

2015-02-02 Thread Igor Mammedov
On Mon, 02 Feb 2015 15:13:39 +0200 Gal Hammer wrote: > On 02/02/2015 14:46, Igor Mammedov wrote: > > On Sun, 01 Feb 2015 14:56:26 +0200 > > Gal Hammer wrote: > > > >> On 22/01/2015 15:52, Igor Mammedov wrote: > >>> On Tue, 16 Dec 2014 17:50:43 +0200 > >>> Gal Hammer wrote: > >>> > Based on

Re: [Qemu-devel] [PATCH v2 1/1] qemu-img: Add QEMU_PKGVERSION to QEMU_IMG_VERSION

2015-02-02 Thread Kevin Wolf
Am 09.01.2015 um 16:17 hat Don Slutz geschrieben: > This is the same way vl.c handles this. > > Signed-off-by: Don Slutz Thanks, applied to the block branch. Kevin

Re: [Qemu-devel] [PATCH 7/7] block/raw-posix: set max_write_zeroes to INT_MAX for regular files

2015-02-02 Thread Peter Lieven
Am 02.02.2015 um 14:23 schrieb Kevin Wolf: Am 30.01.2015 um 09:42 hat Denis V. Lunev geschrieben: fallocate() works fine and could handle properly with arbitrary size requests. There is no sense to reduce the amount of space to fallocate. The bigger is the size, the better is the performance as

[Qemu-devel] [PATCH v4 1/5] block: add accounting for merged requests

2015-02-02 Thread Peter Lieven
Signed-off-by: Peter Lieven Reviewed-by: Eric Blake Reviewed-by: Max Reitz --- block.c| 2 ++ block/accounting.c | 7 +++ block/qapi.c | 2 ++ hmp.c | 6 +- include/block/accounting.h | 3 +++ qapi/block-core.json

Re: [Qemu-devel] [PATCH] qed: Really remove unused field QEDAIOCB.finished

2015-02-02 Thread Kevin Wolf
Am 28.01.2015 um 02:51 hat Fam Zheng geschrieben: > The commit 533ffb17a that removed qed_aiocb_info.cancel said to remove > this but didn't do it. > > Signed-off-by: Fam Zheng Thanks, applied to the block branch. Kevin

[Qemu-devel] [PATCH v4 5/5] virtio-blk: add a knob to disable request merging

2015-02-02 Thread Peter Lieven
this adds a knob to disable request merging for debugging or benchmarks if dedired. Signed-off-by: Peter Lieven --- hw/block/virtio-blk.c | 5 - include/hw/virtio/virtio-blk.h | 1 + 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/hw/block/virtio-blk.c b/hw/block/virt

[Qemu-devel] qemu 2.2.1 ?

2015-02-02 Thread Peter Lieven
Hi, are there any plans to release a 2.2 maintainance release anytime soon? Thanks, Peter

Re: [Qemu-devel] [PATCH 7/7] block/raw-posix: set max_write_zeroes to INT_MAX for regular files

2015-02-02 Thread Kevin Wolf
Am 02.02.2015 um 14:55 hat Peter Lieven geschrieben: > Am 02.02.2015 um 14:23 schrieb Kevin Wolf: > >Am 30.01.2015 um 09:42 hat Denis V. Lunev geschrieben: > >>fallocate() works fine and could handle properly with arbitrary size > >>requests. There is no sense to reduce the amount of space to fallo

Re: [Qemu-devel] [PATCH v2 1/4] qemu-io: initialize progname with error_set_progname()

2015-02-02 Thread Hitoshi Mitake
At Mon, 2 Feb 2015 12:36:00 +0100, Kevin Wolf wrote: > > Am 02.02.2015 um 10:51 hat Hitoshi Mitake geschrieben: > > At Thu, 22 Jan 2015 18:08:11 +0900, > > Hitoshi Mitake wrote: > > > > > > Calling error_get_progname() in the context of qemu-io can cause > > > segmentation fault because qemu-io d

Re: [Qemu-devel] [PATCH] tun: orphan an skb on tx

2015-02-02 Thread Steffen Klassert
On Mon, Feb 02, 2015 at 07:27:10AM +, David Woodhouse wrote: > On Sun, 2015-02-01 at 21:07 -0800, David Miller wrote: > > > We might as well have not have implemented the IPSEC stack at all, > > because as a result of the userland VPN stuff our IPSEC stack is > > largely unused except by a ver

Re: [Qemu-devel] [PATCH RFC v6 18/20] virtio: support revision-specific features

2015-02-02 Thread Cornelia Huck
On Sun, 1 Feb 2015 23:29:20 +0200 "Michael S. Tsirkin" wrote: > On Fri, Jan 30, 2015 at 03:08:08PM +0100, Cornelia Huck wrote: > > On Wed, 7 Jan 2015 21:10:07 +0200 > > "Michael S. Tsirkin" wrote: > > > > > On Wed, Jan 07, 2015 at 05:22:32PM +0100, Cornelia Huck wrote: > > > > On Sun, 28 Dec 20

Re: [Qemu-devel] [PATCH 7/7] block/raw-posix: set max_write_zeroes to INT_MAX for regular files

2015-02-02 Thread Peter Lieven
Am 02.02.2015 um 15:04 schrieb Kevin Wolf: Am 02.02.2015 um 14:55 hat Peter Lieven geschrieben: Am 02.02.2015 um 14:23 schrieb Kevin Wolf: Am 30.01.2015 um 09:42 hat Denis V. Lunev geschrieben: fallocate() works fine and could handle properly with arbitrary size requests. There is no sense to

Re: [Qemu-devel] [PATCH 7/7] block/raw-posix: set max_write_zeroes to INT_MAX for regular files

2015-02-02 Thread Kevin Wolf
Am 02.02.2015 um 15:12 hat Peter Lieven geschrieben: > Am 02.02.2015 um 15:04 schrieb Kevin Wolf: > >Am 02.02.2015 um 14:55 hat Peter Lieven geschrieben: > >>Am 02.02.2015 um 14:23 schrieb Kevin Wolf: > >>>Am 30.01.2015 um 09:42 hat Denis V. Lunev geschrieben: > fallocate() works fine and could

Re: [Qemu-devel] [RFC PATCH v8 09/21] replay: interrupts and exceptions

2015-02-02 Thread Paolo Bonzini
On 02/02/2015 14:50, Pavel Dovgaluk wrote: > I think not. We just have to write number of already executed instructions. > This number is not linked to exception event. They could be read in replay > while > processing some other event. > I was referring to replay_put_event(EVENT_EXCEPTION) o

Re: [Qemu-devel] [PATCH 7/7] block/raw-posix: set max_write_zeroes to INT_MAX for regular files

2015-02-02 Thread Peter Lieven
Am 02.02.2015 um 15:16 schrieb Kevin Wolf: Am 02.02.2015 um 15:12 hat Peter Lieven geschrieben: Am 02.02.2015 um 15:04 schrieb Kevin Wolf: Am 02.02.2015 um 14:55 hat Peter Lieven geschrieben: Am 02.02.2015 um 14:23 schrieb Kevin Wolf: Am 30.01.2015 um 09:42 hat Denis V. Lunev geschrieben: fa

Re: [Qemu-devel] [PATCH] Fix ABI incompatibility between Qemu-aarch64 and Linux Kernel in signal handling.

2015-02-02 Thread Peter Maydell
On 2 February 2015 at 08:23, Maxim Ostapenko wrote: > Sorry, missed ML. You missed qemu-devel as well :-) > On 02/02/2015 12:20 PM, Maxim Ostapenko wrote: >> >> Hi, >> >> this patch fixes https://bugs.launchpad.net/qemu/+bug/1416988. >> >> There is a small ABI incompatibility between Qemu-aarch6

Re: [Qemu-devel] [RFC PATCH v8 00/21] Deterministic replay core

2015-02-02 Thread Paolo Bonzini
On 22/01/2015 09:51, Pavel Dovgalyuk wrote: > These patches include only core function of the replay, > excluding the support for replaying serial, audio, network, and USB devices' > operations. Reverse debugging and monitor commands were also excluded to > be submitted later as separate patches.

Re: [Qemu-devel] [PULL 00/11] RCU, scsi, modules, icount changes for 2015-01-30

2015-02-02 Thread Peter Maydell
On 30 January 2015 at 15:19, Paolo Bonzini wrote: > The following changes since commit 83761b9244ad2ed39d3cfabe8a0e901ab906f7bf: > > Merge remote-tracking branch 'remotes/riku/tags/pull-linux-user-20150127' > into staging (2015-01-27 22:25:56 +) > > are available in the git repository at: >

Re: [Qemu-devel] [PATCH 7/7] block/raw-posix: set max_write_zeroes to INT_MAX for regular files

2015-02-02 Thread Denis V. Lunev
On 02/02/15 17:20, Peter Lieven wrote: Am 02.02.2015 um 15:16 schrieb Kevin Wolf: Am 02.02.2015 um 15:12 hat Peter Lieven geschrieben: Am 02.02.2015 um 15:04 schrieb Kevin Wolf: Am 02.02.2015 um 14:55 hat Peter Lieven geschrieben: Am 02.02.2015 um 14:23 schrieb Kevin Wolf: Am 30.01.2015 um 0

[Qemu-devel] [PATCH] block: change default for discard and write zeroes to INT_MAX

2015-02-02 Thread Peter Lieven
do not trim requests if the driver does not supply a limit through BlockLimits. For write zeroes we still keep a limit for the unsupported path to avoid allocating a big bounce buffer. Suggested-by: Kevin Wolf Suggested-by: Denis V. Lunev Signed-off-by: Peter Lieven --- block.c | 16 --

Re: [Qemu-devel] [PATCH 7/7] block/raw-posix: set max_write_zeroes to INT_MAX for regular files

2015-02-02 Thread Kevin Wolf
Am 02.02.2015 um 15:20 hat Peter Lieven geschrieben: > Am 02.02.2015 um 15:16 schrieb Kevin Wolf: > >Am 02.02.2015 um 15:12 hat Peter Lieven geschrieben: > >>Am 02.02.2015 um 15:04 schrieb Kevin Wolf: > >>>Am 02.02.2015 um 14:55 hat Peter Lieven geschrieben: > Am 02.02.2015 um 14:23 schrieb Kev

Re: [Qemu-devel] [PATCH] Fix ABI incompatibility between Qemu-aarch64 and Linux Kernel in signal handling.

2015-02-02 Thread Maxim Ostapenko
Peter, thank you for review and sorry for sign. I've updated the patch, is it ok now? From 5b035df58f9f17e64b35311b6b5f55097c7f8ce1 Mon Sep 17 00:00:00 2001 From: Max Ostapenko Date: Mon, 2 Feb 2015 12:03:20 +0400 Subject: [PATCH] linux-user: wrong TARGET_SI_PAD_SIZE value for some targets.

Re: [Qemu-devel] [PULL 00/11] RCU, scsi, modules, icount changes for 2015-01-30

2015-02-02 Thread Paolo Bonzini
On 02/02/2015 15:36, Peter Maydell wrote: > (Strictly speaking "local" isn't POSIX sh, but dash seems to cope > with it, which is the major non-POSIX shell, and we have a couple > of instances in configure already. Still, why do we need these > variables to be local?) Just for cleanliness; they

Re: [Qemu-devel] [PATCH] Fix ABI incompatibility between Qemu-aarch64 and Linux Kernel in signal handling.

2015-02-02 Thread Peter Maydell
On 2 February 2015 at 13:52, Maxim Ostapenko wrote: > Peter, > > thank you for review and sorry for sign. I've updated the patch, is it ok > now? The code looks ok, but... > From 5b035df58f9f17e64b35311b6b5f55097c7f8ce1 Mon Sep 17 00:00:00 2001 > From: Max Ostapenko > Date: Mon, 2 Feb 2015 12:0

Re: [Qemu-devel] [PULL 00/11] RCU, scsi, modules, icount changes for 2015-01-30

2015-02-02 Thread Peter Maydell
On 2 February 2015 at 14:55, Paolo Bonzini wrote: > and if it still fails, catch a backtrace of all threads? (gdb) thread apply all backtrace Thread 9 (process 42110): #0 0x7fff94a94746 in __psynch_mutexwait () #1 0x7fff968df779 in _pthread_mutex_lock () #2 0x00010880a589 in qemu_

[Qemu-devel] [PATCH v2] Fix ABI incompatibility between Qemu-aarch64 and Linux Kernel in signal handling.

2015-02-02 Thread Maxim Ostapenko
Thanks again, I've updated the patch. Is this correct now? -Maxim From 5b035df58f9f17e64b35311b6b5f55097c7f8ce1 Mon Sep 17 00:00:00 2001 From: Max Ostapenko Date: Mon, 2 Feb 2015 12:03:20 +0400 Subject: [PATCH] linux-user: wrong TARGET_SI_PAD_SIZE value for some targets. Fix TARGET_SI_PAD_S

Re: [Qemu-devel] [PATCH v2] Fix ABI incompatibility between Qemu-aarch64 and Linux Kernel in signal handling.

2015-02-02 Thread Peter Maydell
On 2 February 2015 at 14:18, Maxim Ostapenko wrote: > Thanks again, > > I've updated the patch. Is this correct now? Yes, and you can have my Reviewed-by: Peter Maydell (though I notice you ignored the bit about sending a separate email, not a followup. Still, I expect that Riku or the -trivial

[Qemu-devel] [PATCH] ui/vnc: optimize full scanline updates

2015-02-02 Thread Peter Lieven
in case we send and update for a complete scanline increment the y offset to avoid running to find_next_bit for that lines twice. Signed-off-by: Peter Lieven --- ui/vnc.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/ui/vnc.c b/ui/vnc.c index a742c90..6fa2ee7 100644 --- a/ui/vnc.c ++

Re: [Qemu-devel] [PATCH] tun: orphan an skb on tx

2015-02-02 Thread David Woodhouse
On Mon, 2015-02-02 at 09:24 +0100, Steffen Klassert wrote: > > Maybe you want to use a virtual tunnel interface (vti) what we have > already. Everything that is routed through such an interface is > guaranteed to be either encrypted if a matching xfrm state is present > or dropped. Same on the rce

Re: [Qemu-devel] [PATCH 7/7] block/raw-posix: set max_write_zeroes to INT_MAX for regular files

2015-02-02 Thread Denis V. Lunev
On 02/02/15 17:49, Kevin Wolf wrote: Am 02.02.2015 um 15:20 hat Peter Lieven geschrieben: Am 02.02.2015 um 15:16 schrieb Kevin Wolf: Am 02.02.2015 um 15:12 hat Peter Lieven geschrieben: Am 02.02.2015 um 15:04 schrieb Kevin Wolf: Am 02.02.2015 um 14:55 hat Peter Lieven geschrieben: Am 02.02.2

Re: [Qemu-devel] [PATCH v2] qga: add guest-set-admin-password command

2015-02-02 Thread Daniel P. Berrange
Ping On Mon, Jan 12, 2015 at 03:58:14PM +, Daniel P. Berrange wrote: > Add a new 'guest-set-admin-password' command for changing the > root/administrator password. This command is needed to allow > OpenStack to support its API for changing the admin password > on a running guest. > > Accepts

Re: [Qemu-devel] [PATCH] tun: orphan an skb on tx

2015-02-02 Thread David Woodhouse
On Mon, 2015-02-02 at 16:23 +0100, Phil Sutter wrote: > Since you want to provide connectivity over HTTPS which is not possible > in kernel space, you are stuck with keeping the tun device. So the > packet flow in that case is identical to how e.g. OpenVPN does it: > > - tunX holds default route >

[Qemu-devel] [PATCH] qemu-thread: fix qemu_event without futexes

2015-02-02 Thread Paolo Bonzini
This had a possible deadlock that was visible with rcutorture. qemu_event_setqemu_event_wait cmpxchg reads FREE, writes BUSY fute

Re: [Qemu-devel] [PATCH v2 06/47] acpi: add acpi_name() & acpi_name_decl() term

2015-02-02 Thread Igor Mammedov
On Fri, 23 Jan 2015 15:42:30 +0200 "Michael S. Tsirkin" wrote: > On Fri, Jan 23, 2015 at 02:32:45PM +0100, Igor Mammedov wrote: > > On Fri, 23 Jan 2015 10:59:48 +0200 > > "Michael S. Tsirkin" wrote: > > > > > On Thu, Jan 22, 2015 at 02:49:50PM +, Igor Mammedov wrote: > > > > Signed-off-by:

Re: [Qemu-devel] [PATCH v4 0/5] this series adds the long missing multiread support to virtio-blk.

2015-02-02 Thread Kevin Wolf
Am 02.02.2015 um 14:52 hat Peter Lieven geschrieben: > some remarks: > - i introduced rd_merged and wr_merged block accounting stats to >blockstats as a generic interface which can be set from any >driver that will introduce multirequest merging in the future. > - the old multiwrite inter

Re: [Qemu-devel] [PATCH] block: change default for discard and write zeroes to INT_MAX

2015-02-02 Thread Kevin Wolf
Am 02.02.2015 um 15:48 hat Peter Lieven geschrieben: > do not trim requests if the driver does not supply a limit > through BlockLimits. For write zeroes we still keep a limit > for the unsupported path to avoid allocating a big bounce buffer. > > Suggested-by: Kevin Wolf > Suggested-by: Denis V.

Re: [Qemu-devel] [PATCH] block: change default for discard and write zeroes to INT_MAX

2015-02-02 Thread Denis V. Lunev
On 02/02/15 19:13, Kevin Wolf wrote: Am 02.02.2015 um 15:48 hat Peter Lieven geschrieben: do not trim requests if the driver does not supply a limit through BlockLimits. For write zeroes we still keep a limit for the unsupported path to avoid allocating a big bounce buffer. Suggested-by: Kevin

[Qemu-devel] [PULL v2 00/12] RCU, scsi, modules, icount changes for 2015-01-30

2015-02-02 Thread Paolo Bonzini
The following changes since commit 83761b9244ad2ed39d3cfabe8a0e901ab906f7bf: Merge remote-tracking branch 'remotes/riku/tags/pull-linux-user-20150127' into staging (2015-01-27 22:25:56 +) are available in the git repository at: git://github.com/bonzini/qemu.git tags/for-upstream for y

Re: [Qemu-devel] [PULL 00/11] RCU, scsi, modules, icount changes for 2015-01-30

2015-02-02 Thread Paolo Bonzini
On 02/02/2015 16:03, Peter Maydell wrote: > On 2 February 2015 at 14:55, Paolo Bonzini wrote: >> and if it still fails, catch a backtrace of all threads? Whoa, this has been broken for a long, long time. Paolo > (gdb) thread apply all backtrace > > Thread 9 (process 42110): > #0 0x7fff9

  1   2   >