All of lore.kernel.org
 help / color / mirror / Atom feed
From: Xiao Guangrong <guangrong.xiao@linux.intel.com>
To: pbonzini@redhat.com, imammedo@redhat.com
Cc: gleb@kernel.org, mtosatti@redhat.com, stefanha@redhat.com,
	mst@redhat.com, rth@twiddle.net, ehabkost@redhat.com,
	dan.j.williams@intel.com, kvm@vger.kernel.org,
	qemu-devel@nongnu.org,
	Xiao Guangrong <guangrong.xiao@linux.intel.com>
Subject: [PATCH v6 24/33] nvdimm acpi: build ACPI NFIT table
Date: Fri, 30 Oct 2015 13:56:18 +0800	[thread overview]
Message-ID: <1446184587-142784-25-git-send-email-guangrong.xiao@linux.intel.com> (raw)
In-Reply-To: <1446184587-142784-1-git-send-email-guangrong.xiao@linux.intel.com>

NFIT is defined in ACPI 6.0: 5.2.25 NVDIMM Firmware Interface Table (NFIT)

Currently, we only support PMEM mode. Each device has 3 structures:
- SPA structure, defines the PMEM region info

- MEM DEV structure, it has the @handle which is used to associate specified
  ACPI NVDIMM  device we will introduce in later patch.
  Also we can happily ignored the memory device's interleave, the real
  nvdimm hardware access is hidden behind host

- DCR structure, it defines vendor ID used to associate specified vendor
  nvdimm driver. Since we only implement PMEM mode this time, Command
  window and Data window are not needed

Signed-off-by: Xiao Guangrong <guangrong.xiao@linux.intel.com>
---
 hw/acpi/nvdimm.c        | 355 ++++++++++++++++++++++++++++++++++++++++++++++++
 hw/i386/acpi-build.c    |   6 +
 include/hw/mem/nvdimm.h |  10 ++
 3 files changed, 371 insertions(+)

diff --git a/hw/acpi/nvdimm.c b/hw/acpi/nvdimm.c
index 1223da2..dd84e5f 100644
--- a/hw/acpi/nvdimm.c
+++ b/hw/acpi/nvdimm.c
@@ -26,8 +26,348 @@
  * License along with this library; if not, see <http://www.gnu.org/licenses/>
  */
 
+#include "hw/acpi/acpi.h"
+#include "hw/acpi/aml-build.h"
 #include "hw/mem/nvdimm.h"
 
