diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2009-09-30 16:46:56 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2009-09-30 16:46:56 -0400 |
commit | e399835c349b7d8339775a004a86a492a444e230 (patch) | |
tree | 6e07f8d53e58a6442bf850097179d0202db4766c /arch/mips/bcm63xx/dev-uart.c | |
parent | 9abf47f11b38f5ecf411b9a44437cad5016631ad (diff) | |
parent | da3a7a2b9f9776f2d44ed9a4b40eabeb17c6e886 (diff) |
Merge branch 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-linus
* 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-linus:
MIPS: Avoid spurious make includecheck message
MIPS: VPE: Get rid of BKL.
MIPS: VPE: Fix build after the credential changes a while ago.
MIPS: Excite: Get rid of BKL.
MIPS: Sibyte: Get rid of BKL.
MIPS: BCM63xx: Add PCMCIA & Cardbus support.
MIPS: MSP71xx: request_irq() failure ignored in msp_pcibios_config_access()
MIPS: Decrease size of au1xxx_dbdma_pm_regs[][]
MIPS: SMP: Inline arch_send_call_function_{single_ipi,ipi_mask}
MIPS: SMP: Fix build.
MIPS: MIPSxx SC: Avoid destructive invalidation on partial L2 cachelines.
MIPS: Sibyte: Fix compilation error.
MIPS: BCM1480: Re-apply patch lost due to bad resolution of merge conflict.
MIPS: BCM63xx: Add serial driver for bcm63xx integrated UART.
MIPS: Loongson2: Fix typo "enalbe" -> "enable"
MIPS: SMTC: Remove duplicate structure field initialization
MIPS: Remove duplicated #include
MIPS: BCM63xx: Remove duplicated #include
Diffstat (limited to 'arch/mips/bcm63xx/dev-uart.c')
-rw-r--r-- | arch/mips/bcm63xx/dev-uart.c | 41 |
1 files changed, 41 insertions, 0 deletions
diff --git a/arch/mips/bcm63xx/dev-uart.c b/arch/mips/bcm63xx/dev-uart.c new file mode 100644 index 000000000000..5f3d89c4a988 --- /dev/null +++ b/arch/mips/bcm63xx/dev-uart.c | |||
@@ -0,0 +1,41 @@ | |||
1 | /* | ||
2 | * This file is subject to the terms and conditions of the GNU General Public | ||
3 | * License. See the file "COPYING" in the main directory of this archive | ||
4 | * for more details. | ||
5 | * | ||
6 | * Copyright (C) 2008 Maxime Bizon <mbizon@freebox.fr> | ||
7 | */ | ||
8 | |||
9 | #include <linux/init.h> | ||
10 | #include <linux/kernel.h> | ||
11 | #include <linux/platform_device.h> | ||
12 | #include <bcm63xx_cpu.h> | ||
13 | #include <bcm63xx_dev_uart.h> | ||
14 | |||
15 | static struct resource uart_resources[] = { | ||
16 | { | ||
17 | .start = -1, /* filled at runtime */ | ||
18 | .end = -1, /* filled at runtime */ | ||
19 | .flags = IORESOURCE_MEM, | ||
20 | }, | ||
21 | { | ||
22 | .start = -1, /* filled at runtime */ | ||
23 | .flags = IORESOURCE_IRQ, | ||
24 | }, | ||
25 | }; | ||
26 | |||
27 | static struct platform_device bcm63xx_uart_device = { | ||
28 | .name = "bcm63xx_uart", | ||
29 | .id = 0, | ||
30 | .num_resources = ARRAY_SIZE(uart_resources), | ||
31 | .resource = uart_resources, | ||
32 | }; | ||
33 | |||
34 | int __init bcm63xx_uart_register(void) | ||
35 | { | ||
36 | uart_resources[0].start = bcm63xx_regset_address(RSET_UART0); | ||
37 | uart_resources[0].end = uart_resources[0].start; | ||
38 | uart_resources[0].end += RSET_UART_SIZE - 1; | ||
39 | uart_resources[1].start = bcm63xx_get_irq_number(IRQ_UART0); | ||
40 | return platform_device_register(&bcm63xx_uart_device); | ||
41 | } | ||