<apritzel>
jernej: digging through the DE2 U-Boot driver, I see that it sets bit 0 in DE2TCON_MUX (offset 0x10), to connect mixer0<->tcon1 and mixer1<->tcon0, but the kernel does not touch this register at all?
<apritzel>
is that correct, and if yes, why was it done this way? Is it somehow simpler this way or just some random configuration choice?
kuba2k21 has joined #linux-sunxi
kuba2k2 has quit [Quit: Ping timeout (120 seconds)]
swiftgeek has quit [Ping timeout: 480 seconds]
swiftgeek has joined #linux-sunxi
ftg has quit [Read error: Connection reset by peer]
bauen1 has quit [Ping timeout: 480 seconds]
swiftgeek has quit [Ping timeout: 480 seconds]
bauen1 has joined #linux-sunxi
swiftgeek has joined #linux-sunxi
zoengjay has joined #linux-sunxi
cnxsoft has joined #linux-sunxi
apritzel has quit [Ping timeout: 480 seconds]
swiftgeek has quit [Ping timeout: 480 seconds]
sauce has quit [Ping timeout: 480 seconds]
swiftgeek has joined #linux-sunxi
sauce has joined #linux-sunxi
bauen1 has quit [Ping timeout: 480 seconds]
bauen1 has joined #linux-sunxi
Daanct12 has joined #linux-sunxi
hexdump01 has joined #linux-sunxi
hexdump0815 has quit [Ping timeout: 480 seconds]
Daanct12 has quit [Quit: WeeChat 4.5.1]
<jernej>
apritzel: when DE2 doesn't have TCON TOP, switching between mixers and TCONs can be done this way. It was done this way to always use mixer0, which is a bit easier, since mixer1 may have different functionality. Although for U-Boot that doesn't matter much, if at all.
bauen1 has quit [Ping timeout: 480 seconds]
JohnDoe_71Rus has joined #linux-sunxi
bauen1 has joined #linux-sunxi
bauen1 has quit [Ping timeout: 480 seconds]
bauen1 has joined #linux-sunxi
radxanaoki has joined #linux-sunxi
apritzel has joined #linux-sunxi
apritzel has quit [Ping timeout: 480 seconds]
cnxsoft1 has joined #linux-sunxi
cnxsoft has quit [Ping timeout: 480 seconds]
Robot_ has joined #linux-sunxi
radxanaoki has quit [Quit: radxanaoki]
bauen1 has quit [Ping timeout: 480 seconds]
evgeny_boger has joined #linux-sunxi
evgeny_boger has quit [Ping timeout: 480 seconds]
ity1 has joined #linux-sunxi
ity has quit [Ping timeout: 480 seconds]
bauen1 has joined #linux-sunxi
apritzel has joined #linux-sunxi
kuba2k21 has quit []
kuba2k2 has joined #linux-sunxi
kuba2k2 has quit []
kuba2k2 has joined #linux-sunxi
kuba2k2 has quit []
kuba2k2 has joined #linux-sunxi
kikuchan has joined #linux-sunxi
<kikuchan>
Hello, I've ported MIPI-DSI, DPHY, DE (TCON, MIXER) Linux drivers to U-Boot with a new simple hierarchical clock system.
<kikuchan>
Anyone interested in? I need a feedback whether I'm on the right track.
<apritzel>
kikuchan: oh no, this is what I was doing in the last week as well ...
<apritzel>
oh, well, I guess we can extract the best of it, and have a contributor and reviewer. And yours seems to be more complete anyway
<apritzel>
so the whole clock driver seems to be a bit too much, I got away with something simpler: we don't need the flexibility of Linux, we just need a few clocks, so I have switch/case plus helper functions instead of structs
<kikuchan>
Ah, I thought the hierarchical clock driver is required to parse DT correctly. If it works with DT, any implementation is welcome.
<apritzel>
well, it's technically hierarchical, just very sparsely implemented, if you like
<apritzel>
and while Linux does it with struct's, I am just putting that in code, since we need just a few clocks
<kikuchan>
I see
<apritzel>
but anyway, your code looks very good, just a bit massive ...
<apritzel>
does it cover HDMI as well?
<apritzel>
kikuchan: I need to have a closer look tonight, but would try to give you some guidance
<kikuchan>
Unfortunately not yet. (HDMI
<kikuchan>
thank you
<kikuchan>
That repository contains a panel driver that I want to publish the most. I've developed it so that we can share a panel firmware between U-Boot and Linux.
<apritzel>
> no HDMI: that's alright, because that's what I focused on. And I was worried how to test my changes on an LCD setup (don't have any, really)
JohnDoe_71Rus has joined #linux-sunxi
Soupborsh has quit [Quit: Bridge terminating on SIGTERM]
barni2000[m] has quit []
exkc has quit []
Quantum_3[m] has quit []
hlauer has quit []
triskit has quit [Quit: Bridge terminating on SIGTERM]
anarsoul[m] has quit [Quit: Bridge terminating on SIGTERM]
fraolt has quit [Read error: Connection reset by peer]
Newbyte has quit [Remote host closed the connection]
cnxsoft1 has quit [Ping timeout: 480 seconds]
Tooniis[m] has joined #linux-sunxi
cnxsoft has joined #linux-sunxi
<jernej>
apritzel: I posted U-Boot patches for move to DT long time ago, but some of them weren't merged, notably HDMI
<jernej>
however, I never tackled clocks
<apritzel>
oh, did you? I thought that most of the DE2 code in U-Boot is from you, and I think allwinner,sun8i-a83t-dw-hdmi is one of the few compatible strings we actually use
<jernej>
and conversion to use HDMI PHY DT node wasn't either
<jernej>
in any case, feel free to use anything for conversion
<apritzel>
yeah, that looks tempting, we can now pick the cherries from each series ;-)
cnxsoft has quit [Ping timeout: 480 seconds]
<jernej>
I remember brainstorming session that it was not possible to register two vidconsoles at the time. Not sure if anything changed in this regard.
vveapon has quit [Ping timeout: 480 seconds]
vveapon has joined #linux-sunxi
hazardchem has quit [Read error: Connection reset by peer]
hazardchem has joined #linux-sunxi
apritzel_ has quit [Ping timeout: 480 seconds]
dsimic is now known as Guest9988
dsimic has joined #linux-sunxi
Guest9988 has quit [Ping timeout: 480 seconds]
colinsane has joined #linux-sunxi
Newbyte has joined #linux-sunxi
barni2000[m] has joined #linux-sunxi
soupborsh[m] has joined #linux-sunxi
colinsane1 has joined #linux-sunxi
colinsane1 has quit []
colinsane has quit [Ping timeout: 480 seconds]
paulk has quit [Ping timeout: 480 seconds]
paulk-ter has joined #linux-sunxi
<kuba2k2>
hello, is there something that can be tweaked in the mainline SD/MMC driver?
<kuba2k2>
compared to BSP, it's 2x slower in sequential read, and takes over 4x as long to mount the rootfs
<kuba2k2>
(comparisons on the same board, same SD card, same OS install)
<gamiee>
kuba2k2: maybe some SD mode is not implemented?
<kuba2k2>
how can I find out?
apritzel has quit [Ping timeout: 480 seconds]
<anarsoul>
compare "dmesg | grep mmc" output for BSP and mainline
<wigyori>
does someone have an opi zero3 (h618) ?
<kuba2k2>
anarsoul: what exactly should I compare? these are two different drivers, the output is totally different too
<wigyori>
i don't - and i've got a bugreport about it not booting up a kernel anymore after upgrading u-boot to 2025.01. The suggested fix for it is adding back the "temporary workaround for enabing i2c clocks" - which seems to be strange a bit
<anarsoul>
kuba2k2: post it to pastebin and share it here
<anarsoul>
so it runs at 50mhz on BSP, nothing special (i.e. it doesn't look like the host supports 1.8V signalling). You should check whether it runs at 50mhz on mainline
<anarsoul>
check the clock in /sys/kernel/debug/clk_summary
<kuba2k2>
yes, mmc0 and mmc1 at 50 MHz
vagrantc has joined #linux-sunxi
<anarsoul>
no ideas then
<kuba2k2>
jernej: looking more closely at the TVE TOP, it seems to take inputs *from* the TVEs - perhaps it would be more correct to position it *after* the TVEs in the DT endpoint graph?
<kuba2k2>
because it is the part that assigns TVE0/TVE1 outputs to DACs (connectors?)
<kuba2k2>
so, if I understand it right, should be tcon_tv0/1_out -> tve0/1_in, and tve0/1_in -> tve_top_in, and tve_top_out -> [connector]
<kuba2k2>
or am I speaking nonsense
<kuba2k2>
(in DT)
<jernej>
that's right
<jernej>
just model ports in tve_top to represent dacs
<jernej>
t113 has one dac, but r40 has 4
<kuba2k2>
yep, I remember
<kuba2k2>
that's great :)
hexdump01 has quit []
hexdump0815 has joined #linux-sunxi
apritzel has joined #linux-sunxi
<apritzel>
kuba2k2: is this about SD cards or eMMC? And what is the performance?
<kuba2k2>
SD card
<kuba2k2>
with "pv /dev/mmcblk0 > /dev/null" it's 11MB/s on mainline, and 22MB/s on BSP
<apritzel>
on the SD card side mainline supports HighSpeed: that's 50 MHz at 4bits, giving about 23 MB/s
<apritzel>
which SoC?
<kuba2k2>
mounting an ext4 rootfs takes 2sec on BSP, and 8 sec on mainline
<kuba2k2>
T113-S3 is the soc
<apritzel>
11 MB/s sounds like a missing clock doubling: we had this in the past
<apritzel>
T113 is same as D1, so I wonder why noone reported that before?
* apritzel
grabs his MangoPi ...
<kuba2k2>
I'm not sure why
<kuba2k2>
do you have the mangopi dual? or the D1s version
<kuba2k2>
previously I blamed an unbranded 2GiB microSD for the slow speeds... but now I've got a new class10 card, and the results were the same. So I compared to BSP and found that it's better there
<apritzel>
MQ-R, so the ARM version
<kuba2k2>
actually the MQ-R seems to come in both variants
<apritzel>
yeah, there are not very clever with their naming, but it's the T113-s3, with dual A7s
<kuba2k2>
I guess it's only a single A7 on mainline :D
<apritzel>
how so? we spent quite some time to get the PSCI code working in U-Boot
<kuba2k2>
ah, I didn't know that was implemented already (linux-sunxi support table only lists it as N/A)
<kuba2k2>
but I'm using awboot so no PSCI :(
<apritzel>
any reason you don't use U-Boot?
<kuba2k2>
I'm not sure, actually- perhaps because of the complexity and size of uboot (and I'm targeting an spi-flash for kernel storage on this board)
<kuba2k2>
maybe I'll switch at some point, knowing now that there are actual benefits
<apritzel>
are 475124 bytes too much?
<kuba2k2>
too much - perhaps not, but compared to 49152 bytes it's nearly 10x more :)
<jernej>
apritzel: are you working just to refactor U-Boot video driver to use DT more, or also add H6 driver?
<apritzel>
jernej: H6 (and H616) are the reason I am doing this, but from what I get the addresses and clocks cover a good deal of the differences
<apritzel>
(when looking at Jookia's H6(16) support series)
<jernej>
yeah, that's huge step forward, adding tcon_top, de3 and hdmi is then pretty self contained and simple
<apritzel>
I thought we should bite the bullet now and fix this properly, before adding support for more SoCs, which would make it more messy
<apritzel>
apparently there is some momentum now, with kikuchan's series for instance
<jernej>
well, I have also my own lcd on t507 support for U-Boot :)
<jernej>
*have
<jernej>
but I hacked clocks a lot, so I would be very happy for proper solution in that regard :)
<apritzel>
I am quite pleased with how the clocks look by now, but my code has quite some gaps in the other parts, so seems like a good fit ;-)
radxanaoki has joined #linux-sunxi
<apritzel>
kuba2k2: ah, was fighting with the UART and the load addresses, but I see it now: it's indeed only 11696 KB/s
<apritzel>
kuba2k2: ah, found and fixed it: there is an undocumented post divider of 2 in the MMC mod clock, like in every other recent SoC, really
<apritzel>
now I get to send a patch that doubles the performance!!!
<apritzel>
in U-Boot it's even worse, we miss that the source is PLL_PERIPH0, not PERIPH0_2X, as in the other SoCs, so it's only 5.8 MB/s there