aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-pxa/devices.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/mach-pxa/devices.c')
-rw-r--r--arch/arm/mach-pxa/devices.c30
1 files changed, 27 insertions, 3 deletions
diff --git a/arch/arm/mach-pxa/devices.c b/arch/arm/mach-pxa/devices.c
index 46fabe1cca11..3395463bb5a6 100644
--- a/arch/arm/mach-pxa/devices.c
+++ b/arch/arm/mach-pxa/devices.c
@@ -4,17 +4,18 @@
4#include <linux/platform_device.h> 4#include <linux/platform_device.h>
5#include <linux/dma-mapping.h> 5#include <linux/dma-mapping.h>
6 6
7#include <mach/hardware.h>
7#include <mach/udc.h> 8#include <mach/udc.h>
8#include <mach/pxafb.h> 9#include <mach/pxafb.h>
9#include <mach/mmc.h> 10#include <mach/mmc.h>
10#include <mach/irda.h> 11#include <mach/irda.h>
11#include <plat/i2c.h>
12#include <mach/ohci.h> 12#include <mach/ohci.h>
13#include <mach/pxa27x_keypad.h> 13#include <mach/pxa27x_keypad.h>
14#include <mach/pxa2xx_spi.h> 14#include <mach/pxa2xx_spi.h>
15#include <mach/camera.h> 15#include <mach/camera.h>
16#include <mach/audio.h> 16#include <mach/audio.h>
17#include <mach/pxa3xx_nand.h> 17#include <plat/i2c.h>
18#include <plat/pxa3xx_nand.h>
18 19
19#include "devices.h" 20#include "devices.h"
20#include "generic.h" 21#include "generic.h"
@@ -167,13 +168,18 @@ static struct resource pxa_resource_ffuart[] = {
167 } 168 }
168}; 169};
169 170
170struct platform_device pxa_device_ffuart= { 171struct platform_device pxa_device_ffuart = {
171 .name = "pxa2xx-uart", 172 .name = "pxa2xx-uart",
172 .id = 0, 173 .id = 0,
173 .resource = pxa_resource_ffuart, 174 .resource = pxa_resource_ffuart,
174 .num_resources = ARRAY_SIZE(pxa_resource_ffuart), 175 .num_resources = ARRAY_SIZE(pxa_resource_ffuart),
175}; 176};
176 177
178void __init pxa_set_ffuart_info(void *info)
179{
180 pxa_register_device(&pxa_device_ffuart, info);
181}
182
177static struct resource pxa_resource_btuart[] = { 183static struct resource pxa_resource_btuart[] = {
178 { 184 {
179 .start = 0x40200000, 185 .start = 0x40200000,
@@ -193,6 +199,11 @@ struct platform_device pxa_device_btuart = {
193 .num_resources = ARRAY_SIZE(pxa_resource_btuart), 199 .num_resources = ARRAY_SIZE(pxa_resource_btuart),
194}; 200};
195 201
202void __init pxa_set_btuart_info(void *info)
203{
204 pxa_register_device(&pxa_device_btuart, info);
205}
206
196static struct resource pxa_resource_stuart[] = { 207static struct resource pxa_resource_stuart[] = {
197 { 208 {
198 .start = 0x40700000, 209 .start = 0x40700000,
@@ -212,6 +223,11 @@ struct platform_device pxa_device_stuart = {
212 .num_resources = ARRAY_SIZE(pxa_resource_stuart), 223 .num_resources = ARRAY_SIZE(pxa_resource_stuart),
213}; 224};
214 225
226void __init pxa_set_stuart_info(void *info)
227{
228 pxa_register_device(&pxa_device_stuart, info);
229}
230
215static struct resource pxa_resource_hwuart[] = { 231static struct resource pxa_resource_hwuart[] = {
216 { 232 {
217 .start = 0x41600000, 233 .start = 0x41600000,
@@ -231,6 +247,14 @@ struct platform_device pxa_device_hwuart = {
231 .num_resources = ARRAY_SIZE(pxa_resource_hwuart), 247 .num_resources = ARRAY_SIZE(pxa_resource_hwuart),
232}; 248};
233 249
250void __init pxa_set_hwuart_info(void *info)
251{
252 if (cpu_is_pxa255())
253 pxa_register_device(&pxa_device_hwuart, info);
254 else
255 pr_info("UART: Ignoring attempt to register HWUART on non-PXA255 hardware");
256}
257
234static struct resource pxai2c_resources[] = { 258static struct resource pxai2c_resources[] = {
235 { 259 {
236 .start = 0x40301680, 260 .start = 0x40301680,