forked from analogdevicesinc/linux
-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[PATCH] ppc32: Add support for MPC8245 8250 serial ports on Sandpoint
Added platform device initialization for the two 8250 style UARTs that exist on the MPC8245. Additionally, updated the Sandpoint code to enable one of these UARTs if an MPC8245 is connected to it. Signed-off-by: Matt McClintock <[email protected]> Signed-off-by: Kumar Gala <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
- Loading branch information
Kumar Gala
authored and
Linus Torvalds
committed
Jun 22, 2005
1 parent
1e5aa8c
commit 682afbb
Showing
2 changed files
with
40 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -81,6 +81,7 @@ | |
#include <linux/serial.h> | ||
#include <linux/tty.h> /* for linux/serial_core.h */ | ||
#include <linux/serial_core.h> | ||
#include <linux/serial_8250.h> | ||
|
||
#include <asm/system.h> | ||
#include <asm/pgtable.h> | ||
|
@@ -99,6 +100,7 @@ | |
#include <asm/mpc10x.h> | ||
#include <asm/pci-bridge.h> | ||
#include <asm/kgdb.h> | ||
#include <asm/ppc_sys.h> | ||
|
||
#include "sandpoint.h" | ||
|
||
|
@@ -305,6 +307,24 @@ sandpoint_setup_arch(void) | |
/* Lookup PCI host bridges */ | ||
sandpoint_find_bridges(); | ||
|
||
if (strncmp (cur_ppc_sys_spec->ppc_sys_name, "8245", 4) == 0) | ||
{ | ||
bd_t *bp = (bd_t *)__res; | ||
struct plat_serial8250_port *pdata; | ||
pdata = (struct plat_serial8250_port *) ppc_sys_get_pdata(MPC10X_DUART); | ||
|
||
if (pdata) | ||
{ | ||
pdata[0].uartclk = bp->bi_busfreq; | ||
pdata[0].membase = ioremap(pdata[0].mapbase, 0x100); | ||
|
||
/* this disables the 2nd serial port on the DUART | ||
* since the sandpoint does not have it connected */ | ||
pdata[1].uartclk = 0; | ||
pdata[1].irq = 0; | ||
pdata[1].mapbase = 0; | ||
} | ||
|
||
printk(KERN_INFO "Motorola SPS Sandpoint Test Platform\n"); | ||
printk(KERN_INFO "Port by MontaVista Software, Inc. ([email protected])\n"); | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters