summaryrefslogtreecommitdiffstats
path: root/drivers/pinctrl/mediatek/pinctrl-mtk-common.h
diff options
context:
space:
mode:
authorYingjoe Chen <yingjoe.chen@mediatek.com>2015-01-27 14:15:26 +0800
committerLinus Walleij <linus.walleij@linaro.org>2015-03-18 02:02:16 +0100
commit3221f40b7631183b0c7a2e5d4be00cab12d983c3 (patch)
tree71f6b06e47ddaa23c42105b696dec52f5ccc0747 /drivers/pinctrl/mediatek/pinctrl-mtk-common.h
parent30f010f5c4cfcdf3773d6f2dcbab3c349d05c668 (diff)
downloadblackbird-op-linux-3221f40b7631183b0c7a2e5d4be00cab12d983c3.tar.gz
blackbird-op-linux-3221f40b7631183b0c7a2e5d4be00cab12d983c3.zip
pinctrl: mediatek: emulate GPIO interrupt on both-edges
MTK EINT does not support generating interrupt on both edges. Emulate this by changing edge polarity while enable irq, set types and interrupt handling. This follows an example of drivers/gpio/gpio-mxc.c. Signed-off-by: Yingjoe Chen <yingjoe.chen@mediatek.com> Signed-off-by: Chaotian Jing <chaotian.jing@mediatek.com> Acked-by: Hongzhou Yang <hongzhou.yang@mediatek.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'drivers/pinctrl/mediatek/pinctrl-mtk-common.h')
-rw-r--r--drivers/pinctrl/mediatek/pinctrl-mtk-common.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/pinctrl/mediatek/pinctrl-mtk-common.h b/drivers/pinctrl/mediatek/pinctrl-mtk-common.h
index 740e6d227d0f..375771db9bd0 100644
--- a/drivers/pinctrl/mediatek/pinctrl-mtk-common.h
+++ b/drivers/pinctrl/mediatek/pinctrl-mtk-common.h
@@ -131,6 +131,9 @@ struct mtk_eint_offsets {
unsigned int sens;
unsigned int sens_set;
unsigned int sens_clr;
+ unsigned int soft;
+ unsigned int soft_set;
+ unsigned int soft_clr;
unsigned int pol;
unsigned int pol_set;
unsigned int pol_clr;
@@ -217,6 +220,7 @@ struct mtk_pinctrl {
const struct mtk_pinctrl_devdata *devdata;
void __iomem *eint_reg_base;
struct irq_domain *domain;
+ int *eint_dual_edges;
};
int mtk_pctrl_init(struct platform_device *pdev,
OpenPOWER on IntegriCloud