aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-omap1/board-nokia770.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/mach-omap1/board-nokia770.c')
-rw-r--r--arch/arm/mach-omap1/board-nokia770.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/arch/arm/mach-omap1/board-nokia770.c b/arch/arm/mach-omap1/board-nokia770.c
index 38d9783ac6d6..b26782471e59 100644
--- a/arch/arm/mach-omap1/board-nokia770.c
+++ b/arch/arm/mach-omap1/board-nokia770.c
@@ -102,7 +102,7 @@ static void mipid_shutdown(struct mipid_platform_data *pdata)
102{ 102{
103 if (pdata->nreset_gpio != -1) { 103 if (pdata->nreset_gpio != -1) {
104 printk(KERN_INFO "shutdown LCD\n"); 104 printk(KERN_INFO "shutdown LCD\n");
105 omap_set_gpio_dataout(pdata->nreset_gpio, 0); 105 gpio_set_value(pdata->nreset_gpio, 0);
106 msleep(120); 106 msleep(120);
107 } 107 }
108} 108}
@@ -124,13 +124,13 @@ static void mipid_dev_init(void)
124 124
125static void ads7846_dev_init(void) 125static void ads7846_dev_init(void)
126{ 126{
127 if (omap_request_gpio(ADS7846_PENDOWN_GPIO) < 0) 127 if (gpio_request(ADS7846_PENDOWN_GPIO, "ADS7846 pendown") < 0)
128 printk(KERN_ERR "can't get ads7846 pen down GPIO\n"); 128 printk(KERN_ERR "can't get ads7846 pen down GPIO\n");
129} 129}
130 130
131static int ads7846_get_pendown_state(void) 131static int ads7846_get_pendown_state(void)
132{ 132{
133 return !omap_get_gpio_datain(ADS7846_PENDOWN_GPIO); 133 return !gpio_get_value(ADS7846_PENDOWN_GPIO);
134} 134}
135 135
136static struct ads7846_platform_data nokia770_ads7846_platform_data __initdata = { 136static struct ads7846_platform_data nokia770_ads7846_platform_data __initdata = {
@@ -228,9 +228,9 @@ static void nokia770_audio_pwr_up(void)
228 /* Turn on codec */ 228 /* Turn on codec */
229 aic23_power_up(); 229 aic23_power_up();
230 230
231 if (omap_get_gpio_datain(HEADPHONE_GPIO)) 231 if (gpio_get_value(HEADPHONE_GPIO))
232 /* HP not connected, turn on amplifier */ 232 /* HP not connected, turn on amplifier */
233 omap_set_gpio_dataout(AMPLIFIER_CTRL_GPIO, 1); 233 gpio_set_value(AMPLIFIER_CTRL_GPIO, 1);
234 else 234 else
235 /* HP connected, do not turn on amplifier */ 235 /* HP connected, do not turn on amplifier */
236 printk("HP connected\n"); 236 printk("HP connected\n");
@@ -250,7 +250,7 @@ static DECLARE_DELAYED_WORK(codec_power_down_work, codec_delayed_power_down);
250static void nokia770_audio_pwr_down(void) 250static void nokia770_audio_pwr_down(void)
251{ 251{
252 /* Turn off amplifier */ 252 /* Turn off amplifier */
253 omap_set_gpio_dataout(AMPLIFIER_CTRL_GPIO, 0); 253 gpio_set_value(AMPLIFIER_CTRL_GPIO, 0);
254 254
255 /* Turn off codec: schedule delayed work */ 255 /* Turn off codec: schedule delayed work */
256 schedule_delayed_work(&codec_power_down_work, HZ / 20); /* 50ms */ 256 schedule_delayed_work(&codec_power_down_work, HZ / 20); /* 50ms */