All of lore.kernel.org
 help / color / mirror / Atom feed
From: Fam Zheng <famz@redhat.com>
To: "Dr. David Alan Gilbert" <dgilbert@redhat.com>
Cc: cornelia.huck@de.ibm.com, qemu-devel@nongnu.org,
	Jianjun Duan <duanj@linux.vnet.ibm.com>
Subject: Re: [Qemu-devel] [PULL 02/15] migration: extend VMStateInfo
Date: Wed, 25 Jan 2017 20:12:29 +0800	[thread overview]
Message-ID: <20170125121229.GD9699@lemon.Home> (raw)
In-Reply-To: <20170125120053.GA2096@work-vm>

On Wed, 01/25 12:00, Dr. David Alan Gilbert wrote:
> * Fam Zheng (famz@redhat.com) wrote:
> > On Tue, 01/24 18:47, Dr. David Alan Gilbert (git) wrote:
> > > diff --git a/hw/intc/s390_flic_kvm.c b/hw/intc/s390_flic_kvm.c
> > > index c313166..da8e4df 100644
> > > --- a/hw/intc/s390_flic_kvm.c
> > > +++ b/hw/intc/s390_flic_kvm.c
> > > @@ -286,7 +286,8 @@ static void kvm_s390_release_adapter_routes(S390FLICState *fs,
> > >   * increase until buffer is sufficient or maxium size is
> > >   * reached
> > >   */
> > > -static void kvm_flic_save(QEMUFile *f, void *opaque, size_t size)
> > > +static int kvm_flic_save(QEMUFile *f, void *opaque, size_t size,
> > > +                         VMStateField *field, QJSON *vmdesc)
> > >  {
> > >      KVMS390FLICState *flic = opaque;
> > >      int len = FLIC_SAVE_INITIAL_SIZE;
> > > @@ -319,6 +320,8 @@ static void kvm_flic_save(QEMUFile *f, void *opaque, size_t size)
> > >                          count * sizeof(struct kvm_s390_irq));
> > >      }
> > >      g_free(buf);
> > > +
> > > +    return 0;
> > >  }
> > 
> > This hunk left one 'return' behind in the function, which should have been
> > changed to 'return 0' as well, and now the compiler is not happy:
> > 
> > /var/tmp/patchew-tester-tmp-itftfkl9/src/hw/intc/s390_flic_kvm.c: In function ‘kvm_flic_save’:
> > /var/tmp/patchew-tester-tmp-itftfkl9/src/hw/intc/s390_flic_kvm.c:306:9: error: ‘return’ with no value, in function returning non-void [-Werror]
> >          return;
> >          ^~~~~~
> > /var/tmp/patchew-tester-tmp-itftfkl9/src/hw/intc/s390_flic_kvm.c:289:12: note: declared here
> >  static int kvm_flic_save(QEMUFile *f, void *opaque, size_t size,
> >             ^~~~~~~~~~~~~
> > cc1: all warnings being treated as errors
> 
> OK, so it looks like that's a failure path, adding a return -ENOMEM would seem to make
> sense there.

OK! I was wrong.

> 
> Do you have a way of build testing that on x86, or can it only be build
> tested on s390?
> (My build test included an s390x-softmmu build on x86-64).

Unfortunately I don't know. This is reported by the newly connected s390x
patchew tester, which is in staging so not replying publicly yet. Hopefully we
can get s390x native build covered in the future.

Fam

> 
> Dave
> > Fam
> --
> Dr. David Alan Gilbert / dgilbert@redhat.com / Manchester, UK

  parent reply	other threads:[~2017-01-25 12:12 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-01-24 18:47 [Qemu-devel] [PULL 00/15] migration queue Dr. David Alan Gilbert (git)
2017-01-24 18:47 ` [Qemu-devel] [PULL 01/15] MAINTAINERS: Add myself as a migration submaintainer Dr. David Alan Gilbert (git)
2017-01-24 18:47 ` [Qemu-devel] [PULL 02/15] migration: extend VMStateInfo Dr. David Alan Gilbert (git)
2017-01-25 11:46   ` Fam Zheng
2017-01-25 12:00     ` Dr. David Alan Gilbert
2017-01-25 12:07       ` Cornelia Huck
2017-01-25 12:12       ` Fam Zheng [this message]
2017-01-25 12:19       ` Cornelia Huck
2017-01-25 13:22         ` Dr. David Alan Gilbert
2017-01-25 14:20           ` Cornelia Huck
2017-01-25 14:44             ` Dr. David Alan Gilbert
2017-01-26 12:14               ` Cornelia Huck
2017-01-27 18:20                 ` Dr. David Alan Gilbert
2017-02-01 10:18                   ` Cornelia Huck
2017-01-24 18:47 ` [Qemu-devel] [PULL 03/15] migration: migrate QTAILQ Dr. David Alan Gilbert (git)
2017-01-24 18:47 ` [Qemu-devel] [PULL 04/15] tests/migration: Add test for QTAILQ migration Dr. David Alan Gilbert (git)
2017-01-24 18:47 ` [Qemu-devel] [PULL 05/15] migration: add error_report Dr. David Alan Gilbert (git)
2017-01-24 18:47 ` [Qemu-devel] [PULL 06/15] block/vvfat: Remove the undesirable comment Dr. David Alan Gilbert (git)
2017-01-24 18:47 ` [Qemu-devel] [PULL 07/15] migration: Add a new option to enable only-migratable Dr. David Alan Gilbert (git)
2017-01-24 18:47 ` [Qemu-devel] [PULL 08/15] migration: Allow "device add" options to only add migratable devices Dr. David Alan Gilbert (git)
2017-01-24 18:47 ` [Qemu-devel] [PULL 09/15] migration: disallow migrate_add_blocker during migration Dr. David Alan Gilbert (git)
2017-01-24 18:47 ` [Qemu-devel] [PULL 10/15] migration: Fail migration blocker for --only-migratable Dr. David Alan Gilbert (git)
2017-01-24 18:47 ` [Qemu-devel] [PULL 11/15] migration: re-active images while migration been canceled after inactive them Dr. David Alan Gilbert (git)
2017-01-24 18:47 ` [Qemu-devel] [PULL 12/15] migration: Change name of live migration thread Dr. David Alan Gilbert (git)
2017-01-24 18:47 ` [Qemu-devel] [PULL 13/15] PCI/migration merge vmstate_pci_device and vmstate_pcie_device Dr. David Alan Gilbert (git)
2017-01-24 18:47 ` [Qemu-devel] [PULL 14/15] migration: transform remaining DPRINTF into trace_ Dr. David Alan Gilbert (git)
2017-01-24 18:47 ` [Qemu-devel] [PULL 15/15] migration/tracing: Add tracing on save Dr. David Alan Gilbert (git)
2017-01-25 10:41 ` [Qemu-devel] [PULL 00/15] migration queue Peter Maydell

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20170125121229.GD9699@lemon.Home \
    --to=famz@redhat.com \
    --cc=cornelia.huck@de.ibm.com \
    --cc=dgilbert@redhat.com \
    --cc=duanj@linux.vnet.ibm.com \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.