Overclocking Router Devices

There are other ways: [Solved] Archer C7 V2.0 Overclock

1 Like

or by crypto by ssh the speed on a remote computer

550/400/200/25

2K performance run parameters for coremark.
CoreMark Size    : 666
Total ticks      : 15859
Total time (secs): 15.859000
Iterations/Sec   : 1261.113563
Iterations       : 20000
Compiler version : GCC5.4.0
Compiler flags   : -O2 -s -static   -lrt
Memory location  : Please put data memory location here
			(e.g. code in flash, data on heap etc)
seedcrc          : 0xe9f5
[0]crclist       : 0xe714
[0]crcmatrix     : 0x1fd7
[0]crcstate      : 0x8e3a
[0]crcfinal      : 0x382f
Correct operation validated. See readme.txt for run and reporting rules.
CoreMark 1.0 : 1261.113563 / GCC5.4.0 -O2 -s -static   -lrt / Heap


root@OpenWrt:/tmp# ./membench_4.6MB
-------------------------------------------------------------
STREAM version $Revision: 5.10 $
-------------------------------------------------------------
This system uses 8 bytes per array element.
-------------------------------------------------------------
Array size = 200000 (elements), Offset = 0 (elements)
Memory per array = 1.5 MiB (= 0.0 GiB).
Total memory required = 4.6 MiB (= 0.0 GiB).
Each kernel will be executed 10 times.
 The *best* time for each kernel (excluding the first iteration)
 will be used to compute the reported bandwidth.
-------------------------------------------------------------
Your clock granularity/precision appears to be 2 microseconds.
Each test below will take on the order of 36169 microseconds.
   (= 18084 clock ticks)
Increase the size of the arrays if this shows that
you are not getting at least 20 clock ticks per test.
-------------------------------------------------------------
WARNING -- The above is only a rough guideline.
For best results, please be sure you know the
precision of your system timer.
-------------------------------------------------------------
Function    Best Rate MB/s  Avg time     Min time     Max time
Copy:             282.3     0.011371     0.011337     0.011414
Scale:             57.0     0.057871     0.056183     0.058757
Add:              115.9     0.043040     0.041421     0.047600
Triad:             48.8     0.098573     0.098299     0.100424
-------------------------------------------------------------
Solution Validates: avg error less than 1.000000e-13 on all three arrays
-------------------------------------------------------------

1000/600/200/25

root@OpenWrt:/tmp# ./coremark_mips32r2
2K performance run parameters for coremark.
CoreMark Size    : 666
Total ticks      : 13075
Total time (secs): 13.075000
Iterations/Sec   : 2294.455067
Iterations       : 30000
Compiler version : GCC5.4.0
Compiler flags   : -O2 -s -static   -lrt
Memory location  : Please put data memory location here
			(e.g. code in flash, data on heap etc)
seedcrc          : 0xe9f5
[0]crclist       : 0xe714
[0]crcmatrix     : 0x1fd7
[0]crcstate      : 0x8e3a
[0]crcfinal      : 0x5275
Correct operation validated. See readme.txt for run and reporting rules.
CoreMark 1.0 : 2294.455067 / GCC5.4.0 -O2 -s -static   -lrt / Heap


root@OpenWrt:/tmp# ./membench_4.6MB
-------------------------------------------------------------
STREAM version $Revision: 5.10 $
-------------------------------------------------------------
This system uses 8 bytes per array element.
-------------------------------------------------------------
Array size = 200000 (elements), Offset = 0 (elements)
Memory per array = 1.5 MiB (= 0.0 GiB).
Total memory required = 4.6 MiB (= 0.0 GiB).
Each kernel will be executed 10 times.
 The *best* time for each kernel (excluding the first iteration)
 will be used to compute the reported bandwidth.
-------------------------------------------------------------
Your clock granularity/precision appears to be 2 microseconds.
Each test below will take on the order of 21818 microseconds.
   (= 10909 clock ticks)
