lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1473015587-15589-3-git-send-email-robert.jarzmik@free.fr>
Date:   Sun,  4 Sep 2016 20:59:47 +0200
From:   Robert Jarzmik <robert.jarzmik@...e.fr>
To:     Russell King <linux@...linux.org.uk>,
        Daniel Mack <daniel@...que.org>,
        Haojian Zhuang <haojian.zhuang@...il.com>,
        Robert Jarzmik <robert.jarzmik@...e.fr>,
        Russell King - ARM Linux <linux@....linux.org.uk>
Cc:     linux-arm-kernel@...ts.infradead.org, linux-kernel@...r.kernel.org
Subject: [PATCH 3/3] [DO_NOT_REVIEW] sa1111: left up to Russell King

In order to be able to cope with ordering problems, especially when the
interrupt descriptor is allocated only after the sa1111 is probed, add a
workaround to "wait" for the interrupt chip to be available.

Signed-off-by: Robert Jarzmik <robert.jarzmik@...e.fr>
---
 arch/arm/common/sa1111.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/arch/arm/common/sa1111.c b/arch/arm/common/sa1111.c
index 1b03ff639836..abd94ff83a6c 100644
--- a/arch/arm/common/sa1111.c
+++ b/arch/arm/common/sa1111.c
@@ -21,6 +21,7 @@
 #include <linux/kernel.h>
 #include <linux/delay.h>
 #include <linux/errno.h>
+#include <linux/interrupt.h>
 #include <linux/ioport.h>
 #include <linux/platform_device.h>
 #include <linux/slab.h>
@@ -1183,6 +1184,9 @@ static int sa1111_probe(struct platform_device *pdev)
 	if (irq < 0)
 		return irq;
 
+	if (!irq_get_chip(irq))
+		return -EPROBE_DEFER;
+
 	return __sa1111_probe(&pdev->dev, mem, irq);
 }
 
-- 
2.1.4

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