+static int nvdimm_plugged_device_list(Object *obj, void *opaque)
+{
+    GSList **list = opaque;
+
+    if (object_dynamic_cast(obj, TYPE_NVDIMM)) {
+        NVDIMMDevice *nvdimm = NVDIMM(obj);
+
+        if (memory_region_is_mapped(&nvdimm->nvdimm_mr)) {
+            *list = g_slist_append(*list, DEVICE(obj));
+        }
+    }
+
+    object_child_foreach(obj, nvdimm_plugged_device_list, opaque);
+    return 0;
+}
+
+/*
+ * inquire plugged NVDIMM devices and link them into the list which is
+ * returned to the caller.
+ *
+ * Note: it is the caller's responsibility to free the list to avoid
+ * memory leak.
+ */
+static GSList *nvdimm_get_plugged_device_list(void)
+{
+    GSList *list = NULL;
+
+    object_child_foreach(qdev_get_machine(), nvdimm_plugged_device_list,
+                         &list);
+    return list;
+}
+
+#define NVDIMM_UUID_LE(a, b, c, d0, d1, d2, d3, d4, d5, d6, d7)             \
+   { (a) & 0xff, ((a) >> 8) & 0xff, ((a) >> 16) & 0xff, ((a) >> 24) & 0xff, \
+     (b) & 0xff, ((b) >> 8) & 0xff, (c) & 0xff, ((c) >> 8) & 0xff,          \
+     (d0), (d1), (d2), (d3), (d4), (d5), (d6), (d7) }
+/*
+ * define Byte Addressable Persistent Memory (PM) Region according to
+ * ACPI 6.0: 5.2.25.1 System Physical Address Range Structure.
+ */
+static const uint8_t nvdimm_nfit_spa_uuid[] =
+      NVDIMM_UUID_LE(0x66f0d379, 0xb4f3, 0x4074, 0xac, 0x43, 0x0d, 0x33,
+                     0x18, 0xb7, 0x8c, 0xdb);
+
+/*
+ * NVDIMM Firmware Interface Table
+ * @signature: "NFIT"
+ *
+ * It provides information that allows OSPM to enumerate NVDIMM present in
+ * the platform and associate system physical address ranges created by the
+ * NVDIMMs.
+ *
+ * It is defined in ACPI 6.0: 5.2.25 NVDIMM Firmware Interface Table (NFIT)
+ */
+struct NvdimmNfitHeader {
+    ACPI_TABLE_HEADER_DEF
+    uint32_t reserved;
+} QEMU_PACKED;
+typedef struct NvdimmNfitHeader NvdimmNfitHeader;
+
+/*
+ * define NFIT structures according to ACPI 6.0: 5.2.25 NVDIMM Firmware
+ * Interface Table (NFIT).
+ */
+
+/*
+ * System Physical Address Range Structure
+ *
+ * It describes the system physical address ranges occupied by NVDIMMs and
+ * the types of the regions.
+ */
+struct NvdimmNfitSpa {
+    uint16_t type;
+    uint16_t length;
+    uint16_t spa_index;
+    uint16_t flags;
+    uint32_t reserved;
+    uint32_t proximity_domain;
+    uint8_t type_guid[16];
+    uint64_t spa_base;
+    uint64_t spa_length;
+    uint64_t mem_attr;
+} QEMU_PACKED;
+typedef struct NvdimmNfitSpa NvdimmNfitSpa;
+
+/*
+ * Memory Device to System Physical Address Range Mapping Structure
+ *
+ * It enables identifying each NVDIMM region and the corresponding SPA
+ * describing the memory interleave
+ */
+struct NvdimmNfitMemDev {
+    uint16_t type;
+    uint16_t length;
+    uint32_t nfit_handle;
+    uint16_t phys_id;
+    uint16_t region_id;
+    uint16_t spa_index;
+    uint16_t dcr_index;
+    uint64_t region_len;
+    uint64_t region_offset;
+    uint64_t region_dpa;
+    uint16_t interleave_index;
+    uint16_t interleave_ways;
+    uint16_t flags;
+    uint16_t reserved;
+} QEMU_PACKED;
+typedef struct NvdimmNfitMemDev NvdimmNfitMemDev;
+
+/*
+ * NVDIMM Control Region Structure
+ *
+ * It describes the NVDIMM and if applicable, Block Control Window.
+ */
+struct NvdimmNfitControlRegion {
+    uint16_t type;
+    uint16_t length;
+    uint16_t dcr_index;
+    uint16_t vendor_id;
+    uint16_t device_id;
+    uint16_t revision_id;
+    uint16_t sub_vendor_id;
+    uint16_t sub_device_id;
+    uint16_t sub_revision_id;
+    uint8_t reserved[6];
+    uint32_t serial_number;
+    uint16_t fic;
+    uint16_t num_bcw;
+    uint64_t bcw_size;
+    uint64_t cmd_offset;
+    uint64_t cmd_size;
+    uint64_t status_offset;
+    uint64_t status_size;
+    uint16_t flags;
+    uint8_t reserved2[6];
+} QEMU_PACKED;
+typedef struct NvdimmNfitControlRegion NvdimmNfitControlRegion;
+
+/*
+ * Module serial number is a unique number for each device. We use the
+ * slot id of NVDIMM device to generate this number so that each device
+ * associates with a different number.
+ *
+ * 0x123456 is a magic number we arbitrarily chose.
+ */
+static uint32_t nvdimm_slot_to_sn(int slot)
+{
+    return 0x123456 + slot;
+}
+
+/*
+ * handle is used to uniquely associate nfit_memdev structure with NVDIMM
+ * ACPI device - nfit_memdev.nfit_handle matches with the value returned
+ * by ACPI device _ADR method.
+ *
+ * We generate the handle with the slot id of NVDIMM device and reserve
+ * 0 for NVDIMM root device.
+ */
+static uint32_t nvdimm_slot_to_handle(int slot)
+{
+    return slot + 1;
+}
+
+/*
+ * index uniquely identifies the structure, 0 is reserved which indicates
+ * that the structure is not valid or the associated structure is not
+ * present.
+ *
+ * Each NVDIMM device needs two indexes, one for nfit_spa and another for
+ * nfit_dc which are generated by the slot id of NVDIMM device.
+ */
+static uint16_t nvdimm_slot_to_spa_index(int slot)
+{
+    return (slot + 1) << 1;
+}
+
+/* See the comments of nvdimm_slot_to_spa_index(). */
+static uint32_t nvdimm_slot_to_dcr_index(int slot)
+{
+    return nvdimm_slot_to_spa_index(slot) + 1;
+}
+
+/* ACPI 6.0: 5.2.25.1 System Physical Address Range Structure */
+static void
+nvdimm_build_structure_spa(GArray *structures, NVDIMMDevice *nvdimm)
+{
+    NvdimmNfitSpa *nfit_spa;
+    uint64_t addr = object_property_get_int(OBJECT(nvdimm), DIMM_ADDR_PROP,
+                                            NULL);
+    uint64_t size = object_property_get_int(OBJECT(nvdimm), DIMM_SIZE_PROP,
+                                            NULL);
+    uint32_t node = object_property_get_int(OBJECT(nvdimm), DIMM_NODE_PROP,
+                                            NULL);
+    int slot = object_property_get_int(OBJECT(nvdimm), DIMM_SLOT_PROP,
+                                            NULL);
+
+    nfit_spa = acpi_data_push(structures, sizeof(*nfit_spa));
+
+    nfit_spa->type = cpu_to_le16(0 /* System Physical Address Range
+                                      Structure */);
+    nfit_spa->length = cpu_to_le16(sizeof(*nfit_spa));
+    nfit_spa->spa_index = cpu_to_le16(nvdimm_slot_to_spa_index(slot));
+
+    /*
+     * Control region is strict as all the device info, such as SN, index,
+     * is associated with slot id.
+     */
+    nfit_spa->flags = cpu_to_le16(1 /* Control region is strictly for
+                                       management during hot add/online
+                                       operation */ |
+                                  2 /* Data in Proximity Domain field is
+                                       valid*/);
+
+    /* NUMA node. */
+    nfit_spa->proximity_domain = cpu_to_le32(node);
+    /* the region reported as PMEM. */
+    memcpy(nfit_spa->type_guid, nvdimm_nfit_spa_uuid,
+           sizeof(nvdimm_nfit_spa_uuid));
+
+    nfit_spa->spa_base = cpu_to_le64(addr);
+    nfit_spa->spa_length = cpu_to_le64(size);
+
+    /* It is the PMEM and can be cached as writeback. */
+    nfit_spa->mem_attr = cpu_to_le64(0x8ULL /* EFI_MEMORY_WB */ |
+                                     0x8000ULL /* EFI_MEMORY_NV */);
+}
+
+/*
+ * ACPI 6.0: 5.2.25.2 Memory Device to System Physical Address Range Mapping
+ * Structure
+ */
+static void
+nvdimm_build_structure_memdev(GArray *structures, NVDIMMDevice *nvdimm)
+{
+    NvdimmNfitMemDev *nfit_memdev;
+    uint64_t addr = object_property_get_int(OBJECT(nvdimm), DIMM_ADDR_PROP,
+                                            NULL);
+    uint64_t size = object_property_get_int(OBJECT(nvdimm), DIMM_SIZE_PROP,
+                                            NULL);
+    int slot = object_property_get_int(OBJECT(nvdimm), DIMM_SLOT_PROP,
+                                            NULL);
+    uint32_t handle = nvdimm_slot_to_handle(slot);
+
+    nfit_memdev = acpi_data_push(structures, sizeof(*nfit_memdev));
+
+    nfit_memdev->type = cpu_to_le16(1 /* Memory Device to System Address
+                                         Range Map Structure*/);
+    nfit_memdev->length = cpu_to_le16(sizeof(*nfit_memdev));
+    nfit_memdev->nfit_handle = cpu_to_le32(handle);
+
+    /*
+     * associate memory device with System Physical Address Range
+     * Structure.
+     */
+    nfit_memdev->spa_index = cpu_to_le16(nvdimm_slot_to_spa_index(slot));
+    /* associate memory device with Control Region Structure. */
+    nfit_memdev->dcr_index = cpu_to_le16(nvdimm_slot_to_dcr_index(slot));
+
+    /* The memory region on the device. */
+    nfit_memdev->region_len = cpu_to_le64(size);
+    nfit_memdev->region_dpa = cpu_to_le64(addr);
+
+    /* Only one interleave for PMEM. */
+    nfit_memdev->interleave_ways = cpu_to_le16(1);
+}
+
+/*
+ * ACPI 6.0: 5.2.25.5 NVDIMM Control Region Structure.
+ */
+static void nvdimm_build_structure_dcr(GArray *structures,
+                                       NVDIMMDevice *nvdimm)
+{
+    NvdimmNfitControlRegion *nfit_dcr;
+    int slot = object_property_get_int(OBJECT(nvdimm), DIMM_SLOT_PROP,
+                                       NULL);
+    uint32_t sn = nvdimm_slot_to_sn(slot);
+
+    nfit_dcr = acpi_data_push(structures, sizeof(*nfit_dcr));
+
+    nfit_dcr->type = cpu_to_le16(4 /* NVDIMM Control Region Structure */);
+    nfit_dcr->length = cpu_to_le16(sizeof(*nfit_dcr));
+    nfit_dcr->dcr_index = cpu_to_le16(nvdimm_slot_to_dcr_index(slot));
+
+    /* vendor: Intel. */
+    nfit_dcr->vendor_id = cpu_to_le16(0x8086);
+    nfit_dcr->device_id = cpu_to_le16(1);
+
+    /* The _DSM method is following Intel's DSM specification. */
+    nfit_dcr->revision_id = cpu_to_le16(1 /* Current Revision supported
+                                             in ACPI 6.0 is 1. */);
+    nfit_dcr->serial_number = cpu_to_le32(sn);
+    nfit_dcr->fic = cpu_to_le16(0x201 /* Format Interface Code. See Chapter
+                                         2: NVDIMM Device Specific Method
+                                         (DSM) in DSM Spec Rev1.*/);
+}
+
+static GArray *nvdimm_build_device_structure(GSList *device_list)
+{
+    GArray *structures = g_array_new(false, true /* clear */, 1);
+
+    for (; device_list; device_list = device_list->next) {
+        NVDIMMDevice *nvdimm = device_list->data;
+
+        /* build System Physical Address Range Structure. */
+        nvdimm_build_structure_spa(structures, nvdimm);
+
+        /*
+         * build Memory Device to System Physical Address Range Mapping
+         * Structure.
+         */
+        nvdimm_build_structure_memdev(structures, nvdimm);
+
+        /* build NVDIMM Control Region Structure. */
+        nvdimm_build_structure_dcr(structures, nvdimm);
+    }
+
+    return structures;
+}
+
+static void nvdimm_build_nfit(GSList *device_list, GArray *table_offsets,
+                              GArray *table_data, GArray *linker)
+{
+    GArray *structures = nvdimm_build_device_structure(device_list);
+    void *header;
+
+    acpi_add_table(table_offsets, table_data);
+
+    /* NFIT header. */
+    header = acpi_data_push(table_data, sizeof(NvdimmNfitHeader));
+
+    /* NVDIMM device structures. */
+    g_array_append_vals(table_data, structures->data, structures->len);
+
+    build_header(linker, table_data, header, "NFIT",
+                 sizeof(NvdimmNfitHeader) + structures->len, 1);
+    g_array_free(structures, true);
+}
+
 static uint64_t
 nvdimm_dsm_read(void *opaque, hwaddr addr, unsigned size)
 {
@@ -61,3 +401,18 @@ void nvdimm_init_acpi_state(MemoryRegion *memory, MemoryRegion *io,
                           "nvdimm-acpi-io", NVDIMM_ACPI_IO_LEN);
     memory_region_add_subregion(io, NVDIMM_ACPI_IO_BASE, &state->io_mr);
 }
