qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH v4 0/2] In memory QEMUFile
@ 2014-09-17 11:26 Dr. David Alan Gilbert (git)
  2014-09-17 11:26 ` [Qemu-devel] [PATCH v4 1/2] QEMUSizedBuffer based QEMUFile Dr. David Alan Gilbert (git)
  2014-09-17 11:26 ` [Qemu-devel] [PATCH v4 2/2] Tests: QEMUSizedBuffer/QEMUBuffer Dr. David Alan Gilbert (git)
  0 siblings, 2 replies; 6+ messages in thread
From: Dr. David Alan Gilbert (git) @ 2014-09-17 11:26 UTC (permalink / raw)
  To: qemu-devel; +Cc: joel.schopp, stefanb, quintela, arei.gonglei, sanidhya.iiith

From: "Dr. David Alan Gilbert" <dgilbert@redhat.com>

Hi,
  This patch-pair adds the QEMUSizedBuffer based in-memory QEMUFile
written by Stefan Berger and Joel Schopp.  I've made some
fixes and modified the existing test-vmstate to use it for some test cases.

  While there's nothing other than test cases using it yet, I think
it's worth going in by itself, since I'm using it in two separate
patchsets (postcopy and visitor/BER) and Sanidhya uses it in
the periodic vmstate test world.  In addition both microcheckpointing and
COLO have similar but independent implementations (although they both
have some extra-gotcha's so it might not be possible to reuse it), and
there was another implementation of the same thing in the Yabusame Postcopy
world.  Thus it seems best to put in, if only to stop people writing yet
another implementation.

Dave

v4:
  Fix very silly mistake in qsb_grow ENOMEM check

v3:
  Mostly addressing comments from Eric and Gonglei

  rewrote qsb_grow to always use _try_ for memory allocation
    also made it use MAX_CHUNK_SIZE as needed
  made QSB_MAX_CHUNK_SIZE 16x rather than 10x CHUNK_SIZE

  reworked qsb_get_buffer to always take an allocated buffer

  qsb_create:
     Cope with 0 length but passed buffer
     Rework so it can fail on memory allocation failures

  qsb_write_at
     return -EINVAL for invalid position
  qsb_clone
     Cope with qsb_write_at failing

  Typo: 'of of' in comment
        'withing'
  Reword qsb_clone 'exact copy'->'deep copy'

Dr. David Alan Gilbert (2):
  QEMUSizedBuffer based QEMUFile
  Tests: QEMUSizedBuffer/QEMUBuffer

 include/migration/qemu-file.h |  28 +++
 include/qemu/typedefs.h       |   1 +
 qemu-file.c                   | 457 ++++++++++++++++++++++++++++++++++++++++++
 tests/Makefile                |   2 +-
 tests/test-vmstate.c          |  74 +++----
 5 files changed, 525 insertions(+), 37 deletions(-)

-- 
1.9.3

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2014-09-29  8:46 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-09-17 11:26 [Qemu-devel] [PATCH v4 0/2] In memory QEMUFile Dr. David Alan Gilbert (git)
2014-09-17 11:26 ` [Qemu-devel] [PATCH v4 1/2] QEMUSizedBuffer based QEMUFile Dr. David Alan Gilbert (git)
2014-09-27  3:34   ` Eric Blake
2014-09-29  8:45     ` Dr. David Alan Gilbert
2014-09-17 11:26 ` [Qemu-devel] [PATCH v4 2/2] Tests: QEMUSizedBuffer/QEMUBuffer Dr. David Alan Gilbert (git)
2014-09-27  3:36   ` Eric Blake

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).