Increase the size of the arrays if this shows that
you are not getting at least 20 clock ticks per test.
-------------------------------------------------------------
WARNING -- The above is only a rough guideline.
For best results, please be sure you know the
precision of your system timer.
-------------------------------------------------------------
Function    Best Rate MB/s  Avg time     Min time     Max time
Copy:             393.4     0.008157     0.008134     0.008194
Scale:            101.6     0.032361     0.031483     0.032815
Add:              197.3     0.024987     0.024333     0.026276
Triad:             85.5     0.056369     0.056116     0.058242
-------------------------------------------------------------
Solution Validates: avg error less than 1.000000e-13 on all three arrays
-------------------------------------------------------------

Uptime: 5h 29m 32s

clock difference between router and my laptop was 3 seconds during this uptime period

kernel log:

[    0.000000] Linux version 4.4.14 (ubuntu@vivid) (gcc version 5.3.0 (OpenWrt GCC 5.3.0 49946) ) #20 Mon Oct 10 17:38:20 UTC 2016
[    0.000000] MyLoader: sysp=6ab65626, boardp=c036b504, parts=571bc521
[    0.000000] bootconsole [early0] enabled
[    0.000000] CPU0 revision is: 00019374 (MIPS 24Kc)
[    0.000000] SoC: Qualcomm Atheros QCA9533 ver 1 rev 1
[    0.000000] Determined physical RAM map:
[    0.000000]  memory: 02000000 @ 00000000 (usable)
[    0.000000] Initrd not found or empty - disabling initrd
[    0.000000] No valid device tree found, continuing without
[    0.000000] Zone ranges:
[    0.000000]   Normal   [mem 0x0000000000000000-0x0000000001ffffff]
[    0.000000] Movable zone start for each node
[    0.000000] Early memory node ranges
[    0.000000]   node   0: [mem 0x0000000000000000-0x0000000001ffffff]
[    0.000000] Initmem setup node 0 [mem 0x0000000000000000-0x0000000001ffffff]
[    0.000000] On node 0 totalpages: 8192
[    0.000000] free_area_init_node: node 0, pgdat 803b7710, node_mem_map 81000000
[    0.000000]   Normal zone: 64 pages used for memmap
[    0.000000]   Normal zone: 0 pages reserved
[    0.000000]   Normal zone: 8192 pages, LIFO batch:0
[    0.000000] Primary instruction cache 64kB, VIPT, 4-way, linesize 32 bytes.
[    0.000000] Primary data cache 32kB, 4-way, VIPT, cache aliases, linesize 32 bytes
[    0.000000] pcpu-alloc: s0 r0 d32768 u32768 alloc=1*32768
[    0.000000] pcpu-alloc: [0] 0 
[    0.000000] Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 8128
[    0.000000] Kernel command line:  board=TL-MR22U  console=ttyATH0,115200 rootfstype=squashfs,jffs2 noinitrd
[    0.000000] PID hash table entries: 128 (order: -3, 512 bytes)
[    0.000000] Dentry cache hash table entries: 4096 (order: 2, 16384 bytes)
[    0.000000] Inode-cache hash table entries: 2048 (order: 1, 8192 bytes)
[    0.000000] Writing ErrCtl register=00000000
[    0.000000] Readback ErrCtl register=00000000
[    0.000000] Memory: 28004K/32768K available (2678K kernel code, 142K rwdata, 712K rodata, 300K init, 193K bss, 4764K reserved, 0K cma-reserved)
[    0.000000] SLUB: HWalign=32, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
[    0.000000] NR_IRQS:51
[    0.000000] Clocks: CPU:1000.000MHz, DDR:600.000MHz, AHB:200.000MHz, Ref:25.000MHz
[    0.000000] clocksource: MIPS: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 3822520893 ns
[    0.000006] sched_clock: 32 bits at 500MHz, resolution 2ns, wraps every 4294967295ns
[    0.008823] Calibrating delay loop... 666.41 BogoMIPS (lpj=3332096)
[    0.071875] pid_max: default: 32768 minimum: 301
[    0.077192] Mount-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.084699] Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.094635] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
[    0.106342] NET: Registered protocol family 16
[    0.112392] MIPS: machine is TP-LINK TL-MR22U v1
[    0.346040] clocksource: Switched to clocksource MIPS
[    0.352748] NET: Registered protocol family 2
[    0.358283] TCP established hash table entries: 1024 (order: 0, 4096 bytes)
[    0.366230] TCP bind hash table entries: 1024 (order: 0, 4096 bytes)
[    0.373441] TCP: Hash tables configured (established 1024 bind 1024)
[    0.380729] UDP hash table entries: 256 (order: 0, 4096 bytes)
[    0.387382] UDP-Lite hash table entries: 256 (order: 0, 4096 bytes)
[    0.394715] NET: Registered protocol family 1
[    0.399708] PCI: CLS 0 bytes, default 32
[    0.400382] futex hash table entries: 256 (order: -1, 3072 bytes)
[    0.418483] squashfs: version 4.0 (2009/01/31) Phillip Lougher
[    0.425106] jffs2: version 2.2 (NAND) (SUMMARY) (LZMA) (RTIME) (CMODE_PRIORITY) (c) 2001-2006 Red Hat, Inc.
[    0.438099] io scheduler noop registered
[    0.442549] io scheduler deadline registered (default)
[    0.448569] Serial: 8250/16550 driver, 1 ports, IRQ sharing disabled
[    0.476219] serial8250.0: ttyS0 at MMIO 0x18020000 (irq = 11, base_baud = 1562500) is a 16550A
[    0.488100] m25p80 spi0.0: found w25q128, expected m25p80
[    0.494228] m25p80 spi0.0: w25q128 (16384 Kbytes)
[    0.500488] 5 tp-link partitions found on MTD device spi0.0
[    0.506845] Creating 5 MTD partitions on "spi0.0":
[    0.512275] 0x000000000000-0x000000020000 : "u-boot"
[    0.518962] 0x000000020000-0x00000014ae9c : "kernel"
[    0.525739] 0x00000014ae9c-0x000000ff0000 : "rootfs"
[    0.532556] mtd: device 2 (rootfs) set to be root filesystem
[    0.539085] 1 squashfs-split partitions found on MTD device rootfs
[    0.546100] 0x000000620000-0x000000ff0000 : "rootfs_data"
[    0.553359] 0x000000ff0000-0x000001000000 : "art"
[    0.559877] 0x000000020000-0x000000ff0000 : "firmware"
[    0.583951] libphy: ag71xx_mdio: probed
[    1.178947] ag71xx ag71xx.0: connected to PHY at ag71xx-mdio.1:04 [uid=004dd042, driver=Generic PHY]
[    1.189805] eth0: Atheros AG71xx at 0xb9000000, irq 4, mode:MII
[    1.197330] NET: Registered protocol family 17
[    1.202450] bridge: automatic filtering via arp/ip/ip6tables has been deprecated. Update your scripts to load br_netfilter if you need this.
[    1.216880] 8021q: 802.1Q VLAN Support v1.8
[    1.221991] bootconsole [early0] disabled
[    1.228272] Warning: unable to open an initial console.
[    1.232215] VFS: Mounted root (squashfs filesystem) readonly on device 31:2.
[    1.233647] Freeing unused kernel memory: 300K (803d5000 - 80420000)
[    2.010777] init: Console is alive
[    2.010946] init: - watchdog -
[    2.962769] usbcore: registered new interface driver usbfs
[    2.962830] usbcore: registered new interface driver hub
[    2.962913] usbcore: registered new device driver usb
[    2.966951] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[    2.968040] ehci-platform: EHCI generic platform driver
[    2.968116] ehci-platform ehci-platform: EHCI Host Controller
[    2.968141] ehci-platform ehci-platform: new USB bus registered, assigned bus number 1
[    2.970230] ehci-platform ehci-platform: irq 3, io mem 0x1b000000
[    2.986052] ehci-platform ehci-platform: USB 2.0 started, EHCI 1.00
[    2.986703] hub 1-0:1.0: USB hub found
[    2.986835] hub 1-0:1.0: 1 port detected
[    2.988907] ohci_hcd: USB 1.1 'Open' Host Controller (OHCI) Driver
[    2.989985] ohci-platform: OHCI generic platform driver
[    2.994246] init: - preinit -
[    3.458601] random: procd urandom read with 5 bits of entropy available
[    5.702846] jffs2: notice: (893) jffs2_build_xattr_subsystem: complete building xattr subsystem, 0 of xdatum (0 unchecked, 0 orphan) and 0 of xref (0 dead, 0 orphan) found.
[    5.704572] mount_root: switching to jffs2 overlay
[    5.735820] procd: - early -
[    5.735904] procd: - watchdog -
[    6.378946] procd: failed to set stdio
[    6.379008] procd: - ubus -
[    6.431080] procd: - init -
[    6.964513] l2tp_core: L2TP core driver, V2.0
[    6.965635] l2tp_netlink: L2TP netlink interface
[    6.967678] Netfilter messages via NETLINK v0.30.
[    6.969713] ip_set: protocol 6
[    6.998364] Loading modules backported from Linux version wt-2016-05-12-0-g7a54796
[    6.998379] Backport generated by backports.git backports-20160216-0-ge3c56e4
[    7.001334] ip_tables: (C) 2000-2006 Netfilter Core Team
[    7.010088] nf_conntrack version 0.5.0 (442 buckets, 1768 max)
[    7.050855] xt_time: kernel timezone is -0000
[    7.097931] PPP generic driver version 2.4.2
[    7.100009] NET: Registered protocol family 24
[    7.130150] l2tp_ppp: PPPoL2TP kernel driver, V2.0
[    7.141556] usbcore: registered new interface driver rt2800usb
[    7.150069] usbcore: registered new interface driver ath9k_htc
[    7.163105] ath: EEPROM regdomain: 0x0
[    7.163123] ath: EEPROM indicates default country code should be used
[    7.163128] ath: doing EEPROM country->regdmn map search
[    7.163144] ath: country maps to regdmn code: 0x3a
[    7.163151] ath: Country alpha2 being used: US
[    7.163156] ath: Regpair used: 0x3a
[    7.173330] ieee80211 phy0: Selected rate control algorithm 'minstrel_ht'
[    7.175747] ieee80211 phy0: Atheros AR9531 Rev:1 mem=0xb8100000, irq=47
[   11.328943] device eth0 entered promiscuous mode
[   12.249598] eth0: link up (100Mbps/Full duplex)
[   12.249649] br-lan: port 1(eth0) entered forwarding state
[   12.249696] br-lan: port 1(eth0) entered forwarding state
[   13.137809] device wlan0 entered promiscuous mode
[   13.137868] br-lan: port 2(wlan0) entered forwarding state
[   13.137901] br-lan: port 2(wlan0) entered forwarding state
[   13.143260] br-lan: port 2(wlan0) entered disabled state
[   14.246044] br-lan: port 1(eth0) entered forwarding state
[   15.699240] br-lan: port 2(wlan0) entered forwarding state
[   15.699299] br-lan: port 2(wlan0) entered forwarding state
[   17.696049] br-lan: port 2(wlan0) entered forwarding state
[   45.786077] random: nonblocking pool is initialized
[  289.268101] eth0: link down
[  289.268176] br-lan: port 1(eth0) entered disabled state
[19711.269525] eth0: link up (100Mbps/Full duplex)
[19711.269579] br-lan: port 1(eth0) entered forwarding state
[19711.269637] br-lan: port 1(eth0) entered forwarding state
[19713.266049] br-lan: port 1(eth0) entered forwarding state

