[PATCH 5/5] hw/arm/smmuv3: Report F_STE_FETCH fault address in correct word position

2019-12-04 Thread Simon Veith
The smmuv3_record_event() function that generates the F_STE_FETCH error uses the EVT_SET_ADDR macro to record the fetch address, placing it in 32-bit words 4 and 5. The correct position for this address is in words 6 and 7, per the SMMUv3 Architecture Specification. Update the function to use

Re: [PATCH v2 09/18] qga: Fix guest-get-fsinfo error API violations

2019-12-04 Thread Philippe Mathieu-Daudé
On 12/4/19 10:36 AM, Markus Armbruster wrote: build_guest_fsinfo_for_virtual_device() dereferences @errp when build_guest_fsinfo_for_device() fails. That's wrong; see the big comment in error.h. Introduced in commit 46d4c5723e "qga: Add guest-get-fsinfo command". No caller actually passes

Re: [PATCH] target/i386: relax assert when old host kernels don't include msrs

2019-12-04 Thread Paolo Bonzini
On 04/12/19 16:07, Catherine Ho wrote: >> Ok, so the problem is that some MSR didn't exist in that version. Which > I thought in my platform, the only MSR didn't exist is MSR_IA32_VMX_BASIC > (0x480). If I remove this kvm_msr_entry_add(), everything is ok, the guest can > be boot up successfully.

Re: [PATCH v3 2/4] s390x: Add missing vcpu reset functions

2019-12-04 Thread Cornelia Huck
On Wed, 4 Dec 2019 16:08:48 +0100 David Hildenbrand wrote: > On 04.12.19 16:07, David Hildenbrand wrote: > > On 04.12.19 15:59, Cornelia Huck wrote: > >> On Tue, 3 Dec 2019 08:28:11 -0500 > >> Janosch Frank wrote: > >> > >>> Up to now we only had an ioctl to reset vcpu data QEMU couldn't

Re: [PATCH v4 16/40] target/arm: Rearrange ARMMMUIdxBit

2019-12-04 Thread Alex Bennée
Richard Henderson writes: > Define via macro expansion, so that renumbering of the base ARMMMUIdx > symbols is automatically reflexed in the bit definitions. > > Signed-off-by: Richard Henderson Reviewed-by: Alex Bennée > --- > target/arm/cpu.h | 39 +++

Re: [PATCH] target/i386: relax assert when old host kernels don't include msrs

2019-12-04 Thread Catherine Ho
Hi Paolo [sorry to resend it, seems to reply it incorrectly] On Wed, 4 Dec 2019 at 19:23, Paolo Bonzini wrote: > On 04/12/19 09:50, Catherine Ho wrote: > > Commit 20a78b02d315 ("target/i386: add VMX features") unconditionally > > add vmx msr entry although older host kernels don't include them.

Re: [PATCH v2] qga: fence guest-set-time if hwclock not available

2019-12-04 Thread Michael Roth
Quoting Cornelia Huck (2019-11-28 12:11:00) > The Posix implementation of guest-set-time invokes hwclock to > set/retrieve the time to/from the hardware clock. If hwclock > is not available, the user is currently informed that "hwclock > failed to set hardware clock to system time", which is quite

[PATCH v2 0/7] Enable Travis builds on arm64, ppc64le and s390x

2019-12-04 Thread Thomas Huth
Travis recently added build hosts for arm64, ppc64le and s390x, so this is a welcome addition to our Travis testing matrix. Unfortunately, the builds are running in quite restricted LXD containers there, for example it is not possible to create huge files there (even if they are just sparse), and

Re: [PATCH v6 6/9] docs/clocks: add device's clock documentation

2019-12-04 Thread Damien Hedde
On 12/2/19 4:17 PM, Peter Maydell wrote: > On Wed, 4 Sep 2019 at 13:56, Damien Hedde wrote: >> >> Add the documentation about the clock inputs and outputs in devices. >> >> This is based on the original work of Frederic Konrad. >> >> Signed-off-by: Damien Hedde >> --- >> docs/devel/clock.txt

NBD reconnect on open

2019-12-04 Thread Vladimir Sementsov-Ogievskiy
Hi Eric! There is a question to discuss. We need to make an option to allow nbd-reconnect loop on nbd-open. For example, add optional nbd blockdev option open-reconnect-delay, to make it possible to start qemu with specified nbd connection, when nbd server is down, and make several tries to

Re: virtiofsd: Where should it live?

2019-12-04 Thread Thomas Huth
On 04/12/2019 14.28, Kevin Wolf wrote: > Am 04.12.2019 um 09:17 hat Gerd Hoffmann geschrieben: >> Hi, >> | ... +- qemu-edid >>> >>> Has its own MAINTAINERS section, together with hw/display/edit* and >>> include/hw/display/edid.h. I'm not sure moving it hw/display/ is a good

Re: [PATCH v3] travis.yml: Run tcg tests with tci

2019-12-04 Thread Alex Bennée
Thomas Huth writes: > So far we only have compile coverage for tci. But since commit > 2f160e0f9797c7522bfd0d09218d0c9340a5137c ("tci: Add implementation > for INDEX_op_ld16u_i64") has been included now, we can also run the > "tcg" and "qtest" tests with tci, so let's enable them in Travis

Re: [PATCH v3] travis.yml: Run tcg tests with tci

2019-12-04 Thread Alex Bennée
Richard Henderson writes: > On 12/4/19 12:31 AM, Thomas Huth wrote: >> -# We manually include builds which we disable "make check" for >> +# Check the TCG interpreter (TCI) >> - env: >> -- CONFIG="--enable-debug --enable-tcg-interpreter" >> -- TEST_CMD="" >> +

