aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/ipq806x/patches-4.9/0004-spi-qup-Fix-transaction-done-signaling.patch
diff options
context:
space:
mode:
authorJohn Crispin <john@phrozen.org>2017-03-13 13:30:10 +0100
committerFelix Fietkau <nbd@nbd.name>2017-03-13 13:40:55 +0100
commit1adf51702e94063fb058ce13226ec5a04d15cfd4 (patch)
tree00fb0f446f516289abb93ff78f103294254545c3 /target/linux/ipq806x/patches-4.9/0004-spi-qup-Fix-transaction-done-signaling.patch
parent99b6aefd638c7934136ffcde271e6fc3f4f6c464 (diff)
downloadupstream-1adf51702e94063fb058ce13226ec5a04d15cfd4.tar.gz
upstream-1adf51702e94063fb058ce13226ec5a04d15cfd4.tar.bz2
upstream-1adf51702e94063fb058ce13226ec5a04d15cfd4.zip
ipq806x: clean up patches, port missing patches from 4.4
Signed-off-by: John Crispin <john@phrozen.org> Signed-off-by: Felix Fietkau <nbd@nbd.name>
Diffstat (limited to 'target/linux/ipq806x/patches-4.9/0004-spi-qup-Fix-transaction-done-signaling.patch')
-rw-r--r--target/linux/ipq806x/patches-4.9/0004-spi-qup-Fix-transaction-done-signaling.patch29
1 files changed, 29 insertions, 0 deletions
diff --git a/target/linux/ipq806x/patches-4.9/0004-spi-qup-Fix-transaction-done-signaling.patch b/target/linux/ipq806x/patches-4.9/0004-spi-qup-Fix-transaction-done-signaling.patch
new file mode 100644
index 0000000000..5881ffa8b6
--- /dev/null
+++ b/target/linux/ipq806x/patches-4.9/0004-spi-qup-Fix-transaction-done-signaling.patch
@@ -0,0 +1,29 @@
+From fbdf80d138f8c7fda8e598287109fb90446d557d Mon Sep 17 00:00:00 2001
+From: Andy Gross <andy.gross@linaro.org>
+Date: Fri, 29 Jan 2016 22:06:50 -0600
+Subject: [PATCH 04/69] spi: qup: Fix transaction done signaling
+
+Wait to signal done until we get all of the interrupts we are expecting
+to get for a transaction. If we don't wait for the input done flag, we
+can be inbetween transactions when the done flag comes in and this can
+mess up the next transaction.
+
+CC: Grant Grundler <grundler@chromium.org>
+CC: Sarthak Kukreti <skukreti@codeaurora.org>
+Signed-off-by: Andy Gross <andy.gross@linaro.org>
+---
+ drivers/spi/spi-qup.c | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+--- a/drivers/spi/spi-qup.c
++++ b/drivers/spi/spi-qup.c
+@@ -445,7 +445,8 @@ static irqreturn_t spi_qup_qup_irq(int i
+ controller->xfer = xfer;
+ spin_unlock_irqrestore(&controller->lock, flags);
+
+- if (controller->rx_bytes == xfer->len || error)
++ if ((controller->rx_bytes == xfer->len &&
++ (opflags & QUP_OP_MAX_INPUT_DONE_FLAG)) || error)
+ complete(&controller->done);
+
+ return IRQ_HANDLED;