On 09/10/17 22:10 -0700, Dan Williams wrote:
> On Sun, Sep 10, 2017 at 9:37 PM, Haozhong Zhang
> wrote:
> > The kernel NVDIMM driver and the traditional NVDIMM management
> > utilities in Dom0 does not work now. 'xen-ndctl' is added as an
> > alternatively, which manages
branch xen-unstable
xenbranch xen-unstable
job test-amd64-i386-xl-qemuu-win10-i386
testid xen-boot
Tree: linux git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6.git
Tree: linuxfirmware git://xenbits.xen.org/osstest/linux-firmware.git
Tree: qemu
On Sun, Sep 10, 2017 at 9:37 PM, Haozhong Zhang
wrote:
> The kernel NVDIMM driver and the traditional NVDIMM management
> utilities in Dom0 does not work now. 'xen-ndctl' is added as an
> alternatively, which manages NVDIMM via Xen hypercalls.
>
> Signed-off-by: Haozhong
Hi,
This series seems to have some coding style problems. See output below for
more information:
Subject: [Qemu-devel] [RFC QEMU PATCH v3 00/10] Implement vNVDIMM for Xen HVM
guest
Message-id: 20170911044157.15403-1-haozhong.zh...@intel.com
Type: series
=== TEST SCRIPT BEGIN ===
#!/bin/bash
flight 113275 ovmf real [real]
http://logs.test-lab.xenproject.org/osstest/logs/113275/
Regressions :-(
Tests which did not succeed and are blocking,
including tests which could not be run:
build-amd64 6 xen-buildfail REGR. vs. 113143
build-i386
Xen relies on QEMU to build the guest NFIT.
Signed-off-by: Haozhong Zhang
---
Cc: "Michael S. Tsirkin"
Cc: Igor Mammedov
Cc: Xiao Guangrong
---
hw/acpi/nvdimm.c | 6 ++
1 file changed, 6
The memory region of vNVDIMM on Xen is a RAM memory region, so
memory_region_get_ram_ptr() cannot be used in nvdimm_realize() to get
a pointer to the label data area in that region. To be worse, it may
abort QEMU. As Xen currently does not support labels (i.e. label size
is 0) and every access in
If the machine option 'nvdimm' is enabled and QEMU is used as Xen
device model, construct the guest NFIT and ACPI namespace devices of
vNVDIMM and copy them into guest memory.
Signed-off-by: Haozhong Zhang
---
Cc: "Michael S. Tsirkin"
Cc: Igor Mammedov
Xen relies on QEMU to build the ACPI namespace device of vNVDIMM for
Xen guest.
Signed-off-by: Haozhong Zhang
---
Cc: "Michael S. Tsirkin"
Cc: Igor Mammedov
Cc: Xiao Guangrong
---
hw/acpi/nvdimm.c |
This is the QEMU part patches that works with the associated Xen
patches to enable vNVDIMM support for Xen HVM domains. Xen relies on
QEMU to build guest NFIT and NVDIMM namespace devices, and allocate
guest address space for vNVDIMM devices.
All patches can be found at
Xen:
The guest physical address of vNVDIMM is allocated from the hotplug
memory region, which is not created when QEMU is used as Xen device
model. In order to use vNVDIMM for Xen HVM domains, this commit reuses
the code for pc machine type to create the hotplug memory region for
Xen HVM domains.
Probe the base address and the length of guest ACPI buffer reserved
for copying ACPI from QEMU.
Signed-off-by: Haozhong Zhang
---
Cc: Stefano Stabellini
cc: Anthony Perard
Cc: "Michael S. Tsirkin"
vNVDIMM requires a host memory backend to allocate its backend
resources to the guest. When QEMU is used as Xen device model, the
backend resource allocation of vNVDIMM is managed out of QEMU. A new
host memory backend 'memory-backend-xen' is introduced to represent
the backend resource allocated
Xen relies on QEMU to build guest ACPI for NVDIMM. However, no fw_cfg
is created when QEMU is used as Xen device model, so QEMU should avoid
using fw_cfg on Xen.
Signed-off-by: Haozhong Zhang
---
Cc: Xiao Guangrong
Cc: "Michael S. Tsirkin"
Xen relies on QEMU to build guest NFIT and NVDIMM namespace devices,
and implements an interface to allow QEMU to copy its ACPI into guest
memory. This commit implements the QEMU side support.
The location of guest memory that can receive QEMU ACPI can be found
from XenStore entries
Xen currently does not support vNVDIMM hotplug and always sets QEMU
option "maxmem" to be just enough for RAM and vNVDIMM, so it's not
necessary to build _FIT method when QEMU is used as Xen device model.
Signed-off-by: Haozhong Zhang
---
Cc: "Michael S. Tsirkin"
Some guest ACPI tables and namespace devices are constructed by Xen,
and should not be loaded from device model. This commit adds their
table signatures and device names into two blacklists, which will be
used to check the collisions between guest ACPI constructed by Xen and
guest ACPI passed from
If some errors happening during QMP initialization can affect the
proper work of a domain, it'd be better to treat them as fatal errors
and abort the creation of that domain. The existing types of QMP
initialization errors are not treated as fatal, and do not abort the
domain creation as before.
A new xl domain configuration
vnvdimms = [ 'type=mfn, backend=START_PMEM_MFN, nr_pages=N', ... ]
is added to specify the virtual NVDIMM devices backed by the specified
host PMEM pages. As the kernel PMEM driver does not work in Dom0 now,
we have to specify MFNs.
Signed-off-by: Haozhong Zhang
For xl configs
vnvdimms = [ 'type=mfn,backend=$PMEM0_MFN,nr_pages=$N0', ... ]
the following qemu options will be built
-machine ,nvdimm
-m ,slots=$NR_SLOTS,maxmem=$MEM_SIZE
-object memory-backend-xen,id=mem1,host-addr=$PMEM0_ADDR,size=$PMEM0_SIZE
-device
libacpi needs to access information placed in XenStore in order to
load ACPI built by the device model.
Signed-off-by: Haozhong Zhang
---
Cc: Jan Beulich
Cc: Andrew Cooper
Cc: Ian Jackson
Cc:
It is used by libacpi to generate SSDTs from ACPI namespace devices
built by the device model.
Signed-off-by: Haozhong Zhang
---
Cc: Andrew Cooper
Cc: Jan Beulich
Cc: Ian Jackson
Cc: Wei Liu
If the option '--mgmt' is present, the command 'list' will list all
PMEM regions for management usage.
Signed-off-by: Haozhong Zhang
---
Cc: Ian Jackson
Cc: Wei Liu
---
tools/misc/xen-ndctl.c | 39
Allow XEN_SYSCTL_nvdimm_pmem_get_regions to return a list of data PMEM
regions.
Signed-off-by: Haozhong Zhang
---
Cc: Ian Jackson
Cc: Wei Liu
Cc: Andrew Cooper
Cc: Jan Beulich
The location of ACPI blobs passed from device modeil is offered in
guest physical address. libacpi needs to convert the guest physical
address to guest virtual address before it can access those ACPI
blobs.
Signed-off-by: Haozhong Zhang
---
Cc: Jan Beulich
ACPI tables built by the device model, whose signatures do not
conflict with tables built by Xen except SSDT, are loaded after ACPI
tables built by Xen.
ACPI namespace devices built by the device model, whose names do not
conflict with devices built by Xen, are assembled and placed in SSDTs
after
Allow XEN_SYSCTL_nvdimm_pmem_get_regions_nr to return the number of
management PMEM regions.
Signed-off-by: Haozhong Zhang
---
Cc: Ian Jackson
Cc: Wei Liu
Cc: Andrew Cooper
Cc: Jan Beulich
Some virtual devices (e.g. NVDIMM) require complex ACPI tables and
definition blocks (in AML), which a device model (e.g. QEMU) has
already been able to construct. Instead of introducing the redundant
implementation to Xen, we would like to reuse the device model to
construct those ACPI stuffs.
The base guest physical address of each vNVDIMM device is decided by
QEMU. Add a QMP callback to get the base address from QEMU and query Xen
hypervisor to map host PMEM pages to that address.
Signed-off-by: Haozhong Zhang
---
Cc: Ian Jackson
A new step RELMEM_pmem is added and taken before RELMEM_xen to release
all PMEM pages mapped to a HVM domain.
Signed-off-by: Haozhong Zhang
---
Cc: Jan Beulich
Cc: Andrew Cooper
Cc: George Dunlap
Replace pdx_to_page(pfn_to_pdx(pfn)) by mfn_to_page(pfn), which is
identical to the former.
Signed-off-by: Haozhong Zhang
---
Cc: Jan Beulich
Cc: Andrew Cooper
---
xen/arch/x86/x86_64/mm.c | 7 +++
1 file changed, 3
... to avoid the inference with the PMEM driver and management
utilities in Dom0.
Signed-off-by: Haozhong Zhang
---
Cc: Jan Beulich
Cc: Andrew Cooper
Cc: Gang Wei
Cc: Shane Wang
The AML builder added later needs to allocate contiguous memory across
multiple calls to mem_ops.alloc(). Therefore, it needs to know the
minimal alignment used by mem_ops.alloc().
Signed-off-by: Haozhong Zhang
---
Cc: Jan Beulich
Cc: Andrew Cooper
As the existing data in PMEM region is persistent, Xen hypervisor has
no knowledge of which part is free to be used for the frame table and
M2P table of that PMEM region. Instead, we will allow users or system
admins to specify the location of those frame table and M2P table.
The location is not
No specification defines that PMEM regions cannot appear in margins
between RAM regions. If that does happen, init_frametable() will need
to allocate RAM for the part of frametable of PMEM regions. However,
PMEM regions can be very large (several terabytes or more), so
init_frametable() may fail.
This hypercall will be used by device models to map host PMEM pages to
guest.
Signed-off-by: Haozhong Zhang
---
Cc: Daniel De Graaf
Cc: Ian Jackson
Cc: Wei Liu
Cc: Andrew Cooper
Add a command XEN_SYSCTL_nvdimm_pmem_setup to hypercall
XEN_SYSCTL_nvdimm_op to setup the frame table and M2P table of a PMEM
region. This command is currently used to setup the management PMEM
region which is used to store the frame table and M2P table of other
PMEM regions and itself. The
Add CONFIG_PMEM to enable NVDIMM persistent memory support. By
default, it's N.
Signed-off-by: Haozhong Zhang
---
Cc: Andrew Cooper
Cc: George Dunlap
Cc: Ian Jackson
Cc: Jan Beulich
XEN_SYSCTL_nvdimm_pmem_get_regions, which is a command of hypercall
XEN_SYSCTL_nvdimm_op, is to get a list of PMEM regions of specified
type (see PMEM_REGION_TYPE_*).
Signed-off-by: Haozhong Zhang
---
Cc: Ian Jackson
Cc: Wei Liu
If the option '--data' is present, the command 'list' will list all
PMEM regions for guest data usage.
Signed-off-by: Haozhong Zhang
---
Cc: Ian Jackson
Cc: Wei Liu
---
tools/misc/xen-ndctl.c | 40
This command is to query Xen hypervisor to setup the specified PMEM
range for guest data usage.
Signed-off-by: Haozhong Zhang
---
Cc: Ian Jackson
Cc: Wei Liu
---
tools/misc/xen-ndctl.c | 36
Allow XEN_SYSCTL_nvdimm_pmem_get_regions_nr to return the number of
data PMEM regions.
Signed-off-by: Haozhong Zhang
---
Cc: Ian Jackson
Cc: Wei Liu
Cc: Andrew Cooper
Cc: Jan Beulich
The kernel NVDIMM driver and the traditional NVDIMM management
utilities in Dom0 does not work now. 'xen-ndctl' is added as an
alternatively, which manages NVDIMM via Xen hypercalls.
Signed-off-by: Haozhong Zhang
---
Cc: Ian Jackson
Cc: Wei
pmem_populate() is added to map the specifed data PMEM pages to a HVM
domain. No called is added in this commit.
Signed-off-by: Haozhong Zhang
---
Cc: Andrew Cooper
Cc: Jan Beulich
---
xen/common/domain.c | 3 ++
cleanup_frame_table() initializes the entire newly added frame table
to all -1's. If it's called after extend_frame_table() failed to map
the entire frame table, the initialization will hit a page fault.
Move the cleanup of partially mapped frametable to extend_frame_table(),
which has enough
Register valid PMEM regions probed via NFIT to Xen hypervisor. No
frametable and M2P table are created for those PMEM regions at this
stage.
Signed-off-by: Haozhong Zhang
---
Cc: Andrew Cooper
Cc: Jan Beulich
---
Allow XEN_SYSCTL_nvdimm_pmem_get_regions to return a list of
management PMEM regions.
Signed-off-by: Haozhong Zhang
---
Cc: Ian Jackson
Cc: Wei Liu
Cc: Andrew Cooper
Cc: Jan Beulich
The current check refuses the hot-plugged memory that falls in one
unused PDX group, which should be allowed.
Signed-off-by: Haozhong Zhang
---
Cc: Jan Beulich
Cc: Andrew Cooper
---
xen/arch/x86/x86_64/mm.c | 6 +-
1
XEN_SYSCTL_nvdimm_pmem_get_rgions_nr, which is a command of hypercall
XEN_SYSCTL_nvdimm_op, is to get the number of PMEM regions of the
specified type (see PMEM_REGION_TYPE_*).
Signed-off-by: Haozhong Zhang
---
Cc: Ian Jackson
Cc: Wei Liu
Allow the command XEN_SYSCTL_nvdimm_pmem_setup of hypercall
XEN_SYSCTL_nvdimm_op to setup a PMEM region for guest data
usage. After the setup, that PMEM region will be able to be
mapped to guest address space.
Signed-off-by: Haozhong Zhang
---
Cc: Ian Jackson
This command is to query Xen hypervisor to setup the specified PMEM
range for the management usage.
Signed-off-by: Haozhong Zhang
---
Cc: Ian Jackson
Cc: Wei Liu
---
tools/misc/xen-ndctl.c | 45
Overview
==
(RFC v2 can be found at
https://lists.xen.org/archives/html/xen-devel/2017-03/msg02401.html)
Well, this RFC v3 changes and inflates a lot from previous versions.
The primary changes are listed below, most of which are to simplify
the first implementation and avoid
XEN_SYSCTL_nvdimm_op will support a set of sub-commands to manage the
physical NVDIMM devices. This commit just adds the framework for this
hypercall, and does not implement any sub-commands.
Signed-off-by: Haozhong Zhang
---
Cc: Daniel De Graaf
Separate the revertible part of memory_add_common(), which will also
be used in PMEM management. The separation will ease the failure
recovery in PMEM management. Several coding-style issues in the
touched code are fixed as well.
No functional change is introduced.
Signed-off-by: Haozhong Zhang
A PMEM region with failures (e.g., not properly flushed in the last
power cycle, or some blocks within it are borken) cannot be safely
used by Xen and guest. Scan the state flags of NVDIMM region mapping
structures in NFIT to check whether any failures happened to a PMEM
region. The recovery of
Two options are supported by command 'list'. '--raw' indicates to list
all PMEM regions detected by Xen hypervisor, which can be later
configured for future usages. '--all' indicates all other
options (i.e. --raw and future options).
Signed-off-by: Haozhong Zhang
---
Hi Felipe, all,
Great that it's going to start :) Looking forward to join :)
Just my 2 cents:
1. Is this academic project, or it have specific goals and areas of
application? Would be good to have some practical use-cases and well
formulated list of problems (we all feel these by guts, but...),
flight 113267 ovmf real [real]
http://logs.test-lab.xenproject.org/osstest/logs/113267/
Regressions :-(
Tests which did not succeed and are blocking,
including tests which could not be run:
build-amd64 6 xen-buildfail REGR. vs. 113143
build-i386
Hi.
I'm working on a scheduling code by which I received a patch regarding
credit scheduler from my professor.
I have had some troubles during that work and I need to make the Xen binary
with 'debug=y' option.
But there was a kernel panic caused by the debugging code triggered by
'debug=y' option
Hi, Roger.
I meet an error when creating a pvh guest. I am using commit 6e2a4c73564a.
From the error log, I found bootlate_pv()->pin_table always failed. And the
failure was caused by is_pv_domain(pg_owner) in do_mmuext_op(). Do you have
any idea on this?
The guest config file is:
builder =
flight 113259 ovmf real [real]
http://logs.test-lab.xenproject.org/osstest/logs/113259/
Regressions :-(
Tests which did not succeed and are blocking,
including tests which could not be run:
build-amd64 6 xen-buildfail REGR. vs. 113143
build-i386
flight 113221 linux-linus real [real]
http://logs.test-lab.xenproject.org/osstest/logs/113221/
Regressions :-(
Tests which did not succeed and are blocking,
including tests which could not be run:
test-amd64-amd64-xl-qcow2broken
test-amd64-i386-qemuu-rhel6hvm-intel 7
branch xen-unstable
xenbranch xen-unstable
job build-i386
testid xen-build
Tree: ovmf https://github.com/tianocore/edk2.git
Tree: qemu git://xenbits.xen.org/qemu-xen-traditional.git
Tree: qemuu git://xenbits.xen.org/qemu-xen.git
Tree: xen git://xenbits.xen.org/xen.git
*** Found and reproduced
flight 113251 ovmf real [real]
http://logs.test-lab.xenproject.org/osstest/logs/113251/
Regressions :-(
Tests which did not succeed and are blocking,
including tests which could not be run:
build-amd64 6 xen-buildfail REGR. vs. 113143
build-i386
This run is configured for baseline tests only.
flight 72088 qemu-mainline real [real]
http://osstest.xs.citrite.net/~osstest/testlogs/logs/72088/
Regressions :-(
Tests which did not succeed and are blocking,
including tests which could not be run:
test-amd64-i386-libvirt-xsm 18
flight 113245 ovmf real [real]
http://logs.test-lab.xenproject.org/osstest/logs/113245/
Regressions :-(
Tests which did not succeed and are blocking,
including tests which could not be run:
build-amd64 6 xen-buildfail REGR. vs. 113143
build-i386
flight 113239 ovmf real [real]
http://logs.test-lab.xenproject.org/osstest/logs/113239/
Regressions :-(
Tests which did not succeed and are blocking,
including tests which could not be run:
build-amd64 6 xen-buildfail REGR. vs. 113143
build-i386
branch xen-unstable
xenbranch xen-unstable
job build-amd64
testid xen-build
Tree: ovmf https://github.com/tianocore/edk2.git
Tree: qemu git://xenbits.xen.org/qemu-xen-traditional.git
Tree: qemuu git://xenbits.xen.org/qemu-xen.git
Tree: xen git://xenbits.xen.org/xen.git
*** Found and reproduced
flight 113234 ovmf real [real]
http://logs.test-lab.xenproject.org/osstest/logs/113234/
Regressions :-(
Tests which did not succeed and are blocking,
including tests which could not be run:
build-amd64 6 xen-buildfail REGR. vs. 113143
build-i386
flight 113229 ovmf real [real]
http://logs.test-lab.xenproject.org/osstest/logs/113229/
Regressions :-(
Tests which did not succeed and are blocking,
including tests which could not be run:
build-amd64 6 xen-buildfail REGR. vs. 113143
build-i386
flight 113209 xen-unstable real [real]
http://logs.test-lab.xenproject.org/osstest/logs/113209/
Failures :-/ but no regressions.
Tests which are failing intermittently (not blocking):
test-amd64-amd64-xl-qemuu-debianhvm-amd64-xsm 16 guest-localmigrate/x10 fail
in 113170 pass in 113209
This run is configured for baseline tests only.
flight 72087 qemu-upstream-unstable real [real]
http://osstest.xs.citrite.net/~osstest/testlogs/logs/72087/
Regressions :-(
Tests which did not succeed and are blocking,
including tests which could not be run:
test-armhf-armhf-xl-multivcpu 7
Hi,
I'm a PhD student from Harvard University having a trouble in running
vTPM manager.
I cannot successfully launch vTPM manager in Xen, because when I
command "sudo xl create vtpm-manager.cfg" to launch a virtual TPM VM,
I get the following error:
libxl: error:
This is late reply but, thank you for your kind reply, Dario Faggioli.
I made the new Xen4.5 binary with 'debug=y' option that I modified and
install it.
Then, there was a kernel panic caused by the debugging code triggered by
'debug=y' during booting process(of dom0):
(XEN) [ Xen-4.5.0
flight 113225 ovmf real [real]
http://logs.test-lab.xenproject.org/osstest/logs/113225/
Regressions :-(
Tests which did not succeed and are blocking,
including tests which could not be run:
build-amd64 6 xen-buildfail REGR. vs. 113143
build-i386
flight 113222 ovmf real [real]
http://logs.test-lab.xenproject.org/osstest/logs/113222/
Regressions :-(
Tests which did not succeed and are blocking,
including tests which could not be run:
build-amd64 6 xen-buildfail REGR. vs. 113143
build-i386
flight 113202 linux-4.9 real [real]
http://logs.test-lab.xenproject.org/osstest/logs/113202/
Failures :-/ but no regressions.
Tests which did not succeed, but are not blocking:
test-amd64-amd64-xl-qemut-win7-amd64 18 guest-start/win.repeat fail like 113154
test-amd64-amd64-xl-qemuu-win7-amd64
This run is configured for baseline tests only.
flight 72086 linux-3.18 real [real]
http://osstest.xs.citrite.net/~osstest/testlogs/logs/72086/
Failures :-/ but no regressions.
Tests which did not succeed, but are not blocking:
test-arm64-arm64-libvirt-xsm 1 build-check(1)
flight 113215 ovmf real [real]
http://logs.test-lab.xenproject.org/osstest/logs/113215/
Regressions :-(
Tests which did not succeed and are blocking,
including tests which could not be run:
build-amd64 6 xen-buildfail REGR. vs. 113143
build-i386
flight 113189 linux-linus real [real]
http://logs.test-lab.xenproject.org/osstest/logs/113189/
Regressions :-(
Tests which did not succeed and are blocking,
including tests which could not be run:
test-amd64-i386-qemuu-rhel6hvm-intel 7 xen-boot fail REGR. vs. 113031
On Sat, Sep 09, 2017 at 05:47:35PM -0700, Pry Mar wrote:
> Adding runstatedir to config/Paths.mk.in
>
> From 0c2c36e92318046eb21a0dbc39bdb02d4288d83d Mon Sep 17 00:00:00 2001
> From: Mark
> Date: Sat, 9 Sep 2017 16:58:25 -0700
> Subject: [PATCH] add runstatedir to Paths.mk
>
flight 113214 xen-unstable-coverity real [real]
http://logs.test-lab.xenproject.org/osstest/logs/113214/
Perfect :-)
All tests in this flight passed as required
version targeted for testing:
xen 70892c317fd56064b09a4b0fcaa0781735e64efc
baseline version:
xen
flight 113206 ovmf real [real]
http://logs.test-lab.xenproject.org/osstest/logs/113206/
Regressions :-(
Tests which did not succeed and are blocking,
including tests which could not be run:
build-amd64 6 xen-buildfail REGR. vs. 113143
build-i386
On Fri, Sep 08, 2017 at 12:53:47AM -0700, Christoph Hellwig wrote:
> > +/*
> > + * Lookup the page table entry for a virtual address and return a pointer
> > to
> > + * the entry. Based on x86 tree.
> > + */
> > +static pte_t *lookup_address(unsigned long addr)
>
> Seems like this should be
flight 113179 qemu-mainline real [real]
http://logs.test-lab.xenproject.org/osstest/logs/113179/
Failures :-/ but no regressions.
Tests which are failing intermittently (not blocking):
test-amd64-amd64-xl-qemuu-win7-amd64 16 guest-localmigrate/x10 fail in 113160
pass in 113179
flight 113170 xen-unstable real [real]
http://logs.test-lab.xenproject.org/osstest/logs/113170/
Failures :-/ but no regressions.
Tests which are failing intermittently (not blocking):
test-amd64-i386-xl-qemuu-win7-amd64 17 guest-stop fail in 113157 pass in 113170
flight 113190 ovmf real [real]
http://logs.test-lab.xenproject.org/osstest/logs/113190/
Regressions :-(
Tests which did not succeed and are blocking,
including tests which could not be run:
build-amd64 6 xen-buildfail REGR. vs. 113143
build-i386
87 matches
Mail list logo