From: David Gibson <david@gibson.dropbear.id.au>
To: Russell King <rmk@arm.linux.org.uk>
Cc: linux-kernel@vger.kernel.org, linuxppc-embedded@lists.linuxppc.org
Subject: Re: Serial core problems on embedded PPC
Date: Tue, 30 Jul 2002 11:12:03 +1000 [thread overview]
Message-ID: <20020730011203.GL2351@zax> (raw)
In-Reply-To: <20020729100009.A23843@flint.arm.linux.org.uk>
On Mon, Jul 29, 2002 at 10:00:10AM +0100, Russell King wrote:
> On Mon, Jul 29, 2002 at 02:08:24PM +1000, David Gibson wrote:
> > I've been trying to get the new serial core stuff working on a PPC 4xx
> > machine (an EP405 board, specifically). This is proving more
> > difficult than I expected.
>
> It's vital that you mention the kernel version you're using; some of
> these problems sound like 2.5.28.
Sorry. I'm working off the linuxppc-2.5 BK tree, which is currently
at 2.5.29.
> > In 8250.c, it appears that in order for a port to be used for the
> > serial console it must be defined "old style" with SERIAL_PORT_DFNS,
> > rather than being registered with register_serial() (because
> > serial8250_console_setup() indexs into the serial8250_ports array)).
> > This presents a small problem for 4xx, since it's serial ports are
> > memory mapped and the new old_serial_port structure can't represent
> > these.
>
> There is no easy solution for this. Alan said we must not drop support
> for serial console initialisation early on in the kernel setup, which
> means before the memory subsystems are initialised.
>
> > I added support for these into 8250.c, but ran into further troubles.
>
> I suspect a 2.5.28 kernel; please confirm and we'll that it from there.
2.5.29 based BK, actually.
> > The current plethora of similar-but-not-the-same structures describing
> > serial ports (serial_state, serial_struct, uart_port, old_serial_port)
> > is also rather confusing. I'm guessing some of these are deprecated
> > and remain only as an aid to transition, but I'm not sure which.
>
> I don't see there being an easy way to kill this off:
>
> 1. serial_struct is a userspace API.
Ok.
> 2. old_serial_port glues asm/serial.h into 8250.c; asm/serial.h can't be
> changed because (mainly) ppc uses it elsewhere. Other architectures
> seem to do the same sort of thing.
I think PPC's use of asm/serial.h in the bootloader needs to go away
anyway. Could old_serial_port at least change base_baud to baud_base
to match serial_struct and serial_state. That way a designated
initializer will work in either context.
> Unless ppc and others are willing to put up with major breakage when I
> change asm/serial.h, I don't see this getting cleaned up. Comments on
> this area welcome.
Well, the machines I'm working on are totally broken now, so...
--
David Gibson | For every complex problem there is a
david@gibson.dropbear.id.au | solution which is simple, neat and
| wrong.
http://www.ozlabs.org/people/dgibson
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
WARNING: multiple messages have this Message-ID (diff)
From: David Gibson <david@gibson.dropbear.id.au>
To: Russell King <rmk@arm.linux.org.uk>
Cc: linux-kernel@vger.kernel.org, linuxppc-embedded@lists.linuxppc.org
Subject: Re: Serial core problems on embedded PPC
Date: Tue, 30 Jul 2002 11:12:03 +1000 [thread overview]
Message-ID: <20020730011203.GL2351@zax> (raw)
In-Reply-To: <20020729100009.A23843@flint.arm.linux.org.uk>
On Mon, Jul 29, 2002 at 10:00:10AM +0100, Russell King wrote:
> On Mon, Jul 29, 2002 at 02:08:24PM +1000, David Gibson wrote:
> > I've been trying to get the new serial core stuff working on a PPC 4xx
> > machine (an EP405 board, specifically). This is proving more
> > difficult than I expected.
>
> It's vital that you mention the kernel version you're using; some of
> these problems sound like 2.5.28.
Sorry. I'm working off the linuxppc-2.5 BK tree, which is currently
at 2.5.29.
> > In 8250.c, it appears that in order for a port to be used for the
> > serial console it must be defined "old style" with SERIAL_PORT_DFNS,
> > rather than being registered with register_serial() (because
> > serial8250_console_setup() indexs into the serial8250_ports array)).
> > This presents a small problem for 4xx, since it's serial ports are
> > memory mapped and the new old_serial_port structure can't represent
> > these.
>
> There is no easy solution for this. Alan said we must not drop support
> for serial console initialisation early on in the kernel setup, which
> means before the memory subsystems are initialised.
>
> > I added support for these into 8250.c, but ran into further troubles.
>
> I suspect a 2.5.28 kernel; please confirm and we'll that it from there.
2.5.29 based BK, actually.
> > The current plethora of similar-but-not-the-same structures describing
> > serial ports (serial_state, serial_struct, uart_port, old_serial_port)
> > is also rather confusing. I'm guessing some of these are deprecated
> > and remain only as an aid to transition, but I'm not sure which.
>
> I don't see there being an easy way to kill this off:
>
> 1. serial_struct is a userspace API.
Ok.
> 2. old_serial_port glues asm/serial.h into 8250.c; asm/serial.h can't be
> changed because (mainly) ppc uses it elsewhere. Other architectures
> seem to do the same sort of thing.
I think PPC's use of asm/serial.h in the bootloader needs to go away
anyway. Could old_serial_port at least change base_baud to baud_base
to match serial_struct and serial_state. That way a designated
initializer will work in either context.
> Unless ppc and others are willing to put up with major breakage when I
> change asm/serial.h, I don't see this getting cleaned up. Comments on
> this area welcome.
Well, the machines I'm working on are totally broken now, so...
--
David Gibson | For every complex problem there is a
david@gibson.dropbear.id.au | solution which is simple, neat and
| wrong.
http://www.ozlabs.org/people/dgibson
next prev parent reply other threads:[~2002-07-30 1:12 UTC|newest]
Thread overview: 50+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-07-29 4:08 Serial core problems on embedded PPC David Gibson
2002-07-29 4:08 ` David Gibson
2002-07-29 9:00 ` Russell King
2002-07-29 9:00 ` Russell King
2002-07-29 14:44 ` Tom Rini
2002-07-29 14:44 ` Tom Rini
2002-07-29 17:17 ` [parisc-linux] 3 Serial issues up for discussion (was: Re: Serial core problems on embedded PPC) Russell King
2002-07-29 17:17 ` Russell King
2002-07-29 17:17 ` Russell King
2002-07-29 17:17 ` Russell King
2002-07-29 17:43 ` Tom Rini
2002-07-29 17:43 ` Tom Rini
2002-07-29 18:13 ` Benjamin Herrenschmidt
2002-07-29 18:13 ` Benjamin Herrenschmidt
2002-07-29 19:07 ` Tom Rini
2002-07-29 19:07 ` Tom Rini
2002-07-29 19:09 ` 3 Serial issues up for discussion (was: " Dan Malek
2002-07-29 19:09 ` Dan Malek
2002-07-29 19:46 ` Remco Treffkorn
2002-07-29 19:46 ` Remco Treffkorn
2002-07-29 20:18 ` Russell King
2002-07-29 20:18 ` Russell King
2002-07-30 2:54 ` 3 Serial issues up for discussion David S. Miller
2002-07-30 2:54 ` David S. Miller
2002-07-30 18:23 ` Remco Treffkorn
2002-07-30 18:47 ` Nicolas Pitre
2002-07-30 18:51 ` Russell King
2002-07-30 18:44 ` Nicolas Pitre
2002-07-29 18:15 ` 3 Serial issues up for discussion (was: Re: Serial core problems on embedded PPC) Matt Porter
2002-07-29 18:15 ` Matt Porter
2002-07-29 17:47 ` [parisc-linux] " Christoph Plattner
2002-07-29 17:47 ` Christoph Plattner
2002-07-29 22:19 ` Matthew Wilcox
2002-07-29 22:19 ` Matthew Wilcox
2002-07-30 14:36 ` Stuart MacDonald
2002-07-30 15:19 ` Matthew Wilcox
2002-07-30 15:43 ` Stuart MacDonald
2002-07-30 15:53 ` Russell King
2002-07-30 15:59 ` Greg KH
2002-07-30 16:06 ` Stuart MacDonald
2002-08-02 1:57 ` Jeff Randall
2002-07-30 2:51 ` 3 Serial issues up for discussion David S. Miller
2002-07-30 2:51 ` David S. Miller
2002-08-02 6:01 ` symbol card with orinoco_cs on mpc823 shaowei dai
2002-08-02 6:23 ` David Gibson
2002-08-02 6:36 ` Matthew Locke
2002-08-02 7:01 ` shaowei dai
[not found] ` <3D4AC468.83BCD667@opensource.se>
2002-08-03 1:30 ` shaowei dai
2002-07-30 1:12 ` David Gibson [this message]
2002-07-30 1:12 ` Serial core problems on embedded PPC David Gibson
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=20020730011203.GL2351@zax \
--to=david@gibson.dropbear.id.au \
--cc=linux-kernel@vger.kernel.org \
--cc=linuxppc-embedded@lists.linuxppc.org \
--cc=rmk@arm.linux.org.uk \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.