Jump to content

Since Tanix TX6 can boot from the SD card


xaduha

Recommended Posts

@hexdump One of the mysteries is solved. Tanix TX6 doesn't have external 32768 Hz crystal, so it has to use internal one. After a quick hack in RTC driver, which takes care for that, there is no more RTC issues reported in dmesg and HDMI-CEC works from the beginning. I wonder if this also helps with Eachlink HDMI issue. Can you test this LE image on Eachlink box?

Link to comment
Share on other sites

Just now, hexdump said:

not sure if i'll get to it today, but during the next days for sure

Note that 5.3 will be released in about 2 weeks so don't delay too much :)

 

1 minute ago, hexdump said:

in case the tests would be ok, shall i then respond with tested-by to all four of them?

I would say that you can just reply to cover letter, but in this case there isn't any, so yes. You can also reply with reviewed-by if you understand the code, but tested-by already helps.

Link to comment
Share on other sites

1 hour ago, hexdump said:

i'm too tired tonight and too slow to review them as well - maybe you can have a look?

Not today, I'm tired too. But I'm pretty sure someone would reviewed them because others complained too.

Link to comment
Share on other sites

So there's actually no way to address more than 2GB of memory on H6 based boxes? How come they started selling and advertising 4GB models? I checked the Allwinner  H6 tech docs and it clearly says it only supports 2GB of memory.

Link to comment
Share on other sites

it is 3gb except for the eachlink h6 mini with its strange memory setup - this 4gb advertising thing is simply marketing i guess: most of those boxes really have 4gb, just that it is not useable :)

 

it would be interesting if those 3gb are a hard limit of the hardware or if there are any ways to maybe move it to 3.5gb ... i know the h6 has 32bit memory addressing, but i think on other even full 32bit systems one can address close to 4gb ...

Link to comment
Share on other sites

7 hours ago, hexdump said:

it would be interesting if those 3gb are a hard limit of the hardware or if there are any ways to maybe move it to 3.5gb ... i know the h6 has 32bit memory addressing, but i think on other even full 32bit systems one can address close to 4gb ...

It's hard limit - address space is 32-bit and first byte from DRAM can be reached at address 0x40000000 (1G). If Allwinner would re-arrange peripherals below 1G, it could squeeze out another 512M or so, but in that case memory address decoder becomes more complicated (slower).

Link to comment
Share on other sites

Guys,

Just quick Q: on 5.3-rc7 I still have blackscreen on Eachlink H6 (even with video=HDMI-A-1:e).

Is this 5.3 kernel issue or rather something else?

 

btw: I switch to beelink Gs1 and got almost fully working with mainline 5.3-rc7 (so far except: thermal, cpu freq. scaling and t720 gpu - but this is different story...)  

 

Link to comment
Share on other sites

12 hours ago, jernej said:

@PiotrO 5.3-rc8 contains fixes needed for this workaround to work. Can you try again?

@jernej,

 

thx for hint!

for sure i'll test it.

rc7+patches You mention gives me working screen on eachlink h6 mini.

 

Last days I'm playing a bit with DVFS on h6 (beelink gs1).

I'm using 5.3-rc7 mainline  + and megous patches (also verified with Yours libreelec patches for h6).

I got ths working (as I see entries in /sys/class/thermal)

 

So next I tried to play with cpufreq.

I added clk to cpu cores (like in https://github.com/megous/linux/commit/19a1b4942b8f040f2b8f2d322368518c5776025b), OPP tables (like in https://github.com/megous/linux/commit/b4aca20e5ce774f6f91bc79317d232ead36e8ede) and trip points/cooling maps (like in https://github.com/megous/linux/commit/b1a1c764c50b6d2d86d1c9124d01ca1726836e9b ). Next I enabled cpu0 power from dcdca reg and my gs1 boots.

 

but here is no any entries in /sys/class/cpufreq 

 

What intriguing me: in megous & Yours patches there is no any touch in cpufreq-dt-platdev for H6 ( https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/tree/drivers/cpufreq/cpufreq-dt-platdev.c?id=089cf7f6ecb266b6a4164919a2e69bd2f938374a#n28

 

so cpufreq-dt will not load for h6.

By curiosity I added 'sun50i-h6' entry in cpufreq-dt-platdev.c and now kernel tries to load cpufreq-dt module but fails with error -2 (cant get cpu0 clock).

interesting.

maybe clock framework not provides required method clock_get to cpufreq?

Link to comment
Share on other sites

@PiotrO - did you add a supply to your cpu too? - like https://github.com/megous/linux/blob/orange-pi-5.1/arch/arm64/boot/dts/allwinner/sun50i-h6-orangepi-3.dts#L122

 

on the h6 tv boxes this is getting a bit tricky as they do not have a real regulator for the cpu voltage - you might have a look at my hack in the patch in the link below: see vcccpu (as some kind of dummy regulator) in the dts and the hacked opp tables in the h6 dtsi to allow this single voltage for all frequencies - but this is just a hack for now ... on the megous 5.2 kernel both the temp sensor and cpufreq are working well this way.

 

best wishes - hexdump

 

 

Link to comment
Share on other sites

1 hour ago, hexdump said:

@PiotrO - did you add a supply to your cpu too? - like https://github.com/megous/linux/blob/orange-pi-5.1/arch/arm64/boot/dts/allwinner/sun50i-h6-orangepi-3.dts#L122

 

on the h6 tv boxes this is getting a bit tricky as they do not have a real regulator for the cpu voltage - you might have a look at my hack in the patch in the link below: see vcccpu (as some kind of dummy regulator) in the dts and the hacked opp tables in the h6 dtsi to allow this single voltage for all frequencies - but this is just a hack for now ... on the megous 5.2 kernel both the temp sensor and cpufreq are working well this way.

 

 

 

@hexdump,

Yes. I added these entries as indeed adding cpu supply is a must to get my GS1 and eachlink working. I understand You have working DVFS on Yours H6 hw.

Do You have any entries in /sys/class/cpufreq ?

Also - what is best way to see what is current cpu freq/voltage & also to see how system walks on dvfs trips?

 

Link to comment
Share on other sites

@PiotrO - with megous 5.2 tree i have a normal /sys/devices/cpu/cpu0/cpufreq and i can see all the frequencies (up to 1.8ghz is possible) i have hacked the voltage for into the h6 dtsi and thermal throttling is working perfectly well too as long as there is enough airflow so that just reducing the frequency can cool the cpu enough down (as there is no voltage scaling, which usually reduces heat the most)

 

Link to comment
Share on other sites

10 hours ago, hexdump said:

@PiotrO - with megous 5.2 tree i have a normal /sys/devices/cpu/cpu0/cpufreq and i can see all the frequencies (up to 1.8ghz is possible) i have hacked the voltage for into the h6 dtsi and thermal throttling is working perfectly well too as long as there is enough airflow so that just reducing the frequency can cool the cpu enough down (as there is no voltage scaling, which usually reduces heat the most)

 

Hmm - interesting: in my case on 5.3-rc8 it looks I need to look in: /sys/devices/system/cpu/cpufreq/policy0

And indeed i.e.:

cat /sys/devices/system/cpu/cpufreq/policy0/stats/trans_table
   From  :    To
         :    480000    720000    816000    888000   1080000   1320000   1488000   1800000
   480000:         0         0         0         0         0         0         0         0
   720000:         0         0         0         0         0         0         0         0
   816000:         0         0         0         0         0         0         0         0
   888000:         0         0         0         0         0         0         0         0
  1080000:         0         0         0         0         0         0         0         1
  1320000:         0         0         0         0         0         0         0         0
  1488000:         0         0         0         0         0         0         0         0
  1800000:         0         0         0         0         0         0         0         0 

but

cat /sys/devices/system/cpu/cpufreq/policy0/scaling_setspeed
<unsupported>
  
echo 1080000 > /sys/devices/system/cpu/cpufreq/policy0/scaling_setspeed
ash: write error: Invalid argument
  

is it setspeed working for You on 5.2?

 

Link to comment
Share on other sites

i am getting the same error on the megous 5.2 tree, but i must admin that i never used this scaling_setspeed functionality yet ... frequency scaling as such is working well though:

 

root@eachlink:~# cat /sys/devices/system/cpu/cpufreq/policy0/stats/time_in_state
480000 14726
720000 231
816000 96
888000 120
1080000 458
1320000 136
1488000 149
1800000 3333

Link to comment
Share on other sites

Hi all,

 

I have a Tanix TX6 4Gb/32Gb on the way. I hope to use it with armbian (if that does not work, I'll use libreelec but I'd prefer having a generic linux). Is there a step by step guide on how to build an armbian image. I read the whole thread and saw that megous tree is almost good to go especially with 5.4 that got a lot of patch included. It's less clear for uboot, is latest uboot good to use or is there some patch to use.

 

Is there a fork of armbian/build with everything included maybe ?

 

Thanks in advance for any help

Link to comment
Share on other sites

On 7/13/2019 at 2:16 AM, hexdump said:

maybe its time to start your armbian image build machinery to spin a test image ..

Sorry, I just now saw the messages for me (I was on vacation when these messages were written and missed them).  I have now started preparing to run Armbian on H6 and discovered these messages. Launch Armbian on TV box H6 still someone interestingly ?

Link to comment
Share on other sites

6 hours ago, balbes150 said:

Sorry, I just now saw the messages for me (I was on vacation when these messages were written and missed them).  I have now started preparing to run Armbian on H6 and discovered these messages. Launch Armbian on TV box H6 still someone interestingly ?

 

Oh sure the H6 is a nice processor, and the Tanix is a sweet hardware!

Link to comment
Share on other sites

hi @balbes150, sure there is still a lot of interest in h6 tv box support - they are easily available, they are usually quite cheap (around 30+ euro for 4/32g), their performance is very good (4x1.8ghz if cooled well) and the h6 mainline support including panfrost is progressing very well ...

 

as a base i would recommend the megous tree as it already has a lot of h6 patches not yet in mainline in it (it has v5.4 and v5.5 branches) -> https://github.com/megous/linux/tree/orange-pi-5.4

 

i have some patches on top of it to add tv box ethernet support and to fake the opp tables and gpu power to give access to all cpu frequencies and the gpu as there is no software controllable power in tv boxes (like for instance in the orange pi 3) - i'll recheck them against 5.4 in the next days and upload some updated ones here

 

other ressources of interest:

best wishes - hexdump

Link to comment
Share on other sites

17 hours ago, hexdump said:

i have some patches on top of it to add tv box ethernet support and to fake the opp tables and gpu power to give access to all cpu frequencies and the gpu as there is no software controllable power in tv boxes (like for instance in the orange pi 3) - i'll recheck them against 5.4 in the next days and upload some updated ones here

Ok

 

17 hours ago, hexdump said:

has brought the h6 support for libreelec quite far

Yes, I used these developments to create my (I added the familiar features I use in all other LE builds) Le variant for Tanix TX6 :)

 

https://yadi.sk/d/GJbDt3-FjQ-dQA

 

I use these sources to create a version of Armbian (I'm currently testing the first alpha version of the image Armbian on TX6).

 

@hexdump I don't have a UART console on the TX6 (I haven't found how to connect it to this model). Can you show UART console output from your h6 model if you write only u-boot to SD card (no system) ? Did I understand correctly that you have an Eachlink H6 model ? And do you have a u-boot file for this model ?

Link to comment
Share on other sites

Took "clean" config from LE and built Armbian with It (version 20191222). Now the wired network works.  Perhaps when using the universal kernel config, some options are not in the state that would ensure the operation of a wired network. :)

 

@hexdump  @PiotrO   Can you drop me a copy of the u-boot and dtb you use for Eachlink H6 ? For u-boot, you can simply make a copy of the DD - 4M from your working SD card.

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

Terms of Use - Privacy Policy - Guidelines