done:

| Qualcomm Atheros QCA9533 ver 1 rev 1 | TP-LINK TL-MR22U v1 | MIPS 24Kc V7.4 | 666.41 | 1.0.2j | 53525350 | 47780940 | 24179760 | 7474510 | 7935140 | 2840830 | 13558580 | 11783900 | 10354730 | 11.2 | 426.4 37.6 | 33.5 |

type             16 bytes     64 bytes    256 bytes   1024 bytes   8192 bytes
md5               2492.10k     8852.93k    26613.09k    53525.35k    75699.03k
sha1              3085.10k    10279.83k    27590.87k    47780.94k    60368.74k
des cbc           7540.07k     7836.45k     7912.71k     7935.14k     7934.46k
des ede3          2783.66k     2827.17k     2838.09k     2840.83k     2843.91k
aes-128 cbc      11880.81k    13101.10k    13456.35k    13558.58k    13626.76k
aes-192 cbc      10464.21k    11403.64k    11667.35k    11783.90k    11798.68k
aes-256 cbc       9349.46k    10092.50k    10295.14k    10354.73k    10359.18k
sha256            4844.18k    11164.10k    19585.97k    24179.76k    25945.90k
sha512            1000.03k     3981.68k     5537.07k     7474.51k     8296.11k
                  sign    verify    sign/s verify/s