Re: [PATCH] target/i386: relax assert when old host kernels don't include msrs

2019-12-04 Thread Paolo Bonzini
On 04/12/19 14:33, Catherine Ho wrote: > Hi Paolo > [sorry to resend it, seems to reply it incorrectly] > > On Wed, 4 Dec 2019 at 19:23, Paolo Bonzini > wrote: > > On 04/12/19 09:50, Catherine Ho wrote: > > Commit 20a78b02d315 ("target/i386: add VMX

Re: [PATCH v4 14/40] target/arm: Recover 4 bits from TBFLAGs

2019-12-04 Thread Richard Henderson
On 12/4/19 3:43 AM, Alex Bennée wrote: > I'm not sure if this visual aid helps but here you go: > > * 31 20 1916 15 10 90 > * +--++-+--+ > * | || TBFLAG_A64

Re: [PATCH v2 07/18] hw/core: Fix fit_load_fdt() error handling violations

2019-12-04 Thread Philippe Mathieu-Daudé
On 12/4/19 10:36 AM, Markus Armbruster wrote: fit_load_fdt() passes @errp to fit_image_addr(), then recovers from ENOENT failures. Passing @errp is wrong, because it works only as long as @errp is neither @error_fatal nor @error_abort. Messed up in commit 3eb99edb48 "loader-fit: Wean off

Re: [RFC v5 024/126] error: auto propagated local_err

2019-12-04 Thread Markus Armbruster
Vladimir Sementsov-Ogievskiy writes: > Here is introduced ERRP_AUTO_PROPAGATE macro, to be used at start of > functions with errp OUT parameter. > > It has three goals: > > 1. Fix issue with error_fatal & error_prepend/error_append_hint: user > can't see this additional information, because

Re: [PATCH v3 2/4] s390x: Add missing vcpu reset functions

2019-12-04 Thread David Hildenbrand
On 04.12.19 16:33, Cornelia Huck wrote: > On Wed, 4 Dec 2019 16:08:48 +0100 > David Hildenbrand wrote: > >> On 04.12.19 16:07, David Hildenbrand wrote: >>> On 04.12.19 15:59, Cornelia Huck wrote: On Tue, 3 Dec 2019 08:28:11 -0500 Janosch Frank wrote: > Up to now we only

[PATCH v2 6/7] configure: allow disable of cross compilation containers

2019-12-04 Thread Thomas Huth
From: Alex Bennée Our docker infrastructure isn't quite as multiarch as we would wish so let's allow the user to disable it if they want. This will allow us to use still run check-tcg on non-x86 CI setups. Signed-off-by: Alex Bennée Reviewed-by: Stefan Weil Signed-off-by: Thomas Huth ---

Re: [PATCH v2 03/13] s390x: protvirt: Support unpack facility

2019-12-04 Thread Janosch Frank
On 12/4/19 12:34 PM, Thomas Huth wrote: > On 04/12/2019 12.32, Janosch Frank wrote: >> On 12/4/19 11:48 AM, Thomas Huth wrote: >>> On 29/11/2019 10.47, Janosch Frank wrote: When a guest has saved a ipib of type 5 and call diagnose308 with subcode 10, we have to setup the protected

Re: [PATCH v2 03/13] s390x: protvirt: Support unpack facility

2019-12-04 Thread Janosch Frank
On 12/4/19 11:48 AM, Thomas Huth wrote: > On 29/11/2019 10.47, Janosch Frank wrote: >> When a guest has saved a ipib of type 5 and call diagnose308 with >> subcode 10, we have to setup the protected processing environment via >> Ultravisor calls. The calls are done by KVM and are exposed via an

Re: virtiofsd: Where should it live?

2019-12-04 Thread Dr. David Alan Gilbert
* Markus Armbruster (arm...@redhat.com) wrote: > Daniel P. Berrangé writes: > > > On Tue, Dec 03, 2019 at 11:06:44AM +, Peter Maydell wrote: > >> On Tue, 3 Dec 2019 at 10:53, Dr. David Alan Gilbert > >> wrote: > >> > > >> > We seem to be coming to the conclusion something that: > >> > > >>

Re: [PATCH v2 08/13] s390x: protvirt: Add new VCPU reset functions

2019-12-04 Thread Thomas Huth
On 29/11/2019 10.48, Janosch Frank wrote: > CPU resets for protected guests need to be done via Ultravisor > calls. Hence we need a way to issue these calls for each reset. > > As we formerly had only one reset function and it was called for > initial, as well as for the clear reset, we now need

Re: [PATCH] Revert "qemu-options.hx: Update for reboot-timeout parameter"

2019-12-04 Thread Dr. David Alan Gilbert
* Han Han (h...@redhat.com) wrote: > This reverts commit bbd9e6985ff342cbe15b9cb7eb30e842796fbbe8. Patchew spotted you're missing the signed-off-by; please send one. Dave > In 20a1922032 we allowed reboot-timeout=-1 again, so update the doc > accordingly. > --- > qemu-options.hx | 4 ++-- > 1

[PATCH 1/5] hw/arm/smmuv3: Apply address mask to linear strtab base address

2019-12-04 Thread Simon Veith
In the SMMU_STRTAB_BASE register, the stream table base address only occupies bits [51:6]. Other bits, such as RA (bit [62]), must be masked out to obtain the base address. The branch for 2-level stream tables correctly applies this mask by way of SMMU_BASE_ADDR_MASK, but the one for linear

[PATCH 2/5] hw/arm/smmuv3: Check stream IDs against actual table LOG2SIZE

2019-12-04 Thread Simon Veith
When checking whether a stream ID is in range of the stream table, we have so far been only checking it against our implementation limit (SMMU_IDR1_SIDSIZE). However, the guest can program the STRTAB_BASE_CFG.LOG2SIZE field to a size that is smaller than this limit. Check the stream ID against

[PATCH 0/5] hw/arm/smmuv3: Correct stream ID and event address handling

2019-12-04 Thread Simon Veith
While working on the Linux SMMUv3 driver, I noticed a few cases where the QEMU SMMUv3 behavior relating to stream tables was inconsistent with our hardware. Also, when debugging those differences, I found that the errors reported through the QEMU SMMUv3 event queue contained the address fields in

[PATCH 4/5] hw/arm/smmuv3: Use correct bit positions in EVT_SET_ADDR2 macro

2019-12-04 Thread Simon Veith
The bit offsets in the EVT_SET_ADDR2 macro do not match those specified in the ARM SMMUv3 Architecture Specification. In all events that use this macro, e.g. F_WALK_EABT, the faulting fetch address or IPA actually occupies the 32-bit words 6 and 7 in the event record contiguously, with the upper

Re: virtiofsd: Where should it live?

2019-12-04 Thread Eric Blake
On 12/4/19 1:43 AM, Markus Armbruster wrote: +- qemu-img | +- qemu-img.c Perhaps this one can all go into existing block/, similar to how pr-manager-helper.c is in scsi/, and virtfs-proxy-helper.c is in fsdev/. Up to the block maintainers, of course. +- qemu-nbd | +-

Re: [PATCH v2 05/18] exec: Fix file_ram_alloc() error API violations

2019-12-04 Thread Philippe Mathieu-Daudé
On 12/4/19 10:36 AM, Markus Armbruster wrote: When os_mem_prealloc() fails, file_ram_alloc() calls qemu_ram_munmap() and returns null. Except it doesn't when its @errp argument is null, because it checks for failure with (errp && *errp). Introduced in commit 056b68af77 "fix qemu exit on memory

[PATCH v2 1/7] iotests: Provide a function for checking the creation of huge files

2019-12-04 Thread Thomas Huth
Some tests create huge (but sparse) files, and to be able to run those tests in certain limited environments (like CI containers), we have to check for the possibility to create such files first. Thus let's introduce a common function to check for large files, and replace the already existing

[PATCH v2 4/7] tests/hd-geo-test: Skip test when images can not be created

2019-12-04 Thread Thomas Huth
In certain environments like restricted containers, we can not create huge test images. To be able to use "make check" in such container environments, too, let's skip the hd-geo-test instead of failing when the test images could not be created. Reviewed-by: Philippe Mathieu-Daudé Reviewed-by:

Re: [PATCH v6 3/9] qdev: add clock input support to devices.

2019-12-04 Thread Damien Hedde
On 12/4/19 10:53 AM, Philippe Mathieu-Daudé wrote: > On 12/4/19 10:05 AM, Damien Hedde wrote: >> On 12/2/19 3:34 PM, Peter Maydell wrote: >>> On Wed, 4 Sep 2019 at 13:56, Damien Hedde >>> wrote: > [...] +/** + * qdev_pass_clock: + * @dev: the device to forward the clock to

Re: virtiofsd: Where should it live?

2019-12-04 Thread Markus Armbruster
"Dr. David Alan Gilbert" writes: > So what do you think of Paolo's suggestion of putting virtiofsd in > fsdev (mkdir fsdev/9p && mv fsdev/* fsdev/9p && mkdir fsdev/virtiofsd ) No objections. Flatter: fsdev-9p/ and fsdev-virtio/. Matter of taste.

Re: NBD reconnect on open

2019-12-04 Thread Kevin Wolf
Am 04.12.2019 um 13:18 hat Vladimir Sementsov-Ogievskiy geschrieben: > There is a question to discuss. > > We need to make an option to allow nbd-reconnect loop on nbd-open. > For example, add optional nbd blockdev option open-reconnect-delay, to > make it possible to start qemu with specified

Re: [PATCH v3] travis.yml: Run tcg tests with tci

2019-12-04 Thread Richard Henderson
On 12/4/19 12:31 AM, Thomas Huth wrote: > -# We manually include builds which we disable "make check" for > +# Check the TCG interpreter (TCI) > - env: > -- CONFIG="--enable-debug --enable-tcg-interpreter" > -- TEST_CMD="" > +- CONFIG="--enable-debug

Re: [PATCH] travis.yml: Drop libcap-dev

2019-12-04 Thread Alex Bennée
Greg Kurz writes: > Commit b1553ab12fe0 converted virtfs-proxy-helper to using libcap-ng. There > aren't any users of libcap anymore. No need to install libcap-dev. > > Signed-off-by: Greg Kurz > --- > > Yet another follow-up to Paolo's patch to use libcap-ng instead of libcap. > Like with

Re: [PATCH v2] qga: fence guest-set-time if hwclock not available

2019-12-04 Thread Cornelia Huck
On Thu, 28 Nov 2019 19:11:00 +0100 Cornelia Huck wrote: > The Posix implementation of guest-set-time invokes hwclock to > set/retrieve the time to/from the hardware clock. If hwclock > is not available, the user is currently informed that "hwclock > failed to set hardware clock to system time",

Re: virtiofsd: Where should it live?

2019-12-04 Thread Eric Blake
On 12/4/19 7:28 AM, Kevin Wolf wrote: Am 04.12.2019 um 09:17 hat Gerd Hoffmann geschrieben: Hi, | ... +- qemu-edid Has its own MAINTAINERS section, together with hw/display/edit* and include/hw/display/edid.h. I'm not sure moving it hw/display/ is a good idea. Gerd?

Re: [PATCH v4 20/40] target/arm: Update arm_mmu_idx for VHE

2019-12-04 Thread Alex Bennée
Richard Henderson writes: > Return the indexes for the EL2&0 regime when the appropriate bits > are set within HCR_EL2. > > Signed-off-by: Richard Henderson Reviewed-by: Alex Bennée > --- > target/arm/helper.c | 11 +-- > 1 file changed, 9 insertions(+), 2 deletions(-) > > diff

Re: qom device lifecycle interaction with hotplug/hotunplug ?

2019-12-04 Thread Eduardo Habkost
On Wed, Dec 04, 2019 at 10:18:24AM +0100, Jens Freimann wrote: > On Tue, Dec 03, 2019 at 06:40:04PM -0300, Eduardo Habkost wrote: > > +jfreimann, +mst > > > > On Sat, Nov 30, 2019 at 11:10:19AM +, Peter Maydell wrote: > > > On Fri, 29 Nov 2019 at 20:05, Eduardo Habkost wrote: > > > > So, to

Re: [PATCH v4 22/40] target/arm: Update aa64_zva_access for EL2

2019-12-04 Thread Alex Bennée
Richard Henderson writes: > The comment that we don't support EL2 is somewhat out of date. > Update to include checks against HCR_EL2.TDZ. > > Signed-off-by: Richard Henderson Reviewed-by: Alex Bennée > --- > target/arm/helper.c | 26 +- > 1 file changed, 21

Re: [PATCH] net/imx_fec: Updating the IMX_FEC IP to support loopback mode.

2019-12-04 Thread Peter Maydell
On Wed, 4 Dec 2019 at 02:15, Jason Wang wrote: > > > On 2019/11/30 上午12:04, Philippe Mathieu-Daudé wrote: > > On Fri, Nov 29, 2019 at 4:59 PM Wasim, Bilal wrote: > >> Thanks for the pointers philippe.. Is the patch okay to be merged without > >> it or do I need to do a re-submission with the

Re: [PATCH v6] error: rename errp to errp_in where it is IN-argument

2019-12-04 Thread Markus Armbruster
Vladimir Sementsov-Ogievskiy writes: > 04.12.2019 16:03, Markus Armbruster wrote: >> Markus Armbruster writes: >> >>> Vladimir Sementsov-Ogievskiy writes: >>> 29.11.2019 17:35, Markus Armbruster wrote: >> [...] > I pushed my fixups to git://repo.or.cz/qemu/armbru.git branch

[PATCH v2 5/7] tests/test-util-filemonitor: Skip test on non-x86 Travis containers

2019-12-04 Thread Thomas Huth
test-util-filemonitor fails in restricted non-x86 Travis containers since they apparently blacklisted some required system calls there. Let's simply skip the test if we detect such an environment. Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Alex Bennée Signed-off-by: Thomas Huth ---

Re: [PATCH v2 2/2] migration: savevm_state_handler_insert: constant-time element insertion

2019-12-04 Thread Dr. David Alan Gilbert
* Scott Cheloha (chel...@linux.vnet.ibm.com) wrote: > savevm_state's SaveStateEntry TAILQ is a priority queue. Priority > sorting is maintained by searching from head to tail for a suitable > insertion spot. Insertion is thus an O(n) operation. > > If we instead keep track of the head of each

[PATCH for-5.0 7/8] acpi: cpuhp: add CPHP_GET_CPU_ID_CMD command

2019-12-04 Thread Igor Mammedov
Extend CPU hotplug interface to return architecture specific identifier for current CPU in 2 registers: - lower 32 bits existing ACPI_CPU_CMD_DATA_OFFSET_RW - upper 32 bits in new ACPI_CPU_CMD_DATA2_OFFSET_R at offset 0. Target user is UEFI firmware, which needs a way to enumerate all CPUs

[PATCH for-5.0 2/8] tests: q35: MCH: add default SMBASE SMRAM lock test

2019-12-04 Thread Igor Mammedov
test lockable SMRAM at default SMBASE feature, introduced by patch "q35: implement 128K SMRAM at default SMBASE address" Signed-off-by: Igor Mammedov --- tests/q35-test.c | 105 +++ 1 file changed, 105 insertions(+) diff --git

[PATCH for-5.0 4/8] acpi: cpuhp: spec: fix 'Command data' description

2019-12-04 Thread Igor Mammedov
Correct returned value description in case 'Command field' == 0x0, it's in not PXM but CPU selector value with pending event In addition describe 0 blanket value in case of not supported 'Command field' value. Signed-off-by: Igor Mammedov --- docs/specs/acpi_cpu_hotplug.txt | 11 +-- 1

[PATCH for-5.0 3/8] acpi: cpuhp: spec: clarify 'CPU selector' register usage and endianness

2019-12-04 Thread Igor Mammedov
* Move reserved registers to the top of the section, so reader would be aware of effects when reading registers description. * State registers endianness explicitly at the beginning of the section * Describe registers behavior in case of 'CPU selector' register contains value that doesn't

Re: [PATCH v4 26/40] target/arm: Update define_one_arm_cp_reg_with_opaque for VHE

2019-12-04 Thread Alex Bennée
Richard Henderson writes: > For ARMv8.1, op1 == 5 is reserved for EL2 aliases of > EL1 and EL0 registers. > > Signed-off-by: Richard Henderson > --- > target/arm/helper.c | 5 + > 1 file changed, 1 insertion(+), 4 deletions(-) > > diff --git a/target/arm/helper.c b/target/arm/helper.c >

Re: [PATCH v2 1/5] virtiofsd: Get rid of unused fields in fv_QueueInfo

2019-12-04 Thread Dr. David Alan Gilbert
* Vivek Goyal (vgo...@redhat.com) wrote: > There are some unused fields in "struct fv_QueueInfo". Get rid of these > fields. > > Signed-off-by: Vivek Goyal > --- > contrib/virtiofsd/fuse_virtio.c | 6 -- > 1 file changed, 6 deletions(-) > > diff --git a/contrib/virtiofsd/fuse_virtio.c

Re: [PATCH v2 2/7] iotests: Skip test 060 if it is not possible to create large files

2019-12-04 Thread Philippe Mathieu-Daudé
On 12/4/19 4:46 PM, Thomas Huth wrote: Test 060 fails in the arm64, s390x and ppc64le LXD containers on Travis (which we will hopefully enable in our CI soon). These containers apparently do not allow large files to be created. The repair process in test 060 creates a file of 64 GiB, so test

Re: [PATCH] target/i386: relax assert when old host kernels don't include msrs

2019-12-04 Thread Paolo Bonzini
On 04/12/19 16:47, Eduardo Habkost wrote: > On Wed, Dec 04, 2019 at 04:34:45PM +0100, Paolo Bonzini wrote: >> On 04/12/19 16:07, Catherine Ho wrote: Ok, so the problem is that some MSR didn't exist in that version. Which >>> I thought in my platform, the only MSR didn't exist is

Re: [PATCH v4 23/40] target/arm: Update ctr_el0_access for EL2

2019-12-04 Thread Alex Bennée
Richard Henderson writes: > Update to include checks against HCR_EL2.TID2. > > Signed-off-by: Richard Henderson Reviewed-by: Alex Bennée > --- > target/arm/helper.c | 26 +- > 1 file changed, 21 insertions(+), 5 deletions(-) > > diff --git a/target/arm/helper.c

Re: qom device lifecycle interaction with hotplug/hotunplug ?

2019-12-04 Thread Jens Freimann
On Wed, Dec 04, 2019 at 11:35:37AM -0300, Eduardo Habkost wrote: On Wed, Dec 04, 2019 at 10:18:24AM +0100, Jens Freimann wrote: On Tue, Dec 03, 2019 at 06:40:04PM -0300, Eduardo Habkost wrote: > +jfreimann, +mst > > On Sat, Nov 30, 2019 at 11:10:19AM +, Peter Maydell wrote: > > On Fri, 29

[for-5.0 PATCH 2/4] xics: Don't deassert outputs

2019-12-04 Thread Greg Kurz
The correct way to do this is to deassert the input pins on the CPU side. This is the case since a previous change. Signed-off-by: Greg Kurz --- hw/intc/xics.c |3 --- 1 file changed, 3 deletions(-) diff --git a/hw/intc/xics.c b/hw/intc/xics.c index 0b259a09c545..1952009e6d22 100644 ---

Re: [PATCH 04/10] arm: allwinner-h3: add USB host controller

2019-12-04 Thread Aleksandar Markovic
On Monday, December 2, 2019, Niek Linnenbank wrote: > The Allwinner H3 System on Chip contains multiple USB 2.0 bus > connections which provide software access using the Enhanced > Host Controller Interface (EHCI) and Open Host Controller > Interface (OHCI) interfaces. This commit adds support

Re: [PATCH] target/sparc: Remove old TODO file

2019-12-04 Thread Thomas Huth
On 30/09/2019 19.10, Thomas Huth wrote: > This file hasn't seen a real (non-trivial) update since 2008 anymore, > so we can assume that it is pretty much out of date and nobody cares > for it anymore. Let's simply remove it. > > Signed-off-by: Thomas Huth > --- > target/sparc/TODO | 88

Re: [PATCH v2 2/2] migration: savevm_state_handler_insert: constant-time element insertion

2019-12-04 Thread Dr. David Alan Gilbert
* Scott Cheloha (chel...@linux.vnet.ibm.com) wrote: > On Mon, Oct 21, 2019 at 09:14:44AM +0100, Dr. David Alan Gilbert wrote: > > * David Gibson (da...@gibson.dropbear.id.au) wrote: > > > On Fri, Oct 18, 2019 at 10:43:52AM +0100, Dr. David Alan Gilbert wrote: > > > > * Laurent Vivier

[PATCH for-5.0 8/8] acpi: cpuhp: spec: document procedure for enabling modern CPU hotplug

2019-12-04 Thread Igor Mammedov
Describe how to enable and detect modern CPU hotplug interface. Detection part is based on new CPHP_GET_CPU_ID_CMD command, introduced by "acpi: cpuhp: add CPHP_GET_CPU_ID_CMD command" patch. Signed-off-by: Igor Mammedov --- docs/specs/acpi_cpu_hotplug.txt | 22 -- 1 file

Re: [PATCH v9 Kernel 2/5] vfio iommu: Add ioctl defination to get dirty pages bitmap.

2019-12-04 Thread Alex Williamson
On Wed, 4 Dec 2019 23:40:25 +0530 Kirti Wankhede wrote: > On 12/3/2019 11:34 PM, Alex Williamson wrote: > > On Mon, 25 Nov 2019 19:57:39 -0500 > > Yan Zhao wrote: > > > >> On Fri, Nov 15, 2019 at 05:06:25AM +0800, Alex Williamson wrote: > >>> On Fri, 15 Nov 2019 00:26:07 +0530 > >>> Kirti

Re: qom device lifecycle interaction with hotplug/hotunplug ?

2019-12-04 Thread Eduardo Habkost
On Wed, Dec 04, 2019 at 05:21:25PM +0100, Jens Freimann wrote: > On Wed, Dec 04, 2019 at 11:35:37AM -0300, Eduardo Habkost wrote: > > On Wed, Dec 04, 2019 at 10:18:24AM +0100, Jens Freimann wrote: > > > On Tue, Dec 03, 2019 at 06:40:04PM -0300, Eduardo Habkost wrote: > > > > +jfreimann, +mst > > >

[PATCH v2 3/5] virtiofd: Create a notification queue

2019-12-04 Thread Vivek Goyal
Add a notification queue which will be used to send async notifications for file lock availability. Signed-off-by: Vivek Goyal --- contrib/virtiofsd/fuse_i.h | 1 + contrib/virtiofsd/fuse_virtio.c| 74 +++--- hw/virtio/vhost-user-fs-pci.c

[for-5.0 PATCH 0/4] ppc: Fix interrupt controller emulation

2019-12-04 Thread Greg Kurz
Guest hangs have been observed recently on POWER9 hosts, specifically LC92x "Boston" systems, when the guests are being rebooted multiple times. The issue isn't POWER9 specific though. It is caused by a very long standing bug when using the uncommon accel=kvm,kernel-irqchip=off machine

[for-5.0 PATCH 1/4] ppc: Deassert the external interrupt pin in KVM on reset

2019-12-04 Thread Greg Kurz
When a CPU is reset, QEMU makes sure no interrupt is pending by clearing CPUPPCstate::pending_interrupts in ppc_cpu_reset(). In the case of a complete machine emulation, eg. a sPAPR machine, an external interrupt request could still be pending in KVM though, eg. an IPI. It will be eventually

Re: [PATCH v4 14/40] target/arm: Recover 4 bits from TBFLAGs

2019-12-04 Thread Alex Bennée
Richard Henderson writes: > On 12/4/19 3:43 AM, Alex Bennée wrote: >>> void gen_intermediate_code(CPUState *cpu, TranslationBlock *tb, int >>> max_insns) >>> { >>> -DisasContext dc; >>> +DisasContext dc = { }; >> >> We seemed to have dropped an initialise here which seems

[PATCH for-5.0 6/8] acpi: cpuhp: spec: add typical usecases

2019-12-04 Thread Igor Mammedov
Document work-flows for * finding a CPU with pending 'insert/remove' event * enumerating present and possible CPUs Signed-off-by: Igor Mammedov --- docs/specs/acpi_cpu_hotplug.txt | 29 + 1 file changed, 29 insertions(+) diff --git

[PATCH v2 5/5] virtiofsd: Implement blocking posix locks

2019-12-04 Thread Vivek Goyal
As of now we don't support fcntl(F_SETLKW) and if we see one, we return -EOPNOTSUPP. Change that by accepting these requests and returning a reply immediately asking caller to wait. Once lock is available, send a notification to the waiter indicating lock is available. Signed-off-by: Vivek Goyal

Re: [PATCH v2 3/7] iotests: Skip test 079 if it is not possible to create large files

2019-12-04 Thread Philippe Mathieu-Daudé
On 12/4/19 4:46 PM, Thomas Huth wrote: Test 079 fails in the arm64, s390x and ppc64le LXD containers on Travis (which we will hopefully enable in our CI soon). These containers apparently do not allow large files to be created. Test 079 tries to create a 4G sparse file, which is apparently

[PATCH for-5.0 0/8] q35: CPU hotplug with secure boot, part 1+2

2019-12-04 Thread Igor Mammedov
Series consists of 2 parts: 1st is lockable SMRAM at SMBASE and the 2nd adds means to enumerate APIC IDs for possible CPUs. 1st part [1-2/8]: In order to support CPU hotplug in secure boot mode, UEFI firmware needs to relocate SMI handler of hotplugged CPU, in a way that won't allow ring 0

[PATCH for-5.0 1/8] q35: implement 128K SMRAM at default SMBASE address

2019-12-04 Thread Igor Mammedov
Use commit (2f295167e0 q35/mch: implement extended TSEG sizes) for inspiration and (ab)use reserved register in config space at 0x9c offset [*] to extend q35 pci-host with ability to use 128K at 0x3 as SMRAM and hide it (like TSEG) from non-SMM context. Usage: 1: write 0xff in the register

[PATCH v2 1/5] virtiofsd: Get rid of unused fields in fv_QueueInfo

2019-12-04 Thread Vivek Goyal
There are some unused fields in "struct fv_QueueInfo". Get rid of these fields. Signed-off-by: Vivek Goyal --- contrib/virtiofsd/fuse_virtio.c | 6 -- 1 file changed, 6 deletions(-) diff --git a/contrib/virtiofsd/fuse_virtio.c b/contrib/virtiofsd/fuse_virtio.c index 31c8542b6c..2a9cd60a01

Re: [PATCH] target/i386: relax assert when old host kernels don't include msrs

2019-12-04 Thread Eduardo Habkost
On Wed, Dec 04, 2019 at 04:34:45PM +0100, Paolo Bonzini wrote: > On 04/12/19 16:07, Catherine Ho wrote: > >> Ok, so the problem is that some MSR didn't exist in that version. Which > > I thought in my platform, the only MSR didn't exist is MSR_IA32_VMX_BASIC > > (0x480). If I remove this

Re: [PATCH v2 1/7] iotests: Provide a function for checking the creation of huge files

2019-12-04 Thread Philippe Mathieu-Daudé
On 12/4/19 4:46 PM, Thomas Huth wrote: Some tests create huge (but sparse) files, and to be able to run those tests in certain limited environments (like CI containers), we have to check for the possibility to create such files first. Thus let's introduce a common function to check for large

Re: [PATCH v4 14/40] target/arm: Recover 4 bits from TBFLAGs

2019-12-04 Thread Richard Henderson
On 12/4/19 7:53 AM, Alex Bennée wrote: > > Richard Henderson writes: > >> On 12/4/19 3:43 AM, Alex Bennée wrote: > void gen_intermediate_code(CPUState *cpu, TranslationBlock *tb, int max_insns) { -DisasContext dc; +DisasContext dc = { }; >>> >>> We seemed to

Re: [PATCH 01/10] hw: arm: add Allwinner H3 System-on-Chip

2019-12-04 Thread Philippe Mathieu-Daudé
Hi Niek, On 12/2/19 10:09 PM, Niek Linnenbank wrote: The Allwinner H3 is a System on Chip containing four ARM Cortex A7 processor cores. Features and specifications include DDR2/DDR3 memory, SD/MMC storage cards, 10/100/1000Mbit ethernet, USB 2.0, HDMI and various I/O modules. This commit adds

Re: [PATCH v9 Kernel 2/5] vfio iommu: Add ioctl defination to get dirty pages bitmap.

2019-12-04 Thread Kirti Wankhede
On 12/3/2019 11:34 PM, Alex Williamson wrote: On Mon, 25 Nov 2019 19:57:39 -0500 Yan Zhao wrote: On Fri, Nov 15, 2019 at 05:06:25AM +0800, Alex Williamson wrote: On Fri, 15 Nov 2019 00:26:07 +0530 Kirti Wankhede wrote: On 11/14/2019 1:37 AM, Alex Williamson wrote: On Thu, 14 Nov

Re: [PATCH v4 25/40] target/arm: Update timer access for VHE

2019-12-04 Thread Alex Bennée
Richard Henderson writes: > Signed-off-by: Richard Henderson Reviewed-by: Alex Bennée > --- > target/arm/helper.c | 102 +++- > 1 file changed, 81 insertions(+), 21 deletions(-) > > diff --git a/target/arm/helper.c b/target/arm/helper.c > index

[PATCH v2 0/5] [RFC] virtiofsd, vhost-user-fs: Add support for notification queue

2019-12-04 Thread Vivek Goyal
Hi, Here is V2 of RFC patches for adding a notification queue to vhost-user-fs device to send notifications from host to guest. It also has patches to support remote posix locks which make use of this newly introduced notification queue. I have taken care of most of the comments from last

[PATCH v2 4/5] virtiofsd: Specify size of notification buffer using config space

2019-12-04 Thread Vivek Goyal
Daemon specifies size of notification buffer needed and that should be done using config space. Only ->notify_buf_size value of config space comes from daemon. Rest of it is filled by qemu device emulation code. Signed-off-by: Vivek Goyal --- contrib/virtiofsd/fuse_virtio.c| 31

[PATCH v2 2/5] virtiofsd: Release file locks using F_UNLCK

2019-12-04 Thread Vivek Goyal
We are emulating posix locks for guest using open file description locks in virtiofsd. When any of the fd is closed in guest, we find associated OFD lock fd (if there is one) and close it to release all the locks. Assumption here is that there is no other thread using lo_inode_plock structure or

Re: [PATCH v4 16/40] target/arm: Rearrange ARMMMUIdxBit

2019-12-04 Thread Philippe Mathieu-Daudé
On 12/3/19 3:29 AM, Richard Henderson wrote: Define via macro expansion, so that renumbering of the base ARMMMUIdx symbols is automatically reflexed in the bit definitions. Signed-off-by: Richard Henderson --- target/arm/cpu.h | 39 +++ 1 file changed, 23

Re: [PATCH] target/sparc: Remove old TODO file

2019-12-04 Thread Artyom Tarasenko
On Wed, Dec 4, 2019 at 5:27 PM Thomas Huth wrote: > > On 30/09/2019 19.10, Thomas Huth wrote: > > This file hasn't seen a real (non-trivial) update since 2008 anymore, > > so we can assume that it is pretty much out of date and nobody cares > > for it anymore. Let's simply remove it. > > > >

Re: virtiofsd: Where should it live?

2019-12-04 Thread Dr. David Alan Gilbert
We seem to be settling out to either fsdev/virtiofsd or tools/virtiofsd with tools picking up some speed as people seem to want to put a bunch of other stuff in there. Unless anyone shouts really loud, I'll work on making it tools/virtiofsd. Dave -- Dr. David Alan Gilbert / dgilb...@redhat.com

Re: [PATCH v6 0/9] Clock framework API

2019-12-04 Thread Damien Hedde
On 12/2/19 5:15 PM, Peter Maydell wrote: > > The one topic I think we could do with discussing is whether > a simple uint64_t giving the frequency of the clock in Hz is > the right representation. In particular in your patch 9 the > board has a clock frequency that's not a nice integer number

Re: [PATCH v2 1/2] migration: add savevm_state_handler_remove()

2019-12-04 Thread Dr. David Alan Gilbert
* Scott Cheloha (chel...@linux.vnet.ibm.com) wrote: > Create a function to abstract common logic needed when removing a > SaveStateEntry element from the savevm_state.handlers queue. > > For now we just remove the element. Soon it will involve additional > cleanup. > > Signed-off-by: Scott

[PATCH for-5.0 5/8] acpi: cpuhp: spec: clarify store into 'Command data' when 'Command field' == 0

2019-12-04 Thread Igor Mammedov
Write section of 'Command data' register should describe what happens when it's written into. Correct description in case the last stored 'Command field' value equals to 0, to reflect that currently it's not supported. Signed-off-by: Igor Mammedov --- docs/specs/acpi_cpu_hotplug.txt | 3 +-- 1

Re: [PATCH v2 0/7] Enable Travis builds on arm64, ppc64le and s390x

2019-12-04 Thread Cleber Rosa
On Wed, Dec 04, 2019 at 04:46:11PM +0100, Thomas Huth wrote: > Travis recently added build hosts for arm64, ppc64le and s390x, so > this is a welcome addition to our Travis testing matrix. > > Unfortunately, the builds are running in quite restricted LXD containers > there, for example it is not

Re: [PATCH 02/10] hw: arm: add Xunlong Orange Pi PC machine

2019-12-04 Thread Niek Linnenbank
On Wed, Dec 4, 2019 at 10:03 AM Philippe Mathieu-Daudé wrote: > On 12/3/19 8:33 PM, Niek Linnenbank wrote: > > Hello Philippe, > > > > Thanks for your quick review comments! > > I'll start working on a v2 of the patches and include the changes you > > suggested. > > Thanks, but I'd suggest to

Re: [PATCH 01/10] hw: arm: add Allwinner H3 System-on-Chip

2019-12-04 Thread Niek Linnenbank
Hello Philippe, On Wed, Dec 4, 2019 at 5:53 PM Philippe Mathieu-Daudé wrote: > Hi Niek, > > On 12/2/19 10:09 PM, Niek Linnenbank wrote: > > The Allwinner H3 is a System on Chip containing four ARM Cortex A7 > > processor cores. Features and specifications include DDR2/DDR3 memory, > > SD/MMC

[PATCH-for-5.0] roms/edk2-funcs.sh: Use available GCC for ARM/Aarch64 targets

2019-12-04 Thread Philippe Mathieu-Daudé
Centos 7.7 only provides cross GCC 4.8.5, but the script forces us to use GCC5. Since the same machinery is valid to check the GCC version, remove the $emulation_target check. $ cat /etc/redhat-release CentOS Linux release 7.7.1908 (Core) $ aarch64-linux-gnu-gcc -v 2>&1 | tail -1 gcc

Re: [PATCH 04/10] arm: allwinner-h3: add USB host controller

2019-12-04 Thread Niek Linnenbank
On Wed, Dec 4, 2019 at 5:11 PM Aleksandar Markovic < aleksandar.m.m...@gmail.com> wrote: > > > On Monday, December 2, 2019, Niek Linnenbank > wrote: > >> The Allwinner H3 System on Chip contains multiple USB 2.0 bus >> connections which provide software access using the Enhanced >> Host

Re: [PATCH v6 0/9] Clock framework API

2019-12-04 Thread Philippe Mathieu-Daudé
On 12/4/19 5:40 PM, Damien Hedde wrote: On 12/2/19 5:15 PM, Peter Maydell wrote: The one topic I think we could do with discussing is whether a simple uint64_t giving the frequency of the clock in Hz is the right representation. In particular in your patch 9 the board has a clock frequency

[PATCH-for-5.0] hw/alpha/dp264: Use the DECchip Tulip network interface

2019-12-04 Thread Philippe Mathieu-Daudé
Commit 34ea023d4b9 introduced the Tulip PCI NIC. Since this better models the DP264 hardware, use it. Signed-off-by: Philippe Mathieu-Daudé --- hw/alpha/dp264.c | 4 ++-- hw/alpha/Kconfig | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/hw/alpha/dp264.c b/hw/alpha/dp264.c

[for-5.0 PATCH 4/4] ppc: Ignore the CPU_INTERRUPT_EXITTB interrupt with KVM

2019-12-04 Thread Greg Kurz
This only makes sense with an emulated CPU. Don't set the bit in CPUState::interrupt_request when using KVM to avoid confusions. Signed-off-by: Greg Kurz --- target/ppc/helper_regs.h |5 + 1 file changed, 5 insertions(+) diff --git a/target/ppc/helper_regs.h b/target/ppc/helper_regs.h

[for-5.0 PATCH 3/4] ppc: Don't use CPUPPCState::irq_input_state with modern Book3s CPU models

2019-12-04 Thread Greg Kurz
The power7_set_irq() and power9_set_irq() functions set this but it is never used actually. Modern Book3s compatible CPUs are only supported by the pnv and spapr machines. They have an interrupt controller, XICS for POWER7/8 and XIVE for POWER9, whose models don't require to track IRQ input states

Re: [PATCH v4 26/40] target/arm: Update define_one_arm_cp_reg_with_opaque for VHE

2019-12-04 Thread Alex Bennée
Richard Henderson writes: > On 12/4/19 10:58 AM, Alex Bennée wrote: >>> @@ -7437,13 +7437,10 @@ void define_one_arm_cp_reg_with_opaque(ARMCPU *cpu, >>> mask = PL0_RW; >>> break; >>> case 4: >>> +case 5: >>> /* min_EL EL2 */ >>>

Re: [PATCH v2 2/2] migration: savevm_state_handler_insert: constant-time element insertion

2019-12-04 Thread David Gibson
On Wed, Dec 04, 2019 at 04:49:15PM +, Dr. David Alan Gilbert wrote: > * Scott Cheloha (chel...@linux.vnet.ibm.com) wrote: > > On Mon, Oct 21, 2019 at 09:14:44AM +0100, Dr. David Alan Gilbert wrote: > > > * David Gibson (da...@gibson.dropbear.id.au) wrote: > > > > On Fri, Oct 18, 2019 at

Re: [PATCH v4 26/40] target/arm: Update define_one_arm_cp_reg_with_opaque for VHE

2019-12-04 Thread Richard Henderson
On 12/4/19 10:58 AM, Alex Bennée wrote: >> @@ -7437,13 +7437,10 @@ void define_one_arm_cp_reg_with_opaque(ARMCPU *cpu, >> mask = PL0_RW; >> break; >> case 4: >> +case 5: >> /* min_EL EL2 */ >> mask = PL2_RW; >>

<    1   2   3   >