Sensu_Be1 has quit [Read error: Connection reset by peer]
radxanaoki has joined #linux-sunxi
Sensu_Be1 has joined #linux-sunxi
Sensu_Bean has quit [Read error: No route to host]
Sensu_Bean has joined #linux-sunxi
Sensu_Be1 has quit [Read error: Connection reset by peer]
Sensu_Be1 has joined #linux-sunxi
Sensu_Bean has quit [Ping timeout: 480 seconds]
apritzel has quit [Ping timeout: 480 seconds]
cnxsoft has joined #linux-sunxi
cnxsoft has quit [Ping timeout: 480 seconds]
ftg^ has quit [Read error: Connection reset by peer]
cnxsoft has joined #linux-sunxi
gsz has joined #linux-sunxi
gsz has quit [Ping timeout: 480 seconds]
hexdump0815 has joined #linux-sunxi
hexdump01 has quit [Ping timeout: 480 seconds]
parthiban has joined #linux-sunxi
wingrime1 has quit []
wingrime-ww has joined #linux-sunxi
junari has joined #linux-sunxi
junari has quit [Remote host closed the connection]
junari has joined #linux-sunxi
dfas has joined #linux-sunxi
sdfgsdfs has quit [Ping timeout: 480 seconds]
evgeny_boger has joined #linux-sunxi
apritzel has joined #linux-sunxi
Sensu_Bean has joined #linux-sunxi
Sensu_Be1 has quit [Read error: Connection reset by peer]
apritzel has quit [Ping timeout: 480 seconds]
warpme has joined #linux-sunxi
dfas has quit [Ping timeout: 480 seconds]
parthiban has quit [Ping timeout: 480 seconds]
parthiban has joined #linux-sunxi
parthi has joined #linux-sunxi
parthiban has quit [Read error: No route to host]
parthiban has joined #linux-sunxi
Schimsalabim has quit [Ping timeout: 480 seconds]
Schimsalabim has joined #linux-sunxi
parthi has quit [Ping timeout: 480 seconds]
parthiban has quit [Ping timeout: 480 seconds]
Schimsalabim has quit [Read error: Connection reset by peer]
Schimsalabim has joined #linux-sunxi
parthiban has joined #linux-sunxi
parthiban has quit [Remote host closed the connection]
Schimsalabim has quit [Ping timeout: 480 seconds]
Schimsalabim has joined #linux-sunxi
Schimsalabim has quit [Read error: Connection reset by peer]
Schimsalabim has joined #linux-sunxi
chewitt has joined #linux-sunxi
apritzel has joined #linux-sunxi
<wens>
is there such a thing?
<wens>
oops
junari has quit [Remote host closed the connection]
junari has joined #linux-sunxi
bauen1 has quit [Ping timeout: 480 seconds]
warpme has quit []
gsz has joined #linux-sunxi
szemzoa_ has quit [Ping timeout: 480 seconds]
Sensu_Be1 has joined #linux-sunxi
szemzoa has joined #linux-sunxi
Sensu_Bean has quit [Ping timeout: 480 seconds]
szemzoa has quit [Remote host closed the connection]
szemzoa has joined #linux-sunxi
Sensu_Bean has joined #linux-sunxi
Sensu_Be1 has quit [Read error: Connection reset by peer]
evgeny_boger has quit [Quit: evgeny_boger]
evgeny_boger has joined #linux-sunxi
evgeny_boger has quit [Ping timeout: 480 seconds]
radxanaoki has quit [Quit: radxanaoki]
bauen1 has joined #linux-sunxi
junari has quit [Remote host closed the connection]
evgeny_boger has joined #linux-sunxi
evgeny_boger has quit [Quit: evgeny_boger]
sdfgsdfs has joined #linux-sunxi
lschmid has joined #linux-sunxi
<lschmid>
apritzel: I've played arround some more the u-boot on the fused t113 and I can't get it succesfully continue. I even tried loading the monitor into the SRAM A1 to see if anything different happens, but it still hangs on the exact same step as before. I also compared the vector tables and call addresses with the unfused board and they seem to match... Any ideas what I could try/check next?
<apritzel>
lschmid: I am still thinking ;-) or rather scratching my head, because this should all be architectural, so within the core (so Arm Cortex, not Allwinner). which means there should be no difference between "secure boot" or not
<lschmid>
apritzel: Is the monitor also being used in non-secure mode? Like do the smc calls also perform something in there?
<apritzel>
do you mean "non-secure boot / fuse burnt"?
<lschmid>
exactly
<apritzel>
yes, that's why I wonder, that should be the same
<lschmid>
oh i see. yeah that's very weird then
<lschmid>
would it maybe help to be able to jtag the soc? If that even works on allwinners atm
<apritzel>
U-Boot proper should always be entered in secure EL1, from which it installs the monitor vectors, then triggers the smc to get into monitor mode, sets the NS bits, and erets, now into non-secure
<apritzel>
yes, JTAG would be useful, and the signals are multiplexed on the SD card pins, and some people in here have used that successfully
<gamiee>
also paulk did openocd configs, but not sure for which all SoCs.
<apritzel>
you would need to hack U-Boot to change the PortF pinmux, and would lose access to the SD card in the process
<apritzel>
and would need a microSD breakout board, unless you have those pins on headers on your board
<lschmid>
I'd have to flash the signed u-boot the eMMC then, but that shouldn't be an issue if I enable ums. I'll see if i can find my jtag stuff and a micro-sd breakout
cnxsoft has quit [Ping timeout: 480 seconds]
<lschmid>
Okay I think openocd is finding the chip. Does that sound right? "JTAG tap: auto0.tap tap/device found: 0x5ba00477 (mfg: 0x23b (ARM Ltd), part: 0xba00, ver: 0x5)"
chewitt has quit [Quit: Zzz..]
Schimsalabim has quit [Ping timeout: 480 seconds]
Schimsalabim has joined #linux-sunxi
dsimic is now known as Guest23469
dsimic has joined #linux-sunxi
Guest23469 has quit [Ping timeout: 480 seconds]
<lschmid>
apritzel: Okay i got jtag working. What do we want to look at?
<apritzel>
well, can you see where it hangs? Or what it does immediately before that?
<lschmid>
If i stop the cpu after it "hangs" it seems to be running somewhere in DRAM (0xc08cb428)-ish
Sensu_Be1 has joined #linux-sunxi
Sensu_Bean has quit [Read error: Connection reset by peer]
Sensu_Bean has joined #linux-sunxi
Sensu_Be1 has quit [Read error: Connection reset by peer]
Sensu_Be1 has joined #linux-sunxi
Sensu_Bean has quit [Read error: Connection reset by peer]
<apritzel>
but DRAM ends at 0x50000000 or even 0x48000000?
<apritzel>
lschmid: can you set a breakpoint, for instance in the monitor vectors?
lschmid has quit [Ping timeout: 480 seconds]
Sensu_Bean has joined #linux-sunxi
lschmid has joined #linux-sunxi
<lschmid>
apritzel: Okay i've got some even weirder stuff now. It seems to run away after the "bx r6" in psci_stack_setup. And the weird thing is if I set a breakpoint for "psci_stack_setup" the kernel actually tries to start up and gets stuck some time later
<lschmid>
As for the DRAM ending earlier. I had thought this is DRAM too as the Datasheet refers to it as DRAM SPACE from 0xC0000000 again
Sensu_Be1 has quit [Read error: No route to host]
<apritzel>
lschmid: but that's the memory map as seen by the DSP?
Sensu_Bean has quit [Remote host closed the connection]
ftg has joined #linux-sunxi
<apritzel>
now I actually wonder if that's something weird with some system registers, I think I saw strange things on a secure boot system as well (cache ID register being wrong)
Sensu_Bean has joined #linux-sunxi
Sensu_Be1 has joined #linux-sunxi
<apritzel>
can you check what the value returned by the "mrs" instruction is (for MPIDR)?
<lschmid>
in arch/arm/cpu/armv7/start.S ?
<lschmid>
Or just anywhere
<apritzel>
in psci.S
<lschmid>
did you mean mrc?
<apritzel>
yes indeed, spent a good part of the day dealing with AArch64 system registers ;-)
Sensu_Be2 has joined #linux-sunxi
Sensu_Be3 has joined #linux-sunxi
<lschmid>
If i've done it right MPIDR is 0x80000000
Sensu_Bean has quit [Ping timeout: 480 seconds]
<apritzel>
thanks, that looks alright, and should work
Sensu_Be1 has quit [Ping timeout: 480 seconds]
Sensu_Be2 has quit [Ping timeout: 480 seconds]
<lschmid>
Any reason why i would not be able to step past "bx r6"? The address in r6 looks good, but if I step over it gdb never returns
<lschmid>
and if i stop it after using ctrl+c were somewhere in 0xc08cb49c again
<apritzel>
can you check what the newly calculated secure stack pointer is? Does that make sense? It should in the middle of U-Boot data
<lschmid>
i think that would be 0x47fc6ffc?
<lschmid>
r6 for bx is 0x47fc4030 btw
<apritzel>
both look reasonable (relocated correctly by U-Boot to the end of DRAM)
<lschmid>
"bx r6" basically jumps to r6 right? so a "set $pc=$r6" in gdb should do the same, right?
<apritzel>
yes, that should return to the instruction after the "bl psci_stack_setup"
<lschmid>
So why does bx r6 run away, and set $pc=$r6 work (at least until the next chance it gets to run away again)?
Sensu_Bean has joined #linux-sunxi
Sensu_Be3 has quit [Read error: Connection reset by peer]
<apritzel>
that's a good question! ;-)
<lschmid>
What I'm hearing is "it shouldn't"
<lschmid>
The "next chance" is a "movs pc, lr" (ERET to non-secure) in _secure_monitor
<lschmid>
And it will run away into 0xc.... again
<lschmid>
Or it might actually crash. Since when i break afterwards, it always shows me this 0xc08cb49c address and if I try to continue I get "Cannot insert breakpoint" and "Cannot access memory at address 0x47f756d0" and I have to hard-reset the board
apritzel has quit [Ping timeout: 480 seconds]
Sensu_Be1 has joined #linux-sunxi
Sensu_Bean has quit [Ping timeout: 480 seconds]
gsz has quit [Ping timeout: 480 seconds]
Schimsalabim has quit [Read error: Connection reset by peer]
Schimsalabim has joined #linux-sunxi
lschmid has quit [Quit: Leaving]
gsz has joined #linux-sunxi
hazardchem has quit [Read error: Connection reset by peer]
hazardchem has joined #linux-sunxi
Sensu_Bean has joined #linux-sunxi
Sensu_Be1 has quit [Read error: Connection reset by peer]
apritzel has joined #linux-sunxi
hazardchem has quit [Read error: Connection reset by peer]
hazardchem has joined #linux-sunxi
Sensu_Be1 has joined #linux-sunxi
Sensu_Bean has quit [Read error: No route to host]
Sensu_Bean has joined #linux-sunxi
Sensu_Be1 has quit [Remote host closed the connection]
vagrantc has joined #linux-sunxi
psydroid has quit []
psydroid has joined #linux-sunxi
Sensu_Be1 has joined #linux-sunxi
Sensu_Bean has quit [Ping timeout: 480 seconds]
bauen1 has quit [Ping timeout: 480 seconds]
wingrime1 has joined #linux-sunxi
wingrime-ww has quit [Ping timeout: 480 seconds]
wingrime1 has quit [Ping timeout: 480 seconds]
Sensu_Bean has joined #linux-sunxi
Sensu_Be1 has quit [Remote host closed the connection]
wingrime-ww has joined #linux-sunxi
gsz has quit [Ping timeout: 480 seconds]
Sensu_Be1 has joined #linux-sunxi
Sensu_Bean has quit [Ping timeout: 480 seconds]
vagrantc has quit [Ping timeout: 480 seconds]
Sensu_Bean has joined #linux-sunxi
Sensu_Be1 has quit [Read error: Connection reset by peer]