narmstrong changed the topic of #linux-amlogic to: Amlogic mainline kernel development discussion - our wiki http://linux-meson.com/ - ml linux-amlogic@lists.infradead.org - Publicly Logged on https://irclog.whitequark.org/linux-amlogic
sputnik_ has quit [Remote host closed the connection]
sputnik_ has joined #linux-amlogic
afaerber has quit [Remote host closed the connection]
sputnik_ has quit [Remote host closed the connection]
sputnik_ has joined #linux-amlogic
vagrantc has joined #linux-amlogic
jakogut_ has quit [Quit: jakogut_]
<sheepman> Morning all, I've posted an issue on the Armbian forum but I thought I'd ask here too incase anyone has seen similar issues before: https://forum.armbian.com/topic/2138-armbian-for-amlogic-s912/?do=findComment&comment=67347 any help would be greatly appreciated.
<sheepman> ccaione: ah sounds very similar doesn't it! thanks for that :)
<ccaione> sheepman: I would be interested in knowing if that solves the issue for you
<sheepman> ok no worries, i'll feedback
<sheepman> ccaione: This is all a bit above my level but essentially these are just change to the dts/dtb file correct? I don't need a special kernel build or anything?
<sheepman> if it helps it's running:
<sheepman> Linux aml 4.19.2-aml-s9xxx #1 SMP PREEMPT Wed Nov 28 13:03:09 MSK 2018 aarch64 aarch64 aarch64 GNU/Linux
<ccaione> just a change in the dts/dtb, yes
<sheepman> perfect
<sheepman> ccaione: i can't see the relevant lines in my dts file although now im thinking maybe i should try a more generic one
<sheepman> currently using: meson-gxm-khadas-vim2.dtb
<ccaione> sheepman: you have to modify `meson-gx.dtsi`
<sheepman> im not currently using that though dts though is the thing, not sure where to get it from
<sheepman> this is how the dts im using looks if it makes any difference: https://paste.fedoraproject.org/paste/fAwuMMF-AT-EsUfnCrGKBA
<sheepman> i can see stuff relating to ethernet but it's very different
<sheepman> let me try the dts/dtb you're suggesting see if it boots
<sheepman> can i point my uEnv.ini straight at the dtsi file or do i need to convert to dtb first do you know?
<ccaione> sheepman: are you using `meson-gxm-khadas-vim2.dts` from the mainline kernel? That DTS is including `meson-gx.dtsi` so you need to modify `meson-gx.dtsi` and keep using `meson-gxm-khadas-vim2.dtb`
<sheepman> so dtsi is a dts include or something? I've never come across dtsi file extension before
<ccaione> (`meson-gxm-khadas-vim2.dts` -> `meson-gxm.dtsi` -> `meson-gxl.dtsi` -> `meson-gx.dtsi`)
<ccaione> yes
<sheepman> ah ok, well basically the Armbian image I downloaded just includes common dtb's for convenience for the average user (I guess) so I'll have to fiddle and learn a little I think :)
<sheepman> I'm happy with the conversion from dtb to dts and vice versa I just wasn't even aware there were and are includes as such
<sheepman> makes sense though
<sheepman> sorry for all the time I'm taking, but essentially download all files here: https://github.com/torvalds/linux/tree/master/arch/arm64/boot/dts/amlogic modify and convert to dtb using the dtc tool?
<ccaione> yeah, or just clone the repo and give `make ARCH=arm64 dtbs`
<ccaione> yeah, or just clone the repo and give `make ARCH=arm64 dtbs`
<sheepman> ok cool ta
<sheepman> ccaione: ok all patched, I'll let you know how I get on but it might be a 24 hours or so
<ccaione> I hope I won't die sooner
<sheepman> me too
<sheepman> <3
<ccaione> lol
<sheepman> is there a reason you might? Or daren't I ask?
<sheepman> apart from the obvious ones... tragic accident etc.
<ccaione> you never know
* sheepman is sensing you're an pessimist
<sheepman> *a
<ccaione> technically we are all dying already
<sheepman> and so's the planet, but for now we have hookers, lamborgini's and cocaine so lets aim for that!
chewitt has joined #linux-amlogic
<sheepman> you need to think more like Bender from Futurama lol
<sheepman> that'll perk you up
<sheepman> in fact, stop what you're doing.... go get a fine whiskey and a cigar and enjoy it... even if you don't enjoy it just enjoy the fact you've done something spontaneous and that it might be (or might not be) a new sensation
<sheepman> humans are curious so embrace your curiosity :D
<ccaione> hahah this is way too OT :D
<sheepman> Well you got my concerned, OT or otherwise thought i'd try and help a fellow human :D
<sheepman> but yes you're right, I'm getting too crazy for the masses.... I'll pipe down :)
<sheepman> FYI i've kicked off a big file copy over NFS as this killed the ethernet before, will see how it goes.
TheAssassin has quit [Ping timeout: 252 seconds]
chewitt has quit [Quit: Zzz..]
Barada has joined #linux-amlogic
ldevulder_ has joined #linux-amlogic
ldevulder has quit [Ping timeout: 246 seconds]
chewitt has joined #linux-amlogic
ldevulder_ is now known as ldevulder
Barada has quit [Quit: Barada]
TheAssassin has joined #linux-amlogic
chewitt has quit [Quit: Zzz..]
<sheepman> ccaione: well my copy finished that didn't finish before so that's a good start.... I'll continue to stress it over the next 24 hours or so
<ccaione> sheepman: good, thanks for trying.
<sheepman> no thank you for the fix (fingers crossed)
dfceaef[m] has joined #linux-amlogic
<dfceaef[m]> hi, can I talk about bl1/bl2/bl3 here? I'm working on reverse engineering firmware on s905d (gxl)
<narmstrong> well, bl31 is already done
<narmstrong> if you want to do bl2, bl30x good luck
<dfceaef[m]> bl2 is so secure that it contains a backdoor
<narmstrong> a backdoor ?
<dfceaef[m]> I'm swimming in the SEC AHB
Xogium has quit [Quit: Leaving.]
Xogium has joined #linux-amlogic
<dfceaef[m]> still working on dumping the AES key for secure boot
<poulecaca> the AES key is in the header
<poulecaca> secure boot is not secure on gxl
<dfceaef[m]> nope not "that" AES key which you'll see AMLC magic on bl2 header
<poulecaca> ah ok
<dfceaef[m]> my device is entirely encrypted and it only accepts encrypted bl2 which looks like random bits
<poulecaca> yes, because bl2 firmware is encrypted with AES_CBC and the key + iv are in the header. But maybe I miss what you mean
<dfceaef[m]> fortunately someone get an unencrypted copy for it and a strange file called SECURE-BOOT-SET
<dfceaef[m]> if you are interested I can send those files
<dfceaef[m]> poulecaca: If that were my case I would not be forced to re it
<dfceaef[m]> so any suggests where's the key?
<poulecaca> do you have the encrypted bl2.bin somewhere ?
<dfceaef[m]> yes, both unencrypted and encrypted (can't find a filebin)
<poulecaca> can you put the encrypted one somewhere, that I can take a look at it ?
<dfceaef[m]> sure wait a moment
<poulecaca> to be sure of what you are asking, you want to know how to go from the encrypted one to the decrypted one and vice versa right ?
<dfceaef[m]> not exactly. I know that's impossible
<dfceaef[m]> since I have gain control over trust world, I want to know how to located AES key in memory space
<dfceaef[m]> and, bl1 is here https://fars.ee/q3XV.bin
<sheepman> ccaione: still going strong, will try and kill it over the weekend
<ccaione> great
<dfceaef[m]> In 25.4 EFUSE: Data is always read/written in 128-bit blocks
<dfceaef[m]> how can I write C code to read 128b at one time...
<xdarklight> dfceaef[m]: you might be interested in checking the code from https://lkml.org/lkml/2018/1/24/116
Darkmatter66 has joined #linux-amlogic
Darkmatter66_ has quit [Ping timeout: 246 seconds]
<poulecaca> ok dfceaef[m] now I see what you mean, sorry for the confusion
jakogut_ has joined #linux-amlogic
drieschel has joined #linux-amlogic
<TheAssassin> does anyone know a source for DTB images for those MXQ OTT boxes? I have one of the cheaper clones (with ~512MiB RAM), and all the DTB images I tried either didn'
<TheAssassin> t work or produced garbage HDMI output
<TheAssassin> I'd like to use that thing with armbian, but not being able to even log in is quite of an issue :)
<xdarklight> TheAssassin: do you have more details on that box?
trem has joined #linux-amlogic
<TheAssassin> xdarklight: MXQ "black box", the ebay page said it's called OTT, wannabe-s805, I somewhere picked up the string "kot49h 20160423" (somewhere in the system details on the preinstalled android 4, IIRC)
<TheAssassin> at first I Thought it might be what is called m201c on this page https://www.rigacci.org/wiki/doku.php/doc/appunti/hardware/mxq_s805, but well, these HD18Q images don't produce any working HDMI output
<xdarklight> S805 is a 32-bit SoC
<TheAssassin> I once had one image that worked as in "it's readable" (looks like it's producing 720p only) until the console font was changed
<xdarklight> I'm not sure if armbian still supports Amlogic's 3.10 kernel
<xdarklight> mainline kernels on the other hand don't support video output
<TheAssassin> i've even built an image using balbes150(?)'s armbian build script stuff
<TheAssassin> but then I had no DTB image, and even the old DTB didn't work any more
<xdarklight> do you have access to the serial console on your device?
<TheAssassin> there's nearly no documentation on all this (at least not that I could've found any), I'd love to debug
<TheAssassin> I wanted to avoid opening the case, but I guess it's time for it?
<xdarklight> I'm not sure about the boot process on these vendor u-boots
<xdarklight> some will only load an image from the SD card if you press some button (sometimes a toothpick is required to do that, because the button is inside the audio connector)
<TheAssassin> where's my saleae thingy...
<TheAssassin> that's one of these boxes
<TheAssassin> mine worked like "boot from sd card (with garbage HDMI) once, then boot from sd first forever"
<TheAssassin> oh cool
<TheAssassin> there's screws below these rubber feet
<TheAssassin> makes things easier
jakogut_ has quit [Remote host closed the connection]
<xdarklight> you "just" need an USB to UART adapter - I'm not sure if these salae thingies support that
<TheAssassin> well, but I wanted to find out where to put that
<TheAssassin> for console I'd use one of those "adapters" ofc :D
<xdarklight> most boards have the RX, TX and GND pads marked
<xdarklight> just remember: never connect 3.3V
<TheAssassin> i thought there's maybe a more easy solution, that's why I came here :) but well
vagrantc has quit [Ping timeout: 252 seconds]
<TheAssassin> I'd generalize that to "never connect _any_ V+"
jakogut_ has joined #linux-amlogic
<xdarklight> :)
<xdarklight> TheAssassin: cna you please upload the .dtb from your board somewhere?
<TheAssassin> in a sec
<TheAssassin> Im making pictures for later :)
<TheAssassin> aaaaah there's the RX TX GND stuff...
<TheAssassin> urgh... soldering
<TheAssassin> xdarklight: hm can you extract that from the preinstalled android, or do you mean the half-working one?
<xdarklight> the best you have :)
<TheAssassin> I gues I'll have to retry...
<xdarklight> seems like an IC+ IP101GR 10/100 PHY
<xdarklight> the 4-port hub is also not very surprising
<xdarklight> random google with the board version string results in this link: https://mega.nz/#!cQhCGCQQ!MZAe5mVA3bRbHAIyG3GP274JcP0BSm_Lf2ZJ88DBssA
<xdarklight> that boot.img contains two .dtbs: https://paste.kde.org/povdxptlq and https://paste.kde.org/pfvplj4gc
<xdarklight> there's also a PWM based regulator - I need to double-check but at first sight the PWM / voltage table is identical to the one on EC-100 (for which we have mainline support :))
<xdarklight> double-checked and confirmed: it's probably the same VCCK (CPU voltage regulator) design as EC-100
sputnik_ has quit [Remote host closed the connection]
sputnik_ has joined #linux-amlogic
sputnik_ has quit [Remote host closed the connection]
sputnik_ has joined #linux-amlogic
<TheAssassin> xdarklight: sorry, back now
<TheAssassin> spent 15 minutes looking for the box with the jumper cables, then soldered a bit and then someone called :D
<TheAssassin> will flash that image, and monitor the UART
<xdarklight> don't flash that image
<xdarklight> or well, it depends on what you want
<xdarklight> that image may get you some old 3.10 kernel - possible with HDMI output
<xdarklight> do you need HDMI output or do you want to use it as <random headless system>?
trem has quit [Quit: Leaving]
<TheAssassin> well I tried the "random headless system" bit
<TheAssassin> but I never got it to get an address via DHCP
<TheAssassin> in fact, I'd love to continue using my self-built image, as that'd ensure I can build updates
<TheAssassin> but I'd like to see something work for now, and then continue from there
<xdarklight> OK
<xdarklight> then feel free to try that image
<TheAssassin> like, my idea is, find a working configuration, and maybe it's possible to then just copy that dtb or so
<TheAssassin> but first i'll try my own image, but will watch the serial console
<xdarklight> once you're ready for experiments then let me know so we can start filling https://github.com/torvalds/linux/blob/master/arch/arm/boot/dts/meson8b-mxq.dts (mainline kernels need a different .dts / .dtb than Amlogic's 3.10 kernel)
<TheAssassin> i've tried that before
<TheAssassin> so, it's simply for another kernel?
<xdarklight> 150balbes' repos are typically for Amlogic 3.10 (S802, S805 and S812) or 3.14 (S905, S905X, ...) kernels
<xdarklight> however, I think even within the 3.10 kernels Amlogic changed the .dtb from time to time
<xdarklight> so <some 3.10 kernel> may not be compatible with <.dtb from another 3.10 kernel>
<TheAssassin> hm
<TheAssassin> I've built the image using https://github.com/150balbes/Build-Armbian
<TheAssassin> or, say, images
<TheAssassin> one with mainline kernel, and a headless one for those 3.1x kernels
<TheAssassin> I can "quickly" build one for the 3.1x kernel
<TheAssassin> w/ graphics
vagrantc has joined #linux-amlogic
drieschel has quit [Quit: drieschel]
yangxuan has joined #linux-amlogic
yangxuan has quit [Quit: Leaving]
_whitelogger has joined #linux-amlogic