From patchwork Thu Sep 26 21:03:05 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christoffer Dall X-Patchwork-Id: 278277 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [IPv6:2001:4830:134:3::11]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id EB9A12C033B for ; Fri, 27 Sep 2013 07:20:13 +1000 (EST) Received: from localhost ([::1]:59948 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VPIku-0004Ms-JO for incoming@patchwork.ozlabs.org; Thu, 26 Sep 2013 17:05:48 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:56841) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VPIia-0008DD-RN for qemu-devel@nongnu.org; Thu, 26 Sep 2013 17:03:31 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VPIiU-0000tn-Dy for qemu-devel@nongnu.org; Thu, 26 Sep 2013 17:03:24 -0400 Received: from mail-pd0-f171.google.com ([209.85.192.171]:39967) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VPIiU-0000tb-8d for qemu-devel@nongnu.org; Thu, 26 Sep 2013 17:03:18 -0400 Received: by mail-pd0-f171.google.com with SMTP id g10so1676950pdj.2 for ; Thu, 26 Sep 2013 14:03:17 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=hAm1krUw5r+B6pEvAmE5jlZm5h3/OGbAR6eAT6jCe3o=; b=B8ocO29uz6wDG8a0jRuiKpR/WRDI43qlVEIcsMtV8XUgvE34OO3/pcVI9iO6vJJ8bd I+W4OFEn+huViTtxQRKbANqyUH+d59o+tUC4X91M09htF6vtGphzeMt+kr1p45job/ts +XBthY8Flca7McAPBBKd8Q5TGoM/R/3n5lBhKDYZmbbZtE3NO0duLC3HMs5FYDA+rQUY LIyCf4BfBZ2g3qzW6zfTH+Qn2yQ/s9XiweI+G9q2MIdynfCEnQzl4L2vlJzjIM6/yDPn ISbkP8J+9AOYHp//gVZ469rhT+jO291Dm0NReJ8GFbcRFLshdH52ro700PJT+GkEQUJP 30Ig== X-Gm-Message-State: ALoCoQmNMN3RBWIEpzsNREWeIe7/Z3F94cakchCG58yZT3Hho3e04KbB6rXkd30NYH511t8x0dCJ X-Received: by 10.68.193.98 with SMTP id hn2mr2759248pbc.191.1380229397576; Thu, 26 Sep 2013 14:03:17 -0700 (PDT) Received: from localhost.localdomain (c-67-169-181-221.hsd1.ca.comcast.net. [67.169.181.221]) by mx.google.com with ESMTPSA id 7sm7385572paf.22.1969.12.31.16.00.00 (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 26 Sep 2013 14:03:16 -0700 (PDT) From: Christoffer Dall To: qemu-devel@nongnu.org Date: Thu, 26 Sep 2013 14:03:05 -0700 Message-Id: <1380229386-24166-6-git-send-email-christoffer.dall@linaro.org> X-Mailer: git-send-email 1.7.10.4 In-Reply-To: <1380229386-24166-1-git-send-email-christoffer.dall@linaro.org> References: <1380229386-24166-1-git-send-email-christoffer.dall@linaro.org> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 209.85.192.171 Cc: kvmarm@lists.cs.columbia.edu, Christoffer Dall , patches@linaro.org Subject: [Qemu-devel] [RFC PATCH v2 5/6] vmstate: Add uint32 2D-array support X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Add support for saving VMtate of 2D arrays of uint32 values. Signed-off-by: Christoffer Dall Reviewed-by: Peter Maydell --- include/migration/vmstate.h | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/include/migration/vmstate.h b/include/migration/vmstate.h index 1c31b5d..e5538c7 100644 --- a/include/migration/vmstate.h +++ b/include/migration/vmstate.h @@ -633,9 +633,15 @@ extern const VMStateInfo vmstate_info_bitmap; #define VMSTATE_UINT32_ARRAY_V(_f, _s, _n, _v) \ VMSTATE_ARRAY(_f, _s, _n, _v, vmstate_info_uint32, uint32_t) +#define VMSTATE_UINT32_2DARRAY_V(_f, _s, _n1, _n2, _v) \ + VMSTATE_2DARRAY(_f, _s, _n1, _n2, _v, vmstate_info_uint32, uint32_t) + #define VMSTATE_UINT32_ARRAY(_f, _s, _n) \ VMSTATE_UINT32_ARRAY_V(_f, _s, _n, 0) +#define VMSTATE_UINT32_2DARRAY(_f, _s, _n1, _n2) \ + VMSTATE_UINT32_2DARRAY_V(_f, _s, _n1, _n2, 0) + #define VMSTATE_UINT64_ARRAY_V(_f, _s, _n, _v) \ VMSTATE_ARRAY(_f, _s, _n, _v, vmstate_info_uint64, uint64_t)