gpio: omap: fix lack of irqstatus_raw0 for OMAP4 [Linux 4.9.187]

This Linux kernel change "gpio: omap: fix lack of irqstatus_raw0 for OMAP4" is included in the Linux 4.9.187 release. This change is authored by Russell King <rmk+kernel [at]> on Mon Jun 10 20:10:45 2019 +0300. The commit for this change in Linux stable tree is 58337d9 (patch) which is from upstream commit 64ea3e9. The same Linux upstream change may have been applied to various maintained Linux releases and you can find all Linux releases containing changes from upstream 64ea3e9.

gpio: omap: fix lack of irqstatus_raw0 for OMAP4

[ Upstream commit 64ea3e9094a1f13b96c33244a3fb3a0f45690bd2 ]

Commit 384ebe1c2849 ("gpio/omap: Add DT support to GPIO driver") added
the register definition tables to the gpio-omap driver. Subsequently to
that commit, commit 4e962e8998cc ("gpio/omap: remove cpu_is_omapxxxx()
checks from *_runtime_resume()") added definitions for irqstatus_raw*
registers to the legacy OMAP4 definitions, but missed the DT

This causes an unintentional change of behaviour for the 1.101 errata
workaround on OMAP4 platforms. Fix this oversight.

Fixes: 4e962e8998cc ("gpio/omap: remove cpu_is_omapxxxx() checks from *_runtime_resume()")
Signed-off-by: Russell King <>
Signed-off-by: Grygorii Strashko <>
Tested-by: Tony Lindgren <>
Signed-off-by: Linus Walleij <>
Signed-off-by: Sasha Levin <>

There are 2 lines of Linux source code added/deleted in this change. Code changes to Linux kernel are as follows.

 drivers/gpio/gpio-omap.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/gpio/gpio-omap.c b/drivers/gpio/gpio-omap.c
index 0388821..bd12b43 100644
--- a/drivers/gpio/gpio-omap.c
+++ b/drivers/gpio/gpio-omap.c
@@ -1585,6 +1585,8 @@ static inline void omap_gpio_init_context(struct gpio_bank *p) {}
    .clr_dataout =      OMAP4_GPIO_CLEARDATAOUT,
    .irqstatus =        OMAP4_GPIO_IRQSTATUS0,
    .irqstatus2 =       OMAP4_GPIO_IRQSTATUS1,
+   .irqstatus_raw0 =   OMAP4_GPIO_IRQSTATUSRAW0,
+   .irqstatus_raw1 =   OMAP4_GPIO_IRQSTATUSRAW1,
    .irqenable =        OMAP4_GPIO_IRQSTATUSSET0,
    .irqenable2 =       OMAP4_GPIO_IRQSTATUSSET1,
    .set_irqenable =    OMAP4_GPIO_IRQSTATUSSET0,

Leave a Reply

Your email address will not be published. Required fields are marked *