All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCHv2] pinctrl: baytrail: Clear DIRECT_IRQ bit
@ 2014-09-17 13:47 Loic Poulain
  2014-09-18  7:49 ` Mika Westerberg
  2014-09-23 15:44 ` Linus Walleij
  0 siblings, 2 replies; 10+ messages in thread
From: Loic Poulain @ 2014-09-17 13:47 UTC (permalink / raw)
  To: linus.walleij, heikki.krogerus, mika.westerberg, mathias.nyman,
	samuel.ortiz
  Cc: linux-kernel, Loic Poulain

Direct Irq En bit can be initialized to a bad value.
This bit has to be cleared for io access mode.

Signed-off-by: Loic Poulain <loic.poulain@intel.com>
---
 v2: Apply over ff998356b644ebe723127bd9eec6040b59a4a4f6 + add Warning

 drivers/pinctrl/pinctrl-baytrail.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/drivers/pinctrl/pinctrl-baytrail.c b/drivers/pinctrl/pinctrl-baytrail.c
index 701a646..77db3db 100644
--- a/drivers/pinctrl/pinctrl-baytrail.c
+++ b/drivers/pinctrl/pinctrl-baytrail.c
@@ -230,10 +230,13 @@ static int byt_irq_type(struct irq_data *d, unsigned type)
 	spin_lock_irqsave(&vg->lock, flags);
 	value = readl(reg);

+	WARN(value & BYT_DIRECT_IRQ_EN, "Clearing direct_irq_en bit");
+
 	/* For level trigges the BYT_TRIG_POS and BYT_TRIG_NEG bits
 	 * are used to indicate high and low level triggering
 	 */
-	value &= ~(BYT_TRIG_POS | BYT_TRIG_NEG | BYT_TRIG_LVL);
+	value &= ~(BYT_DIRECT_IRQ_EN | BYT_TRIG_POS | BYT_TRIG_NEG |
+		   BYT_TRIG_LVL);

 	switch (type) {
 	case IRQ_TYPE_LEVEL_HIGH:
--
1.8.3.2


^ permalink raw reply related	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2014-09-24  8:42 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-09-17 13:47 [PATCHv2] pinctrl: baytrail: Clear DIRECT_IRQ bit Loic Poulain
2014-09-18  7:49 ` Mika Westerberg
2014-09-18  9:31   ` Loic Poulain
2014-09-18  9:53     ` Mika Westerberg
2014-09-18  9:41   ` Samuel Ortiz
2014-09-18  9:55     ` Mika Westerberg
2014-09-18 23:59       ` eric ernst
2014-09-23 15:44 ` Linus Walleij
2014-09-23 18:36   ` Westerberg, Mika
2014-09-24  8:44     ` Loic Poulain

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.