Linux Serial subsystem development
 help / color / mirror / Atom feed
From: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
To: Guenter Roeck <linux@roeck-us.net>
Cc: Jiri Slaby <jirislaby@kernel.org>,
	linux-kernel@vger.kernel.org, linux-serial@vger.kernel.org,
	Arnd Bergmann <arnd@arndb.de>,
	Niklas Schnelle <schnelle@linux.ibm.com>
Subject: Re: [PATCH] tty: serial: Work around warning backtrace in serial8250_set_defaults
Date: Fri, 6 Dec 2024 07:58:52 +0100	[thread overview]
Message-ID: <2024120642-prize-shawl-979d@gregkh> (raw)
In-Reply-To: <20241205143033.2695333-1-linux@roeck-us.net>

On Thu, Dec 05, 2024 at 06:30:33AM -0800, Guenter Roeck wrote:
> Commit 7c7e6c8924e7 ("tty: serial: handle HAS_IOPORT dependencies")
> triggers warning backtraces on a number of platforms which don't support
> IO ports.
> 
> WARNING: CPU: 0 PID: 0 at drivers/tty/serial/8250/8250_port.c:470 serial8250_set_defaults+0x148/0x1d8
> Unsupported UART type 0
> 
> The problem is seen because serial8250_set_defaults() is called for
> all members of the serial8250_ports[] array even if that array is
> not initialized.
> 
> Work around the problem by only displaying the warning if the port
> type is not 0 (UPIO_PORT) or if iobase is set for the port.
> 
> Fixes: 7c7e6c8924e7 ("tty: serial: handle HAS_IOPORT dependencies")
> Acked-by: Arnd Bergmann <arnd@arndb.de>
> Cc: Niklas Schnelle <schnelle@linux.ibm.com>
> Signed-off-by: Guenter Roeck <linux@roeck-us.net>
> ---
> A complete fix will require a sequence of patches, which will have to be
> tested thoroughly and is thus not 6.13 material. This patch doesn't fix
> the underlying problem, but it is good enough for 6.13, or at least not
> worse than 6.12, while at the same time avoiding the warning backtrace.

Thanks, I'll take this for now.

greg k-h

      parent reply	other threads:[~2024-12-06  6:58 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-12-05 14:30 [PATCH] tty: serial: Work around warning backtrace in serial8250_set_defaults Guenter Roeck
2024-12-05 19:12 ` Stafford Horne
2024-12-05 19:29   ` Guenter Roeck
2024-12-06  6:58 ` Greg Kroah-Hartman [this message]

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=2024120642-prize-shawl-979d@gregkh \
    --to=gregkh@linuxfoundation.org \
    --cc=arnd@arndb.de \
    --cc=jirislaby@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-serial@vger.kernel.org \
    --cc=linux@roeck-us.net \
    --cc=schnelle@linux.ibm.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