From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:36837) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1URwVU-0004fU-7c for qemu-devel@nongnu.org; Mon, 15 Apr 2013 23:24:32 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1URwVT-0004yK-Ao for qemu-devel@nongnu.org; Mon, 15 Apr 2013 23:24:32 -0400 Received: from mail-ea0-x229.google.com ([2a00:1450:4013:c01::229]:37828) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1URwVT-0004yC-4A for qemu-devel@nongnu.org; Mon, 15 Apr 2013 23:24:31 -0400 Received: by mail-ea0-f169.google.com with SMTP id n15so19186ead.0 for ; Mon, 15 Apr 2013 20:24:30 -0700 (PDT) Sender: Paolo Bonzini Message-ID: <516CC465.6090305@redhat.com> Date: Tue, 16 Apr 2013 05:24:21 +0200 From: Paolo Bonzini MIME-Version: 1.0 References: <1366080286-9288-1-git-send-email-mrhines@linux.vnet.ibm.com> <1366080286-9288-3-git-send-email-mrhines@linux.vnet.ibm.com> In-Reply-To: <1366080286-9288-3-git-send-email-mrhines@linux.vnet.ibm.com> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PULL 2/8] rdma: new QEMUFileOps hooks List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: mrhines@linux.vnet.ibm.com Cc: aliguori@us.ibm.com, mst@redhat.com, qemu-devel@nongnu.org, owasserm@redhat.com, abali@us.ibm.com, mrhines@us.ibm.com, gokul@us.ibm.com Il 16/04/2013 04:44, mrhines@linux.vnet.ibm.com ha scritto: > +void ram_control_load_hook(QEMUFile *f, uint32_t flags) > +{ > + int ret = 0; > + > + if (f->ops->hook_ram_load) { > + ret = f->ops->hook_ram_load(f, f->opaque, flags); > + if (ret < 0) { > + qemu_file_set_error(f, ret); > + } > + } > +} This must set an error if the hook is not implemented. Paolo