This is a DRAM tuning/overclocking stability report for various Allwinner A10/A13/A20 based devices.It can be automatically generated by the tools from https://github.com/ssvb/a10-meminfo. Here we primarily focus on finding optimal dram_tpr3 values, tuned individually for every sunxi device. Currently these values need to be hardcoded into the sources of the u-boot-sunxi bootloader. The dram_tpr3 parameter is just a hexadecimal number with the following bit fields:

The RK30XX manual can be checked for more details about the MFWDLY, MFBDLY and SDPHASE bit fields. The Rockchip 30XX family of SoCs is apparently using the same DRAM controller IP.

Results interpretation:

Cubieboard1, dram_clk=540MHz

dcdc3_vol = 1250
dram_clk = 540
dram_type = 3
dram_rank_num = 1
dram_chip_density = 4096
dram_io_width = 16
dram_bus_width = 32
dram_cas = 9
dram_zq = 0x7f
dram_odt_en = 0
dram_tpr0 = 0x42d899b7
dram_tpr1 = 0xa090
dram_tpr2 = 0x22a00
dram_tpr3 = 0x0
dram_emr1 = 0x4
dram_emr2 = 0x10
dram_emr3 = 0x0
mfxdlyphase=36phase=54phase=72phase=90phase=108phase=126
0x070x0733330x0722220x0711110x0700000x07EEEE0x07DDDD
0x060x0633330x0622220x0611110x0600000x06EEEE0x06DDDD
0x050x0533330x0522220x0511110x0500000x05EEEE0x05DDDD
0x040x0433330x0422220x0411110x0400000x04EEEE0x04DDDD
0x030x0333330x0322220x0311110x0300000x03EEEE0x03DDDD
0x020x0233330x0222220x0211110x0200000x02EEEE0x02DDDD
0x010x0133330x0122220x0111110x0100000x01EEEE0x01DDDD
0x000x0033330x0022220x0011110x0000000x00EEEE0x00DDDD
0x080x0833330x0822220x0811110x0800000x08EEEE0x08DDDD
0x100x1033330x1022220x1011110x1000000x10EEEE0x10DDDD
0x180x1833330x1822220x1811110x1800000x18EEEE0x18DDDD
0x200x2033330x2022220x2011110x2000000x20EEEE0x20DDDD
0x280x2833330x2822220x2811110x2800000x28EEEE0x28DDDD
0x300x3033330x3022220x3011110x3000000x30EEEE0x30DDDD
0x380x3833330x3822220x3811110x3800000x38EEEE0x38DDDD
Lane phase adjustments: [0, 0, 0, 0]

Error statistics from memtester: [solidbits=17, bitflip=13, bitspread=11]

Best number of successful memtester runs, which span over 1 columns (3-3): 60
Best number of successful memtester runs, which span over 2 columns (2-3): 96
Best number of successful memtester runs, which span over 3 columns (1-3): 122
Best number of successful memtester runs, which span over 4 columns (1-4): 131
Best number of successful memtester runs, which span over 5 columns (1-5): 131
Best number of successful memtester runs, which span over 6 columns (0-5): 131

Errors per lane: [20, 14, 27, 22]. Lane 1 is the most noisy/problematic.

Errors from the lane 0 are 63.6% eclipsed by the worst lane 1.
Errors from the lane 2 are 100.0% eclipsed by the worst lane 1.
Errors from the lane 3 are 70.0% eclipsed by the worst lane 1.
dcdc3_vol = 1250
dram_clk = 540
dram_type = 3
dram_rank_num = 1
dram_chip_density = 4096
dram_io_width = 16
dram_bus_width = 32
dram_cas = 9
dram_zq = 0x7f
dram_odt_en = 0
dram_tpr0 = 0x42d899b7
dram_tpr1 = 0xa090
dram_tpr2 = 0x22a00
dram_tpr3 = 0x0
dram_emr1 = 0x4
dram_emr2 = 0x10
dram_emr3 = 0x0
mfxdlyphase=36phase=54phase=72phase=90phase=108phase=126
0x070x0722320x0711210x0700100x07EE0E0x07DDED
0x060x0622320x0611210x0600100x06EE0E0x06DDED
0x050x0522320x0511210x0500100x05EE0E0x05DDED
0x040x0422320x0411210x0400100x04EE0E0x04DDED
0x030x0322320x0311210x0300100x03EE0E0x03DDED
0x020x0222320x0211210x0200100x02EE0E0x02DDED
0x010x0122320x0111210x0100100x01EE0E0x01DDED
0x000x0022320x0011210x0000100x00EE0E0x00DDED
0x080x0822320x0811210x0800100x08EE0E0x08DDED
0x100x1022320x1011210x1000100x10EE0E0x10DDED
0x180x1822320x1811210x1800100x18EE0E0x18DDED
0x200x2022320x2011210x2000100x20EE0E0x20DDED
0x280x2822320x2811210x2800100x28EE0E0x28DDED
0x300x3022320x3011210x3000100x30EE0E0x30DDED
0x380x3822320x3811210x3800100x38EE0E0x38DDED
Lane phase adjustments: [1, 1, 0, 1]

