On 01/29/2012 01:37 PM, Blue Swirl wrote: > On Sun, Jan 29, 2012 at 10:22, Avi Kivity <a...@redhat.com> wrote: > > On 01/28/2012 08:13 PM, Blue Swirl wrote: > >> Fix suspend/resume broken by off-by-one error in > >> 59abb06198ee9471e29c970f294eae80c0b39be1. > >> > >> Adjust the loop so that it handles correctly the case > >> start = (ram_addr_t)-TARGET_PAGE_SIZE, length = TARGET_PAGE_SIZE. > > > > Is the ram_addr_t even legal? ram addresses start from 0 and end up > > around ~(ram_addr_t)0 >> 1, max. > > Is that defined somewhere? I think only the size of host virtual > address space should limit the range, for example on a 32 bit host, > near to 3GB should be possible as limited by host OS.
Correct, but the code limits it to 2GB. > Anyway, this version is closer to your original code and should be > equal or better otherwise to current broken code. I prefer the earlier patch, but both should work. -- error compiling committee.c: too many arguments to function