Re: [Qemu-devel] [RFC PATCH] memory: Don't use memcpy for ram marked as skip_dump

2016-10-24 Thread Thorsten Kohfeldt
Am 22.10.2016 um 17:09 schrieb Alex Williamson: On Sat, 22 Oct 2016 11:10:59 +0200 Thorsten Kohfeldt wrote: Hi *, this came to my mind when browsing the sources in the patch's vicinity. It is just a collection of thoughts, so please don't feel offended about how I phrased certain statements

Re: [Qemu-devel] [RFC PATCH] memory: Don't use memcpy for ram marked as skip_dump

2016-10-24 Thread Alex Williamson
On Mon, 24 Oct 2016 13:05:56 +0200 Paolo Bonzini wrote: > On 22/10/2016 17:09, Alex Williamson wrote: > > > Add a trace message for each mrop. > > > > Yes, this is on my todo list post-RFC. > > Another thing to think about: > > 1) rename all the skip_dump occurrences in the API to device_m

Re: [Qemu-devel] [RFC PATCH] memory: Don't use memcpy for ram marked as skip_dump

2016-10-24 Thread Paolo Bonzini
On 22/10/2016 17:09, Alex Williamson wrote: > > Add a trace message for each mrop. > > Yes, this is on my todo list post-RFC. Another thing to think about: 1) rename all the skip_dump occurrences in the API to device_memory. The new ops make it much more specific than just skipping the region

Re: [Qemu-devel] [RFC PATCH] memory: Don't use memcpy for ram marked as skip_dump

2016-10-22 Thread Alex Williamson
On Sat, 22 Oct 2016 11:10:59 +0200 Thorsten Kohfeldt wrote: > Hi *, > > this came to my mind when browsing the sources in the patch's vicinity. > > It is just a collection of thoughts, so please don't feel offended > about how I phrased certain statements. > > > Questions > > Is mr->opaque a

Re: [Qemu-devel] [RFC PATCH] memory: Don't use memcpy for ram marked as skip_dump

2016-10-22 Thread Paolo Bonzini
- Original Message - > From: "Alex Williamson" > To: qemu-devel@nongnu.org > Cc: pbonz...@redhat.com, "thorsten kohfeldt" > Sent: Friday, October 21, 2016 7:11:44 PM > Subject: [RFC PATCH] memory: Don't use memcpy for ram marked as skip_dump > > With a vfio assigned device we lay down

Re: [Qemu-devel] [RFC PATCH] memory: Don't use memcpy for ram marked as skip_dump

2016-10-22 Thread Thorsten Kohfeldt
Hi *, this came to my mind when browsing the sources in the patch's vicinity. It is just a collection of thoughts, so please don't feel offended about how I phrased certain statements. Questions Is mr->opaque always unused ? i.e. should we assert NULL before assignment ? mr->ops vs. mr->iomm

[Qemu-devel] [RFC PATCH] memory: Don't use memcpy for ram marked as skip_dump

2016-10-21 Thread Alex Williamson
With a vfio assigned device we lay down a base MemoryRegion registered as an IO region, giving us read & write accessors. If the region supports mmap, we lay down a higher priority sub-region MemoryRegion on top of the base layer initialized as a RAM pointer to the mmap. Finally, if we have any qu