aboutsummaryrefslogtreecommitdiffstats
path: root/target
diff options
context:
space:
mode:
authorJohn Crispin <john@phrozen.org>2016-06-24 13:00:45 +0200
committerZoltan HERPAI <wigyori@uid0.hu>2016-06-24 13:00:45 +0200
commit05daba8e2eb1ae66d91d7a7898ae342a3578c95a (patch)
tree62e051893dd48bb56482cf58528224e2eea173be /target
parentfa132c2a36cc267a4b3681729ddeb04aaa7d0cc1 (diff)
downloadmaster-187ad058-05daba8e2eb1ae66d91d7a7898ae342a3578c95a.tar.gz
master-187ad058-05daba8e2eb1ae66d91d7a7898ae342a3578c95a.tar.bz2
master-187ad058-05daba8e2eb1ae66d91d7a7898ae342a3578c95a.zip
ramips: fix timing issues when using MT7621 spi
Signed-off-by: John Crispin <john@phrozen.org>
Diffstat (limited to 'target')
-rw-r--r--target/linux/ramips/patches-4.4/0043-spi-add-mt7621-support.patch9
1 files changed, 6 insertions, 3 deletions
diff --git a/target/linux/ramips/patches-4.4/0043-spi-add-mt7621-support.patch b/target/linux/ramips/patches-4.4/0043-spi-add-mt7621-support.patch
index 73fe51c841..517a7d7f13 100644
--- a/target/linux/ramips/patches-4.4/0043-spi-add-mt7621-support.patch
+++ b/target/linux/ramips/patches-4.4/0043-spi-add-mt7621-support.patch
@@ -13,7 +13,7 @@ Signed-off-by: John Crispin <blogic@openwrt.org>
--- a/drivers/spi/Kconfig
+++ b/drivers/spi/Kconfig
-@@ -483,6 +483,12 @@ config SPI_RT2880
+@@ -483,6 +483,12 @@
help
This selects a driver for the Ralink RT288x/RT305x SPI Controller.
@@ -28,7 +28,7 @@ Signed-off-by: John Crispin <blogic@openwrt.org>
depends on ARCH_S3C24XX
--- a/drivers/spi/Makefile
+++ b/drivers/spi/Makefile
-@@ -51,6 +51,7 @@ obj-$(CONFIG_SPI_MPC512x_PSC) += spi-mp
+@@ -51,6 +51,7 @@
obj-$(CONFIG_SPI_MPC52xx_PSC) += spi-mpc52xx-psc.o
obj-$(CONFIG_SPI_MPC52xx) += spi-mpc52xx.o
obj-$(CONFIG_SPI_MT65XX) += spi-mt65xx.o
@@ -38,7 +38,7 @@ Signed-off-by: John Crispin <blogic@openwrt.org>
obj-$(CONFIG_SPI_OC_TINY) += spi-oc-tiny.o
--- /dev/null
+++ b/drivers/spi/spi-mt7621.c
-@@ -0,0 +1,480 @@
+@@ -0,0 +1,483 @@
+/*
+ * spi-mt7621.c -- MediaTek MT7621 SPI controller driver
+ *
@@ -240,6 +240,9 @@ Signed-off-by: John Crispin <blogic@openwrt.org>
+ if (!buf)
+ continue;
+
++ if (t->speed_hz < speed)
++ speed = t->speed_hz;
++
+ if (WARN_ON(len + t->len > 36)) {
+ status = -EIO;
+ goto msg_done;