1
/* linux/arch/arm/mach-vt8500/devices.h
3
* Copyright (C) 2010 Alexey Charkov <alchark@gmail.com>
5
* This software is licensed under the terms of the GNU General Public
6
* License version 2, as published by the Free Software Foundation, and
7
* may be copied, distributed, and modified under those terms.
9
* This program is distributed in the hope that it will be useful,
10
* but WITHOUT ANY WARRANTY; without even the implied warranty of
11
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12
* GNU General Public License for more details.
16
#ifndef __ARCH_ARM_MACH_VT8500_DEVICES_H
17
#define __ARCH_ARM_MACH_VT8500_DEVICES_H
19
#include <linux/platform_device.h>
20
#include <asm/mach/map.h>
22
void __init vt8500_init_irq(void);
23
void __init wm8505_init_irq(void);
24
void __init vt8500_map_io(void);
25
void __init wm8505_map_io(void);
26
void __init vt8500_reserve_mem(void);
27
void __init wm8505_reserve_mem(void);
28
void __init vt8500_gpio_init(void);
29
void __init vt8500_set_resources(void);
30
void __init wm8505_set_resources(void);
32
extern unsigned long wmt_ic_base __initdata;
33
extern unsigned long wmt_sic_base __initdata;
34
extern unsigned long wmt_gpio_base __initdata;
35
extern unsigned long wmt_pmc_base __initdata;
37
extern int wmt_nr_irqs __initdata;
38
extern int wmt_timer_irq __initdata;
39
extern int wmt_gpio_ext_irq[8] __initdata;
41
extern struct map_desc wmt_io_desc[2] __initdata;
43
static inline struct resource wmt_mmio_res(u32 start, u32 size)
45
struct resource tmp = {
46
.flags = IORESOURCE_MEM,
48
.end = start + size - 1,
54
static inline struct resource wmt_irq_res(int irq)
56
struct resource tmp = {
57
.flags = IORESOURCE_IRQ,
65
static inline void wmt_res_add(struct platform_device *pdev,
66
const struct resource *res, unsigned int num)
68
if (unlikely(platform_device_add_resources(pdev, res, num)))
69
pr_err("Failed to assign resources\n");
72
extern struct sys_timer vt8500_timer;
74
extern struct platform_device vt8500_device_uart0;
75
extern struct platform_device vt8500_device_uart1;
76
extern struct platform_device vt8500_device_uart2;
77
extern struct platform_device vt8500_device_uart3;
78
extern struct platform_device vt8500_device_uart4;
79
extern struct platform_device vt8500_device_uart5;
81
extern struct platform_device vt8500_device_lcdc;
82
extern struct platform_device vt8500_device_wm8505_fb;
83
extern struct platform_device vt8500_device_ehci;
84
extern struct platform_device vt8500_device_ge_rops;
85
extern struct platform_device vt8500_device_pwm;
86
extern struct platform_device vt8500_device_pwmbl;
87
extern struct platform_device vt8500_device_rtc;