linux-mips
[Top] [All Lists]

Re: Bitrotting serial drivers

To: linux-mips@linux-mips.org
Subject: Re: Bitrotting serial drivers
From: Michael Stickel <michael.stickel@4g-systems.biz>
Date: Mon, 21 Mar 2005 13:12:08 +0100
In-reply-to: <423E91B3.4000302@embeddedalley.com>
Original-recipient: rfc822;linux-mips@linux-mips.org
References: <20050319172101.C23907@flint.arm.linux.org.uk> <423E7B9D.3040908@cubic.org> <423E91B3.4000302@embeddedalley.com>
Sender: linux-mips-bounce@linux-mips.org
User-agent: KMail/1.7
On Monday 21 March 2005 10:19, Pete Popov wrote:
> There were a bunch of differences including how you program the baud rate,

You mentioned the baudrate. There is one thing that had happend to me.
On the au1x00 the baud_base  is 0 by default. In the serial driver there is a 
division by baud_base, that ends up in a an exception. How could we handle 
that. For the moment I set it to a default before it is used:

if (baud_base == 0L)
  baud_base = 115200;

Which is also a hack. How can we get the correct baud_base for a pcmcia based 
serial-port.

> the addresses of the registers, and if I remember correctly,
> additional/different registers. To cleanly get the au1x support into the
> 8250 driver, some additional abstraction was necessary and I just never had
> the time to do it.

We should have a resource for the register access and the serial driver should 
not care about what it is (memory,io,au1x00,multiport,...). It should just 
use the resource to access the chip. The resource can be a "virtual resource" 
like the multiport cards that have an index register.

The serial port needs a second resource that is the interrupt.

Michael

<Prev in Thread] Current Thread [Next in Thread>