blob: 56210d5e154c628b3ba58d6bcd007f06b03bae92 [file] [log] [blame]
Russell Kinga09e64f2008-08-05 16:14:15 +01001/* arch/arm/mach-msm/include/mach/board.h
2 *
3 * Copyright (C) 2007 Google, Inc.
Nagamalleswararao Ganji70fac1e2011-12-29 19:06:37 -08004 * Copyright (c) 2008-2012, Code Aurora Forum. All rights reserved.
Russell Kinga09e64f2008-08-05 16:14:15 +01005 * Author: Brian Swetland <swetland@google.com>
6 *
7 * This software is licensed under the terms of the GNU General Public
8 * License version 2, as published by the Free Software Foundation, and
9 * may be copied, distributed, and modified under those terms.
10 *
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
15 *
16 */
17
18#ifndef __ASM_ARCH_MSM_BOARD_H
19#define __ASM_ARCH_MSM_BOARD_H
20
21#include <linux/types.h>
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -070022#include <linux/input.h>
23#include <linux/usb.h>
24#include <linux/leds-pmic8058.h>
25#include <linux/clkdev.h>
Sathish Ambleyc58afc22011-10-09 21:55:39 -070026#include <linux/of_platform.h>
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -070027#include <linux/msm_ssbi.h>
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -070028#include <mach/msm_bus.h>
Russell Kinga09e64f2008-08-05 16:14:15 +010029
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -070030struct msm_camera_io_ext {
31 uint32_t mdcphy;
32 uint32_t mdcsz;
33 uint32_t appphy;
34 uint32_t appsz;
35 uint32_t camifpadphy;
36 uint32_t camifpadsz;
37 uint32_t csiphy;
38 uint32_t csisz;
39 uint32_t csiirq;
40 uint32_t csiphyphy;
41 uint32_t csiphysz;
42 uint32_t csiphyirq;
43 uint32_t ispifphy;
44 uint32_t ispifsz;
45 uint32_t ispifirq;
46};
47
48struct msm_camera_io_clk {
49 uint32_t mclk_clk_rate;
50 uint32_t vfe_clk_rate;
51};
52
Nishant Pandit474f2252011-07-23 23:17:56 +053053struct msm_cam_expander_info {
54 struct i2c_board_info const *board_info;
55 int bus_id;
56};
57
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -070058struct msm_camera_device_platform_data {
59 int (*camera_gpio_on) (void);
60 void (*camera_gpio_off)(void);
61 struct msm_camera_io_ext ioext;
62 struct msm_camera_io_clk ioclk;
63 uint8_t csid_core;
Suresh Vankadara8df2c752012-01-18 00:18:03 +053064 uint8_t is_csiphy;
65 uint8_t is_csic;
66 uint8_t is_csid;
67 uint8_t is_ispif;
68 uint8_t is_vpe;
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -070069 struct msm_bus_scale_pdata *cam_bus_scale_table;
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -070070};
71enum msm_camera_csi_data_format {
72 CSI_8BIT,
73 CSI_10BIT,
74 CSI_12BIT,
75};
76struct msm_camera_csi_params {
77 enum msm_camera_csi_data_format data_format;
78 uint8_t lane_cnt;
79 uint8_t lane_assign;
80 uint8_t settle_cnt;
81 uint8_t dpcm_scheme;
82};
83
84#ifdef CONFIG_SENSORS_MT9T013
85struct msm_camera_legacy_device_platform_data {
86 int sensor_reset;
87 int sensor_pwd;
88 int vcm_pwd;
89 void (*config_gpio_on) (void);
90 void (*config_gpio_off)(void);
91};
92#endif
93
94#define MSM_CAMERA_FLASH_NONE 0
95#define MSM_CAMERA_FLASH_LED 1
96
97#define MSM_CAMERA_FLASH_SRC_PMIC (0x00000001<<0)
98#define MSM_CAMERA_FLASH_SRC_PWM (0x00000001<<1)
99#define MSM_CAMERA_FLASH_SRC_CURRENT_DRIVER (0x00000001<<2)
Nishant Pandit474f2252011-07-23 23:17:56 +0530100#define MSM_CAMERA_FLASH_SRC_EXT (0x00000001<<3)
Taniya Das7a22cdd2011-09-08 14:57:00 +0530101#define MSM_CAMERA_FLASH_SRC_LED (0x00000001<<3)
Raju P.L.S.S.S.Nbf3faff2012-04-05 14:33:36 +0530102#define MSM_CAMERA_FLASH_SRC_LED1 (0x00000001<<4)
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700103
104struct msm_camera_sensor_flash_pmic {
105 uint8_t num_of_src;
106 uint32_t low_current;
107 uint32_t high_current;
108 enum pmic8058_leds led_src_1;
109 enum pmic8058_leds led_src_2;
110 int (*pmic_set_current)(enum pmic8058_leds id, unsigned mA);
111};
112
113struct msm_camera_sensor_flash_pwm {
114 uint32_t freq;
115 uint32_t max_load;
116 uint32_t low_load;
117 uint32_t high_load;
118 uint32_t channel;
119};
120
121struct pmic8058_leds_platform_data;
122struct msm_camera_sensor_flash_current_driver {
123 uint32_t low_current;
124 uint32_t high_current;
125 const struct pmic8058_leds_platform_data *driver_channel;
Nishant Pandit474f2252011-07-23 23:17:56 +0530126};
127
128struct msm_camera_sensor_flash_external {
129 uint32_t led_en;
130 uint32_t led_flash_en;
131 struct msm_cam_expander_info *expander_info;
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700132};
133
Taniya Das7a22cdd2011-09-08 14:57:00 +0530134struct msm_camera_sensor_flash_led {
135 const char *led_name;
136 const int led_name_len;
137};
138
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700139struct msm_camera_sensor_flash_src {
140 int flash_sr_type;
141
142 union {
143 struct msm_camera_sensor_flash_pmic pmic_src;
144 struct msm_camera_sensor_flash_pwm pwm_src;
145 struct msm_camera_sensor_flash_current_driver
146 current_driver_src;
Nishant Pandit474f2252011-07-23 23:17:56 +0530147 struct msm_camera_sensor_flash_external
148 ext_driver_src;
Taniya Das7a22cdd2011-09-08 14:57:00 +0530149 struct msm_camera_sensor_flash_led led_src;
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700150 } _fsrc;
151};
152
153struct msm_camera_sensor_flash_data {
154 int flash_type;
155 struct msm_camera_sensor_flash_src *flash_src;
156};
157
158struct msm_camera_sensor_strobe_flash_data {
159 uint8_t flash_trigger;
160 uint8_t flash_charge; /* pin for charge */
161 uint8_t flash_charge_done;
162 uint32_t flash_recharge_duration;
163 uint32_t irq;
164 spinlock_t spin_lock;
165 spinlock_t timer_lock;
166 int state;
167};
168
Nishant Pandit24153d82011-08-27 16:05:13 +0530169enum msm_camera_type {
170 BACK_CAMERA_2D,
171 FRONT_CAMERA_2D,
172 BACK_CAMERA_3D,
173 BACK_CAMERA_INT_3D,
174};
175
Raju P.L.S.S.S.N3f4b3022012-03-29 10:09:01 +0530176enum msm_sensor_type {
177 BAYER_SENSOR,
178 YUV_SENSOR,
179};
180
Kevin Chaneb6b6072012-01-17 11:54:54 -0800181enum camera_vreg_type {
182 REG_LDO,
183 REG_VS,
Kevin Chan8b0d2322011-09-10 21:06:31 -0700184};
185
Kevin Chaneb6b6072012-01-17 11:54:54 -0800186struct camera_vreg_t {
187 char *reg_name;
188 enum camera_vreg_type type;
189 int min_voltage;
190 int max_voltage;
191 int op_mode;
192};
193
194struct msm_gpio_set_tbl {
195 unsigned gpio;
196 unsigned long flags;
197 uint32_t delay;
Nishant Pandit24153d82011-08-27 16:05:13 +0530198};
199
Hody Hung9ba65cf2012-01-17 17:34:51 -0800200struct msm_camera_csi_lane_params {
201 uint8_t csi_lane_assign;
202 uint8_t csi_lane_mask;
203};
204
Nishant Pandit24153d82011-08-27 16:05:13 +0530205struct msm_camera_gpio_conf {
206 void *cam_gpiomux_conf_tbl;
207 uint8_t cam_gpiomux_conf_tbl_size;
Kevin Chaneb6b6072012-01-17 11:54:54 -0800208 struct gpio *cam_gpio_common_tbl;
209 uint8_t cam_gpio_common_tbl_size;
210 struct gpio *cam_gpio_req_tbl;
211 uint8_t cam_gpio_req_tbl_size;
212 struct msm_gpio_set_tbl *cam_gpio_set_tbl;
213 uint8_t cam_gpio_set_tbl_size;
Sandeep Kodimelac6f78672012-03-07 10:44:04 +0530214 uint32_t gpio_no_mux;
215 uint32_t *camera_off_table;
216 uint8_t camera_off_table_size;
217 uint32_t *camera_on_table;
218 uint8_t camera_on_table_size;
Kevin Chaneb6b6072012-01-17 11:54:54 -0800219};
220
Kevin Chanbb8ef862012-02-14 13:03:04 -0800221enum msm_camera_i2c_mux_mode {
222 MODE_R,
223 MODE_L,
224 MODE_DUAL
225};
226
227struct msm_camera_i2c_conf {
228 uint8_t use_i2c_mux;
229 struct platform_device *mux_dev;
230 enum msm_camera_i2c_mux_mode i2c_mux_mode;
231};
232
Kevin Chaneb6b6072012-01-17 11:54:54 -0800233struct msm_camera_sensor_platform_info {
234 int mount_angle;
235 int sensor_reset;
236 struct camera_vreg_t *cam_vreg;
237 int num_vreg;
238 int32_t (*ext_power_ctrl) (int enable);
239 struct msm_camera_gpio_conf *gpio_conf;
Kevin Chanbb8ef862012-02-14 13:03:04 -0800240 struct msm_camera_i2c_conf *i2c_conf;
Hody Hung9ba65cf2012-01-17 17:34:51 -0800241 struct msm_camera_csi_lane_params *csi_lane_params;
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700242};
243
Rajakumar Govindaram6627b362012-01-29 19:00:30 -0800244enum msm_camera_actuator_name {
245 MSM_ACTUATOR_MAIN_CAM_0,
246 MSM_ACTUATOR_MAIN_CAM_1,
247 MSM_ACTUATOR_MAIN_CAM_2,
248 MSM_ACTUATOR_MAIN_CAM_3,
249 MSM_ACTUATOR_MAIN_CAM_4,
250 MSM_ACTUATOR_MAIN_CAM_5,
251 MSM_ACTUATOR_WEB_CAM_0,
252 MSM_ACTUATOR_WEB_CAM_1,
253 MSM_ACTUATOR_WEB_CAM_2,
254};
255
Sreesudhan Ramakrish Ramkumara4b5f302011-09-12 16:23:22 -0700256struct msm_actuator_info {
257 struct i2c_board_info const *board_info;
Rajakumar Govindaram6627b362012-01-29 19:00:30 -0800258 enum msm_camera_actuator_name cam_name;
Sreesudhan Ramakrish Ramkumara4b5f302011-09-12 16:23:22 -0700259 int bus_id;
260 int vcm_pwd;
261 int vcm_enable;
262};
263
Jeyaprakash Soundrapandian734476b2012-05-03 20:08:15 -0700264struct msm_eeprom_info {
265 struct i2c_board_info const *board_info;
266 int bus_id;
267};
268
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700269struct msm_camera_sensor_info {
270 const char *sensor_name;
271 int sensor_reset_enable;
272 int sensor_reset;
273 int sensor_pwd;
274 int vcm_pwd;
275 int vcm_enable;
276 int mclk;
277 int flash_type;
278 struct msm_camera_sensor_platform_info *sensor_platform_info;
279 struct msm_camera_device_platform_data *pdata;
280 struct resource *resource;
281 uint8_t num_resources;
282 struct msm_camera_sensor_flash_data *flash_data;
283 int csi_if;
284 struct msm_camera_csi_params csi_params;
285 struct msm_camera_sensor_strobe_flash_data *strobe_flash_data;
286 char *eeprom_data;
Nishant Pandit24153d82011-08-27 16:05:13 +0530287 enum msm_camera_type camera_type;
Raju P.L.S.S.S.N3f4b3022012-03-29 10:09:01 +0530288 enum msm_sensor_type sensor_type;
Sreesudhan Ramakrish Ramkumara4b5f302011-09-12 16:23:22 -0700289 struct msm_actuator_info *actuator_info;
Su Liuaca04702012-02-14 02:27:32 +0530290 int pmic_gpio_enable;
Raju P.L.S.S.S.Nce5c5c22012-05-17 23:10:08 +0530291 int (*sensor_lcd_gpio_onoff)(int on);
Jeyaprakash Soundrapandian734476b2012-05-03 20:08:15 -0700292 struct msm_eeprom_info *eeprom_info;
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700293};
294
Kevin Chan09f4e662011-12-16 08:17:02 -0800295struct msm_camera_board_info {
296 struct i2c_board_info *board_info;
297 uint8_t num_i2c_board_info;
298};
299
Stepan Moskovchenkob3e63862011-10-20 18:36:55 -0700300int msm_get_cam_resources(struct msm_camera_sensor_info *);
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700301
Stephen Boydbd323442011-02-23 09:37:42 -0800302struct clk_lookup;
Daniel Walker5e96da52010-05-12 13:43:28 -0700303
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700304struct snd_endpoint {
305 int id;
306 const char *name;
307};
Steve Mucklea55df6e2010-01-07 12:43:24 -0800308
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700309struct msm_snd_endpoints {
310 struct snd_endpoint *endpoints;
311 unsigned num;
312};
313
314#define MSM_MAX_DEC_CNT 14
315/* 7k target ADSP information */
316/* Bit 23:0, for codec identification like mp3, wav etc *
317 * Bit 27:24, for mode identification like tunnel, non tunnel*
318 * bit 31:28, for operation support like DM, DMA */
319enum msm_adspdec_concurrency {
320 MSM_ADSP_CODEC_WAV = 0,
321 MSM_ADSP_CODEC_ADPCM = 1,
322 MSM_ADSP_CODEC_MP3 = 2,
323 MSM_ADSP_CODEC_REALAUDIO = 3,
324 MSM_ADSP_CODEC_WMA = 4,
325 MSM_ADSP_CODEC_AAC = 5,
326 MSM_ADSP_CODEC_RESERVED = 6,
327 MSM_ADSP_CODEC_MIDI = 7,
328 MSM_ADSP_CODEC_YADPCM = 8,
329 MSM_ADSP_CODEC_QCELP = 9,
330 MSM_ADSP_CODEC_AMRNB = 10,
331 MSM_ADSP_CODEC_AMRWB = 11,
332 MSM_ADSP_CODEC_EVRC = 12,
333 MSM_ADSP_CODEC_WMAPRO = 13,
334 MSM_ADSP_MODE_TUNNEL = 24,
335 MSM_ADSP_MODE_NONTUNNEL = 25,
336 MSM_ADSP_MODE_LP = 26,
337 MSM_ADSP_OP_DMA = 28,
338 MSM_ADSP_OP_DM = 29,
339};
340
341struct msm_adspdec_info {
342 const char *module_name;
343 unsigned module_queueid;
344 int module_decid; /* objid */
345 unsigned nr_codec_support;
346};
347
348/* Carries information about number codec
349 * supported if same codec or different codecs
350 */
351struct dec_instance_table {
352 uint8_t max_instances_same_dec;
353 uint8_t max_instances_diff_dec;
354};
355
356struct msm_adspdec_database {
357 unsigned num_dec;
358 unsigned num_concurrency_support;
359 unsigned int *dec_concurrency_table; /* Bit masked entry to *
360 * represents codec, mode etc */
361 struct msm_adspdec_info *dec_info_list;
362 struct dec_instance_table *dec_instance_list;
363};
364
365enum msm_mdp_hw_revision {
366 MDP_REV_20 = 1,
367 MDP_REV_22,
368 MDP_REV_30,
369 MDP_REV_303,
370 MDP_REV_31,
371 MDP_REV_40,
372 MDP_REV_41,
373 MDP_REV_42,
Huaibin Yang4a084e32011-12-15 15:25:52 -0800374 MDP_REV_43,
375 MDP_REV_44,
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700376};
377
378struct msm_panel_common_pdata {
379 uintptr_t hw_revision_addr;
380 int gpio;
Padmanabhan Komandurubea9c062012-04-09 10:33:48 +0530381 bool bl_lock;
Padmanabhan Komanduru0f0000a2012-04-12 10:23:02 +0530382 spinlock_t bl_spinlock;
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700383 int (*backlight_level)(int level, int max, int min);
384 int (*pmic_backlight)(int level);
Jeevan Shriram8f7c96d2012-05-15 12:42:57 +0530385 int (*rotate_panel)(void);
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700386 int (*panel_num)(void);
387 void (*panel_config_gpio)(int);
388 int (*vga_switch)(int select_vga);
389 int *gpio_num;
390 int mdp_core_clk_rate;
391 unsigned num_mdp_clk;
392 int *mdp_core_clk_table;
393#ifdef CONFIG_MSM_BUS_SCALING
394 struct msm_bus_scale_pdata *mdp_bus_scale_table;
395#endif
396 int mdp_rev;
Nagamalleswararao Ganji937a1192011-12-07 19:00:52 -0800397 u32 ov0_wb_size; /* overlay0 writeback size */
398 u32 ov1_wb_size; /* overlay1 writeback size */
399 u32 mem_hid;
Chandan Uddaraju2679f092012-03-09 15:48:04 -0800400 char cont_splash_enabled;
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700401};
402
Huaibin Yanga5419422011-12-08 23:52:10 -0800403
404
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700405struct lcdc_platform_data {
406 int (*lcdc_gpio_config)(int on);
407 int (*lcdc_power_save)(int);
408 unsigned int (*lcdc_get_clk)(void);
409#ifdef CONFIG_MSM_BUS_SCALING
410 struct msm_bus_scale_pdata *bus_scale_table;
411#endif
Huaibin Yang02f981c2012-02-27 16:58:41 -0800412 int (*lvds_pixel_remap)(void);
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700413};
414
415struct tvenc_platform_data {
416 int poll;
417 int (*pm_vid_en)(int on);
418#ifdef CONFIG_MSM_BUS_SCALING
419 struct msm_bus_scale_pdata *bus_scale_table;
420#endif
421};
422
423struct mddi_platform_data {
424 int (*mddi_power_save)(int on);
425 int (*mddi_sel_clk)(u32 *clk_rate);
426 int (*mddi_client_power)(u32 client_id);
427};
428
429struct mipi_dsi_platform_data {
430 int vsync_gpio;
431 int (*dsi_power_save)(int on);
432 int (*dsi_client_reset)(void);
433 int (*get_lane_config)(void);
Ravishangar Kalyanam87dd72e2012-04-16 19:07:36 -0700434 char (*splash_is_enabled)(void);
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700435 int target_type;
436};
437
Chandan Uddaraju83eac3c2011-09-11 18:32:23 -0700438enum mipi_dsi_3d_ctrl {
439 FPGA_EBI2_INTF,
440 FPGA_SPI_INTF,
441};
442
443/* DSI PHY configuration */
444struct mipi_dsi_phy_ctrl {
445 uint32_t regulator[5];
446 uint32_t timing[12];
447 uint32_t ctrl[4];
448 uint32_t strength[4];
449 uint32_t pll[21];
450};
451
Nagamalleswararao Ganjieac5dfa2011-07-23 17:31:16 -0700452struct mipi_dsi_panel_platform_data {
Chandan Uddaraju83eac3c2011-09-11 18:32:23 -0700453 int fpga_ctrl_mode;
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700454 int fpga_3d_config_addr;
Nagamalleswararao Ganjieac5dfa2011-07-23 17:31:16 -0700455 int *gpio;
Chandan Uddaraju83eac3c2011-09-11 18:32:23 -0700456 struct mipi_dsi_phy_ctrl *phy_ctrl_settings;
Ravishangar Kalyanam903f65c2012-01-28 21:36:22 -0800457 char dlane_swap;
Chandan Uddaraju2679f092012-03-09 15:48:04 -0800458 void (*dsi_pwm_cfg)(void);
Chandan Uddaraju194a4b52012-03-21 10:11:18 -0700459 char enable_wled_bl_ctrl;
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700460};
461
Ravishangar Kalyanamc2fee312012-02-09 19:11:22 -0800462struct lvds_panel_platform_data {
463 int *gpio;
464};
465
Ravishangar Kalyanam8c79ead2011-12-02 21:05:01 -0800466#define PANEL_NAME_MAX_LEN 50
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700467struct msm_fb_platform_data {
468 int (*detect_client)(const char *name);
469 int mddi_prescan;
470 int (*allow_set_offset)(void);
Ravishangar Kalyanam8c79ead2011-12-02 21:05:01 -0800471 char prim_panel_name[PANEL_NAME_MAX_LEN];
472 char ext_panel_name[PANEL_NAME_MAX_LEN];
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700473};
474
475struct msm_hdmi_platform_data {
476 int irq;
477 int (*cable_detect)(int insert);
478 int (*comm_power)(int on, int show);
479 int (*enable_5v)(int on);
480 int (*core_power)(int on, int show);
481 int (*cec_power)(int on);
482 int (*init_irq)(void);
483 bool (*check_hdcp_hw_support)(void);
484};
485
Manoj Rao14648742012-03-30 19:42:12 -0700486struct msm_mhl_platform_data {
487 int irq;
488 int (*gpio_setup)(int on);
489 void (*reset_pin)(int on);
490};
491
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700492struct msm_i2c_platform_data {
493 int clk_freq;
494 uint32_t rmutex;
495 const char *rsl_id;
496 uint32_t pm_lat;
497 int pri_clk;
498 int pri_dat;
499 int aux_clk;
500 int aux_dat;
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700501 int src_clk_rate;
502 int use_gsbi_shared_mode;
503 void (*msm_i2c_config_gpio)(int iface, int config_type);
504};
505
506struct msm_i2c_ssbi_platform_data {
507 const char *rsl_id;
508 enum msm_ssbi_controller_type controller_type;
509};
510
511struct msm_vidc_platform_data {
512 int memtype;
Deepak Koturcb4f6722011-10-31 14:06:57 -0700513 u32 enable_ion;
Deepika Pepakayalabebc7622011-12-01 15:13:43 -0800514 int disable_dmx;
Rajeshwar Kurapatyc155c352011-12-17 06:35:32 +0530515 int disable_fullhd;
Deepak kotur5f10b272012-03-15 22:01:39 -0700516 u32 cp_enabled;
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700517#ifdef CONFIG_MSM_BUS_SCALING
518 struct msm_bus_scale_pdata *vidc_bus_client_pdata;
519#endif
Mohan Kumar Gubbihalli Lachma Naiked9dc912012-03-01 19:11:14 -0800520 int cont_mode_dpb_count;
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700521};
522
Terence Hampsona6914ca2012-04-09 14:06:50 -0400523struct vcap_platform_data {
524 unsigned *gpios;
525 int num_gpios;
526 struct msm_bus_scale_pdata *bus_client_pdata;
527};
528
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700529#if defined(CONFIG_USB_PEHCI_HCD) || defined(CONFIG_USB_PEHCI_HCD_MODULE)
530struct isp1763_platform_data {
531 unsigned reset_gpio;
532 int (*setup_gpio)(int enable);
533};
534#endif
Russell Kinga09e64f2008-08-05 16:14:15 +0100535/* common init routines for use by arch/arm/mach-msm/board-*.c */
536
Sathish Ambleyc58afc22011-10-09 21:55:39 -0700537#ifdef CONFIG_OF_DEVICE
538void msm_copper_init(struct of_dev_auxdata **);
539#endif
Stepan Moskovchenkob3e63862011-10-20 18:36:55 -0700540void msm_add_devices(void);
Sathish Ambleyc58afc22011-10-09 21:55:39 -0700541void msm_copper_add_devices(void);
Michael Bohane7c2b472012-03-30 14:27:18 -0700542void msm_copper_add_drivers(void);
Stepan Moskovchenkob3e63862011-10-20 18:36:55 -0700543void msm_map_common_io(void);
544void msm_map_qsd8x50_io(void);
545void msm_map_msm8x60_io(void);
546void msm_map_msm8960_io(void);
547void msm_map_msm8930_io(void);
548void msm_map_apq8064_io(void);
549void msm_map_msm7x30_io(void);
550void msm_map_fsm9xxx_io(void);
Sathish Ambleyc58afc22011-10-09 21:55:39 -0700551void msm_map_copper_io(void);
Taniya Das43bcdd62011-12-02 17:33:27 +0530552void msm_map_msm8625_io(void);
Stepan Moskovchenkob3e63862011-10-20 18:36:55 -0700553void msm_init_irq(void);
Sathish Ambleyc58afc22011-10-09 21:55:39 -0700554void msm_copper_init_irq(void);
Taniya Das86e0e132011-10-19 11:32:00 +0530555void vic_handle_irq(struct pt_regs *regs);
Olav Hauganb800c8c2012-01-30 08:50:45 -0800556void msm_copper_reserve(void);
557void msm_copper_very_early(void);
Sathish Ambleyb17ec7e2012-04-03 15:20:03 -0700558void msm_copper_init_gpiomux(void);
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700559
560struct mmc_platform_data;
Stepan Moskovchenkob3e63862011-10-20 18:36:55 -0700561int msm_add_sdcc(unsigned int controller,
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700562 struct mmc_platform_data *plat);
563
Murali Nalajala2a0bbda2012-03-28 12:12:54 +0530564void msm_pm_register_irqs(void);
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700565struct msm_usb_host_platform_data;
Stepan Moskovchenkob3e63862011-10-20 18:36:55 -0700566int msm_add_host(unsigned int host,
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700567 struct msm_usb_host_platform_data *plat);
568#if defined(CONFIG_USB_FUNCTION_MSM_HSUSB) \
569 || defined(CONFIG_USB_MSM_72K) || defined(CONFIG_USB_MSM_72K_MODULE)
570void msm_hsusb_set_vbus_state(int online);
571#else
572static inline void msm_hsusb_set_vbus_state(int online) {}
573#endif
574
Stepan Moskovchenkob3e63862011-10-20 18:36:55 -0700575void msm_snddev_init(void);
576void msm_snddev_init_timpani(void);
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700577void msm_snddev_poweramp_on(void);
578void msm_snddev_poweramp_off(void);
579void msm_snddev_hsed_voltage_on(void);
580void msm_snddev_hsed_voltage_off(void);
581void msm_snddev_tx_route_config(void);
582void msm_snddev_tx_route_deconfig(void);
583
584extern unsigned int msm_shared_ram_phys; /* defined in arch/arm/mach-msm/io.c */
585
Russell Kinga09e64f2008-08-05 16:14:15 +0100586
587#endif