aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-pxa/em-x270.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/mach-pxa/em-x270.c')
-rw-r--r--arch/arm/mach-pxa/em-x270.c236
1 files changed, 208 insertions, 28 deletions
diff --git a/arch/arm/mach-pxa/em-x270.c b/arch/arm/mach-pxa/em-x270.c
index bc0f73fbd4ca..63b10d9bb1d3 100644
--- a/arch/arm/mach-pxa/em-x270.c
+++ b/arch/arm/mach-pxa/em-x270.c
@@ -28,6 +28,9 @@
28#include <linux/spi/libertas_spi.h> 28#include <linux/spi/libertas_spi.h>
29#include <linux/power_supply.h> 29#include <linux/power_supply.h>
30#include <linux/apm-emulation.h> 30#include <linux/apm-emulation.h>
31#include <linux/i2c.h>
32#include <linux/i2c/pca953x.h>
33#include <linux/regulator/userspace-consumer.h>
31 34
32#include <media/soc_camera.h> 35#include <media/soc_camera.h>
33 36
@@ -41,7 +44,7 @@
41#include <mach/ohci.h> 44#include <mach/ohci.h>
42#include <mach/mmc.h> 45#include <mach/mmc.h>
43#include <mach/pxa27x_keypad.h> 46#include <mach/pxa27x_keypad.h>
44#include <mach/i2c.h> 47#include <plat/i2c.h>
45#include <mach/camera.h> 48#include <mach/camera.h>
46#include <mach/pxa2xx_spi.h> 49#include <mach/pxa2xx_spi.h>
47 50
@@ -52,23 +55,31 @@
52#define GPIO13_MMC_CD (13) 55#define GPIO13_MMC_CD (13)
53#define GPIO95_MMC_WP (95) 56#define GPIO95_MMC_WP (95)
54#define GPIO56_NAND_RB (56) 57#define GPIO56_NAND_RB (56)
58#define GPIO93_CAM_RESET (93)
59#define GPIO16_USB_HUB_RESET (16)
55 60
56/* eXeda specific GPIOs */ 61/* eXeda specific GPIOs */
57#define GPIO114_MMC_CD (114) 62#define GPIO114_MMC_CD (114)
58#define GPIO20_NAND_RB (20) 63#define GPIO20_NAND_RB (20)
59#define GPIO38_SD_PWEN (38) 64#define GPIO38_SD_PWEN (38)
65#define GPIO37_WLAN_RST (37)
66#define GPIO95_TOUCHPAD_INT (95)
67#define GPIO130_CAM_RESET (130)
68#define GPIO10_USB_HUB_RESET (10)
60 69
61/* common GPIOs */ 70/* common GPIOs */
62#define GPIO11_NAND_CS (11) 71#define GPIO11_NAND_CS (11)
63#define GPIO93_CAM_RESET (93)
64#define GPIO41_ETHIRQ (41) 72#define GPIO41_ETHIRQ (41)
65#define EM_X270_ETHIRQ IRQ_GPIO(GPIO41_ETHIRQ) 73#define EM_X270_ETHIRQ IRQ_GPIO(GPIO41_ETHIRQ)
66#define GPIO115_WLAN_PWEN (115) 74#define GPIO115_WLAN_PWEN (115)
67#define GPIO19_WLAN_STRAP (19) 75#define GPIO19_WLAN_STRAP (19)
76#define GPIO9_USB_VBUS_EN (9)
68 77
69static int mmc_cd; 78static int mmc_cd;
70static int nand_rb; 79static int nand_rb;
71static int dm9000_flags; 80static int dm9000_flags;
81static int cam_reset;
82static int usb_hub_reset;
72 83
73static unsigned long common_pin_config[] = { 84static unsigned long common_pin_config[] = {
74 /* AC'97 */ 85 /* AC'97 */
@@ -180,7 +191,6 @@ static unsigned long common_pin_config[] = {
180 191
181 /* power controls */ 192 /* power controls */
182 GPIO20_GPIO | MFP_LPM_DRIVE_LOW, /* GPRS_PWEN */ 193 GPIO20_GPIO | MFP_LPM_DRIVE_LOW, /* GPRS_PWEN */
183 GPIO93_GPIO | MFP_LPM_DRIVE_LOW, /* Camera reset */
184 GPIO115_GPIO | MFP_LPM_DRIVE_LOW, /* WLAN_PWEN */ 194 GPIO115_GPIO | MFP_LPM_DRIVE_LOW, /* WLAN_PWEN */
185 195
186 /* NAND controls */ 196 /* NAND controls */
@@ -191,14 +201,18 @@ static unsigned long common_pin_config[] = {
191}; 201};
192 202
193static unsigned long em_x270_pin_config[] = { 203static unsigned long em_x270_pin_config[] = {
194 GPIO13_GPIO, /* MMC card detect */ 204 GPIO13_GPIO, /* MMC card detect */
195 GPIO56_GPIO, /* NAND Ready/Busy */ 205 GPIO16_GPIO, /* USB hub reset */
196 GPIO95_GPIO, /* MMC Write protect */ 206 GPIO56_GPIO, /* NAND Ready/Busy */
207 GPIO93_GPIO | MFP_LPM_DRIVE_LOW, /* Camera reset */
208 GPIO95_GPIO, /* MMC Write protect */
197}; 209};
198 210
199static unsigned long exeda_pin_config[] = { 211static unsigned long exeda_pin_config[] = {
212 GPIO10_GPIO, /* USB hub reset */
200 GPIO20_GPIO, /* NAND Ready/Busy */ 213 GPIO20_GPIO, /* NAND Ready/Busy */
201 GPIO38_GPIO | MFP_LPM_DRIVE_LOW, /* SD slot power */ 214 GPIO38_GPIO | MFP_LPM_DRIVE_LOW, /* SD slot power */
215 GPIO95_GPIO, /* touchpad IRQ */
202 GPIO114_GPIO, /* MMC card detect */ 216 GPIO114_GPIO, /* MMC card detect */
203}; 217};
204 218
@@ -464,18 +478,79 @@ static inline void em_x270_init_nor(void) {}
464 478
465/* PXA27x OHCI controller setup */ 479/* PXA27x OHCI controller setup */
466#if defined(CONFIG_USB_OHCI_HCD) || defined(CONFIG_USB_OHCI_HCD_MODULE) 480#if defined(CONFIG_USB_OHCI_HCD) || defined(CONFIG_USB_OHCI_HCD_MODULE)
481static struct regulator *em_x270_usb_ldo;
482
483static int em_x270_usb_hub_init(void)
484{
485 int err;
486
487 em_x270_usb_ldo = regulator_get(NULL, "vcc usb");
488 if (IS_ERR(em_x270_usb_ldo))
489 return PTR_ERR(em_x270_usb_ldo);
490
491 err = gpio_request(GPIO9_USB_VBUS_EN, "vbus en");
492 if (err)
493 goto err_free_usb_ldo;
494
495 err = gpio_request(usb_hub_reset, "hub rst");
496 if (err)
497 goto err_free_vbus_gpio;
498
499 /* USB Hub power-on and reset */
500 gpio_direction_output(usb_hub_reset, 0);
501 regulator_enable(em_x270_usb_ldo);
502 gpio_set_value(usb_hub_reset, 1);
503 gpio_set_value(usb_hub_reset, 0);
504 regulator_disable(em_x270_usb_ldo);
505 regulator_enable(em_x270_usb_ldo);
506 gpio_set_value(usb_hub_reset, 1);
507
508 /* enable VBUS */
509 gpio_direction_output(GPIO9_USB_VBUS_EN, 1);
510
511 return 0;
512
513err_free_vbus_gpio:
514 gpio_free(GPIO9_USB_VBUS_EN);
515err_free_usb_ldo:
516 regulator_put(em_x270_usb_ldo);
517
518 return err;
519}
520
467static int em_x270_ohci_init(struct device *dev) 521static int em_x270_ohci_init(struct device *dev)
468{ 522{
523 int err;
524
525 /* we don't want to entirely disable USB if the HUB init failed */
526 err = em_x270_usb_hub_init();
527 if (err)
528 pr_err("USB Hub initialization failed: %d\n", err);
529
469 /* enable port 2 transiever */ 530 /* enable port 2 transiever */
470 UP2OCR = UP2OCR_HXS | UP2OCR_HXOE; 531 UP2OCR = UP2OCR_HXS | UP2OCR_HXOE;
471 532
472 return 0; 533 return 0;
473} 534}
474 535
536static void em_x270_ohci_exit(struct device *dev)
537{
538 gpio_free(usb_hub_reset);
539 gpio_free(GPIO9_USB_VBUS_EN);
540
541 if (!IS_ERR(em_x270_usb_ldo)) {
542 if (regulator_is_enabled(em_x270_usb_ldo))
543 regulator_disable(em_x270_usb_ldo);
544
545 regulator_put(em_x270_usb_ldo);
546 }
547}
548
475static struct pxaohci_platform_data em_x270_ohci_platform_data = { 549static struct pxaohci_platform_data em_x270_ohci_platform_data = {
476 .port_mode = PMM_PERPORT_MODE, 550 .port_mode = PMM_PERPORT_MODE,
477 .flags = ENABLE_PORT1 | ENABLE_PORT2 | POWER_CONTROL_LOW, 551 .flags = ENABLE_PORT1 | ENABLE_PORT2 | POWER_CONTROL_LOW,
478 .init = em_x270_ohci_init, 552 .init = em_x270_ohci_init,
553 .exit = em_x270_ohci_exit,
479}; 554};
480 555
481static void __init em_x270_init_ohci(void) 556static void __init em_x270_init_ohci(void)
@@ -661,6 +736,7 @@ static struct pxa2xx_spi_chip em_x270_libertas_chip = {
661 .rx_threshold = 1, 736 .rx_threshold = 1,
662 .tx_threshold = 1, 737 .tx_threshold = 1,
663 .timeout = 1000, 738 .timeout = 1000,
739 .gpio_cs = 14,
664}; 740};
665 741
666static unsigned long em_x270_libertas_pin_config[] = { 742static unsigned long em_x270_libertas_pin_config[] = {
@@ -677,33 +753,58 @@ static int em_x270_libertas_setup(struct spi_device *spi)
677 if (err) 753 if (err)
678 return err; 754 return err;
679 755
756 err = gpio_request(GPIO19_WLAN_STRAP, "WLAN STRAP");
757 if (err)
758 goto err_free_pwen;
759
760 if (machine_is_exeda()) {
761 err = gpio_request(GPIO37_WLAN_RST, "WLAN RST");
762 if (err)
763 goto err_free_strap;
764
765 gpio_direction_output(GPIO37_WLAN_RST, 1);
766 msleep(100);
767 }
768
680 gpio_direction_output(GPIO19_WLAN_STRAP, 1); 769 gpio_direction_output(GPIO19_WLAN_STRAP, 1);
681 mdelay(100); 770 msleep(100);
682 771
683 pxa2xx_mfp_config(ARRAY_AND_SIZE(em_x270_libertas_pin_config)); 772 pxa2xx_mfp_config(ARRAY_AND_SIZE(em_x270_libertas_pin_config));
684 773
685 gpio_direction_output(GPIO115_WLAN_PWEN, 0); 774 gpio_direction_output(GPIO115_WLAN_PWEN, 0);
686 mdelay(100); 775 msleep(100);
687 gpio_set_value(GPIO115_WLAN_PWEN, 1); 776 gpio_set_value(GPIO115_WLAN_PWEN, 1);
688 mdelay(100); 777 msleep(100);
689 778
690 spi->bits_per_word = 16; 779 spi->bits_per_word = 16;
691 spi_setup(spi); 780 spi_setup(spi);
692 781
693 return 0; 782 return 0;
783
784err_free_strap:
785 gpio_free(GPIO19_WLAN_STRAP);
786err_free_pwen:
787 gpio_free(GPIO115_WLAN_PWEN);
788
789 return err;
694} 790}
695 791
696static int em_x270_libertas_teardown(struct spi_device *spi) 792static int em_x270_libertas_teardown(struct spi_device *spi)
697{ 793{
698 gpio_set_value(GPIO115_WLAN_PWEN, 0); 794 gpio_set_value(GPIO115_WLAN_PWEN, 0);
699 gpio_free(GPIO115_WLAN_PWEN); 795 gpio_free(GPIO115_WLAN_PWEN);
796 gpio_free(GPIO19_WLAN_STRAP);
797
798 if (machine_is_exeda()) {
799 gpio_set_value(GPIO37_WLAN_RST, 0);
800 gpio_free(GPIO37_WLAN_RST);
801 }
700 802
701 return 0; 803 return 0;
702} 804}
703 805
704struct libertas_spi_platform_data em_x270_libertas_pdata = { 806struct libertas_spi_platform_data em_x270_libertas_pdata = {
705 .use_dummy_writes = 1, 807 .use_dummy_writes = 1,
706 .gpio_cs = 14,
707 .setup = em_x270_libertas_setup, 808 .setup = em_x270_libertas_setup,
708 .teardown = em_x270_libertas_teardown, 809 .teardown = em_x270_libertas_teardown,
709}; 810};
@@ -738,10 +839,14 @@ static void __init em_x270_init_spi(void)
738static inline void em_x270_init_spi(void) {} 839static inline void em_x270_init_spi(void) {}
739#endif 840#endif
740 841
741#if defined(CONFIG_SND_PXA2XX_AC97) || defined(CONFIG_SND_PXA2XX_AC97_MODULE) 842#if defined(CONFIG_SND_PXA2XX_LIB_AC97)
843static pxa2xx_audio_ops_t em_x270_ac97_info = {
844 .reset_gpio = 113,
845};
846
742static void __init em_x270_init_ac97(void) 847static void __init em_x270_init_ac97(void)
743{ 848{
744 pxa_set_ac97_info(NULL); 849 pxa_set_ac97_info(&em_x270_ac97_info);
745} 850}
746#else 851#else
747static inline void em_x270_init_ac97(void) {} 852static inline void em_x270_init_ac97(void) {}
@@ -863,26 +968,26 @@ static int em_x270_sensor_init(struct device *dev)
863{ 968{
864 int ret; 969 int ret;
865 970
866 ret = gpio_request(GPIO93_CAM_RESET, "camera reset"); 971 ret = gpio_request(cam_reset, "camera reset");
867 if (ret) 972 if (ret)
868 return ret; 973 return ret;
869 974
870 gpio_direction_output(GPIO93_CAM_RESET, 0); 975 gpio_direction_output(cam_reset, 0);
871 976
872 em_x270_camera_ldo = regulator_get(NULL, "vcc cam"); 977 em_x270_camera_ldo = regulator_get(NULL, "vcc cam");
873 if (em_x270_camera_ldo == NULL) { 978 if (em_x270_camera_ldo == NULL) {
874 gpio_free(GPIO93_CAM_RESET); 979 gpio_free(cam_reset);
875 return -ENODEV; 980 return -ENODEV;
876 } 981 }
877 982
878 ret = regulator_enable(em_x270_camera_ldo); 983 ret = regulator_enable(em_x270_camera_ldo);
879 if (ret) { 984 if (ret) {
880 regulator_put(em_x270_camera_ldo); 985 regulator_put(em_x270_camera_ldo);
881 gpio_free(GPIO93_CAM_RESET); 986 gpio_free(cam_reset);
882 return ret; 987 return ret;
883 } 988 }
884 989
885 gpio_set_value(GPIO93_CAM_RESET, 1); 990 gpio_set_value(cam_reset, 1);
886 991
887 return 0; 992 return 0;
888} 993}
@@ -902,7 +1007,7 @@ static int em_x270_sensor_power(struct device *dev, int on)
902 if (on == is_on) 1007 if (on == is_on)
903 return 0; 1008 return 0;
904 1009
905 gpio_set_value(GPIO93_CAM_RESET, !on); 1010 gpio_set_value(cam_reset, !on);
906 1011
907 if (on) 1012 if (on)
908 ret = regulator_enable(em_x270_camera_ldo); 1013 ret = regulator_enable(em_x270_camera_ldo);
@@ -912,7 +1017,7 @@ static int em_x270_sensor_power(struct device *dev, int on)
912 if (ret) 1017 if (ret)
913 return ret; 1018 return ret;
914 1019
915 gpio_set_value(GPIO93_CAM_RESET, on); 1020 gpio_set_value(cam_reset, on);
916 1021
917 return 0; 1022 return 0;
918} 1023}
@@ -929,13 +1034,8 @@ static struct i2c_board_info em_x270_i2c_cam_info[] = {
929 }, 1034 },
930}; 1035};
931 1036
932static struct i2c_pxa_platform_data em_x270_i2c_info = {
933 .fast_mode = 1,
934};
935
936static void __init em_x270_init_camera(void) 1037static void __init em_x270_init_camera(void)
937{ 1038{
938 pxa_set_i2c_info(&em_x270_i2c_info);
939 i2c_register_board_info(0, ARRAY_AND_SIZE(em_x270_i2c_cam_info)); 1039 i2c_register_board_info(0, ARRAY_AND_SIZE(em_x270_i2c_cam_info));
940 pxa_set_camera_info(&em_x270_camera_platform_data); 1040 pxa_set_camera_info(&em_x270_camera_platform_data);
941} 1041}
@@ -943,6 +1043,52 @@ static void __init em_x270_init_camera(void)
943static inline void em_x270_init_camera(void) {} 1043static inline void em_x270_init_camera(void) {}
944#endif 1044#endif
945 1045
1046static struct regulator_bulk_data em_x270_gps_consumer_supply = {
1047 .supply = "vcc gps",
1048};
1049
1050static struct regulator_userspace_consumer_data em_x270_gps_consumer_data = {
1051 .name = "vcc gps",
1052 .num_supplies = 1,
1053 .supplies = &em_x270_gps_consumer_supply,
1054};
1055
1056static struct platform_device em_x270_gps_userspace_consumer = {
1057 .name = "reg-userspace-consumer",
1058 .id = 0,
1059 .dev = {
1060 .platform_data = &em_x270_gps_consumer_data,
1061 },
1062};
1063
1064static struct regulator_bulk_data em_x270_gprs_consumer_supply = {
1065 .supply = "vcc gprs",
1066};
1067
1068static struct regulator_userspace_consumer_data em_x270_gprs_consumer_data = {
1069 .name = "vcc gprs",
1070 .num_supplies = 1,
1071 .supplies = &em_x270_gprs_consumer_supply
1072};
1073
1074static struct platform_device em_x270_gprs_userspace_consumer = {
1075 .name = "reg-userspace-consumer",
1076 .id = 1,
1077 .dev = {
1078 .platform_data = &em_x270_gprs_consumer_data,
1079 }
1080};
1081
1082static struct platform_device *em_x270_userspace_consumers[] = {
1083 &em_x270_gps_userspace_consumer,
1084 &em_x270_gprs_userspace_consumer,
1085};
1086
1087static void __init em_x270_userspace_consumers_init(void)
1088{
1089 platform_add_devices(ARRAY_AND_SIZE(em_x270_userspace_consumers));
1090}
1091
946/* DA9030 related initializations */ 1092/* DA9030 related initializations */
947#define REGULATOR_CONSUMER(_name, _dev, _supply) \ 1093#define REGULATOR_CONSUMER(_name, _dev, _supply) \
948 static struct regulator_consumer_supply _name##_consumers[] = { \ 1094 static struct regulator_consumer_supply _name##_consumers[] = { \
@@ -952,11 +1098,11 @@ static inline void em_x270_init_camera(void) {}
952 }, \ 1098 }, \
953 } 1099 }
954 1100
955REGULATOR_CONSUMER(ldo3, NULL, "vcc gps"); 1101REGULATOR_CONSUMER(ldo3, &em_x270_gps_userspace_consumer.dev, "vcc gps");
956REGULATOR_CONSUMER(ldo5, NULL, "vcc cam"); 1102REGULATOR_CONSUMER(ldo5, NULL, "vcc cam");
957REGULATOR_CONSUMER(ldo10, &pxa_device_mci.dev, "vcc sdio"); 1103REGULATOR_CONSUMER(ldo10, &pxa_device_mci.dev, "vcc sdio");
958REGULATOR_CONSUMER(ldo12, NULL, "vcc usb"); 1104REGULATOR_CONSUMER(ldo12, NULL, "vcc usb");
959REGULATOR_CONSUMER(ldo19, NULL, "vcc gprs"); 1105REGULATOR_CONSUMER(ldo19, &em_x270_gprs_userspace_consumer.dev, "vcc gprs");
960 1106
961#define REGULATOR_INIT(_ldo, _min_uV, _max_uV, _ops_mask) \ 1107#define REGULATOR_INIT(_ldo, _min_uV, _max_uV, _ops_mask) \
962 static struct regulator_init_data _ldo##_data = { \ 1108 static struct regulator_init_data _ldo##_data = { \
@@ -967,6 +1113,7 @@ REGULATOR_CONSUMER(ldo19, NULL, "vcc gprs");
967 .enabled = 0, \ 1113 .enabled = 0, \
968 }, \ 1114 }, \
969 .valid_ops_mask = _ops_mask, \ 1115 .valid_ops_mask = _ops_mask, \
1116 .apply_uV = 1, \
970 }, \ 1117 }, \
971 .num_consumer_supplies = ARRAY_SIZE(_ldo##_consumers), \ 1118 .num_consumer_supplies = ARRAY_SIZE(_ldo##_consumers), \
972 .consumer_supplies = _ldo##_consumers, \ 1119 .consumer_supplies = _ldo##_consumers, \
@@ -985,7 +1132,7 @@ struct led_info em_x270_led_info = {
985}; 1132};
986 1133
987struct power_supply_info em_x270_psy_info = { 1134struct power_supply_info em_x270_psy_info = {
988 .name = "LP555597P6H-FPS", 1135 .name = "battery",
989 .technology = POWER_SUPPLY_TECHNOLOGY_LIPO, 1136 .technology = POWER_SUPPLY_TECHNOLOGY_LIPO,
990 .voltage_max_design = 4200000, 1137 .voltage_max_design = 4200000,
991 .voltage_min_design = 3000000, 1138 .voltage_min_design = 3000000,
@@ -1069,6 +1216,29 @@ static void __init em_x270_init_da9030(void)
1069 i2c_register_board_info(1, &em_x270_i2c_pmic_info, 1); 1216 i2c_register_board_info(1, &em_x270_i2c_pmic_info, 1);
1070} 1217}
1071 1218
1219static struct pca953x_platform_data exeda_gpio_ext_pdata = {
1220 .gpio_base = 128,
1221};
1222
1223static struct i2c_board_info exeda_i2c_info[] = {
1224 {
1225 I2C_BOARD_INFO("pca9555", 0x21),
1226 .platform_data = &exeda_gpio_ext_pdata,
1227 },
1228};
1229
1230static struct i2c_pxa_platform_data em_x270_i2c_info = {
1231 .fast_mode = 1,
1232};
1233
1234static void __init em_x270_init_i2c(void)
1235{
1236 pxa_set_i2c_info(&em_x270_i2c_info);
1237
1238 if (machine_is_exeda())
1239 i2c_register_board_info(0, ARRAY_AND_SIZE(exeda_i2c_info));
1240}
1241
1072static void __init em_x270_module_init(void) 1242static void __init em_x270_module_init(void)
1073{ 1243{
1074 pr_info("%s\n", __func__); 1244 pr_info("%s\n", __func__);
@@ -1077,6 +1247,8 @@ static void __init em_x270_module_init(void)
1077 mmc_cd = GPIO13_MMC_CD; 1247 mmc_cd = GPIO13_MMC_CD;
1078 nand_rb = GPIO56_NAND_RB; 1248 nand_rb = GPIO56_NAND_RB;
1079 dm9000_flags = DM9000_PLATF_32BITONLY; 1249 dm9000_flags = DM9000_PLATF_32BITONLY;
1250 cam_reset = GPIO93_CAM_RESET;
1251 usb_hub_reset = GPIO16_USB_HUB_RESET;
1080} 1252}
1081 1253
1082static void __init em_x270_exeda_init(void) 1254static void __init em_x270_exeda_init(void)
@@ -1087,12 +1259,18 @@ static void __init em_x270_exeda_init(void)
1087 mmc_cd = GPIO114_MMC_CD; 1259 mmc_cd = GPIO114_MMC_CD;
1088 nand_rb = GPIO20_NAND_RB; 1260 nand_rb = GPIO20_NAND_RB;
1089 dm9000_flags = DM9000_PLATF_16BITONLY; 1261 dm9000_flags = DM9000_PLATF_16BITONLY;
1262 cam_reset = GPIO130_CAM_RESET;
1263 usb_hub_reset = GPIO10_USB_HUB_RESET;
1090} 1264}
1091 1265
1092static void __init em_x270_init(void) 1266static void __init em_x270_init(void)
1093{ 1267{
1094 pxa2xx_mfp_config(ARRAY_AND_SIZE(common_pin_config)); 1268 pxa2xx_mfp_config(ARRAY_AND_SIZE(common_pin_config));
1095 1269
1270#ifdef CONFIG_PM
1271 pxa27x_set_pwrmode(PWRMODE_DEEPSLEEP);
1272#endif
1273
1096 if (machine_is_em_x270()) 1274 if (machine_is_em_x270())
1097 em_x270_module_init(); 1275 em_x270_module_init();
1098 else if (machine_is_exeda()) 1276 else if (machine_is_exeda())
@@ -1111,8 +1289,10 @@ static void __init em_x270_init(void)
1111 em_x270_init_keypad(); 1289 em_x270_init_keypad();
1112 em_x270_init_gpio_keys(); 1290 em_x270_init_gpio_keys();
1113 em_x270_init_ac97(); 1291 em_x270_init_ac97();
1114 em_x270_init_camera();
1115 em_x270_init_spi(); 1292 em_x270_init_spi();
1293 em_x270_init_i2c();
1294 em_x270_init_camera();
1295 em_x270_userspace_consumers_init();
1116} 1296}
1117 1297
1118MACHINE_START(EM_X270, "Compulab EM-X270") 1298MACHINE_START(EM_X270, "Compulab EM-X270")