Problem in twl4030_gpio.c
Hi,
twl4030 gpio driver has a problem which causes the pull up/down registers to be reset with every call to twl4030_request_gpio().
Below is a patch that fixes this.
twl4030_gpio.c 2008-02-26 18:53:35.000000000 -0800 renamed from twl4030_gpio.c.org 2008-02-26 18:52:57.000000000 -0800 +2 -0
@@ -332,13 +332,13 @@ gpio_twl4030_write(REG_GPIO_CTRL, MASK_GPIO_CTRL_GPIO_ON); ret = gpio_twl4030_write(REG_GPIO_SIH_CTRL, 0x00); + ret = + twl4030_i2c_write(TWL4030_MODULE_GPIO,
clear_pull,
+ REG_GPIOPUPDCTR1, 5);
}
if (!ret)
gpio_usage_count |= (0x1 << gpio);- ret =
- twl4030_i2c_write(TWL4030_MODULE_GPIO, clear_pull,
- REG_GPIOPUPDCTR1, 5);
}
up(&gpio_sem);
return ret;- Juha
Signature · 1 line
Madness takes it's toll. Please have exact change.