+
+void nvdimm_build_acpi(GArray *table_offsets, GArray *table_data,
+                       GArray *linker)
+{
+    GSList *device_list;
+
+    /* no NVDIMM device is plugged. */
+    device_list = nvdimm_get_plugged_device_list();
+    if (!device_list) {
+        return;
+    }
+
+    nvdimm_build_nfit(device_list, table_offsets, table_data, linker);
+    g_slist_free(device_list);
+}
diff --git a/hw/i386/acpi-build.c b/hw/i386/acpi-build.c
index 95e0c65..27b2854 100644
--- a/hw/i386/acpi-build.c
+++ b/hw/i386/acpi-build.c
@@ -90,6 +90,7 @@ typedef struct AcpiPmInfo {
     bool s3_disabled;
     bool s4_disabled;
     bool pcihp_bridge_en;
+    bool nvdimm_support;
     uint8_t s4_val;
     uint16_t sci_int;
     uint8_t acpi_enable_cmd;
@@ -231,6 +232,7 @@ static void acpi_get_pm_info(AcpiPmInfo *pm)
     pm->pcihp_bridge_en =
         object_property_get_bool(obj, "acpi-pci-hotplug-with-bridge-support",
                                  NULL);
+    pm->nvdimm_support = object_property_get_bool(obj, "nvdimm-support", NULL);
 }
 
 static void acpi_get_misc_info(AcpiMiscInfo *info)
@@ -1742,6 +1744,10 @@ void acpi_build(PcGuestInfo *guest_info, AcpiBuildTables *tables)
         build_dmar_q35(tables_blob, tables->linker);
     }
 
