Re: [Qemu-devel] [PATCH 07/20] target/arm: Fix is_a64 for user-only

2018-08-17 Thread Peter Maydell
On 17 August 2018 at 17:10, Laurent Desnogues wrote: > Hello, > > On Fri, Aug 17, 2018 at 6:04 PM Peter Maydell > wrote: >> And again. I don't want to pepper the code with ifdefs if >> we can do the right thing without them. > > FWIW I find it more readable with the ifdef's (here and in the >

Re: [Qemu-devel] [PATCH v2 21/60] json: Reject invalid UTF-8 sequences

2018-08-17 Thread Eric Blake
On 08/17/2018 10:05 AM, Markus Armbruster wrote: We reject bytes that can't occur in valid UTF-8 (\xC0..\xC1, \xF5..\xFF in the lexer. That's insufficient; there's plenty of invalid UTF-8 not containing these bytes, as demonstrated by check-qjson: * Malformed sequences - Unexpected

Re: [Qemu-devel] [PATCH 06/20] target/arm: Fix arm_current_el for user-only

2018-08-17 Thread Peter Maydell
On 9 August 2018 at 05:21, Richard Henderson wrote: > Saves about 12k code size in qemu-aarch64. > > Signed-off-by: Richard Henderson > --- > target/arm/cpu.h | 4 > 1 file changed, 4 insertions(+) > > diff --git a/target/arm/cpu.h b/target/arm/cpu.h > index 2d6d7d03aa..aedaf2631e 100644 >

Re: [Qemu-devel] [PATCH v2 28/60] json: Fix \uXXXX for surrogate pairs

2018-08-17 Thread Eric Blake
On 08/17/2018 10:05 AM, Markus Armbruster wrote: The JSON parser treats each half of a surrogate pair as unpaired surrogate. Fix it to recognize surrogate pairs. Signed-off-by: Markus Armbruster Reviewed-by: Eric Blake I might have dropped the R-b, to ensure the changes since v1 get

Re: [Qemu-devel] [PATCH v2 19/60] json: Tighten and simplify qstring_from_escaped_str()'s loop

2018-08-17 Thread Eric Blake
On 08/17/2018 10:05 AM, Markus Armbruster wrote: Simplify loop control, and assert that the string ends with the appropriate quote (the lexer ensures it does). Signed-off-by: Markus Armbruster --- qobject/json-parser.c | 30 +++--- 1 file changed, 7 insertions(+), 23

Re: [Qemu-devel] [PATCH 0/7] discard blockstats

2018-08-17 Thread Paolo Bonzini
On 20/11/2017 17:50, Anton Nefedov wrote: > qmp query-blockstats provides stats info for write/read/flush ops. > > Patches 1-5 implement the similar for discard (unmap) command for scsi > and ide disks. > Discard stat "unmap_ops / unmap_bytes" is supposed to account the ops that > have completed

Re: [Qemu-devel] [RFC v4 2/6] acpi-build: allocate mcfg for pxb-pcie host bridges

2018-08-17 Thread Marcel Apfelbaum
Hi Zihan, On 08/09/2018 09:33 AM, Zihan Yang wrote: Allocate new segment for pxb-pcie host bridges in MCFG table, and reserve corresponding MCFG space for them. This allows user-defined pxb-pcie host bridges to be placed in different pci domain than q35 host. The pci_host_bridges list is

Re: [Qemu-devel] [PATCH v9 00/84] Add nanoMIPS support to QEMU

2018-08-17 Thread no-reply
Hi, This series seems to have some coding style problems. See output below for more information: Type: series Message-id: 1534431497-1385-1-git-send-email-aleksandar.marko...@rt-rk.com Subject: [Qemu-devel] [PATCH v9 00/84] Add nanoMIPS support to QEMU === TEST SCRIPT BEGIN === #!/bin/bash

Re: [Qemu-devel] [PATCH v2 2/3] scripts: add render_block_graph function for QEMUMachine

2018-08-17 Thread Eduardo Habkost
On Fri, Aug 17, 2018 at 09:04:39PM +0300, Vladimir Sementsov-Ogievskiy wrote: > Render block nodes graph with help of graphviz. This new function is > for debugging, so there is no sense to put it into qemu.py as a method > of QEMUMachine. Let's instead put it separately. > > Signed-off-by:

Re: [Qemu-devel] [PATCH v3 1/3] x86: Data structure changes to support MSR based features

2018-08-17 Thread Paolo Bonzini
On 10/08/2018 16:06, Robert Hoo wrote: > +typedef enum FeatureWordType { > + CPUID_FEATURE_WORD, > + MSR_FEATURE_WORD, > +} FeatureWordType; This enum probably should be defined with QAPI, so that it can be reused in the feature-words property: # @X86CPUFeatureWordType: # # Kinds of X86 CPU

[Qemu-devel] [PATCH v2 20/60] check-qjson: Document we expect invalid UTF-8 to be rejected

2018-08-17 Thread Markus Armbruster
The JSON parser rejects some invalid sequences, but accepts others without correcting the problem. We should either reject all invalid sequences, or minimize overlong sequences and replace all other invalid sequences by a suitable replacement character. A common choice for replacement is U+FFFD.

[Qemu-devel] [PATCH v2 51/60] json: Eliminate lexer state IN_ERROR and pseudo-token JSON_MIN

2018-08-17 Thread Markus Armbruster
Signed-off-by: Markus Armbruster Reviewed-by: Eric Blake --- include/qapi/qmp/json-lexer.h | 10 -- qobject/json-lexer.c | 15 +++ 2 files changed, 11 insertions(+), 14 deletions(-) diff --git a/include/qapi/qmp/json-lexer.h b/include/qapi/qmp/json-lexer.h index

Re: [Qemu-devel] [PATCH v3 3/3] Change other funcitons referring to feature_word_info[]

2018-08-17 Thread Paolo Bonzini
On 10/08/2018 16:06, Robert Hoo wrote: > x86_cpu_get_feature_words(): limit to CPUID_FEATURE_WORD only. This should also grow support for MSR feature words. My suggestion is that you add another patch after patch 1 that expands the definition of X86CPUFeatureWordInfo like this, and adjusts

[Qemu-devel] [PATCH v2 47/60] qjson: Have qobject_from_json() & friends reject empty and blank

2018-08-17 Thread Markus Armbruster
The last case where qobject_from_json() & friends return null without setting an error is empty or blank input. Callers: * block.c's parse_json_protocol() reports "Could not parse the JSON options". It's marked as a work-around, because it also covered actual bugs, but they got fixed in the

[Qemu-devel] [PATCH v2 45/60] json: Fix streamer not to ignore trailing unterminated structures

2018-08-17 Thread Markus Armbruster
json_message_process_token() accumulates tokens until it got the sequence of tokens that comprise a single JSON value (it counts curly braces and square brackets to decide). It feeds those token sequences to json_parser_parse(). If a non-empty sequence of tokens remains at the end of the parse,

Re: [Qemu-devel] [PATCH v2 10/60] check-qjson: Consolidate partly redundant string tests

2018-08-17 Thread Eric Blake
On 08/17/2018 10:05 AM, Markus Armbruster wrote: simple_string() and single_quote_string() have become redundant with escaped_string(), except fot embedded single and double quotes. s/fot/for/ Replace them by a test that covers just that. Signed-off-by: Markus Armbruster ---

Re: [Qemu-devel] [PATCH 10/20] target/arm: Adjust aarch64_cpu_dump_state for system mode SVE

2018-08-17 Thread Peter Maydell
On 9 August 2018 at 05:21, Richard Henderson wrote: > Use the existing helpers to determine if (1) the fpu is enabled, > (2) sve state is enabled, and (3) the current sve vector length. > > Signed-off-by: Richard Henderson > --- > target/arm/cpu.h | 4 > target/arm/helper.c

Re: [Qemu-devel] [PATCH v2 56/60] docs/interop/qmp-spec: How to force known good parser state

2018-08-17 Thread Eric Blake
On 08/17/2018 10:05 AM, Markus Armbruster wrote: Section "QGA Synchronization" specifies that sending "a raw 0xFF sentinel byte" makes the server "reset its state and discard all pending data prior to the sentinel." What actually happens there is a lexical error, which will produce one ore more

Re: [Qemu-devel] [PATCH v2 57/60] tests/drive_del-test: Fix harmless JSON interpolation bug

2018-08-17 Thread Eric Blake
On 08/17/2018 10:05 AM, Markus Armbruster wrote: test_after_failed_device_add() does this: response = qmp("{'execute': 'device_add'," " 'arguments': {" " 'driver': 'virtio-blk-%s'," " 'drive': 'drive0'"

[Qemu-devel] [RFC PATCH 2/5] tests: Acquire AioContext around job_finish_sync()

2018-08-17 Thread Kevin Wolf
All callers in QEMU proper hold the AioContext lock when calling job_finish_sync(). The tests should do the same. Signed-off-by: Kevin Wolf --- include/qemu/job.h | 6 ++ tests/test-bdrv-drain.c | 6 ++ tests/test-blockjob.c | 6 ++ 3 files changed, 18 insertions(+) diff

[Qemu-devel] [RFC PATCH 0/5] Fix some jobs/drain/aio_poll related hangs

2018-08-17 Thread Kevin Wolf
I'm running out of time and will be offline for the next two weeks, so I'm just sending out what I have right now. This is probably not ready to be merged yet, but if need be, someone else can pick it up. Otherwise I'll do that myself when I return. This is related to the following bug reports:

[Qemu-devel] [RFC PATCH 5/5] [WIP] Lock AioContext in bdrv_co_drain_bh_cb()

2018-08-17 Thread Kevin Wolf
Not sure if this is correct, but at least it makes qemu-iotests 127 pass again. Signed-off-by: Kevin Wolf --- block/io.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/block/io.c b/block/io.c index 832d2536bf..d3dde4d7fd 100644 --- a/block/io.c +++ b/block/io.c @@ -309,6 +309,10 @@

[Qemu-devel] [RFC PATCH 3/5] job: Drop AioContext lock around aio_poll()

2018-08-17 Thread Kevin Wolf
Simimlar to AIO_WAIT_WHILE(), job_finish_sync() needs to release the AioContext lock of the job before calling aio_poll(). Otherwise, callbacks called by aio_poll() would possibly take the lock a second time and run into a deadlock with a nested AIO_WAIT_WHILE() call. Signed-off-by: Kevin Wolf

Re: [Qemu-devel] [PATCH v2] target/arm: crash on conditional instr in it block

2018-08-17 Thread no-reply
Hi, This series failed docker-mingw@fedora build test. Please find the testing commands and their output below. If you have Docker installed, you can probably reproduce it locally. Type: series Message-id: 20180816120533.6587-1-...@sysgo.com Subject: [Qemu-devel] [PATCH v2] target/arm: crash on

[Qemu-devel] [PATCH 2/2] qobject: modify qobject_ref() to assert on NULL

2018-08-17 Thread Marc-André Lureau
While it may be convenient to accept NULL value in qobject_unref() (for similar reasons as free() accepts NULL), it is not such a good idea for qobject_ref(): now assert() on NULL. Some code relied on that behaviour, but it's best to be explicit that NULL is accepted. We have to rely on testing,

Re: [Qemu-devel] [PATCH 01/14] i2c:pm_smbus: Clean up some style issues

2018-08-17 Thread Paolo Bonzini
On 07/12/2017 22:46, miny...@acm.org wrote: > From: Corey Minyard > > Fix some spacing issues, remove extraneous comments, add some > defines instead of hard-coding numbers. > > Signed-off-by: Corey Minyard > Cc: Michael S. Tsirkin > Cc: Paolo Bonzini > --- > hw/i2c/pm_smbus.c | 58 >

[Qemu-devel] [PATCH] vnc: call sasl_server_init() only when required

2018-08-17 Thread Marc-André Lureau
VNC server is calling sasl_server_init() during startup of QEMU, even if SASL auth has not been enabled. This may create undesirable warnings like "Could not find keytab file: /etc/qemu/krb5.tab" when the user didn't configure SASL on host and started VNC server. Instead, only initialize SASL

Re: [Qemu-devel] [PATCH] target-i386: fix segment limit check in ljmp

2018-08-17 Thread Paolo Bonzini
On 16/08/2018 03:19, and...@andrewoates.com wrote: > From: Andrew Oates > > The current implementation has three bugs, > * segment limits are not enforced in protected mode if the L bit is set >in the target segment descriptor[1] > * segment limits are not enforced in compatability mode

Re: [Qemu-devel] [PATCH 1/1] kvm: add call to qemu_add_opts() for -overcommit option

2018-08-17 Thread Paolo Bonzini
On 15/08/2018 19:57, prasad.singamse...@oracle.com wrote: > From: Prasad Singamsetty > > qemu command fails to process -overcommit option. Add the missing > call to qemu_add_opts() in vl.c. > > Signed-off-by: Prasad Singamsetty > --- > vl.c | 1 + > 1 file changed, 1 insertion(+) > > diff

[Qemu-devel] X86CPU "feature-words" property on QEMU (was Re: [PATCH v3 1/3] x86: Data structure changes to support MSR based) features

2018-08-17 Thread Eduardo Habkost
On Fri, Aug 17, 2018 at 07:34:13PM +0200, Paolo Bonzini wrote: > On 17/08/2018 17:55, Eduardo Habkost wrote: > >> The names will be X86_CPU_FEATURE_WORD_TYPE_CPUID and > >> X86_CPU_FEATURE_WORD_TYPE_MSR. > > I wouldn't like to make this an external API unless really > > necessary. I would rather

Re: [Qemu-devel] [PATCH 3/3] qom: implement CPU list with an RCU QLIST

2018-08-17 Thread Paolo Bonzini
On 15/08/2018 02:34, Emilio G. Cota wrote: > On Tue, Aug 14, 2018 at 08:26:54 +0200, Paolo Bonzini wrote: >> On 13/08/2018 18:38, Emilio G. Cota wrote: >>> Fix it by implementing the CPU list as an RCU QLIST. This requires >>> a little bit of extra work to insert CPUs at the tail of >>> the list

Re: [Qemu-devel] [RFC v4 6/6] i386/acpi-build: pxb-pcie start bus should always be 0 in separate pci domain

2018-08-17 Thread Marcel Apfelbaum
On 08/09/2018 09:35 AM, Zihan Yang wrote: The bus_nr indicates the bus number of pxb-pcie under pcie.0, but since pxb host can be put into different pci domain, the start bus should always be 0 I am  not sure about this limitation. Do you know where is coming from? Why do we must start a

[Qemu-devel] [PATCH v2 2/3] scripts: add render_block_graph function for QEMUMachine

2018-08-17 Thread Vladimir Sementsov-Ogievskiy
Render block nodes graph with help of graphviz. This new function is for debugging, so there is no sense to put it into qemu.py as a method of QEMUMachine. Let's instead put it separately. Signed-off-by: Vladimir Sementsov-Ogievskiy --- scripts/render_block_graph.py | 78

[Qemu-devel] [PATCH v2 3/3] not-for-commit: example of new command usage for debugging

2018-08-17 Thread Vladimir Sementsov-Ogievskiy
Signed-off-by: Vladimir Sementsov-Ogievskiy --- tests/qemu-iotests/222 | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tests/qemu-iotests/222 b/tests/qemu-iotests/222 index 0ead56d574..c2e647fa83 100644 --- a/tests/qemu-iotests/222 +++ b/tests/qemu-iotests/222 @@ -137,6 +137,9 @@ with

[Qemu-devel] [PATCH v2 33/60] json: Redesign the callback to consume JSON values

2018-08-17 Thread Markus Armbruster
The classical way to structure parser and lexer is to have the client call the parser to get an abstract syntax tree, the parser call the lexer to get the next token, and the lexer call some function to get input characters. Another way to structure them would be to have the client feed

[Qemu-devel] [PATCH v2 12/60] check-qjson: Simplify utf8_string()

2018-08-17 Thread Markus Armbruster
The previous commit made utf8_string()'s test_cases[].utf8_in superfluous: we can use .json_in instead. Except for the case testing U+. \x00 doesn't work in C strings, so it tests \\u instead. But testing \\u is escaped_string()'s job. It's covered there. Test U+0001 here, and drop

[Qemu-devel] [PATCH v2 24/60] json: Accept overlong \xC0\x80 as U+0000 ("modified UTF-8")

2018-08-17 Thread Markus Armbruster
Since the JSON grammer doesn't accept U+ anywhere, this merely exchanges one kind of parse error for another. It's purely for consistency with qobject_to_json(), which accepts \xC0\x80 (see commit e2ec3f97680). Signed-off-by: Markus Armbruster Reviewed-by: Eric Blake ---

[Qemu-devel] [PATCH v2 46/60] json: Assert json_parser_parse() consumes all tokens on success

2018-08-17 Thread Markus Armbruster
Signed-off-by: Markus Armbruster Reviewed-by: Eric Blake --- qobject/json-parser.c | 1 + 1 file changed, 1 insertion(+) diff --git a/qobject/json-parser.c b/qobject/json-parser.c index 247946e7c7..8f13c8f062 100644 --- a/qobject/json-parser.c +++ b/qobject/json-parser.c @@ -544,6 +544,7 @@

[Qemu-devel] [PATCH v2 43/60] qjson: Fix qobject_from_json() & friends for multiple values

2018-08-17 Thread Markus Armbruster
qobject_from_json() & friends use the consume_json() callback to receive either a value or an error from the parser. When they are fed a string that contains more than either one JSON value or one JSON syntax error, consume_json() gets called multiple times. When the last call receives a value,

Re: [Qemu-devel] [PATCH v2 05/60] qmp-test: Cover syntax and lexical errors

2018-08-17 Thread Eric Blake
On 08/17/2018 10:05 AM, Markus Armbruster wrote: Signed-off-by: Markus Armbruster --- Might be worth mentioning the addition of qtest_qmp_send_raw() in the commit message body. tests/libqtest.c | 17 + tests/libqtest.h | 11 +++ tests/qmp-test.c | 41

[Qemu-devel] [PATCH v2 39/60] json: Leave rejecting invalid interpolation to parser

2018-08-17 Thread Markus Armbruster
Both lexer and parser reject invalid interpolation specifications. The parser's check is useless. The lexer ends the token right after the first bad character. This tends to lead to suboptimal error reporting. For instance, input [ %04d ] produces the tokens JSON_LSQUARE [

Re: [Qemu-devel] [PATCH v2 2/3] hw/pci: add teardown function for PCI resource reserve capability

2018-08-17 Thread Marcel Apfelbaum
Hi Jing, On 08/16/2018 12:28 PM, Jing Liu wrote: Clean up the PCI config space of resource reserve capability. Signed-off-by: Jing Liu --- hw/pci/pci_bridge.c | 9 + include/hw/pci/pci_bridge.h | 1 + 2 files changed, 10 insertions(+) diff --git a/hw/pci/pci_bridge.c

[Qemu-devel] [PATCH 1/2] update-linux-headers.sh: add qemu_fw_cfg.h

2018-08-17 Thread Marc-André Lureau
The fw_cfg header was added during 4.17 cycle. Signed-off-by: Marc-André Lureau --- scripts/update-linux-headers.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/scripts/update-linux-headers.sh b/scripts/update-linux-headers.sh index feb75390aa..0a964fe240 100755 ---

Re: [Qemu-devel] [PATCH v2 41/60] json: Nicer recovery from invalid leading zero

2018-08-17 Thread Eric Blake
On 08/17/2018 10:05 AM, Markus Armbruster wrote: For input 0123, the lexer produces the tokens JSON_ERROR01 JSON_INTEGER 23 Reporting an error is correct; 0123 is invalid according to RFC 7159. But the error recovery isn't nice. Make the finite state machine eat digits before

[Qemu-devel] [PATCH 2/2] fw_cfg: import & use linux/qemu_fw_cfg.h

2018-08-17 Thread Marc-André Lureau
Use kernel common header for fw_cfg. (unfortunately, optionrom.h must have its own define, since it's actually an assembler header) Signed-off-by: Marc-André Lureau --- include/hw/misc/vmcoreinfo.h | 12 +-- include/hw/nvram/fw_cfg.h| 18 +---

Re: [Qemu-devel] [PATCH 2/5] target/i386: Convert to HAVE_CMPXCHG128

2018-08-17 Thread Emilio G. Cota
On Wed, Aug 15, 2018 at 19:54:49 -0700, Richard Henderson wrote: > Signed-off-by: Richard Henderson > --- > target/i386/mem_helper.c | 9 - > 1 file changed, 4 insertions(+), 5 deletions(-) Reviewed-by: Emilio G. Cota

Re: [Qemu-devel] [PATCH 06/20] target/arm: Fix arm_current_el for user-only

2018-08-17 Thread Richard Henderson
On 08/17/2018 09:03 AM, Peter Maydell wrote: > On 9 August 2018 at 05:21, Richard Henderson > wrote: >> Saves about 12k code size in qemu-aarch64. >> >> Signed-off-by: Richard Henderson >> --- >> target/arm/cpu.h | 4 >> 1 file changed, 4 insertions(+) >> >> diff --git a/target/arm/cpu.h

Re: [Qemu-devel] [RFC v4 1/6] pci_expander_bridge: add type TYPE_PXB_PCIE_HOST

2018-08-17 Thread Marcel Apfelbaum
Hi Zihan, On 08/09/2018 09:33 AM, Zihan Yang wrote: The inner host bridge created by pxb-pcie is TYPE_PXB_PCI_HOST by default, change it to a new type TYPE_PXB_PCIE_HOST to better utilize ECAM of PCIe Signed-off-by: Zihan Yang --- hw/pci-bridge/pci_expander_bridge.c | 127

Re: [Qemu-devel] [PATCH] i386: Fix arch_query_cpu_model_expansion() leak

2018-08-17 Thread Paolo Bonzini
On 16/08/2018 20:35, Eduardo Habkost wrote: > Reported by Coverity: > > Error: RESOURCE_LEAK (CWE-772): [#def439] > qemu-2.12.0/target/i386/cpu.c:3179: alloc_fn: Storage is returned from > allocation function "qdict_new". > qemu-2.12.0/qobject/qdict.c:34:5: alloc_fn: Storage is returned from >

Re: [Qemu-devel] [PATCH 1/1] libqtest: Improve error reporting for bad read from QEMU

2018-08-17 Thread Paolo Bonzini
On 15/08/2018 16:19, Markus Armbruster wrote: > When read() from the qtest socket or the QMP socket fails or EOFs, we > report "Broken pipe" and exit(1). This commonly happens when QEMU > crashes. It also happens when QEMU refuses to run because the test > passed it bad arguments. Sadly, we

[Qemu-devel] [PATCH 1/2] qdict: add qdict_steal()

2018-08-17 Thread Marc-André Lureau
Add a new function qdict_steal(), that deletes a key from a dict, and returns the associated value, if any. Simplify related code. Signed-off-by: Marc-André Lureau --- include/qapi/qmp/qdict.h | 1 + monitor.c| 3 +-- qobject/block-qdict.c| 7 ++- qobject/qdict.c

Re: [Qemu-devel] X86CPU "feature-words" property on QEMU (was Re: [PATCH v3 1/3] x86: Data structure changes to support MSR based) features

2018-08-17 Thread Eduardo Habkost
On Fri, Aug 17, 2018 at 07:59:40PM +0200, Paolo Bonzini wrote: > On 17/08/2018 19:48, Eduardo Habkost wrote: > > So let's do what's necessary to remove it. But I don't think the > > removal of "feature-words" should block the inclusion of this > > series. > > > > Now, should QOM properties

Re: [Qemu-devel] [PATCH v2 58/60] json: Keep interpolation state in JSONParserContext

2018-08-17 Thread Eric Blake
On 08/17/2018 10:05 AM, Markus Armbruster wrote: The recursive descent parser passes along a pointer to JSONParserContext. It additionally passes a pointer to interpolation state (a va_alist *) as needed to reach its consumer parse_interpolation(). Stuffing the latter pointer into

[Qemu-devel] [PATCH 1/7] jobs: change start callback to run callback

2018-08-17 Thread John Snow
Presently we codify the entry point for a job as the "start" callback, but a more apt name would be "run" to clarify the idea that when this function returns we consider the job to have "finished," except for any cleanup which occurs in separate callbacks later. As part of this clarification,

[Qemu-devel] [PATCH 4/7] block/commit: utilize job_exit shim

2018-08-17 Thread John Snow
Change the manual deferment to commit_complete into the implicit callback to job_exit, renaming commit_complete to commit_exit. This conversion does change the timing of when job_completed is called to after the bdrv_replace_node and bdrv_unref calls, which could have implications for bjob->blk

Re: [Qemu-devel] [PATCH v3 1/6] hw/riscv/virtio: Set the soc device tree node as a simple-bus

2018-08-17 Thread Philippe Mathieu-Daudé
Hi Alistair, On 08/16/2018 01:11 PM, Alistair Francis wrote: > To allow Linux to ennumerate devices on the /soc/ node set it as a enumerate > "simple-bus". > > Signed-off-by: Alistair Francis > --- > hw/riscv/virt.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git

[Qemu-devel] [PATCH 4/6] test-qht: test removal of non-existent entries

2018-08-17 Thread Emilio G. Cota
This improves qht.c code coverage from 89.44% to 90.00%. Signed-off-by: Emilio G. Cota --- tests/test-qht.c | 26 -- 1 file changed, 24 insertions(+), 2 deletions(-) diff --git a/tests/test-qht.c b/tests/test-qht.c index 283fb3db39..05b1d6807a 100644 ---

[Qemu-devel] [PATCH 1/6] qht: remove unused map param from qht_remove__locked

2018-08-17 Thread Emilio G. Cota
Signed-off-by: Emilio G. Cota --- util/qht.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/util/qht.c b/util/qht.c index c138777a9c..7b57b50a24 100644 --- a/util/qht.c +++ b/util/qht.c @@ -665,8 +665,7 @@ static inline void qht_bucket_remove_entry(struct qht_bucket

[Qemu-devel] [PATCH 3/6] test-qht: test qht_iter_remove

2018-08-17 Thread Emilio G. Cota
Signed-off-by: Emilio G. Cota --- tests/test-qht.c | 50 ++-- 1 file changed, 48 insertions(+), 2 deletions(-) diff --git a/tests/test-qht.c b/tests/test-qht.c index dda6a067be..283fb3db39 100644 --- a/tests/test-qht.c +++ b/tests/test-qht.c @@ -108,6

Re: [Qemu-devel] [PULL 0/8] x86 queue, 2018-08-16

2018-08-17 Thread no-reply
Hi, This series seems to have some coding style problems. See output below for more information: Type: series Message-id: 20180817013400.13353-1-ehabk...@redhat.com Subject: [Qemu-devel] [PULL 0/8] x86 queue, 2018-08-16 === TEST SCRIPT BEGIN === #!/bin/bash BASE=base n=1 total=$(git log

Re: [Qemu-devel] [Qemu-arm] [PATCH 16/16] hw/arm/mps2-tz: Create PL081s and MSCs

2018-08-17 Thread Philippe Mathieu-Daudé
On 08/09/2018 10:01 AM, Peter Maydell wrote: > The AN505 FPGA image includes four PL081 DMA controllers, each > of which is gated by a Master Security Controller that allows > the guest to prevent a non-secure DMA controller from accessing > memory that is used by secure guest code. Create and

[Qemu-devel] [PATCH 2/4] docker: Sort Fedora packages (i386-cross)

2018-08-17 Thread Philippe Mathieu-Daudé
As recommended in https://docs.docker.com/develop/develop-images/dockerfile_best-practices/#sort-multi-line-arguments "This helps to avoid duplication of packages and make the list much easier to update. This also makes PRs a lot easier to read and review." Signed-off-by: Philippe

Re: [Qemu-devel] [PATCH v3 1/3] x86: Data structure changes to support MSR based features

2018-08-17 Thread Robert Hoo
On Fri, 2018-08-17 at 00:10 -0300, Eduardo Habkost wrote: [trim...] > > + > > typedef struct FeatureWordInfo { > > -/* feature flags names are taken from "Intel Processor Identification > > and > > +FeatureWordType type; > > + /* feature flags names are taken from "Intel Processor

Re: [Qemu-devel] [Qemu-arm] [PATCH 04/16] hw/arm/iotkit: Wire up the S32KTIMER

2018-08-17 Thread Philippe Mathieu-Daudé
On 08/09/2018 10:01 AM, Peter Maydell wrote: > The IoTKit has a CMSDK timer device that runs on the S32KCLK. > Create this and wire it up. > > Signed-off-by: Peter Maydell Reviewed-by: Philippe Mathieu-Daudé > --- > include/hw/arm/iotkit.h | 2 +- > hw/arm/iotkit.c | 9 + > 2

Re: [Qemu-devel] [Qemu-arm] [PATCH 11/16] hw/dma/pl080: Support all three interrupt lines

2018-08-17 Thread Philippe Mathieu-Daudé
On 08/09/2018 10:01 AM, Peter Maydell wrote: > The PL080 and PL081 have three outgoing interrupt lines: > * DMACINTERR signals DMA errors > * DMACINTTC is the DMA count interrupt > * DMACINTR is a combined interrupt, the logical OR of the other two > > We currently only implement DMACINTR,

Re: [Qemu-devel] [PATCH v2 2/3] scripts: add render_block_graph function for QEMUMachine

2018-08-17 Thread Vladimir Sementsov-Ogievskiy
17.08.2018 21:25, Eduardo Habkost wrote: On Fri, Aug 17, 2018 at 09:04:39PM +0300, Vladimir Sementsov-Ogievskiy wrote: Render block nodes graph with help of graphviz. This new function is for debugging, so there is no sense to put it into qemu.py as a method of QEMUMachine. Let's instead put it

Re: [Qemu-devel] [PATCH 2/2] qemu-img: Add dd seek= option

2018-08-17 Thread Max Reitz
On 2018-08-16 09:15, Kevin Wolf wrote: > Am 16.08.2018 um 04:49 hat Max Reitz geschrieben: >> On 2018-08-16 04:39, Eric Blake wrote: >>> If convert were more powerful, I'd be fine dropping 'qemu-img dd' after >>> a proper deprecation period. >> >> Technically it has those features already, with

Re: [Qemu-devel] [PATCH] qemu-img.c: increase spacing between commands in documentation

2018-08-17 Thread Programmingkid
> On Aug 17, 2018, at 9:44 AM, Eric Blake wrote: > > On 08/16/2018 08:27 PM, Programmingkid wrote: > >> I am by no means an expert at qemu-img. But I did try my best to create what >> I think should be the new output for qemu-img --help. This is just >> the text I plan on using in a future

Re: [Qemu-devel] [PATCH for-3.1 v10 00/31] block: Fix some filename generation issues

2018-08-17 Thread Max Reitz
On 2018-08-16 08:02, Markus Armbruster wrote: > Max Reitz writes: > >> On 2018-08-15 05:43, no-re...@patchew.org wrote: >>> Hi, >>> >>> This series seems to have some coding style problems. See output below for >>> more information: >> >> [...] >> >>> === OUTPUT BEGIN === >>> Checking PATCH

Re: [Qemu-devel] [PATCH v2 1/3] qapi: add x-query-block-graph

2018-08-17 Thread Eric Blake
On 08/17/2018 01:04 PM, Vladimir Sementsov-Ogievskiy wrote: Add a new command, returning block nodes graph. Signed-off-by: Vladimir Sementsov-Ogievskiy --- qapi/block-core.json | 116 ++ +## +# @BlockGraphEdge: +# +# Block Graph edge

Re: [Qemu-devel] [RFC v2] new, node-graph-based fleecing and backup

2018-08-17 Thread Max Reitz
On 2018-08-14 19:01, Vladimir Sementsov-Ogievskiy wrote: > Signed-off-by: Vladimir Sementsov-Ogievskiy > --- > > [v2 is just a resend. I forget to add Den an me to cc, and I don't see the > letter in my thunderbird at all. strange. sorry for that] > > Hi all! > > Here is an idea and kind of

[Qemu-devel] [PATCH 2/6] qht: add qht_iter_remove

2018-08-17 Thread Emilio G. Cota
This currently has no users, but the use case is so common that I think we must support it. Note that without the appended we cannot safely remove a set of elements; a 2-step approach (i.e. qht_iter first, keep track of the to-be-deleted elements, and then a bunch of qht_remove calls) would be

Re: [Qemu-devel] [Qemu-arm] [PATCH 03/16] hw/arm/iotkit: Wire up the watchdogs

2018-08-17 Thread Philippe Mathieu-Daudé
Hi Peter, On 08/09/2018 10:01 AM, Peter Maydell wrote: > The IoTKit includes three different instances of the > CMSDK APB watchdog; create and wire them up. > > Signed-off-by: Peter Maydell > --- > include/hw/arm/iotkit.h | 6 + > hw/arm/iotkit.c | 58

Re: [Qemu-devel] [Qemu-arm] [PATCH 05/16] hw/misc/iotkit-sysctl: Implement IoTKit system control element

2018-08-17 Thread Philippe Mathieu-Daudé
Hi Peter, On 08/09/2018 10:01 AM, Peter Maydell wrote: > The Arm IoTKit includes a system control element which > provides a block of read-only ID registers and a block > of read-write control registers. Implement a minimal > version of this. > > Signed-off-by: Peter Maydell > --- >

Re: [Qemu-devel] [Qemu-arm] [PATCH 09/16] hw/arm/iotkit: Wire up the lines for MSCs

2018-08-17 Thread Philippe Mathieu-Daudé
On 08/09/2018 10:01 AM, Peter Maydell wrote: > The IoTKit doesn't have any MSCs itself but it does need > some wiring to connect the external signals from MSCs > in the outer board model up to the registers and the > NVIC IRQ line. > > We also need to expose a MemoryRegion corresponding to > the

Re: [Qemu-devel] [Qemu-arm] [PATCH 01/16] hw/watchdog/cmsdk_apb_watchdog: Implement CMSDK APB watchdog module

2018-08-17 Thread Philippe Mathieu-Daudé
On 08/09/2018 10:01 AM, Peter Maydell wrote: > The Arm Cortex-M System Design Kit includes a simple watchdog module > based on a 32-bit down-counter. Implement this. > > Signed-off-by: Peter Maydell > --- > Makefile.objs| 1 + > hw/watchdog/Makefile.objs

[Qemu-devel] [PATCH 0/4] docker: Sort packages

2018-08-17 Thread Philippe Mathieu-Daudé
Trivial cleanup patches. Per the Docker recommendation, "this helps to avoid duplication of packages and make the list much easier to update. This also makes PRs a lot easier to read and review." Regards, Phil. Philippe Mathieu-Daudé (4): docker: Sort Fedora packages docker: Sort Fedora

[Qemu-devel] [PATCH 4/4] docker: Sort CentOS packages

2018-08-17 Thread Philippe Mathieu-Daudé
As recommended in https://docs.docker.com/develop/develop-images/dockerfile_best-practices/#sort-multi-line-arguments "This helps to avoid duplication of packages and make the list much easier to update." Signed-off-by: Philippe Mathieu-Daudé --- tests/docker/dockerfiles/centos7.docker |

[Qemu-devel] [PATCH 1/4] docker: Sort Fedora packages

2018-08-17 Thread Philippe Mathieu-Daudé
As recommended in https://docs.docker.com/develop/develop-images/dockerfile_best-practices/#sort-multi-line-arguments "This helps to avoid duplication of packages and make the list much easier to update. This also makes PRs a lot easier to read and review." Signed-off-by: Philippe

[Qemu-devel] [PATCH 3/4] docker: Sort Ubuntu packages

2018-08-17 Thread Philippe Mathieu-Daudé
As recommended in https://docs.docker.com/develop/develop-images/dockerfile_best-practices/#sort-multi-line-arguments "This helps to avoid duplication of packages and make the list much easier to update. This also makes PRs a lot easier to read and review." Signed-off-by: Philippe

[Qemu-devel] [PATCH] migration: Replace strncpy() by g_strlcpy()

2018-08-17 Thread Philippe Mathieu-Daudé
Fedora 29 comes with GCC 8.1 which added the 'stringop-truncation' checks. Replace the strncpy() calls by g_strlcpy() to avoid the following warning: migration/global_state.c: In function 'global_state_store_running': migration/global_state.c:45:5: error: 'strncpy' specified bound 100 equals

[Qemu-devel] [PATCH] docker: Clean dangling tarball files

2018-08-17 Thread Philippe Mathieu-Daudé
When a container fails, it leaves a dangling tarball which name is based on a timestamp. Further uses of make won't clean those files, neither calling the 'docker-clean' target. Use the .DELETE_ON_ERROR built-in target to let make remove those temporary tarballs in case of failure.

Re: [Qemu-devel] [PATCH v2] sdhci: add i.MX SD Stable Clock bit

2018-08-17 Thread no-reply
Hi, This series seems to have some coding style problems. See output below for more information: Type: series Message-id: 1534507432-2873-1-git-send-email-hans-erik.flo...@rt-labs.com Subject: [Qemu-devel] [PATCH v2] sdhci: add i.MX SD Stable Clock bit === TEST SCRIPT BEGIN === #!/bin/bash

[Qemu-devel] [PATCH 0/6] qht improvements for 3.1

2018-08-17 Thread Emilio G. Cota
A small series with: - The addition of qht_iter_remove, necessary to safely remove a set of elements. This currently has no users, but it's easy to implement and very useful to have. (I initially wrote it for the sync-profiler, but for unrelated reasons I ended up changing the profiler's

[Qemu-devel] [PATCH 6/6] test-qht: speed up + test qht_resize

2018-08-17 Thread Emilio G. Cota
Perform first the tests that exercise code paths that are easier to hit at small table sizes, and then resize the table to speed up subsequent tests. If this resize is not too large, we can make the test faster with no code coverage loss. - With gcov enabled: Before: 20.568s, 90.28% qht.c

[Qemu-devel] [PATCH 5/6] test-qht: test deletion of the last entry in a bucket

2018-08-17 Thread Emilio G. Cota
This improves coverage by one (!) LoC in qht.c, bringing the coverage rate up from 90.00% to 90.28%. Signed-off-by: Emilio G. Cota --- tests/test-qht.c | 13 - 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/tests/test-qht.c b/tests/test-qht.c index

Re: [Qemu-devel] [Qemu-arm] [PATCH 06/16] hw/misc/iotkit: Wire up the system control element

2018-08-17 Thread Philippe Mathieu-Daudé
Hi Peter, On 08/09/2018 10:01 AM, Peter Maydell wrote: > Wire up the system control element's register banks. > > This is the last of the previously completely unimplemented > components in the IoTKit. > > Signed-off-by: Peter Maydell > --- > include/hw/arm/iotkit.h | 4 +++- >

Re: [Qemu-devel] [PATCH v3 0/3] file-posix: Simplifications on image locking

2018-08-17 Thread no-reply
Hi, This series failed docker-quick@centos7 build test. Please find the testing commands and their output below. If you have Docker installed, you can probably reproduce it locally. Type: series Message-id: 20180817054758.14515-1-f...@redhat.com Subject: [Qemu-devel] [PATCH v3 0/3] file-posix:

Re: [Qemu-devel] [Qemu-arm] [PATCH 08/16] hw/misc/iotkit-secctl: Wire up registers for controlling MSCs

2018-08-17 Thread Philippe Mathieu-Daudé
On 08/09/2018 10:01 AM, Peter Maydell wrote: > The IoTKit does not have any Master Security Contollers itself, > but it does provide registers in the secure privilege control > block which allow control of MSCs in the external system. > Add support for these registers. > > Signed-off-by: Peter

Re: [Qemu-devel] [Qemu-arm] [PATCH 07/16] hw/misc/tz-msc: Model TrustZone Master Security Controller

2018-08-17 Thread Philippe Mathieu-Daudé
On 08/09/2018 10:01 AM, Peter Maydell wrote: > Implement a model of the TrustZone Master Securtiy Controller, Security > as documented in the Arm CoreLink SIE-200 System IP for > Embedded TRM (DDI0571G): > https://developer.arm.com/products/architecture/m-profile/docs/ddi0571/g Your link

Re: [Qemu-devel] [Qemu-arm] [PATCH 00/16] arm: Implement MPS2 watchdogs and DMA

2018-08-17 Thread Philippe Mathieu-Daudé
On 08/16/2018 03:02 PM, Peter Maydell wrote: > Ping for code review, please? I let patch #7 for someone else (or later) and few comments before adding R-b for the rest. > > (It's only been a week so this is a little bit eager, but > I have some more MPS patches which wire up the PL022 SPI >

Re: [Qemu-devel] [PATCH v2 0/9] synchronization profiler

2018-08-17 Thread no-reply
Hi, This series seems to have some coding style problems. See output below for more information: Type: series Message-id: 20180817051853.23792-1-c...@braap.org Subject: [Qemu-devel] [PATCH v2 0/9] synchronization profiler === TEST SCRIPT BEGIN === #!/bin/bash BASE=base n=1 total=$(git log

[Qemu-devel] [PATCH] sheepdog: Replace strncpy() by g_strlcpy()

2018-08-17 Thread Philippe Mathieu-Daudé
Fedora 29 comes with GCC 8.1 which added the 'stringop-truncation' checks. Replace the strncpy() calls by g_strlcpy() to avoid the following warning: block/sheepdog.c: In function 'find_vdi_name': block/sheepdog.c:1239:5: error: 'strncpy' specified bound 256 equals destination size

[Qemu-devel] [Bug 1777293] Re: [REQUEST] SHARING MEMORY WITH HOST

2018-08-17 Thread Launchpad Bug Tracker
[Expired for QEMU because there has been no activity for 60 days.] ** Changed in: qemu Status: Incomplete => Expired -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1777293 Title: [REQUEST]

Re: [Qemu-devel] [RFC PATCH] rbd: Don't convert keypairs to JSON and back

2018-08-17 Thread Max Reitz
On 2018-08-16 08:40, Markus Armbruster wrote: > Max Reitz writes: > >> On 2018-08-15 10:12, Markus Armbruster wrote: >>> Max Reitz writes: >> >> [...] >> To me personally the issue is that if you can specify a plain filename, bdrv_refresh_filename() should give you that plain filename

Re: [Qemu-devel] [RFC v2] new, node-graph-based fleecing and backup

2018-08-17 Thread no-reply
Hi, This series failed docker-quick@centos7 build test. Please find the testing commands and their output below. If you have Docker installed, you can probably reproduce it locally. Type: series Message-id: 20180814170126.56461-1-vsement...@virtuozzo.com Subject: [Qemu-devel] [RFC v2] new,

[Qemu-devel] [PATCH 2/7] jobs: canonize Error object

2018-08-17 Thread John Snow
Jobs presently use both an Error object in the case of the create job, and char strings in the case of generic errors elsewhere. Unify the two paths as just j->err, and remove the extra argument from job_completed. The integer error code for job_completed is kept for now for use by pre-emptive

Re: [Qemu-devel] [RFC v2] new, node-graph-based fleecing and backup

2018-08-17 Thread no-reply
Hi, This series failed docker-mingw@fedora build test. Please find the testing commands and their output below. If you have Docker installed, you can probably reproduce it locally. Type: series Message-id: 20180814170126.56461-1-vsement...@virtuozzo.com Subject: [Qemu-devel] [RFC v2] new,

[Qemu-devel] [PATCH 3/7] jobs: add exit shim

2018-08-17 Thread John Snow
All jobs do the same thing when they leave their running loop: - Store the return code in a structure - wait to receive this structure in the main thread - signal job completion via job_completed Few jobs do anything beyond exactly this. Consolidate this exit logic for a net reduction in SLOC.

Re: [Qemu-devel] [PATCH 4/7] block/commit: utilize job_exit shim

2018-08-17 Thread John Snow
On 08/17/2018 03:04 PM, John Snow wrote: > Change the manual deferment to commit_complete into the implicit > callback to job_exit, renaming commit_complete to commit_exit. > > This conversion does change the timing of when job_completed is > called to after the bdrv_replace_node and

<    1   2   3   4   5   >