summaryrefslogtreecommitdiff
path: root/target/linux/brcm63xx/patches-3.14
diff options
context:
space:
mode:
authorJonas Gorski <jogo@openwrt.org>2014-04-05 18:32:34 +0000
committerJonas Gorski <jogo@openwrt.org>2014-04-05 18:32:34 +0000
commit663083d930549e783e5e992b233409929ffd2353 (patch)
tree091178d72cd1b8b4e465aeffc2700609c1c04cd8 /target/linux/brcm63xx/patches-3.14
parent6d3672b13bebd89a4639bf7f4079c90d81c29d31 (diff)
downloadmtk-20170518-663083d930549e783e5e992b233409929ffd2353.zip
mtk-20170518-663083d930549e783e5e992b233409929ffd2353.tar.gz
mtk-20170518-663083d930549e783e5e992b233409929ffd2353.tar.bz2
brcm63xx: sync mips counters during bringup of cpus
Fixes gettimeofday returning different values depending on which cpu it is called. Signed-off-by: Jonas Gorski <jogo@openwrt.org> SVN-Revision: 40387
Diffstat (limited to 'target/linux/brcm63xx/patches-3.14')
-rw-r--r--target/linux/brcm63xx/patches-3.14/101-MIPS-BCM63XX-sync-mips-counter-during-cpu-bringup.patch27
1 files changed, 27 insertions, 0 deletions
diff --git a/target/linux/brcm63xx/patches-3.14/101-MIPS-BCM63XX-sync-mips-counter-during-cpu-bringup.patch b/target/linux/brcm63xx/patches-3.14/101-MIPS-BCM63XX-sync-mips-counter-during-cpu-bringup.patch
new file mode 100644
index 0000000..f303c61
--- /dev/null
+++ b/target/linux/brcm63xx/patches-3.14/101-MIPS-BCM63XX-sync-mips-counter-during-cpu-bringup.patch
@@ -0,0 +1,27 @@
+From 23c21090f49a64b532755542a71e9aa3e4fc84d9 Mon Sep 17 00:00:00 2001
+From: Jonas Gorski <jogo@openwrt.org>
+Date: Sat, 5 Apr 2014 20:07:25 +0200
+Subject: [PATCH] MIPS: BCM63XX: sync mips counter during cpu bringup
+
+We are using the mips counters as the clock source, so we need to ensure
+they are synced, else e.g. gettimeofday will return different values
+depending on which core it was run.
+
+Observed difference was about 8 seconds, causing ~8 seconds ping or time
+running backwards for some programs.
+
+Signed-off-by: Jonas Gorski <jogo@openwrt.org>
+---
+ arch/mips/Kconfig | 1 +
+ 1 file changed, 1 insertion(+)
+
+--- a/arch/mips/Kconfig
++++ b/arch/mips/Kconfig
+@@ -132,6 +132,7 @@ config BCM63XX
+ select BOOT_RAW
+ select CEVT_R4K
+ select CSRC_R4K
++ select SYNC_R4K
+ select DMA_NONCOHERENT
+ select IRQ_CPU
+ select SYS_SUPPORTS_32BIT_KERNEL