[Qemu-devel] [PATCH v2] file-posix: Use error API properly

2018-10-30 Thread Fam Zheng
Use error_report for situations that affect user operation (i.e. we're actually returning error), and warn_report/warn_report_err when some less critical error happened but the user operation can still carry on. For raw_normalize_devicepath, add Error parameter to propagate to its callers. Sugge

Re: [Qemu-devel] [PATCH] fmops: fix off-by-one in AR_TABLE and DR_TABLE array size

2018-10-30 Thread no-reply
Hi, This series seems to have some coding style problems. See output below for more information: Type: series Message-id: 20181030082340.17170-1-kra...@redhat.com Subject: [Qemu-devel] [PATCH] fmops: fix off-by-one in AR_TABLE and DR_TABLE array size === TEST SCRIPT BEGIN === #!/bin/bash BASE=

[Qemu-devel] [Bug 1448985] Re: llvmpipe i386 crashes when running on qemu64 cpu

2018-10-30 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/1448985 Title: llvmpipe i3

[Qemu-devel] [Bug 1495380] Re: Invalid parameter 'queues'. multi-queue vhost-user backends does not work.

2018-10-30 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/1495380 Title: Invalid par

[Qemu-devel] [PATCH v4] tests: vm: auto_install OpenBSD

2018-10-30 Thread Fam Zheng
Upgrade OpenBSD to 6.4 using auto_install. Especially, drop SDL1, include SDL2. Also do the build in $HOME since both /var/tmp and /tmp are tmpfs with limited capacities. Signed-off-by: Fam Zheng --- v4: Use 6.4. [Brad] --- tests/vm/basevm.py | 6 ++-- tests/vm/openbsd | 85 +++

[Qemu-devel] [PULL v2 24/24] qga-win: changing --retry-path option behavior

2018-10-30 Thread Michael Roth
From: Bishara AbuHattoum Currently whenever the qemu-ga's service doesn't find the virtio-serial the run_agent() loops in a QGA_RETRY_INTERVAL (default 5 seconds) intervals and try to restart the qemu-ga which causes a synchronous loop. Changed to wait and listen for the serial events by register

[Qemu-devel] [PULL v2 08/24] qga-win: fsinfo: pci-info: allow partial info

2018-10-30 Thread Michael Roth
From: Sameeh Jubran The call to SetupDiGetDeviceRegistryProperty might fail because the value doesn't exist in the registry, in this case we shouldn't exit from the loop but instead continue to look for other available values in the registry and set this value as unavailable (-1). Signed-off-by:

[Qemu-devel] [PULL v2 02/24] qga-win: add support for qmp_guest_fsfreeze_freeze_list

2018-10-30 Thread Michael Roth
From: Chen Hanxiao This patch add support for freeze specified fs. The valid mountpoints list member are [1]: The path of a mounted folder, for example, Y:\MountX\ A drive letter, for example, D:\ A volume GUID path of the form \\?\Volume{GUID}\, where GUID identifies the volume A

[Qemu-devel] [PULL v2 07/24] qga-win: prevent crash when executing fsinfo command

2018-10-30 Thread Michael Roth
From: Sameeh Jubran The fsinfo command is currently implemented for Windows only and it's disk parameter can be enabled by adding the define "CONFIG_QGA_NTDDSCSI" to the qga code. When enabled and executed the qemu-ga crashed with the following message: --

[Qemu-devel] [PULL v2 06/24] qga: linux: return disk device in guest-get-fsinfo

2018-10-30 Thread Michael Roth
From: Tomáš Golembiovský Report device node of the disk on Linux (e.g. "/dev/sda2"). Requirs libudev. Signed-off-by: Tomáš Golembiovský Signed-off-by: Michael Roth --- qga/commands-posix.c | 7 ++- qga/qapi-schema.json | 3 ++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git

[Qemu-devel] [PULL v2 23/24] qga-win: report specific error when failing to open channel

2018-10-30 Thread Michael Roth
Useful in general, but especially now that errors might occur more frequently with --retry-path set. Signed-off-by: Michael Roth Reviewed-by: Marc-André Lureau Signed-off-by: Michael Roth --- qga/channel-win32.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/qga/channel-

[Qemu-devel] [PULL v2 03/24] qga: ignore non present cpus when handling qmp_guest_get_vcpus()

2018-10-30 Thread Michael Roth
From: Igor Mammedov If VM has VCPUs plugged sparselly (for example a VM started with 3 VCPUs (cpu0, cpu1 and cpu2) and then cpu1 was hotunplugged so only cpu0 and cpu2 are present), QGA will rise a error error: internal error: unable to execute QEMU agent command 'guest-get-vcpus': open("/sys

[Qemu-devel] [PULL v2 05/24] qga: linux: report disk serial number

2018-10-30 Thread Michael Roth
From: Tomáš Golembiovský Add reporting of disk serial number on Linux guests. The feature depends on libudev. Example: { "name": "dm-2", "mountpoint": "/", ... "disk": [ { "serial": "SAMSUNG_MZ7LN512HCHP-000L1_S1ZKNXAG822493", ...

[Qemu-devel] [PULL v2 22/24] qga-win: install service with --retry-path set by default

2018-10-30 Thread Michael Roth
It's nicer from a management perspective that the agent can survive hotplug/unplug of the channel device, or be started prior to the installation of the channel device's driver without and still be able to resume normal function afterward. On linux there are alternatives like systemd to support thi

[Qemu-devel] [PULL v2 16/24] qga-win: demystify namespace stripping

2018-10-30 Thread Michael Roth
From: Tomáš Golembiovský It was not obvious what exactly the cryptic string copying does to the GUID. This change makes the intent clearer. Signed-off-by: Tomáš Golembiovský Signed-off-by: Michael Roth --- qga/commands-win32.c | 9 - 1 file changed, 8 insertions(+), 1 deletion(-) dif

[Qemu-devel] [PULL v2 04/24] configure: add test for libudev

2018-10-30 Thread Michael Roth
From: Tomáš Golembiovský Signed-off-by: Tomáš Golembiovský Reviewed-by: Marc-André Lureau *make libudev optional to avoid breaking existing build/test environments *disable libudev for --static builds Signed-off-by: Michael Roth --- configure | 21 + 1 file changed, 21 ins

[Qemu-devel] [PULL v2 21/24] qga: add --retry-path option for re-initializing channel on failure

2018-10-30 Thread Michael Roth
This adds an option to instruct the agent to periodically attempt re-opening the communication channel after a channel error has occurred. The main use-case for this is providing an OS-independent way of allowing the agent to survive situations like hotplug/unplug of the communication channel, or i

[Qemu-devel] [PULL v2 15/24] qga-win: return disk device in guest-get-fsinfo

2018-10-30 Thread Michael Roth
From: Tomáš Golembiovský Report device UNC of the disk. It is reported as "\\.\PhysicalDriveX". Signed-off-by: Tomáš Golembiovský Signed-off-by: Michael Roth --- qga/commands-win32.c | 21 +++-- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/qga/commands-win32

[Qemu-devel] [PULL v2 20/24] qga: move w32 service handling out of run_agent()

2018-10-30 Thread Michael Roth
Eventually we want a w32 service to be able to restart the qga main loop from within service_main(). To allow for this we move service handling out of run_agent() such that service_main() calls run_agent() instead of the reverse. Signed-off-by: Michael Roth Signed-off-by: Bishara AbuHattoum Sign

[Qemu-devel] [PULL v2 01/24] qga: Support Unicode paths in guest-file-open on win32

2018-10-30 Thread Michael Roth
From: Jonathon Reinhart Currently, the win32 port of QEMU Guest Agent does not properly handle Unicode paths. The JSON decoder produces a valid UTF-8 path string, but this is passed directly to CreateFileA, which is expecting an ANSI string and not UTF-8. This leads to mangled filenames. This pa

[Qemu-devel] [PULL v2 14/24] qga-win: handle multi-disk volumes

2018-10-30 Thread Michael Roth
From: Tomáš Golembiovský Probe the volume for disk extents and return list of all disks. Originally only first disk of composite volume was returned. Note that the patch changes get_pci_info() from one state of brokenness into a different state of brokenness. In other words it still does not do

[Qemu-devel] [PULL v2 17/24] qga: fix an off-by-one issue

2018-10-30 Thread Michael Roth
From: Li Qiang Signed-off-by: Li Qiang Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Michael Roth --- qga/commands-win32.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/qga/commands-win32.c b/qga/commands-win32.c index a1b7512d46..ef1d7d48d2 100644 --- a/qga/command

[Qemu-devel] [PULL v2 18/24] qga: group agent init/cleanup init separate routines

2018-10-30 Thread Michael Roth
This patch better separates the init/cleanup routines out into separate functions to make the start-up procedure a bit easier to follow. This will be useful when we eventually break out the actual start/stop of the agent's main loop into separates routines that can be called multiple times after th

[Qemu-devel] [PULL v2 09/24] build: rename CONFIG_QGA_NTDDDISK to CONFIG_QGA_NTDDSCSI

2018-10-30 Thread Michael Roth
From: Tomáš Golembiovský There was inconsistency between commits: 50cbebb9a3 configure: add configure check for ntdddisk.h a3ef3b2272 qga: added bus type and disk location path The first commit added #define CONFIG_QGA_NTDDDISK but the second commit expected the name to be CONFIG_QGA_NTDDSC

[Qemu-devel] [PULL v2 00/24] qemu-ga patch queue for soft-freeze

2018-10-30 Thread Michael Roth
The following changes since commit a2e002ff7913ce93aa0f7dbedd2123dce5f1a9cd: Merge remote-tracking branch 'remotes/vivier2/tags/qemu-trivial-for-3.1-pull-request' into staging (2018-10-30 15:49:55 +) are available in the Git repository at: git://github.com/mdroth/qemu.git tags/qga-pull

[Qemu-devel] [PULL v2 10/24] qga-win: add debugging information

2018-10-30 Thread Michael Roth
The windows code generaly lacks debug information (compared to posix code). This patch adds some related to HW info in guest-get-fsinfo command. Signed-off-by: Tomáš Golembiovský Reviewed-by: Marc-André Lureau Signed-off-by: Michael Roth --- qga/commands-win32.c | 15 +++ 1 file ch

[Qemu-devel] [PULL v2 19/24] qga: hang GAConfig/socket_activation off of GAState global

2018-10-30 Thread Michael Roth
For w32 services we rely on the global GAState to access resources associated with the agent within service_main(). Currently this is sufficient for starting the agent since we open the channel once prior to calling service_main(), and simply start the GMainLoop to start the agent from within servi

[Qemu-devel] [PULL v2 11/24] qga-win: refactor disk properties (bus)

2018-10-30 Thread Michael Roth
From: Tomáš Golembiovský Refactor code that queries bus type to be more generic. The function get_disk_bus_type() has been renamed to build_guest_disk_info(). Following commit(s) will extend this function. Signed-off-by: Tomáš Golembiovský Signed-off-by: Michael Roth --- qga/commands-win32.c

[Qemu-devel] [PULL v2 12/24] qga-win: report disk serial number

2018-10-30 Thread Michael Roth
From: Tomáš Golembiovský Signed-off-by: Tomáš Golembiovský *coding style fix-ups (declarations at beginning of block) *improve readability for user-visible errors *cover additional edge-cases with debug statements Signed-off-by: Michael Roth --- qga/commands-win32.c | 30 ++

[Qemu-devel] [PULL v2 13/24] qga-win: refactor disk info

2018-10-30 Thread Michael Roth
From: Tomáš Golembiovský Refactor building of disk info into a function that builds the list and a function that returns infor for single disk. This will be used in future commit that will handle multi-disk volumes. Signed-off-by: Tomáš Golembiovský Signed-off-by: Michael Roth --- qga/command

Re: [Qemu-devel] [QEMU PATCH v2 0/2]: KVM: i386: Add support for save and restore nested state

2018-10-30 Thread Liran Alon
Ping. Patch was submitted almost two months ago and I haven’t seen any respond for the v2 of this series. Thanks, -Liran > On 15 Oct 2018, at 21:10, Liran Alon wrote: > > Another gentle ping on v2 of this series? > Patch was submitted a month ago. > > Thanks, > -Liran > >> On 8 Oct 2018, at

Re: [Qemu-devel] [PATCH v3 19/19] hw: i386: Implement the ACPI builder interface for PC

2018-10-30 Thread Samuel Ortiz
On Tue, Oct 30, 2018 at 05:03:28PM +0100, Paolo Bonzini wrote: > On 30/10/2018 15:13, Samuel Ortiz wrote: > >> Just a quick question before I go and actually apply the patches to look > >> at the resulting code: is there any reason why you didn't add the > >> MachineState and/or AcpiBuilder to Acpi

[Qemu-devel] [PATCH V2] net/filter-rewriter.c: Fix coverity static analysis issue

2018-10-30 Thread Zhang Chen
The original code just follow the TCP state diagram, but in this case, we can skip the TCPS_TIME_WAIT state to simplify the implementation. Signed-off-by: Zhang Chen --- net/filter-rewriter.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/net/filter-rewriter.c b/net/filter

Re: [Qemu-devel] [PATCH] net/filter-rewirter.c: Fix coverity static analysis issue

2018-10-30 Thread Zhang Chen
Oh, Sorry. I will send the V2 patch. Thank Zhang Chen On Wed, Oct 31, 2018 at 12:18 AM Peter Maydell wrote: > On 30 October 2018 at 03:50, Zhang Chen wrote: > > The original code just follow the TCP state diagram, > > but in this case, we can skip the TCPS_TIME_WAIT state to simplify > > the i

[Qemu-devel] [PULL 6/7] i386: Add new model of Cascadelake-Server

2018-10-30 Thread Eduardo Habkost
From: Tao Xu New CPU models mostly inherit features from ancestor Skylake-Server, while addin new features: AVX512_VNNI, Intel PT. SSBD support for speculative execution side channel mitigations. Note: On Cascadelake, some capabilities (RDCL_NO, IBRS_ALL, RSBA, SKIP_L1DFL_VMENTRY and SSB_NO) ar

[Qemu-devel] [PULL 2/7] target/i386: Remove #ifdeffed-out icebp debugging hack

2018-10-30 Thread Eduardo Habkost
From: Peter Maydell Remove a debugging hack which could be used to cause the undocumented 'icebp' instruction to enable QEMU internal debug logging. This code has always been #ifdeffed out since it was introduced in commit aba9d61e34b9 in 2005; judging by the rest of that commit (which is entirel

[Qemu-devel] [PULL 3/7] kvm: Add support to KVM_GET_MSR_FEATURE_INDEX_LIST and KVM_GET_MSRS system ioctl

2018-10-30 Thread Eduardo Habkost
From: Robert Hoo Add kvm_get_supported_feature_msrs() to get supported MSR feature index list. Add kvm_arch_get_supported_msr_feature() to get each MSR features value. Signed-off-by: Robert Hoo Message-Id: <1539578845-37944-2-git-send-email-robert...@linux.intel.com> Reviewed-by: Eduardo Habkos

[Qemu-devel] [PULL 5/7] x86: define a new MSR based feature word -- FEATURE_WORDS_ARCH_CAPABILITIES

2018-10-30 Thread Eduardo Habkost
From: Robert Hoo Note RSBA is specially treated -- no matter host support it or not, qemu pretends it is supported. Signed-off-by: Robert Hoo Message-Id: <1539578845-37944-4-git-send-email-robert...@linux.intel.com> [ehabkost: removed automatic enabling of RSBA] Reviewed-by: Eduardo Habkost --

[Qemu-devel] [PULL 0/7] x86 queue, 2018-10-30

2018-10-30 Thread Eduardo Habkost
Sorry for submitting this at the last minute. The following changes since commit a2e002ff7913ce93aa0f7dbedd2123dce5f1a9cd: Merge remote-tracking branch 'remotes/vivier2/tags/qemu-trivial-for-3.1-pull-request' into staging (2018-10-30 15:49:55 +) are available in the Git repository at:

[Qemu-devel] [PULL 1/7] i386: correct cpu_x86_cpuid(0xd)

2018-10-30 Thread Eduardo Habkost
From: Sebastian Andrzej Siewior Intel SDM says for CPUID function 0DH, sub-function 0: | • ECX enumerates the size (in bytes) required by the XSAVE instruction for an | XSAVE area containing all the user state components supported by this | processor. | • EBX enumerates the size (in bytes) r

[Qemu-devel] [PULL 10/15] iotests: Unify log outputs between Python 2 and 3

2018-10-30 Thread Eduardo Habkost
From: Max Reitz When dumping an object into the log, there are differences between Python 2 and 3. First, unicode strings are prefixed by 'u' in Python 2 (they are no longer in 3, because unicode strings are the default there). Second, the order of keys in dicts may differ. Third, especially l

[Qemu-devel] [PULL 15/15] scripts/qemu.py: use a more consistent docstring style

2018-10-30 Thread Eduardo Habkost
From: Cleber Rosa Signed-off-by: Cleber Rosa Message-Id: <20181004161852.11673-10-cr...@redhat.com> [ehabkost: reverted unintentional submodule update] Signed-off-by: Eduardo Habkost --- scripts/qemu.py | 65 +++-- 1 file changed, 41 insertions(+), 2

[Qemu-devel] [PULL 4/7] x86: Data structure changes to support MSR based features

2018-10-30 Thread Eduardo Habkost
From: Robert Hoo Add FeatureWordType indicator in struct FeatureWordInfo. Change feature_word_info[] accordingly. Change existing functions that refer to feature_word_info[] accordingly. Signed-off-by: Robert Hoo Message-Id: <1539578845-37944-3-git-send-email-robert...@linux.intel.com> [ehabkos

[Qemu-devel] [PULL 05/15] iotests: Use // for Python integer division

2018-10-30 Thread Eduardo Habkost
From: Max Reitz In Python 3, / is always a floating-point division. We usually do not want this, and as Python 2.7 understands // as well, change all integer divisions to use that. Signed-off-by: Max Reitz Reviewed-by: Eduardo Habkost Reviewed-by: Cleber Rosa Message-Id: <20181022135307.1439

[Qemu-devel] [PULL 14/15] scripts/decodetree.py: fix reference to attributes

2018-10-30 Thread Eduardo Habkost
From: Cleber Rosa Signed-off-by: Cleber Rosa Message-Id: <20181004161852.11673-9-cr...@redhat.com> Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Eduardo Habkost --- scripts/decodetree.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/decodetree.py b/scripts/d

[Qemu-devel] [PULL 09/15] iotests: Modify imports for Python 3

2018-10-30 Thread Eduardo Habkost
From: Max Reitz There are two imports that need to be modified when running the iotests under Python 3: One is StringIO, which no longer exists; instead, the StringIO class comes from the io module, so import it from there (and use the BytesIO class for Python 2). The other is the ConfigParser,

[Qemu-devel] [PULL 7/7] i386: Add PKU on Skylake-Server CPU model

2018-10-30 Thread Eduardo Habkost
From: Tao Xu As the release document ref below link (page 13): https://software.intel.com/sites/default/files/managed/c5/15/\ architecture-instruction-set-extensions-programming-reference.pdf PKU is supported in Skylake Server (Only Server) and later, and on Intel(R) Xeon(R) Processor Scalable F

[Qemu-devel] [PULL 04/15] iotests: Use Python byte strings where appropriate

2018-10-30 Thread Eduardo Habkost
From: Max Reitz Since byte strings are no longer the default in Python 3, we have to explicitly use them where we need to, which is mostly when working with structures. It also means that we need to open a file in binary mode when we want to use structures. On the other hand, we have to accomod

[Qemu-devel] [PULL 12/15] Acceptance tests: add make rule for running them

2018-10-30 Thread Eduardo Habkost
From: Cleber Rosa The acceptance (aka functional, aka Avocado-based) tests are Python files located in "tests/acceptance" that need to be run with the Avocado libs and test runner. Let's provide a convenient way for QEMU developers to run them, by making use of the tests-venv with the required s

[Qemu-devel] [PULL 03/15] iotests: Flush in iotests.py's QemuIoInteractive

2018-10-30 Thread Eduardo Habkost
From: Max Reitz After issuing a command, flush the pipe. This does not change anything in Python 2, but it makes a difference in Python 3. Signed-off-by: Max Reitz Reviewed-by: Eduardo Habkost Reviewed-by: Cleber Rosa Message-Id: <20181022135307.14398-3-mre...@redhat.com> Signed-off-by: Edua

[Qemu-devel] [PULL 08/15] iotests: 'new' module replacement in 169

2018-10-30 Thread Eduardo Habkost
From: Max Reitz iotest 169 uses the 'new' module to add methods to a class. This module no longer exists in Python 3. Instead, we can use a lambda. Best of all, this works in 2.7 just as well. Signed-off-by: Max Reitz Reviewed-by: Eduardo Habkost Reviewed-by: Cleber Rosa Message-Id: <20181

[Qemu-devel] [PULL 11/15] Bootstrap Python venv for tests

2018-10-30 Thread Eduardo Habkost
From: Cleber Rosa A number of QEMU tests are written in Python, and may benefit from an untainted Python venv. By using make rules, tests that depend on specific Python libs can set that rule as a requirement, along with rules that require the presence or installation of specific libraries. The

[Qemu-devel] [PATCH v3 12/13] arm: Instantiate NRF51 Timers

2018-10-30 Thread Steffen Görtz
Instantiates TIMER0 - TIMER2 Signed-off-by: Steffen Görtz --- hw/arm/nrf51_soc.c | 27 +++ include/hw/arm/nrf51_soc.h | 4 2 files changed, 31 insertions(+) diff --git a/hw/arm/nrf51_soc.c b/hw/arm/nrf51_soc.c index 695b335dc5..c29b80c0ca 100644 --- a/hw/ar

[Qemu-devel] [PULL 01/15] scripts/device-crash-test: Remove devices that are not user_creatable anymore

2018-10-30 Thread Eduardo Habkost
From: Thomas Huth Devices that are derived from TYPE_SYS_BUS_DEVICE are not user_creatable anymore by default, and some others have been marked as non-user_creatable manually, so we can remove these devices from the "ignore"-list in the device-crash-test script. Signed-off-by: Thomas Huth Messa

[Qemu-devel] [PULL 06/15] iotests: Different iterator behavior in Python 3

2018-10-30 Thread Eduardo Habkost
From: Max Reitz In Python 3, several functions now return iterators instead of lists. This includes range(), items(), map(), and filter(). This means that if we really want a list, we have to wrap those instances with list(). But then again, the two instances where this is the case for map() an

[Qemu-devel] [PULL 13/15] Travis support for the acceptance tests

2018-10-30 Thread Eduardo Habkost
From: Cleber Rosa This enables the execution of the acceptance tests on Travis. Because the Travis environment is based on Ubuntu Trusty, it requires the python3-pip and python3.4-venv packages. Signed-off-by: Cleber Rosa Tested-by: Philippe Mathieu-Daudé Reviewed-by: Alex Bennée Acked-by: S

[Qemu-devel] [PULL 00/15] Python queue, 2018-10-30

2018-10-30 Thread Eduardo Habkost
Sorry for submitting this at the last minute. The following changes since commit a2e002ff7913ce93aa0f7dbedd2123dce5f1a9cd: Merge remote-tracking branch 'remotes/vivier2/tags/qemu-trivial-for-3.1-pull-request' into staging (2018-10-30 15:49:55 +) are available in the Git repository at:

[Qemu-devel] [PATCH v3 11/13] hw/timer/nrf51_timer: Add nRF51 Timer peripheral

2018-10-30 Thread Steffen Görtz
This patch adds the model for the nRF51 timer peripheral. Currently, only the TIMER mode is implemented. Signed-off-by: Steffen Görtz --- hw/timer/Makefile.objs | 1 + hw/timer/nrf51_timer.c | 358 + hw/timer/trace-events | 5 + includ

[Qemu-devel] [PATCH v3 10/13] tests/microbit-test: Add Tests for nRF51 GPIO

2018-10-30 Thread Steffen Görtz
The test suite for the nRF51 GPIO peripheral for now only tests initial state. Additionally a set of tests testing an implementation detail of the model are included. Signed-off-by: Steffen Görtz --- tests/microbit-test.c | 122 ++ 1 file changed, 122 inse

[Qemu-devel] [PULL 07/15] iotests: Explicitly bequeath FDs in Python

2018-10-30 Thread Eduardo Habkost
From: Max Reitz Python 3.4 introduced the inheritable attribute for FDs. At the same time, it changed the default so that all FDs are not inheritable by default, that only inheritable FDs are inherited to subprocesses, and only if close_fds is explicitly set to False. Adhere to this by setting

[Qemu-devel] [PATCH v3 08/13] hw/gpio/nrf51_gpio: Add nRF51 GPIO peripheral

2018-10-30 Thread Steffen Görtz
This adds a model of the nRF51 GPIO peripheral. Reference Manual: http://infocenter.nordicsemi.com/pdf/nRF51_RM_v3.0.pdf The nRF51 series microcontrollers support up to 32 GPIO pins in various configurations. The pins can be used as input pins with pull-ups or pull-down. Furthermore, three diffe

[Qemu-devel] [PULL 02/15] iotests: Make nbd-fault-injector flush

2018-10-30 Thread Eduardo Habkost
From: Max Reitz When closing a connection, make the nbd-fault-injector flush the socket. Without this, the output is a bit unreliable with Python 3. Signed-off-by: Max Reitz Reviewed-by: Eduardo Habkost Reviewed-by: Cleber Rosa Reviewed-by: Eric Blake Message-Id: <20181022135307.14398-2-mre.

[Qemu-devel] [PATCH v3 06/13] arm: Instantiate NRF51 special NVM's and NVMC

2018-10-30 Thread Steffen Görtz
Instantiates UICR, FICR and NVMC in nRF51 SOC. Signed-off-by: Steffen Görtz --- hw/arm/nrf51_soc.c | 37 ++--- include/hw/arm/nrf51_soc.h | 2 ++ 2 files changed, 36 insertions(+), 3 deletions(-) diff --git a/hw/arm/nrf51_soc.c b/hw/arm/nrf51_soc.c index

[Qemu-devel] [PATCH v3 05/13] hw/nvram/nrf51_nvm: Add nRF51 non-volatile memories

2018-10-30 Thread Steffen Görtz
The nRF51 contains three regions of non-volatile memory (NVM): - CODE (R/W): contains code - FICR (R): Factory information like code size, chip id etc. - UICR (R/W): Changeable configuration data. Lock bits, Code protection configuration, Bootloader address, Nordic SoftRadio configuration, Firm

[Qemu-devel] [PATCH v3 07/13] tests: Add bbc:microbit / nRF51 test suite

2018-10-30 Thread Steffen Görtz
The microbit-test includes tests for the nRF51 NVMC peripheral and will host future nRF51 peripheral tests and board-level bbc:microbit tests. Signed-off-by: Steffen Görtz --- tests/Makefile.include | 2 + tests/microbit-test.c | 117 + 2 files changed,

[Qemu-devel] [PATCH v3 04/13] arm: Instantiate NRF51 random number generator

2018-10-30 Thread Steffen Görtz
Use RNG in SOC. Signed-off-by: Steffen Görtz --- hw/arm/nrf51_soc.c | 16 include/hw/arm/nrf51_soc.h | 2 ++ 2 files changed, 18 insertions(+) diff --git a/hw/arm/nrf51_soc.c b/hw/arm/nrf51_soc.c index 55f8eaafcb..d2a19b8ead 100644 --- a/hw/arm/nrf51_soc.c +++ b/hw/arm

[Qemu-devel] [PATCH v3 13/13] arm: Add Clock peripheral stub to NRF51 SOC

2018-10-30 Thread Steffen Görtz
This stubs enables the microbit-micropython firmware to run on the microbit machine. Signed-off-by: Steffen Görtz --- hw/arm/nrf51_soc.c | 27 +++ include/hw/arm/nrf51_soc.h | 1 + 2 files changed, 28 insertions(+) diff --git a/hw/arm/nrf51_soc.c b/hw/arm/nrf51_

[Qemu-devel] [PATCH v3 01/13] qtest: Add set_irq_in command to set IRQ/GPIO level

2018-10-30 Thread Steffen Görtz
Adds a new qtest command "set_irq_in" which allows to set qemu gpio lines to a given level. Based on https://lists.gnu.org/archive/html/qemu-devel/2012-12/msg02363.html which never got merged. Signed-off-by: Steffen Görtz Originally-by: Matthew Ogilvie --- qtest.c | 40 +++

[Qemu-devel] [PATCH v3 03/13] hw/misc/nrf51_rng: Add NRF51 random number generator peripheral

2018-10-30 Thread Steffen Görtz
Add a model of the NRF51 random number generator peripheral. This is a simple random generator that continuously generates new random values after startup. Reference Manual: http://infocenter.nordicsemi.com/pdf/nRF51_RM_v3.0.pdf Signed-off-by: Steffen Görtz Reviewed-by: Stefan Hajnoczi --- hw/

[Qemu-devel] [PATCH v3 09/13] arm: Instantiate NRF51 general purpose I/O

2018-10-30 Thread Steffen Görtz
Instantiates GPIO peripheral model Signed-off-by: Steffen Görtz --- hw/arm/nrf51_soc.c | 16 include/hw/arm/nrf51_soc.h | 2 ++ 2 files changed, 18 insertions(+) diff --git a/hw/arm/nrf51_soc.c b/hw/arm/nrf51_soc.c index fd0efd0ee8..695b335dc5 100644 --- a/hw/arm/nrf51

[Qemu-devel] [PATCH v3 02/13] arm: Add header to host common definition for nRF51 SOC peripherals

2018-10-30 Thread Steffen Görtz
Adds a header that provides definitions that are used across nRF51 peripherals Signed-off-by: Steffen Görtz --- hw/arm/nrf51_soc.c | 33 ++- include/hw/arm/nrf51.h | 44 include/hw/char/nrf51_uart.h | 1 - 3 files chan

[Qemu-devel] [PATCH v3 00/13] arm: nRF51 Devices and Microbit Support

2018-10-30 Thread Steffen Görtz
This series contains additional peripheral devices for the nRF51822 microcontroller. Included devices: - Random Number Generator - Non-volatile Memories - General purpose I/O - Timer - Stub for clock peripheral v3: * Included device instantiation in this patch * All devices use the comm

[Qemu-devel] [PATCH] hw/timer/sun4v-rtc: Fix tracing at sun4v_rtc_write()

2018-10-30 Thread Eduardo Habkost
The code was converted to use sun4v_rtc_read() by mistake, fix it. Reported-by: David Gibson Cc: Philippe Mathieu-Daudé Signed-off-by: Eduardo Habkost --- hw/timer/sun4v-rtc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/timer/sun4v-rtc.c b/hw/timer/sun4v-rtc.c index

Re: [Qemu-devel] [PATCH 1/4] add QemuSupportState

2018-10-30 Thread Eduardo Habkost
On Tue, Oct 30, 2018 at 06:37:42PM +0100, Philippe Mathieu-Daudé wrote: > On 30/10/18 16:46, Cornelia Huck wrote: > > On Tue, 30 Oct 2018 15:13:45 +0100 > > Philippe Mathieu-Daudé wrote: > > > > > On 30/10/18 15:00, Gerd Hoffmann wrote: > > > > On Tue, Oct 30, 2018 at 02:32:40PM +0100, Philippe M

Re: [Qemu-devel] [PATCH 1/9] qom/user-creatable: add a few helper macros

2018-10-30 Thread Eduardo Habkost
On Tue, Oct 30, 2018 at 03:22:43PM +0100, Igor Mammedov wrote: > On Tue, 30 Oct 2018 13:26:40 +0400 > Marc-André Lureau wrote: > > > Hi > > > > On Tue, Oct 30, 2018 at 5:37 AM Eduardo Habkost wrote: > > > > > > On Mon, Oct 29, 2018 at 10:56:57AM +0100, Igor Mammedov wrote: > > > > On Fri, 26

Re: [Qemu-devel] [PATCH for-3.1] hw/ppc/ppc440_uc: Remove dead code in sdram_size()

2018-10-30 Thread BALATON Zoltan
On Tue, 30 Oct 2018, Peter Maydell wrote: Coverity points out in CID 1390588 that the test for sh == 0 in sdram_size() can never fire, because we calculate sh with sh = 1024 - ((bcr >> 6) & 0x3ff); which must result in a value between 1 and 1024 inclusive. Without the relevant manual for the

Re: [Qemu-devel] [PATCH 3/3] arm: allwinner: Enable USB EHCI

2018-10-30 Thread Philippe Mathieu-Daudé
Hi Gerd, On 30/10/18 7:38, Gerd Hoffmann wrote: On Mon, Oct 29, 2018 at 11:32:07PM +0100, Philippe Mathieu-Daudé wrote: From: Guenter Roeck Signed-off-by: Guenter Roeck Reviewed-by: Philippe Mathieu-Daudé [PMD: Intented tabs -> space] Signed-off-by: Philippe Mathieu-Daudé --- hw/arm/allw

[Qemu-devel] [PULL v2 1/5] tests/tpm: fix tpm_util_swtpm_has_tpm2()

2018-10-30 Thread Stefan Berger
From: Marc-André Lureau Using g_spawn_async_with_pipes() is more complicated than running the sync version. The async version returns a file descriptor for stdout, which may not be fully read. Sometime "--tpm2" will failed to be read, and will cause the related test to be silently skipped. Use g

[Qemu-devel] [PULL v2 2/5] tests/tpm: Display if swtpm is not found or --tpm2 not supported

2018-10-30 Thread Stefan Berger
From: Marc-André Lureau If swtpm is not found in $PATH or --tpm2 isn't supported, we display this in the test log. We cannot mark the test as skipped due to a bug in certain versions of the gtester environment that interprets a skipped test as failure. Signed-off-by: Marc-André Lureau Reviewed-

[Qemu-devel] [PULL v2 3/5] docs: tpm: Mention implemented TPM CRB interface emulation and specs

2018-10-30 Thread Stefan Berger
From: Stefan Berger Add a few sentences about the implemented emulation of the TPM CRB interface and its specification. Signed-off-by: Stefan Berger Reviewed-by: Marc-André Lureau --- docs/specs/tpm.txt | 15 +++ 1 file changed, 15 insertions(+) diff --git a/docs/specs/tpm.txt b/

[Qemu-devel] [PULL v2 4/5] MAINTAINERS: Change my email address to the new domain

2018-10-30 Thread Stefan Berger
From: Stefan Berger My old email address will soon not work anymore, so change it to the new domain. Signed-off-by: Stefan Berger --- MAINTAINERS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/MAINTAINERS b/MAINTAINERS index 40672c4eba..332353ce5c 100644 --- a/MAINTAINERS

[Qemu-devel] [PULL v2 0/5] Merge tpm 2018/10/29 v2

2018-10-30 Thread Stefan Berger
This pull request fixes a couple of TPM support related issues, such as full initialization of a variable to quiet down valgrind, a possible race in the TPM related test cases and marking test cases as skipped if swtpm was not found in PATH. Stefan The following changes since commit a4d710251

Re: [Qemu-devel] [PATCH RFC v6 5/7] migration: fix the multifd code when receiving less channels

2018-10-30 Thread Peter Xu
On Tue, Oct 30, 2018 at 06:05:18PM +0800, Fei Li wrote: [...] > > > @@ -1366,6 +1373,10 @@ bool multifd_recv_new_channel(QIOChannel *ioc) > > > QEMU_THREAD_JOINABLE); > > > atomic_inc(&multifd_recv_state->count); > > > return multifd_recv_state->count == migra

[Qemu-devel] [PULL v2 5/5] tpm: Zero-init structure to avoid uninitialized variables in valgrind log

2018-10-30 Thread Stefan Berger
From: Stefan Berger Zero-init the ptm_loc structure so that we don't have fields that are not initialised. Signed-off-by: Stefan Berger Reviewed-by: Philippe Mathieu-Daudé --- hw/tpm/tpm_emulator.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/tpm/tpm_emulator.c b/hw/tpm/tpm_emulator

[Qemu-devel] [PATCH v6 5/5] hw/riscv/virt: Connect a VirtIO net PCIe device

2018-10-30 Thread Alistair Francis
Signed-off-by: Alistair Francis --- default-configs/riscv32-softmmu.mak | 1 + default-configs/riscv64-softmmu.mak | 1 + hw/riscv/virt.c | 16 +++- 3 files changed, 17 insertions(+), 1 deletion(-) diff --git a/default-configs/riscv32-softmmu.mak b/default-conf

[Qemu-devel] [PATCH v6 2/5] hw/riscv/virt: Connect the gpex PCIe

2018-10-30 Thread Alistair Francis
Connect the gpex PCIe device based on the device tree included in the HiFive Unleashed ROM. Signed-off-by: Alistair Francis --- default-configs/riscv32-softmmu.mak | 6 +- default-configs/riscv64-softmmu.mak | 6 +- hw/riscv/virt.c | 111 incl

[Qemu-devel] [PATCH v6 3/5] riscv: Enable VGA and PCIE_VGA

2018-10-30 Thread Alistair Francis
Enable compile support for VGA devices. This allows the user to conenct a display by adding '-device bochs-display -display sdl' to their command line argument. Signed-off-by: Alistair Francis --- default-configs/riscv32-softmmu.mak | 3 +++ default-configs/riscv64-softmmu.mak | 3 +++ 2 files c

[Qemu-devel] [PATCH v6 4/5] hw/riscv/sifive_u: Connect the Xilinx PCIe

2018-10-30 Thread Alistair Francis
Connect the Xilinx PCIe device based on the information in the device tree stored in the ROM of the HiFish Unleashed board. Signed-off-by: Alistair Francis --- hw/riscv/sifive_u.c | 64 + include/hw/riscv/sifive_u.h | 4 ++- 2 files changed, 67 insert

[Qemu-devel] [PATCH v6 1/5] hw/riscv/virt: Increase the number of interrupts

2018-10-30 Thread Alistair Francis
Increase the number of interrupts to match the HiFive Unleashed board. Signed-off-by: Alistair Francis --- include/hw/riscv/virt.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/hw/riscv/virt.h b/include/hw/riscv/virt.h index 91163d6cbf..7cb2742070 100644 --- a/inclu

[Qemu-devel] [PATCH v6 0/5] Connect a PCIe host and graphics support to RISC-V

2018-10-30 Thread Alistair Francis
V6: - Fix the interrupt issue for the GPEX device V5: - Rebase - Include pci.mak in the default configs V4: - Fix the spike device tree - Don't use stdvga device V3: - Remove Makefile config changes - Connect a network adapter to the virt device V2: - Use the gpex PCIe host for virt - Add

[Qemu-devel] [PATCH v3] lsi_scsi: Reselection needed to remove pending commands from queue

2018-10-30 Thread George Kennedy
Under heavy IO (e.g. fio) the queue is not checked frequently enough for pending commands. As a result some pending commands are timed out by the linux sym53c8xx driver, which sends SCSI Abort messages for the timed out commands. The SCSI Abort messages result in linux errors, which show up on the

Re: [Qemu-devel] [PATCH v3 01/16] hw/cpu: introduce CPU clusters

2018-10-30 Thread Philippe Mathieu-Daudé
Hi Luc, On 26/10/18 10:16, Luc Michel wrote: This commit adds the cpu-cluster type. It aims at gathering CPUs from the same cluster in a machine. For now it only has a `cluster-id` property. Signed-off-by: Luc Michel --- include/hw/cpu/cluster.h | 38 +++ hw/cpu

Re: [Qemu-devel] [PATCH v5 2/5] hw/riscv/virt: Connect the gpex PCIe

2018-10-30 Thread Alistair Francis
On Thu, Oct 25, 2018 at 11:47 AM Peter Maydell wrote: > > On 4 October 2018 at 21:06, Alistair Francis wrote: > > Connect the gpex PCIe device based on the device tree included in the > > HiFive Unleashed ROM. > > > > Signed-off-by: Alistair Francis > > --- > > default-configs/riscv32-softmmu.m

Re: [Qemu-devel] [PULL 2/3] Add Alistair as a RISC-V Maintainer

2018-10-30 Thread Alistair Francis
On Tue, Oct 30, 2018 at 2:23 PM Palmer Dabbelt wrote: > > Alistair has been contributing to the RISC-V QEMU port for a while now > so I'd like him to be officially listed as a maintainer. I've checked > with the other RISC-V maintainers and there are no objections, and I've > also checked with Al

Re: [Qemu-devel] [PATCH 2/4] scsi-generic: avoid out-of-bounds access to VPD page list

2018-10-30 Thread Philippe Mathieu-Daudé
On 29/10/18 18:34, Paolo Bonzini wrote: A device can report an excessive number of VPD pages when asked for a list; this can cause an out-of-bounds access to buf in scsi_generic_set_vpd_bl_emulation. It should not happen, but it is technically not incorrect so handle it: do not check any byte pa

[Qemu-devel] [PR RFC] RISC-V Patches for the 3.1 Soft Freeze, Part 2

2018-10-30 Thread Palmer Dabbelt
Since this is the first time I've actually done this for QEMU, I thought I'd write up a bit of a header describing how I intend to handle RISC-V pull requests. This is modeled after how I've been doing things in Linux, where it seems to work out fairly well. My flow is to: * Collect reviews over

[Qemu-devel] [PULL 3/3] Add qemu-ri...@nongnu.org as the RISC-V list

2018-10-30 Thread Palmer Dabbelt
We now have a RISC-V specific QEMU development list. Reviewed-by: Alistair Francis Reviewed-by: Philippe Mathieu-Daudé Tested-by: Philippe Mathieu-Daudé Signed-off-by: Palmer Dabbelt --- MAINTAINERS | 1 + 1 file changed, 1 insertion(+) diff --git a/MAINTAINERS b/MAINTAINERS index d550fd8b80

[Qemu-devel] [PULL 2/3] Add Alistair as a RISC-V Maintainer

2018-10-30 Thread Palmer Dabbelt
Alistair has been contributing to the RISC-V QEMU port for a while now so I'd like him to be officially listed as a maintainer. I've checked with the other RISC-V maintainers and there are no objections, and I've also checked with Alistair so he knows I'm volunteering him. Signed-off-by: Palmer D

[Qemu-devel] [PULL 1/3] target/riscv/pmp.c: pmpcfg_csr_read returns bogus value on RV64

2018-10-30 Thread Palmer Dabbelt
From: Dayeol Lee pmp_read_cfg() returns 8-bit value, which is combined together to form a single pmpcfg CSR. The default promotion rules will result in an integer here ("i*8" is integer, which flows through) resulting in a 32-bit signed value on most hosts. That's bogus on RV64I, with the high

Re: [Qemu-devel] [PULL 00/24] qemu-ga patch queue for soft-freeze

2018-10-30 Thread Michael Roth
Quoting Peter Maydell (2018-10-30 13:49:18) > On 30 October 2018 at 14:43, Michael Roth wrote: > > The following changes since commit 62b658db1df7c6fa574caae038144f24bf6ca495: > > > > Merge remote-tracking branch 'remotes/stefanha/tags/block-pull-request' > > into staging (2018-10-29 17:03:27 +

  1   2   3   4   5   >