<prefixcactus>
I decided to just extract the dram_para block from the fex and convert it into a uboot C file. Where do I now plug that file in order to compile those settings in?
afaerber has joined #linux-sunxi
afaerber has quit [Remote host closed the connection]
afaerber has joined #linux-sunxi
afaerber has quit [Remote host closed the connection]
afaerber has joined #linux-sunxi
afaerber has quit [Remote host closed the connection]
afaerber has joined #linux-sunxi
afaerber has quit [Remote host closed the connection]
abelvesa has quit [Remote host closed the connection]
ldevulder_ is now known as ldevulder
lucascastro has joined #linux-sunxi
Mangy_Dog has joined #linux-sunxi
apritzel has joined #linux-sunxi
afaerber has joined #linux-sunxi
<apritzel>
prefixcactus: can you send a dump of the other DRAM controller register regions as well?
<apritzel>
prefixcactus: just a dump, don't need to match them to this struct
<apritzel>
prefixcactus: so: md.l 0x01c62000 80
afaerber has quit [Remote host closed the connection]
afaerber has joined #linux-sunxi
afaerber has quit [Remote host closed the connection]
<prefixcactus>
Still zero errors across the whole gig
<prefixcactus>
So it seems that DRAM works fine
<prefixcactus>
(at least for the purpose of writing individual u32's
matthias_bgg has quit [Ping timeout: 272 seconds]
reinforce has quit [Quit: Leaving.]
lucascastro has joined #linux-sunxi
prefixcactus has quit [Quit: No Ping reply in 180 seconds.]
matthias_bgg has joined #linux-sunxi
lucascastro has quit [Remote host closed the connection]
prefixcactus has joined #linux-sunxi
lucascastro has joined #linux-sunxi
<apritzel>
prefixcactus: so this is with this "panic on R40 dual rank" code commented out?
<prefixcactus>
Yep.
lucascastro has quit [Ping timeout: 246 seconds]
<apritzel>
prefixcactus: what is your memtest like? Do you write a different value to each u32?
<prefixcactus>
No, I populate the whole memory with the same value and then read it back sequentially.
<apritzel>
I am asking because I think we need to write *something* to that "cr_r1" register that you commented
<prefixcactus>
(and then repeat the same for 6 other values)
<apritzel>
so I had once some test which tries to find aliasing, so I used one magic value, XORed with the particular address you write that value into
<apritzel>
so that each u32 contains a (somewhat) unique value, which you can verify
<prefixcactus>
sounds like a good idea. I'll try that
<apritzel>
and also you can find out where a particular value comes from, if it appears out of place
<apritzel>
from my shallow understanding of this R40 dual rank circuitry, we would need to write the same(?) CR value that we write into offset 0 also into offset 4
<apritzel>
but it probably need a few bits set differently
AndroUkeie has joined #linux-sunxi
AndroUkeie has quit [Read error: Connection reset by peer]
lucascastro has joined #linux-sunxi
AndroUkeie has joined #linux-sunxi
AndroUkeie has quit [Read error: Connection reset by peer]
AndroUkeie has joined #linux-sunxi
cmeerw has joined #linux-sunxi
AndroUkeie has quit [Read error: Connection reset by peer]
lucascastro has quit [Ping timeout: 264 seconds]
<prefixcactus>
apritzel: it's running, but slowly...
<prefixcactus>
so far no errors over magic 00000000 (e.g. address written to memory as is)
AndroUkeie has joined #linux-sunxi
AndroUkeie has quit [Read error: Connection reset by peer]
sunshavi has quit [Quit: nil]
<apritzel>
0 is not a good magic ;-) try 0x55aa31ce or something like that
<prefixcactus>
there's more on the way
sunshavi has joined #linux-sunxi
<prefixcactus>
all ones (ffffffff) is fine too, now doing 55555555
lucascastro has joined #linux-sunxi
matthias_bgg has quit [Ping timeout: 256 seconds]
AndroUkeie has joined #linux-sunxi
AndroUkeie has quit [Read error: Connection reset by peer]
<karlp>
I'm trying https://linux-sunxi.org/FEL#Through_serial_console to take a "factory" friendlyarm neo core to fel mode, and it just hangs after "go 0xffff0020" and I don't see any usb device turn up.
<karlp>
is there a different address for h3 or anything?
vagrantc has quit [Quit: leaving]
<apritzel>
karlp: not sure that works reliably from U-Boot
<apritzel>
karlp: this branches into the FEL routine, but the system is not in the same state as after reset: clocks are different, system registers are different, etc
<karlp>
yeah, Iwas honeslty kinda curious that "go" would be sufficient :)
<apritzel>
karlp: the most reliable way to enter FEL mode without the dedicated FEL button is and SD card with that "magic" FEL code
<karlp>
yeah, was hoping to come up with something that didn't need to insert a card :)
<apritzel>
which essentially is the equivalent of "go 0xffff0020", but from a much more controlled state
<karlp>
I _could_ feasibly let it boot the "factory" ubuntu 16.x and write something to trash the headers on emmc?
<apritzel>
karlp: yes, that would be the other way
<karlp>
the time of booting is certainly easier than inserting and removing special sd cards.
<apritzel>
you can just backup sector 16, then replace it with something (could be zeroes)
<apritzel>
a nicer way would be to read sector 16, replace bytes 0xc-0xf in there with zeroes, then write it back
<apritzel>
that would just zero the checksum, which you can re-calculate easily
<apritzel>
so you can re-activate this later on
fl_0 has quit [Ping timeout: 258 seconds]
<karlp>
where are the docs on this sector 16? I'm lost on the wiki
<karlp>
I guess I could in the future interrupt uboot and just use tftp to reflash emmc too I suppose
fl_0 has joined #linux-sunxi
<apritzel>
sector 16 is the first sector of the eGON image, the first 20 bytes are the crucial information in this image for the BootROM to recognise this as a bootable image
<apritzel>
karlp: yes, if U-Boot and TFTP work for you
<apritzel>
(AFAIK the BSP U-Boots don't support network)
<karlp>
hrm, don't have a baseboard working for this yet, was hoping to use fel mode.
<apritzel>
or you can write the "go-to-FEL" SD card image into the eMMC boot partition (sector 0 this time), which takes precedence over normal eMMC partitions
<karlp>
I only have mmcblk0, fwiw.
<apritzel>
is that the eMMC?
<apritzel>
whatever Linux names the eMMC block device ...
<karlp>
yeah, presumably, there's no sdcard installed
<karlp>
qok, that's ok, it has eGON.BT0 in the first line.
<apritzel>
yes, that's the indication that you got the right sector
<apritzel>
if you can back this up(!) somewhere, then just write zeroes back: dd if=/dev/zero of=/dev/mmcblk0 seek=16 count=1
<karlp>
yooooolo, like I need a backup ;)
<apritzel>
(or even better edit this file as I explained above to just clear the checksum)
<karlp>
yeah, I was just poking how to do the ehxedit with the onboard tools
<apritzel>
I know, that's tricky
<karlp>
printf with head and cat came to mind, but... meh
<apritzel>
"od" is typically available (part of busybox), but it needs some UNIX trickery to turn it into an editor
<karlp>
meh, now it boots uboot sufficiently
<apritzel>
via FEL?
<karlp>
ah well, was worth a shot.
<karlp>
no, now it just gets stuck in uboot
<karlp>
failes to boot further.
<apritzel>
they might have a backup boot0 at sector 256 ;-)
<karlp>
hah
<karlp>
don't hve dd anymore ;)
<karlp>
mmc write should work....
<apritzel>
yeah. Do you have a U-Boot prompt?
<karlp>
yeah.
<apritzel>
mmc read 0x50000000 10 1
<apritzel>
md.l 0x50000000 8
<karlp>
hrm, still says eGON.BT0
<karlp>
is that 256?
<apritzel>
for the backup boot0: mmc read 0x50000000 100 1
<apritzel>
(confusingly U-Boot defaults to hex, even without the 0x prefix)
<karlp>
ok, block 256 doesn't have egon tag, block 16 does, so it didn't properly erase?
<karlp>
oops, mmc erase 16 1 has... got me no longer to uboot, but still no fel :) guess I'll get an sd card to recover this one then...
<karlp>
thanks for your help, very informative
gaston1980 has joined #linux-sunxi
matthias_bgg has joined #linux-sunxi
<apritzel>
karlp: FEL is picky about power and reset, so it sometimes help to completely remove all cables (including serial and USB), then power on from there
damex has joined #linux-sunxi
<karlp>
yeah, tired that, it' s_only_ got the microusb cable now, but no go. not a big deal, was a good exploration for the afternoon.
damex has quit [Read error: Connection reset by peer]
damex has joined #linux-sunxi
pmp-p has quit [Disconnected by services]
matthias_bgg has quit [Ping timeout: 246 seconds]
pmp-p has joined #linux-sunxi
damex has quit [Read error: Connection reset by peer]
damex has joined #linux-sunxi
damex has quit [Read error: Connection reset by peer]
damex has joined #linux-sunxi
Guest18038 has quit [Quit: WeeChat 3.0]
pmp-p has quit [Quit: pmp-p]
damex has quit [Read error: Connection reset by peer]
damex has joined #linux-sunxi
AndroUkeie has joined #linux-sunxi
AndroUkeie has quit [Read error: Connection reset by peer]
damex has quit [Read error: Connection reset by peer]
damex has joined #linux-sunxi
matthias_bgg has joined #linux-sunxi
AndroUkeie has joined #linux-sunxi
AndroUkeie has quit [Read error: Connection reset by peer]
pmp-p has joined #linux-sunxi
damex has quit [Read error: Connection reset by peer]
damex has joined #linux-sunxi
matteo has joined #linux-sunxi
matteo is now known as Guest21414
diego71 has quit [Ping timeout: 265 seconds]
damex has quit [Read error: Connection reset by peer]
damex has joined #linux-sunxi
damex has quit [Read error: Connection reset by peer]
damex has joined #linux-sunxi
gaston1980 has quit [Quit: Konversation terminated!]
arnd has quit [Read error: Connection reset by peer]
lvrp16 has quit [Read error: Connection reset by peer]
arnd has joined #linux-sunxi
lvrp16 has joined #linux-sunxi
AndroUkeie has joined #linux-sunxi
AndroUkeie has quit [Read error: Connection reset by peer]
pCactus has joined #linux-sunxi
<pCactus>
apritzel: no errors still, with 8 different values
<pCactus>
maybe I should throw some debug prints around the MMC detection code tomorrow
pCactus has quit [Read error: Connection reset by peer]
pCactus has joined #linux-sunxi
lucascastro has quit [Ping timeout: 272 seconds]
pCactus has quit [Ping timeout: 246 seconds]
pCactus has joined #linux-sunxi
pCactus has quit [Read error: Connection reset by peer]
pCactus has joined #linux-sunxi
pCactus has quit [Read error: Connection reset by peer]
pCactus has joined #linux-sunxi
lucascastro has joined #linux-sunxi
lucascastro has quit [Remote host closed the connection]
pCactus has quit [Read error: Connection reset by peer]