qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH 14/16] nvdimm: support NFIT_CMD_GET_CONFIG_SIZE


From: Xiao Guangrong
Subject: Re: [Qemu-devel] [PATCH 14/16] nvdimm: support NFIT_CMD_GET_CONFIG_SIZE function
Date: Fri, 03 Jul 2015 02:02:54 +0800
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.7.0



On 07/02/2015 05:23 PM, Stefan Hajnoczi wrote:
On Wed, Jul 01, 2015 at 10:50:30PM +0800, Xiao Guangrong wrote:
+static uint32_t dsm_cmd_config_size(struct dsm_buffer *in, struct dsm_out *out)
+{
+    GSList *list = get_nvdimm_built_list();
+    PCNVDIMMDevice *nvdimm = get_nvdimm_device_by_handle(list, in->handle);
+    uint32_t status = NFIT_STATUS_NON_EXISTING_MEM_DEV;
+
+    if (!nvdimm) {
+        goto exit;
+    }
+
+    status = NFIT_STATUS_SUCCESS;
+    out->cmd_config_size.config_size = nvdimm->config_data_size;
+    out->cmd_config_size.max_xfer = max_xfer_config_size();

cpu_to_*() missing?

It should be possible to emulate NVDIMMs for a x86_64 guest on a
big-endian host, for example.

Indeed, will fix it in the next version, thank you for pointing it out.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]