diff options
author | Jason Chen <b02280@freescale.com> | 2011-09-14 16:23:03 +0800 |
---|---|---|
committer | Jason Chen <b02280@freescale.com> | 2011-09-14 16:23:03 +0800 |
commit | 7e4c452de18618ec140a0a1d00171ce776a00d83 (patch) | |
tree | 208268c4ad9aea3d613c378d9fd7ee54cd333fcd | |
parent | e21a452bd4d60dd1de4f880c3a241db2d221fdbe (diff) |
ENGR00156183-1 mx53_loco: add get_pins/put_pins call back for sii902x
there is hardware pin conflict between sii902x DET and egalax touch screen
on mx53 loco board. Request gpio during sii902x probe can fix this conflict
only when these two module not co-exist.
Signed-off-by: Jason Chen <b02280@freescale.com>
-rw-r--r-- | arch/arm/mach-mx5/mx53_loco.c | 28 |
1 files changed, 20 insertions, 8 deletions
diff --git a/arch/arm/mach-mx5/mx53_loco.c b/arch/arm/mach-mx5/mx53_loco.c index 301ea1b464a5..c8417dad4c70 100644 --- a/arch/arm/mach-mx5/mx53_loco.c +++ b/arch/arm/mach-mx5/mx53_loco.c @@ -484,9 +484,27 @@ static void sii902x_hdmi_reset(void) msleep(10); } +static int sii902x_get_pins(void) +{ + /* Sii902x HDMI controller */ + gpio_request(DISP0_RESET, "disp0-reset"); + gpio_direction_output(DISP0_RESET, 0); + gpio_request(DISP0_DET_INT, "disp0-detect"); + gpio_direction_input(DISP0_DET_INT); + return 1; +} + +static void sii902x_put_pins(void) +{ + gpio_free(DISP0_RESET); + gpio_free(DISP0_DET_INT); +} + static struct mxc_lcd_platform_data sii902x_hdmi_data = { - .reset = sii902x_hdmi_reset, - .fb_id = "DISP3 BG", + .reset = sii902x_hdmi_reset, + .fb_id = "DISP3 BG", + .get_pins = sii902x_get_pins, + .put_pins = sii902x_put_pins, }; static struct imxi2c_platform_data mxci2c_data = { @@ -843,12 +861,6 @@ static void __init mx53_loco_io_init(void) gpio_request(USB_PWREN, "usb-pwr"); gpio_direction_output(USB_PWREN, 0); - /* Sii902x HDMI controller */ - gpio_request(DISP0_RESET, "disp0-reset"); - gpio_direction_output(DISP0_RESET, 0); - gpio_request(DISP0_DET_INT, "disp0-detect"); - gpio_direction_input(DISP0_DET_INT); - /* LCD panel power enable */ gpio_request(DISP0_POWER_EN, "disp0-power-en"); gpio_direction_output(DISP0_POWER_EN, 1); |