diff options
author | Lina Iyer <ilina@codeaurora.org> | 2019-11-15 15:11:51 -0700 |
---|---|---|
committer | Marc Zyngier <maz@kernel.org> | 2019-11-16 10:23:15 +0000 |
commit | e35a6ae0eb3a7cc451e8d8db55e9b938a95de416 (patch) | |
tree | 621ac3bead84a8d4ab5ab59956304856c0966b2b /include/linux/soc | |
parent | e71374c07564536d38caed3e80a1ff1c4609161d (diff) | |
download | linux-stable-e35a6ae0eb3a7cc451e8d8db55e9b938a95de416.tar.gz linux-stable-e35a6ae0eb3a7cc451e8d8db55e9b938a95de416.tar.bz2 linux-stable-e35a6ae0eb3a7cc451e8d8db55e9b938a95de416.zip |
pinctrl/msm: Setup GPIO chip in hierarchy
Some GPIOs are marked as wakeup capable and are routed to another
interrupt controller that is an always-domain and can detect interrupts
even when most of the SoC is powered off. The wakeup interrupt
controller wakes up the GIC and replays the interrupt at the GIC.
Setup the TLMM irqchip in hierarchy with the wakeup interrupt controller
and ensure the wakeup GPIOs are handled correctly.
Co-developed-by: Maulik Shah <mkshah@codeaurora.org>
Signed-off-by: Lina Iyer <ilina@codeaurora.org>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Reviewed-by: Stephen Boyd <swboyd@chromium.org>
Link: https://lore.kernel.org/r/1573855915-9841-9-git-send-email-ilina@codeaurora.org
----
Changes in v2:
- Address review comments
- Fix Co-developed-by tag
Changes in v1:
- Address minor review comments
- Remove redundant call to set irq handler
- Move irq_domain_qcom_handle_wakeup() to this patch
Changes in RFC v2:
- Rebase on top of GPIO hierarchy support in linux-next
- Set the chained irq handler for summary line
Diffstat (limited to 'include/linux/soc')
-rw-r--r-- | include/linux/soc/qcom/irq.h | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/include/linux/soc/qcom/irq.h b/include/linux/soc/qcom/irq.h index 637c0bfa89e7..9e1ece58e55b 100644 --- a/include/linux/soc/qcom/irq.h +++ b/include/linux/soc/qcom/irq.h @@ -18,4 +18,17 @@ #define IRQ_DOMAIN_FLAG_QCOM_PDC_WAKEUP (IRQ_DOMAIN_FLAG_NONCORE << 0) #define IRQ_DOMAIN_FLAG_QCOM_MPM_WAKEUP (IRQ_DOMAIN_FLAG_NONCORE << 1) +/** + * irq_domain_qcom_handle_wakeup: Return if the domain handles interrupt + * configuration + * @d: irq domain + * + * This QCOM specific irq domain call returns if the interrupt controller + * requires the interrupt be masked at the child interrupt controller. + */ +static inline bool irq_domain_qcom_handle_wakeup(const struct irq_domain *d) +{ + return (d->flags & IRQ_DOMAIN_FLAG_QCOM_PDC_WAKEUP); +} + #endif |