aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Büsch <mb@bu3sch.de>2011-11-17 18:06:19 +0000
committerMichael Büsch <mb@bu3sch.de>2011-11-17 18:06:19 +0000
commit4793be2df9316bfed829656a7fd93be7b2789e4f (patch)
treed1189113768bcc07bbe78d76bd8b939bd1583c76
parent630bafc5dd73b82ee644baf01a66562bb436701c (diff)
downloadupstream-4793be2df9316bfed829656a7fd93be7b2789e4f.tar.gz
upstream-4793be2df9316bfed829656a7fd93be7b2789e4f.tar.bz2
upstream-4793be2df9316bfed829656a7fd93be7b2789e4f.zip
omap24xx: Some retu/tahvo IRQ fixes
SVN-Revision: 29233
-rw-r--r--target/linux/omap24xx/patches-3.1/252-cbus-retu-tahvo-ack-fix.patch65
-rw-r--r--target/linux/omap24xx/patches-3.1/253-cbus-tahvo-irq-reg-lock.patch15
2 files changed, 80 insertions, 0 deletions
diff --git a/target/linux/omap24xx/patches-3.1/252-cbus-retu-tahvo-ack-fix.patch b/target/linux/omap24xx/patches-3.1/252-cbus-retu-tahvo-ack-fix.patch
new file mode 100644
index 0000000000..34f9465969
--- /dev/null
+++ b/target/linux/omap24xx/patches-3.1/252-cbus-retu-tahvo-ack-fix.patch
@@ -0,0 +1,65 @@
+Index: linux-3.1.1/drivers/cbus/retu.c
+===================================================================
+--- linux-3.1.1.orig/drivers/cbus/retu.c 2011-11-17 18:47:59.453004678 +0100
++++ linux-3.1.1/drivers/cbus/retu.c 2011-11-17 18:49:03.180787673 +0100
+@@ -54,8 +54,6 @@ struct retu {
+ int irq;
+
+ int ack;
+- bool ack_pending;
+-
+ int mask;
+ bool mask_pending;
+
+@@ -238,7 +236,6 @@ static void retu_irq_ack(struct irq_data
+ int irq = data->irq;
+
+ retu->ack |= (1 << (irq - retu->irq_base));
+- retu->ack_pending = true;
+ }
+
+ static void retu_bus_lock(struct irq_data *data)
+@@ -257,9 +254,9 @@ static void retu_bus_sync_unlock(struct
+ retu->mask_pending = false;
+ }
+
+- if (retu->ack_pending) {
++ if (retu->ack) {
+ __retu_write_reg(retu, RETU_REG_IDR, retu->ack);
+- retu->ack_pending = false;
++ retu->ack = 0;
+ }
+
+ mutex_unlock(&retu->mutex);
+Index: linux-3.1.1/drivers/cbus/tahvo.c
+===================================================================
+--- linux-3.1.1.orig/drivers/cbus/tahvo.c 2011-11-17 18:47:59.437004733 +0100
++++ linux-3.1.1/drivers/cbus/tahvo.c 2011-11-17 18:51:03.708374259 +0100
+@@ -52,7 +52,6 @@ struct tahvo {
+ int mask;
+
+ unsigned int mask_pending:1;
+- unsigned int ack_pending:1;
+ unsigned int is_betty:1;
+ };
+
+@@ -177,9 +176,9 @@ static void tahvo_irq_bus_sync_unlock(st
+ tahvo->mask_pending = false;
+ }
+
+- if (tahvo->ack_pending) {
++ if (tahvo->ack) {
+ __tahvo_write_reg(tahvo, TAHVO_REG_IDR, tahvo->ack);
+- tahvo->ack_pending = false;
++ tahvo->ack = 0;
+ }
+
+ mutex_unlock(&tahvo->mutex);
+@@ -209,7 +208,6 @@ static void tahvo_irq_ack(struct irq_dat
+ int irq = data->irq;
+
+ tahvo->ack |= (1 << (irq - tahvo->irq_base));
+- tahvo->ack_pending = true;
+ }
+
+ static struct irq_chip tahvo_irq_chip = {
diff --git a/target/linux/omap24xx/patches-3.1/253-cbus-tahvo-irq-reg-lock.patch b/target/linux/omap24xx/patches-3.1/253-cbus-tahvo-irq-reg-lock.patch
new file mode 100644
index 0000000000..c27a67c7c9
--- /dev/null
+++ b/target/linux/omap24xx/patches-3.1/253-cbus-tahvo-irq-reg-lock.patch
@@ -0,0 +1,15 @@
+Index: linux-3.1.1/drivers/cbus/tahvo.c
+===================================================================
+--- linux-3.1.1.orig/drivers/cbus/tahvo.c 2011-11-17 18:51:03.708374259 +0100
++++ linux-3.1.1/drivers/cbus/tahvo.c 2011-11-17 18:57:17.739067493 +0100
+@@ -137,8 +137,10 @@ static irqreturn_t tahvo_irq_handler(int
+ u16 id;
+ u16 im;
+
++ mutex_lock(&tahvo->mutex);
+ id = __tahvo_read_reg(tahvo, TAHVO_REG_IDR);
+ im = __tahvo_read_reg(tahvo, TAHVO_REG_IMR);
++ mutex_unlock(&tahvo->mutex);
+ id &= ~im;
+
+ if (!id) {