All of lore.kernel.org
 help / color / mirror / Atom feed
From: Gonglei <arei.gonglei@huawei.com>
To: Gerd Hoffmann <kraxel@redhat.com>
Cc: "qemu-devel@nongnu.org" <qemu-devel@nongnu.org>,
	"Dr. David Alan Gilbert" <dgilbert@redhat.com>
Subject: Re: [Qemu-devel] [RfC PATCH] hid: handle full ptr queues in post_load
Date: Thu, 27 Nov 2014 20:28:38 +0800	[thread overview]
Message-ID: <547718F6.6080803@huawei.com> (raw)
In-Reply-To: <54770972.60206@huawei.com>

On 2014/11/27 19:22, Gonglei wrote:

> On 2014/11/27 19:19, Gerd Hoffmann wrote:
> 
>> On Do, 2014-11-27 at 19:16 +0800, Gonglei wrote:
>>> On 2014/11/27 19:04, Gerd Hoffmann wrote:
>>>
>>>>   Hi,
>>>>
>>>>>> +        evt = s->ptr.queue[(s->head+s->n) & QUEUE_MASK];
>>>>>
>>>>> s->n is QUEUE_LENGTH, can we directly delete it?
>>>>>   evt = s->ptr.queue[s->head & QUEUE_MASK]
>>>>
>>>> I prefer to make clear in the code that we want the last ring element
>>>> not the first and leave in the "+n", even if we could take it out.
>>>>
>>> OK.
>>>
>>> Another question, whether or not we handle this scenario
>>> before calling hid_set_next_idle(s) ? Maybe it is safer, because
>>> hid_idle_timer will call  hid_pointer_event(), callback function
>>> of hs->event(hs).
>>
>> Not needed, the timer will not called before vmload is completely
>> finished.
>>
> 
> Yep, as the Qemu big lock.
> I will test this patch later, thanks for your work. :)
> 
Patch works for me.  Thanks.

Tested-by: Gonglei <arei.gonglei@huawei.com>
Reviewed-by: Gonglei <arei.gonglei@huawei.com>

Regards,
-Gonglei

      reply	other threads:[~2014-11-27 12:29 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-11-27  9:04 [Qemu-devel] [RfC PATCH] hid: handle full ptr queues in post_load Gerd Hoffmann
2014-11-27  9:25 ` Gonglei
2014-11-27 11:04   ` Gerd Hoffmann
2014-11-27 11:16     ` Gonglei
2014-11-27 11:19       ` Gerd Hoffmann
2014-11-27 11:22         ` Gonglei
2014-11-27 12:28           ` Gonglei [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=547718F6.6080803@huawei.com \
    --to=arei.gonglei@huawei.com \
    --cc=dgilbert@redhat.com \
    --cc=kraxel@redhat.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.