On 02/07/14 18:25, Dmitry Torokhov wrote: > In this case board code should take care of setting up the interrupt > properly and the driver should simply use 0 as flags in request_irq(). > By the way, doesn't generic DT infrastructure already allow specifying > interrupt triggers and sets them up properly? Yes. I've checked and tested this behaviour today. If you don't specify a trigger type, then when you request the irq it trusts that the platform has already set it up correctly: http://lxr.free-electrons.com/source/kernel/irq/manage.c#L1208 Stephen: you should be able to set up the interrupt config in the device tree. I believe this should be done by putting IRQ_TYPE_LEVEL_LOW or IRQ_TYPE_EDGE_FALLING in the third field in the "interrupts" definition, although I haven't a tegra DTS device to test on at the moment. I've applied the patch below, which is basically what Sekhar had originally, with a minor extra fix. I've merged it into the appropriate parts of my for upstream series at https://github.com/ndyer/linux/commits/for-next diff --git a/drivers/input/touchscreen/atmel_mxt_ts.c b/drivers/input/touchscree index dc46100..15efb3b 100644 --- a/drivers/input/touchscreen/atmel_mxt_ts.c +++ b/drivers/input/touchscreen/atmel_mxt_ts.c @@ -1453,7 +1453,7 @@ static int mxt_check_retrigen(struct mxt_data *data) int error; int val; - if (data->pdata->irqflags & IRQF_TRIGGER_LOW) + if (irq_get_trigger_type(data->irq) & IRQF_TRIGGER_LOW) return 0; if (data->T18_address) { @@ -3155,9 +3155,6 @@ static struct mxt_platform_data *mxt_parse_dt(struct i2c_c pdata->gpio_reset = of_get_named_gpio_flags(dev->of_node, "atmel,reset-gpio", 0, NULL); - /* Default to this. Properties can be added to configure it later */ - pdata->irqflags = IRQF_TRIGGER_FALLING; - of_property_read_string(dev->of_node, "atmel,cfg_name", &pdata->cfg_name); -- 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