From: Arwed Meyer <arwed.meyer@gmx.de>
To: Peter Maydell <peter.maydell@linaro.org>
Cc: qemu-devel@nongnu.org, qemu-stable@nongnu.org,
"Marc-André Lureau" <marcandre.lureau@redhat.com>,
"Paolo Bonzini" <pbonzini@redhat.com>
Subject: Re: [PATCH v2 1/5] msmouse: Handle mouse reset
Date: Mon, 12 Sep 2022 19:45:23 +0200 [thread overview]
Message-ID: <8bb22c23-23b2-8c2c-12e7-24a2f299445c@gmx.de> (raw)
In-Reply-To: <CAFEAcA-9RD_Lxypgm1yM6T_R=SS=LD9JPQbD5SFek4_wrCnKhg@mail.gmail.com>
Am 11.09.22 um 20:27 schrieb Peter Maydell:
> On Sun, 11 Sept 2022 at 18:14, Arwed Meyer <arwed.meyer@gmx.de> wrote:
>>
>> Am 08.09.22 um 23:11 schrieb Peter Maydell:
>>> On Thu, 8 Sept 2022 at 18:43, Arwed Meyer <arwed.meyer@gmx.de> wrote:
>>>>
>>>> Detect mouse reset via RTS or DTR line:
>>>> Don't send or process anything while in reset.
>>>> When coming out of reset, send ID sequence first thing.
>>>> This allows msmouse to be detected by common mouse drivers.
>>>>
>>>> Resolves: https://gitlab.com/qemu-project/qemu/-/issues/77
>>>> Signed-off-by: Arwed Meyer <arwed.meyer@gmx.de>
>>>
>>> How does this work across migration? There doesn't seem
>>> to be anything that handles migration of the existing
>>> state inside the MouseChardev either, though...
>
>> can you please explain in more detail what you don't understand and what
>> you mean by "migration"?
>
> Migration is when the state of the whole VM is copied from
> one host to another, or, equivalently, when it is saved to
> the disk image with 'savevm' to be restarted later. For this
> to work all the guest-changeable state in the whole VM (all
> device registers, internal state, etc) has to be saved so
> it can be reloaded on the destination. My question is basically
> how this new state in mouse->tiocm, and more generally how
> the existing other state fields in that struct, are saved
> and loaded during the migration process. I know how this
> works for device models, but I'm not sure how chardevs
> figure into it. (Perhaps the answer is "this shouldn't be
> a chardev at all" ???)
>
> thanks
> -- PMM
Hi,
thanks for adding some context. Good question.
Unfortunately I don't know the device and migration code much, so I
can't really say anything about this. I guess(!) it should be enough to
save/load contents of struct MouseChardev. No idea if and how this can
be done though.
Also since saving/loading device state wasn't supported in the msmouse
code to begin with, for me this is a new feature and out of scope for
this patch set.
The result of this missing feature might be that mouse buttons are
detected as not pressed and mouse movement data is lost after migration.
Regards
next prev parent reply other threads:[~2022-09-12 17:51 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-09-08 17:31 [PATCH v2 0/5] Make serial msmouse work Arwed Meyer
2022-09-08 17:31 ` [PATCH v2 1/5] msmouse: Handle mouse reset Arwed Meyer
2022-09-08 21:11 ` Peter Maydell
2022-09-11 17:14 ` Arwed Meyer
2022-09-11 18:27 ` Peter Maydell
2022-09-12 17:45 ` Arwed Meyer [this message]
2022-09-12 17:54 ` Arwed Meyer
2022-09-13 12:30 ` Peter Maydell
2022-09-08 17:31 ` [PATCH v2 2/5] chardev: src buffer const for write functions Arwed Meyer
2022-09-09 13:13 ` Marc-André Lureau
2022-09-08 17:31 ` [PATCH v2 3/5] msmouse: Use fifo8 instead of array Arwed Meyer
2022-09-09 13:18 ` Marc-André Lureau
2022-09-11 17:27 ` Arwed Meyer
2022-09-11 6:12 ` Volker Rümelin
2022-09-11 17:53 ` Arwed Meyer
2022-09-08 17:31 ` [PATCH v2 4/5] msmouse: Add pnp data Arwed Meyer
2022-09-09 13:20 ` Marc-André Lureau
2022-09-08 17:31 ` [PATCH v2 5/5] serial: Allow unaligned i/o access Arwed Meyer
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=8bb22c23-23b2-8c2c-12e7-24a2f299445c@gmx.de \
--to=arwed.meyer@gmx.de \
--cc=marcandre.lureau@redhat.com \
--cc=pbonzini@redhat.com \
--cc=peter.maydell@linaro.org \
--cc=qemu-devel@nongnu.org \
--cc=qemu-stable@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 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).