On 8 January 2013 16:48, Laxman Dewangan <ldewangan@xxxxxxxxxx> wrote: > I think we can do it in the gpio chip driver inthe function > xxx_gpio_irq_set_type(). > When you register any irq and if this callback is available from gpio chip > driver then this will get called. and so the setting the pi to input mode as > well as putting the pin in GPIO mode can be done here. This is what we are > doing it in gpio-tegra driver. Hmm... So, the initial question was, is somebody setting gpio in input mode? There were no bugs reported, it was just a query. As most of the stuff would work as per my earlier explanation. But yes, your suggestion makes sense too.. I would rather do it in the gpiolib routine instead of adding this in every driver. @Linus/Grant: What do you say? -- To unsubscribe from this list: send the line "unsubscribe linux-input" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html