Error statistics from memtester: [solidbits=13, bitflip=10, bitspread=9]

Best number of successful memtester runs, which span over 1 columns (2-2): 18
Best number of successful memtester runs, which span over 2 columns (1-2): 36
Best number of successful memtester runs, which span over 3 columns (1-3): 39
Best number of successful memtester runs, which span over 4 columns (0-3): 42
Best number of successful memtester runs, which span over 5 columns (0-4): 42

Errors per lane: [16, 10, 19, 14]. Lane 1 is the most noisy/problematic.

Errors from the lane 0 are 64.3% eclipsed by the worst lane 1.
Errors from the lane 2 are 90.0% eclipsed by the worst lane 1.
Errors from the lane 3 are 56.2% eclipsed by the worst lane 1.
dcdc3_vol = 1250
dram_clk = 540
dram_type = 3
dram_rank_num = 1
dram_chip_density = 4096
dram_io_width = 16
dram_bus_width = 32
dram_cas = 9
dram_zq = 0x7f
dram_odt_en = 0
dram_tpr0 = 0x42d899b7
dram_tpr1 = 0xa090
dram_tpr2 = 0x22a00
dram_tpr3 = 0x0
dram_emr1 = 0x4
dram_emr2 = 0x10
dram_emr3 = 0x0
mfxdlyphase=36phase=54phase=72phase=90phase=108phase=126
0x070x0711310x0700200x07EE1E0x07DD0D
0x060x0611310x0600200x06EE1E0x06DD0D
0x050x0511310x0500200x05EE1E0x05DD0D
0x040x0411310x0400200x04EE1E0x04DD0D
0x030x0311310x0300200x03EE1E0x03DD0D
0x020x0211310x0200200x02EE1E0x02DD0D
0x010x0111310x0100200x01EE1E0x01DD0D
0x000x0011310x0000200x00EE1E0x00DD0D
0x080x0811310x0800200x08EE1E0x08DD0D
0x100x1011310x1000200x10EE1E0x10DD0D
0x180x1811310x1800200x18EE1E0x18DD0D
0x200x2011310x2000200x20EE1E0x20DD0D
0x280x2811310x2800200x28EE1E0x28DD0D
0x300x3011310x3000200x30EE1E0x30DD0D
0x380x3811310x3800200x38EE1E0x38DD0D
Lane phase adjustments: [2, 2, 0, 2]

Error statistics from memtester: [solidbits=14, bitspread=11, bitflip=3]

Best number of successful memtester runs, which span over 1 columns (1-1): 37
Best number of successful memtester runs, which span over 2 columns (0-1): 43
Best number of successful memtester runs, which span over 3 columns (0-2): 45
Best number of successful memtester runs, which span over 4 columns (0-3): 45

Errors per lane: [7, 2, 14, 11]. Lane 1 is the most noisy/problematic.

Errors from the lane 0 are 18.2% eclipsed by the worst lane 1.
Errors from the lane 2 are 100.0% eclipsed by the worst lane 1.
Errors from the lane 3 are 28.6% eclipsed by the worst lane 1.
dcdc3_vol = 1250
dram_clk = 540
dram_type = 3
dram_rank_num = 1
dram_chip_density = 4096
dram_io_width = 16
dram_bus_width = 32
dram_cas = 9
dram_zq = 0x7f
dram_odt_en = 0
dram_tpr0 = 0x42d899b7
dram_tpr1 = 0xa090
dram_tpr2 = 0x22a00
dram_tpr3 = 0x0
dram_emr1 = 0x4
dram_emr2 = 0x10
dram_emr3 = 0x0
mfxdlyphase=36phase=54phase=72phase=90phase=108phase=126
0x070x0733230x0722120x0711010x0700E00x07EEDE
0x060x0633230x0622120x0611010x0600E00x06EEDE
0x050x0533230x0522120x0511010x0500E00x05EEDE
0x040x0433230x0422120x0411010x0400E00x04EEDE
0x030x0333230x0322120x0311010x0300E00x03EEDE
0x020x0233230x0222120x0211010x0200E00x02EEDE
0x010x0133230x0122120x0111010x0100E00x01EEDE
0x000x0033230x0022120x0011010x0000E00x00EEDE
0x080x0833230x0822120x0811010x0800E00x08EEDE
0x100x1033230x1022120x1011010x1000E00x10EEDE
0x180x1833230x1822120x1811010x1800E00x18EEDE
0x200x2033230x2022120x2011010x2000E00x20EEDE
0x280x2833230x2822120x2811010x2800E00x28EEDE
0x300x3033230x3022120x3011010x3000E00x30EEDE
0x380x3833230x3822120x3811010x3800E00x38EEDE
Lane phase adjustments: [-1, -1, 0, -1]

Error statistics from memtester: [bitspread=22, bitflip=10]