rsa 2048 bits 0.089196s 0.002345s     11.2    426.4
                  sign    verify    sign/s verify/s
dsa 2048 bits 0.026595s 0.029850s     37.6     33.5

@psyborg I confirmed your CPU clock with a scope. There is also MikroTik hEX lite (RB750r2, QCA9533 based) which runs by default with CPU @ 850 MHz and allows setting up to 1000 MHz.

1 Like

u-boot was actually capable of starting at 1100MHz, but would not boot firmware. maybe the clock drift issue described in Archer C7 V2.0 Overclock thread is the cause of this.. i've also tried 1200MHz and u-boot hangs there.

I was able to run 1 GHz only on one from two QCA9531 based devices I tried (didn't have more time).

Ok. 1050MHz is max at which device is stable without heatsinks or fans. RAM max at 625MHz (might do better if i manage to replace it for 64M one). Do you know if there is a way to set SPI clock independently on AHB clock? I found that device won't boot at 40MHz but boots fine at 37.5MHz (AHB300/8) but i want to use AHB @ 200. Maybe derive it from CPU clock?

Derive it from CPU/5, at 1050MHz you'll get 210MHz AHB. Maybe BREED is an option for quick changes, then settle with optimal clocks from u-boot.

@gwlim
I have a netgear 4300 v1,how to overclock it,thanks

where could i find safe clocks values for tplink wdr4300?
my understanding if i use values to high i will brick router.
i looked at pepe2k setclk method but it says wdr4300 not supported by setclk

The doc says, but this is outdated...
On my WDR4300 i have 750 MHz.

The set clock with setclk is applied only if the reset button isn't pressed... So if you set a to high clock, start with reset button pressed, your router does not use the stored clock settings and use 400 for cpu.
At the moment i dont know the safe default values for ddr, ahb and spi...

1 Like

Thanks for sharing this helpful information about overclocking router devices. Maybe I should also try these tips and see if it will improve the performance of my device.

Is there way to overclock older Broadcom bcm47xx routers? Such as Asus RT-N16?
In DD-WRT there was command nvram set clkfreq

Routers with 9344 cannot be oveclocked with pepe2k uboot, just found setclk is missing, you probably overclocked WDR4300 with some other uboot

actually they can be overclocked by editing the uboot with a hex editor...

that is whole point i do not want hex editor, he said can be oc with pepe uboot but cant for routers with AR9344 because setclk is missing

Breed boot loader should be able to do it.

ALCON/FYI,

Instructions for Netgear R7000 are identical to DD-WRT/Tomato firmware after installing an additional package for OpenWRT. Once committed to nvram, there is no need to add anything to boot/startup options.

1. opkg update && opkg install nvram
2. nvram show clkfreq && cat /proc/cpuinfo | grep Bogo 

The default is cpu=1000MHZ ram=800MHZ

3. nvram set clkfreq=1200,800 
4. nvram commit && reboot

Available options: 1000,800 1000,1066 1200,800 1200,1066 1400,800 1400,1066

DO NOT GO OVER 1400,1066. YOU WILL LOCK UP YOUR ROUTER

I`ve the setclk uboot cmd on my TL-WDR4300 and TL-WDR3600 and this two devices have a ar9344 chipset.
I´ve also can oc my TL-WR841v8 which has the very similar ar9341 chipset
I use a self compiled version of pepe2k´s great uboot mod.

When did you tried pepe2k´s uboot mod?
I think he added support for ar934x a bit later...