]> git.kernelconcepts.de Git - karo-tx-linux.git/blobdiff - drivers/gpio/gpio-dwapb.c
Merge branch 'stable-4.13' of git://git.infradead.org/users/pcmoore/audit
[karo-tx-linux.git] / drivers / gpio / gpio-dwapb.c
index f051c4552af570257b92bf5d7f80b2a706cbf721..c07ada9c7af6d6f8403f5412bd5d4bc85fd46055 100644 (file)
@@ -288,7 +288,8 @@ static int dwapb_irq_set_type(struct irq_data *d, u32 type)
        irq_setup_alt_chip(d, type);
 
        dwapb_write(gpio, GPIO_INTTYPE_LEVEL, level);
-       dwapb_write(gpio, GPIO_INT_POLARITY, polarity);
+       if (type != IRQ_TYPE_EDGE_BOTH)
+               dwapb_write(gpio, GPIO_INT_POLARITY, polarity);
        spin_unlock_irqrestore(&gc->bgpio_lock, flags);
 
        return 0;