Best number of successful memtester runs, which span over 1 columns (0-0): 29
Best number of successful memtester runs, which span over 2 columns (0-1): 43
Best number of successful memtester runs, which span over 3 columns (0-2): 61
Best number of successful memtester runs, which span over 4 columns (0-3): 66
Best number of successful memtester runs, which span over 5 columns (0-4): 66

Errors per lane: [7, 7, 27, 12]. Lane 1 is the most noisy/problematic.

Errors from the lane 0 are 58.3% eclipsed by the worst lane 1.
Errors from the lane 2 are 100.0% eclipsed by the worst lane 1.
Errors from the lane 3 are 100.0% eclipsed by the worst lane 1.
dcdc3_vol = 1250
dram_clk = 540
dram_type = 3
dram_rank_num = 1
dram_chip_density = 4096
dram_io_width = 16
dram_bus_width = 32
dram_cas = 9
dram_zq = 0x7f
dram_odt_en = 0
dram_tpr0 = 0x42d899b7
dram_tpr1 = 0xa090
dram_tpr2 = 0x22a00
dram_tpr3 = 0x0
dram_emr1 = 0x4
dram_emr2 = 0x10
dram_emr3 = 0x0
mfxdlyphase=36phase=54phase=72phase=90phase=108phase=126
0x070x0733130x0722020x0711E10x0700D0
0x060x0633130x0622020x0611E10x0600D0
0x050x0533130x0522020x0511E10x0500D0
0x040x0433130x0422020x0411E10x0400D0
0x030x0333130x0322020x0311E10x0300D0
0x020x0233130x0222020x0211E10x0200D0
0x010x0133130x0122020x0111E10x0100D0
0x000x0033130x0022020x0011E10x0000D0
0x080x0833130x0822020x0811E10x0800D0
0x100x1033130x1022020x1011E10x1000D0
0x180x1833130x1822020x1811E10x1800D0
0x200x2033130x2022020x2011E10x2000D0
0x280x2833130x2822020x2811E10x2800D0
0x300x3033130x3022020x3011E10x3000D0
0x380x3833130x3822020x3811E10x3800D0
Lane phase adjustments: [-2, -2, 0, -2]

Error statistics from memtester: [bitspread=17, bitflip=12, solidbits=1]

Best number of successful memtester runs, which span over 1 columns (1-1): 20
Best number of successful memtester runs, which span over 2 columns (0-1): 38
Best number of successful memtester runs, which span over 3 columns (0-2): 40
Best number of successful memtester runs, which span over 4 columns (0-3): 40

Errors per lane: [8, 8, 29, 7]. Lane 1 is the most noisy/problematic.

Errors from the lane 0 are 100.0% eclipsed by the worst lane 1.
Errors from the lane 2 are 87.5% eclipsed by the worst lane 1.
Errors from the lane 3 are 87.5% eclipsed by the worst lane 1.
dcdc3_vol = 1250
dram_clk = 540
dram_type = 3
dram_rank_num = 1
dram_chip_density = 4096
dram_io_width = 16
dram_bus_width = 32
dram_cas = 9
dram_zq = 0x7f
dram_odt_en = 0
dram_tpr0 = 0x42d899b7
dram_tpr1 = 0xa090
dram_tpr2 = 0x22a00
dram_tpr3 = 0x0
dram_emr1 = 0x4
dram_emr2 = 0x10
dram_emr3 = 0x0
mfxdlyphase=36phase=54phase=72phase=90phase=108phase=126
0x070x0721130x0710020x070EE10x07EDD0
0x060x0621130x0610020x060EE10x06EDD0
0x050x0521130x0510020x050EE10x05EDD0
0x040x0421130x0410020x040EE10x04EDD0
0x030x0321130x0310020x030EE10x03EDD0
0x020x0221130x0210020x020EE10x02EDD0
0x010x0121130x0110020x010EE10x01EDD0
0x000x0021130x0010020x000EE10x00EDD0
0x080x0821130x0810020x080EE10x08EDD0
0x100x1021130x1010020x100EE10x10EDD0
0x180x1821130x1810020x180EE10x18EDD0
0x200x2021130x2010020x200EE10x20EDD0
0x280x2821130x2810020x280EE10x28EDD0
0x300x3021130x3010020x300EE10x30EDD0
0x380x3821130x3810020x380EE10x38EDD0
Lane phase adjustments: [-1, 0, 0, -2]

Error statistics from memtester: [bitspread=18, bitflip=15, solidbits=3]

Best number of successful memtester runs, which span over 1 columns (1-1): 20
Best number of successful memtester runs, which span over 2 columns (0-1): 35
Best number of successful memtester runs, which span over 3 columns (0-2): 41
Best number of successful memtester runs, which span over 4 columns (0-3): 41

Errors per lane: [13, 13, 36, 13]. Lane 1 is the most noisy/problematic.

Errors from the lane 0 are 100.0% eclipsed by the worst lane 1.
Errors from the lane 2 are 100.0% eclipsed by the worst lane 1.
Errors from the lane 3 are 100.0% eclipsed by the worst lane 1.