+    if (pm.nvdimm_support) {
+        nvdimm_build_acpi(table_offsets, tables_blob, tables->linker);
+    }
+
     /* Add tables supplied by user (if any) */
     for (u = acpi_table_first(); u; u = acpi_table_next(u)) {
         unsigned len = acpi_table_len(u);
diff --git a/include/hw/mem/nvdimm.h b/include/hw/mem/nvdimm.h
index f0b1dda..7fdf591 100644
--- a/include/hw/mem/nvdimm.h
+++ b/include/hw/mem/nvdimm.h
@@ -25,6 +25,14 @@
 
 #include "hw/mem/dimm.h"
 
+#define NVDIMM_DEBUG 0
+#define nvdimm_debug(fmt, ...)                                \
+    do {                                                      \
+        if (NVDIMM_DEBUG) {                                   \
+            fprintf(stderr, "nvdimm: " fmt, ## __VA_ARGS__);  \
+        }                                                     \
+    } while (0)
+
 /*
  * The minimum label data size is required by NVDIMM Namespace
  * specification, please refer to chapter 2 Namespaces:
@@ -114,4 +122,6 @@ typedef struct AcpiNVDIMMState AcpiNVDIMMState;
 /* Initialize the memory and IO region needed by NVDIMM ACPI emulation.*/
 void nvdimm_init_acpi_state(MemoryRegion *memory, MemoryRegion *io,
                             Object *owner, AcpiNVDIMMState *state);
+void nvdimm_build_acpi(GArray *table_offsets, GArray *table_data,
+                       GArray *linker);
 #endif
-- 
1.8.3.1


WARNING: multiple messages have this Message-ID (diff)
From: Xiao Guangrong <guangrong.xiao@linux.intel.com>
To: pbonzini@redhat.com, imammedo@redhat.com
Cc: Xiao Guangrong <guangrong.xiao@linux.intel.com>,
	ehabkost@redhat.com, kvm@vger.kernel.org, mst@redhat.com,
	gleb@kernel.org, mtosatti@redhat.com, qemu-devel@nongnu.org,
	stefanha@redhat.com, dan.j.williams@intel.com, rth@twiddle.net
Subject: [Qemu-devel] [PATCH v6 24/33] nvdimm acpi: build ACPI NFIT table
Date: Fri, 30 Oct 2015 13:56:18 +0800	[thread overview]
Message-ID: <1446184587-142784-25-git-send-email-guangrong.xiao@linux.intel.com> (raw)
In-Reply-To: <1446184587-142784-1-git-send-email-guangrong.xiao@linux.intel.com>

NFIT is defined in ACPI 6.0: 5.2.25 NVDIMM Firmware Interface Table (NFIT)

Currently, we only support PMEM mode. Each device has 3 structures:
- SPA structure, defines the PMEM region info

- MEM DEV structure, it has the @handle which is used to associate specified
  ACPI NVDIMM  device we will introduce in later patch.
  Also we can happily ignored the memory device's interleave, the real
  nvdimm hardware access is hidden behind host

- DCR structure, it defines vendor ID used to associate specified vendor
  nvdimm driver. Since we only implement PMEM mode this time, Command
  window and Data window are not needed

Signed-off-by: Xiao Guangrong <guangrong.xiao@linux.intel.com>
---
 hw/acpi/nvdimm.c        | 355 ++++++++++++++++++++++++++++++++++++++++++++++++
 hw/i386/acpi-build.c    |   6 +
 include/hw/mem/nvdimm.h |  10 ++
 3 files changed, 371 insertions(+)

diff --git a/hw/acpi/nvdimm.c b/hw/acpi/nvdimm.c
index 1223da2..dd84e5f 100644
--- a/hw/acpi/nvdimm.c
+++ b/hw/acpi/nvdimm.c
@@ -26,8 +26,348 @@
  * License along with this library; if not, see <http://www.gnu.org/licenses/>
  */
 
+#include "hw/acpi/acpi.h"
+#include "hw/acpi/aml-build.h"
 #include "hw/mem/nvdimm.h"
 
+static int nvdimm_plugged_device_list(Object *obj, void *opaque)
+{
+    GSList **list = opaque;
+
+    if (object_dynamic_cast(obj, TYPE_NVDIMM)) {
+        NVDIMMDevice *nvdimm = NVDIMM(obj);
+
+        if (memory_region_is_mapped(&nvdimm->nvdimm_mr)) {
+            *list = g_slist_append(*list, DEVICE(obj));
+        }
+    }
+
+    object_child_foreach(obj, nvdimm_plugged_device_list, opaque);
+    return 0;
+}
+
+/*
+ * inquire plugged NVDIMM devices and link them into the list which is
+ * returned to the caller.
+ *
+ * Note: it is the caller's responsibility to free the list to avoid
+ * memory leak.
+ */
+static GSList *nvdimm_get_plugged_device_list(void)
+{
+    GSList *list = NULL;
+
+    object_child_foreach(qdev_get_machine(), nvdimm_plugged_device_list,
+                         &list);
+    return list;
+}
+
+#define NVDIMM_UUID_LE(a, b, c, d0, d1, d2, d3, d4, d5, d6, d7)             \
+   { (a) & 0xff, ((a) >> 8) & 0xff, ((a) >> 16) & 0xff, ((a) >> 24) & 0xff, \
+     (b) & 0xff, ((b) >> 8) & 0xff, (c) & 0xff, ((c) >> 8) & 0xff,          \
+     (d0), (d1), (d2), (d3), (d4), (d5), (d6), (d7) }
+/*
+ * define Byte Addressable Persistent Memory (PM) Region according to
+ * ACPI 6.0: 5.2.25.1 System Physical Address Range Structure.
+ */
+static const uint8_t nvdimm_nfit_spa_uuid[] =
+      NVDIMM_UUID_LE(0x66f0d379, 0xb4f3, 0x4074, 0xac, 0x43, 0x0d, 0x33,
+                     0x18, 0xb7, 0x8c, 0xdb);
+
+/*
+ * NVDIMM Firmware Interface Table
+ * @signature: "NFIT"
+ *
+ * It provides information that allows OSPM to enumerate NVDIMM present in
+ * the platform and associate system physical address ranges created by the
+ * NVDIMMs.
+ *
+ * It is defined in ACPI 6.0: 5.2.25 NVDIMM Firmware Interface Table (NFIT)
+ */
+struct NvdimmNfitHeader {
+    ACPI_TABLE_HEADER_DEF
+    uint32_t reserved;
+} QEMU_PACKED;
+typedef struct NvdimmNfitHeader NvdimmNfitHeader;
+
+/*
+ * define NFIT structures according to ACPI 6.0: 5.2.25 NVDIMM Firmware
+ * Interface Table (NFIT).
+ */
+
+/*
+ * System Physical Address Range Structure
+ *
+ * It describes the system physical address ranges occupied by NVDIMMs and
+ * the types of the regions.
+ */
+struct NvdimmNfitSpa {
+    uint16_t type;
+    uint16_t length;
+    uint16_t spa_index;
+    uint16_t flags;
+    uint32_t reserved;
+    uint32_t proximity_domain;
+    uint8_t type_guid[16];
+    uint64_t spa_base;
+    uint64_t spa_length;
+    uint64_t mem_attr;
+} QEMU_PACKED;
+typedef struct NvdimmNfitSpa NvdimmNfitSpa;
+
+/*
+ * Memory Device to System Physical Address Range Mapping Structure
+ *
+ * It enables identifying each NVDIMM region and the corresponding SPA
+ * describing the memory interleave
+ */
+struct NvdimmNfitMemDev {
+    uint16_t type;
+    uint16_t length;
+    uint32_t nfit_handle;
+    uint16_t phys_id;
+    uint16_t region_id;
+    uint16_t spa_index;
+    uint16_t dcr_index;
+    uint64_t region_len;
+    uint64_t region_offset;
+    uint64_t region_dpa;
+    uint16_t interleave_index;
+    uint16_t interleave_ways;
+    uint16_t flags;
+    uint16_t reserved;
+} QEMU_PACKED;
+typedef struct NvdimmNfitMemDev NvdimmNfitMemDev;
+
+/*
+ * NVDIMM Control Region Structure
+ *
+ * It describes the NVDIMM and if applicable, Block Control Window.
+ */
+struct NvdimmNfitControlRegion {
+    uint16_t type;
+    uint16_t length;
+    uint16_t dcr_index;
+    uint16_t vendor_id;
+    uint16_t device_id;
+    uint16_t revision_id;
+    uint16_t sub_vendor_id;
+    uint16_t sub_device_id;
+    uint16_t sub_revision_id;
+    uint8_t reserved[6];
+    uint32_t serial_number;
+    uint16_t fic;
+    uint16_t num_bcw;
+    uint64_t bcw_size;
+    uint64_t cmd_offset;
+    uint64_t cmd_size;
+    uint64_t status_offset;
+    uint64_t status_size;
+    uint16_t flags;
+    uint8_t reserved2[6];
+} QEMU_PACKED;
+typedef struct NvdimmNfitControlRegion NvdimmNfitControlRegion;
+
+/*
+ * Module serial number is a unique number for each device. We use the
+ * slot id of NVDIMM device to generate this number so that each device
+ * associates with a different number.
+ *
+ * 0x123456 is a magic number we arbitrarily chose.
+ */
+static uint32_t nvdimm_slot_to_sn(int slot)
+{
+    return 0x123456 + slot;
+}
+
+/*
+ * handle is used to uniquely associate nfit_memdev structure with NVDIMM
+ * ACPI device - nfit_memdev.nfit_handle matches with the value returned
+ * by ACPI device _ADR method.
+ *
+ * We generate the handle with the slot id of NVDIMM device and reserve
+ * 0 for NVDIMM root device.
+ */
+static uint32_t nvdimm_slot_to_handle(int slot)
+{
+    return slot + 1;
+}
+
+/*
+ * index uniquely identifies the structure, 0 is reserved which indicates
+ * that the structure is not valid or the associated structure is not
+ * present.
+ *
+ * Each NVDIMM device needs two indexes, one for nfit_spa and another for
+ * nfit_dc which are generated by the slot id of NVDIMM device.
+ */
+static uint16_t nvdimm_slot_to_spa_index(int slot)
+{
+    return (slot + 1) << 1;
+}
+
+/* See the comments of nvdimm_slot_to_spa_index(). */
+static uint32_t nvdimm_slot_to_dcr_index(int slot)
+{
+    return nvdimm_slot_to_spa_index(slot) + 1;
+}
+
+/* ACPI 6.0: 5.2.25.1 System Physical Address Range Structure */
+static void
+nvdimm_build_structure_spa(GArray *structures, NVDIMMDevice *nvdimm)
+{
+    NvdimmNfitSpa *nfit_spa;
+    uint64_t addr = object_property_get_int(OBJECT(nvdimm), DIMM_ADDR_PROP,
+                                            NULL);
+    uint64_t size = object_property_get_int(OBJECT(nvdimm), DIMM_SIZE_PROP,
+                                            NULL);
+    uint32_t node = object_property_get_int(OBJECT(nvdimm), DIMM_NODE_PROP,
+                                            NULL);
+    int slot = object_property_get_int(OBJECT(nvdimm), DIMM_SLOT_PROP,
+                                            NULL);
+
+    nfit_spa = acpi_data_push(structures, sizeof(*nfit_spa));
+
+    nfit_spa->type = cpu_to_le16(0 /* System Physical Address Range
+                                      Structure */);
+    nfit_spa->length = cpu_to_le16(sizeof(*nfit_spa));
+    nfit_spa->spa_index = cpu_to_le16(nvdimm_slot_to_spa_index(slot));
+
+    /*
+     * Control region is strict as all the device info, such as SN, index,
+     * is associated with slot id.
+     */
+    nfit_spa->flags = cpu_to_le16(1 /* Control region is strictly for
+                                       management during hot add/online
+                                       operation */ |
+                                  2 /* Data in Proximity Domain field is
+                                       valid*/);
+
+    /* NUMA node. */
+    nfit_spa->proximity_domain = cpu_to_le32(node);
+    /* the region reported as PMEM. */
+    memcpy(nfit_spa->type_guid, nvdimm_nfit_spa_uuid,
+           sizeof(nvdimm_nfit_spa_uuid));
+
+    nfit_spa->spa_base = cpu_to_le64(addr);
+    nfit_spa->spa_length = cpu_to_le64(size);
+
+    /* It is the PMEM and can be cached as writeback. */
+    nfit_spa->mem_attr = cpu_to_le64(0x8ULL /* EFI_MEMORY_WB */ |
+                                     0x8000ULL /* EFI_MEMORY_NV */);
+}
+
+/*
+ * ACPI 6.0: 5.2.25.2 Memory Device to System Physical Address Range Mapping
+ * Structure
+ */
+static void
+nvdimm_build_structure_memdev(GArray *structures, NVDIMMDevice *nvdimm)
+{
+    NvdimmNfitMemDev *nfit_memdev;
+    uint64_t addr = object_property_get_int(OBJECT(nvdimm), DIMM_ADDR_PROP,
+                                            NULL);
+    uint64_t size = object_property_get_int(OBJECT(nvdimm), DIMM_SIZE_PROP,
+                                            NULL);
+    int slot = object_property_get_int(OBJECT(nvdimm), DIMM_SLOT_PROP,
+                                            NULL);
+    uint32_t handle = nvdimm_slot_to_handle(slot);
+
+    nfit_memdev = acpi_data_push(structures, sizeof(*nfit_memdev));
+
+    nfit_memdev->type = cpu_to_le16(1 /* Memory Device to System Address
+                                         Range Map Structure*/);
+    nfit_memdev->length = cpu_to_le16(sizeof(*nfit_memdev));
+    nfit_memdev->nfit_handle = cpu_to_le32(handle);
+
+    /*
+     * associate memory device with System Physical Address Range
+     * Structure.
+     */
+    nfit_memdev->spa_index = cpu_to_le16(nvdimm_slot_to_spa_index(slot));
+    /* associate memory device with Control Region Structure. */
+    nfit_memdev->dcr_index = cpu_to_le16(nvdimm_slot_to_dcr_index(slot));
+
+    /* The memory region on the device. */
+    nfit_memdev->region_len = cpu_to_le64(size);
+    nfit_memdev->region_dpa = cpu_to_le64(addr);
+
+    /* Only one interleave for PMEM. */
+    nfit_memdev->interleave_ways = cpu_to_le16(1);
+}
+
+/*
+ * ACPI 6.0: 5.2.25.5 NVDIMM Control Region Structure.
+ */
+static void nvdimm_build_structure_dcr(GArray *structures,
+                                       NVDIMMDevice *nvdimm)
+{
+    NvdimmNfitControlRegion *nfit_dcr;
+    int slot = object_property_get_int(OBJECT(nvdimm), DIMM_SLOT_PROP,
+                                       NULL);
+    uint32_t sn = nvdimm_slot_to_sn(slot);
+
+    nfit_dcr = acpi_data_push(structures, sizeof(*nfit_dcr));
+
+    nfit_dcr->type = cpu_to_le16(4 /* NVDIMM Control Region Structure */);
+    nfit_dcr->length = cpu_to_le16(sizeof(*nfit_dcr));
+    nfit_dcr->dcr_index = cpu_to_le16(nvdimm_slot_to_dcr_index(slot));
+
+    /* vendor: Intel. */
+    nfit_dcr->vendor_id = cpu_to_le16(0x8086);
+    nfit_dcr->device_id = cpu_to_le16(1);
+
+    /* The _DSM method is following Intel's DSM specification. */
+    nfit_dcr->revision_id = cpu_to_le16(1 /* Current Revision supported
+                                             in ACPI 6.0 is 1. */);
+    nfit_dcr->serial_number = cpu_to_le32(sn);
+    nfit_dcr->fic = cpu_to_le16(0x201 /* Format Interface Code. See Chapter
+                                         2: NVDIMM Device Specific Method
+                                         (DSM) in DSM Spec Rev1.*/);
+}
+
+static GArray *nvdimm_build_device_structure(GSList *device_list)
+{
+    GArray *structures = g_array_new(false, true /* clear */, 1);
+
+    for (; device_list; device_list = device_list->next) {
+        NVDIMMDevice *nvdimm = device_list->data;
+
+        /* build System Physical Address Range Structure. */
+        nvdimm_build_structure_spa(structures, nvdimm);
+
+        /*
+         * build Memory Device to System Physical Address Range Mapping
+         * Structure.
+         */
+        nvdimm_build_structure_memdev(structures, nvdimm);
+
+        /* build NVDIMM Control Region Structure. */
+        nvdimm_build_structure_dcr(structures, nvdimm);
+    }
+
+    return structures;
+}
+
+static void nvdimm_build_nfit(GSList *device_list, GArray *table_offsets,
+                              GArray *table_data, GArray *linker)
+{
+    GArray *structures = nvdimm_build_device_structure(device_list);
+    void *header;
+
+    acpi_add_table(table_offsets, table_data);
+
+    /* NFIT header. */
+    header = acpi_data_push(table_data, sizeof(NvdimmNfitHeader));
+
+    /* NVDIMM device structures. */
+    g_array_append_vals(table_data, structures->data, structures->len);
+
+    build_header(linker, table_data, header, "NFIT",
+                 sizeof(NvdimmNfitHeader) + structures->len, 1);
+    g_array_free(structures, true);
+}
+
 static uint64_t
 nvdimm_dsm_read(void *opaque, hwaddr addr, unsigned size)
 {
@@ -61,3 +401,18 @@ void nvdimm_init_acpi_state(MemoryRegion *memory, MemoryRegion *io,
                           "nvdimm-acpi-io", NVDIMM_ACPI_IO_LEN);
     memory_region_add_subregion(io, NVDIMM_ACPI_IO_BASE, &state->io_mr);
 }
+
+void nvdimm_build_acpi(GArray *table_offsets, GArray *table_data,
+                       GArray *linker)
+{
+    GSList *device_list;
+
+    /* no NVDIMM device is plugged. */
+    device_list = nvdimm_get_plugged_device_list();
+    if (!device_list) {
+        return;
+    }
+
+    nvdimm_build_nfit(device_list, table_offsets, table_data, linker);
+    g_slist_free(device_list);
+}
diff --git a/hw/i386/acpi-build.c b/hw/i386/acpi-build.c
index 95e0c65..27b2854 100644
--- a/hw/i386/acpi-build.c
+++ b/hw/i386/acpi-build.c
@@ -90,6 +90,7 @@ typedef struct AcpiPmInfo {
     bool s3_disabled;
     bool s4_disabled;
     bool pcihp_bridge_en;
+    bool nvdimm_support;
     uint8_t s4_val;
     uint16_t sci_int;
     uint8_t acpi_enable_cmd;
@@ -231,6 +232,7 @@ static void acpi_get_pm_info(AcpiPmInfo *pm)
     pm->pcihp_bridge_en =
         object_property_get_bool(obj, "acpi-pci-hotplug-with-bridge-support",
                                  NULL);
+    pm->nvdimm_support = object_property_get_bool(obj, "nvdimm-support", NULL);
 }
 
 static void acpi_get_misc_info(AcpiMiscInfo *info)
@@ -1742,6 +1744,10 @@ void acpi_build(PcGuestInfo *guest_info, AcpiBuildTables *tables)
         build_dmar_q35(tables_blob, tables->linker);
     }
 
+    if (pm.nvdimm_support) {
+        nvdimm_build_acpi(table_offsets, tables_blob, tables->linker);
+    }
+
     /* Add tables supplied by user (if any) */
     for (u = acpi_table_first(); u; u = acpi_table_next(u)) {
         unsigned len = acpi_table_len(u);
diff --git a/include/hw/mem/nvdimm.h b/include/hw/mem/nvdimm.h
index f0b1dda..7fdf591 100644
--- a/include/hw/mem/nvdimm.h
+++ b/include/hw/mem/nvdimm.h
@@ -25,6 +25,14 @@
 
 #include "hw/mem/dimm.h"
 
+#define NVDIMM_DEBUG 0
+#define nvdimm_debug(fmt, ...)                                \
+    do {                                                      \
+        if (NVDIMM_DEBUG) {                                   \
+            fprintf(stderr, "nvdimm: " fmt, ## __VA_ARGS__);  \
+        }                                                     \
+    } while (0)
+
 /*
  * The minimum label data size is required by NVDIMM Namespace
  * specification, please refer to chapter 2 Namespaces:
@@ -114,4 +122,6 @@ typedef struct AcpiNVDIMMState AcpiNVDIMMState;
 /* Initialize the memory and IO region needed by NVDIMM ACPI emulation.*/
 void nvdimm_init_acpi_state(MemoryRegion *memory, MemoryRegion *io,
                             Object *owner, AcpiNVDIMMState *state);
+void nvdimm_build_acpi(GArray *table_offsets, GArray *table_data,
+                       GArray *linker);
 #endif
-- 
1.8.3.1

  parent reply	other threads:[~2015-10-30  6:02 UTC|newest]

Thread overview: 182+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-10-30  5:55 [PATCH v6 00/33] implement vNVDIMM Xiao Guangrong
2015-10-30  5:55 ` [Qemu-devel] " Xiao Guangrong
2015-10-30  5:55 ` [PATCH v6 01/33] acpi: add aml_derefof Xiao Guangrong
2015-10-30  5:55   ` [Qemu-devel] " Xiao Guangrong
2015-10-30  5:55 ` [PATCH v6 02/33] acpi: add aml_sizeof Xiao Guangrong
2015-10-30  5:55   ` [Qemu-devel] " Xiao Guangrong
2015-10-30  5:55 ` [PATCH v6 03/33] acpi: add aml_create_field Xiao Guangrong
2015-10-30  5:55   ` [Qemu-devel] " Xiao Guangrong
2015-10-30  5:55 ` [PATCH v6 04/33] acpi: add aml_concatenate Xiao Guangrong
2015-10-30  5:55   ` [Qemu-devel] " Xiao Guangrong
2015-10-30  5:55 ` [PATCH v6 05/33] acpi: add aml_object_type Xiao Guangrong
2015-10-30  5:55   ` [Qemu-devel] " Xiao Guangrong
2015-11-09 11:35   ` Michael S. Tsirkin
2015-11-09 11:35     ` [Qemu-devel] " Michael S. Tsirkin
2015-11-09 12:40     ` Igor Mammedov
2015-11-09 12:40       ` [Qemu-devel] " Igor Mammedov
2015-10-30  5:56 ` [PATCH v6 06/33] acpi: add aml_method_serialized Xiao Guangrong
2015-10-30  5:56   ` [Qemu-devel] " Xiao Guangrong
2015-11-09 11:14   ` Michael S. Tsirkin
2015-11-09 11:14     ` [Qemu-devel] " Michael S. Tsirkin
2015-11-09 11:18     ` Xiao Guangrong
2015-11-09 11:18       ` [Qemu-devel] " Xiao Guangrong
2015-10-30  5:56 ` [PATCH v6 07/33] util: introduce qemu_file_get_page_size() Xiao Guangrong
2015-10-30  5:56   ` [Qemu-devel] " Xiao Guangrong
2015-10-30 13:26   ` Vladimir Sementsov-Ogievskiy
2015-10-30 13:26     ` Vladimir Sementsov-Ogievskiy
2015-10-31  7:26     ` Xiao Guangrong
2015-10-31  7:26       ` [Qemu-devel] " Xiao Guangrong
2015-10-31  9:37       ` Vladimir Sementsov-Ogievskiy
2015-10-31  9:37         ` Vladimir Sementsov-Ogievskiy
2015-10-31 14:06         ` Xiao Guangrong
2015-10-31 14:06           ` [Qemu-devel] " Xiao Guangrong
2015-10-30 15:54   ` Eduardo Habkost
2015-10-30 15:54     ` [Qemu-devel] " Eduardo Habkost
2015-10-31  8:09     ` Xiao Guangrong
2015-10-31  8:09       ` [Qemu-devel] " Xiao Guangrong
2015-10-31 14:11       ` Eduardo Habkost
2015-10-31 14:11         ` [Qemu-devel] " Eduardo Habkost
2015-10-31 17:03         ` Xiao Guangrong
2015-10-31 17:03           ` [Qemu-devel] " Xiao Guangrong
2015-11-09 20:00       ` Michael S. Tsirkin
2015-11-09 20:00         ` [Qemu-devel] " Michael S. Tsirkin
2015-10-31  8:25     ` Xiao Guangrong
2015-10-31  8:25       ` [Qemu-devel] " Xiao Guangrong
2015-11-09 10:33   ` Michael S. Tsirkin
2015-11-09 10:33     ` [Qemu-devel] " Michael S. Tsirkin
2015-11-09 10:55     ` Xiao Guangrong
2015-11-09 10:55       ` [Qemu-devel] " Xiao Guangrong
2015-10-30  5:56 ` [PATCH v6 08/33] exec: allow memory to be allocated from any kind of path Xiao Guangrong
2015-10-30  5:56   ` [Qemu-devel] " Xiao Guangrong
2015-10-30 14:04   ` Vladimir Sementsov-Ogievskiy
2015-10-30 14:04     ` Vladimir Sementsov-Ogievskiy
2015-10-31  7:44     ` Xiao Guangrong
2015-10-31 13:55       ` Eduardo Habkost
2015-10-31 13:55         ` Eduardo Habkost
2015-10-31 15:56         ` Xiao Guangrong
2015-10-31 15:56           ` Xiao Guangrong
2015-11-09 10:39   ` Michael S. Tsirkin
2015-11-09 10:39     ` [Qemu-devel] " Michael S. Tsirkin
2015-11-09 11:01     ` Xiao Guangrong
2015-11-09 11:01       ` [Qemu-devel] " Xiao Guangrong
2015-10-30  5:56 ` [PATCH v6 09/33] exec: allow file_ram_alloc to work on file Xiao Guangrong
2015-10-30  5:56   ` [Qemu-devel] " Xiao Guangrong
2015-10-30 14:25   ` Vladimir Sementsov-Ogievskiy
2015-10-30 14:25     ` Vladimir Sementsov-Ogievskiy
2015-10-31  7:53     ` Xiao Guangrong
2015-10-31  7:53       ` [Qemu-devel] " Xiao Guangrong
2015-11-09 10:13   ` Michael S. Tsirkin
2015-11-09 10:13     ` [Qemu-devel] " Michael S. Tsirkin
2015-11-09 10:48     ` Xiao Guangrong
2015-11-09 10:48       ` [Qemu-devel] " Xiao Guangrong
2015-10-30  5:56 ` [PATCH v6 10/33] hostmem-file: clean up memory allocation Xiao Guangrong
2015-10-30  5:56   ` [Qemu-devel] " Xiao Guangrong
2015-10-30 14:54   ` Vladimir Sementsov-Ogievskiy
2015-10-30 14:54     ` Vladimir Sementsov-Ogievskiy
2015-10-30  5:56 ` [PATCH v6 11/33] hostmem-file: use whole file size if possible Xiao Guangrong
2015-10-30  5:56   ` [Qemu-devel] " Xiao Guangrong
2015-10-30 15:27   ` Vladimir Sementsov-Ogievskiy
2015-10-30 15:27     ` Vladimir Sementsov-Ogievskiy
2015-10-31  7:59     ` Xiao Guangrong
2015-10-31  7:59       ` [Qemu-devel] " Xiao Guangrong
2015-10-30 17:30   ` Eduardo Habkost
2015-10-30 17:30     ` Eduardo Habkost
2015-10-31  8:46     ` Xiao Guangrong
2015-10-31  8:46       ` Xiao Guangrong
2015-10-31 13:45       ` Eduardo Habkost
2015-10-31 13:45         ` Eduardo Habkost
2015-10-31 16:59         ` Xiao Guangrong
2015-10-31 16:59           ` [Qemu-devel] " Xiao Guangrong
2015-11-09 10:17   ` Michael S. Tsirkin
2015-11-09 10:17     ` [Qemu-devel] " Michael S. Tsirkin
2015-11-09 10:49     ` Xiao Guangrong
2015-11-09 10:49       ` [Qemu-devel] " Xiao Guangrong
2015-10-30  5:56 ` [PATCH v6 12/33] pc-dimm: remove DEFAULT_PC_DIMMSIZE Xiao Guangrong
2015-10-30  5:56   ` [Qemu-devel] " Xiao Guangrong
2015-11-09 10:40   ` Michael S. Tsirkin
2015-11-09 10:40     ` [Qemu-devel] " Michael S. Tsirkin
2015-11-09 11:03     ` Xiao Guangrong
2015-11-09 11:03       ` [Qemu-devel] " Xiao Guangrong
2015-10-30  5:56 ` [PATCH v6 13/33] pc-dimm: make pc_existing_dimms_capacity static and rename it Xiao Guangrong
2015-10-30  5:56   ` [Qemu-devel] " Xiao Guangrong
2015-10-30 15:38   ` Vladimir Sementsov-Ogievskiy
2015-10-30 15:38     ` Vladimir Sementsov-Ogievskiy
2015-10-30  5:56 ` [PATCH v6 14/33] pc-dimm: drop the prefix of pc-dimm Xiao Guangrong
2015-10-30  5:56   ` [Qemu-devel] " Xiao Guangrong
2015-10-30 16:10   ` Vladimir Sementsov-Ogievskiy
2015-10-30 16:10     ` Vladimir Sementsov-Ogievskiy
2015-10-31  8:18     ` Xiao Guangrong
2015-10-30 17:06   ` Eric Blake
2015-10-31  8:23     ` Xiao Guangrong
2015-11-09 20:05   ` Michael S. Tsirkin
2015-11-09 20:05     ` [Qemu-devel] " Michael S. Tsirkin
2015-10-30  5:56 ` [PATCH v6 15/33] stubs: rename qmp_pc_dimm_device_list.c Xiao Guangrong
2015-10-30  5:56   ` [Qemu-devel] " Xiao Guangrong
2015-10-30  5:56 ` [PATCH v6 16/33] pc-dimm: rename pc-dimm.c and pc-dimm.h Xiao Guangrong
2015-10-30  5:56   ` [Qemu-devel] " Xiao Guangrong
2015-10-31 10:28   ` Vladimir Sementsov-Ogievskiy
2015-10-31 10:28     ` Vladimir Sementsov-Ogievskiy
2015-10-30  5:56 ` [PATCH v6 17/33] dimm: abstract dimm device from pc-dimm Xiao Guangrong
2015-10-30  5:56   ` [Qemu-devel] " Xiao Guangrong
2015-10-31 10:41   ` Vladimir Sementsov-Ogievskiy
2015-10-31 10:41     ` [Qemu-devel] " Vladimir Sementsov-Ogievskiy
2015-10-30  5:56 ` [PATCH v6 18/33] dimm: get mapped memory region from DIMMDeviceClass->get_memory_region Xiao Guangrong
2015-10-30  5:56   ` [Qemu-devel] " Xiao Guangrong
2015-10-31 10:52   ` Vladimir Sementsov-Ogievskiy
2015-10-31 10:52     ` Vladimir Sementsov-Ogievskiy
2015-10-31 14:15     ` Xiao Guangrong
2015-10-31 14:15       ` [Qemu-devel] " Xiao Guangrong
2015-11-02  9:18       ` Xiao Guangrong
2015-10-30  5:56 ` [PATCH v6 19/33] dimm: keep the state of the whole backend memory Xiao Guangrong
2015-10-30  5:56   ` [Qemu-devel] " Xiao Guangrong
2015-10-31 11:05   ` Vladimir Sementsov-Ogievskiy
2015-10-31 11:05     ` Vladimir Sementsov-Ogievskiy
2015-10-31 14:19     ` Xiao Guangrong
2015-11-09 11:04   ` Michael S. Tsirkin
2015-11-09 11:04     ` [Qemu-devel] " Michael S. Tsirkin
2015-11-09 11:13     ` Xiao Guangrong
2015-11-09 11:13       ` [Qemu-devel] " Xiao Guangrong
2015-10-30  5:56 ` [PATCH v6 20/33] dimm: introduce realize callback Xiao Guangrong
2015-10-30  5:56   ` [Qemu-devel] " Xiao Guangrong
2015-10-31 11:22   ` Vladimir Sementsov-Ogievskiy
2015-10-31 11:22     ` [Qemu-devel] " Vladimir Sementsov-Ogievskiy
2015-10-30  5:56 ` [PATCH v6 21/33] nvdimm: implement NVDIMM device abstract Xiao Guangrong
2015-10-30  5:56   ` [Qemu-devel] " Xiao Guangrong
2015-10-30  5:56 ` [PATCH v6 22/33] docs: add NVDIMM ACPI documentation Xiao Guangrong
2015-10-30  5:56   ` [Qemu-devel] " Xiao Guangrong
2015-10-30  5:56 ` [PATCH v6 23/33] nvdimm acpi: init the resource used by NVDIMM ACPI Xiao Guangrong
2015-10-30  5:56   ` [Qemu-devel] " Xiao Guangrong
2015-10-30  5:56 ` Xiao Guangrong [this message]
2015-10-30  5:56   ` [Qemu-devel] [PATCH v6 24/33] nvdimm acpi: build ACPI NFIT table Xiao Guangrong
2015-10-30  5:56 ` [PATCH v6 25/33] nvdimm acpi: build ACPI nvdimm devices Xiao Guangrong
2015-10-30  5:56   ` [Qemu-devel] " Xiao Guangrong
2015-11-08 17:38   ` Michael S. Tsirkin
2015-11-08 17:38     ` [Qemu-devel] " Michael S. Tsirkin
2015-11-09  6:07     ` Xiao Guangrong
2015-11-09  6:07       ` [Qemu-devel] " Xiao Guangrong
2015-10-30  5:56 ` [PATCH v6 26/33] nvdimm acpi: save arg3 for NVDIMM device _DSM method Xiao Guangrong
2015-10-30  5:56   ` [Qemu-devel] " Xiao Guangrong
2015-10-30  5:56 ` [PATCH v6 27/33] nvdimm acpi: support function 0 Xiao Guangrong
2015-10-30  5:56   ` [Qemu-devel] " Xiao Guangrong
2015-10-30 10:14   ` Stefan Hajnoczi
2015-10-30 10:14     ` [Qemu-devel] " Stefan Hajnoczi
2015-10-30 13:01     ` Xiao Guangrong
2015-10-30 13:01       ` [Qemu-devel] " Xiao Guangrong
2015-10-30  5:56 ` [PATCH v6 28/33] nvdimm acpi: support Get Namespace Label Size function Xiao Guangrong
2015-10-30  5:56   ` [Qemu-devel] " Xiao Guangrong
2015-10-30  5:56 ` [PATCH v6 29/33] nvdimm acpi: support Get Namespace Label Data function Xiao Guangrong
2015-10-30  5:56   ` [Qemu-devel] " Xiao Guangrong
2015-10-30  5:56 ` [PATCH v6 30/33] nvdimm acpi: support Set " Xiao Guangrong
2015-10-30  5:56   ` [Qemu-devel] " Xiao Guangrong
2015-10-30  5:56 ` [PATCH v6 31/33] nvdimm: allow using whole backend memory as pmem Xiao Guangrong
2015-10-30  5:56   ` [Qemu-devel] " Xiao Guangrong
2015-10-30  5:56 ` [PATCH v6 32/33] nvdimm acpi: support _FIT method Xiao Guangrong
2015-10-30  5:56   ` [Qemu-devel] " Xiao Guangrong
2015-11-08 17:50   ` Michael S. Tsirkin
2015-11-08 17:50     ` [Qemu-devel] " Michael S. Tsirkin
2015-11-09  6:37     ` Xiao Guangrong
2015-11-09  6:37       ` [Qemu-devel] " Xiao Guangrong
2015-10-30  5:56 ` [PATCH v6 33/33] nvdimm: add maintain info Xiao Guangrong
2015-10-30  5:56   ` [Qemu-devel] " Xiao Guangrong
2015-10-30 10:15 ` [PATCH v6 00/33] implement vNVDIMM Stefan Hajnoczi
2015-10-30 10:15   ` [Qemu-devel] " Stefan Hajnoczi

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1446184587-142784-25-git-send-email-guangrong.xiao@linux.intel.com \
    --to=guangrong.xiao@linux.intel.com \
    --cc=dan.j.williams@intel.com \
    --cc=ehabkost@redhat.com \
    --cc=gleb@kernel.org \
    --cc=imammedo@redhat.com \
    --cc=kvm@vger.kernel.org \
    --cc=mst@redhat.com \
    --cc=mtosatti@redhat.com \
    --cc=pbonzini@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=rth@twiddle.net \
    --cc=stefanha@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.