[PATCH 0/1] imx_serial: add missing migration state

Tao Ding posted 1 patch 1 week, 3 days ago
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/20260715131819.14827-1-dingtao0430@163.com
Maintainers: Peter Maydell <peter.maydell@linaro.org>, "Marc-André Lureau" <marcandre.lureau@redhat.com>, Paolo Bonzini <pbonzini@redhat.com>
hw/char/imx_serial.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
[PATCH 0/1] imx_serial: add missing migration state
Posted by Tao Ding 1 week, 3 days ago
Hi all.
The imx_serial is missing a migration status, 
resulting in no display on the terminal after migration.
This patch fixes this issue.

Thanks.

Tao Ding (1):
  hw/char: imx_serial: add missing migration state

 hw/char/imx_serial.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)


base-commit: eca2c16212ef9dcb0871de39bb9d1c2efebe76be
-- 
2.43.0
Re: [PATCH 0/1] imx_serial: add missing migration state
Posted by Peter Maydell 1 week, 1 day ago
On Wed, 15 Jul 2026 at 14:18, Tao Ding <dingtao0430@163.com> wrote:
>
> Hi all.
> The imx_serial is missing a migration status,
> resulting in no display on the terminal after migration.
> This patch fixes this issue.

Whoops. Yes, ucr2 has the rx enable and tx enable bits,
so not migrating it will leave the UART in a completely
broken state.

I've applied this patch to target-arm.next for 11.1. I
tweaked the commit message a bit to lead off with a clearer
description of the problem and to note that it's a migration
compat break:

    The imx_serial vmstate is missing the ucr2 field.  This register
    includes important state like the transmit enable and receive enable
    bits, so it's likely that after a migration the UART will be in a
    completely broken state. This bug has been present ever since
    the UART code was first added to QEMU.

    Add ucr2 from imx_serial to vmstate, and increment the version_id.
    This is a migration compatibility break, but this UART is only used
    in the various imx-based boards, where we are OK with compat breaks.

    [etc]

thanks
-- PMM