Hi Denis,

Thank you for the patch.

On Tue, Sep 9, 2025 at 12:12 AM <[email protected]> wrote:
>
> From: Denis Mukhin <[email protected]>
>
> Add SCR register emulation to the I/O port handler.
> Firmware (e.g. OVMF) may use SCR during the guest OS boot.
>
> Signed-off-by: Denis Mukhin <[email protected]>
> ---
> Changes since v6:
> - default handling of non-DLL/DLM registers moved to the previous patch
> ---
>  xen/common/emul/vuart/ns16x50.c | 9 +++++++++
>  1 file changed, 9 insertions(+)
>
> diff --git a/xen/common/emul/vuart/ns16x50.c b/xen/common/emul/vuart/ns16x50.c
> index da8583a1dc93..5643ef4cc01e 100644
> --- a/xen/common/emul/vuart/ns16x50.c
> +++ b/xen/common/emul/vuart/ns16x50.c
> @@ -106,6 +106,11 @@ static int ns16x50_io_write8(
>      {
>          switch ( reg )
>          {
> +        /* NB: Firmware (e.g. OVMF) may rely on SCR presence. */
> +        case UART_SCR:
> +            regs[UART_SCR] = val;
> +            break;
> +
>          default:
>              rc = -EINVAL;
>              break;
> @@ -177,6 +182,10 @@ static int ns16x50_io_read8(
>      {
>          switch ( reg )
>          {
> +        case UART_SCR:
> +            val = regs[UART_SCR];
> +            break;
> +
>          default:
>              rc = -EINVAL;
>              break;
> --
> 2.51.0
>
>

Reviewed-by: Mykola Kvach <[email protected]>

Best regards,
Mykola

Reply via email to