[PATCH] rtc: sunxi: fix possible race condition
From: Maxime Ripard <hidden>
Date: 2018-06-04 12:31:28
Also in:
linux-rtc, lkml
From: Maxime Ripard <hidden>
Date: 2018-06-04 12:31:28
Also in:
linux-rtc, lkml
On Mon, Jun 04, 2018 at 02:05:40PM +0200, Alexandre Belloni wrote:
The IRQ is requested before the struct rtc is allocated and registered, but this struct is used in the IRQ handler. This may lead to a NULL pointer dereference. Switch to devm_rtc_allocate_device/rtc_register_device to allocate the rtc before requesting the IRQ. Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Acked-by: Maxime Ripard <redacted> Maxime -- Maxime Ripard, Bootlin (formerly Free Electrons) Embedded Linux and Kernel engineering https://bootlin.com -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 833 bytes Desc: not available URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20180604/e4f3741d/attachment.sig>