]> git.baikalelectronics.ru Git - kernel.git/commit
can: m_can: process interrupt only when not runtime suspended
authorJarkko Nikula <jarkko.nikula@linux.intel.com>
Tue, 15 Sep 2020 13:47:15 +0000 (16:47 +0300)
committerMarc Kleine-Budde <mkl@pengutronix.de>
Wed, 18 Nov 2020 15:37:32 +0000 (16:37 +0100)
commita649b19b17df26559b69d0fb00c639c5c38f5af3
tree3a790dcb197057001adea5a423db03a3e128c7f4
parentf9ed233c080c9e1bb5c8a31c97dcd3ec6f61c508
can: m_can: process interrupt only when not runtime suspended

Avoid processing bogus interrupt statuses when the HW is runtime suspended and
the M_CAN_IR register read may get all bits 1's. Handler can be called if the
interrupt request is shared with other peripherals or at the end of free_irq().

Therefore check the runtime suspended status before processing.

Fixes: 51afffa9b791 ("can: m_can: Add PM Support")
Signed-off-by: Jarkko Nikula <jarkko.nikula@linux.intel.com>
Link: https://lore.kernel.org/r/20200915134715.696303-1-jarkko.nikula@linux.intel.com
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
drivers/net/can/m_can/m_can.c