On 30.10.2015 08:56, Xiao Guangrong wrote:
QEMU keeps the state of memory of dimm device during live migration,
however, it is not enough for nvdimm device as its memory does not
contain its label data, so that we should protect the whole backend
memory instead
Signed-off-by: Xiao Guangrong
---
ion *(*get_memory_region)(DIMMDevice *dimm);
} DIMMDeviceClass;
Reviewed-by: Vladimir Sementsov-Ogievskiy
--
Best regards,
Vladimir
* now, @virtuozzo.com instead of @parallels.com. Sorry for this inconvenience.
--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the
On 02.11.2015 12:13, Xiao Guangrong wrote:
Curretly, the memory region of backed memory is directly mapped to
guest's address space, however, it is not true for nvdimm device
This patch let dimm device realize this fact and use
DIMMDeviceClass->get_memory_region method to get the mapped memory
r
when others return long. long is more common practice here, but this
doesn't really matter, so with or without size_t <-> long changes:
Reviewed-by: Vladimir Sementsov-Ogievskiy
--
Best regards,
Vladimir
* now, @virtuozzo.com instead of @parallels.com. Sorry for this inconvenien
On 02.11.2015 16:08, Xiao Guangrong wrote:
On 11/02/2015 08:19 PM, Vladimir Sementsov-Ogievskiy wrote:
On 02.11.2015 12:13, Xiao Guangrong wrote:
Curretly, the memory region of backed memory is directly mapped to
guest's address space, however, it is not true for nvdimm device
This
On 02.11.2015 12:13, Xiao Guangrong wrote:
Currently file_ram_alloc() is designed for hugetlbfs, however, the memory
of nvdimm can come from either raw pmem device eg, /dev/pmem, or the file
locates at DAX enabled filesystem
So this patch let it work on any kind of path
No, this patch doesn't
on't bother bailing out on errors.
- * If anything goes wrong with it under other filesystems,
- * mmap will fail.
- */
-if (ftruncate(fd, memory)) {
- perror("ftruncate");
-}
area = qemu_ram_mmap(fd, memory, pagesize, block->flags & RAM_SHARED);
r_setg_errno(errp, -size, "can't get size of file %s", file);
+size = 0;
+}
+
+qemu_close(fd);
+return size;
+}
Reviewed-by: Vladimir Sementsov-Ogievskiy
--
Best regards,
Vladimir
* now, @virtuozzo.com instead of @parallels.com. Sorry for this inconvenience.
--
On 02.11.2015 18:22, Xiao Guangrong wrote:
On 11/02/2015 10:51 PM, Vladimir Sementsov-Ogievskiy wrote:
On 02.11.2015 12:13, Xiao Guangrong wrote:
Currently file_ram_alloc() is designed for hugetlbfs, however, the
memory
of nvdimm can come from either raw pmem device eg, /dev/pmem, or the
On 02.11.2015 18:25, Xiao Guangrong wrote:
On 11/02/2015 11:12 PM, Vladimir Sementsov-Ogievskiy wrote:
On 02.11.2015 12:13, Xiao Guangrong wrote:
Currently, file_ram_alloc() only works on directory - it creates a file
under @path and do mmap on it
This patch tries to allow it to work on
return size;
+}
+#endif
+
size = lseek(fd, 0, SEEK_END);
if (size < 0) {
return -errno;
Reviewed-by: Vladimir Sementsov-Ogievskiy
just a question: is there any use for stat.st_size ? Is it always worse
then lseek? Does it work for blk?
also, "This patch
On 02.11.2015 18:06, Xiao Guangrong wrote:
On 11/02/2015 10:26 PM, Vladimir Sementsov-Ogievskiy wrote:
On 02.11.2015 16:08, Xiao Guangrong wrote:
On 11/02/2015 08:19 PM, Vladimir Sementsov-Ogievskiy wrote:
On 02.11.2015 12:13, Xiao Guangrong wrote:
Curretly, the memory region of backed
On 02.11.2015 12:13, Xiao Guangrong wrote:
Use the whole file size if @size is not specified which is useful
if we want to directly pass a file to guest
Signed-off-by: Xiao Guangrong
---
backends/hostmem-file.c | 22 ++
1 file changed, 18 insertions(+), 4 deletions(-)
di
On 03.11.2015 17:47, Xiao Guangrong wrote:
On 11/03/2015 12:16 AM, Vladimir Sementsov-Ogievskiy wrote:
On 02.11.2015 18:06, Xiao Guangrong wrote:
On 11/02/2015 10:26 PM, Vladimir Sementsov-Ogievskiy wrote:
On 02.11.2015 16:08, Xiao Guangrong wrote:
On 11/02/2015 08:19 PM, Vladimir
On 02.11.2015 12:13, Xiao Guangrong wrote:
Introduce "nvdimm" device which is based on dimm device type
128K memory region which is the minimum namespace label size
required by NVDIMM Namespace Spec locates at the end of
backend memory device is reserved for label data
We can use "-m 1G,maxmem=
On 16.11.2015 13:50, Xiao Guangrong wrote:
NVDIMM (A Non-Volatile Dual In-line Memory Module) is going to be supported
on Intel's platform.
Hi.
One question: do this mean, that your qemu emulated nvidimm - pmem
solution will work only on Intel host?
--
Best regards,
Vladimir
* now, @virtuo
On 11.10.2015 06:52, Xiao Guangrong wrote:
Use the whole file size if @size is not specified which is useful
if we want to directly pass a file to guest
Signed-off-by: Xiao Guangrong
---
backends/hostmem-file.c | 47 +++
1 file changed, 43 insertio
logic is changed:
in old version gethugepagesize on statfs error generates exit(1)
in new it returns getpagesize() in this case (through fd_getpagesize)
(I think, fd_getpagesize should be fixed to handle error)
also, in new version for windows we have getpagesize(), when in old
version t
On 30.10.2015 08:56, Xiao Guangrong wrote:
Currently file_ram_alloc() is designed for hugetlbfs, however, the memory
of nvdimm can come from either raw pmem device eg, /dev/pmem, or the file
locates at DAX enabled filesystem
So this patch let it work on any kind of path
Signed-off-by: Xiao Guan
On 30.10.2015 08:56, Xiao Guangrong wrote:
Currently, file_ram_alloc() only works on directory - it creates a file
under @path and do mmap on it
This patch tries to allow it to work on file directly, if @path is a
directory it works as before, otherwise it treats @path as the target
file then di
ckendClass) - ram_backend_memory_alloc - has not such check
too. It's ok..
Reviewed-by: Vladimir Sementsov-Ogievskiy
--
Best regards,
Vladimir
* now, @virtuozzo.com instead of @parallels.com. Sorry for this inconvenience.
--
To unsubscribe from this list: send the line "unsubs
On 30.10.2015 08:56, Xiao Guangrong wrote:
Use the whole file size if @size is not specified which is useful
if we want to directly pass a file to guest
Signed-off-by: Xiao Guangrong
---
backends/hostmem-file.c | 48
1 file changed, 44 inserti
MemoryRegion *mr, uint64_t align, Error **errp);
void pc_dimm_memory_unplug(DeviceState *dev, MemoryHotplugState *hpms,
Reviewed-by: Vladimir Sementsov-Ogievskiy
--
Best regards,
Vladimir
* now, @virtuozzo.com instead of @parallels.com. Sorry for this inconvenience.
--
To unsubscribe
On 30.10.2015 08:56, Xiao Guangrong wrote:
This patch is generated by this script:
find ./ -name "*.[ch]" -o -name "*.json" -o -name "trace-events" -type f \
| xargs sed -i "s/PC_DIMM/DIMM/g"
find ./ -name "*.[ch]" -o -name "*.json" -o -name "trace-events" -type f \
| xargs sed -i "s/PCDIMM/DIM
On 31.10.2015 10:26, Xiao Guangrong wrote:
On 10/30/2015 09:26 PM, Vladimir Sementsov-Ogievskiy wrote:
logic is changed:
in old version gethugepagesize on statfs error generates exit(1)
in new it returns getpagesize() in this case (through
fd_getpagesize)
(I think, fd_getpagesize
ds.h"
#include "qom/object_interfaces.h"
-#include "hw/mem/pc-dimm.h"
+#include "hw/mem/dimm.h"
#include "hw/acpi/acpi_dev_interface.h"
NameInfo *qmp_query_name(Error **errp)
diff --git a/stubs/qmp_dimm_device_list.c b/stubs/qmp_dimm_device_list.c
in
ce, (obj), TYPE_DIMM)
#define DIMM_CLASS(oc) \
diff --git a/include/hw/mem/pc-dimm.h b/include/hw/mem/pc-dimm.h
new file mode 100644
index 000..50818c2
--- /dev/null
+++ b/include/hw/mem/pc-dimm.h
@@ -0,0 +1,7 @@
+#ifndef QEMU_PC_DIMM_H
+#define QEMU_PC_DIMM_H
+
+#include "hw/mem/dimm.h
On 30.10.2015 08:56, Xiao Guangrong wrote:
Curretly, the memory region of backed memory is directly mapped to
guest's address space, however, it is not true for nvdimm device
This patch let dimm device realize this fact and use
DIMMDeviceClass->get_memory_region method to get the mapped memory
r
28 matches
Mail list logo