Merge remote-tracking branch 'stable/linux-3.0.y' into develop-3.0
[firefly-linux-kernel-4.4.55.git] / drivers / input / touchscreen / ili2102_ts.h
1 /*
2  * drivers/input/touchscreen/xpt2046_cbn_ts.h
3  *
4  * Copyright (C) 2010 ROCKCHIP, Inc.
5  *
6  * This software is licensed under the terms of the GNU General Public
7  * License version 2, as published by the Free Software Foundation, and
8  * may be copied, distributed, and modified under those terms.
9  *
10  * This program is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13  * GNU General Public License for more details.
14  */
15
16 #ifndef __DRIVERS_TOUCHSCREEN_ILI2102_TS_H
17 #define __DRIVERS_TOUCHSCREEN_ILI2102_TS_H
18
19 #define IOMUX_NAME_SIZE 40
20
21 enum touchstate {
22         TOUCH_UP = 0, TOUCH_DOWN = 1,
23 };      
24
25 struct ili2102_platform_data {
26
27         u16             model;                  /* 8520. */
28         bool    swap_xy;                /* swap x and y axes */
29         u16             x_min, x_max;
30         u16             y_min, y_max;
31   int   gpio_reset;
32   int   gpio_reset_active_low;
33         int             gpio_pendown;           /* the GPIO used to decide the pendown*/
34         
35         char    pendown_iomux_name[IOMUX_NAME_SIZE];
36         char    resetpin_iomux_name[IOMUX_NAME_SIZE];
37         int             pendown_iomux_mode;
38         int             resetpin_iomux_mode;
39         
40         int     (*get_pendown_state)(void);
41 };
42 #endif