On Thu, Apr 01, 2010 at 11:29:16AM +0200, ext Grazvydas Ignotas wrote:
Hmh, dbck is shared by the whole GPIO bank, so what happens if someone calls _set_gpio_debounce(bank, 1, 310) and then _set_gpio_debounce(bank, 2, 0)? This should leave debounce enabled for GPIO1, but you'll disable dbck on second call. GPIOs 0-31 share the same bank.
but why would you call _set_gpio_debounce(bank, 2 0); without setting a real debounce value before ?
There is also an issue if somebody calls _set_gpio_debounce(bank, 1, 310) and _set_gpio_debounce(bank, 2, 620), the second call will override debounce setting of GPIO1 (as it's shared by the whole bank). This might be not what the user intended, would be useful to detect this and warn the user.
good point. As this is RFC, I'll wait until everybody comments. -- balbi -- To unsubscribe from this list: send the line "unsubscribe linux-omap" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html