[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CAJZ5v0gHw7ECzDF-tVQ=Ve0LO3m3Gm5DfF6=vxi_CFsZ6y_xAQ@mail.gmail.com>
Date: Mon, 22 Sep 2025 19:14:46 +0200
From: "Rafael J. Wysocki" <rafael@...nel.org>
To: cp0613@...ux.alibaba.com
Cc: rafael@...nel.org, lenb@...nel.org, guoren@...nel.org,
jeeheng.sia@...rfivetech.com, linux-acpi@...r.kernel.org,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH v3] ACPI: SPCR: Support Precise Baud Rate filed
On Sat, Sep 13, 2025 at 9:08 AM <cp0613@...ux.alibaba.com> wrote:
>
> From: Chen Pei <cp0613@...ux.alibaba.com>
>
> The Microsoft Serial Port Console Redirection (SPCR) specification
> revision 1.09 comprises additional field: Precise Baud Rate [1].
>
> It is used to describe non-traditional baud rates (such as those
> used by high-speed UARTs).
>
> It contains a specific non-zero baud rate which overrides the value
> of the Configured Baud Rate field. If this field is zero or not
> present, Configured Baud Rate is used.
>
> Link: https://learn.microsoft.com/en-us/windows-hardware/drivers/serports/serial-port-console-redirection-table # 1
>
> Signed-off-by: Chen Pei <cp0613@...ux.alibaba.com>
> ---
> drivers/acpi/spcr.c | 10 +++++++++-
> 1 file changed, 9 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/acpi/spcr.c b/drivers/acpi/spcr.c
> index cd36a97b0ea2..fa12e740386d 100644
> --- a/drivers/acpi/spcr.c
> +++ b/drivers/acpi/spcr.c
> @@ -146,7 +146,15 @@ int __init acpi_parse_spcr(bool enable_earlycon, bool enable_console)
> goto done;
> }
>
> - switch (table->baud_rate) {
> + /*
> + * SPCR 1.09 defines Precise Baud Rate Filed contains a specific
> + * non-zero baud rate which overrides the value of the Configured
> + * Baud Rate field. If this field is zero or not present, Configured
> + * Baud Rate is used.
> + */
> + if (table->precise_baudrate)
> + baud_rate = table->precise_baudrate;
> + else switch (table->baud_rate) {
> case 0:
> /*
> * SPCR 1.04 defines 0 as a preconfigured state of UART.
> --
Applied as 6.18 material, thanks!
Powered by blists - more mailing lists