rellla changed the topic of #linux-sunxi to: Allwinner/sunxi /development discussion - did you try looking at our wiki? https://linux-sunxi.org - Don't ask to ask. Just ask and wait! - https://github.com/linux-sunxi/ - Logs at http://irclog.whitequark.org/linux-sunxi - *only registered users can talk*
t12 has joined #linux-sunxi
apritzel has quit [Ping timeout: 244 seconds]
nashpa_ has joined #linux-sunxi
nashpa has quit [Ping timeout: 250 seconds]
_whitelogger has joined #linux-sunxi
t12 has quit [Quit: Page closed]
victhor has quit [Remote host closed the connection]
yangxuan has joined #linux-sunxi
yangxuan has quit [Ping timeout: 240 seconds]
yangxuan has joined #linux-sunxi
clemens3_ has joined #linux-sunxi
clemens3 has quit [Ping timeout: 240 seconds]
yangxuan has quit [Ping timeout: 250 seconds]
vagrantc has quit [Quit: leaving]
lurchi_ is now known as lurchi__
popolon has quit [Quit: WeeChat 2.3]
merlin1991 has quit [Remote host closed the connection]
kelvan has quit [Remote host closed the connection]
kelvan has joined #linux-sunxi
merlin1991 has joined #linux-sunxi
doppo has quit [Ping timeout: 260 seconds]
doppo has joined #linux-sunxi
doppo has quit [Remote host closed the connection]
doppo has joined #linux-sunxi
dddddd has quit [Remote host closed the connection]
reinforce has joined #linux-sunxi
_whitelogger has joined #linux-sunxi
IgorPec has joined #linux-sunxi
nuuuciano has quit [Ping timeout: 250 seconds]
nuuuciano has joined #linux-sunxi
tllim has quit [Ping timeout: 250 seconds]
yangxuan has joined #linux-sunxi
yangxuan has quit [Quit: Leaving]
clemens3_ has quit [Ping timeout: 240 seconds]
return0e has joined #linux-sunxi
nuuuciano has quit [Ping timeout: 244 seconds]
return0e_ has quit [Ping timeout: 268 seconds]
netlynx has joined #linux-sunxi
lurchi__ is now known as lurchi_
apritzel has joined #linux-sunxi
apritzel has quit [Ping timeout: 245 seconds]
lykt has quit [Quit: leaving]
lurchi_ is now known as lurchi__
camus has joined #linux-sunxi
kaspter has quit [Ping timeout: 250 seconds]
camus is now known as kaspter
lykt has joined #linux-sunxi
IgorPec has quit [Ping timeout: 250 seconds]
netlynx has quit [Quit: Ex-Chat]
BenG83 has quit [Quit: Leaving]
kaspter has quit [Remote host closed the connection]
kaspter has joined #linux-sunxi
clemens3_ has joined #linux-sunxi
foxx_ has joined #linux-sunxi
BenG83 has joined #linux-sunxi
lurchi__ is now known as lurchi_
foxx_ has quit [Ping timeout: 246 seconds]
chomwitt has joined #linux-sunxi
victhor has joined #linux-sunxi
reinforce has quit [Ping timeout: 268 seconds]
reinforce has joined #linux-sunxi
IgorPec has joined #linux-sunxi
lurchi_ is now known as lurchi__
apritzel has joined #linux-sunxi
apritzel has quit [Ping timeout: 250 seconds]
camus has joined #linux-sunxi
kaspter has quit [Ping timeout: 244 seconds]
camus is now known as kaspter
popolon has joined #linux-sunxi
kever has quit [Remote host closed the connection]
kever has joined #linux-sunxi
Andy-D has joined #linux-sunxi
ttlover has joined #linux-sunxi
ttlover has quit [Client Quit]
Rafael1980 has joined #linux-sunxi
<catphish> is there a correct initialization order for the DE, TCAM, HDMI, and HDMI PHY?
<catphish> i believe i'm not doing everything correctly, but the code only works if i boot u-boot first, then reset, then boot my code, which is bizarre, but at least i must be close, maybe just a timing, or problem with doing things in the wrong order
<plaes> u-boot setting up something that you're not
<plaes> you can compare registers
nuuuciano has joined #linux-sunxi
Mandragor has quit [Ping timeout: 246 seconds]
Mandragor has joined #linux-sunxi
dddddd_ has joined #linux-sunxi
<catphish> plaes: i thought that too, but i was also told that no registers should survive a reset
<catphish> is there anything that it could be setting up that does survive a reset (by the watchdog)? if so, i'll look there firs
dddddd_ is now known as dddddd
apritzel has joined #linux-sunxi
yangxuan has joined #linux-sunxi
apritzel has quit [Ping timeout: 240 seconds]
Andy-D has quit [Ping timeout: 250 seconds]
Andy-D has joined #linux-sunxi
Amit_T has joined #linux-sunxi
<tautologico> catphish: is your H3 code on github?
reinforce has quit [Quit: Leaving.]
yangxuan has quit [Quit: Leaving]
return0e_ has joined #linux-sunxi
return0e has quit [Ping timeout: 250 seconds]
JohnDoe_71Rus has joined #linux-sunxi
lurchi__ is now known as lurchi_
return0e_ has quit [Ping timeout: 250 seconds]
return0e has joined #linux-sunxi
<catphish> sorry, got distracted by a feast being served, tautologico yes - https://github.com/catphish/allwinner-bare-metal/
<catphish> the problematic (hopefully simple, but currently full of unexplained bit offsets) display code is in https://github.com/catphish/allwinner-bare-metal/blob/master/display.c
<catphish> hope it's clear enough and easy to build, would certainly appreciate any input :)
<tautologico> I'll try to take a look at it today or tomorrow
<tautologico> are you testing on an orange pi one?
<catphish> thanks, and yes i am
<catphish> it should work the same way on any h3 i hope, i use u-boot spl to initialize the ram, then everything else is bare metal, my test platform is orange pi one
<tautologico> cool, I have an opi one
apritzel has joined #linux-sunxi
reinforce has joined #linux-sunxi
tllim has joined #linux-sunxi
fossxplorer has quit [Ping timeout: 252 seconds]
apritzel has quit [Ping timeout: 246 seconds]
Andy-D has quit [Ping timeout: 250 seconds]
Andy-D has joined #linux-sunxi
lurchi_ is now known as lurchi__
\\Mr_C\\ has quit [Read error: Connection reset by peer]
\\Mr_C\\ has joined #linux-sunxi
lurchi__ is now known as lurchi_
vagrantc has joined #linux-sunxi
tllim has quit [Read error: Connection reset by peer]
lkcl has quit [Ping timeout: 268 seconds]
camus has joined #linux-sunxi
kaspter has quit [Ping timeout: 250 seconds]
camus is now known as kaspter
apritzel has joined #linux-sunxi
NeuroScr has joined #linux-sunxi
Andy-D has quit [Ping timeout: 250 seconds]
Andy-D has joined #linux-sunxi
NeuroScr has quit [Ping timeout: 245 seconds]
NeuroScr has joined #linux-sunxi
NeuroScr has quit [Ping timeout: 272 seconds]
NeuroScr has joined #linux-sunxi
NeuroScr has quit [Ping timeout: 250 seconds]
NeuroScr has joined #linux-sunxi
NeuroScr has quit [Ping timeout: 250 seconds]
NeuroScr has joined #linux-sunxi
NeuroScr has quit [Ping timeout: 250 seconds]
Andy-D has quit [Ping timeout: 246 seconds]
Andy-D has joined #linux-sunxi
BenG83 has quit [Quit: Leaving]
NeuroScr has joined #linux-sunxi
NeuroScr has quit [Ping timeout: 240 seconds]
NeuroScr has joined #linux-sunxi
apritzel has quit [Ping timeout: 250 seconds]
lurchi_ is now known as lurchi__
NeuroScr has quit [Ping timeout: 250 seconds]
lkcl has joined #linux-sunxi
NeuroScr has joined #linux-sunxi
lurchi__ is now known as lurchi_
NeuroScr has quit [Ping timeout: 246 seconds]
NeuroScr has joined #linux-sunxi
NeuroScr has quit [Ping timeout: 250 seconds]
NeuroScr has joined #linux-sunxi
NeuroScr has quit [Ping timeout: 268 seconds]
NeuroScr has joined #linux-sunxi
Amit_T has quit [Quit: Leaving]
hanni76 has joined #linux-sunxi
IgorPec has quit [Ping timeout: 250 seconds]
JohnDoe_71Rus has quit [Quit: KVIrc 5.0.0 Aria http://www.kvirc.net/]
Andy-D has quit [Ping timeout: 245 seconds]
Andy-D has joined #linux-sunxi
NeuroScr has quit [Quit: NeuroScr]
dev1990_ has joined #linux-sunxi
anarsoul|2 has quit [Ping timeout: 272 seconds]
dev1990 has quit [Ping timeout: 268 seconds]
foxx_ has joined #linux-sunxi
Andy-D has quit [Ping timeout: 246 seconds]
Andy-D has joined #linux-sunxi
lurchi_ is now known as lurchi__
reinforce has quit [Quit: Leaving.]
lurchi__ is now known as lurchi_
anarsoul|2 has joined #linux-sunxi
foxx_ has quit [Ping timeout: 246 seconds]
BenG83 has joined #linux-sunxi
willmore has quit [Ping timeout: 244 seconds]
willmore has joined #linux-sunxi
<KotCzarny> hmm, not directly related, but. on devices which expect uboot from block 0, can uboot be compiled in a way to pad mbr partition table space ?
<kilobyte> if not, an asm shim could work -- there's plenty of space there
<catphish> mbr allows some space at the start for a boot sector
<KotCzarny> keep in mind i didnt dig into spl layout yet for that particular board
<catphish> so as kilobyte says, it should definitely be possible to do manually
<KotCzarny> so dont know how many bytes would be needed before pad
<catphish> but i guess you know all that, you just need a way to move the code up
<KotCzarny> nah, asm is way over my head, thats why im asking pros
<catphish> well, spl might be position independent
<kilobyte> or even copy it around memory with that asm code
<catphish> which means it might be as simple as just moving it up, then adding a single assembly instruction at sector 0 to goto the new location
<KotCzarny> best would be if it could be simple 2-4 bytes that jump into 512bytes offset
anarsoul|2 has quit [Ping timeout: 268 seconds]
<catphish> KotCzarny: yeah i suspect that will work
<KotCzarny> but i also suspect it would require additional dancing around embedded sub binaries
<catphish> not really, build the spl binary, pad the beginning, inject the 4 byte goto, then run it through the code that turns it into a sunxi binary
<KotCzarny> nah, its not sunxi but marvel
<catphish> ah sure, similar deal though
<KotCzarny> they load from 0 sector (whoever thought it would be best idea..)
<catphish> u-boot outputs a binary, you just need to move it up a few bytes and add a goto at bytes 0-3
<KotCzarny> in that regard allwinner was ingenious
<catphish> well to be fair, MBR is *designed* to have boot0 code at sector 0
<KotCzarny> it has some initialization before uboot, memory etc (similar to sunxi)
<KotCzarny> 640kB should be enough for everyone!
<KotCzarny> ;)
<catphish> what byte offset do you want to put the binary?
NeuroScr has joined #linux-sunxi
<KotCzarny> to make it easier, i was thinking about 512B, but again, before uboot is spl, and i havent checked if it would work out of the box from different position
<catphish> isn't 512B the start of the MBR?
<catphish> i mean the start of the partition table
<KotCzarny> mbr starts at 0x0
<KotCzarny> partition table starts few bytes before 512B
<catphish> oh ok
<KotCzarny> (the old mbr one)
<KotCzarny> gpt is fubar
<catphish> ah ok, so the first partition can start at 512B
<KotCzarny> not the partition, partition table
<catphish> huh?
<KotCzarny> ie. 0..X - asm jump code, X-512B partition table, 512B spl and uboot
<kilobyte> IBM PC's boot sequence: load sector 0 (at a fixed offset in memory, 512 bytes), jump to it. It doesn't care if it's a floppy or a hard disk; if it has partitions or not.
<catphish> so the first PARTITION can start at 512B i said
<catphish> the table starts at 446B
<catphish> anyway that's fine, gimme a sec
<KotCzarny> catphish i can start partition at 8MB, not a problem, just location of partition table inside sector 0
<catphish> sure
<kilobyte> yeah -- any modern $DISK/SD card has alignment higher than 512B but work it would do
<KotCzarny> that's the spl+uboot
<KotCzarny> even better trick would be fitting spl between 512B and 8kB, so it could coexist with sunxi's uboot
<KotCzarny> (ie. single sdcard to run on marvell and sunxi boards ;)
<catphish> KotCzarny: write the following 4 bytes to the beginning of the disk: "7E 00 00 EA"
<catphish> KotCzarny: if any ARM CPU executes this, it will immediately jump 508 bytes forward
<KotCzarny> uhum, thanks for the tip, will definitely test it
<KotCzarny> i will have to move the firs few kB a bit too and pad, etc
<catphish> so assuming you put that at offset 0, and the spl at offset 512, if the chip loads the whole thing into memory and starts executing at the start, it should immediately jump to thee spl and work
<catphish> doesn't matter what's in between
hanni76 has quit [Quit: Leaving]
<catphish> well if you're lucky you can just write the whole spl as-is starting at byte 512, and add that jump code
<catphish> this information comes with no warranty
<catphish> but it might work
<catphish> 0:ea00007e b0x200
<KotCzarny> gotta run now, but thanks again!
netlynx has joined #linux-sunxi
netlynx has quit [Changing host]
netlynx has joined #linux-sunxi
<catphish> enjoy :)
<catphish> now if someone could just fix my display code :)
NeuroScr has quit [Quit: NeuroScr]
netlynx has quit [Quit: Ex-Chat]
Andy-D has quit [Ping timeout: 272 seconds]
Andy-D has joined #linux-sunxi
\\Mr_C\\ has quit [Quit: (Read error: Connection reset by beer)]
dev1990_ has quit [Quit: Konversation terminated!]
apritzel has joined #linux-sunxi
\\Mr_C\\ has joined #linux-sunxi
lurchi_ is now known as lurchi__
* hanetzer passes catphish's code through a cheese grater
<catphish> :))
lurchi__ is now known as lurchi_
willmore has quit [Ping timeout: 250 seconds]