public inbox for linux-serial@vger.kernel.org
 help / color / mirror / Atom feed
From: Greg KH <gregkh@linuxfoundation.org>
To: Zong Jiang <quic_zongjian@quicinc.com>
Cc: linux-serial@vger.kernel.org, linux-kernel@vger.kernel.org,
	quic_ztu@quicinc.com, quic_anupkulk@quicinc.com,
	quic_msavaliy@quicinc.com, quic_vdadhani@quicinc.com
Subject: Re: [PATCH 2/2] serial: qcom-geni: Make UART port count configurable via Kconfig
Date: Tue, 12 Aug 2025 08:29:56 +0200	[thread overview]
Message-ID: <2025081249-amusement-spongy-e052@gregkh> (raw)
In-Reply-To: <20250812054819.3748649-3-quic_zongjian@quicinc.com>

On Tue, Aug 12, 2025 at 01:48:19PM +0800, Zong Jiang wrote:
> Replace the hardcoded GENI_UART_PORTS macro with a new Kconfig option
> SERIAL_QCOM_GENI_UART_PORTS to allow platforms to configure the maximum
> number of UART ports supported by the driver at build time.
> 
> This improves flexibility for platforms that require more than the
> previously fixed number of UART ports, and avoids unnecessary allocation
> for unused ports.
> 
> Signed-off-by: Zong Jiang <quic_zongjian@quicinc.com>
> ---
>  drivers/tty/serial/Kconfig            | 8 ++++++++
>  drivers/tty/serial/qcom_geni_serial.c | 5 ++---
>  2 files changed, 10 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/tty/serial/Kconfig b/drivers/tty/serial/Kconfig
> index 44427415a80d..e661f5951f55 100644
> --- a/drivers/tty/serial/Kconfig
> +++ b/drivers/tty/serial/Kconfig
> @@ -928,6 +928,14 @@ config SERIAL_QCOM_GENI_CONSOLE
>  	  Serial console driver for Qualcomm Technologies Inc's GENI based
>  	  QUP hardware.
>  
> +config SERIAL_QCOM_GENI_UART_PORTS
> +	int "Maximum number of GENI UART ports"
> +	depends on SERIAL_QCOM_GENI
> +	default "8"
> +	help
> +	  Set this to the maximum number of serial ports you want the driver
> +	  to support.

Why do you need a static number of ports at all?  Why not just handle
how ever many there are in the system at the moment?  Or is this due to
some restriction in the serial core that requires this?

thanks,

greg k-h

  reply	other threads:[~2025-08-12  6:29 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-08-12  5:48 [PATCH v2 0/2] serial: qcom-geni: Add support to increase UART ports efficiently Zong Jiang
2025-08-12  5:48 ` [PATCH 1/2] serial: qcom-geni: Dynamically allocate UART ports Zong Jiang
2025-08-12  5:48 ` [PATCH 2/2] serial: qcom-geni: Make UART port count configurable via Kconfig Zong Jiang
2025-08-12  6:29   ` Greg KH [this message]
2025-08-13  6:51     ` Zong Jiang (QUIC)

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=2025081249-amusement-spongy-e052@gregkh \
    --to=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-serial@vger.kernel.org \
    --cc=quic_anupkulk@quicinc.com \
    --cc=quic_msavaliy@quicinc.com \
    --cc=quic_vdadhani@quicinc.com \
    --cc=quic_zongjian@quicinc.com \
    --cc=quic_ztu@quicinc.com \
    /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