Commit | Line | Data |
---|---|---|
e7736d47 | 1 | /* |
a09e64fb | 2 | * arch/arm/mach-ep93xx/include/mach/platform.h |
e7736d47 LB |
3 | */ |
4 | ||
5 | #ifndef __ASSEMBLY__ | |
6 | ||
6531a991 | 7 | struct i2c_gpio_platform_data; |
ef449e6d | 8 | struct i2c_board_info; |
4fec9978 | 9 | struct spi_board_info; |
ef12379f | 10 | struct platform_device; |
c6012189 | 11 | struct ep93xxfb_mach_info; |
12f56c68 | 12 | struct ep93xx_keypad_platform_data; |
4fec9978 | 13 | struct ep93xx_spi_info; |
ef449e6d | 14 | |
1d22e05d LB |
15 | struct ep93xx_eth_data |
16 | { | |
17 | unsigned char dev_addr[6]; | |
18 | unsigned char phy_id; | |
19 | }; | |
20 | ||
a0a08fdc HS |
21 | void ep93xx_map_io(void); |
22 | void ep93xx_init_irq(void); | |
02239f0a HS |
23 | |
24 | /* EP93xx System Controller software locked register write */ | |
fbeeea53 | 25 | void ep93xx_syscon_swlocked_write(unsigned int val, void __iomem *reg); |
02239f0a HS |
26 | void ep93xx_devcfg_set_clear(unsigned int set_bits, unsigned int clear_bits); |
27 | ||
28 | static inline void ep93xx_devcfg_set_bits(unsigned int bits) | |
29 | { | |
30 | ep93xx_devcfg_set_clear(bits, 0x00); | |
31 | } | |
32 | ||
33 | static inline void ep93xx_devcfg_clear_bits(unsigned int bits) | |
34 | { | |
35 | ep93xx_devcfg_set_clear(0x00, bits); | |
36 | } | |
37 | ||
99e6a23a MW |
38 | #define EP93XX_CHIP_REV_D0 3 |
39 | #define EP93XX_CHIP_REV_D1 4 | |
40 | #define EP93XX_CHIP_REV_E0 5 | |
41 | #define EP93XX_CHIP_REV_E1 6 | |
42 | #define EP93XX_CHIP_REV_E2 7 | |
43 | ||
44 | unsigned int ep93xx_chip_revision(void); | |
45 | ||
a0a08fdc | 46 | void ep93xx_register_eth(struct ep93xx_eth_data *data, int copy_addr); |
6531a991 HS |
47 | void ep93xx_register_i2c(struct i2c_gpio_platform_data *data, |
48 | struct i2c_board_info *devices, int num); | |
4fec9978 MW |
49 | void ep93xx_register_spi(struct ep93xx_spi_info *info, |
50 | struct spi_board_info *devices, int num); | |
c6012189 | 51 | void ep93xx_register_fb(struct ep93xxfb_mach_info *data); |
ef12379f HS |
52 | void ep93xx_register_pwm(int pwm0, int pwm1); |
53 | int ep93xx_pwm_acquire_gpio(struct platform_device *pdev); | |
54 | void ep93xx_pwm_release_gpio(struct platform_device *pdev); | |
12f56c68 HS |
55 | void ep93xx_register_keypad(struct ep93xx_keypad_platform_data *data); |
56 | int ep93xx_keypad_acquire_gpio(struct platform_device *pdev); | |
57 | void ep93xx_keypad_release_gpio(struct platform_device *pdev); | |
02239f0a | 58 | |
a0a08fdc HS |
59 | void ep93xx_init_devices(void); |
60 | extern struct sys_timer ep93xx_timer; | |
e7736d47 LB |
61 | |
62 | #endif |