qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "Pavel Dovgalyuk" <dovgaluk@ispras.ru>
To: quintela@redhat.com
Cc: 'Pavel Dovgalyuk' <Pavel.Dovgaluk@ispras.ru>,
	qemu-devel@nongnu.org, mst@redhat.com, dgilbert@redhat.com,
	maria.klimushenkova@ispras.ru, pbonzini@redhat.com
Subject: Re: [Qemu-devel] [PATCH v2] hpet: recover timer offset correctly
Date: Wed, 10 Jan 2018 13:10:04 +0300	[thread overview]
Message-ID: <001a01d389fb$2f33b1f0$8d9b15d0$@ru> (raw)
In-Reply-To: <87d12iyrct.fsf@secure.laptop>



> -----Original Message-----
> From: Juan Quintela [mailto:quintela@redhat.com]
> Sent: Wednesday, January 10, 2018 12:51 PM
> To: Pavel Dovgalyuk
> Cc: 'Pavel Dovgalyuk'; qemu-devel@nongnu.org; mst@redhat.com; dgilbert@redhat.com;
> maria.klimushenkova@ispras.ru; pbonzini@redhat.com
> Subject: Re: [PATCH v2] hpet: recover timer offset correctly
> 
> "Pavel Dovgalyuk" <dovgaluk@ispras.ru> wrote:
> >> From: Juan Quintela [mailto:quintela@redhat.com]
> >> "Pavel Dovgalyuk" <dovgaluk@ispras.ru> wrote:
> >> >> From: Juan Quintela [mailto:quintela@redhat.com]
> >> If you *don't* use a needed function then please just increase the
> >> version.  You are just breaking compatibility anyways.  The whole point
> >> of subsections is that they are optional.  If they are mandatory (this
> >> case), then they bring no advantage at all.
> >
> > Thanks, I thought that the sections are skipped automatically when
> > there is no code for loading
> > them.
> >
> >> What dave is asked for your previous version is that you disable the
> >> section for old machine types.  Look at how to use DEFINE_PROP_* for
> >> this use case.
> >
> > How do you like this one?
> 
> Much better, thanks.
> 
> > +static bool hpet_offset_needed(void *opaque)
> > +{
> > +    HPETState *s = opaque;
> > +
> > +    return s->hpet_offset_saved;
> > +}
> > +
> 
> If this is only one optimization, this test is ok.  If it makes things
> go worse, you can add something there like && hpet_enabled() or
> whatever.  Remember that I don't understand HPET.

Right. Please check the new version of the patch.

> > diff --git a/include/hw/compat.h b/include/hw/compat.h
> > index 263de97..8897302 100644
> > --- a/include/hw/compat.h
> > +++ b/include/hw/compat.h
> > @@ -13,6 +13,10 @@
> >          .driver   = "virtio-tablet-device",\
> >          .property = "wheel-axis",\
> >          .value    = "false",\
> > +    },{\
> > +        .driver   = "hpet",\
> > +        .property = "hpet-offset-saved",\
> > +        .value    = "off",\
> >      },
> >
> >  #define HW_COMPAT_2_9 \
> 
> This should be on 2_11 not 2_10 O:-)
> 
> But for the vmstate bits:
> 
> Reviewed-by: Juan Quintela <quintela@redhat.com>

Thanks.

Pavel Dovgalyuk

      reply	other threads:[~2018-01-10 10:10 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-12-20 10:02 [Qemu-devel] [PATCH v2] hpet: recover timer offset correctly Pavel Dovgalyuk
2018-01-09  8:23 ` Pavel Dovgalyuk
2018-01-09 11:26   ` Juan Quintela
2018-01-09 11:52     ` Pavel Dovgalyuk
2018-01-09 13:08       ` Juan Quintela
2018-01-10  9:33         ` Pavel Dovgalyuk
2018-01-10  9:50           ` Juan Quintela
2018-01-10 10:10             ` Pavel Dovgalyuk [this message]

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='001a01d389fb$2f33b1f0$8d9b15d0$@ru' \
    --to=dovgaluk@ispras.ru \
    --cc=Pavel.Dovgaluk@ispras.ru \
    --cc=dgilbert@redhat.com \
    --cc=maria.klimushenkova@ispras.ru \
    --cc=mst@redhat.com \
    --cc=pbonzini@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=quintela@redhat.com \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).