qemu-devel
[Top][All Lists]
Advanced

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

[Qemu-devel] Re: [PATCH 07/10] ram_save_remaining() returns an uint64_t


From: Anthony Liguori
Subject: [Qemu-devel] Re: [PATCH 07/10] ram_save_remaining() returns an uint64_t
Date: Tue, 30 Nov 2010 07:44:36 -0600
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.1.15) Gecko/20101027 Lightning/1.0b1 Thunderbird/3.0.10

On 11/30/2010 01:21 AM, Paolo Bonzini wrote:
On 11/30/2010 03:06 AM, Anthony Liguori wrote:

-static ram_addr_t ram_save_remaining(void)
+static uint64_t ram_save_remaining(void)
  {
      RAMBlock *block;
-    ram_addr_t count = 0;
+    uint64_t count = 0;

      QLIST_FOREACH(block,&ram_list.blocks, next) {
          ram_addr_t addr;

No, it returns a count of bytes of ram which is a subset of ram_addr_t's
space.  The unit is definitely right here.

It returns a count of pages, actually, which is a different unit.

Page size is just a fixed number in the ram_addr_t space.

Regards,

Anthony Liguori

For example, in practice it can fit in 32 bits even (though I'm not saying we should make it uint32_t; we'd be dangerously close to the limit for the guest sizes that Juan is handling).

Paolo




reply via email to

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